mirror of
https://github.com/lwfinger/rtl8188eu.git
synced 2024-11-10 07:29:40 +00:00
rtl8188eu: Remove conditionals related to chip type
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
parent
da6721497d
commit
76e49eeec2
14 changed files with 70 additions and 987 deletions
21
Makefile
21
Makefile
|
@ -24,7 +24,6 @@ CONFIG_USB_AUTOSUSPEND = n
|
||||||
CONFIG_HW_PWRP_DETECTION = n
|
CONFIG_HW_PWRP_DETECTION = n
|
||||||
CONFIG_WIFI_TEST = n
|
CONFIG_WIFI_TEST = n
|
||||||
CONFIG_BT_COEXIST = n
|
CONFIG_BT_COEXIST = n
|
||||||
CONFIG_RTL8192CU_REDEFINE_1X1 = n
|
|
||||||
CONFIG_INTEL_WIDI = n
|
CONFIG_INTEL_WIDI = n
|
||||||
CONFIG_WAPI_SUPPORT = n
|
CONFIG_WAPI_SUPPORT = n
|
||||||
CONFIG_EFUSE_CONFIG_FILE = n
|
CONFIG_EFUSE_CONFIG_FILE = n
|
||||||
|
@ -45,7 +44,6 @@ OUTSRC_FILES := hal/odm_debug.o \
|
||||||
hal/odm.o\
|
hal/odm.o\
|
||||||
hal/HalPhyRf.o
|
hal/HalPhyRf.o
|
||||||
|
|
||||||
ifeq ($(CONFIG_RTL8188E), y)
|
|
||||||
|
|
||||||
RTL871X = rtl8188e
|
RTL871X = rtl8188e
|
||||||
HAL_COMM_FILES := hal/rtl8188e_xmit.o\
|
HAL_COMM_FILES := hal/rtl8188e_xmit.o\
|
||||||
|
@ -62,19 +60,15 @@ OUTSRC_FILES += hal/HalHWImg8188E_MAC.o\
|
||||||
hal/Hal8188ERateAdaptive.o\
|
hal/Hal8188ERateAdaptive.o\
|
||||||
hal/odm_RTL8188E.o
|
hal/odm_RTL8188E.o
|
||||||
|
|
||||||
ifeq ($(CONFIG_RTL8188E), y)
|
|
||||||
ifeq ($(CONFIG_WOWLAN), y)
|
ifeq ($(CONFIG_WOWLAN), y)
|
||||||
OUTSRC_FILES += hal/HalHWImg8188E_FW.o
|
OUTSRC_FILES += hal/HalHWImg8188E_FW.o
|
||||||
endif
|
endif
|
||||||
endif
|
|
||||||
|
|
||||||
PWRSEQ_FILES := hal/HalPwrSeqCmd.o \
|
PWRSEQ_FILES := hal/HalPwrSeqCmd.o \
|
||||||
hal/Hal8188EPwrSeq.o
|
hal/Hal8188EPwrSeq.o
|
||||||
|
|
||||||
CHIP_FILES += $(HAL_COMM_FILES) $(OUTSRC_FILES) $(PWRSEQ_FILES)
|
CHIP_FILES += $(HAL_COMM_FILES) $(OUTSRC_FILES) $(PWRSEQ_FILES)
|
||||||
|
|
||||||
endif
|
|
||||||
|
|
||||||
HCI_NAME = usb
|
HCI_NAME = usb
|
||||||
|
|
||||||
_OS_INTFS_FILES := os_dep/osdep_service.o \
|
_OS_INTFS_FILES := os_dep/osdep_service.o \
|
||||||
|
@ -141,10 +135,6 @@ ifeq ($(CONFIG_BT_COEXIST), y)
|
||||||
EXTRA_CFLAGS += -DCONFIG_BT_COEXIST
|
EXTRA_CFLAGS += -DCONFIG_BT_COEXIST
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_RTL8192CU_REDEFINE_1X1), y)
|
|
||||||
EXTRA_CFLAGS += -DRTL8192C_RECONFIG_TO_1T1R
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_INTEL_WIDI), y)
|
ifeq ($(CONFIG_INTEL_WIDI), y)
|
||||||
EXTRA_CFLAGS += -DCONFIG_INTEL_WIDI
|
EXTRA_CFLAGS += -DCONFIG_INTEL_WIDI
|
||||||
endif
|
endif
|
||||||
|
@ -165,17 +155,13 @@ ifeq ($(CONFIG_FTP_PROTECT), y)
|
||||||
EXTRA_CFLAGS += -DCONFIG_FTP_PROTECT
|
EXTRA_CFLAGS += -DCONFIG_FTP_PROTECT
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_RTL8188E), y)
|
|
||||||
ifeq ($(CONFIG_WOWLAN), y)
|
ifeq ($(CONFIG_WOWLAN), y)
|
||||||
EXTRA_CFLAGS += -DCONFIG_WOWLAN
|
EXTRA_CFLAGS += -DCONFIG_WOWLAN
|
||||||
endif
|
endif
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_RTL8188E), y)
|
|
||||||
ifeq ($(CONFIG_EFUSE_CONFIG_FILE), y)
|
ifeq ($(CONFIG_EFUSE_CONFIG_FILE), y)
|
||||||
EXTRA_CFLAGS += -DCONFIG_RF_GAIN_OFFSET
|
EXTRA_CFLAGS += -DCONFIG_RF_GAIN_OFFSET
|
||||||
endif
|
endif
|
||||||
endif
|
|
||||||
|
|
||||||
SUBARCH := $(shell uname -m | sed -e s/i.86/i386/ | sed -e s/ppc/powerpc/)
|
SUBARCH := $(shell uname -m | sed -e s/i.86/i386/ | sed -e s/ppc/powerpc/)
|
||||||
|
|
||||||
|
@ -455,12 +441,7 @@ $(MODULE_NAME)-y += $(_OS_INTFS_FILES)
|
||||||
|
|
||||||
$(MODULE_NAME)-$(CONFIG_MP_INCLUDED) += core/rtw_mp.o \
|
$(MODULE_NAME)-$(CONFIG_MP_INCLUDED) += core/rtw_mp.o \
|
||||||
core/rtw_mp_ioctl.o
|
core/rtw_mp_ioctl.o
|
||||||
ifeq ($(CONFIG_RTL8723A), y)
|
obj-y := $(MODULE_NAME).o
|
||||||
|
|
||||||
$(MODULE_NAME)-$(CONFIG_MP_INCLUDED)+= core/rtw_bt_mp.o
|
|
||||||
endif
|
|
||||||
|
|
||||||
obj-$(CONFIG_RTL8188EU) := $(MODULE_NAME).o
|
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
|
|
|
@ -2138,11 +2138,6 @@ _func_enter_;
|
||||||
|
|
||||||
mlmeext_sta_add_event_callback(adapter, psta);
|
mlmeext_sta_add_event_callback(adapter, psta);
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8711
|
|
||||||
//submit SetStaKey_cmd to tell fw, fw will allocate an CAM entry for this sta
|
|
||||||
rtw_setstakey_cmd(adapter, (unsigned char*)psta, false);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
exit:
|
exit:
|
||||||
|
|
||||||
_func_exit_;
|
_func_exit_;
|
||||||
|
@ -3447,14 +3442,6 @@ unsigned int rtw_restructure_ht_ie(_adapter *padapter, u8 *in_ie, u8 *out_ie, ui
|
||||||
AMPDU_para [4:2]:Min MPDU Start Spacing
|
AMPDU_para [4:2]:Min MPDU Start Spacing
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
|
||||||
#if defined(CONFIG_RTL8188E )&& defined (CONFIG_SDIO_HCI)
|
|
||||||
ht_capie.ampdu_params_info = 2;
|
|
||||||
#else
|
|
||||||
ht_capie.ampdu_params_info = (IEEE80211_HT_CAP_AMPDU_FACTOR&0x03);
|
|
||||||
#endif
|
|
||||||
*/
|
|
||||||
|
|
||||||
rtw_hal_get_def_var(padapter, HW_VAR_MAX_RX_AMPDU_FACTOR, &max_rx_ampdu_factor);
|
rtw_hal_get_def_var(padapter, HW_VAR_MAX_RX_AMPDU_FACTOR, &max_rx_ampdu_factor);
|
||||||
ht_capie.ampdu_params_info = (max_rx_ampdu_factor&0x03);
|
ht_capie.ampdu_params_info = (max_rx_ampdu_factor&0x03);
|
||||||
|
|
||||||
|
@ -3466,17 +3453,10 @@ unsigned int rtw_restructure_ht_ie(_adapter *padapter, u8 *in_ie, u8 *out_ie, ui
|
||||||
|
|
||||||
pframe = rtw_set_ie(out_ie+out_len, _HT_CAPABILITY_IE_,
|
pframe = rtw_set_ie(out_ie+out_len, _HT_CAPABILITY_IE_,
|
||||||
sizeof(struct rtw_ieee80211_ht_cap), (unsigned char*)&ht_capie, pout_len);
|
sizeof(struct rtw_ieee80211_ht_cap), (unsigned char*)&ht_capie, pout_len);
|
||||||
|
|
||||||
|
|
||||||
//_rtw_memcpy(out_ie+out_len, p, ielen+2);//gtest
|
|
||||||
//*pout_len = *pout_len + (ielen+2);
|
|
||||||
|
|
||||||
|
|
||||||
phtpriv->ht_option = true;
|
phtpriv->ht_option = true;
|
||||||
|
|
||||||
p = rtw_get_ie(in_ie+12, _HT_ADD_INFO_IE_, &ielen, in_len-12);
|
p = rtw_get_ie(in_ie+12, _HT_ADD_INFO_IE_, &ielen, in_len-12);
|
||||||
if (p && (ielen==sizeof(struct ieee80211_ht_addt_info)))
|
if (p && (ielen==sizeof(struct ieee80211_ht_addt_info))) {
|
||||||
{
|
|
||||||
out_len = *pout_len;
|
out_len = *pout_len;
|
||||||
pframe = rtw_set_ie(out_ie+out_len, _HT_ADD_INFO_IE_, ielen, p+2 , pout_len);
|
pframe = rtw_set_ie(out_ie+out_len, _HT_ADD_INFO_IE_, ielen, p+2 , pout_len);
|
||||||
}
|
}
|
||||||
|
|
|
@ -8089,24 +8089,16 @@ void issue_action_BA(_adapter *padapter, unsigned char *raddr, unsigned char act
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
#if defined(CONFIG_RTL8188E) && defined(CONFIG_SDIO_HCI)
|
|
||||||
BA_para_set = (0x0802 | ((status & 0xf) << 2)); //immediate ack & 16 buffer size
|
|
||||||
#else
|
|
||||||
BA_para_set = (0x1002 | ((status & 0xf) << 2)); //immediate ack & 64 buffer size
|
BA_para_set = (0x1002 | ((status & 0xf) << 2)); //immediate ack & 64 buffer size
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
//sys_mib.BA_para_set = 0x0802; //immediate ack & 32 buffer size
|
|
||||||
BA_para_set = cpu_to_le16(BA_para_set);
|
BA_para_set = cpu_to_le16(BA_para_set);
|
||||||
pframe = rtw_set_fixed_ie(pframe, 2, (unsigned char *)(&(BA_para_set)), &(pattrib->pktlen));
|
pframe = rtw_set_fixed_ie(pframe, 2, (unsigned char *)(&(BA_para_set)), &(pattrib->pktlen));
|
||||||
|
|
||||||
//BA_timeout_value = 0xffff;//max: 65535 TUs(~ 65 ms)
|
|
||||||
BA_timeout_value = 5000;//~ 5ms
|
BA_timeout_value = 5000;//~ 5ms
|
||||||
BA_timeout_value = cpu_to_le16(BA_timeout_value);
|
BA_timeout_value = cpu_to_le16(BA_timeout_value);
|
||||||
pframe = rtw_set_fixed_ie(pframe, 2, (unsigned char *)(&(BA_timeout_value)), &(pattrib->pktlen));
|
pframe = rtw_set_fixed_ie(pframe, 2, (unsigned char *)(&(BA_timeout_value)), &(pattrib->pktlen));
|
||||||
|
|
||||||
//if ((psta = rtw_get_stainfo(pstapriv, pmlmeinfo->network.MacAddress)) != NULL)
|
if ((psta = rtw_get_stainfo(pstapriv, raddr)) != NULL) {
|
||||||
if ((psta = rtw_get_stainfo(pstapriv, raddr)) != NULL)
|
|
||||||
{
|
|
||||||
start_seq = (psta->sta_xmitpriv.txseq_tid[status & 0x07]&0xfff) + 1;
|
start_seq = (psta->sta_xmitpriv.txseq_tid[status & 0x07]&0xfff) + 1;
|
||||||
|
|
||||||
DBG_88E("BA_starting_seqctrl = %d for TID=%d\n", start_seq, status & 0x07);
|
DBG_88E("BA_starting_seqctrl = %d for TID=%d\n", start_seq, status & 0x07);
|
||||||
|
@ -8123,14 +8115,6 @@ void issue_action_BA(_adapter *padapter, unsigned char *raddr, unsigned char act
|
||||||
case 1: //ADDBA rsp
|
case 1: //ADDBA rsp
|
||||||
pframe = rtw_set_fixed_ie(pframe, 1, &(pmlmeinfo->ADDBA_req.dialog_token), &(pattrib->pktlen));
|
pframe = rtw_set_fixed_ie(pframe, 1, &(pmlmeinfo->ADDBA_req.dialog_token), &(pattrib->pktlen));
|
||||||
pframe = rtw_set_fixed_ie(pframe, 2, (unsigned char *)(&status), &(pattrib->pktlen));
|
pframe = rtw_set_fixed_ie(pframe, 2, (unsigned char *)(&status), &(pattrib->pktlen));
|
||||||
/*
|
|
||||||
//BA_para_set = cpu_to_le16((le16_to_cpu(pmlmeinfo->ADDBA_req.BA_para_set) & 0x3f) | 0x1000); //64 buffer size
|
|
||||||
#if defined(CONFIG_RTL8188E )&& defined (CONFIG_SDIO_HCI)
|
|
||||||
BA_para_set = ((le16_to_cpu(pmlmeinfo->ADDBA_req.BA_para_set) & 0x3f) | 0x0800); //32buffer size
|
|
||||||
#else
|
|
||||||
BA_para_set = ((le16_to_cpu(pmlmeinfo->ADDBA_req.BA_para_set) & 0x3f) | 0x1000); //64 buffer size
|
|
||||||
#endif
|
|
||||||
*/
|
|
||||||
rtw_hal_get_def_var(padapter, HW_VAR_MAX_RX_AMPDU_FACTOR, &max_rx_ampdu_factor);
|
rtw_hal_get_def_var(padapter, HW_VAR_MAX_RX_AMPDU_FACTOR, &max_rx_ampdu_factor);
|
||||||
if (MAX_AMPDU_FACTOR_64K == max_rx_ampdu_factor)
|
if (MAX_AMPDU_FACTOR_64K == max_rx_ampdu_factor)
|
||||||
BA_para_set = ((le16_to_cpu(pmlmeinfo->ADDBA_req.BA_para_set) & 0x3f) | 0x1000); //64 buffer size
|
BA_para_set = ((le16_to_cpu(pmlmeinfo->ADDBA_req.BA_para_set) & 0x3f) | 0x1000); //64 buffer size
|
||||||
|
|
162
core/rtw_mp.c
162
core/rtw_mp.c
|
@ -25,23 +25,8 @@
|
||||||
#include <sys/unistd.h> /* for RFHIGHPID */
|
#include <sys/unistd.h> /* for RFHIGHPID */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8712
|
|
||||||
#include <rtw_mp_phy_regdef.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
#include <rtl8192c_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
#include <rtl8192d_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#include <rtl8723a_hal.h>
|
|
||||||
#include "rtw_bt_mp.h"
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#include "odm_precomp.h"
|
#include "odm_precomp.h"
|
||||||
#include "rtl8188e_hal.h"
|
#include "rtl8188e_hal.h"
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef CONFIG_MP_INCLUDED
|
#ifdef CONFIG_MP_INCLUDED
|
||||||
|
@ -337,25 +322,9 @@ void free_mp_priv(struct mp_priv *pmp_priv)
|
||||||
pmp_priv->pmp_xmtframe_buf = NULL;
|
pmp_priv->pmp_xmtframe_buf = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (CONFIG_RTL8192C) || defined (CONFIG_RTL8723A)
|
|
||||||
#define PHY_IQCalibrate(a,b) rtl8192c_PHY_IQCalibrate(a,b)
|
|
||||||
#define PHY_LCCalibrate(a) rtl8192c_PHY_LCCalibrate(a)
|
|
||||||
//#define dm_CheckTXPowerTracking(a) rtl8192c_odm_CheckTXPowerTracking(a)
|
|
||||||
#define PHY_SetRFPathSwitch(a,b) rtl8192c_PHY_SetRFPathSwitch(a,b)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
#define PHY_IQCalibrate(a,b) rtl8192d_PHY_IQCalibrate(a)
|
|
||||||
#define PHY_LCCalibrate(a) rtl8192d_PHY_LCCalibrate(a)
|
|
||||||
//#define dm_CheckTXPowerTracking(a) rtl8192d_odm_CheckTXPowerTracking(a)
|
|
||||||
#define PHY_SetRFPathSwitch(a,b) rtl8192d_PHY_SetRFPathSwitch(a,b)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#define PHY_IQCalibrate(a,b) PHY_IQCalibrate_8188E(a,b)
|
#define PHY_IQCalibrate(a,b) PHY_IQCalibrate_8188E(a,b)
|
||||||
#define PHY_LCCalibrate(a) PHY_LCCalibrate_8188E(a)
|
#define PHY_LCCalibrate(a) PHY_LCCalibrate_8188E(a)
|
||||||
#define PHY_SetRFPathSwitch(a,b) PHY_SetRFPathSwitch_8188E(a,b)
|
#define PHY_SetRFPathSwitch(a,b) PHY_SetRFPathSwitch_8188E(a,b)
|
||||||
#endif
|
|
||||||
|
|
||||||
s32
|
s32
|
||||||
MPT_InitializeAdapter(
|
MPT_InitializeAdapter(
|
||||||
|
@ -380,66 +349,28 @@ MPT_InitializeAdapter(
|
||||||
pMptCtx->bMptIndexEven = true; //default gain index is -6.0db
|
pMptCtx->bMptIndexEven = true; //default gain index is -6.0db
|
||||||
pMptCtx->h2cReqNum = 0x0;
|
pMptCtx->h2cReqNum = 0x0;
|
||||||
/* Init mpt event. */
|
/* Init mpt event. */
|
||||||
//init for BT MP
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
pMptCtx->bMPh2c_timeout = false;
|
|
||||||
pMptCtx->MptH2cRspEvent = false;
|
|
||||||
pMptCtx->MptBtC2hEvent = false;
|
|
||||||
|
|
||||||
_rtw_init_sema(&pMptCtx->MPh2c_Sema, 0);
|
|
||||||
_init_timer( &pMptCtx->MPh2c_timeout_timer, pAdapter->pnetdev, MPh2c_timeout_handle, pAdapter );
|
|
||||||
#endif
|
|
||||||
|
|
||||||
pMptCtx->bMptWorkItemInProgress = false;
|
pMptCtx->bMptWorkItemInProgress = false;
|
||||||
pMptCtx->CurrMptAct = NULL;
|
pMptCtx->CurrMptAct = NULL;
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
|
||||||
#if 1
|
|
||||||
// Don't accept any packets
|
// Don't accept any packets
|
||||||
rtw_write32(pAdapter, REG_RCR, 0);
|
rtw_write32(pAdapter, REG_RCR, 0);
|
||||||
#else
|
|
||||||
// Accept CRC error and destination address
|
|
||||||
//pHalData->ReceiveConfig |= (RCR_ACRC32|RCR_AAP);
|
|
||||||
//rtw_write32(pAdapter, REG_RCR, pHalData->ReceiveConfig);
|
|
||||||
rtw_write32(pAdapter, REG_RCR, 0x70000101);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (IS_HARDWARE_TYPE_8192DU(pAdapter))
|
if (IS_HARDWARE_TYPE_8192DU(pAdapter))
|
||||||
{
|
|
||||||
rtw_write32(pAdapter, REG_LEDCFG0, 0x8888);
|
rtw_write32(pAdapter, REG_LEDCFG0, 0x8888);
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
|
||||||
//rtw_write32(pAdapter, REG_LEDCFG0, 0x08080);
|
|
||||||
ledsetting = rtw_read32(pAdapter, REG_LEDCFG0);
|
ledsetting = rtw_read32(pAdapter, REG_LEDCFG0);
|
||||||
|
|
||||||
#if defined (CONFIG_RTL8192C) || defined( CONFIG_RTL8192D )
|
|
||||||
rtw_write32(pAdapter, REG_LEDCFG0, ledsetting & ~LED0DIS);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
PHY_IQCalibrate(pAdapter, false);
|
PHY_IQCalibrate(pAdapter, false);
|
||||||
dm_CheckTXPowerTracking(&pHalData->odmpriv); //trigger thermal meter
|
dm_CheckTXPowerTracking(&pHalData->odmpriv); //trigger thermal meter
|
||||||
PHY_LCCalibrate(pAdapter);
|
PHY_LCCalibrate(pAdapter);
|
||||||
|
|
||||||
#ifdef CONFIG_PCI_HCI
|
|
||||||
PHY_SetRFPathSwitch(pAdapter, 1/*pHalData->bDefaultAntenna*/); //Wifi default use Main
|
|
||||||
#else
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
if (pHalData->BoardType == BOARD_MINICARD)
|
|
||||||
PHY_SetRFPathSwitch(pAdapter, 1/*pHalData->bDefaultAntenna*/); //default use Main
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
pMptCtx->backup0xc50 = (u1Byte)PHY_QueryBBReg(pAdapter, rOFDM0_XAAGCCore1, bMaskByte0);
|
pMptCtx->backup0xc50 = (u1Byte)PHY_QueryBBReg(pAdapter, rOFDM0_XAAGCCore1, bMaskByte0);
|
||||||
pMptCtx->backup0xc58 = (u1Byte)PHY_QueryBBReg(pAdapter, rOFDM0_XBAGCCore1, bMaskByte0);
|
pMptCtx->backup0xc58 = (u1Byte)PHY_QueryBBReg(pAdapter, rOFDM0_XBAGCCore1, bMaskByte0);
|
||||||
pMptCtx->backup0xc30 = (u1Byte)PHY_QueryBBReg(pAdapter, rOFDM0_RxDetector1, bMaskByte0);
|
pMptCtx->backup0xc30 = (u1Byte)PHY_QueryBBReg(pAdapter, rOFDM0_RxDetector1, bMaskByte0);
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
pMptCtx->backup0x52_RF_A = (u1Byte)PHY_QueryRFReg(pAdapter, RF_PATH_A, RF_0x52, 0x000F0);
|
pMptCtx->backup0x52_RF_A = (u1Byte)PHY_QueryRFReg(pAdapter, RF_PATH_A, RF_0x52, 0x000F0);
|
||||||
pMptCtx->backup0x52_RF_B = (u1Byte)PHY_QueryRFReg(pAdapter, RF_PATH_A, RF_0x52, 0x000F0);
|
pMptCtx->backup0x52_RF_B = (u1Byte)PHY_QueryRFReg(pAdapter, RF_PATH_A, RF_0x52, 0x000F0);
|
||||||
#endif
|
|
||||||
|
|
||||||
//set ant to wifi side in mp mode
|
//set ant to wifi side in mp mode
|
||||||
rtw_write16(pAdapter, 0x870, 0x300);
|
rtw_write16(pAdapter, 0x870, 0x300);
|
||||||
|
@ -476,10 +407,6 @@ MPT_DeInitAdapter(
|
||||||
PMPT_CONTEXT pMptCtx = &pAdapter->mppriv.MptCtx;
|
PMPT_CONTEXT pMptCtx = &pAdapter->mppriv.MptCtx;
|
||||||
|
|
||||||
pMptCtx->bMptDrvUnload = true;
|
pMptCtx->bMptDrvUnload = true;
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
_rtw_free_sema(&(pMptCtx->MPh2c_Sema));
|
|
||||||
_cancel_timer_ex( &pMptCtx->MPh2c_timeout_timer);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static u8 mpt_ProStartTest(PADAPTER padapter)
|
static u8 mpt_ProStartTest(PADAPTER padapter)
|
||||||
|
@ -514,22 +441,15 @@ void GetPowerTracking(PADAPTER padapter, u8 *enable)
|
||||||
|
|
||||||
static void disable_dm(PADAPTER padapter)
|
static void disable_dm(PADAPTER padapter)
|
||||||
{
|
{
|
||||||
#ifndef CONFIG_RTL8723A
|
|
||||||
u8 v8;
|
u8 v8;
|
||||||
#endif
|
|
||||||
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(padapter);
|
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(padapter);
|
||||||
struct dm_priv *pdmpriv = &pHalData->dmpriv;
|
struct dm_priv *pdmpriv = &pHalData->dmpriv;
|
||||||
|
|
||||||
|
|
||||||
//3 1. disable firmware dynamic mechanism
|
//3 1. disable firmware dynamic mechanism
|
||||||
// disable Power Training, Rate Adaptive
|
// disable Power Training, Rate Adaptive
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
SetBcnCtrlReg(padapter, 0, EN_BCN_FUNCTION);
|
|
||||||
#else
|
|
||||||
v8 = rtw_read8(padapter, REG_BCN_CTRL);
|
v8 = rtw_read8(padapter, REG_BCN_CTRL);
|
||||||
v8 &= ~EN_BCN_FUNCTION;
|
v8 &= ~EN_BCN_FUNCTION;
|
||||||
rtw_write8(padapter, REG_BCN_CTRL, v8);
|
rtw_write8(padapter, REG_BCN_CTRL, v8);
|
||||||
#endif
|
|
||||||
|
|
||||||
//3 2. disable driver dynamic mechanism
|
//3 2. disable driver dynamic mechanism
|
||||||
// disable Dynamic Initial Gain
|
// disable Dynamic Initial Gain
|
||||||
|
@ -538,9 +458,6 @@ static void disable_dm(PADAPTER padapter)
|
||||||
Switch_DM_Func(padapter, DYNAMIC_FUNC_DISABLE, false);
|
Switch_DM_Func(padapter, DYNAMIC_FUNC_DISABLE, false);
|
||||||
|
|
||||||
// enable APK, LCK and IQK but disable power tracking
|
// enable APK, LCK and IQK but disable power tracking
|
||||||
#ifndef CONFIG_RTL8188E
|
|
||||||
pdmpriv->TxPowerTrackControl = false;
|
|
||||||
#endif
|
|
||||||
Switch_DM_Func(padapter, DYNAMIC_RF_CALIBRATION, true);
|
Switch_DM_Func(padapter, DYNAMIC_RF_CALIBRATION, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -652,24 +569,10 @@ end_of_mp_start_test:
|
||||||
if (res == _SUCCESS)
|
if (res == _SUCCESS)
|
||||||
{
|
{
|
||||||
// set MSR to WIFI_FW_ADHOC_STATE
|
// set MSR to WIFI_FW_ADHOC_STATE
|
||||||
#if !defined (CONFIG_RTL8712)
|
|
||||||
val8 = rtw_read8(padapter, MSR) & 0xFC; // 0x0102
|
val8 = rtw_read8(padapter, MSR) & 0xFC; // 0x0102
|
||||||
val8 |= WIFI_FW_ADHOC_STATE;
|
val8 |= WIFI_FW_ADHOC_STATE;
|
||||||
rtw_write8(padapter, MSR, val8); // Link in ad hoc network
|
rtw_write8(padapter, MSR, val8); // Link in ad hoc network
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined (CONFIG_RTL8712)
|
|
||||||
rtw_write8(padapter, MSR, 1); // Link in ad hoc network
|
|
||||||
rtw_write8(padapter, RCR, 0); // RCR : disable all pkt, 0x10250048
|
|
||||||
rtw_write8(padapter, RCR+2, 0x57); // RCR disable Check BSSID, 0x1025004a
|
|
||||||
|
|
||||||
// disable RX filter map , mgt frames will put in RX FIFO 0
|
|
||||||
rtw_write16(padapter, RXFLTMAP0, 0x0); // 0x10250116
|
|
||||||
|
|
||||||
val8 = rtw_read8(padapter, EE_9346CR); // 0x1025000A
|
|
||||||
if (!(val8 & _9356SEL))//boot from EFUSE
|
|
||||||
efuse_change_max_size(padapter);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
|
@ -823,27 +726,6 @@ void MP_PHY_SetRFPathSwitch(PADAPTER pAdapter ,bool bMain)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (CONFIG_RTL8712)
|
|
||||||
/*------------------------------Define structure----------------------------*/
|
|
||||||
typedef struct _R_ANTENNA_SELECT_OFDM {
|
|
||||||
u32 r_tx_antenna:4;
|
|
||||||
u32 r_ant_l:4;
|
|
||||||
u32 r_ant_non_ht:4;
|
|
||||||
u32 r_ant_ht1:4;
|
|
||||||
u32 r_ant_ht2:4;
|
|
||||||
u32 r_ant_ht_s1:4;
|
|
||||||
u32 r_ant_non_ht_s1:4;
|
|
||||||
u32 OFDM_TXSC:2;
|
|
||||||
u32 Reserved:2;
|
|
||||||
}R_ANTENNA_SELECT_OFDM;
|
|
||||||
|
|
||||||
typedef struct _R_ANTENNA_SELECT_CCK {
|
|
||||||
u8 r_cckrx_enable_2:2;
|
|
||||||
u8 r_cckrx_enable:2;
|
|
||||||
u8 r_ccktx_enable:4;
|
|
||||||
}R_ANTENNA_SELECT_CCK;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
s32 SetThermalMeter(PADAPTER pAdapter, u8 target_ther)
|
s32 SetThermalMeter(PADAPTER pAdapter, u8 target_ther)
|
||||||
{
|
{
|
||||||
return Hal_SetThermalMeter( pAdapter, target_ther);
|
return Hal_SetThermalMeter( pAdapter, target_ther);
|
||||||
|
@ -906,15 +788,7 @@ void PhySetTxPowerLevel(PADAPTER pAdapter)
|
||||||
struct mp_priv *pmp_priv = &pAdapter->mppriv;
|
struct mp_priv *pmp_priv = &pAdapter->mppriv;
|
||||||
|
|
||||||
if (pmp_priv->bSetTxPower==0) // for NO manually set power index
|
if (pmp_priv->bSetTxPower==0) // for NO manually set power index
|
||||||
{
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
PHY_SetTxPowerLevel8188E(pAdapter,pmp_priv->channel);
|
PHY_SetTxPowerLevel8188E(pAdapter,pmp_priv->channel);
|
||||||
#elif defined(CONFIG_RTL8192D)
|
|
||||||
PHY_SetTxPowerLevel8192D(pAdapter,pmp_priv->channel);
|
|
||||||
#else
|
|
||||||
PHY_SetTxPowerLevel8192C(pAdapter,pmp_priv->channel);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
@ -1071,44 +945,24 @@ void SetPacketTx(PADAPTER padapter)
|
||||||
|
|
||||||
//3 3. init TX descriptor
|
//3 3. init TX descriptor
|
||||||
// offset 0
|
// offset 0
|
||||||
#if defined(CONFIG_RTL8188E) && !defined(CONFIG_RTL8188E_SDIO)
|
|
||||||
desc->txdw0 |= cpu_to_le32(OWN | FSG | LSG);
|
desc->txdw0 |= cpu_to_le32(OWN | FSG | LSG);
|
||||||
desc->txdw0 |= cpu_to_le32(pkt_size & 0x0000FFFF); // packet size
|
desc->txdw0 |= cpu_to_le32(pkt_size & 0x0000FFFF); // packet size
|
||||||
desc->txdw0 |= cpu_to_le32(((TXDESC_SIZE + OFFSET_SZ) << OFFSET_SHT) & 0x00FF0000); //32 bytes for TX Desc
|
desc->txdw0 |= cpu_to_le32(((TXDESC_SIZE + OFFSET_SZ) << OFFSET_SHT) & 0x00FF0000); //32 bytes for TX Desc
|
||||||
if (bmcast) desc->txdw0 |= cpu_to_le32(BMC); // broadcast packet
|
if (bmcast) desc->txdw0 |= cpu_to_le32(BMC); // broadcast packet
|
||||||
|
|
||||||
desc->txdw1 |= cpu_to_le32((0x01 << 26) & 0xff000000);
|
desc->txdw1 |= cpu_to_le32((0x01 << 26) & 0xff000000);
|
||||||
#endif
|
|
||||||
// offset 4
|
// offset 4
|
||||||
#ifndef CONFIG_RTL8188E
|
|
||||||
desc->txdw1 |= cpu_to_le32(BK); // don't aggregate(AMPDU)
|
|
||||||
desc->txdw1 |= cpu_to_le32((pattrib->mac_id) & 0x1F); //CAM_ID(MAC_ID)
|
|
||||||
#else
|
|
||||||
desc->txdw1 |= cpu_to_le32((pattrib->mac_id) & 0x3F); //CAM_ID(MAC_ID)
|
desc->txdw1 |= cpu_to_le32((pattrib->mac_id) & 0x3F); //CAM_ID(MAC_ID)
|
||||||
#endif
|
|
||||||
desc->txdw1 |= cpu_to_le32((pattrib->qsel << QSEL_SHT) & 0x00001F00); // Queue Select, TID
|
desc->txdw1 |= cpu_to_le32((pattrib->qsel << QSEL_SHT) & 0x00001F00); // Queue Select, TID
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
desc->txdw1 |= cpu_to_le32((pattrib->raid << RATE_ID_SHT) & 0x000F0000); // Rate Adaptive ID
|
desc->txdw1 |= cpu_to_le32((pattrib->raid << RATE_ID_SHT) & 0x000F0000); // Rate Adaptive ID
|
||||||
#else
|
|
||||||
desc->txdw1 |= cpu_to_le32((pattrib->raid << Rate_ID_SHT) & 0x000F0000); // Rate Adaptive ID
|
|
||||||
|
|
||||||
#endif
|
|
||||||
// offset 8
|
// offset 8
|
||||||
// desc->txdw2 |= cpu_to_le32(AGG_BK);//AGG BK
|
|
||||||
// offset 12
|
// offset 12
|
||||||
|
|
||||||
desc->txdw3 |= cpu_to_le32((pattrib->seqnum<<16)&0x0fff0000);
|
desc->txdw3 |= cpu_to_le32((pattrib->seqnum<<16)&0x0fff0000);
|
||||||
// desc->txdw3 |= cpu_to_le32((pattrib->seqnum & 0xFFF) << SEQ_SHT);
|
|
||||||
//desc->txdw3 |= cpu_to_le32((pattrib->seqnum << SEQ_SHT) & 0xffff0000);
|
|
||||||
|
|
||||||
// offset 16
|
// offset 16
|
||||||
//desc->txdw4 |= cpu_to_le32(QoS)
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
desc->txdw4 |= cpu_to_le32(HW_SSN);
|
desc->txdw4 |= cpu_to_le32(HW_SSN);
|
||||||
#else
|
|
||||||
desc->txdw4 |= cpu_to_le32(HW_SEQ_EN);
|
|
||||||
#endif
|
|
||||||
desc->txdw4 |= cpu_to_le32(USERATE);
|
desc->txdw4 |= cpu_to_le32(USERATE);
|
||||||
desc->txdw4 |= cpu_to_le32(DISDATAFB);
|
desc->txdw4 |= cpu_to_le32(DISDATAFB);
|
||||||
|
|
||||||
|
@ -1126,12 +980,8 @@ void SetPacketTx(PADAPTER padapter)
|
||||||
if (pmp_priv->rateidx > MPT_RATE_54M)
|
if (pmp_priv->rateidx > MPT_RATE_54M)
|
||||||
desc->txdw5 |= cpu_to_le32(SGI); // MCS Short Guard Interval
|
desc->txdw5 |= cpu_to_le32(SGI); // MCS Short Guard Interval
|
||||||
}
|
}
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
desc->txdw5 |= cpu_to_le32(RTY_LMT_EN); // retry limit enable
|
desc->txdw5 |= cpu_to_le32(RTY_LMT_EN); // retry limit enable
|
||||||
desc->txdw5 |= cpu_to_le32(0x00180000); // DATA/RTS Rate Fallback Limit
|
desc->txdw5 |= cpu_to_le32(0x00180000); // DATA/RTS Rate Fallback Limit
|
||||||
#else
|
|
||||||
desc->txdw5 |= cpu_to_le32(0x0001FF00); // DATA/RTS Rate Fallback Limit
|
|
||||||
#endif
|
|
||||||
|
|
||||||
//3 4. make wlan header, make_wlanhdr()
|
//3 4. make wlan header, make_wlanhdr()
|
||||||
hdr = (struct rtw_ieee80211_hdr *)pkt_start;
|
hdr = (struct rtw_ieee80211_hdr *)pkt_start;
|
||||||
|
@ -1186,11 +1036,8 @@ void SetPacketRx(PADAPTER pAdapter, u8 bStartRx)
|
||||||
{
|
{
|
||||||
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(pAdapter);
|
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(pAdapter);
|
||||||
|
|
||||||
if (bStartRx)
|
if (bStartRx) {
|
||||||
{
|
|
||||||
// Accept CRC error and destination address
|
// Accept CRC error and destination address
|
||||||
#if 1
|
|
||||||
//ndef CONFIG_RTL8723A
|
|
||||||
pHalData->ReceiveConfig = AAP | APM | AM | AB | APP_ICV | ADF | AMF | HTC_LOC_CTRL | APP_MIC | APP_PHYSTS;
|
pHalData->ReceiveConfig = AAP | APM | AM | AB | APP_ICV | ADF | AMF | HTC_LOC_CTRL | APP_MIC | APP_PHYSTS;
|
||||||
|
|
||||||
pHalData->ReceiveConfig |= ACRC32;
|
pHalData->ReceiveConfig |= ACRC32;
|
||||||
|
@ -1199,12 +1046,7 @@ void SetPacketRx(PADAPTER pAdapter, u8 bStartRx)
|
||||||
|
|
||||||
// Accept all data frames
|
// Accept all data frames
|
||||||
rtw_write16(pAdapter, REG_RXFLTMAP2, 0xFFFF);
|
rtw_write16(pAdapter, REG_RXFLTMAP2, 0xFFFF);
|
||||||
#else
|
} else {
|
||||||
rtw_write32(pAdapter, REG_RCR, 0x70000101);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
rtw_write32(pAdapter, REG_RCR, 0);
|
rtw_write32(pAdapter, REG_RCR, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -811,18 +811,7 @@ _func_enter_;
|
||||||
adapter_to_dvobj(Adapter)->pusbdev->autosuspend_disabled = Adapter->bDisableAutosuspend;//autosuspend disabled by the user
|
adapter_to_dvobj(Adapter)->pusbdev->autosuspend_disabled = Adapter->bDisableAutosuspend;//autosuspend disabled by the user
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
else
|
|
||||||
#endif
|
#endif
|
||||||
{
|
|
||||||
#if defined(CONFIG_PLATFORM_SPRD) && defined(CONFIG_RTL8188E)
|
|
||||||
#ifdef CONFIG_IPS
|
|
||||||
if (false == ips_leave(Adapter))
|
|
||||||
{
|
|
||||||
DBG_88E("======> ips_leave fail.............\n");
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#endif //CONFIG_PLATFORM_SPRD && CONFIG_RTL8188E
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -24,18 +24,7 @@
|
||||||
#include <hal_intf.h>
|
#include <hal_intf.h>
|
||||||
#include <hal_com.h>
|
#include <hal_com.h>
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
#include <rtl8192c_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
#include <rtl8192d_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#include <rtl8723a_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#include <rtl8188e_hal.h>
|
#include <rtl8188e_hal.h>
|
||||||
#endif
|
|
||||||
|
|
||||||
#define _HAL_INIT_C_
|
#define _HAL_INIT_C_
|
||||||
|
|
||||||
|
|
27
hal/odm.c
27
hal/odm.c
|
@ -4431,7 +4431,6 @@ odm_TXPowerTrackingThermalMeterInit(
|
||||||
#endif//#if (MP_DRIVER != 1)
|
#endif//#if (MP_DRIVER != 1)
|
||||||
ODM_RT_TRACE(pDM_Odm,COMP_POWER_TRACKING, DBG_LOUD, ("pMgntInfo->bTXPowerTracking = %d\n", pMgntInfo->bTXPowerTracking));
|
ODM_RT_TRACE(pDM_Odm,COMP_POWER_TRACKING, DBG_LOUD, ("pMgntInfo->bTXPowerTracking = %d\n", pMgntInfo->bTXPowerTracking));
|
||||||
#elif (DM_ODM_SUPPORT_TYPE == ODM_CE)
|
#elif (DM_ODM_SUPPORT_TYPE == ODM_CE)
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
{
|
{
|
||||||
pDM_Odm->RFCalibrateInfo.bTXPowerTracking = true;
|
pDM_Odm->RFCalibrateInfo.bTXPowerTracking = true;
|
||||||
pDM_Odm->RFCalibrateInfo.TXPowercount = 0;
|
pDM_Odm->RFCalibrateInfo.TXPowercount = 0;
|
||||||
|
@ -4442,29 +4441,7 @@ odm_TXPowerTrackingThermalMeterInit(
|
||||||
//#endif//#if (MP_DRIVER != 1)
|
//#endif//#if (MP_DRIVER != 1)
|
||||||
MSG_88E("pDM_Odm TxPowerTrackControl = %d\n", pDM_Odm->RFCalibrateInfo.TxPowerTrackControl);
|
MSG_88E("pDM_Odm TxPowerTrackControl = %d\n", pDM_Odm->RFCalibrateInfo.TxPowerTrackControl);
|
||||||
}
|
}
|
||||||
#else
|
|
||||||
{
|
|
||||||
PADAPTER Adapter = pDM_Odm->Adapter;
|
|
||||||
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(Adapter);
|
|
||||||
struct dm_priv *pdmpriv = &pHalData->dmpriv;
|
|
||||||
|
|
||||||
//if (IS_HARDWARE_TYPE_8192C(pHalData))
|
|
||||||
{
|
|
||||||
pdmpriv->bTXPowerTracking = true;
|
|
||||||
pdmpriv->TXPowercount = 0;
|
|
||||||
pdmpriv->bTXPowerTrackingInit = false;
|
|
||||||
//#if (MP_DRIVER != 1) //for mp driver, turn off txpwrtracking as default
|
|
||||||
|
|
||||||
if (*(pDM_Odm->mp_mode) != 1)
|
|
||||||
pdmpriv->TxPowerTrackControl = true;
|
|
||||||
//#endif//#if (MP_DRIVER != 1)
|
|
||||||
}
|
|
||||||
MSG_88E("pdmpriv->TxPowerTrackControl = %d\n", pdmpriv->TxPowerTrackControl);
|
|
||||||
|
|
||||||
}
|
|
||||||
#endif//endif (CONFIG_RTL8188E==1)
|
|
||||||
#elif (DM_ODM_SUPPORT_TYPE & (ODM_AP|ODM_ADSL))
|
#elif (DM_ODM_SUPPORT_TYPE & (ODM_AP|ODM_ADSL))
|
||||||
#ifdef RTL8188E_SUPPORT
|
|
||||||
{
|
{
|
||||||
pDM_Odm->RFCalibrateInfo.bTXPowerTracking = true;
|
pDM_Odm->RFCalibrateInfo.bTXPowerTracking = true;
|
||||||
pDM_Odm->RFCalibrateInfo.TXPowercount = 0;
|
pDM_Odm->RFCalibrateInfo.TXPowercount = 0;
|
||||||
|
@ -4472,7 +4449,6 @@ odm_TXPowerTrackingThermalMeterInit(
|
||||||
pDM_Odm->RFCalibrateInfo.TxPowerTrackControl = true;
|
pDM_Odm->RFCalibrateInfo.TxPowerTrackControl = true;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
|
|
||||||
pDM_Odm->RFCalibrateInfo.TxPowerTrackControl = TRUE;
|
pDM_Odm->RFCalibrateInfo.TxPowerTrackControl = TRUE;
|
||||||
}
|
}
|
||||||
|
@ -4490,9 +4466,6 @@ ODM_TXPowerTrackingCheck(
|
||||||
PADAPTER pAdapter = pDM_Odm->Adapter;
|
PADAPTER pAdapter = pDM_Odm->Adapter;
|
||||||
prtl8192cd_priv priv = pDM_Odm->priv;
|
prtl8192cd_priv priv = pDM_Odm->priv;
|
||||||
|
|
||||||
//if (!(pDM_Odm->SupportAbility & ODM_RF_TX_PWR_TRACK))
|
|
||||||
//return;
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// 2011/09/29 MH In HW integration first stage, we provide 4 different handle to operate
|
// 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
|
// at the same time. In the stage2/3, we need to prive universal interface and merge all
|
||||||
|
|
|
@ -51,24 +51,8 @@ enum _EFUSE_DEF_TYPE {
|
||||||
};
|
};
|
||||||
|
|
||||||
/* E-Fuse */
|
/* E-Fuse */
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
#define EFUSE_MAP_SIZE 256
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
#define EFUSE_MAP_SIZE 128
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#define EFUSE_MAP_SIZE 256
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#define EFUSE_MAP_SIZE 512
|
#define EFUSE_MAP_SIZE 512
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#define EFUSE_MAX_SIZE 256
|
#define EFUSE_MAX_SIZE 256
|
||||||
#else
|
|
||||||
#define EFUSE_MAX_SIZE 512
|
|
||||||
#endif
|
|
||||||
/* end of E-Fuse */
|
/* end of E-Fuse */
|
||||||
|
|
||||||
#define EFUSE_MAX_MAP_LEN 256
|
#define EFUSE_MAX_MAP_LEN 256
|
||||||
|
|
|
@ -182,19 +182,7 @@ struct mp_tx
|
||||||
_thread_hdl_ PktTxThread;
|
_thread_hdl_ PktTxThread;
|
||||||
};
|
};
|
||||||
|
|
||||||
#if defined(CONFIG_RTL8192C) || defined(CONFIG_RTL8192D) || defined(CONFIG_RTL8723A) || defined(CONFIG_RTL8188E)
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
#include <Hal8192CPhyCfg.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
#include <Hal8192DPhyCfg.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#include <Hal8723APhyCfg.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#include <Hal8188EPhyCfg.h>
|
#include <Hal8188EPhyCfg.h>
|
||||||
#endif
|
|
||||||
|
|
||||||
#define MP_MAX_LINES 1000
|
#define MP_MAX_LINES 1000
|
||||||
#define MP_MAX_LINES_BYTES 256
|
#define MP_MAX_LINES_BYTES 256
|
||||||
|
@ -335,8 +323,6 @@ typedef struct _MPT_CONTEXT
|
||||||
u1Byte mptOutBuf[100];
|
u1Byte mptOutBuf[100];
|
||||||
|
|
||||||
}MPT_CONTEXT, *PMPT_CONTEXT;
|
}MPT_CONTEXT, *PMPT_CONTEXT;
|
||||||
#endif
|
|
||||||
//#endif
|
|
||||||
|
|
||||||
//#define RTPRIV_IOCTL_MP ( SIOCIWFIRSTPRIV + 0x17)
|
//#define RTPRIV_IOCTL_MP ( SIOCIWFIRSTPRIV + 0x17)
|
||||||
enum {
|
enum {
|
||||||
|
|
|
@ -32,18 +32,7 @@ struct sreset_priv {
|
||||||
unsigned long last_tx_complete_time;
|
unsigned long last_tx_complete_time;
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
#include <rtl8192c_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
#include <rtl8192d_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#include <rtl8723a_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#include <rtl8188e_hal.h>
|
#include <rtl8188e_hal.h>
|
||||||
#endif
|
|
||||||
|
|
||||||
#define WIFI_STATUS_SUCCESS 0
|
#define WIFI_STATUS_SUCCESS 0
|
||||||
#define USB_VEN_REQ_CMD_FAIL BIT0
|
#define USB_VEN_REQ_CMD_FAIL BIT0
|
||||||
|
|
|
@ -20,27 +20,11 @@
|
||||||
#ifndef __USB_HAL_H__
|
#ifndef __USB_HAL_H__
|
||||||
#define __USB_HAL_H__
|
#define __USB_HAL_H__
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
void rtl8192cu_set_hal_ops(_adapter * padapter);
|
|
||||||
#define hal_set_hal_ops rtl8192cu_set_hal_ops
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
void rtl8192du_set_hal_ops(_adapter * padapter);
|
|
||||||
#define hal_set_hal_ops rtl8192du_set_hal_ops
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
void rtl8723au_set_hal_ops(_adapter * padapter);
|
|
||||||
#define hal_set_hal_ops rtl8723au_set_hal_ops
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
void rtl8188eu_set_hal_ops(_adapter * padapter);
|
void rtl8188eu_set_hal_ops(_adapter * padapter);
|
||||||
#define hal_set_hal_ops rtl8188eu_set_hal_ops
|
#define hal_set_hal_ops rtl8188eu_set_hal_ops
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_INTEL_PROXIM
|
#ifdef CONFIG_INTEL_PROXIM
|
||||||
extern _adapter *rtw_usb_get_sw_pointer(void);
|
extern _adapter *rtw_usb_get_sw_pointer(void);
|
||||||
#endif //CONFIG_INTEL_PROXIM
|
#endif //CONFIG_INTEL_PROXIM
|
||||||
|
|
||||||
#endif //__USB_HAL_H__
|
#endif //__USB_HAL_H__
|
||||||
|
|
|
@ -55,53 +55,10 @@ enum{
|
||||||
#include <usb_ops_linux.h>
|
#include <usb_ops_linux.h>
|
||||||
#endif //PLATFORM_LINUX
|
#endif //PLATFORM_LINUX
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
void rtl8192cu_set_hw_type(_adapter *padapter);
|
|
||||||
#define hal_set_hw_type rtl8192cu_set_hw_type
|
|
||||||
|
|
||||||
void rtl8192cu_set_intf_ops(struct _io_ops *pops);
|
|
||||||
#define usb_set_intf_ops rtl8192cu_set_intf_ops
|
|
||||||
|
|
||||||
void rtl8192cu_recv_tasklet(void *priv);
|
|
||||||
|
|
||||||
void rtl8192cu_xmit_tasklet(void *priv);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
void rtl8723au_set_hw_type(_adapter *padapter);
|
|
||||||
#define hal_set_hw_type rtl8723au_set_hw_type
|
|
||||||
|
|
||||||
void rtl8723au_set_intf_ops(struct _io_ops *pops);
|
|
||||||
#define usb_set_intf_ops rtl8723au_set_intf_ops
|
|
||||||
|
|
||||||
void rtl8192cu_recv_tasklet(void *priv);
|
|
||||||
|
|
||||||
void rtl8192cu_xmit_tasklet(void *priv);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
void rtl8192du_set_hw_type(_adapter *padapter);
|
|
||||||
#define hal_set_hw_type rtl8192du_set_hw_type
|
|
||||||
void rtl8192du_set_intf_ops(struct _io_ops *pops);
|
|
||||||
#define usb_set_intf_ops rtl8192du_set_intf_ops
|
|
||||||
#ifndef PLATFORM_FREEBSD
|
|
||||||
void rtl8192du_recv_tasklet(void *priv);
|
|
||||||
#else // PLATFORM_FREEBSD
|
|
||||||
void rtl8192du_recv_tasklet(void *priv, int npending);
|
|
||||||
#ifdef CONFIG_RX_INDICATE_QUEUE
|
|
||||||
void rtw_rx_indicate_tasklet(void *priv, int npending);
|
|
||||||
#endif // CONFIG_RX_INDICATE_QUEUE
|
|
||||||
#endif // PLATFORM_FREEBSD
|
|
||||||
|
|
||||||
void rtl8192du_xmit_tasklet(void *priv);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
void rtl8188eu_set_hw_type(_adapter *padapter);
|
void rtl8188eu_set_hw_type(_adapter *padapter);
|
||||||
#define hal_set_hw_type rtl8188eu_set_hw_type
|
#define hal_set_hw_type rtl8188eu_set_hw_type
|
||||||
void rtl8188eu_set_intf_ops(struct _io_ops *pops);
|
void rtl8188eu_set_intf_ops(struct _io_ops *pops);
|
||||||
#define usb_set_intf_ops rtl8188eu_set_intf_ops
|
#define usb_set_intf_ops rtl8188eu_set_intf_ops
|
||||||
#endif
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Increase and check if the continual_urb_error of this @param dvobjprive is larger than MAX_CONTINUAL_URB_ERR
|
* Increase and check if the continual_urb_error of this @param dvobjprive is larger than MAX_CONTINUAL_URB_ERR
|
||||||
|
|
|
@ -43,24 +43,7 @@
|
||||||
#ifdef CONFIG_MP_INCLUDED
|
#ifdef CONFIG_MP_INCLUDED
|
||||||
#include <rtw_mp.h>
|
#include <rtw_mp.h>
|
||||||
#endif //#ifdef CONFIG_MP_INCLUDED
|
#endif //#ifdef CONFIG_MP_INCLUDED
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
#include <rtl8192c_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
#include <rtl8192d_hal.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#include <rtl8723a_pg.h>
|
|
||||||
#include <rtl8723a_hal.h>
|
|
||||||
#include <rtw_bt_mp.h>
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#include <rtl8188e_hal.h>
|
#include <rtl8188e_hal.h>
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_GSPI_HCI
|
|
||||||
#include <gspi_ops.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27))
|
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27))
|
||||||
#define iwe_stream_add_event(a, b, c, d, e) iwe_stream_add_event(b, c, d, e)
|
#define iwe_stream_add_event(a, b, c, d, e) iwe_stream_add_event(b, c, d, e)
|
||||||
|
@ -8750,53 +8733,25 @@ static int rtw_mp_efuse_get(struct net_device *dev,
|
||||||
{
|
{
|
||||||
addr = 0;
|
addr = 0;
|
||||||
mapLen = EFUSE_MAX_SIZE;
|
mapLen = EFUSE_MAX_SIZE;
|
||||||
if (rtw_efuse_access(padapter, false, addr, mapLen, rawdata) == _FAIL)
|
if (rtw_efuse_access(padapter, false, addr, mapLen, rawdata) == _FAIL) {
|
||||||
{
|
|
||||||
DBG_88E("%s: rtw_efuse_access Fail!!\n", __func__);
|
DBG_88E("%s: rtw_efuse_access Fail!!\n", __func__);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
// DBG_88E("%s: realraw={\n", __func__);
|
|
||||||
sprintf(extra, "\n");
|
sprintf(extra, "\n");
|
||||||
for (i=0; i<mapLen; i++)
|
for (i=0; i<mapLen; i++) {
|
||||||
{
|
|
||||||
// DBG_88E("%02X", rawdata[i]);
|
|
||||||
sprintf(extra, "%s%02X", extra, rawdata[i]);
|
sprintf(extra, "%s%02X", extra, rawdata[i]);
|
||||||
|
|
||||||
if ((i & 0xF) == 0xF) {
|
if ((i & 0xF) == 0xF) {
|
||||||
// DBG_88E("\n");
|
|
||||||
sprintf(extra, "%s\n", extra);
|
sprintf(extra, "%s\n", extra);
|
||||||
}
|
} else if ((i & 0x7) == 0x7){
|
||||||
else if ((i & 0x7) == 0x7){
|
|
||||||
// DBG_88E("\t");
|
|
||||||
sprintf(extra, "%s\t", extra);
|
sprintf(extra, "%s\t", extra);
|
||||||
} else {
|
} else {
|
||||||
// DBG_88E(" ");
|
|
||||||
sprintf(extra, "%s ", extra);
|
sprintf(extra, "%s ", extra);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// DBG_88E("}\n");
|
} else if (strcmp(tmp[0], "mac") == 0) {
|
||||||
}
|
|
||||||
else if (strcmp(tmp[0], "mac") == 0)
|
|
||||||
{
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
addr = 0x16; // EEPROM_MAC_ADDR
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
addr = 0x19;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#ifdef CONFIG_SDIO_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_8723AS;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_GSPI_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_8723AS;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_USB_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_8723AU;
|
|
||||||
#endif
|
|
||||||
#endif // CONFIG_RTL8723A
|
|
||||||
cnts = 6;
|
cnts = 6;
|
||||||
|
|
||||||
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_available_size, false);
|
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_available_size, false);
|
||||||
|
@ -8806,141 +8761,81 @@ static int rtw_mp_efuse_get(struct net_device *dev,
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rtw_efuse_map_read(padapter, addr, cnts, data) == _FAIL)
|
if (rtw_efuse_map_read(padapter, addr, cnts, data) == _FAIL) {
|
||||||
{
|
|
||||||
DBG_88E("%s: rtw_efuse_map_read error!\n", __func__);
|
DBG_88E("%s: rtw_efuse_map_read error!\n", __func__);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
// DBG_88E("%s: MAC address={", __func__);
|
|
||||||
*extra = 0;
|
*extra = 0;
|
||||||
for (i=0; i<cnts; i++)
|
for (i=0; i<cnts; i++) {
|
||||||
{
|
|
||||||
// DBG_88E("%02X", data[i]);
|
|
||||||
sprintf(extra, "%s%02X", extra, data[i]);
|
sprintf(extra, "%s%02X", extra, data[i]);
|
||||||
if (i != (cnts-1))
|
if (i != (cnts-1))
|
||||||
{
|
|
||||||
// DBG_88E(":");
|
|
||||||
sprintf(extra,"%s:",extra);
|
sprintf(extra,"%s:",extra);
|
||||||
}
|
}
|
||||||
}
|
} else if (strcmp(tmp[0], "vidpid") == 0) {
|
||||||
// DBG_88E("}\n");
|
|
||||||
}
|
|
||||||
else if (strcmp(tmp[0], "vidpid") == 0)
|
|
||||||
{
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
addr = 0x0a; // EEPROM_VID
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
addr = 0x0c;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
addr = EEPROM_VID_8723AU;
|
|
||||||
#endif
|
|
||||||
cnts = 4;
|
cnts = 4;
|
||||||
|
|
||||||
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_available_size, false);
|
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_available_size, false);
|
||||||
if ((addr + cnts) > max_available_size)
|
if ((addr + cnts) > max_available_size) {
|
||||||
{
|
|
||||||
DBG_88E("%s: addr(0x%02x)+cnts(%d) parameter error!\n", __func__, addr, cnts);
|
DBG_88E("%s: addr(0x%02x)+cnts(%d) parameter error!\n", __func__, addr, cnts);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
if (rtw_efuse_map_read(padapter, addr, cnts, data) == _FAIL)
|
if (rtw_efuse_map_read(padapter, addr, cnts, data) == _FAIL) {
|
||||||
{
|
|
||||||
DBG_88E("%s: rtw_efuse_access error!!\n", __func__);
|
DBG_88E("%s: rtw_efuse_access error!!\n", __func__);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
// DBG_88E("%s: {VID,PID}={", __func__);
|
|
||||||
*extra = 0;
|
*extra = 0;
|
||||||
for (i=0; i<cnts; i++)
|
for (i=0; i<cnts; i++) {
|
||||||
{
|
|
||||||
// DBG_88E("0x%02x", data[i]);
|
|
||||||
sprintf(extra, "%s0x%02X", extra, data[i]);
|
sprintf(extra, "%s0x%02X", extra, data[i]);
|
||||||
if (i != (cnts-1))
|
if (i != (cnts-1))
|
||||||
{
|
|
||||||
// DBG_88E(",");
|
|
||||||
sprintf(extra,"%s,",extra);
|
sprintf(extra,"%s,",extra);
|
||||||
}
|
}
|
||||||
}
|
} else if (strcmp(tmp[0], "ableraw") == 0) {
|
||||||
// DBG_88E("}\n");
|
|
||||||
}
|
|
||||||
else if (strcmp(tmp[0], "ableraw") == 0)
|
|
||||||
{
|
|
||||||
efuse_GetCurrentSize(padapter,&raw_cursize);
|
efuse_GetCurrentSize(padapter,&raw_cursize);
|
||||||
raw_maxsize = efuse_GetMaxSize(padapter);
|
raw_maxsize = efuse_GetMaxSize(padapter);
|
||||||
sprintf(extra, "[available raw size]= %d bytes", raw_maxsize-raw_cursize);
|
sprintf(extra, "[available raw size]= %d bytes", raw_maxsize-raw_cursize);
|
||||||
}
|
} else if (strcmp(tmp[0], "btfmap") == 0) {
|
||||||
else if (strcmp(tmp[0], "btfmap") == 0)
|
|
||||||
{
|
|
||||||
mapLen = EFUSE_BT_MAX_MAP_LEN;
|
mapLen = EFUSE_BT_MAX_MAP_LEN;
|
||||||
if (rtw_BT_efuse_map_read(padapter, 0, mapLen, pEfuseHal->BTEfuseInitMap) == _FAIL)
|
if (rtw_BT_efuse_map_read(padapter, 0, mapLen, pEfuseHal->BTEfuseInitMap) == _FAIL) {
|
||||||
{
|
|
||||||
DBG_88E("%s: rtw_BT_efuse_map_read Fail!!\n", __func__);
|
DBG_88E("%s: rtw_BT_efuse_map_read Fail!!\n", __func__);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
// DBG_88E("OFFSET\tVALUE(hex)\n");
|
|
||||||
sprintf(extra, "\n");
|
sprintf(extra, "\n");
|
||||||
for (i=0; i<512; i+=16) // set 512 because the iwpriv's extra size have limit 0x7FF
|
for (i=0; i<512; i+=16) { // set 512 because the iwpriv's extra size have limit 0x7FF
|
||||||
{
|
|
||||||
// DBG_88E("0x%03x\t", i);
|
|
||||||
sprintf(extra, "%s0x%03x\t", extra, i);
|
|
||||||
for (j=0; j<8; j++) {
|
|
||||||
// DBG_88E("%02X ", pEfuseHal->BTEfuseInitMap[i+j]);
|
|
||||||
sprintf(extra, "%s%02X ", extra, pEfuseHal->BTEfuseInitMap[i+j]);
|
|
||||||
}
|
|
||||||
// DBG_88E("\t");
|
|
||||||
sprintf(extra,"%s\t",extra);
|
|
||||||
for (; j<16; j++) {
|
|
||||||
// DBG_88E("%02X ", pEfuseHal->BTEfuseInitMap[i+j]);
|
|
||||||
sprintf(extra, "%s%02X ", extra, pEfuseHal->BTEfuseInitMap[i+j]);
|
|
||||||
}
|
|
||||||
// DBG_88E("\n");
|
|
||||||
sprintf(extra, "%s\n", extra);
|
|
||||||
}
|
|
||||||
// DBG_88E("\n");
|
|
||||||
}
|
|
||||||
else if (strcmp(tmp[0],"btbmap") == 0)
|
|
||||||
{
|
|
||||||
mapLen = EFUSE_BT_MAX_MAP_LEN;
|
|
||||||
if (rtw_BT_efuse_map_read(padapter, 0, mapLen, pEfuseHal->BTEfuseInitMap) == _FAIL)
|
|
||||||
{
|
|
||||||
DBG_88E("%s: rtw_BT_efuse_map_read Fail!!\n", __func__);
|
|
||||||
err = -EFAULT;
|
|
||||||
goto exit;
|
|
||||||
}
|
|
||||||
|
|
||||||
// DBG_88E("OFFSET\tVALUE(hex)\n");
|
|
||||||
sprintf(extra, "\n");
|
|
||||||
for (i=512; i<1024 ; i+=16)
|
|
||||||
{
|
|
||||||
// DBG_88E("0x%03x\t", i);
|
|
||||||
sprintf(extra, "%s0x%03x\t", extra, i);
|
sprintf(extra, "%s0x%03x\t", extra, i);
|
||||||
for (j=0; j<8; j++)
|
for (j=0; j<8; j++)
|
||||||
{
|
|
||||||
// DBG_88E("%02X ", data[i+j]);
|
|
||||||
sprintf(extra, "%s%02X ", extra, pEfuseHal->BTEfuseInitMap[i+j]);
|
sprintf(extra, "%s%02X ", extra, pEfuseHal->BTEfuseInitMap[i+j]);
|
||||||
}
|
|
||||||
// DBG_88E("\t");
|
|
||||||
sprintf(extra,"%s\t",extra);
|
sprintf(extra,"%s\t",extra);
|
||||||
for (; j<16; j++) {
|
for (; j<16; j++)
|
||||||
// DBG_88E("%02X ", data[i+j]);
|
|
||||||
sprintf(extra, "%s%02X ", extra, pEfuseHal->BTEfuseInitMap[i+j]);
|
sprintf(extra, "%s%02X ", extra, pEfuseHal->BTEfuseInitMap[i+j]);
|
||||||
}
|
|
||||||
// DBG_88E("\n");
|
|
||||||
sprintf(extra, "%s\n", extra);
|
sprintf(extra, "%s\n", extra);
|
||||||
}
|
}
|
||||||
// DBG_88E("\n");
|
} else if (strcmp(tmp[0],"btbmap") == 0) {
|
||||||
|
mapLen = EFUSE_BT_MAX_MAP_LEN;
|
||||||
|
if (rtw_BT_efuse_map_read(padapter, 0, mapLen, pEfuseHal->BTEfuseInitMap) == _FAIL) {
|
||||||
|
DBG_88E("%s: rtw_BT_efuse_map_read Fail!!\n", __func__);
|
||||||
|
err = -EFAULT;
|
||||||
|
goto exit;
|
||||||
}
|
}
|
||||||
else if (strcmp(tmp[0],"btrmap") == 0)
|
|
||||||
{
|
sprintf(extra, "\n");
|
||||||
if ((tmp[1]==NULL) || (tmp[2]==NULL))
|
for (i=512; i<1024 ; i+=16) {
|
||||||
{
|
sprintf(extra, "%s0x%03x\t", extra, i);
|
||||||
|
for (j=0; j<8; j++)
|
||||||
|
sprintf(extra, "%s%02X ", extra, pEfuseHal->BTEfuseInitMap[i+j]);
|
||||||
|
sprintf(extra,"%s\t",extra);
|
||||||
|
for (; j<16; j++)
|
||||||
|
sprintf(extra, "%s%02X ", extra, pEfuseHal->BTEfuseInitMap[i+j]);
|
||||||
|
sprintf(extra, "%s\n", extra);
|
||||||
|
}
|
||||||
|
} else if (strcmp(tmp[0],"btrmap") == 0) {
|
||||||
|
if ((tmp[1]==NULL) || (tmp[2]==NULL)) {
|
||||||
err = -EINVAL;
|
err = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
@ -8950,8 +8845,7 @@ static int rtw_mp_efuse_get(struct net_device *dev,
|
||||||
DBG_88E("%s: addr=0x%X\n", __func__, addr);
|
DBG_88E("%s: addr=0x%X\n", __func__, addr);
|
||||||
|
|
||||||
cnts = simple_strtoul(tmp[2], &ptmp, 10);
|
cnts = simple_strtoul(tmp[2], &ptmp, 10);
|
||||||
if (cnts == 0)
|
if (cnts == 0) {
|
||||||
{
|
|
||||||
DBG_88E("%s: btrmap Fail!! cnts error!\n", __func__);
|
DBG_88E("%s: btrmap Fail!! cnts error!\n", __func__);
|
||||||
err = -EINVAL;
|
err = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
|
@ -9183,30 +9077,21 @@ static int rtw_mp_efuse_set(struct net_device *dev,
|
||||||
{
|
{
|
||||||
setdata[jj] = key_2char2num(tmp[2][kk], tmp[2][kk+1]);
|
setdata[jj] = key_2char2num(tmp[2][kk], tmp[2][kk+1]);
|
||||||
}
|
}
|
||||||
#ifndef CONFIG_RTL8188E
|
|
||||||
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_available_size, false);
|
|
||||||
#else
|
|
||||||
//Change to check TYPE_EFUSE_MAP_LEN ,beacuse 8188E raw 256,logic map over 256.
|
//Change to check TYPE_EFUSE_MAP_LEN ,beacuse 8188E raw 256,logic map over 256.
|
||||||
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_EFUSE_MAP_LEN, (void *)&max_available_size, false);
|
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_EFUSE_MAP_LEN, (void *)&max_available_size, false);
|
||||||
#endif
|
if ((addr+cnts) > max_available_size) {
|
||||||
if ((addr+cnts) > max_available_size)
|
|
||||||
{
|
|
||||||
DBG_88E("%s: addr(0x%X)+cnts(%d) parameter error!\n", __func__, addr, cnts);
|
DBG_88E("%s: addr(0x%X)+cnts(%d) parameter error!\n", __func__, addr, cnts);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rtw_efuse_map_write(padapter, addr, cnts, setdata) == _FAIL)
|
if (rtw_efuse_map_write(padapter, addr, cnts, setdata) == _FAIL) {
|
||||||
{
|
|
||||||
DBG_88E("%s: rtw_efuse_map_write error!!\n", __func__);
|
DBG_88E("%s: rtw_efuse_map_write error!!\n", __func__);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
}
|
} else if (strcmp(tmp[0], "wraw") == 0) {
|
||||||
else if (strcmp(tmp[0], "wraw") == 0)
|
if ((tmp[1]==NULL) || (tmp[2]==NULL)) {
|
||||||
{
|
|
||||||
if ((tmp[1]==NULL) || (tmp[2]==NULL))
|
|
||||||
{
|
|
||||||
err = -EINVAL;
|
err = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
@ -9215,14 +9100,12 @@ static int rtw_mp_efuse_set(struct net_device *dev,
|
||||||
addr &= 0xFFF;
|
addr &= 0xFFF;
|
||||||
|
|
||||||
cnts = strlen(tmp[2]);
|
cnts = strlen(tmp[2]);
|
||||||
if (cnts%2)
|
if (cnts%2) {
|
||||||
{
|
|
||||||
err = -EINVAL;
|
err = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
cnts /= 2;
|
cnts /= 2;
|
||||||
if (cnts == 0)
|
if (cnts == 0) {
|
||||||
{
|
|
||||||
err = -EINVAL;
|
err = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
@ -9231,8 +9114,7 @@ static int rtw_mp_efuse_set(struct net_device *dev,
|
||||||
DBG_88E("%s: cnts=%d\n", __func__, cnts);
|
DBG_88E("%s: cnts=%d\n", __func__, cnts);
|
||||||
DBG_88E("%s: raw data=%s\n", __func__, tmp[2]);
|
DBG_88E("%s: raw data=%s\n", __func__, tmp[2]);
|
||||||
|
|
||||||
for (jj=0, kk=0; jj<cnts; jj++, kk+=2)
|
for (jj=0, kk=0; jj<cnts; jj++, kk+=2) {
|
||||||
{
|
|
||||||
setrawdata[jj] = key_2char2num(tmp[2][kk], tmp[2][kk+1]);
|
setrawdata[jj] = key_2char2num(tmp[2][kk], tmp[2][kk+1]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -9252,49 +9134,19 @@ static int rtw_mp_efuse_set(struct net_device *dev,
|
||||||
}
|
}
|
||||||
|
|
||||||
//mac,00e04c871200
|
//mac,00e04c871200
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
addr = 0x16;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
addr = 0x19;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#ifdef CONFIG_SDIO_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_8723AS;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_GSPI_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_8723AS;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_USB_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_8723AU;
|
|
||||||
#endif
|
|
||||||
#endif // CONFIG_RTL8723A
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#ifdef CONFIG_USB_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_88EU;
|
addr = EEPROM_MAC_ADDR_88EU;
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_SDIO_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_88ES;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_PCI_HCI
|
|
||||||
addr = EEPROM_MAC_ADDR_88EE;
|
|
||||||
#endif
|
|
||||||
#endif //#ifdef CONFIG_RTL8188E
|
|
||||||
|
|
||||||
cnts = strlen(tmp[1]);
|
cnts = strlen(tmp[1]);
|
||||||
if (cnts%2)
|
if (cnts%2) {
|
||||||
{
|
|
||||||
err = -EINVAL;
|
err = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
cnts /= 2;
|
cnts /= 2;
|
||||||
if (cnts == 0)
|
if (cnts == 0) {
|
||||||
{
|
|
||||||
err = -EINVAL;
|
err = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
if (cnts > 6)
|
if (cnts > 6) {
|
||||||
{
|
|
||||||
DBG_88E("%s: error data for mac addr=\"%s\"\n", __func__, tmp[1]);
|
DBG_88E("%s: error data for mac addr=\"%s\"\n", __func__, tmp[1]);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
|
@ -9308,14 +9160,9 @@ static int rtw_mp_efuse_set(struct net_device *dev,
|
||||||
{
|
{
|
||||||
setdata[jj] = key_2char2num(tmp[1][kk], tmp[1][kk+1]);
|
setdata[jj] = key_2char2num(tmp[1][kk], tmp[1][kk+1]);
|
||||||
}
|
}
|
||||||
#ifndef CONFIG_RTL8188E
|
|
||||||
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_available_size, false);
|
|
||||||
#else
|
|
||||||
//Change to check TYPE_EFUSE_MAP_LEN ,beacuse 8188E raw 256,logic map over 256.
|
//Change to check TYPE_EFUSE_MAP_LEN ,beacuse 8188E raw 256,logic map over 256.
|
||||||
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_EFUSE_MAP_LEN, (void *)&max_available_size, false);
|
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_EFUSE_MAP_LEN, (void *)&max_available_size, false);
|
||||||
#endif
|
if ((addr+cnts) > max_available_size) {
|
||||||
if ((addr+cnts) > max_available_size)
|
|
||||||
{
|
|
||||||
DBG_88E("%s: addr(0x%X)+cnts(%d) parameter error!\n", __func__, addr, cnts);
|
DBG_88E("%s: addr(0x%X)+cnts(%d) parameter error!\n", __func__, addr, cnts);
|
||||||
err = -EFAULT;
|
err = -EFAULT;
|
||||||
goto exit;
|
goto exit;
|
||||||
|
@ -9337,23 +9184,7 @@ static int rtw_mp_efuse_set(struct net_device *dev,
|
||||||
}
|
}
|
||||||
|
|
||||||
// pidvid,da0b7881
|
// pidvid,da0b7881
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
addr = 0x0a;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
addr = 0x0c;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
addr = EEPROM_VID_8723AU;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
#ifdef CONFIG_USB_HCI
|
|
||||||
addr = EEPROM_VID_88EE;
|
addr = EEPROM_VID_88EE;
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_PCI_HCI
|
|
||||||
addr = EEPROM_VID_88EE;
|
|
||||||
#endif
|
|
||||||
#endif //#ifdef CONFIG_RTL8188E
|
|
||||||
cnts = strlen(tmp[1]);
|
cnts = strlen(tmp[1]);
|
||||||
if (cnts%2)
|
if (cnts%2)
|
||||||
{
|
{
|
||||||
|
@ -9905,13 +9736,7 @@ static int rtw_mp_start(struct net_device *dev,
|
||||||
u8 val8;
|
u8 val8;
|
||||||
PADAPTER padapter = rtw_netdev_priv(dev);
|
PADAPTER padapter = rtw_netdev_priv(dev);
|
||||||
|
|
||||||
if (padapter->registrypriv.mp_mode ==0)
|
if (padapter->registrypriv.mp_mode ==0) {
|
||||||
{
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
DBG_88E("_rtw_mp_xmit_priv for Download BT patch FW\n");
|
|
||||||
_rtw_mp_xmit_priv(&padapter->xmitpriv);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
padapter->registrypriv.mp_mode =1;
|
padapter->registrypriv.mp_mode =1;
|
||||||
|
|
||||||
rtw_pm_set_ips(padapter,IPS_NONE);
|
rtw_pm_set_ips(padapter,IPS_NONE);
|
||||||
|
@ -9938,13 +9763,7 @@ static int rtw_mp_stop(struct net_device *dev,
|
||||||
{
|
{
|
||||||
PADAPTER padapter = rtw_netdev_priv(dev);
|
PADAPTER padapter = rtw_netdev_priv(dev);
|
||||||
|
|
||||||
if (padapter->registrypriv.mp_mode ==1)
|
if (padapter->registrypriv.mp_mode ==1) {
|
||||||
{
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
DBG_88E("_rtw_mp_xmit_priv reinit for normal mode\n");
|
|
||||||
_rtw_mp_xmit_priv(&padapter->xmitpriv);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
MPT_DeInitAdapter(padapter);
|
MPT_DeInitAdapter(padapter);
|
||||||
padapter->registrypriv.mp_mode=0;
|
padapter->registrypriv.mp_mode=0;
|
||||||
}
|
}
|
||||||
|
@ -10440,15 +10259,7 @@ static int rtw_mp_thermal(struct net_device *dev,
|
||||||
u8 val;
|
u8 val;
|
||||||
u16 bwrite=1;
|
u16 bwrite=1;
|
||||||
|
|
||||||
#if defined(CONFIG_RTL8192C) || defined(CONFIG_RTL8192D)
|
|
||||||
u16 addr=EEPROM_THERMAL_METER;
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
u16 addr=EEPROM_THERMAL_METER_8723A;
|
|
||||||
#endif
|
|
||||||
#if defined(CONFIG_RTL8188E)
|
|
||||||
u16 addr=EEPROM_THERMAL_METER_88E;
|
u16 addr=EEPROM_THERMAL_METER_88E;
|
||||||
#endif
|
|
||||||
|
|
||||||
u16 cnt=1;
|
u16 cnt=1;
|
||||||
u16 max_available_size=0;
|
u16 max_available_size=0;
|
||||||
|
@ -10457,15 +10268,11 @@ static int rtw_mp_thermal(struct net_device *dev,
|
||||||
if (copy_from_user(extra, wrqu->pointer, wrqu->length))
|
if (copy_from_user(extra, wrqu->pointer, wrqu->length))
|
||||||
return -EFAULT;
|
return -EFAULT;
|
||||||
|
|
||||||
//DBG_88E("print extra %s\n",extra);
|
|
||||||
|
|
||||||
bwrite = strncmp(extra, "write", 6); // strncmp TRUE is 0
|
bwrite = strncmp(extra, "write", 6); // strncmp TRUE is 0
|
||||||
|
|
||||||
Hal_GetThermalMeter(padapter, &val);
|
Hal_GetThermalMeter(padapter, &val);
|
||||||
|
|
||||||
if (bwrite == 0)
|
if (bwrite == 0) {
|
||||||
{
|
|
||||||
//DBG_88E("to write val:%d",val);
|
|
||||||
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_available_size, false);
|
EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI, TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_available_size, false);
|
||||||
if (2 > max_available_size)
|
if (2 > max_available_size)
|
||||||
{
|
{
|
||||||
|
@ -10556,19 +10363,14 @@ static int rtw_mp_dump(struct net_device *dev,
|
||||||
else
|
else
|
||||||
path_nums = 2;
|
path_nums = 2;
|
||||||
|
|
||||||
for (path=0;path<path_nums;path++)
|
for (path=0;path<path_nums;path++) {
|
||||||
{
|
for (i = 0; i < 0x34; i++) {
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
for (i = 0; i < 0x50; i++)
|
|
||||||
#else
|
|
||||||
for (i = 0; i < 0x34; i++)
|
|
||||||
#endif
|
|
||||||
{
|
|
||||||
//value = PHY_QueryRFReg(padapter, (RF_RADIO_PATH_E)path,i, bMaskDWord);
|
|
||||||
value = rtw_hal_read_rfreg(padapter, path, i, 0xffffffff);
|
value = rtw_hal_read_rfreg(padapter, path, i, 0xffffffff);
|
||||||
if (j%4==1) DBG_88E("0x%02x ",i);
|
if (j%4 == 1)
|
||||||
|
DBG_88E("0x%02x ",i);
|
||||||
DBG_88E(" 0x%08x ",value);
|
DBG_88E(" 0x%08x ",value);
|
||||||
if ((j++)%4==0) DBG_88E("\n");
|
if ((j++)%4 == 0)
|
||||||
|
DBG_88E("\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -10593,15 +10395,10 @@ static int rtw_mp_phypara(struct net_device *dev,
|
||||||
|
|
||||||
if (!IS_HARDWARE_TYPE_8192D(padapter))
|
if (!IS_HARDWARE_TYPE_8192D(padapter))
|
||||||
return 0;
|
return 0;
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
Hal_ProSetCrystalCap(padapter , valxcap);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
sprintf(extra, "Set xcap=%d",valxcap);
|
sprintf(extra, "Set xcap=%d",valxcap);
|
||||||
wrqu->length = strlen(extra) + 1;
|
wrqu->length = strlen(extra) + 1;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int rtw_mp_SetRFPath(struct net_device *dev,
|
static int rtw_mp_SetRFPath(struct net_device *dev,
|
||||||
|
@ -10673,161 +10470,6 @@ static int rtw_mp_antBdiff(struct net_device *dev,
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
|
|
||||||
/* update Tx AGC offset */
|
|
||||||
static int rtw_mp_SetBT(struct net_device *dev,
|
|
||||||
struct iw_request_info *info,
|
|
||||||
union iwreq_data *wrqu, char *extra)
|
|
||||||
{
|
|
||||||
PADAPTER padapter = rtw_netdev_priv(dev);
|
|
||||||
BT_REQ_CMD BtReq;
|
|
||||||
PMPT_CONTEXT pMptCtx=&(padapter->mppriv.MptCtx);
|
|
||||||
PBT_RSP_CMD pBtRsp=(PBT_RSP_CMD)&pMptCtx->mptOutBuf[0];
|
|
||||||
char input[128];
|
|
||||||
char *pch, *ptmp, *token, *tmp[2]={0x00,0x00};
|
|
||||||
u8 setdata[100];
|
|
||||||
|
|
||||||
u16 testmode=1,ready=1,trxparam=1,setgen=1,getgen=1,testctrl=1,testbt=1;
|
|
||||||
u32 i,ii,jj,kk,cnts,status;
|
|
||||||
|
|
||||||
if (copy_from_user(extra, wrqu->data.pointer, wrqu->data.length))
|
|
||||||
return -EFAULT;
|
|
||||||
if (strlen(extra)<1) return -EFAULT;
|
|
||||||
|
|
||||||
DBG_88E("%s:iwpriv in=%s\n", __func__, extra);
|
|
||||||
ready = strncmp(extra, "ready", 5);
|
|
||||||
testmode = strncmp(extra, "testmode", 8); // strncmp TRUE is 0
|
|
||||||
trxparam = strncmp(extra, "trxparam", 8);
|
|
||||||
setgen = strncmp(extra, "setgen", 6);
|
|
||||||
getgen = strncmp(extra, "getgen", 6);
|
|
||||||
testctrl = strncmp(extra, "testctrl", 8);
|
|
||||||
testbt = strncmp(extra, "testbt", 6);
|
|
||||||
|
|
||||||
if (strncmp(extra, "dlfw", 4) == 0)
|
|
||||||
{
|
|
||||||
status = rtl8723a_FirmwareDownload(padapter);
|
|
||||||
if (status==_SUCCESS)
|
|
||||||
{
|
|
||||||
_rtw_memset(extra,'\0', wrqu->data.length);
|
|
||||||
DBG_88E("%s: download FW %s\n", __func__, (_FAIL==status) ? "FAIL!":"OK.");
|
|
||||||
sprintf(extra, "download FW %s", (_FAIL==status) ? "FAIL!":"OK.");
|
|
||||||
wrqu->data.length = strlen(extra) + 1;
|
|
||||||
}
|
|
||||||
goto exit;
|
|
||||||
}
|
|
||||||
if (testbt==0)
|
|
||||||
{
|
|
||||||
BtReq.opCodeVer=1;
|
|
||||||
BtReq.OpCode=6;
|
|
||||||
BtReq.paraLength=cnts/2;
|
|
||||||
goto todo;
|
|
||||||
}
|
|
||||||
if (ready==0)
|
|
||||||
{
|
|
||||||
BtReq.opCodeVer=1;
|
|
||||||
BtReq.OpCode=0;
|
|
||||||
BtReq.paraLength=0;
|
|
||||||
goto todo;
|
|
||||||
}
|
|
||||||
|
|
||||||
DBG_88E("%s:after strncmp\n", __func__);
|
|
||||||
pch = extra;
|
|
||||||
i = 0;
|
|
||||||
while ((token = strsep(&pch, ",")) != NULL)
|
|
||||||
{
|
|
||||||
if (i > 1) break;
|
|
||||||
tmp[i] = token;
|
|
||||||
i++;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((tmp[0]==NULL) && (tmp[1]==NULL))
|
|
||||||
{
|
|
||||||
return -EFAULT;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
cnts = strlen(tmp[1]);
|
|
||||||
if (cnts<1) return -EFAULT;
|
|
||||||
|
|
||||||
DBG_88E("%s: cnts=%d\n", __func__, cnts);
|
|
||||||
DBG_88E("%s: data=%s\n", __func__, tmp[1]);
|
|
||||||
|
|
||||||
for (jj=0, kk=0; jj<cnts; jj++, kk+=2)
|
|
||||||
{
|
|
||||||
BtReq.pParamStart[jj] = key_2char2num(tmp[1][kk], tmp[1][kk+1]);
|
|
||||||
DBG_88E("BtReq.pParamStart[%d]=%x\n",ii,BtReq.pParamStart[jj]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (testmode==0)
|
|
||||||
{
|
|
||||||
BtReq.opCodeVer=1;
|
|
||||||
BtReq.OpCode=1;
|
|
||||||
BtReq.paraLength=1;
|
|
||||||
}
|
|
||||||
if (trxparam==0)
|
|
||||||
{
|
|
||||||
BtReq.opCodeVer=1;
|
|
||||||
BtReq.OpCode=2;
|
|
||||||
BtReq.paraLength=cnts/2;
|
|
||||||
}
|
|
||||||
if (setgen==0)
|
|
||||||
{
|
|
||||||
DBG_88E("%s: BT_SET_GENERAL\n", __func__);
|
|
||||||
BtReq.opCodeVer=1;
|
|
||||||
BtReq.OpCode=3; //BT_SET_GENERAL 3
|
|
||||||
BtReq.paraLength=cnts/2;
|
|
||||||
}
|
|
||||||
if (getgen==0)
|
|
||||||
{
|
|
||||||
DBG_88E("%s: BT_GET_GENERAL\n", __func__);
|
|
||||||
BtReq.opCodeVer=1;
|
|
||||||
BtReq.OpCode=4; //BT_GET_GENERAL 4
|
|
||||||
BtReq.paraLength=cnts/2;
|
|
||||||
}
|
|
||||||
if (testctrl==0)
|
|
||||||
{
|
|
||||||
DBG_88E("%s: BT_TEST_CTRL\n", __func__);
|
|
||||||
BtReq.opCodeVer=1;
|
|
||||||
BtReq.OpCode=5; //BT_TEST_CTRL 5
|
|
||||||
BtReq.paraLength=cnts/2;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
DBG_88E("%s: BtReq.paraLength =%d\n", __func__, BtReq.paraLength);
|
|
||||||
|
|
||||||
DBG_88E("opCodeVer=%d,OpCode=%d\n",BtReq.opCodeVer,BtReq.OpCode);
|
|
||||||
|
|
||||||
if (BtReq.paraLength<1)
|
|
||||||
goto todo;
|
|
||||||
|
|
||||||
for (i=0;i<BtReq.paraLength;i++)
|
|
||||||
{
|
|
||||||
DBG_88E("%s: BtReq.pParamStart[ %d ] = 0x%02x\n", __func__,i,BtReq.pParamStart[i]);
|
|
||||||
}
|
|
||||||
|
|
||||||
todo:
|
|
||||||
_rtw_memset(extra,'\0', wrqu->data.length);
|
|
||||||
|
|
||||||
mptbt_BtControlProcess(padapter,&BtReq);
|
|
||||||
|
|
||||||
for (i=4; i<pMptCtx->mptOutLen; i++)
|
|
||||||
{
|
|
||||||
DBG_88E("0x%x ", pMptCtx->mptOutBuf[i]);
|
|
||||||
sprintf(extra, "%s 0x%x ", extra, pMptCtx->mptOutBuf[i]);
|
|
||||||
}
|
|
||||||
|
|
||||||
exit:
|
|
||||||
wrqu->data.length = strlen(extra) + 1;
|
|
||||||
|
|
||||||
return status;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif //#ifdef CONFIG_RTL8723A
|
|
||||||
|
|
||||||
static int rtw_mp_set(struct net_device *dev,
|
static int rtw_mp_set(struct net_device *dev,
|
||||||
struct iw_request_info *info,
|
struct iw_request_info *info,
|
||||||
union iwreq_data *wdata, char *extra)
|
union iwreq_data *wdata, char *extra)
|
||||||
|
@ -11002,13 +10644,6 @@ static int rtw_mp_get(struct net_device *dev,
|
||||||
DBG_88E("set case efuse set\n");
|
DBG_88E("set case efuse set\n");
|
||||||
rtw_mp_efuse_set (dev,info,wdata,extra);
|
rtw_mp_efuse_set (dev,info,wdata,extra);
|
||||||
break;
|
break;
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
case MP_SetBT:
|
|
||||||
DBG_88E("set MP_SetBT\n");
|
|
||||||
rtw_mp_SetBT (dev,info,wdata,extra);
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
rtw_msleep_os(10); //delay 5ms for sending pkt before exit adb shell operation
|
rtw_msleep_os(10); //delay 5ms for sending pkt before exit adb shell operation
|
||||||
|
@ -11702,29 +11337,11 @@ static int rtw_widi_set_probe_request(struct net_device *dev,
|
||||||
}
|
}
|
||||||
#endif // CONFIG_INTEL_WIDI
|
#endif // CONFIG_INTEL_WIDI
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
#include <rtl8723a_hal.h>
|
|
||||||
//extern u8 _InitPowerOn(PADAPTER padapter);
|
|
||||||
//extern s32 rtl8723a_FirmwareDownload(PADAPTER padapter);
|
|
||||||
extern s32 FillH2CCmd(PADAPTER padapter, u8 ElementID, u32 CmdLen, u8 *pCmdBuffer);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_MAC_LOOPBACK_DRIVER
|
#ifdef CONFIG_MAC_LOOPBACK_DRIVER
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
extern void rtl8723a_cal_txdesc_chksum(struct tx_desc *ptxdesc);
|
|
||||||
#define cal_txdesc_chksum rtl8723a_cal_txdesc_chksum
|
|
||||||
extern void rtl8723a_fill_default_txdesc(struct xmit_frame *pxmitframe, u8 *pbuf);
|
|
||||||
#define fill_default_txdesc rtl8723a_fill_default_txdesc
|
|
||||||
#elif defined(CONFIG_RTL8188E)
|
|
||||||
#include <rtl8188e_hal.h>
|
#include <rtl8188e_hal.h>
|
||||||
extern void rtl8188e_cal_txdesc_chksum(struct tx_desc *ptxdesc);
|
extern void rtl8188e_cal_txdesc_chksum(struct tx_desc *ptxdesc);
|
||||||
#define cal_txdesc_chksum rtl8188e_cal_txdesc_chksum
|
#define cal_txdesc_chksum rtl8188e_cal_txdesc_chksum
|
||||||
#ifdef CONFIG_SDIO_HCI
|
|
||||||
extern void rtl8188es_fill_default_txdesc(struct xmit_frame *pxmitframe, u8 *pbuf);
|
|
||||||
#define fill_default_txdesc rtl8188es_fill_default_txdesc
|
|
||||||
#endif // CONFIG_SDIO_HCI
|
|
||||||
#endif // CONFIG_RTL8188E
|
|
||||||
|
|
||||||
static s32 initLoopback(PADAPTER padapter)
|
static s32 initLoopback(PADAPTER padapter)
|
||||||
{
|
{
|
||||||
|
@ -12302,88 +11919,6 @@ static int rtw_test(
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
|
|
||||||
#ifdef CONFIG_BT_COEXIST
|
|
||||||
#define GET_BT_INFO(padapter) (&GET_HAL_DATA(padapter)->BtInfo)
|
|
||||||
|
|
||||||
if (strcmp(pch, "btdbg") == 0)
|
|
||||||
{
|
|
||||||
DBG_88E("===== BT debug information Start =====\n");
|
|
||||||
DBG_88E("WIFI status=\n");
|
|
||||||
DBG_88E("BT status=\n");
|
|
||||||
DBG_88E("BT profile=\n");
|
|
||||||
DBG_88E("WIFI RSSI=%d\n", GET_HAL_DATA(padapter)->dmpriv.UndecoratedSmoothedPWDB);
|
|
||||||
DBG_88E("BT RSSI=\n");
|
|
||||||
DBG_88E("coex mechanism=\n");
|
|
||||||
DBG_88E("BT counter TX/RX=/\n");
|
|
||||||
DBG_88E("0x880=0x%08x\n", rtw_read32(padapter, 0x880));
|
|
||||||
DBG_88E("0x6c0=0x%08x\n", rtw_read32(padapter, 0x6c0));
|
|
||||||
DBG_88E("0x6c4=0x%08x\n", rtw_read32(padapter, 0x6c4));
|
|
||||||
DBG_88E("0x6c8=0x%08x\n", rtw_read32(padapter, 0x6c8));
|
|
||||||
DBG_88E("0x6cc=0x%08x\n", rtw_read32(padapter, 0x6cc));
|
|
||||||
DBG_88E("0x778=0x%08x\n", rtw_read32(padapter, 0x778));
|
|
||||||
DBG_88E("0xc50=0x%08x\n", rtw_read32(padapter, 0xc50));
|
|
||||||
BT_DisplayBtCoexInfo(padapter);
|
|
||||||
DBG_88E("===== BT debug information End =====\n");
|
|
||||||
}
|
|
||||||
|
|
||||||
if (strcmp(pch, "bton") == 0)
|
|
||||||
{
|
|
||||||
PBT30Info pBTInfo = GET_BT_INFO(padapter);
|
|
||||||
PBT_MGNT pBtMgnt = &pBTInfo->BtMgnt;
|
|
||||||
|
|
||||||
pBtMgnt->ExtConfig.bManualControl = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (strcmp(pch, "btoff") == 0)
|
|
||||||
{
|
|
||||||
PBT30Info pBTInfo = GET_BT_INFO(padapter);
|
|
||||||
PBT_MGNT pBtMgnt = &pBTInfo->BtMgnt;
|
|
||||||
|
|
||||||
pBtMgnt->ExtConfig.bManualControl = true;
|
|
||||||
}
|
|
||||||
#endif // CONFIG_BT_COEXIST
|
|
||||||
|
|
||||||
if (strcmp(pch, "h2c") == 0)
|
|
||||||
{
|
|
||||||
u8 param[6];
|
|
||||||
u8 count = 0;
|
|
||||||
u32 tmp;
|
|
||||||
u8 i;
|
|
||||||
u32 pos;
|
|
||||||
s32 ret;
|
|
||||||
|
|
||||||
|
|
||||||
do {
|
|
||||||
pch = strsep(&ptmp, delim);
|
|
||||||
if ((pch == NULL) || (strlen(pch) == 0))
|
|
||||||
break;
|
|
||||||
|
|
||||||
sscanf(pch, "%x", &tmp);
|
|
||||||
param[count++] = (u8)tmp;
|
|
||||||
} while (count < 6);
|
|
||||||
|
|
||||||
if (count == 0) {
|
|
||||||
rtw_mfree(pbuf, len);
|
|
||||||
DBG_88E("%s: parameter error(level 2)!\n", __func__);
|
|
||||||
return -EFAULT;
|
|
||||||
}
|
|
||||||
|
|
||||||
ret = FillH2CCmd(padapter, param[0], count-1, ¶m[1]);
|
|
||||||
|
|
||||||
pos = sprintf(extra, "H2C ID=%x content=", param[0]);
|
|
||||||
for (i=0; i<count; i++) {
|
|
||||||
pos += sprintf(extra+pos, "%x,", param[i]);
|
|
||||||
}
|
|
||||||
extra[pos] = 0;
|
|
||||||
pos--;
|
|
||||||
pos += sprintf(extra+pos, " %s", ret==_FAIL?"FAIL":"OK");
|
|
||||||
|
|
||||||
wrqu->data.length = strlen(extra) + 1;
|
|
||||||
}
|
|
||||||
#endif // CONFIG_RTL8723A
|
|
||||||
|
|
||||||
rtw_mfree(pbuf, len);
|
rtw_mfree(pbuf, len);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -12587,9 +12122,6 @@ static const struct iw_priv_args rtw_private_args[] = {
|
||||||
{ MP_QueryDrvStats, IW_PRIV_TYPE_CHAR | 1024, IW_PRIV_TYPE_CHAR | IW_PRIV_SIZE_MASK, "mp_drvquery" },
|
{ MP_QueryDrvStats, IW_PRIV_TYPE_CHAR | 1024, IW_PRIV_TYPE_CHAR | IW_PRIV_SIZE_MASK, "mp_drvquery" },
|
||||||
{ MP_IOCTL, IW_PRIV_TYPE_CHAR | 1024, 0, "mp_ioctl"}, // mp_ioctl
|
{ MP_IOCTL, IW_PRIV_TYPE_CHAR | 1024, 0, "mp_ioctl"}, // mp_ioctl
|
||||||
{ MP_SetRFPathSwh, IW_PRIV_TYPE_CHAR | 1024, 0, "mp_setrfpath" },
|
{ MP_SetRFPathSwh, IW_PRIV_TYPE_CHAR | 1024, 0, "mp_setrfpath" },
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
{ MP_SetBT, IW_PRIV_TYPE_CHAR | 1024, IW_PRIV_TYPE_CHAR | IW_PRIV_SIZE_MASK, "mp_setbt" },
|
|
||||||
#endif
|
|
||||||
{ CTA_TEST, IW_PRIV_TYPE_CHAR | 1024, 0, "cta_test"},
|
{ CTA_TEST, IW_PRIV_TYPE_CHAR | 1024, 0, "cta_test"},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -251,22 +251,12 @@ static void rtw_dev_remove(struct usb_interface *pusb_intf);
|
||||||
/****** 8188EUS ********/ \
|
/****** 8188EUS ********/ \
|
||||||
{USB_DEVICE(0x8179, 0x07B8)}, /* Abocom - Abocom */
|
{USB_DEVICE(0x8179, 0x07B8)}, /* Abocom - Abocom */
|
||||||
|
|
||||||
#ifndef CONFIG_RTL8192C
|
|
||||||
#undef RTL8192C_USB_IDS
|
#undef RTL8192C_USB_IDS
|
||||||
#define RTL8192C_USB_IDS
|
#define RTL8192C_USB_IDS
|
||||||
#endif
|
|
||||||
#ifndef CONFIG_RTL8192D
|
|
||||||
#undef RTL8192D_USB_IDS
|
#undef RTL8192D_USB_IDS
|
||||||
#define RTL8192D_USB_IDS
|
#define RTL8192D_USB_IDS
|
||||||
#endif
|
|
||||||
#ifndef CONFIG_RTL8723A
|
|
||||||
#undef RTL8723A_USB_IDS
|
#undef RTL8723A_USB_IDS
|
||||||
#define RTL8723A_USB_IDS
|
#define RTL8723A_USB_IDS
|
||||||
#endif
|
|
||||||
#ifndef CONFIG_RTL8188E
|
|
||||||
#undef RTL8188E_USB_IDS
|
|
||||||
#define RTL8188E_USB_IDS
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static struct usb_device_id rtw_usb_id_tbl[] ={
|
static struct usb_device_id rtw_usb_id_tbl[] ={
|
||||||
RTL8192C_USB_IDS
|
RTL8192C_USB_IDS
|
||||||
|
@ -305,78 +295,6 @@ struct rtw_usb_drv {
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192C
|
|
||||||
static struct usb_device_id rtl8192c_usb_id_tbl[] ={
|
|
||||||
RTL8192C_USB_IDS
|
|
||||||
{} /* Terminating entry */
|
|
||||||
};
|
|
||||||
|
|
||||||
struct rtw_usb_drv rtl8192c_usb_drv = {
|
|
||||||
.usbdrv.name = (char*)"rtl8192cu",
|
|
||||||
.usbdrv.probe = rtw_drv_init,
|
|
||||||
.usbdrv.disconnect = rtw_dev_remove,
|
|
||||||
.usbdrv.id_table = rtl8192c_usb_id_tbl,
|
|
||||||
.usbdrv.suspend = rtw_suspend,
|
|
||||||
.usbdrv.resume = rtw_resume,
|
|
||||||
#if (LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 22))
|
|
||||||
.usbdrv.reset_resume = rtw_resume,
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_AUTOSUSPEND
|
|
||||||
.usbdrv.supports_autosuspend = 1,
|
|
||||||
#endif
|
|
||||||
};
|
|
||||||
|
|
||||||
static struct rtw_usb_drv *usb_drv = &rtl8192c_usb_drv;
|
|
||||||
#endif /* CONFIG_RTL8192C */
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8192D
|
|
||||||
static struct usb_device_id rtl8192d_usb_id_tbl[] ={
|
|
||||||
RTL8192D_USB_IDS
|
|
||||||
{} /* Terminating entry */
|
|
||||||
};
|
|
||||||
|
|
||||||
struct rtw_usb_drv rtl8192d_usb_drv = {
|
|
||||||
.usbdrv.name = (char*)"rtl8192du",
|
|
||||||
.usbdrv.probe = rtw_drv_init,
|
|
||||||
.usbdrv.disconnect = rtw_dev_remove,
|
|
||||||
.usbdrv.id_table = rtl8192d_usb_id_tbl,
|
|
||||||
.usbdrv.suspend = rtw_suspend,
|
|
||||||
.usbdrv.resume = rtw_resume,
|
|
||||||
#if (LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 22))
|
|
||||||
.usbdrv.reset_resume = rtw_resume,
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_AUTOSUSPEND
|
|
||||||
.usbdrv.supports_autosuspend = 1,
|
|
||||||
#endif
|
|
||||||
};
|
|
||||||
static struct rtw_usb_drv *usb_drv = &rtl8192d_usb_drv;
|
|
||||||
#endif /* CONFIG_RTL8192D */
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8723A
|
|
||||||
static struct usb_device_id rtl8723a_usb_id_tbl[] ={
|
|
||||||
RTL8723A_USB_IDS
|
|
||||||
{} /* Terminating entry */
|
|
||||||
};
|
|
||||||
|
|
||||||
struct rtw_usb_drv rtl8723a_usb_drv = {
|
|
||||||
.usbdrv.name = (char*)"rtl8723au",
|
|
||||||
.usbdrv.probe = rtw_drv_init,
|
|
||||||
.usbdrv.disconnect = rtw_dev_remove,
|
|
||||||
.usbdrv.id_table = rtl8723a_usb_id_tbl,
|
|
||||||
.usbdrv.suspend = rtw_suspend,
|
|
||||||
.usbdrv.resume = rtw_resume,
|
|
||||||
#if (LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 22))
|
|
||||||
.usbdrv.reset_resume = rtw_resume,
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_AUTOSUSPEND
|
|
||||||
.usbdrv.supports_autosuspend = 1,
|
|
||||||
#endif
|
|
||||||
};
|
|
||||||
|
|
||||||
static struct rtw_usb_drv *usb_drv = &rtl8723a_usb_drv;
|
|
||||||
#endif /* CONFIG_RTL8723A */
|
|
||||||
|
|
||||||
#ifdef CONFIG_RTL8188E
|
|
||||||
static struct usb_device_id rtl8188e_usb_id_tbl[] ={
|
static struct usb_device_id rtl8188e_usb_id_tbl[] ={
|
||||||
RTL8188E_USB_IDS
|
RTL8188E_USB_IDS
|
||||||
{} /* Terminating entry */
|
{} /* Terminating entry */
|
||||||
|
@ -398,7 +316,6 @@ struct rtw_usb_drv rtl8188e_usb_drv = {
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct rtw_usb_drv *usb_drv = &rtl8188e_usb_drv;
|
static struct rtw_usb_drv *usb_drv = &rtl8188e_usb_drv;
|
||||||
#endif /* CONFIG_RTL8188E */
|
|
||||||
|
|
||||||
static inline int RT_usb_endpoint_dir_in(const struct usb_endpoint_descriptor *epd)
|
static inline int RT_usb_endpoint_dir_in(const struct usb_endpoint_descriptor *epd)
|
||||||
{
|
{
|
||||||
|
@ -1813,7 +1730,6 @@ static int __init rtw_drv_entry(void)
|
||||||
writel(tmp,(volatile unsigned int*)0xb801a608);//write dummy register for 1055
|
writel(tmp,(volatile unsigned int*)0xb801a608);//write dummy register for 1055
|
||||||
#endif
|
#endif
|
||||||
#ifdef CONFIG_PLATFORM_ARM_SUNxI
|
#ifdef CONFIG_PLATFORM_ARM_SUNxI
|
||||||
#ifndef CONFIG_RTL8723A
|
|
||||||
int ret = 0;
|
int ret = 0;
|
||||||
/* ----------get usb_wifi_usbc_num------------- */
|
/* ----------get usb_wifi_usbc_num------------- */
|
||||||
ret = script_parser_fetch("usb_wifi_para", "usb_wifi_usbc_num", (int *)&usb_wifi_host, 64);
|
ret = script_parser_fetch("usb_wifi_para", "usb_wifi_usbc_num", (int *)&usb_wifi_host, 64);
|
||||||
|
@ -1824,7 +1740,6 @@ static int __init rtw_drv_entry(void)
|
||||||
}
|
}
|
||||||
DBG_88E("sw_usb_enable_hcd: usbc_num = %d\n", usb_wifi_host);
|
DBG_88E("sw_usb_enable_hcd: usbc_num = %d\n", usb_wifi_host);
|
||||||
sw_usb_enable_hcd(usb_wifi_host);
|
sw_usb_enable_hcd(usb_wifi_host);
|
||||||
#endif //CONFIG_RTL8723A
|
|
||||||
#endif //CONFIG_PLATFORM_ARM_SUNxI
|
#endif //CONFIG_PLATFORM_ARM_SUNxI
|
||||||
|
|
||||||
|
|
||||||
|
@ -1868,10 +1783,8 @@ static void __exit rtw_drv_halt(void)
|
||||||
_rtw_mutex_free(&usb_drv->setbw_mutex);
|
_rtw_mutex_free(&usb_drv->setbw_mutex);
|
||||||
#endif
|
#endif
|
||||||
#ifdef CONFIG_PLATFORM_ARM_SUNxI
|
#ifdef CONFIG_PLATFORM_ARM_SUNxI
|
||||||
#ifndef CONFIG_RTL8723A
|
|
||||||
DBG_88E("sw_usb_disable_hcd: usbc_num = %d\n", usb_wifi_host);
|
DBG_88E("sw_usb_disable_hcd: usbc_num = %d\n", usb_wifi_host);
|
||||||
sw_usb_disable_hcd(usb_wifi_host);
|
sw_usb_disable_hcd(usb_wifi_host);
|
||||||
#endif //ifndef CONFIG_RTL8723A
|
|
||||||
#endif //CONFIG_PLATFORM_ARM_SUNxI
|
#endif //CONFIG_PLATFORM_ARM_SUNxI
|
||||||
|
|
||||||
DBG_88E("-rtw_drv_halt\n");
|
DBG_88E("-rtw_drv_halt\n");
|
||||||
|
|
Loading…
Reference in a new issue