[PATCH] 4/4: Only dump metadata once per physical device

"Darrick J. Wong" <[email protected]>
Newsgroups gmane.linux.ataraid
Organization IBM LTC
Message-ID <[email protected]>
Greetings,

These are preliminary patches to modify dmraid so that we can have
multiple raid_dev structures per physical device.  The DDF1
specification allows for a disk to participate in multiple RAID arrays,
which is what is gained from these patches.  They've been tested against
2.6.16.19 + dmraid45 on Ubuntu 6.06, and seem to be pretty stable.  At
this stage, I'm looking for comments about the code because it touches
core dmraid code and could (but shouldn't) break support for hardware
that I don't have.

This patch modifies the code that dumps disk metadata so that we only
call fmt->log once per physical device (and ignore clones).

--D

Signed-off-by: Darrick J. Wong <[email protected]>

_______________________________________________
Ataraid-list mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/ataraid-list
quiet_metadata_dump.patch (text/x-patch, 463 B)
diff -Naurp v11.orig/lib/display/display.c v11-mdisk3/lib/display/display.c
--- v11.orig/lib/display/display.c	2006-02-02 06:06:03.000000000 -0800
+++ v11-mdisk3/lib/display/display.c	2006-06-01 16:58:56.000000000 -0700
@@ -122,7 +122,7 @@ static void log_rd_native(struct lib_con
 {
 	struct raid_dev *rd = list_entry(pos, typeof(*rd), list);
 
-	if (rd->fmt->log) {
+	if (rd->fmt->log && !rd->is_clone) {
 		rd->fmt->log(lc, rd);
 		log_print(lc, "");
 	} else
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.