]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
mmc: wbsd: remove redundant assignment to variable id
authorColin Ian King <colin.i.king@gmail.com>
Mon, 5 Feb 2024 19:13:10 +0000 (19:13 +0000)
committerUlf Hansson <ulf.hansson@linaro.org>
Tue, 13 Feb 2024 13:01:28 +0000 (14:01 +0100)
The variable id is being initialized with a value that is never
read, it is being re-assigned later on. The initialization is
redundant and can be removed.

Cleans up clang scan build warning:
drivers/mmc/host/wbsd.c:1287:4: warning: Value stored to 'id'
is never read [deadcode.DeadStores]

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Link: https://lore.kernel.org/r/20240205191310.1848561-1-colin.i.king@gmail.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/wbsd.c

index 001a468bc149a15116106d8630f8f2541642da73..f0562f712d98e412ec5d96b02519fee0f1e4a2c1 100644 (file)
@@ -1284,8 +1284,6 @@ static int wbsd_scan(struct wbsd_host *host)
                        continue;
 
                for (j = 0; j < ARRAY_SIZE(unlock_codes); j++) {
-                       id = 0xFFFF;
-
                        host->config = config_ports[i];
                        host->unlock_code = unlock_codes[j];