mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-11 23:24:22 -04:00
qcacmn: Add 6GHz support for chan/freq/band usage in scan
Currently the conversion APIs used doesn't take into account the overloading of channel numbers between 6GHz, 5GHz and 2.4GHz bands. Add support to obtain the correct channel number (and auxiliary information like band and frequency) through the new APIs that support all three bands. Change-Id: Ic2c8dfa4cc845d701dfd07df61c9ae1ee3d8bdef CRs-Fixed: 2610378
This commit is contained in:
parent
14e285e95c
commit
6287db0784
2 changed files with 7 additions and 9 deletions
|
|
@ -639,7 +639,7 @@ static int32_t scm_calculate_oce_wan_score(
|
|||
#ifdef WLAN_POLICY_MGR_ENABLE
|
||||
|
||||
static uint32_t scm_get_sta_nss(struct wlan_objmgr_psoc *psoc,
|
||||
uint8_t bss_channel,
|
||||
qdf_freq_t bss_channel_freq,
|
||||
uint8_t vdev_nss_2g,
|
||||
uint8_t vdev_nss_5g)
|
||||
{
|
||||
|
|
@ -650,22 +650,22 @@ static uint32_t scm_get_sta_nss(struct wlan_objmgr_psoc *psoc,
|
|||
*/
|
||||
|
||||
if (policy_mgr_is_chnl_in_diff_band(
|
||||
psoc, wlan_chan_to_freq(bss_channel)) &&
|
||||
psoc, bss_channel_freq) &&
|
||||
policy_mgr_is_hw_dbs_capable(psoc) &&
|
||||
!(policy_mgr_is_hw_dbs_2x2_capable(psoc)))
|
||||
return 1;
|
||||
|
||||
return (WLAN_REG_IS_24GHZ_CH(bss_channel) ?
|
||||
return (WLAN_REG_IS_24GHZ_CH_FREQ(bss_channel_freq) ?
|
||||
vdev_nss_2g :
|
||||
vdev_nss_5g);
|
||||
}
|
||||
#else
|
||||
static uint32_t scm_get_sta_nss(struct wlan_objmgr_psoc *psoc,
|
||||
uint8_t bss_channel,
|
||||
qdf_freq_t bss_channel_freq,
|
||||
uint8_t vdev_nss_2g,
|
||||
uint8_t vdev_nss_5g)
|
||||
{
|
||||
return (WLAN_REG_IS_24GHZ_CH(bss_channel) ?
|
||||
return (WLAN_REG_IS_24GHZ_CH_FREQ(bss_channel_freq) ?
|
||||
vdev_nss_2g :
|
||||
vdev_nss_5g);
|
||||
}
|
||||
|
|
@ -812,9 +812,7 @@ int scm_calculate_bss_score(struct wlan_objmgr_psoc *psoc,
|
|||
}
|
||||
|
||||
sta_nss = scm_get_sta_nss(psoc,
|
||||
wlan_reg_freq_to_chan(
|
||||
pdev,
|
||||
entry->channel.chan_freq),
|
||||
entry->channel.chan_freq,
|
||||
score_config->vdev_nss_24g,
|
||||
score_config->vdev_nss_5g);
|
||||
|
||||
|
|
|
|||
|
|
@ -1380,7 +1380,7 @@ ucfg_scan_init_chanlist_params(struct scan_start_request *req,
|
|||
req->scan_req.chan_list.chan[idx].freq =
|
||||
(chan_list[idx] > WLAN_24_GHZ_BASE_FREQ) ?
|
||||
chan_list[idx] :
|
||||
wlan_reg_chan_to_freq(pdev, chan_list[idx]);
|
||||
wlan_reg_legacy_chan_to_freq(pdev, chan_list[idx]);
|
||||
if (phymode)
|
||||
req->scan_req.chan_list.chan[idx].phymode =
|
||||
phymode[idx];
|
||||
|
|
|
|||
Loading…
Reference in a new issue