[PATCH 05/10] staging: rtl8723au: pnp_bstop_trx is never set

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Jes Sorensen <Jes.Sorensen@xxxxxxxxxx>

In addition remove unused pnp_current_pwr_state

Signed-off-by: Jes Sorensen <Jes.Sorensen@xxxxxxxxxx>
---
 drivers/staging/rtl8723au/hal/usb_ops_linux.c    | 11 ++++-------
 drivers/staging/rtl8723au/include/rtw_pwrctrl.h  |  2 --
 drivers/staging/rtl8723au/os_dep/usb_ops_linux.c |  8 +++-----
 3 files changed, 7 insertions(+), 14 deletions(-)

diff --git a/drivers/staging/rtl8723au/hal/usb_ops_linux.c b/drivers/staging/rtl8723au/hal/usb_ops_linux.c
index 23af718..780658c 100644
--- a/drivers/staging/rtl8723au/hal/usb_ops_linux.c
+++ b/drivers/staging/rtl8723au/hal/usb_ops_linux.c
@@ -34,10 +34,9 @@ static int usbctrl_vendorreq(struct rtw_adapter *padapter, u8 request,
 	u8 *pIo_buf;
 	int vendorreq_times = 0;
 
-	if (padapter->bSurpriseRemoved || padapter->pwrctrlpriv.pnp_bstop_trx) {
+	if (padapter->bSurpriseRemoved) {
 		RT_TRACE(_module_hci_ops_os_c_, _drv_err_,
-			 ("usbctrl_vendorreq:(padapter->bSurpriseRemoved||"
-			  "adapter->pwrctrlpriv.pnp_bstop_trx)!!!\n"));
+			 ("usbctrl_vendorreq:(padapter->bSurpriseRemoved)!!!"));
 		status = -EPERM;
 		goto exit;
 	}
@@ -743,12 +742,10 @@ int rtl8723au_read_port(struct rtw_adapter *adapter, u32 addr, u32 cnt,
 	struct recv_priv *precvpriv = &adapter->recvpriv;
 	struct usb_device *pusbd = pdvobj->pusbdev;
 
-	if (adapter->bDriverStopped || adapter->bSurpriseRemoved ||
-	    adapter->pwrctrlpriv.pnp_bstop_trx) {
+	if (adapter->bDriverStopped || adapter->bSurpriseRemoved) {
 		RT_TRACE(_module_hci_ops_os_c_, _drv_err_,
 			 ("usb_read_port:(padapter->bDriverStopped ||"
-			  "padapter->bSurpriseRemoved ||adapter->"
-			  "pwrctrlpriv.pnp_bstop_trx)!!!\n"));
+			  "padapter->bSurpriseRemoved)!!!\n"));
 		return _FAIL;
 	}
 
diff --git a/drivers/staging/rtl8723au/include/rtw_pwrctrl.h b/drivers/staging/rtl8723au/include/rtw_pwrctrl.h
index 2142255..45e13ce 100644
--- a/drivers/staging/rtl8723au/include/rtw_pwrctrl.h
+++ b/drivers/staging/rtl8723au/include/rtw_pwrctrl.h
@@ -184,8 +184,6 @@ struct pwrctrl_priv {
 	u8	bFwCurrentInPSMode;
 	unsigned long	DelayLPSLastTimeStamp;
 	u8	btcoex_rfon;
-	s32		pnp_current_pwr_state;
-	u8		pnp_bstop_trx;
 
 	u8		bInSuspend;
 #ifdef	CONFIG_8723AU_BT_COEXIST
diff --git a/drivers/staging/rtl8723au/os_dep/usb_ops_linux.c b/drivers/staging/rtl8723au/os_dep/usb_ops_linux.c
index 3352807..a3349ac 100644
--- a/drivers/staging/rtl8723au/os_dep/usb_ops_linux.c
+++ b/drivers/staging/rtl8723au/os_dep/usb_ops_linux.c
@@ -153,12 +153,10 @@ int rtl8723au_write_port(struct rtw_adapter *padapter, u32 addr, u32 cnt,
 
 	RT_TRACE(_module_hci_ops_os_c_, _drv_err_, ("+usb_write_port23a\n"));
 
-	if (padapter->bDriverStopped || padapter->bSurpriseRemoved ||
-	    padapter->pwrctrlpriv.pnp_bstop_trx) {
+	if (padapter->bDriverStopped || padapter->bSurpriseRemoved) {
 		RT_TRACE(_module_hci_ops_os_c_, _drv_err_,
-			 ("usb_write_port23a:( padapter->bDriverStopped || "
-			  "padapter->bSurpriseRemoved || "
-			  "adapter->pwrctrlpriv.pnp_bstop_trx)!!!\n"));
+			 ("%s:(padapter->bDriverStopped || "
+			  "padapter->bSurpriseRemoved)!!!\n", __func__));
 		rtw23a_sctx_done_err(&pxmitbuf->sctx, RTW_SCTX_DONE_TX_DENY);
 		goto exit;
 	}
-- 
1.9.3

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




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux