All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Staging: rtl8723au: Remove unnecessary variable
@ 2016-02-09 19:09 Bhumika Goyal
  2016-02-09 21:56 ` [Outreachy kernel] " Julia Lawall
  0 siblings, 1 reply; 4+ messages in thread
From: Bhumika Goyal @ 2016-02-09 19:09 UTC (permalink / raw)
  To: outreachy-kernel; +Cc: Bhumika Goyal

Variable ret is initially made 0 and it's value remains unchanged in
function. It is used only as return value.So remove ret and replace
return ret with return 0.

Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
---
 drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c
index 0ae2180..b10fdce 100644
--- a/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c
+++ b/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c
@@ -242,7 +242,6 @@ rtw_cfg80211_default_mgmt_stypes[NUM_NL80211_IFTYPES] = {
 static int rtw_cfg80211_inform_bss(struct rtw_adapter *padapter,
 				   struct wlan_network *pnetwork)
 {
-	int ret = 0;
 	struct ieee80211_channel *notify_channel;
 	struct cfg80211_bss *bss;
 	u16 channel;
@@ -295,7 +294,7 @@ static int rtw_cfg80211_inform_bss(struct rtw_adapter *padapter,
 
 	cfg80211_put_bss(wiphy, bss);
 
-	return ret;
+	return 0;
 }
 
 void rtw_cfg80211_indicate_connect(struct rtw_adapter *padapter)
@@ -1300,7 +1299,6 @@ void rtw_cfg80211_surveydone_event_callback(struct rtw_adapter *padapter)
 static int rtw_cfg80211_set_probe_req_wpsp2pie(struct rtw_adapter *padapter,
 					       char *buf, int len)
 {
-	int ret = 0;
 	const u8 *wps_ie;
 	struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
 
@@ -1330,7 +1328,7 @@ static int rtw_cfg80211_set_probe_req_wpsp2pie(struct rtw_adapter *padapter,
 		}
 	}
 
-	return ret;
+	return 0;
 }
 
 static int cfg80211_rtw_scan(struct wiphy *wiphy,
-- 
1.9.1



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

end of thread, other threads:[~2016-02-10  9:19 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-09 19:09 [PATCH] Staging: rtl8723au: Remove unnecessary variable Bhumika Goyal
2016-02-09 21:56 ` [Outreachy kernel] " Julia Lawall
2016-02-10  9:18   ` Bhumika Goyal
2016-02-10  9:19     ` Julia Lawall

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.