[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20210521103138.43383-1-colin.king@canonical.com>
Date: Fri, 21 May 2021 11:31:38 +0100
From: Colin King <colin.king@...onical.com>
To: Alasdair Kergon <agk@...hat.com>,
Mike Snitzer <snitzer@...hat.com>, dm-devel@...hat.com
Cc: kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH][next] dm space map disk: remove redundant initialization of variable index
From: Colin Ian King <colin.king@...onical.com>
The variable index is being initialized with a value that is never read,
it is being updated later on. The assignment is redundant and can be
removed.
Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@...onical.com>
---
drivers/md/persistent-data/dm-space-map-common.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/md/persistent-data/dm-space-map-common.c b/drivers/md/persistent-data/dm-space-map-common.c
index 7e30700c8830..ad7a1b9304c7 100644
--- a/drivers/md/persistent-data/dm-space-map-common.c
+++ b/drivers/md/persistent-data/dm-space-map-common.c
@@ -577,7 +577,7 @@ static int __sm_ll_inc_overflow(struct ll_disk *ll, dm_block_t b, struct inc_con
static int sm_ll_inc_overflow(struct ll_disk *ll, dm_block_t b, struct inc_context *ic)
{
- int index = -1;
+ int index;
struct btree_node *n;
__le32 *v_ptr;
uint32_t rc;
--
2.31.1
Powered by blists - more mailing lists