Commit 63a7cabb authored by Jes Sorensen's avatar Jes Sorensen Committed by Greg Kroah-Hartman

staging: rtl8723au: Wifi_Error_Status isn't used for anything

Signed-off-by: default avatarJes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5a907658
...@@ -23,7 +23,6 @@ void rtw_sreset_init(struct rtw_adapter *padapter) ...@@ -23,7 +23,6 @@ void rtw_sreset_init(struct rtw_adapter *padapter)
mutex_init(&psrtpriv->silentreset_mutex); mutex_init(&psrtpriv->silentreset_mutex);
psrtpriv->silent_reset_inprogress = false; psrtpriv->silent_reset_inprogress = false;
psrtpriv->Wifi_Error_Status = WIFI_STATUS_SUCCESS;
psrtpriv->last_tx_time = 0; psrtpriv->last_tx_time = 0;
psrtpriv->last_tx_complete_time = 0; psrtpriv->last_tx_complete_time = 0;
} }
...@@ -34,18 +33,10 @@ void rtw_sreset_reset_value(struct rtw_adapter *padapter) ...@@ -34,18 +33,10 @@ void rtw_sreset_reset_value(struct rtw_adapter *padapter)
struct sreset_priv *psrtpriv = &pHalData->srestpriv; struct sreset_priv *psrtpriv = &pHalData->srestpriv;
psrtpriv->silent_reset_inprogress = false; psrtpriv->silent_reset_inprogress = false;
psrtpriv->Wifi_Error_Status = WIFI_STATUS_SUCCESS;
psrtpriv->last_tx_time = 0; psrtpriv->last_tx_time = 0;
psrtpriv->last_tx_complete_time = 0; psrtpriv->last_tx_complete_time = 0;
} }
void sreset_set_wifi_error_status23a(struct rtw_adapter *padapter, u32 status)
{
struct hal_data_8723a *pHalData = GET_HAL_DATA(padapter);
pHalData->srestpriv.Wifi_Error_Status = status;
}
void sreset_set_trigger_point(struct rtw_adapter *padapter, s32 tgp) void sreset_set_trigger_point(struct rtw_adapter *padapter, s32 tgp)
{ {
struct hal_data_8723a *pHalData = GET_HAL_DATA(padapter); struct hal_data_8723a *pHalData = GET_HAL_DATA(padapter);
...@@ -213,8 +204,6 @@ void rtw_sreset_reset(struct rtw_adapter *active_adapter) ...@@ -213,8 +204,6 @@ void rtw_sreset_reset(struct rtw_adapter *active_adapter)
DBG_8723A("%s\n", __func__); DBG_8723A("%s\n", __func__);
psrtpriv->Wifi_Error_Status = WIFI_STATUS_SUCCESS;
mutex_lock(&psrtpriv->silentreset_mutex); mutex_lock(&psrtpriv->silentreset_mutex);
psrtpriv->silent_reset_inprogress = true; psrtpriv->silent_reset_inprogress = true;
pwrpriv->change_rfpwrstate = rf_off; pwrpriv->change_rfpwrstate = rf_off;
......
...@@ -46,7 +46,6 @@ void rtl8723a_sreset_xmit_status_check(struct rtw_adapter *padapter) ...@@ -46,7 +46,6 @@ void rtl8723a_sreset_xmit_status_check(struct rtw_adapter *padapter)
} else { } else {
diff_time = jiffies_to_msecs(jiffies - psrtpriv->last_tx_complete_time); diff_time = jiffies_to_msecs(jiffies - psrtpriv->last_tx_complete_time);
if (diff_time > 4000) { if (diff_time > 4000) {
/* padapter->Wifi_Error_Status = WIFI_TX_HANG; */
DBG_8723A("%s tx hang\n", __func__); DBG_8723A("%s tx hang\n", __func__);
rtw_sreset_reset(padapter); rtw_sreset_reset(padapter);
} }
......
...@@ -94,13 +94,6 @@ static int usbctrl_vendorreq(struct rtw_adapter *padapter, u8 request, ...@@ -94,13 +94,6 @@ static int usbctrl_vendorreq(struct rtw_adapter *padapter, u8 request,
if (status < 0) { if (status < 0) {
if (status == -ESHUTDOWN || status == -ENODEV) if (status == -ESHUTDOWN || status == -ENODEV)
padapter->bSurpriseRemoved = true; padapter->bSurpriseRemoved = true;
else {
struct hal_data_8723a *pHalData;
pHalData = GET_HAL_DATA(padapter);
pHalData->srestpriv.Wifi_Error_Status =
USB_VEN_REQ_CMD_FAIL;
}
} else { /* status != len && status >= 0 */ } else { /* status != len && status >= 0 */
if (status > 0) { if (status > 0) {
if (requesttype == 0x01) { if (requesttype == 0x01) {
...@@ -647,7 +640,6 @@ static void usb_read_port_complete(struct urb *purb) ...@@ -647,7 +640,6 @@ static void usb_read_port_complete(struct urb *purb)
struct recv_buf *precvbuf = (struct recv_buf *)purb->context; struct recv_buf *precvbuf = (struct recv_buf *)purb->context;
struct rtw_adapter *padapter = (struct rtw_adapter *)precvbuf->adapter; struct rtw_adapter *padapter = (struct rtw_adapter *)precvbuf->adapter;
struct recv_priv *precvpriv = &padapter->recvpriv; struct recv_priv *precvpriv = &padapter->recvpriv;
struct hal_data_8723a *pHalData;
RT_TRACE(_module_hci_ops_os_c_, _drv_err_, RT_TRACE(_module_hci_ops_os_c_, _drv_err_,
("usb_read_port_complete!!!\n")); ("usb_read_port_complete!!!\n"));
...@@ -726,9 +718,6 @@ static void usb_read_port_complete(struct urb *purb) ...@@ -726,9 +718,6 @@ static void usb_read_port_complete(struct urb *purb)
break; break;
case -EPROTO: case -EPROTO:
case -EOVERFLOW: case -EOVERFLOW:
pHalData = GET_HAL_DATA(padapter);
pHalData->srestpriv.Wifi_Error_Status =
USB_READ_PORT_FAIL;
rtl8723au_read_port(padapter, RECV_BULK_IN_ADDR, 0, rtl8723au_read_port(padapter, RECV_BULK_IN_ADDR, 0,
precvbuf); precvbuf);
break; break;
......
...@@ -27,7 +27,6 @@ enum { ...@@ -27,7 +27,6 @@ enum {
struct sreset_priv { struct sreset_priv {
struct mutex silentreset_mutex; struct mutex silentreset_mutex;
u8 silent_reset_inprogress; u8 silent_reset_inprogress;
u8 Wifi_Error_Status;
unsigned long last_tx_time; unsigned long last_tx_time;
unsigned long last_tx_complete_time; unsigned long last_tx_complete_time;
...@@ -36,19 +35,9 @@ struct sreset_priv { ...@@ -36,19 +35,9 @@ struct sreset_priv {
#include <rtl8723a_hal.h> #include <rtl8723a_hal.h>
#define WIFI_STATUS_SUCCESS 0
#define USB_VEN_REQ_CMD_FAIL BIT(0)
#define USB_READ_PORT_FAIL BIT(1)
#define USB_WRITE_PORT_FAIL BIT(2)
#define WIFI_MAC_TXDMA_ERROR BIT(3)
#define WIFI_TX_HANG BIT(4)
#define WIFI_RX_HANG BIT(5)
#define WIFI_IF_NOT_EXIST BIT(6)
void rtw_sreset_init(struct rtw_adapter *padapter); void rtw_sreset_init(struct rtw_adapter *padapter);
void rtw_sreset_reset_value(struct rtw_adapter *padapter); void rtw_sreset_reset_value(struct rtw_adapter *padapter);
bool rtw_sreset_inprogress(struct rtw_adapter *padapter); bool rtw_sreset_inprogress(struct rtw_adapter *padapter);
void sreset_set_wifi_error_status23a(struct rtw_adapter *padapter, u32 status);
void sreset_set_trigger_point(struct rtw_adapter *padapter, s32 tgp); void sreset_set_trigger_point(struct rtw_adapter *padapter, s32 tgp);
void rtw_sreset_reset(struct rtw_adapter *active_adapter); void rtw_sreset_reset(struct rtw_adapter *active_adapter);
......
...@@ -96,8 +96,6 @@ static void usb_write_port23a_complete(struct urb *purb) ...@@ -96,8 +96,6 @@ static void usb_write_port23a_complete(struct urb *purb)
DBG_8723A("###=> urb_write_port_complete status(%d)\n", DBG_8723A("###=> urb_write_port_complete status(%d)\n",
purb->status); purb->status);
if (purb->status == -EPIPE || purb->status == -EPROTO) { if (purb->status == -EPIPE || purb->status == -EPROTO) {
sreset_set_wifi_error_status23a(padapter,
USB_WRITE_PORT_FAIL);
} else if (purb->status == -EINPROGRESS) { } else if (purb->status == -EINPROGRESS) {
RT_TRACE(_module_hci_ops_os_c_, _drv_err_, RT_TRACE(_module_hci_ops_os_c_, _drv_err_,
("usb_write_port23a_complete: EINPROGESS\n")); ("usb_write_port23a_complete: EINPROGESS\n"));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment