summaryrefslogtreecommitdiff
path: root/drivers/staging/rtl8723bs/hal/HalBtc8723b1Ant.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/staging/rtl8723bs/hal/HalBtc8723b1Ant.c')
-rw-r--r--drivers/staging/rtl8723bs/hal/HalBtc8723b1Ant.c258
1 files changed, 128 insertions, 130 deletions
diff --git a/drivers/staging/rtl8723bs/hal/HalBtc8723b1Ant.c b/drivers/staging/rtl8723bs/hal/HalBtc8723b1Ant.c
index c60e8c58d9cc..503790924532 100644
--- a/drivers/staging/rtl8723bs/hal/HalBtc8723b1Ant.c
+++ b/drivers/staging/rtl8723bs/hal/HalBtc8723b1Ant.c
@@ -8,10 +8,10 @@
#include "Mp_Precomp.h"
/* Global variables, these are static variables */
-static COEX_DM_8723B_1ANT GLCoexDm8723b1Ant;
-static PCOEX_DM_8723B_1ANT pCoexDm = &GLCoexDm8723b1Ant;
-static COEX_STA_8723B_1ANT GLCoexSta8723b1Ant;
-static PCOEX_STA_8723B_1ANT pCoexSta = &GLCoexSta8723b1Ant;
+static struct coex_dm_8723b_1ant GLCoexDm8723b1Ant;
+static struct coex_dm_8723b_1ant *pCoexDm = &GLCoexDm8723b1Ant;
+static struct coex_sta_8723b_1ant GLCoexSta8723b1Ant;
+static struct coex_sta_8723b_1ant *pCoexSta = &GLCoexSta8723b1Ant;
static const char *const GLBtInfoSrc8723b1Ant[] = {
"BT Info[wifi fw]",
@@ -38,7 +38,7 @@ static u8 halbtc8723b1ant_BtRssiState(
(pCoexSta->preBtRssiState == BTC_RSSI_STATE_LOW) ||
(pCoexSta->preBtRssiState == BTC_RSSI_STATE_STAY_LOW)
) {
- if (btRssi >= (rssiThresh+BTC_RSSI_COEX_THRESH_TOL_8723B_1ANT)) {
+ if (btRssi >= (rssiThresh + BTC_RSSI_COEX_THRESH_TOL_8723B_1ANT)) {
btRssiState = BTC_RSSI_STATE_HIGH;
BTC_PRINT(
@@ -85,7 +85,7 @@ static u8 halbtc8723b1ant_BtRssiState(
(pCoexSta->preBtRssiState == BTC_RSSI_STATE_LOW) ||
(pCoexSta->preBtRssiState == BTC_RSSI_STATE_STAY_LOW)
) {
- if (btRssi >= (rssiThresh+BTC_RSSI_COEX_THRESH_TOL_8723B_1ANT)) {
+ if (btRssi >= (rssiThresh + BTC_RSSI_COEX_THRESH_TOL_8723B_1ANT)) {
btRssiState = BTC_RSSI_STATE_MEDIUM;
BTC_PRINT(
BTC_MSG_ALGORITHM,
@@ -104,7 +104,7 @@ static u8 halbtc8723b1ant_BtRssiState(
(pCoexSta->preBtRssiState == BTC_RSSI_STATE_MEDIUM) ||
(pCoexSta->preBtRssiState == BTC_RSSI_STATE_STAY_MEDIUM)
) {
- if (btRssi >= (rssiThresh1+BTC_RSSI_COEX_THRESH_TOL_8723B_1ANT)) {
+ if (btRssi >= (rssiThresh1 + BTC_RSSI_COEX_THRESH_TOL_8723B_1ANT)) {
btRssiState = BTC_RSSI_STATE_HIGH;
BTC_PRINT(
BTC_MSG_ALGORITHM,
@@ -151,7 +151,7 @@ static u8 halbtc8723b1ant_BtRssiState(
}
static void halbtc8723b1ant_UpdateRaMask(
- PBTC_COEXIST pBtCoexist, bool bForceExec, u32 disRateMask
+ struct btc_coexist *pBtCoexist, bool bForceExec, u32 disRateMask
)
{
pCoexDm->curRaMask = disRateMask;
@@ -166,7 +166,7 @@ static void halbtc8723b1ant_UpdateRaMask(
}
static void halbtc8723b1ant_AutoRateFallbackRetry(
- PBTC_COEXIST pBtCoexist, bool bForceExec, u8 type
+ struct btc_coexist *pBtCoexist, bool bForceExec, u8 type
)
{
bool bWifiUnderBMode = false;
@@ -204,7 +204,7 @@ static void halbtc8723b1ant_AutoRateFallbackRetry(
}
static void halbtc8723b1ant_RetryLimit(
- PBTC_COEXIST pBtCoexist, bool bForceExec, u8 type
+ struct btc_coexist *pBtCoexist, bool bForceExec, u8 type
)
{
pCoexDm->curRetryLimitType = type;
@@ -231,7 +231,7 @@ static void halbtc8723b1ant_RetryLimit(
}
static void halbtc8723b1ant_AmpduMaxTime(
- PBTC_COEXIST pBtCoexist, bool bForceExec, u8 type
+ struct btc_coexist *pBtCoexist, bool bForceExec, u8 type
)
{
pCoexDm->curAmpduTimeType = type;
@@ -257,7 +257,7 @@ static void halbtc8723b1ant_AmpduMaxTime(
}
static void halbtc8723b1ant_LimitedTx(
- PBTC_COEXIST pBtCoexist,
+ struct btc_coexist *pBtCoexist,
bool bForceExec,
u8 raMaskType,
u8 arfrType,
@@ -285,7 +285,7 @@ static void halbtc8723b1ant_LimitedTx(
}
static void halbtc8723b1ant_LimitedRx(
- PBTC_COEXIST pBtCoexist,
+ struct btc_coexist *pBtCoexist,
bool bForceExec,
bool bRejApAggPkt,
bool bBtCtrlAggBufSize,
@@ -314,7 +314,7 @@ static void halbtc8723b1ant_LimitedRx(
}
-static void halbtc8723b1ant_QueryBtInfo(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_QueryBtInfo(struct btc_coexist *pBtCoexist)
{
u8 H2C_Parameter[1] = {0};
@@ -331,7 +331,7 @@ static void halbtc8723b1ant_QueryBtInfo(PBTC_COEXIST pBtCoexist)
pBtCoexist->fBtcFillH2c(pBtCoexist, 0x61, 1, H2C_Parameter);
}
-static void halbtc8723b1ant_MonitorBtCtr(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_MonitorBtCtr(struct btc_coexist *pBtCoexist)
{
u32 regHPTxRx, regLPTxRx, u4Tmp;
u32 regHPTx = 0, regHPRx = 0, regLPTx = 0, regLPRx = 0;
@@ -353,11 +353,11 @@ static void halbtc8723b1ant_MonitorBtCtr(PBTC_COEXIST pBtCoexist)
u4Tmp = pBtCoexist->fBtcRead4Byte(pBtCoexist, regHPTxRx);
regHPTx = u4Tmp & bMaskLWord;
- regHPRx = (u4Tmp & bMaskHWord)>>16;
+ regHPRx = (u4Tmp & bMaskHWord) >> 16;
u4Tmp = pBtCoexist->fBtcRead4Byte(pBtCoexist, regLPTxRx);
regLPTx = u4Tmp & bMaskLWord;
- regLPRx = (u4Tmp & bMaskHWord)>>16;
+ regLPRx = (u4Tmp & bMaskHWord) >> 16;
pCoexSta->highPriorityTx = regHPTx;
pCoexSta->highPriorityRx = regHPRx;
@@ -392,7 +392,7 @@ static void halbtc8723b1ant_MonitorBtCtr(PBTC_COEXIST pBtCoexist)
}
-static void halbtc8723b1ant_MonitorWiFiCtr(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_MonitorWiFiCtr(struct btc_coexist *pBtCoexist)
{
s32 wifiRssi = 0;
bool bWifiBusy = false, bWifiUnderBMode = false;
@@ -478,7 +478,7 @@ static void halbtc8723b1ant_MonitorWiFiCtr(PBTC_COEXIST pBtCoexist)
}
-static bool halbtc8723b1ant_IsWifiStatusChanged(PBTC_COEXIST pBtCoexist)
+static bool halbtc8723b1ant_IsWifiStatusChanged(struct btc_coexist *pBtCoexist)
{
static bool bPreWifiBusy, bPreUnder4way, bPreBtHsOn;
bool bWifiBusy = false, bUnder4way = false, bBtHsOn = false;
@@ -513,9 +513,9 @@ static bool halbtc8723b1ant_IsWifiStatusChanged(PBTC_COEXIST pBtCoexist)
return false;
}
-static void halbtc8723b1ant_UpdateBtLinkInfo(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_UpdateBtLinkInfo(struct btc_coexist *pBtCoexist)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
bool bBtHsOn = false;
pBtCoexist->fBtcGet(pBtCoexist, BTC_GET_BL_HS_OPERATION, &bBtHsOn);
@@ -577,9 +577,9 @@ static void halbtc8723b1ant_UpdateBtLinkInfo(PBTC_COEXIST pBtCoexist)
pBtLinkInfo->bHidOnly = false;
}
-static u8 halbtc8723b1ant_ActionAlgorithm(PBTC_COEXIST pBtCoexist)
+static u8 halbtc8723b1ant_ActionAlgorithm(struct btc_coexist *pBtCoexist)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
bool bBtHsOn = false;
u8 algorithm = BT_8723B_1ANT_COEX_ALGO_UNDEFINED;
u8 numOfDiffProfile = 0;
@@ -805,7 +805,7 @@ static u8 halbtc8723b1ant_ActionAlgorithm(PBTC_COEXIST pBtCoexist)
}
static void halbtc8723b1ant_SetSwPenaltyTxRateAdaptive(
- PBTC_COEXIST pBtCoexist, bool bLowPenaltyRa
+ struct btc_coexist *pBtCoexist, bool bLowPenaltyRa
)
{
u8 H2C_Parameter[6] = {0};
@@ -833,7 +833,7 @@ static void halbtc8723b1ant_SetSwPenaltyTxRateAdaptive(
}
static void halbtc8723b1ant_LowPenaltyRa(
- PBTC_COEXIST pBtCoexist, bool bForceExec, bool bLowPenaltyRa
+ struct btc_coexist *pBtCoexist, bool bForceExec, bool bLowPenaltyRa
)
{
pCoexDm->bCurLowPenaltyRa = bLowPenaltyRa;
@@ -850,7 +850,7 @@ static void halbtc8723b1ant_LowPenaltyRa(
}
static void halbtc8723b1ant_SetCoexTable(
- PBTC_COEXIST pBtCoexist,
+ struct btc_coexist *pBtCoexist,
u32 val0x6c0,
u32 val0x6c4,
u32 val0x6c8,
@@ -887,7 +887,7 @@ static void halbtc8723b1ant_SetCoexTable(
}
static void halbtc8723b1ant_CoexTable(
- PBTC_COEXIST pBtCoexist,
+ struct btc_coexist *pBtCoexist,
bool bForceExec,
u32 val0x6c0,
u32 val0x6c4,
@@ -930,7 +930,7 @@ static void halbtc8723b1ant_CoexTable(
}
static void halbtc8723b1ant_CoexTableWithType(
- PBTC_COEXIST pBtCoexist, bool bForceExec, u8 type
+ struct btc_coexist *pBtCoexist, bool bForceExec, u8 type
)
{
BTC_PRINT(
@@ -988,7 +988,7 @@ static void halbtc8723b1ant_CoexTableWithType(
}
static void halbtc8723b1ant_SetFwIgnoreWlanAct(
- PBTC_COEXIST pBtCoexist, bool bEnable
+ struct btc_coexist *pBtCoexist, bool bEnable
)
{
u8 H2C_Parameter[1] = {0};
@@ -1009,7 +1009,7 @@ static void halbtc8723b1ant_SetFwIgnoreWlanAct(
}
static void halbtc8723b1ant_IgnoreWlanAct(
- PBTC_COEXIST pBtCoexist, bool bForceExec, bool bEnable
+ struct btc_coexist *pBtCoexist, bool bForceExec, bool bEnable
)
{
BTC_PRINT(
@@ -1043,7 +1043,7 @@ static void halbtc8723b1ant_IgnoreWlanAct(
}
static void halbtc8723b1ant_SetLpsRpwm(
- PBTC_COEXIST pBtCoexist, u8 lpsVal, u8 rpwmVal
+ struct btc_coexist *pBtCoexist, u8 lpsVal, u8 rpwmVal
)
{
u8 lps = lpsVal;
@@ -1054,7 +1054,7 @@ static void halbtc8723b1ant_SetLpsRpwm(
}
static void halbtc8723b1ant_LpsRpwm(
- PBTC_COEXIST pBtCoexist, bool bForceExec, u8 lpsVal, u8 rpwmVal
+ struct btc_coexist *pBtCoexist, bool bForceExec, u8 lpsVal, u8 rpwmVal
)
{
BTC_PRINT(
@@ -1105,7 +1105,7 @@ static void halbtc8723b1ant_LpsRpwm(
}
static void halbtc8723b1ant_SwMechanism(
- PBTC_COEXIST pBtCoexist, bool bLowPenaltyRA
+ struct btc_coexist *pBtCoexist, bool bLowPenaltyRA
)
{
BTC_PRINT(
@@ -1118,10 +1118,10 @@ static void halbtc8723b1ant_SwMechanism(
}
static void halbtc8723b1ant_SetAntPath(
- PBTC_COEXIST pBtCoexist, u8 antPosType, bool bInitHwCfg, bool bWifiOff
+ struct btc_coexist *pBtCoexist, u8 antPosType, bool bInitHwCfg, bool bWifiOff
)
{
- PBTC_BOARD_INFO pBoardInfo = &pBtCoexist->boardInfo;
+ struct btc_board_info *pBoardInfo = &pBtCoexist->boardInfo;
u32 fwVer = 0, u4Tmp = 0, cntBtCalChk = 0;
bool bPgExtSwitch = false;
bool bUseExtSwitch = false;
@@ -1307,7 +1307,7 @@ static void halbtc8723b1ant_SetAntPath(
}
static void halbtc8723b1ant_SetFwPstdma(
- PBTC_COEXIST pBtCoexist, u8 byte1, u8 byte2, u8 byte3, u8 byte4, u8 byte5
+ struct btc_coexist *pBtCoexist, u8 byte1, u8 byte2, u8 byte3, u8 byte4, u8 byte5
)
{
u8 H2C_Parameter[5] = {0};
@@ -1317,7 +1317,7 @@ static void halbtc8723b1ant_SetFwPstdma(
pBtCoexist->fBtcGet(pBtCoexist, BTC_GET_BL_WIFI_AP_MODE_ENABLE, &bApEnable);
if (bApEnable) {
- if (byte1&BIT4 && !(byte1&BIT5)) {
+ if (byte1 & BIT4 && !(byte1 & BIT5)) {
BTC_PRINT(
BTC_MSG_INTERFACE,
INTF_NOTIFY,
@@ -1349,9 +1349,9 @@ static void halbtc8723b1ant_SetFwPstdma(
(
"[BTCoex], PS-TDMA H2C cmd = 0x%x%08x\n",
H2C_Parameter[0],
- H2C_Parameter[1]<<24|
- H2C_Parameter[2]<<16|
- H2C_Parameter[3]<<8|
+ H2C_Parameter[1] << 24 |
+ H2C_Parameter[2] << 16 |
+ H2C_Parameter[3] << 8 |
H2C_Parameter[4]
)
);
@@ -1361,10 +1361,10 @@ static void halbtc8723b1ant_SetFwPstdma(
static void halbtc8723b1ant_PsTdma(
- PBTC_COEXIST pBtCoexist, bool bForceExec, bool bTurnOn, u8 type
+ struct btc_coexist *pBtCoexist, bool bForceExec, bool bTurnOn, u8 type
)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
bool bWifiBusy = false;
u8 rssiAdjustVal = 0;
u8 psTdmaByte4Val = 0x50, psTdmaByte0Val = 0x51, psTdmaByte3Val = 0x10;
@@ -1435,7 +1435,7 @@ static void halbtc8723b1ant_PsTdma(
halbtc8723b1ant_SetFwPstdma(
pBtCoexist,
psTdmaByte0Val,
- 0x3a+nWiFiDurationAdjust,
+ 0x3a + nWiFiDurationAdjust,
0x03,
psTdmaByte3Val,
psTdmaByte4Val
@@ -1445,7 +1445,7 @@ static void halbtc8723b1ant_PsTdma(
halbtc8723b1ant_SetFwPstdma(
pBtCoexist,
psTdmaByte0Val,
- 0x2d+nWiFiDurationAdjust,
+ 0x2d + nWiFiDurationAdjust,
0x03,
psTdmaByte3Val,
psTdmaByte4Val
@@ -1661,7 +1661,7 @@ static void halbtc8723b1ant_PsTdma(
pCoexDm->prePsTdma = pCoexDm->curPsTdma;
}
-static bool halbtc8723b1ant_IsCommonAction(PBTC_COEXIST pBtCoexist)
+static bool halbtc8723b1ant_IsCommonAction(struct btc_coexist *pBtCoexist)
{
bool bCommon = false, bWifiConnected = false, bWifiBusy = false;
@@ -1752,7 +1752,7 @@ static bool halbtc8723b1ant_IsCommonAction(PBTC_COEXIST pBtCoexist)
static void halbtc8723b1ant_TdmaDurationAdjustForAcl(
- PBTC_COEXIST pBtCoexist, u8 wifiStatus
+ struct btc_coexist *pBtCoexist, u8 wifiStatus
)
{
static s32 up, dn, m, n, WaitCount;
@@ -1855,7 +1855,7 @@ static void halbtc8723b1ant_TdmaDurationAdjustForAcl(
if (m >= 20) /* m 最大值 = 20 ' 最大120秒 recheck是否調整 WiFi duration. */
m = 20;
- n = 3*m;
+ n = 3 * m;
up = 0;
dn = 0;
WaitCount = 0;
@@ -1871,7 +1871,7 @@ static void halbtc8723b1ant_TdmaDurationAdjustForAcl(
if (m >= 20) /* m 最大值 = 20 ' 最大120秒 recheck是否調整 WiFi duration. */
m = 20;
- n = 3*m;
+ n = 3 * m;
up = 0;
dn = 0;
WaitCount = 0;
@@ -1941,7 +1941,7 @@ static void halbtc8723b1ant_TdmaDurationAdjustForAcl(
}
static void halbtc8723b1ant_PsTdmaCheckForPowerSaveState(
- PBTC_COEXIST pBtCoexist, bool bNewPsState
+ struct btc_coexist *pBtCoexist, bool bNewPsState
)
{
u8 lpsMode = 0x0;
@@ -1963,7 +1963,7 @@ static void halbtc8723b1ant_PsTdmaCheckForPowerSaveState(
}
static void halbtc8723b1ant_PowerSaveState(
- PBTC_COEXIST pBtCoexist, u8 psType, u8 lpsVal, u8 rpwmVal
+ struct btc_coexist *pBtCoexist, u8 psType, u8 lpsVal, u8 rpwmVal
)
{
bool bLowPwrDisable = false;
@@ -2011,7 +2011,7 @@ static void halbtc8723b1ant_PowerSaveState(
/* Non-Software Coex Mechanism start */
/* */
/* */
-static void halbtc8723b1ant_ActionWifiMultiPort(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_ActionWifiMultiPort(struct btc_coexist *pBtCoexist)
{
halbtc8723b1ant_PowerSaveState(pBtCoexist, BTC_PS_WIFI_NATIVE, 0x0, 0x0);
@@ -2019,15 +2019,15 @@ static void halbtc8723b1ant_ActionWifiMultiPort(PBTC_COEXIST pBtCoexist)
halbtc8723b1ant_CoexTableWithType(pBtCoexist, NORMAL_EXEC, 2);
}
-static void halbtc8723b1ant_ActionHs(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_ActionHs(struct btc_coexist *pBtCoexist)
{
halbtc8723b1ant_PsTdma(pBtCoexist, NORMAL_EXEC, true, 5);
halbtc8723b1ant_CoexTableWithType(pBtCoexist, NORMAL_EXEC, 2);
}
-static void halbtc8723b1ant_ActionBtInquiry(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_ActionBtInquiry(struct btc_coexist *pBtCoexist)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
bool bWifiConnected = false;
bool bApEnable = false;
bool bWifiBusy = false;
@@ -2067,10 +2067,10 @@ static void halbtc8723b1ant_ActionBtInquiry(PBTC_COEXIST pBtCoexist)
}
static void halbtc8723b1ant_ActionBtScoHidOnlyBusy(
- PBTC_COEXIST pBtCoexist, u8 wifiStatus
+ struct btc_coexist *pBtCoexist, u8 wifiStatus
)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
bool bWifiConnected = false;
pBtCoexist->fBtcGet(pBtCoexist, BTC_GET_BL_WIFI_CONNECTED, &bWifiConnected);
@@ -2087,13 +2087,11 @@ static void halbtc8723b1ant_ActionBtScoHidOnlyBusy(
}
static void halbtc8723b1ant_ActionWifiConnectedBtAclBusy(
- PBTC_COEXIST pBtCoexist, u8 wifiStatus
+ struct btc_coexist *pBtCoexist, u8 wifiStatus
)
{
- u8 btRssiState;
-
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
- btRssiState = halbtc8723b1ant_BtRssiState(2, 28, 0);
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ halbtc8723b1ant_BtRssiState(2, 28, 0);
if ((pCoexSta->lowPriorityRx >= 1000) && (pCoexSta->lowPriorityRx != 65535))
pBtLinkInfo->bSlaveRole = true;
@@ -2141,7 +2139,7 @@ static void halbtc8723b1ant_ActionWifiConnectedBtAclBusy(
}
}
-static void halbtc8723b1ant_ActionWifiNotConnected(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_ActionWifiNotConnected(struct btc_coexist *pBtCoexist)
{
/* power save state */
halbtc8723b1ant_PowerSaveState(pBtCoexist, BTC_PS_WIFI_NATIVE, 0x0, 0x0);
@@ -2152,10 +2150,10 @@ static void halbtc8723b1ant_ActionWifiNotConnected(PBTC_COEXIST pBtCoexist)
}
static void halbtc8723b1ant_ActionWifiNotConnectedScan(
- PBTC_COEXIST pBtCoexist
+ struct btc_coexist *pBtCoexist
)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
halbtc8723b1ant_PowerSaveState(pBtCoexist, BTC_PS_WIFI_NATIVE, 0x0, 0x0);
@@ -2186,10 +2184,10 @@ static void halbtc8723b1ant_ActionWifiNotConnectedScan(
}
static void halbtc8723b1ant_ActionWifiNotConnectedAssoAuth(
- PBTC_COEXIST pBtCoexist
+ struct btc_coexist *pBtCoexist
)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
halbtc8723b1ant_PowerSaveState(pBtCoexist, BTC_PS_WIFI_NATIVE, 0x0, 0x0);
@@ -2210,9 +2208,9 @@ static void halbtc8723b1ant_ActionWifiNotConnectedAssoAuth(
}
}
-static void halbtc8723b1ant_ActionWifiConnectedScan(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_ActionWifiConnectedScan(struct btc_coexist *pBtCoexist)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
halbtc8723b1ant_PowerSaveState(pBtCoexist, BTC_PS_WIFI_NATIVE, 0x0, 0x0);
@@ -2243,10 +2241,10 @@ static void halbtc8723b1ant_ActionWifiConnectedScan(PBTC_COEXIST pBtCoexist)
}
static void halbtc8723b1ant_ActionWifiConnectedSpecialPacket(
- PBTC_COEXIST pBtCoexist
+ struct btc_coexist *pBtCoexist
)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
halbtc8723b1ant_PowerSaveState(pBtCoexist, BTC_PS_WIFI_NATIVE, 0x0, 0x0);
@@ -2267,7 +2265,7 @@ static void halbtc8723b1ant_ActionWifiConnectedSpecialPacket(
}
}
-static void halbtc8723b1ant_ActionWifiConnected(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_ActionWifiConnected(struct btc_coexist *pBtCoexist)
{
bool bWifiBusy = false;
bool bScan = false, bLink = false, bRoam = false;
@@ -2387,7 +2385,7 @@ static void halbtc8723b1ant_ActionWifiConnected(PBTC_COEXIST pBtCoexist)
}
}
-static void halbtc8723b1ant_RunSwCoexistMechanism(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_RunSwCoexistMechanism(struct btc_coexist *pBtCoexist)
{
u8 algorithm = 0;
@@ -2446,9 +2444,9 @@ static void halbtc8723b1ant_RunSwCoexistMechanism(PBTC_COEXIST pBtCoexist)
}
}
-static void halbtc8723b1ant_RunCoexistMechanism(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_RunCoexistMechanism(struct btc_coexist *pBtCoexist)
{
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
bool bWifiConnected = false, bBtHsOn = false;
bool bIncreaseScanDevNum = false;
bool bBtCtrlAggBufSize = false;
@@ -2497,9 +2495,9 @@ static void halbtc8723b1ant_RunCoexistMechanism(PBTC_COEXIST pBtCoexist)
BTC_GET_U4_WIFI_LINK_STATUS,
&wifiLinkStatus
);
- numOfWifiLink = wifiLinkStatus>>16;
+ numOfWifiLink = wifiLinkStatus >> 16;
- if ((numOfWifiLink >= 2) || (wifiLinkStatus&WIFI_P2P_GO_CONNECTED)) {
+ if ((numOfWifiLink >= 2) || (wifiLinkStatus & WIFI_P2P_GO_CONNECTED)) {
BTC_PRINT(
BTC_MSG_INTERFACE,
INTF_NOTIFY,
@@ -2579,7 +2577,7 @@ static void halbtc8723b1ant_RunCoexistMechanism(PBTC_COEXIST pBtCoexist)
halbtc8723b1ant_ActionWifiConnected(pBtCoexist);
}
-static void halbtc8723b1ant_InitCoexDm(PBTC_COEXIST pBtCoexist)
+static void halbtc8723b1ant_InitCoexDm(struct btc_coexist *pBtCoexist)
{
/* force to reset coex mechanism */
@@ -2593,7 +2591,7 @@ static void halbtc8723b1ant_InitCoexDm(PBTC_COEXIST pBtCoexist)
}
static void halbtc8723b1ant_InitHwConfig(
- PBTC_COEXIST pBtCoexist,
+ struct btc_coexist *pBtCoexist,
bool bBackUp,
bool bWifiOnly
)
@@ -2648,9 +2646,9 @@ static void halbtc8723b1ant_InitHwConfig(
/* */
/* extern function start with EXhalbtc8723b1ant_ */
/* */
-void EXhalbtc8723b1ant_PowerOnSetting(PBTC_COEXIST pBtCoexist)
+void EXhalbtc8723b1ant_PowerOnSetting(struct btc_coexist *pBtCoexist)
{
- PBTC_BOARD_INFO pBoardInfo = &pBtCoexist->boardInfo;
+ struct btc_board_info *pBoardInfo = &pBtCoexist->boardInfo;
u8 u1Tmp = 0x0;
u16 u2Tmp = 0x0;
@@ -2658,7 +2656,7 @@ void EXhalbtc8723b1ant_PowerOnSetting(PBTC_COEXIST pBtCoexist)
/* enable BB, REG_SYS_FUNC_EN such that we can write 0x948 correctly. */
u2Tmp = pBtCoexist->fBtcRead2Byte(pBtCoexist, 0x2);
- pBtCoexist->fBtcWrite2Byte(pBtCoexist, 0x2, u2Tmp|BIT0|BIT1);
+ pBtCoexist->fBtcWrite2Byte(pBtCoexist, 0x2, u2Tmp | BIT0 | BIT1);
/* set GRAN_BT = 1 */
pBtCoexist->fBtcWrite1Byte(pBtCoexist, 0x765, 0x18);
@@ -2700,12 +2698,12 @@ void EXhalbtc8723b1ant_PowerOnSetting(PBTC_COEXIST pBtCoexist)
}
}
-void EXhalbtc8723b1ant_InitHwConfig(PBTC_COEXIST pBtCoexist, bool bWifiOnly)
+void EXhalbtc8723b1ant_InitHwConfig(struct btc_coexist *pBtCoexist, bool bWifiOnly)
{
halbtc8723b1ant_InitHwConfig(pBtCoexist, true, bWifiOnly);
}
-void EXhalbtc8723b1ant_InitCoexDm(PBTC_COEXIST pBtCoexist)
+void EXhalbtc8723b1ant_InitCoexDm(struct btc_coexist *pBtCoexist)
{
BTC_PRINT(
BTC_MSG_INTERFACE,
@@ -2720,11 +2718,11 @@ void EXhalbtc8723b1ant_InitCoexDm(PBTC_COEXIST pBtCoexist)
halbtc8723b1ant_QueryBtInfo(pBtCoexist);
}
-void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
+void EXhalbtc8723b1ant_DisplayCoexInfo(struct btc_coexist *pBtCoexist)
{
- PBTC_BOARD_INFO pBoardInfo = &pBtCoexist->boardInfo;
- PBTC_STACK_INFO pStackInfo = &pBtCoexist->stackInfo;
- PBTC_BT_LINK_INFO pBtLinkInfo = &pBtCoexist->btLinkInfo;
+ struct btc_board_info *pBoardInfo = &pBtCoexist->boardInfo;
+ struct btc_stack_info *pStackInfo = &pBtCoexist->stackInfo;
+ struct btc_bt_link_info *pBtLinkInfo = &pBtCoexist->btLinkInfo;
u8 *cliBuf = pBtCoexist->cliBuf;
u8 u1Tmp[4], i, btInfoExt, psTdmaCase = 0;
u16 u2Tmp[4];
@@ -2839,7 +2837,7 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
cliBuf,
BT_TMP_BUF_SIZE,
"\r\n %-35s = %d/ %d", "Wifi rssi/ HS rssi", \
- wifiRssi-100, btHsRssi-100
+ wifiRssi - 100, btHsRssi - 100
);
CL_PRINTF(cliBuf);
@@ -2883,11 +2881,11 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
cliBuf,
BT_TMP_BUF_SIZE,
"\r\n %-35s = %d/ %d/ %d/ %d/ %d", "sta/vwifi/hs/p2pGo/p2pGc", \
- ((wifiLinkStatus&WIFI_STA_CONNECTED) ? 1 : 0),
- ((wifiLinkStatus&WIFI_AP_CONNECTED) ? 1 : 0),
- ((wifiLinkStatus&WIFI_HS_CONNECTED) ? 1 : 0),
- ((wifiLinkStatus&WIFI_P2P_GO_CONNECTED) ? 1 : 0),
- ((wifiLinkStatus&WIFI_P2P_GC_CONNECTED) ? 1 : 0)
+ ((wifiLinkStatus & WIFI_STA_CONNECTED) ? 1 : 0),
+ ((wifiLinkStatus & WIFI_AP_CONNECTED) ? 1 : 0),
+ ((wifiLinkStatus & WIFI_HS_CONNECTED) ? 1 : 0),
+ ((wifiLinkStatus & WIFI_P2P_GO_CONNECTED) ? 1 : 0),
+ ((wifiLinkStatus & WIFI_P2P_GC_CONNECTED) ? 1 : 0)
);
CL_PRINTF(cliBuf);
@@ -2934,7 +2932,7 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
cliBuf,
BT_TMP_BUF_SIZE,
"\r\n %-35s = %s", "BT Info A2DP rate", \
- (btInfoExt&BIT0) ? "Basic rate" : "EDR rate"
+ (btInfoExt & BIT0) ? "Basic rate" : "EDR rate"
);
CL_PRINTF(cliBuf);
@@ -3046,7 +3044,7 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
CL_SPRINTF(
cliBuf, BT_TMP_BUF_SIZE,
"\r\n %-35s = 0x%x/ 0x%x/ 0x%x", "0x778/0x6cc/0x880[29:25]", \
- u1Tmp[0], u4Tmp[0], (u4Tmp[1]&0x3e000000) >> 25
+ u1Tmp[0], u4Tmp[0], (u4Tmp[1] & 0x3e000000) >> 25
);
CL_PRINTF(cliBuf);
@@ -3058,7 +3056,7 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
cliBuf,
BT_TMP_BUF_SIZE,
"\r\n %-35s = 0x%x/ 0x%x/ 0x%x/ 0x%x", "0x948/ 0x67[5] / 0x764 / 0x76e", \
- u4Tmp[0], ((u1Tmp[0]&0x20) >> 5), (u4Tmp[1] & 0xffff), u1Tmp[1]
+ u4Tmp[0], ((u1Tmp[0] & 0x20) >> 5), (u4Tmp[1] & 0xffff), u1Tmp[1]
);
CL_PRINTF(cliBuf);
@@ -3069,7 +3067,7 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
cliBuf,
BT_TMP_BUF_SIZE,
"\r\n %-35s = 0x%x/ 0x%x/ 0x%x", "0x92c[1:0]/ 0x930[7:0]/0x944[1:0]", \
- u4Tmp[0]&0x3, u4Tmp[1]&0xff, u4Tmp[2]&0x3
+ u4Tmp[0] & 0x3, u4Tmp[1] & 0xff, u4Tmp[2] & 0x3
);
CL_PRINTF(cliBuf);
@@ -3081,10 +3079,10 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
cliBuf,
BT_TMP_BUF_SIZE,
"\r\n %-35s = 0x%x/ 0x%x/ 0x%x/ 0x%x", "0x38[11]/0x40/0x4c[24:23]/0x64[0]", \
- ((u1Tmp[0] & 0x8)>>3),
+ ((u1Tmp[0] & 0x8) >> 3),
u1Tmp[1],
- ((u4Tmp[0]&0x01800000)>>23),
- u1Tmp[2]&0x1
+ ((u4Tmp[0] & 0x01800000) >> 23),
+ u1Tmp[2] & 0x1
);
CL_PRINTF(cliBuf);
@@ -3104,7 +3102,7 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
cliBuf,
BT_TMP_BUF_SIZE,
"\r\n %-35s = 0x%x/ 0x%x", "0xc50(dig)/0x49c(null-drop)", \
- u4Tmp[0]&0xff, u1Tmp[0]
+ u4Tmp[0] & 0xff, u1Tmp[0]
);
CL_PRINTF(cliBuf);
@@ -3117,17 +3115,17 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
u1Tmp[1] = pBtCoexist->fBtcRead1Byte(pBtCoexist, 0xa5c);
faOfdm =
- ((u4Tmp[0]&0xffff0000) >> 16) +
- ((u4Tmp[1]&0xffff0000) >> 16) +
+ ((u4Tmp[0] & 0xffff0000) >> 16) +
+ ((u4Tmp[1] & 0xffff0000) >> 16) +
(u4Tmp[1] & 0xffff) + (u4Tmp[2] & 0xffff) + \
- ((u4Tmp[3]&0xffff0000) >> 16) + (u4Tmp[3] & 0xffff);
+ ((u4Tmp[3] & 0xffff0000) >> 16) + (u4Tmp[3] & 0xffff);
faCck = (u1Tmp[0] << 8) + u1Tmp[1];
CL_SPRINTF(
cliBuf,
BT_TMP_BUF_SIZE,
"\r\n %-35s = 0x%x/ 0x%x/ 0x%x", "OFDM-CCA/OFDM-FA/CCK-FA", \
- u4Tmp[0]&0xffff, faOfdm, faCck
+ u4Tmp[0] & 0xffff, faOfdm, faCck
);
CL_PRINTF(cliBuf);
@@ -3183,7 +3181,7 @@ void EXhalbtc8723b1ant_DisplayCoexInfo(PBTC_COEXIST pBtCoexist)
}
-void EXhalbtc8723b1ant_IpsNotify(PBTC_COEXIST pBtCoexist, u8 type)
+void EXhalbtc8723b1ant_IpsNotify(struct btc_coexist *pBtCoexist, u8 type)
{
if (pBtCoexist->bManualControl || pBtCoexist->bStopCoexDm)
return;
@@ -3209,7 +3207,7 @@ void EXhalbtc8723b1ant_IpsNotify(PBTC_COEXIST pBtCoexist, u8 type)
}
}
-void EXhalbtc8723b1ant_LpsNotify(PBTC_COEXIST pBtCoexist, u8 type)
+void EXhalbtc8723b1ant_LpsNotify(struct btc_coexist *pBtCoexist, u8 type)
{
if (pBtCoexist->bManualControl || pBtCoexist->bStopCoexDm)
return;
@@ -3227,7 +3225,7 @@ void EXhalbtc8723b1ant_LpsNotify(PBTC_COEXIST pBtCoexist, u8 type)
}
}
-void EXhalbtc8723b1ant_ScanNotify(PBTC_COEXIST pBtCoexist, u8 type)
+void EXhalbtc8723b1ant_ScanNotify(struct btc_coexist *pBtCoexist, u8 type)
{
bool bWifiConnected = false, bBtHsOn = false;
u32 wifiLinkStatus = 0;
@@ -3283,7 +3281,7 @@ void EXhalbtc8723b1ant_ScanNotify(PBTC_COEXIST pBtCoexist, u8 type)
halbtc8723b1ant_QueryBtInfo(pBtCoexist);
pBtCoexist->fBtcGet(pBtCoexist, BTC_GET_U4_WIFI_LINK_STATUS, &wifiLinkStatus);
- numOfWifiLink = wifiLinkStatus>>16;
+ numOfWifiLink = wifiLinkStatus >> 16;
if (numOfWifiLink >= 2) {
halbtc8723b1ant_LimitedTx(pBtCoexist, NORMAL_EXEC, 0, 0, 0, 0);
@@ -3317,7 +3315,7 @@ void EXhalbtc8723b1ant_ScanNotify(PBTC_COEXIST pBtCoexist, u8 type)
}
}
-void EXhalbtc8723b1ant_ConnectNotify(PBTC_COEXIST pBtCoexist, u8 type)
+void EXhalbtc8723b1ant_ConnectNotify(struct btc_coexist *pBtCoexist, u8 type)
{
bool bWifiConnected = false, bBtHsOn = false;
u32 wifiLinkStatus = 0;
@@ -3343,7 +3341,7 @@ void EXhalbtc8723b1ant_ConnectNotify(PBTC_COEXIST pBtCoexist, u8 type)
}
pBtCoexist->fBtcGet(pBtCoexist, BTC_GET_U4_WIFI_LINK_STATUS, &wifiLinkStatus);
- numOfWifiLink = wifiLinkStatus>>16;
+ numOfWifiLink = wifiLinkStatus >> 16;
if (numOfWifiLink >= 2) {
halbtc8723b1ant_LimitedTx(pBtCoexist, NORMAL_EXEC, 0, 0, 0, 0);
halbtc8723b1ant_LimitedRx(pBtCoexist, NORMAL_EXEC, false, bBtCtrlAggBufSize, aggBufSize);
@@ -3374,7 +3372,7 @@ void EXhalbtc8723b1ant_ConnectNotify(PBTC_COEXIST pBtCoexist, u8 type)
}
}
-void EXhalbtc8723b1ant_MediaStatusNotify(PBTC_COEXIST pBtCoexist, u8 type)
+void EXhalbtc8723b1ant_MediaStatusNotify(struct btc_coexist *pBtCoexist, u8 type)
{
u8 H2C_Parameter[3] = {0};
u32 wifiBw;
@@ -3437,14 +3435,14 @@ void EXhalbtc8723b1ant_MediaStatusNotify(PBTC_COEXIST pBtCoexist, u8 type)
ALGO_TRACE_FW_EXEC,
(
"[BTCoex], FW write 0x66 = 0x%x\n",
- H2C_Parameter[0]<<16 | H2C_Parameter[1]<<8 | H2C_Parameter[2]
+ H2C_Parameter[0] << 16 | H2C_Parameter[1] << 8 | H2C_Parameter[2]
)
);
pBtCoexist->fBtcFillH2c(pBtCoexist, 0x66, 3, H2C_Parameter);
}
-void EXhalbtc8723b1ant_SpecialPacketNotify(PBTC_COEXIST pBtCoexist, u8 type)
+void EXhalbtc8723b1ant_SpecialPacketNotify(struct btc_coexist *pBtCoexist, u8 type)
{
bool bBtHsOn = false;
u32 wifiLinkStatus = 0;
@@ -3504,7 +3502,7 @@ void EXhalbtc8723b1ant_SpecialPacketNotify(PBTC_COEXIST pBtCoexist, u8 type)
pBtCoexist->fBtcGet(
pBtCoexist, BTC_GET_U4_WIFI_LINK_STATUS, &wifiLinkStatus
);
- numOfWifiLink = wifiLinkStatus>>16;
+ numOfWifiLink = wifiLinkStatus >> 16;
if (numOfWifiLink >= 2) {
halbtc8723b1ant_LimitedTx(pBtCoexist, NORMAL_EXEC, 0, 0, 0, 0);
@@ -3533,7 +3531,7 @@ void EXhalbtc8723b1ant_SpecialPacketNotify(PBTC_COEXIST pBtCoexist, u8 type)
}
void EXhalbtc8723b1ant_BtInfoNotify(
- PBTC_COEXIST pBtCoexist, u8 *tmpBuf, u8 length
+ struct btc_coexist *pBtCoexist, u8 *tmpBuf, u8 length
)
{
u8 btInfo = 0;
@@ -3543,7 +3541,7 @@ void EXhalbtc8723b1ant_BtInfoNotify(
pCoexSta->bC2hBtInfoReqSent = false;
- rspSource = tmpBuf[0]&0xf;
+ rspSource = tmpBuf[0] & 0xf;
if (rspSource >= BT_INFO_SRC_8723B_1ANT_MAX)
rspSource = BT_INFO_SRC_8723B_1ANT_WIFI_FW;
pCoexSta->btInfoC2hCnt[rspSource]++;
@@ -3559,7 +3557,7 @@ void EXhalbtc8723b1ant_BtInfoNotify(
pCoexSta->btInfoC2h[rspSource][i] = tmpBuf[i];
if (i == 1)
btInfo = tmpBuf[i];
- if (i == length-1)
+ if (i == length - 1)
BTC_PRINT(
BTC_MSG_INTERFACE, INTF_NOTIFY, ("0x%02x]\n", tmpBuf[i])
);
@@ -3568,22 +3566,22 @@ void EXhalbtc8723b1ant_BtInfoNotify(
}
if (BT_INFO_SRC_8723B_1ANT_WIFI_FW != rspSource) {
- pCoexSta->btRetryCnt = pCoexSta->btInfoC2h[rspSource][2]&0xf;
+ pCoexSta->btRetryCnt = pCoexSta->btInfoC2h[rspSource][2] & 0xf;
if (pCoexSta->btRetryCnt >= 1)
pCoexSta->popEventCnt++;
- if (pCoexSta->btInfoC2h[rspSource][2]&0x20)
+ if (pCoexSta->btInfoC2h[rspSource][2] & 0x20)
pCoexSta->bC2hBtPage = true;
else
pCoexSta->bC2hBtPage = false;
- pCoexSta->btRssi = pCoexSta->btInfoC2h[rspSource][3]*2-90;
+ pCoexSta->btRssi = pCoexSta->btInfoC2h[rspSource][3] * 2 - 90;
/* pCoexSta->btInfoC2h[rspSource][3]*2+10; */
pCoexSta->btInfoExt = pCoexSta->btInfoC2h[rspSource][4];
- pCoexSta->bBtTxRxMask = (pCoexSta->btInfoC2h[rspSource][2]&0x40);
+ pCoexSta->bBtTxRxMask = (pCoexSta->btInfoC2h[rspSource][2] & 0x40);
pBtCoexist->fBtcSet(pBtCoexist, BTC_SET_BL_BT_TX_RX_MASK, &pCoexSta->bBtTxRxMask);
if (!pCoexSta->bBtTxRxMask) {
@@ -3628,7 +3626,7 @@ void EXhalbtc8723b1ant_BtInfoNotify(
pCoexSta->bC2hBtInquiryPage = false;
/* set link exist status */
- if (!(btInfo&BT_INFO_8723B_1ANT_B_CONNECTION)) {
+ if (!(btInfo & BT_INFO_8723B_1ANT_B_CONNECTION)) {
pCoexSta->bBtLinkExist = false;
pCoexSta->bPanExist = false;
pCoexSta->bA2dpExist = false;
@@ -3661,7 +3659,7 @@ void EXhalbtc8723b1ant_BtInfoNotify(
btInfo = btInfo & 0x1f; /* mask profile bit for connect-ilde identification (for CSR case: A2DP idle --> 0x41) */
- if (!(btInfo&BT_INFO_8723B_1ANT_B_CONNECTION)) {
+ if (!(btInfo & BT_INFO_8723B_1ANT_B_CONNECTION)) {
pCoexDm->btStatus = BT_8723B_1ANT_BT_STATUS_NON_CONNECTED_IDLE;
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE, ("[BTCoex], BtInfoNotify(), BT Non-Connected idle!!!\n"));
} else if (btInfo == BT_INFO_8723B_1ANT_B_CONNECTION) {
@@ -3669,12 +3667,12 @@ void EXhalbtc8723b1ant_BtInfoNotify(
pCoexDm->btStatus = BT_8723B_1ANT_BT_STATUS_CONNECTED_IDLE;
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE, ("[BTCoex], BtInfoNotify(), BT Connected-idle!!!\n"));
} else if (
- (btInfo&BT_INFO_8723B_1ANT_B_SCO_ESCO) ||
- (btInfo&BT_INFO_8723B_1ANT_B_SCO_BUSY)
+ (btInfo & BT_INFO_8723B_1ANT_B_SCO_ESCO) ||
+ (btInfo & BT_INFO_8723B_1ANT_B_SCO_BUSY)
) {
pCoexDm->btStatus = BT_8723B_1ANT_BT_STATUS_SCO_BUSY;
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE, ("[BTCoex], BtInfoNotify(), BT SCO busy!!!\n"));
- } else if (btInfo&BT_INFO_8723B_1ANT_B_ACL_BUSY) {
+ } else if (btInfo & BT_INFO_8723B_1ANT_B_ACL_BUSY) {
if (BT_8723B_1ANT_BT_STATUS_ACL_BUSY != pCoexDm->btStatus)
pCoexDm->bAutoTdmaAdjust = false;
@@ -3698,7 +3696,7 @@ void EXhalbtc8723b1ant_BtInfoNotify(
halbtc8723b1ant_RunCoexistMechanism(pBtCoexist);
}
-void EXhalbtc8723b1ant_HaltNotify(PBTC_COEXIST pBtCoexist)
+void EXhalbtc8723b1ant_HaltNotify(struct btc_coexist *pBtCoexist)
{
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], Halt notify\n"));
@@ -3713,7 +3711,7 @@ void EXhalbtc8723b1ant_HaltNotify(PBTC_COEXIST pBtCoexist)
pBtCoexist->bStopCoexDm = true;
}
-void EXhalbtc8723b1ant_PnpNotify(PBTC_COEXIST pBtCoexist, u8 pnpState)
+void EXhalbtc8723b1ant_PnpNotify(struct btc_coexist *pBtCoexist, u8 pnpState)
{
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], Pnp notify\n"));
@@ -3735,7 +3733,7 @@ void EXhalbtc8723b1ant_PnpNotify(PBTC_COEXIST pBtCoexist, u8 pnpState)
}
}
-void EXhalbtc8723b1ant_Periodical(PBTC_COEXIST pBtCoexist)
+void EXhalbtc8723b1ant_Periodical(struct btc_coexist *pBtCoexist)
{
static u8 disVerInfoCnt;
u32 fwVer = 0, btPatchVer = 0;