public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dm: remove unneeded variable
@ 2021-11-11  7:53 cgel.zte
  2021-11-11 16:50 ` kernel test robot
  2021-11-12 15:09 ` Mike Snitzer
  0 siblings, 2 replies; 3+ messages in thread
From: cgel.zte @ 2021-11-11  7:53 UTC (permalink / raw)
  To: agk; +Cc: snitzer, dm-devel, linux-kernel, ran jianping, Zeal Robot

From: ran jianping <ran.jianping@zte.com.cn>

Fix the following coccicheck review:
./drivers/md/dm-ps-round-robin.c:91:5-7:Unneeded variable

Remove unneeded variable used to store return value.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: ran jianping <ran.jianping@zte.com.cn>
---
 drivers/md/dm-ps-round-robin.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/md/dm-ps-round-robin.c b/drivers/md/dm-ps-round-robin.c
index 27f44c5fa04e..455fc02af1cf 100644
--- a/drivers/md/dm-ps-round-robin.c
+++ b/drivers/md/dm-ps-round-robin.c
@@ -88,7 +88,6 @@ static int rr_status(struct path_selector *ps, struct dm_path *path,
 		     status_type_t type, char *result, unsigned int maxlen)
 {
 	struct path_info *pi;
-	int sz = 0;
 
 	if (!path)
 		DMEMIT("0 ");
@@ -107,7 +106,7 @@ static int rr_status(struct path_selector *ps, struct dm_path *path,
 		}
 	}
 
-	return sz;
+	return 0;
 }
 
 /*
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-11-12 15:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-11-11  7:53 [PATCH] dm: remove unneeded variable cgel.zte
2021-11-11 16:50 ` kernel test robot
2021-11-12 15:09 ` Mike Snitzer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox