linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] orinoco: remove useless variable 'err' in spectrum_cs_suspend()
@ 2020-04-13  8:20 Jason Yan
  2020-04-15  8:47 ` Kalle Valo
  0 siblings, 1 reply; 2+ messages in thread
From: Jason Yan @ 2020-04-13  8:20 UTC (permalink / raw)
  To: kvalo, davem, yanaijie, linux-wireless, netdev, linux-kernel; +Cc: Hulk Robot

Fix the following coccicheck warning:

drivers/net/wireless/intersil/orinoco/spectrum_cs.c:281:5-8: Unneeded
variable: "err". Return "0" on line 286

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
 drivers/net/wireless/intersil/orinoco/spectrum_cs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/net/wireless/intersil/orinoco/spectrum_cs.c b/drivers/net/wireless/intersil/orinoco/spectrum_cs.c
index b60048c95e0a..291ef97ed45e 100644
--- a/drivers/net/wireless/intersil/orinoco/spectrum_cs.c
+++ b/drivers/net/wireless/intersil/orinoco/spectrum_cs.c
@@ -278,12 +278,11 @@ static int
 spectrum_cs_suspend(struct pcmcia_device *link)
 {
 	struct orinoco_private *priv = link->priv;
-	int err = 0;
 
 	/* Mark the device as stopped, to block IO until later */
 	orinoco_down(priv);
 
-	return err;
+	return 0;
 }
 
 static int
-- 
2.21.1


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

* Re: [PATCH] orinoco: remove useless variable 'err' in spectrum_cs_suspend()
  2020-04-13  8:20 [PATCH] orinoco: remove useless variable 'err' in spectrum_cs_suspend() Jason Yan
@ 2020-04-15  8:47 ` Kalle Valo
  0 siblings, 0 replies; 2+ messages in thread
From: Kalle Valo @ 2020-04-15  8:47 UTC (permalink / raw)
  To: Jason Yan
  Cc: davem, yanaijie, linux-wireless, netdev, linux-kernel, Hulk Robot

Jason Yan <yanaijie@huawei.com> wrote:

> Fix the following coccicheck warning:
> 
> drivers/net/wireless/intersil/orinoco/spectrum_cs.c:281:5-8: Unneeded
> variable: "err". Return "0" on line 286
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Jason Yan <yanaijie@huawei.com>

Patch applied to wireless-drivers-next.git, thanks.

7b9ae69d5441 orinoco: remove useless variable 'err' in spectrum_cs_suspend()

-- 
https://patchwork.kernel.org/patch/11485247/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches

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

end of thread, other threads:[~2020-04-15  8:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-13  8:20 [PATCH] orinoco: remove useless variable 'err' in spectrum_cs_suspend() Jason Yan
2020-04-15  8:47 ` Kalle Valo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).