* [patch]raid5: remove unused variables
@ 2012-04-17 5:09 Shaohua Li
2012-04-17 6:36 ` NeilBrown
0 siblings, 1 reply; 2+ messages in thread
From: Shaohua Li @ 2012-04-17 5:09 UTC (permalink / raw)
To: linux-raid; +Cc: neilb
The two variables are useless.
Signed-off-by: Shaohua Li <shli@fusionio.com>
---
drivers/md/raid5.c | 4 ----
1 file changed, 4 deletions(-)
Index: linux/drivers/md/raid5.c
===================================================================
--- linux.orig/drivers/md/raid5.c 2012-04-17 11:56:16.606009690 +0800
+++ linux/drivers/md/raid5.c 2012-04-17 11:57:47.026009295 +0800
@@ -3953,12 +3953,10 @@ static void make_request(struct mddev *m
plugged = mddev_check_plugged(mddev);
for (;logical_sector < last_sector; logical_sector += STRIPE_SECTORS) {
DEFINE_WAIT(w);
- int disks, data_disks;
int previous;
retry:
previous = 0;
- disks = conf->raid_disks;
prepare_to_wait(&conf->wait_for_overlap, &w, TASK_UNINTERRUPTIBLE);
if (unlikely(conf->reshape_progress != MaxSector)) {
/* spinlock is needed as reshape_progress may be
@@ -3973,7 +3971,6 @@ static void make_request(struct mddev *m
if (mddev->delta_disks < 0
? logical_sector < conf->reshape_progress
: logical_sector >= conf->reshape_progress) {
- disks = conf->previous_raid_disks;
previous = 1;
} else {
if (mddev->delta_disks < 0
@@ -3986,7 +3983,6 @@ static void make_request(struct mddev *m
}
spin_unlock_irq(&conf->device_lock);
}
- data_disks = disks - conf->max_degraded;
new_sector = raid5_compute_sector(conf, logical_sector,
previous,
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [patch]raid5: remove unused variables
2012-04-17 5:09 [patch]raid5: remove unused variables Shaohua Li
@ 2012-04-17 6:36 ` NeilBrown
0 siblings, 0 replies; 2+ messages in thread
From: NeilBrown @ 2012-04-17 6:36 UTC (permalink / raw)
To: Shaohua Li; +Cc: linux-raid
[-- Attachment #1: Type: text/plain, Size: 1654 bytes --]
On Tue, 17 Apr 2012 13:09:26 +0800 Shaohua Li <shli@kernel.org> wrote:
>
> The two variables are useless.
>
> Signed-off-by: Shaohua Li <shli@fusionio.com>
> ---
> drivers/md/raid5.c | 4 ----
> 1 file changed, 4 deletions(-)
>
> Index: linux/drivers/md/raid5.c
> ===================================================================
> --- linux.orig/drivers/md/raid5.c 2012-04-17 11:56:16.606009690 +0800
> +++ linux/drivers/md/raid5.c 2012-04-17 11:57:47.026009295 +0800
> @@ -3953,12 +3953,10 @@ static void make_request(struct mddev *m
> plugged = mddev_check_plugged(mddev);
> for (;logical_sector < last_sector; logical_sector += STRIPE_SECTORS) {
> DEFINE_WAIT(w);
> - int disks, data_disks;
> int previous;
>
> retry:
> previous = 0;
> - disks = conf->raid_disks;
> prepare_to_wait(&conf->wait_for_overlap, &w, TASK_UNINTERRUPTIBLE);
> if (unlikely(conf->reshape_progress != MaxSector)) {
> /* spinlock is needed as reshape_progress may be
> @@ -3973,7 +3971,6 @@ static void make_request(struct mddev *m
> if (mddev->delta_disks < 0
> ? logical_sector < conf->reshape_progress
> : logical_sector >= conf->reshape_progress) {
> - disks = conf->previous_raid_disks;
> previous = 1;
> } else {
> if (mddev->delta_disks < 0
> @@ -3986,7 +3983,6 @@ static void make_request(struct mddev *m
> }
> spin_unlock_irq(&conf->device_lock);
> }
> - data_disks = disks - conf->max_degraded;
>
> new_sector = raid5_compute_sector(conf, logical_sector,
> previous,
applied, thanks.
NeilBrown
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-04-17 6:36 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-04-17 5:09 [patch]raid5: remove unused variables Shaohua Li
2012-04-17 6:36 ` NeilBrown
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.