From: Colin Ian King Date: Sun, 24 May 2020 16:10:43 +0000 (+0100) Subject: loop: remove redundant assignment to variable error X-Git-Tag: v5.8-rc1~191^2~7 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=d29b92f57ecee125a86587919a22152a702a6411;p=tomoyo%2Ftomoyo-test1.git loop: remove redundant assignment to variable error The variable error is being assigned a value that is never read so the assignment is redundant and can be removed. Addresses-Coverity: ("Unused value") Signed-off-by: Colin Ian King Signed-off-by: Jens Axboe --- diff --git a/drivers/block/loop.c b/drivers/block/loop.c index a565c5aafa52..8462ada86e91 100644 --- a/drivers/block/loop.c +++ b/drivers/block/loop.c @@ -1136,8 +1136,6 @@ static int loop_configure(struct loop_device *lo, fmode_t mode, if (error) goto out_unlock; - error = 0; - set_device_ro(bdev, (lo->lo_flags & LO_FLAGS_READ_ONLY) != 0); lo->use_dio = lo->lo_flags & LO_FLAGS_DIRECT_IO;