]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
block: blk-crypto-fallback: remove redundant initialization of variable err
authorColin Ian King <colin.king@canonical.com>
Tue, 26 May 2020 22:49:02 +0000 (23:49 +0100)
committerJens Axboe <axboe@kernel.dk>
Wed, 27 May 2020 11:41:59 +0000 (05:41 -0600)
The variable err is being initialized with a value that is never read
and it is being updated later with a new value.  The initialization is
redundant and can be removed.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Eric Biggers <ebiggers@google.com>
Reviewed-by: Satya Tangirala <satyat@google.com>
Addresses-Coverity: ("Unused value")
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-crypto-fallback.c

index 74ab137ae3baa09cf09d0b78d937e818d0a80082..6e49688a2d8023c968f775c64534fe8e0b52de57 100644 (file)
@@ -529,7 +529,7 @@ static bool blk_crypto_fallback_inited;
 static int blk_crypto_fallback_init(void)
 {
        int i;
-       int err = -ENOMEM;
+       int err;
 
        if (blk_crypto_fallback_inited)
                return 0;