[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230326125637.1352895-1-trix@redhat.com>
Date: Sun, 26 Mar 2023 08:56:37 -0400
From: Tom Rix <trix@...hat.com>
To: song@...nel.org, nathan@...nel.org, ndesaulniers@...gle.com
Cc: linux-raid@...r.kernel.org, linux-kernel@...r.kernel.org,
llvm@...ts.linux.dev, Tom Rix <trix@...hat.com>
Subject: [PATCH] md/raid5: remove unused working_disks variable
clang with W=1 reports
drivers/md/raid5.c:7719:6: error: variable 'working_disks'
set but not used [-Werror,-Wunused-but-set-variable]
int working_disks = 0;
^
This variable is not used so remove it.
Signed-off-by: Tom Rix <trix@...hat.com>
---
drivers/md/raid5.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
index 7b820b81d8c2..2b1e78c46817 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -7716,7 +7716,6 @@ static void raid5_set_io_opt(struct r5conf *conf)
static int raid5_run(struct mddev *mddev)
{
struct r5conf *conf;
- int working_disks = 0;
int dirty_parity_disks = 0;
struct md_rdev *rdev;
struct md_rdev *journal_dev = NULL;
@@ -7913,7 +7912,6 @@ static int raid5_run(struct mddev *mddev)
goto abort;
}
if (test_bit(In_sync, &rdev->flags)) {
- working_disks++;
continue;
}
/* This disc is not fully in-sync. However if it
--
2.27.0
Powered by blists - more mailing lists