1
0
mirror of https://github.com/aircrack-ng/rtl8812au.git synced 2024-11-26 07:04:12 +00:00

Enable DBG_TX_POWER_IDX and DBG_PG_TXPWR_READ, extra logging for these

This commit is contained in:
kimocoder 2018-06-22 22:33:44 +02:00
parent ecaee90b13
commit fdf8a14621
2 changed files with 21 additions and 6 deletions

View File

@ -52,6 +52,10 @@ const char *const _pg_txpwr_src_str[] = {
#define DBG_PG_TXPWR_READ 0
#endif
#ifndef DBG_TX_POWER_IDX
#define DBG_TX_POWER_IDX 0
#endif
#if DBG_PG_TXPWR_READ
static void dump_pg_txpwr_info_2g(void *sel, TxPowerInfo24G *txpwr_info, u8 rfpath_num, u8 max_tx_cnt)
{
@ -1358,6 +1362,10 @@ phy_SetTxPowerByRateBase(
return;
}
if (DBG_TX_POWER_IDX)
RTW_INFO( "TXPWR: by-rate-base [%sG][%c] RateSection:%d = %d\n",
(Band == BAND_ON_2_4G) ? "2.4" : "5", rf_path_char(RfPath), RateSection, Value );
if (Band == BAND_ON_2_4G)
pHalData->TxPwrByRateBase2_4G[RfPath][RateSection] = Value;
else /* BAND_ON_5G */
@ -2655,6 +2663,11 @@ PHY_SetTxPowerByRate(
return;
}
if (DBG_TX_POWER_IDX)
RTW_INFO( "TXPWR: by-rate-base [%sG][%c] Rate:%s = %d\n",
(Band == BAND_ON_2_4G) ? "2.4" : "5", rf_path_char(RFPath),
MGN_RATE_STR(rateIndex), Value );
pHalData->TxPwrByRateOffset[Band][RFPath][rateIndex] = Value;
}
@ -2693,10 +2706,6 @@ phy_set_tx_power_level_by_path(
}
}
#ifndef DBG_TX_POWER_IDX
#define DBG_TX_POWER_IDX 0
#endif
VOID
PHY_SetTxPowerIndexByRateArray(
IN PADAPTER pAdapter,
@ -2713,7 +2722,6 @@ PHY_SetTxPowerIndexByRateArray(
for (i = 0; i < RateArraySize; ++i) {
#if DBG_TX_POWER_IDX
struct txpwr_idx_comp tic;
powerIndex = rtw_hal_get_tx_power_index(pAdapter, RFPath, Rates[i], BandWidth, Channel, &tic);
RTW_INFO("TXPWR: [%c][%s]ch:%u, %s %uT, pwr_idx:%u = %u + (%d=%d:%d) + (%d) + (%d)\n"
, rf_path_char(RFPath), ch_width_str(BandWidth), Channel, MGN_RATE_STR(Rates[i]), tic.ntx_idx + 1
@ -3500,6 +3508,10 @@ PHY_SetTxPowerIndex(
IN u8 Rate
)
{
/* if (DBG_TX_POWER_IDX) */
/* RTW_INFO( "TXPWR: set-index [%c] %s pwr_idx:%u\n", */
/* rf_path_char(RFPath), MGN_RATE_STR(Rate), PowerIndex ); */
if (IS_HARDWARE_TYPE_8814A(pAdapter)) {
#if (RTL8814A_SUPPORT == 1)
PHY_SetTxPowerIndex_8814A(pAdapter, PowerIndex, RFPath, Rate);

View File

@ -323,7 +323,7 @@
/*
* Debug Related Config
*/
#define DBG 1
#define DBG 1
#define CONFIG_PROC_DEBUG
@ -346,6 +346,9 @@
/* #define DBG_RX_SIGNAL_DISPLAY_PROCESSING */
/* #define DBG_RX_SIGNAL_DISPLAY_SSID_MONITORED "jeff-ap" */
#define DBG_TX_POWER_IDX 1
#define DBG_PG_TXPWR_READ 1
/* #define DBG_SHOW_MCUFWDL_BEFORE_51_ENABLE */