summaryrefslogtreecommitdiff
path: root/drivers/staging
diff options
context:
space:
mode:
authorNishka Dasgupta <nishkadg.linux@gmail.com>2019-05-29 16:24:57 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-05-31 00:13:45 +0300
commitdb622e05cdbe11ff908268c8eb4bffb972daedb7 (patch)
tree47c3373e5d0669d15800c7513b3eedfeaa0b7dc0 /drivers/staging
parenteb2b3edfd427d11e9553aaf772b40fb18e42fbba (diff)
downloadlinux-db622e05cdbe11ff908268c8eb4bffb972daedb7.tar.xz
staging: rtl8712: Remove return variable of different type
The local return variable ret may be replaced directly by its value, especially since its type (uint) is not the same as the function's return type (int). Issue found with Coccinelle. Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/rtl8712/rtl871x_ioctl_linux.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/rtl8712/rtl871x_ioctl_linux.c b/drivers/staging/rtl8712/rtl871x_ioctl_linux.c
index a7230c0c7b23..b424b8436fcf 100644
--- a/drivers/staging/rtl8712/rtl871x_ioctl_linux.c
+++ b/drivers/staging/rtl8712/rtl871x_ioctl_linux.c
@@ -1577,7 +1577,7 @@ static int r8711_wx_get_enc(struct net_device *dev,
struct iw_request_info *info,
union iwreq_data *wrqu, char *keybuf)
{
- uint key, ret = 0;
+ uint key;
struct _adapter *padapter = netdev_priv(dev);
struct iw_point *erq = &(wrqu->encoding);
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
@@ -1633,7 +1633,7 @@ static int r8711_wx_get_enc(struct net_device *dev,
erq->flags |= IW_ENCODE_DISABLED;
break;
}
- return ret;
+ return 0;
}
static int r8711_wx_get_power(struct net_device *dev,