summaryrefslogtreecommitdiff
path: root/drivers/staging/r8188eu/core
diff options
context:
space:
mode:
authorMartin Kaiser <martin@kaiser.cx>2021-12-12 21:58:32 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-12-20 19:47:43 +0300
commitb66fbc855ee5ef29006f6d0148fff89c05bf47c7 (patch)
treed470c4ea22d6cbfe20085eaebdd48b059820a49e /drivers/staging/r8188eu/core
parent22f92b77479a1f869663cb6a09fb522e296ab242 (diff)
downloadlinux-b66fbc855ee5ef29006f6d0148fff89c05bf47c7.tar.xz
staging: r8188eu: move linked status check from hal to rtw_mlme_ext
Move rtl8188e_sreset_linked_status_check from the hal layer into rtw_mlme_ext.c. Like the xmit status check, this is a simple function that's only called from one place. With this function gone, hal/rtl8188e_sreset.c and include/rtl8188e_sreset.h are now empty and can be removed. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Link: https://lore.kernel.org/r/20211212185833.22000-3-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/r8188eu/core')
-rw-r--r--drivers/staging/r8188eu/core/rtw_cmd.c1
-rw-r--r--drivers/staging/r8188eu/core/rtw_mlme_ext.c19
2 files changed, 18 insertions, 2 deletions
diff --git a/drivers/staging/r8188eu/core/rtw_cmd.c b/drivers/staging/r8188eu/core/rtw_cmd.c
index 283ae08ae4cb..6d503eb7ff26 100644
--- a/drivers/staging/r8188eu/core/rtw_cmd.c
+++ b/drivers/staging/r8188eu/core/rtw_cmd.c
@@ -10,7 +10,6 @@
#include "../include/rtw_br_ext.h"
#include "../include/rtw_mlme_ext.h"
#include "../include/rtl8188e_dm.h"
-#include "../include/rtl8188e_sreset.h"
/*
Caller and the rtw_cmd_thread can protect cmd_q by spin_lock.
diff --git a/drivers/staging/r8188eu/core/rtw_mlme_ext.c b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
index 4b6d33249d95..15a443b9bc6d 100644
--- a/drivers/staging/r8188eu/core/rtw_mlme_ext.c
+++ b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
@@ -10,7 +10,6 @@
#include "../include/wlan_bssdef.h"
#include "../include/mlme_osdep.h"
#include "../include/recv_osdep.h"
-#include "../include/rtl8188e_sreset.h"
#include "../include/rtl8188e_xmit.h"
#include "../include/rtl8188e_dm.h"
@@ -7160,6 +7159,24 @@ static u8 chk_ap_is_alive(struct adapter *padapter, struct sta_info *psta)
return ret;
}
+static void rtl8188e_sreset_linked_status_check(struct adapter *padapter)
+{
+ u32 rx_dma_status = 0;
+ u8 fw_status = 0;
+ rx_dma_status = rtw_read32(padapter, REG_RXDMA_STATUS);
+ if (rx_dma_status != 0x00) {
+ DBG_88E("%s REG_RXDMA_STATUS:0x%08x\n", __func__, rx_dma_status);
+ rtw_write32(padapter, REG_RXDMA_STATUS, rx_dma_status);
+ }
+ fw_status = rtw_read8(padapter, REG_FMETHR);
+ if (fw_status != 0x00) {
+ if (fw_status == 1)
+ DBG_88E("%s REG_FW_STATUS (0x%02x), Read_Efuse_Fail !!\n", __func__, fw_status);
+ else if (fw_status == 2)
+ DBG_88E("%s REG_FW_STATUS (0x%02x), Condition_No_Match !!\n", __func__, fw_status);
+ }
+}
+
void linked_status_chk(struct adapter *padapter)
{
u32 i;