]> git.ipfire.org Git - thirdparty/mdadm.git/commitdiff
mdmon: don't copy an invalid chunk_size
authorNeilBrown <neilb@suse.de>
Tue, 30 Nov 2010 07:35:36 +0000 (18:35 +1100)
committerNeilBrown <neilb@suse.de>
Tue, 30 Nov 2010 07:35:36 +0000 (18:35 +1100)
As chunk_size in mdstat_ent is never set, we shouldn't copy
it into a->info.array.
In fact, it is safest to get rid of the field altogether.

Reported-by: "Kwolek, Adam" <adam.kwolek@intel.com>
Signed-off-by: NeilBrown <neilb@suse.de>
managemon.c
mdadm.h
mdstat.c

index 8915522df0102ce0225b9596c974dcec1b0890ff..12a37927bcf12e250d54f294a88bc97008aa5414 100644 (file)
@@ -399,7 +399,6 @@ static void manage_member(struct mdstat_ent *mdstat,
 
        // FIXME
        a->info.array.raid_disks = mdstat->raid_disks;
-       a->info.array.chunk_size = mdstat->chunk_size;
        // MORE
 
        /* honor 'frozen' */
diff --git a/mdadm.h b/mdadm.h
index 05bf0b8de92314e9ee3048b6fcba7edf1ce60a75..91afe160c32a5b1871c15ce1b688eb2489295225 100644 (file)
--- a/mdadm.h
+++ b/mdadm.h
@@ -386,7 +386,6 @@ struct mdstat_ent {
        int             resync; /* 3 if check, 2 if reshape, 1 if resync, 0 if recovery */
        int             devcnt;
        int             raid_disks;
-       int             chunk_size;
        char *          metadata_version;
        struct dev_member {
                char                    *name;
index bb030bf391774fe491a9c8e70c3b6156a7c59c33..fdce51655f8643e90ec94ec37bbf4183753353c7 100644 (file)
--- a/mdstat.c
+++ b/mdstat.c
@@ -185,7 +185,6 @@ struct mdstat_ent *mdstat_read(int hold, int start)
                ent->resync = 0;
                ent->metadata_version = NULL;
                ent->raid_disks = 0;
-               ent->chunk_size = 0;
                ent->devcnt = 0;
                ent->members = NULL;