All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/4] staging: rtl8188eu: os_dep: Remove return variable
@ 2019-06-26  6:50 Nishka Dasgupta
  2019-06-26  6:50 ` [PATCH 2/4] staging: rtl8188eu: hal: Replace function odm_TXPowerTrackingInit() Nishka Dasgupta
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Nishka Dasgupta @ 2019-06-26  6:50 UTC (permalink / raw)
  To: gregkh, devel, larry.finger; +Cc: Nishka Dasgupta

Remove return variable as its value is not altered between
initialisation and return.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
---
 drivers/staging/rtl8188eu/os_dep/ioctl_linux.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/rtl8188eu/os_dep/ioctl_linux.c b/drivers/staging/rtl8188eu/os_dep/ioctl_linux.c
index eaa4adb32a0d..f47e51a6a5ec 100644
--- a/drivers/staging/rtl8188eu/os_dep/ioctl_linux.c
+++ b/drivers/staging/rtl8188eu/os_dep/ioctl_linux.c
@@ -1686,7 +1686,7 @@ static int rtw_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 = (struct adapter *)rtw_netdev_priv(dev);
 	struct iw_point *erq = &(wrqu->encoding);
 	struct	mlme_priv	*pmlmepriv = &(padapter->mlmepriv);
@@ -1744,7 +1744,7 @@ static int rtw_wx_get_enc(struct net_device *dev,
 		break;
 	}
 
-	return ret;
+	return 0;
 }
 
 static int rtw_wx_get_power(struct net_device *dev,
-- 
2.19.1

_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

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

* [PATCH 2/4] staging: rtl8188eu: hal: Replace function odm_TXPowerTrackingInit()
  2019-06-26  6:50 [PATCH 1/4] staging: rtl8188eu: os_dep: Remove return variable Nishka Dasgupta
@ 2019-06-26  6:50 ` Nishka Dasgupta
  2019-06-26  6:50 ` [PATCH 3/4] staging: rtl8188eu: hal: Replace function ODM_TXPowerTrackingCheck() Nishka Dasgupta
  2019-06-26  6:50 ` [PATCH 4/4] staging: rtl8188eu: Remove declarations of unused functions Nishka Dasgupta
  2 siblings, 0 replies; 4+ messages in thread
From: Nishka Dasgupta @ 2019-06-26  6:50 UTC (permalink / raw)
  To: gregkh, devel, larry.finger; +Cc: Nishka Dasgupta

Remove function odm_TXPowerTrackingInit as all it does is call
odm_TXPowerTrackingThermalMeterInit.
Rename odm_TXPowerTrackingThermalMeterInit to odm_TXPowerTrackingInit
for compatibility with call sites.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
---
 drivers/staging/rtl8188eu/hal/odm.c             | 5 -----
 drivers/staging/rtl8188eu/include/odm_precomp.h | 1 -
 2 files changed, 6 deletions(-)

diff --git a/drivers/staging/rtl8188eu/hal/odm.c b/drivers/staging/rtl8188eu/hal/odm.c
index 74f7c9c81bf6..3fb2cc24436e 100644
--- a/drivers/staging/rtl8188eu/hal/odm.c
+++ b/drivers/staging/rtl8188eu/hal/odm.c
@@ -942,11 +942,6 @@ void odm_RSSIMonitorCheckCE(struct odm_dm_struct *pDM_Odm)
 /* 3============================================================ */
 
 void odm_TXPowerTrackingInit(struct odm_dm_struct *pDM_Odm)
