Blame SOURCES/lvm2-2_02_183-libdm-stats-move-no-regions-warning-after-dm_stats_l.patch

3a5d46
 libdm/libdm-stats.c | 10 +++++-----
3a5d46
 1 file changed, 5 insertions(+), 5 deletions(-)
3a5d46
3a5d46
diff --git a/libdm/libdm-stats.c b/libdm/libdm-stats.c
3a5d46
index 94ad380..6b4e3d8 100644
3a5d46
--- a/libdm/libdm-stats.c
3a5d46
+++ b/libdm/libdm-stats.c
3a5d46
@@ -2336,11 +2336,6 @@ int dm_stats_populate(struct dm_stats *dms, const char *program_id,
3a5d46
 		return 0;
3a5d46
 	}
3a5d46
 
3a5d46
-	if (!dms->nr_regions) {
3a5d46
-		log_error("No regions registered.");
3a5d46
-		return 0;
3a5d46
-	}
3a5d46
-
3a5d46
 	/* allow zero-length program_id for populate */
3a5d46
 	if (!program_id)
3a5d46
 		program_id = dms->program_id;
3a5d46
@@ -2352,6 +2347,11 @@ int dm_stats_populate(struct dm_stats *dms, const char *program_id,
3a5d46
 		goto_bad;
3a5d46
 	}
3a5d46
 
3a5d46
+	if (!dms->nr_regions) {
3a5d46
+		log_verbose("No stats regions registered: %s", dms->name);
3a5d46
+		return 0;
3a5d46
+	}
3a5d46
+
3a5d46
 	dms->walk_flags = DM_STATS_WALK_REGION;
3a5d46
 	dm_stats_walk_start(dms);
3a5d46
 	do {