[Drbd-dev] [PATCH] block/drbd: remove redundant initialization to variable rv
Colin King
colin.king at canonical.com
Sat Jun 13 11:58:15 CEST 2020
From: Colin Ian King <colin.king at canonical.com>
The variable rv 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.
Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king at canonical.com>
---
drivers/block/drbd/drbd_main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_main.c
index c094c3c2c5d4..22dfaa91a89d 100644
--- a/drivers/block/drbd/drbd_main.c
+++ b/drivers/block/drbd/drbd_main.c
@@ -3522,7 +3522,7 @@ void drbd_uuid_set_bm(struct drbd_device *device, u64 val) __must_hold(local)
*/
int drbd_bmio_set_n_write(struct drbd_device *device) __must_hold(local)
{
- int rv = -EIO;
+ int rv;
drbd_md_set_flag(device, MDF_FULL_SYNC);
drbd_md_sync(device);
--
2.25.1
More information about the drbd-dev
mailing list