qcacmn: Add support to configure spectral scan bandwidth
Add support to configure spectral scan bandwidth as provided by the user. Validate the user configured value before applying it. As the spectral scan bandwidth is an optional parameter, when the user doesn't configure it, use configure the spectral scan bandwidth to the maximum value supported by the target for the current operating bandwidth. Also, populate the spectral scan bandwidths supported for different operating bandwidths on different targets. CRs-Fixed: 3042424 Change-Id: I266aa5489b0ce5c149968067a06e1cc65bb4e3b7
Bu işleme şunda yer alıyor:

işlemeyi yapan:
Madan Koyyalamudi

ebeveyn
697dce6937
işleme
aead8c4d39
@@ -91,6 +91,8 @@ const struct nla_policy spectral_scan_policy[
|
||||
.type = NLA_U8},
|
||||
[QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_DMA_BUFFER_DEBUG] = {
|
||||
.type = NLA_U8},
|
||||
[QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_BANDWIDTH] = {
|
||||
.type = NLA_U8},
|
||||
};
|
||||
|
||||
const struct nla_policy spectral_scan_get_status_policy[
|
||||
@@ -126,6 +128,7 @@ static void wlan_spectral_intit_config(struct spectral_config *config_req)
|
||||
config_req->ss_chn_mask = SPECTRAL_PHYERR_PARAM_NOVAL;
|
||||
config_req->ss_frequency.cfreq1 = SPECTRAL_PHYERR_PARAM_NOVAL;
|
||||
config_req->ss_frequency.cfreq2 = SPECTRAL_PHYERR_PARAM_NOVAL;
|
||||
config_req->ss_bandwidth = SPECTRAL_PHYERR_PARAM_NOVAL;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -369,6 +372,10 @@ int wlan_cfg80211_spectral_scan_config_and_start(struct wiphy *wiphy,
|
||||
config_req.ss_frequency.cfreq2 = nla_get_u32(tb
|
||||
[QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_FREQUENCY_2]);
|
||||
|
||||
if (tb[QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_BANDWIDTH])
|
||||
config_req.ss_bandwidth = nla_get_u8(tb
|
||||
[QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_BANDWIDTH]);
|
||||
|
||||
if (tb[QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_MODE]) {
|
||||
status = convert_spectral_mode_nl_to_internal(nla_get_u32(tb
|
||||
[QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_MODE]), &sscan_mode);
|
||||
@@ -676,7 +683,10 @@ int wlan_cfg80211_spectral_scan_get_config(struct wiphy *wiphy,
|
||||
sconfig->ss_frequency.cfreq1) ||
|
||||
nla_put_u32(skb,
|
||||
QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_FREQUENCY_2,
|
||||
sconfig->ss_frequency.cfreq2))
|
||||
sconfig->ss_frequency.cfreq2) ||
|
||||
nla_put_u8(skb,
|
||||
QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_BANDWIDTH,
|
||||
sconfig->ss_bandwidth))
|
||||
|
||||
goto fail;
|
||||
|
||||
|
Yeni konuda referans
Bir kullanıcı engelle