wcn36xx: set self sta entry as HT capable
PATCH 1/1 wcn36xx: set self sta entry as HT capable
Set the HT capable for self STA entry for bss configuration. Otherwise, only legacy rate will be used for transmitting, especially for mesh mode.
--- drivers/net/wireless/ath/wcn36xx/smd.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)
drivers/net/wireless/ath/wcn36xx/smd.c +8 -1
@@ -115,6 +115,13 @@ static void wcn36xx_smd_set_sta_ht_params(struct ieee80211_sta *sta, } } +static void wcn36xx_smd_set_sta_default_ht_params ( +struct wcn36xx_hal_config_sta_params *sta_params) +{ +wcn36xx_set_default_rates (&sta_params->supported_rates); + sta_params->ht_capable =1 ; +} + static void wcn36xx_smd_set_sta_params(struct wcn36xx *wcn, struct ieee80211_vif *vif, struct ieee80211_sta *sta,
@@ -171,7 +178,7 @@ static void wcn36xx_smd_set_sta_params(struct wcn36xx *wcn,memcpy (&sta_params->supported_rates, &priv_sta->supported_rates,sizeof (priv_sta->supported_rates)); }else { -wcn36xx_set_default_rates (&sta_params->supported_rates); +wcn36xx_smd_set_sta_default_ht_params (sta_params); } }
Signature · 1 line
1.7.9.5
Why would the function that is setting default HT params will also set default rates? There is no connection between HT params and default rates.
But the idea to set HT by default in AP mode is something that we definitely need.
Quoted 39 lines · Chun-Yeow Yeoh
Set the HT capable for self STA entry for bss configuration. Otherwise, only legacy rate will be used for transmitting, especially for mesh mode.
Signed-off-by Chun-Yeow Yeoh <[email protected]>--- drivers/net/wireless/ath/wcn36xx/smd.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)drivers/net/wireless/ath/wcn36xx/smd.c +8
-2@@ -115,6 +115,13 @@ static void wcn36xx_smd_set_sta_ht_params(struct ieee80211_sta *sta, } } +static void wcn36xx_smd_set_sta_default_ht_params ( +struct wcn36xx_hal_config_sta_params *sta_params) +{ +wcn36xx_set_default_rates (&sta_params->supported_rates); + sta_params->ht_capable =1 ; +} + static void wcn36xx_smd_set_sta_params(struct wcn36xx *wcn, struct ieee80211_vif *vif, struct ieee80211_sta *sta,@@ -171,7 +178,7 @@ static void wcn36xx_smd_set_sta_params(struct wcn36xx *wcn,memcpy (&sta_params->supported_rates, &priv_sta->supported_rates,sizeof (priv_sta->supported_rates)); }else { -wcn36xx_set_default_rates (&sta_params->supported_rates); +wcn36xx_smd_set_sta_default_ht_params (sta_params); } } --1.7.9.5
Signature · 2 lines
Best regards, Eugene
Hi, Eugene
Quoted 3 lines
Why would the function that is setting default HT params will also set default rates? There is no connection between HT params and default rates.
How about rename the function name to wcn36xx_smd_set_self_sta?
----
Chun-Yeow
How about wcn36xx_smd_set_sta_default_ht_params?
This function will set all of the following fields to default values:sta_params->ht_capablesta_params->tx_channel_width_set sta_params->lsig_txop_protection sta_params->max_ampdu_sizesta_params->max_ampdu_densitysta_params->max_amsdu_sizesta_params->sgi_20Mhzsta_params->sgi_40mhzsta_params->green_field_capable sta_params->delayed_ba_support sta_params->dsss_cck_mode_40mhz
And then in wcn36xx_smd_set_sta_params it is called like this:wcn36xx_set_default_rates(&sta_params->supported_rates); wcn36xx_smd_set_sta_default_ht_params
How does that sound?
Quoted 9 lines · Yeoh Chun-Yeow
Hi, Eugene
Quoted 3 lines
Why would the function that is setting default HT params will also set default rates? There is no connection between HT params and default rates.
How about rename the function name to
wcn36xx_smd_set_self_sta?----
Chun-Yeow
Signature · 2 lines
Best regards, Eugene
A message that is not in the archive (sent off-list or not yet received): CAEFj9859MXVE5L1Diiw0cNsaNPaNEYPddm0Fjco5hJGJpLtNSA@mail.gmail.com
Most of these values are taken from wcn_band_2ghz
Will try to remember:
sta_params->ht_capable = 1 sta_params->tx_channel_width_set = 1 sta_params->lsig_txop_protection = 1 sta_params->max_ampdu_size = 3 // Might be wrong but let's have this value as a begining.sta_params->max_ampdu_density = 5 // Might be wrong but let's have this value as a begining.sta_params->max_amsdu_size = 0sta_params->sgi_20Mhz = 1sta_params->sgi_40mhz = 1sta_params->green_field_capable = 1 sta_params->delayed_ba_support = 0 sta_params->dsss_cck_mode_40mhz = 1
Quoted 27 lines · Yeoh Chun-Yeow
Quoted 4 lines
This function will set all of the following fields to default values:
sta_params->ht_capablesta_params->tx_channel_width_setsta_params->lsig_txop_protectionQuoted 8 lines
sta_params->max_ampdu_sizesta_params->max_ampdu_densitysta_params->max_amsdu_sizesta_params->sgi_20Mhzsta_params->sgi_40mhzsta_params->green_field_capablesta_params->delayed_ba_supportsta_params->dsss_cck_mode_40mhzI am alright with that. But I am not sure about the default value of other fields mentioned above. Are you able to provide that?
Quoted 6 lines
And then in
wcn36xx_smd_set_sta_paramsit is called like this:wcn36xx_set_default_rates(&sta_params->supported_rates);wcn36xx_smd_set_sta_default_ht_paramsHow does that sound?
---
Chun-Yeow
Signature · 2 lines
Best regards, Eugene
Alright, I will resubmit the patch with these as default value.
---
Chun-Yeow
Quoted 17 lines · Eugene Krasnikov
Most of these values are taken from
wcn_band_2ghzWill try to remember:
sta_params->ht_capable= 1sta_params->tx_channel_width_set= 1sta_params->lsig_txop_protection= 1sta_params->max_ampdu_size= 3 // Might be wrong but let's have this value as a begining.sta_params->max_ampdu_density= 5 // Might be wrong but let's have this value as a begining.sta_params->max_amsdu_size= 0sta_params->sgi_20Mhz= 1sta_params->sgi_40mhz= 1sta_params->green_field_capable= 1sta_params->delayed_ba_support= 0sta_params->dsss_cck_mode_40mhz= 1