From: Oleksij Rempel Date: Sat, 11 May 2013 05:49:08 +0000 (+0200) Subject: ratectrl_11n_ln: nuke rcSibUpdate_11n X-Git-Tag: 1.4.0~13^2~1 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=a8a319cd891d6579316755c2b65728735d0f8a97;p=open-ath9k-htc-firmware.git ratectrl_11n_ln: nuke rcSibUpdate_11n This function is reather useless. Side effect of it is a filter for some bits which can be in other way implemented. For now, i do not see any sense for this filter. Signed-off-by: Oleksij Rempel --- diff --git a/target_firmware/wlan/ratectrl.h b/target_firmware/wlan/ratectrl.h index c832dc1..97ee9a6 100755 --- a/target_firmware/wlan/ratectrl.h +++ b/target_firmware/wlan/ratectrl.h @@ -159,7 +159,6 @@ typedef struct phy_rate_ctrl { struct atheros_node { TX_RATE_CTRL txRateCtrl; /* rate control state proper */ A_UINT32 lastRateKbps; /* last rate in Kb/s */ - A_UINT32 htcap; /* ht capabilites */ A_UINT8 singleStream :1, /* When TRUE, only single stream Tx possible */ stbc :2; /* Rx stbc capability */ diff --git a/target_firmware/wlan/ratectrl11n.h b/target_firmware/wlan/ratectrl11n.h index f220819..1123feb 100755 --- a/target_firmware/wlan/ratectrl11n.h +++ b/target_firmware/wlan/ratectrl11n.h @@ -157,20 +157,6 @@ typedef struct { rc11n_info_t info[]; } RATE_TABLE_11N; -/* - * Update the SIB's rate control information - * - * This should be called when the supported rates change - * (e.g. SME operation, wireless mode change) - * - * It will determine which rates are valid for use. - */ -void rcSibUpdate_11n(struct ath_softc_tgt *, - struct ath_node_target *, - A_UINT32 capflag, - A_BOOL keepState, - struct ieee80211_rate *rs); - /* * Determines and returns the new Tx rate index. */ diff --git a/target_firmware/wlan/ratectrl_11n_ln.c b/target_firmware/wlan/ratectrl_11n_ln.c index 788822c..57ac34a 100755 --- a/target_firmware/wlan/ratectrl_11n_ln.c +++ b/target_firmware/wlan/ratectrl_11n_ln.c @@ -429,19 +429,7 @@ rcSibUpdate_ht(struct ath_softc_tgt *sc, struct ath_node_target *an, rcSortValidRates(pRateTable, pRc); } -void -rcSibUpdate_11n(struct ath_softc_tgt *sc, struct ath_node_target *pSib, - A_UINT32 capflag, A_BOOL keepState, struct ieee80211_rate *pRateSet) -{ - rcSibUpdate_ht(sc, - pSib, - ((capflag & ATH_RC_DS_FLAG) ? WLAN_RC_DS_FLAG : 0) | - ((capflag & ATH_RC_HT40_SGI_FLAG) ? WLAN_RC_HT40_SGI_FLAG : 0) | - ((capflag & ATH_RC_HT_FLAG) ? WLAN_RC_HT_FLAG : 0) | - ((capflag & ATH_RC_CW40_FLAG) ? WLAN_RC_40_FLAG : 0), - keepState, - pRateSet); -} + /* * Return the median of three numbers @@ -1210,19 +1198,12 @@ ath_rate_newassoc_11n(struct ath_softc_tgt *sc, struct ath_node_target *an, int unsigned int capflag, struct ieee80211_rate *rs) { if (isnew) { - struct atheros_node *oan = ATH_NODE_ATHEROS(an); - - oan->htcap = ((capflag & ATH_RC_DS_FLAG) ? WLAN_RC_DS_FLAG : 0) | - ((capflag & ATH_RC_HT40_SGI_FLAG) ? WLAN_RC_HT40_SGI_FLAG : 0) | - ((capflag & ATH_RC_HT_FLAG) ? WLAN_RC_HT_FLAG : 0) | - ((capflag & ATH_RC_CW40_FLAG) ? WLAN_RC_40_FLAG : 0) | - ((capflag & ATH_RC_WEP_TKIP_FLAG) ? WLAN_RC_WEP_TKIP_FLAG : 0); - #ifdef MAGPIE_MERLIN + struct atheros_node *oan = ATH_NODE_ATHEROS(an); /* Only MERLIN can send STBC */ oan->stbc = (capflag & ATH_RC_TX_STBC_FLAG) ? 1 : 0; #endif - rcSibUpdate_11n(sc, an, oan->htcap, 0, rs); + rcSibUpdate_ht(sc, an, capflag, 0, rs); } }