diff options
author | Coywolf Qi Hunt <qiyong@freeforge.net> | 2006-10-03 04:15:50 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-10-03 11:04:17 -0400 |
commit | 2d2063ceae73660d5142f4754d50a75b655fd1f9 (patch) | |
tree | fc0e810ec5e7fa01ab53fca93043d68813d9de7f | |
parent | 9b1d1dac181d8c1b9492e05cee660a985d035a06 (diff) |
[PATCH] md: remove unnecessary variable x in stripe_to_pdidx()
Signed-off-by: Coywolf Qi Hunt <qiyong@freeforge.net>
Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r-- | drivers/md/raid5.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c index 1c8ab340a11d..46fd651539fe 100644 --- a/drivers/md/raid5.c +++ b/drivers/md/raid5.c | |||
@@ -1351,10 +1351,9 @@ static int page_is_zero(struct page *p) | |||
1351 | static int stripe_to_pdidx(sector_t stripe, raid5_conf_t *conf, int disks) | 1351 | static int stripe_to_pdidx(sector_t stripe, raid5_conf_t *conf, int disks) |
1352 | { | 1352 | { |
1353 | int sectors_per_chunk = conf->chunk_size >> 9; | 1353 | int sectors_per_chunk = conf->chunk_size >> 9; |
1354 | sector_t x = stripe; | ||
1355 | int pd_idx, dd_idx; | 1354 | int pd_idx, dd_idx; |
1356 | int chunk_offset = sector_div(x, sectors_per_chunk); | 1355 | int chunk_offset = sector_div(stripe, sectors_per_chunk); |
1357 | stripe = x; | 1356 | |
1358 | raid5_compute_sector(stripe*(disks-1)*sectors_per_chunk | 1357 | raid5_compute_sector(stripe*(disks-1)*sectors_per_chunk |
1359 | + chunk_offset, disks, disks-1, &dd_idx, &pd_idx, conf); | 1358 | + chunk_offset, disks, disks-1, &dd_idx, &pd_idx, conf); |
1360 | return pd_idx; | 1359 | return pd_idx; |