-{
-	odm_TXPowerTrackingThermalMeterInit(pDM_Odm);
-}
-
-void odm_TXPowerTrackingThermalMeterInit(struct odm_dm_struct *pDM_Odm)
 {
 	pDM_Odm->RFCalibrateInfo.bTXPowerTracking = true;
 	pDM_Odm->RFCalibrateInfo.TXPowercount = 0;
diff --git a/drivers/staging/rtl8188eu/include/odm_precomp.h b/drivers/staging/rtl8188eu/include/odm_precomp.h
index df096c37f5eb..b4b7bce80694 100644
--- a/drivers/staging/rtl8188eu/include/odm_precomp.h
+++ b/drivers/staging/rtl8188eu/include/odm_precomp.h
@@ -59,7 +59,6 @@ void odm_RefreshRateAdaptiveMaskCE(struct odm_dm_struct *pDM_Odm);
 void odm_RefreshRateAdaptiveMaskAPADSL(struct odm_dm_struct *pDM_Odm);
 void odm_DynamicTxPowerNIC(struct odm_dm_struct *pDM_Odm);
 void odm_RSSIMonitorCheckCE(struct odm_dm_struct *pDM_Odm);
-void odm_TXPowerTrackingThermalMeterInit(struct odm_dm_struct *pDM_Odm);
 void odm_EdcaTurboCheckCE(struct odm_dm_struct *pDM_Odm);
 void odm_TXPowerTrackingCheckCE(struct odm_dm_struct *pDM_Odm);
 void odm_SwAntDivChkAntSwitchCallback(void *FunctionContext);
-- 
2.19.1

_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

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

* [PATCH 3/4] staging: rtl8188eu: hal: Replace function ODM_TXPowerTrackingCheck()
  2019-06-26  6:50 [PATCH 1/4] staging: rtl8188eu: os_dep: Remove return variable Nishka Dasgupta
  2019-06-26  6:50 ` [PATCH 2/4] staging: rtl8188eu: hal: Replace function odm_TXPowerTrackingInit() Nishka Dasgupta
@ 2019-06-26  6:50 ` Nishka Dasgupta
  2019-06-26  6:50 ` [PATCH 4/4] staging: rtl8188eu: Remove declarations of unused functions Nishka Dasgupta
  2 siblings, 0 replies; 4+ messages in thread
From: Nishka Dasgupta @ 2019-06-26  6:50 UTC (permalink / raw)
  To: gregkh, devel, larry.finger; +Cc: Nishka Dasgupta

Remove function ODM_TXPowerTrackingCheck as all it does is call
odm_TXPowerTrackingCheckCE.
Rename odm_TXPowerTrackingCheckCE to ODM_TXPowerTrackingCheck for
compatibility with call sites.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
---
 drivers/staging/rtl8188eu/hal/odm.c             | 5 -----
 drivers/staging/rtl8188eu/include/odm_precomp.h | 1 -
 2 files changed, 6 deletions(-)

diff --git a/drivers/staging/rtl8188eu/hal/odm.c b/drivers/staging/rtl8188eu/hal/odm.c
index 3fb2cc24436e..4e2f6cb55a75 100644
--- a/drivers/staging/rtl8188eu/hal/odm.c
+++ b/drivers/staging/rtl8188eu/hal/odm.c
@@ -957,11 +957,6 @@ void ODM_TXPowerTrackingCheck(struct odm_dm_struct *pDM_Odm)
 	/*  2011/09/29 MH In HW integration first stage, we provide 4 different handle to operate */
 	/*  at the same time. In the stage2/3, we need to prive universal interface and merge all */
 	/*  HW dynamic mechanism. */
-	odm_TXPowerTrackingCheckCE(pDM_Odm);
-}
-
-void odm_TXPowerTrackingCheckCE(struct odm_dm_struct *pDM_Odm)
-{
 	struct adapter *Adapter = pDM_Odm->Adapter;
 
 	if (!(pDM_Odm->SupportAbility & ODM_RF_TX_PWR_TRACK))
diff --git a/drivers/staging/rtl8188eu/include/odm_precomp.h b/drivers/staging/rtl8188eu/include/odm_precomp.h
index b4b7bce80694..5254d875f96b 100644
--- a/drivers/staging/rtl8188eu/include/odm_precomp.h
+++ b/drivers/staging/rtl8188eu/include/odm_precomp.h
@@ -60,7 +60,6 @@ void odm_RefreshRateAdaptiveMaskAPADSL(struct odm_dm_struct *pDM_Odm);
 void odm_DynamicTxPowerNIC(struct odm_dm_struct *pDM_Odm);
 void odm_RSSIMonitorCheckCE(struct odm_dm_struct *pDM_Odm);
 void odm_EdcaTurboCheckCE(struct odm_dm_struct *pDM_Odm);
-void odm_TXPowerTrackingCheckCE(struct odm_dm_struct *pDM_Odm);
 void odm_SwAntDivChkAntSwitchCallback(void *FunctionContext);
 void odm_InitHybridAntDiv(struct odm_dm_struct *pDM_Odm);
 void odm_HwAntDiv(struct odm_dm_struct *pDM_Odm);
-- 
2.19.1

_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

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

* [PATCH 4/4] staging: rtl8188eu: Remove declarations of unused functions
  2019-06-26  6:50 [PATCH 1/4] staging: rtl8188eu: os_dep: Remove return variable Nishka Dasgupta
  2019-06-26  6:50 ` [PATCH 2/4] staging: rtl8188eu: hal: Replace function odm_TXPowerTrackingInit() Nishka Dasgupta
  2019-06-26  6:50 ` [PATCH 3/4] staging: rtl8188eu: hal: Replace function ODM_TXPowerTrackingCheck() Nishka Dasgupta
@ 2019-06-26  6:50 ` Nishka Dasgupta
  2 siblings, 0 replies; 4+ messages in thread
From: Nishka Dasgupta @ 2019-06-26  6:50 UTC (permalink / raw)
  To: gregkh, devel, larry.finger; +Cc: Nishka Dasgupta

Remove the declarations of the following unused functions from
rtw_eeprom.h:
- eeprom_write16
- eeprom_read16
- eeprom_read_sz
- read_eeprom_content
- read_eeprom_content_by_attrib.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
---
 drivers/staging/rtl8188eu/include/rtw_eeprom.h | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/staging/rtl8188eu/include/rtw_eeprom.h b/drivers/staging/rtl8188eu/include/rtw_eeprom.h
index db25eb580c98..10525493129b 100644
--- a/drivers/staging/rtl8188eu/include/rtw_eeprom.h
+++ b/drivers/staging/rtl8188eu/include/rtw_eeprom.h
@@ -111,10 +111,4 @@ struct eeprom_priv {
 	u8		efuse_eeprom_data[HWSET_MAX_SIZE_512];
 };
 
-void eeprom_write16(struct adapter *padapter, u16 reg, u16 data);
-u16 eeprom_read16(struct adapter *padapter, u16 reg);
-void read_eeprom_content(struct adapter *padapter);
-void eeprom_read_sz(struct adapter *adapt, u16 reg, u8 *data, u32 sz);
-void read_eeprom_content_by_attrib(struct adapter *padapter);
-
 #endif  /* __RTL871X_EEPROM_H__ */
-- 
2.19.1

_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

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

end of thread, other threads:[~2019-06-26  6:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-26  6:50 [PATCH 1/4] staging: rtl8188eu: os_dep: Remove return variable Nishka Dasgupta
2019-06-26  6:50 ` [PATCH 2/4] staging: rtl8188eu: hal: Replace function odm_TXPowerTrackingInit() Nishka Dasgupta
2019-06-26  6:50 ` [PATCH 3/4] staging: rtl8188eu: hal: Replace function ODM_TXPowerTrackingCheck() Nishka Dasgupta
2019-06-26  6:50 ` [PATCH 4/4] staging: rtl8188eu: Remove declarations of unused functions Nishka Dasgupta

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.