Commit f2421da3 authored by Neil Brown's avatar Neil Brown Committed by Trond Myklebust

[PATCH] MD - Remove old_dev field.

Remove old_dev field.

We used to monitor the pervious device number of a
component device for superblock maintenance.  This is
not needed any more.
parent d109d34c
...@@ -708,8 +708,8 @@ static void print_sb(mdp_super_t *sb) ...@@ -708,8 +708,8 @@ static void print_sb(mdp_super_t *sb)
static void print_rdev(mdk_rdev_t *rdev) static void print_rdev(mdk_rdev_t *rdev)
{ {
printk(KERN_INFO "md: rdev %s: O:%s, SZ:%08ld F:%d DN:%d ", printk(KERN_INFO "md: rdev %s, SZ:%08ld F:%d DN:%d ",
partition_name(rdev->dev), partition_name(rdev->old_dev), partition_name(rdev->dev),
rdev->size, rdev->faulty, rdev->desc_nr); rdev->size, rdev->faulty, rdev->desc_nr);
if (rdev->sb) { if (rdev->sb) {
printk(KERN_INFO "md: rdev superblock:\n"); printk(KERN_INFO "md: rdev superblock:\n");
...@@ -1029,12 +1029,6 @@ static mdk_rdev_t *md_import_device(kdev_t newdev, int on_disk) ...@@ -1029,12 +1029,6 @@ static mdk_rdev_t *md_import_device(kdev_t newdev, int on_disk)
partition_name(newdev)); partition_name(newdev));
goto abort_free; goto abort_free;
} }
if (rdev->sb->level != LEVEL_MULTIPATH)
rdev->old_dev = mk_kdev(rdev->sb->this_disk.major,
rdev->sb->this_disk.minor);
else
rdev->old_dev = NODEV;
} }
INIT_LIST_HEAD(&rdev->same_set); INIT_LIST_HEAD(&rdev->same_set);
...@@ -1954,7 +1948,6 @@ static int add_new_disk(mddev_t * mddev, mdu_disk_info_t *info) ...@@ -1954,7 +1948,6 @@ static int add_new_disk(mddev_t * mddev, mdu_disk_info_t *info)
printk(KERN_WARNING "md: error, md_import_device() returned %ld\n", PTR_ERR(rdev)); printk(KERN_WARNING "md: error, md_import_device() returned %ld\n", PTR_ERR(rdev));
return PTR_ERR(rdev); return PTR_ERR(rdev);
} }
rdev->old_dev = dev;
rdev->desc_nr = info->number; rdev->desc_nr = info->number;
rdev->raid_disk = info->raid_disk; rdev->raid_disk = info->raid_disk;
rdev->faulty = 0; rdev->faulty = 0;
...@@ -2104,7 +2097,6 @@ static int hot_add_disk(mddev_t * mddev, kdev_t dev) ...@@ -2104,7 +2097,6 @@ static int hot_add_disk(mddev_t * mddev, kdev_t dev)
* The rest should better be atomic, we can have disk failures * The rest should better be atomic, we can have disk failures
* noticed in interrupt contexts ... * noticed in interrupt contexts ...
*/ */
rdev->old_dev = dev;
rdev->size = size; rdev->size = size;
rdev->sb_offset = calc_dev_sboffset(rdev, mddev, persistent); rdev->sb_offset = calc_dev_sboffset(rdev, mddev, persistent);
......
...@@ -145,7 +145,6 @@ struct mdk_rdev_s ...@@ -145,7 +145,6 @@ struct mdk_rdev_s
struct list_head same_set; /* RAID devices within the same set */ struct list_head same_set; /* RAID devices within the same set */
kdev_t dev; /* Device number */ kdev_t dev; /* Device number */
kdev_t old_dev; /* "" when it was last imported */
unsigned long size; /* Device size (in blocks) */ unsigned long size; /* Device size (in blocks) */
mddev_t *mddev; /* RAID array if running */ mddev_t *mddev; /* RAID array if running */
unsigned long last_events; /* IO event timestamp */ unsigned long last_events; /* IO event timestamp */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment