aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/raid5.c
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2009-09-23 04:06:41 -0400
committerNeilBrown <neilb@suse.de>2009-09-23 04:06:41 -0400
commita9f326ebf22a0de776815240fb76dabe139397ea (patch)
tree4402ba08931cd0663aca077be4d26e66c91869bd /drivers/md/raid5.c
parent7fa07729e439a6184bd824746d06a49cca553f15 (diff)
md: remove sparse waring "symbol xxx shadows an earlier one"
Rename some variable and remove some duplicate definitions to avoid there warnings. None of them are actual errors. Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/raid5.c')
-rw-r--r--drivers/md/raid5.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
index 826eb3467357..763dcc40e513 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -2756,7 +2756,8 @@ static bool handle_stripe5(struct stripe_head *sh)
2756 rcu_read_lock(); 2756 rcu_read_lock();
2757 for (i=disks; i--; ) { 2757 for (i=disks; i--; ) {
2758 mdk_rdev_t *rdev; 2758 mdk_rdev_t *rdev;
2759 struct r5dev *dev = &sh->dev[i]; 2759
2760 dev = &sh->dev[i];
2760 clear_bit(R5_Insync, &dev->flags); 2761 clear_bit(R5_Insync, &dev->flags);
2761 2762
2762 pr_debug("check %d: state 0x%lx toread %p read %p write %p " 2763 pr_debug("check %d: state 0x%lx toread %p read %p write %p "
@@ -3880,7 +3881,7 @@ static sector_t reshape_request(mddev_t *mddev, sector_t sector_nr, int *skipped
3880 INIT_LIST_HEAD(&stripes); 3881 INIT_LIST_HEAD(&stripes);
3881 for (i = 0; i < reshape_sectors; i += STRIPE_SECTORS) { 3882 for (i = 0; i < reshape_sectors; i += STRIPE_SECTORS) {
3882 int j; 3883 int j;
3883 int skipped = 0; 3884 int skipped_disk = 0;
3884 sh = get_active_stripe(conf, stripe_addr+i, 0, 0, 1); 3885 sh = get_active_stripe(conf, stripe_addr+i, 0, 0, 1);
3885 set_bit(STRIPE_EXPANDING, &sh->state); 3886 set_bit(STRIPE_EXPANDING, &sh->state);
3886 atomic_inc(&conf->reshape_stripes); 3887 atomic_inc(&conf->reshape_stripes);
@@ -3896,14 +3897,14 @@ static sector_t reshape_request(mddev_t *mddev, sector_t sector_nr, int *skipped
3896 continue; 3897 continue;
3897 s = compute_blocknr(sh, j, 0); 3898 s = compute_blocknr(sh, j, 0);
3898 if (s < raid5_size(mddev, 0, 0)) { 3899 if (s < raid5_size(mddev, 0, 0)) {
3899 skipped = 1; 3900 skipped_disk = 1;
3900 continue; 3901 continue;
3901 } 3902 }
3902 memset(page_address(sh->dev[j].page), 0, STRIPE_SIZE); 3903 memset(page_address(sh->dev[j].page), 0, STRIPE_SIZE);
3903 set_bit(R5_Expanded, &sh->dev[j].flags); 3904 set_bit(R5_Expanded, &sh->dev[j].flags);
3904 set_bit(R5_UPTODATE, &sh->dev[j].flags); 3905 set_bit(R5_UPTODATE, &sh->dev[j].flags);
3905 } 3906 }
3906 if (!skipped) { 3907 if (!skipped_disk) {
3907 set_bit(STRIPE_EXPAND_READY, &sh->state); 3908 set_bit(STRIPE_EXPAND_READY, &sh->state);
3908 set_bit(STRIPE_HANDLE, &sh->state); 3909 set_bit(STRIPE_HANDLE, &sh->state);
3909 } 3910 }