orinoco: remove useless variable 'err' in spectrum_cs_suspend()
authorJason Yan <yanaijie@huawei.com>
Mon, 13 Apr 2020 08:20:43 +0000 (16:20 +0800)
committerKalle Valo <kvalo@codeaurora.org>
Wed, 15 Apr 2020 08:46:49 +0000 (11:46 +0300)
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>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20200413082043.22468-1-yanaijie@huawei.com
drivers/net/wireless/intersil/orinoco/spectrum_cs.c

index b60048c..291ef97 100644 (file)
@@ -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