]> sourceware.org Git - lvm2.git/commitdiff
debug: print VG name in log messages for segment errors
authorNikhil Kshirsagar <nkshirsa@redhat.com>
Tue, 26 Nov 2019 07:06:45 +0000 (12:36 +0530)
committerZdenek Kabelac <zkabelac@redhat.com>
Tue, 10 Dec 2019 14:44:06 +0000 (15:44 +0100)
Signed-off-by: Nikhil Kshirsagar <nkshirsa@redhat.com>
lib/metadata/merge.c

index e482921ce00ae71ac2b48c53620ba76977b24ce2..11b26b46994b13ab7d581421ac15d8d94e23a2ba 100644 (file)
@@ -73,7 +73,7 @@ int lv_merge_segments(struct logical_volume *lv)
 
 #define seg_error(msg) do { \
                log_error("LV %s, segment %u invalid: %s for %s segment.", \
-                         seg->lv->name, seg_count, (msg), lvseg_name(seg)); \
+                         display_lvname(seg->lv), seg_count, (msg), lvseg_name(seg)); \
                if ((*error_count)++ > ERROR_MAX) \
                        return; \
        } while (0)
@@ -86,14 +86,14 @@ int lv_merge_segments(struct logical_volume *lv)
  */
 #define raid_seg_error(msg) do { \
        log_error("LV %s invalid: %s for %s segment", \
-                 seg->lv->name, (msg), lvseg_name(seg)); \
+                 display_lvname(seg->lv), (msg), lvseg_name(seg)); \
        if ((*error_count)++ > ERROR_MAX) \
                return; \
 } while (0)
 
 #define raid_seg_error_val(msg, val) do { \
        log_error("LV %s invalid: %s (is %u) for %s segment", \
-                 seg->lv->name, (msg), (val), lvseg_name(seg)); \
+                 display_lvname(seg->lv), (msg), (val), lvseg_name(seg)); \
        if ((*error_count)++ > ERROR_MAX) \
                return; \
 } while(0)
This page took 1.211024 seconds and 5 git commands to generate.