From: Jes Sorensen Date: Wed, 9 Apr 2014 21:20:36 +0000 (+0200) Subject: staging: rtl8723au: Make direct calls for HW_VAR_TXDMA_AGG_PG_TH X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=1e7b6ebe193a23faf3f559c9611dc1b5ca87c287;p=deliverable%2Flinux.git staging: rtl8723au: Make direct calls for HW_VAR_TXDMA_AGG_PG_TH This was in fact turned into a no-op for the RTL8723AU, but it looks like a bug, so this reenables it. Keep an eye out for side-effects here and revert this, if it causes issues. Signed-off-by: Jes Sorensen Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8723au/core/rtw_mlme.c b/drivers/staging/rtl8723au/core/rtw_mlme.c index 6cee78785bdc..9cf26ea0088b 100644 --- a/drivers/staging/rtl8723au/core/rtw_mlme.c +++ b/drivers/staging/rtl8723au/core/rtw_mlme.c @@ -2193,13 +2193,10 @@ void rtw_joinbss_reset23a(struct rtw_adapter *padapter) threshold = 1; else threshold = 0; - rtw_hal_set_hwreg23a(padapter, HW_VAR_RXDMA_AGG_PG_TH, - (u8 *)(&threshold)); - } else { + } else threshold = 1; - rtw_hal_set_hwreg23a(padapter, HW_VAR_RXDMA_AGG_PG_TH, - (u8 *)(&threshold)); - } + + rtl8723a_set_rxdma_agg_pg_th(padapter, threshold); } /* the fucntion is >= passive_level */ diff --git a/drivers/staging/rtl8723au/core/rtw_sreset.c b/drivers/staging/rtl8723au/core/rtw_sreset.c index e243a3afcdcd..dd2a6f18f7d7 100644 --- a/drivers/staging/rtl8723au/core/rtw_sreset.c +++ b/drivers/staging/rtl8723au/core/rtw_sreset.c @@ -132,13 +132,13 @@ static void sreset_restore_network_station(struct rtw_adapter *padapter) threshold = 1; else threshold = 0; - rtw_hal_set_hwreg23a(padapter, HW_VAR_RXDMA_AGG_PG_TH, (u8 *)(&threshold)); - } else { + } else threshold = 1; - rtw_hal_set_hwreg23a(padapter, HW_VAR_RXDMA_AGG_PG_TH, (u8 *)(&threshold)); - } - set_channel_bwmode23a(padapter, pmlmeext->cur_channel, pmlmeext->cur_ch_offset, pmlmeext->cur_bwmode); + rtl8723a_set_rxdma_agg_pg_th(padapter, threshold); + + set_channel_bwmode23a(padapter, pmlmeext->cur_channel, + pmlmeext->cur_ch_offset, pmlmeext->cur_bwmode); /* disable dynamic functions, such as high power, DIG */ /* Switch_DM_Func23a(padapter, DYNAMIC_FUNC_DISABLE, false); */ diff --git a/drivers/staging/rtl8723au/hal/rtl8723a_hal_init.c b/drivers/staging/rtl8723au/hal/rtl8723a_hal_init.c index e6e501217e6d..fee79d1a190a 100644 --- a/drivers/staging/rtl8723au/hal/rtl8723a_hal_init.c +++ b/drivers/staging/rtl8723au/hal/rtl8723a_hal_init.c @@ -3153,10 +3153,6 @@ void SetHwReg8723A(struct rtw_adapter *padapter, u8 variable, u8 *val) rtl8723a_odm_support_ability_clr(padapter, *val32); break; - case HW_VAR_RXDMA_AGG_PG_TH: - rtl8723a_set_rxdma_agg_pg_th(padapter, *val); - break; - case HW_VAR_H2C_FW_PWRMODE: rtl8723a_set_FwPwrMode_cmd(padapter, *val); break; diff --git a/drivers/staging/rtl8723au/hal/usb_halinit.c b/drivers/staging/rtl8723au/hal/usb_halinit.c index eae95ec38516..2b44b17acc70 100644 --- a/drivers/staging/rtl8723au/hal/usb_halinit.c +++ b/drivers/staging/rtl8723au/hal/usb_halinit.c @@ -1519,8 +1519,6 @@ static void rtl8723au_trigger_gpio_0(struct rtw_adapter *padapter) static void SetHwReg8723AU(struct rtw_adapter *Adapter, u8 variable, u8 *val) { switch (variable) { - case HW_VAR_RXDMA_AGG_PG_TH: - break; case HW_VAR_SET_RPWM: rtl8723a_set_rpwm(Adapter, *val); break; diff --git a/drivers/staging/rtl8723au/include/hal_intf.h b/drivers/staging/rtl8723au/include/hal_intf.h index fcb441154b31..e2b9fdcb2192 100644 --- a/drivers/staging/rtl8723au/include/hal_intf.h +++ b/drivers/staging/rtl8723au/include/hal_intf.h @@ -44,7 +44,6 @@ enum HW_VARIABLES { HW_VAR_DM_FUNC_SET, HW_VAR_DM_FUNC_CLR, HW_VAR_CAM_READ, - HW_VAR_RXDMA_AGG_PG_TH, HW_VAR_SET_RPWM, HW_VAR_H2C_FW_PWRMODE, HW_VAR_H2C_FW_JOINBSSRPT,