lkml.org 
[lkml]   [2022]   [Jan]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v4 03/23] staging: r8188eu: remove unneeded variable in rtw_p2p_get
Date
Remove unneeded return variable that is initialized to 0 and not
assigned after.

Found using Coccinelle
Signed-off-by: Abdun Nihaal <abdun.nihaal@gmail.com>
---
drivers/staging/r8188eu/os_dep/ioctl_linux.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/staging/r8188eu/os_dep/ioctl_linux.c b/drivers/staging/r8188eu/os_dep/ioctl_linux.c
index f99942417a71..bc5c8454ebcf 100644
--- a/drivers/staging/r8188eu/os_dep/ioctl_linux.c
+++ b/drivers/staging/r8188eu/os_dep/ioctl_linux.c
@@ -3422,8 +3422,6 @@ static int rtw_p2p_get(struct net_device *dev,
struct iw_request_info *info,
union iwreq_data *wrqu, char *extra)
{
- int ret = 0;
-
struct adapter *padapter = (struct adapter *)rtw_netdev_priv(dev);

if (padapter->bShowGetP2PState)
@@ -3447,7 +3445,7 @@ static int rtw_p2p_get(struct net_device *dev,
} else if (!memcmp(wrqu->data.pointer, "op_ch", 5)) {
rtw_p2p_get_op_ch(dev, info, wrqu, extra);
}
- return ret;
+ return 0;
}

static int rtw_p2p_get2(struct net_device *dev,
--
2.34.1
\
 
 \ /
  Last update: 2022-01-29 17:32    [W:0.226 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site