Currently, if the country code which is going to be set is the
same as the country currently being used, it will be ignored.
It does not consider its country code source. This causes the
working of 11d logic unexpected.
To fix this issue, check the country source when trying to set
the same country code.
CRs-Fixed: 2583172
Change-Id: I9c574a62d11676bc0305510f1da9848cc044f874
To support dynamic mode switch (phase 2), correct phy_id
should be used. Instead of pdev_id, target phy_id should
be used to retrieve correct channel range sent in target
capabilities (mac_phy_caps).
Change-Id: If0e2503cc99636b775721ecb3628290d19e5575c
Currently get channel list with power api fills only
channel number and tx power, fill center frequency also
in the response with this api.
Change-Id: Ib4487e20d7da0c59d6b4a041deac4d4ecc8dd8c1
CRs-Fixed: 2597550
Add an API wlan_reg_get_opclass_details, to get the operating class
table details from the regulatory component. Also, add a new structure
regdmn_ap_cap_opclass_t in the regulatory component, to fill members
of the mapapcap_t structure.
Change-Id: I8b6a3867a766038663c10ce2f01a8b7d310c7375
CRs-Fixed: 2580505
Parameter freq type has a conflict in reg_is_dsrc_freq(qdf_freq_t freq)
and reg_is_dsrc_freq(uint16_t freq) functions.
Change the type to qdf_freq_t in these functions.
Change-Id: I4c348778a7cb2fd588799332241701357de90422
CRs-Fixed: 2595642
The variables center_freq_seg0 and center_freq_seg1 in struct
ch_params are used to represent channel numbers. Their types
were wrongly changed to qdf_freq_t in change ID
e205befb82f643808973286ae578d7add7738eec. Change their type
back to uint8_t.
Change-Id: I13c629850bf207c6088b44c8695167e96dc33476
Add the API wlan_reg_get_opclass_from_freq_width, to give country_iso,
channel frequency, channel width and behaviour limit as input, and get
the operating class as output.
Change-Id: I96c39119ab855d10965b2603e8b15c21699daa68
CRs-Fixed: 2583789
When enalbe DSRC feature, member reg_dmn_pair_id of struct
country_code_to_reg_domain g_all_countries[] may equal FCC10_FCCA.
However, FCC10_FCCA can't be found in array g_reg_dmn_pairs[].
So, add FCC10_FCCA into arry g_reg_dmn_pairs[].
And, fix one compile issue.
Change-Id: I6069c43505e15312d8bd9be48495998c31f1f8eb
CRs-Fixed: 2590094
Add the operating classes 129 and 130 to the US, Europe, Japan,
and Global operating class tables in the regulatory component.
Change-Id: I930019c2b14451de57a92c069a77c27fb56d273b
CRs-Fixed: 2587094
In regulatory non-offloads feature, send conformance_test_limit_2G,
conformance_test_limit_5G, reg_domain, reg_domain_2G and reg_domain_5G
information to firmware using WMI_PDEV_SET_REGDOMAIN_CMDID.
If all these attributes are not populated then CTL power limit is
not applied by the firmware.
Change-Id: I1523ab447aec64ec0af42da32318136f90fd17ca
CRs-Fixed: 2518246
Currently CTRY_JAPAN15 is not there in host regulatory
database and it is still in use. If CTRY_JAPAN15 is set
from BDF, driver load will fail as this country is not
present in host driver database.
To address this issue add CTRY_JAPAN15 to regdb.
Change-Id: I031b766ac34d57193ded4856b1396306cd5bb76d
CRs-Fixed: 2590635
Fix compile issues when some features are disabled, the features are:
BUILD_DEBUG_VERSION
CONFIG_CP_STATS
CONFIG_HOST_OPCLASS
CONFIG_FEATURE_ROAM_DEBUG
There are some other features depends on each other, so enabled features to
qcs40x.snoc.perf_defconfig, the features are:
CONFIG_WLAN_FEATURE_FILS
CONFIG_WMI_ROAM_SUPPORT
CONFIG_WMI_STA_SUPPORT
CONFIG_REG_CLIENT
CONFIG_WLAN_FEATURE_DP_BUS_BANDWIDTH
CONFIG_WMI_CONCURRENCY_SUPPORT
CONFIG_LL_DP_SUPPORT
Change-Id: I6fa1eacb79576a955e593dbb9ac52083742275e3
CRs-Fixed: 2584839
Depending on the requirement, a bigger size or a smaller size for
the frequency variable can be chosen. The advantages of each size
are described below:
Advantage of a bigger size:
When two technologies (e.g. 802.11AX and 802.11AD) are controlled
by the same driver software, the frequency range may be very large
and a bigger size (e.g. 32bit integer) is more appropriate.
Advantage of a smaller size:
When the frequency range is not very large, a smaller size (e.g.
16bit integer) can be used. It saves a large amount of space especially
when many large arrays containing elements of this type/size are
defined in the driver.
Also, change the size of the IEEE channel variables to unsigned
8-bit integer.
Change-Id: Ie205befb82f643808973286ae578d7add7738eec
CRs-Fixed: 2586071
Update the regulatory database with the following changes:
1) Add full reg domain FCC15_FCCA, FCC16_FCCA and FCC17_FCCA.
2) Add associated 5G reg rules and channel bands for the new regdomains.
Change-Id: I2b6038d0f106555adf650c12ca48efcaacc69071
CRs-Fixed: 2582502
Introduce a new DFS domain MKKN that supports new w53 Japan RADAR
pattern only.
Initialize a new empty RADAR table dfs_mkkn_radars for MKKN DFS domain.
Map The 5G regdamain MKK17 to the new DFS domain MKKN to make sure that
the new w53 Radar pulses should be detected only by JP country or
MKK17 5G regdomain.
Change-Id: Ib0f6a7e98353c9930e90703ead2342b932e491e3
CRs-Fixed: 2575347
Remove the unused API wlan_reg_get_5g_bonded_channel_and_state in the
regulatory component
Change-Id: I45c9b083dfb6faf6c97293d54200ed4f15a7d289
CRs-Fixed: 2574154
1) Add the API wlan_reg_get_5g_bonded_channel_and_state_for_freq
that returns the state for a 5G or 6G channel frequency,
based on the channel width and and state of the bonded channels.
2) In the API target_if_calculate_center_freq, remove the instances
of IEEE channel number, and provide regulatory support, with the
channel frequency based structure - bonded_channel_freq and the API -
wlan_reg_get_5g_bonded_channel_and_state_for_freq.
3) Remove the usage of band_info and replace it with reg_wifi_band within
the target_if of the spectral module.
Change-Id: If5108b55097208d33fafb48968ea8b6dc83011fa
CRs-Fixed: 2571906
Move MACRO definition of TWOG_CHAN_6_IN_MHZ out of
ifdef CONFIG_CHAN_FREQ_API, move to public header file,
then other components can use it.
Change-Id: Ieb4b2b167c664246d39949ad4f8d53eda6b9d7de
CRs-Fixed: 2580207
Initialize channel_map to "us" at regulatory init.
Use NUM_6GHZ_CHANNELS to get 6Ghz channel numbers
instead of MAX_6GHZ_CHANNEL.
Change-Id: Ifed996c1a528c8a3c0a29d3959f17dff6d298193
CRs-Fixed: 2949971
While checking if a channel frequency is 6Ghz PSC frequency within
wlan_reg_is_6ghz_psc_chan_freq, check the remainder of the expression,
instead of quotient.
Change-Id: Ia40d7cd8485f9f8eb90222f9a3454d46e681681b
CRs-Fixed: 2572914
Add regulatory APIs reg_get_unii_5g_bitmap and ucfg_reg_get_unii_5g_bitmap
to retrieve the value of "unii_5g_bitmap" stored in regulatory pdev
private object.
CRs-Fixed: 2574642
Change-Id: Iffb004b7fc9d9fbcf1972eb6f527529024e49c70
The 5G cellular RF band and wifi frequency band of UNII-1
(IEEE channels 36, 40, 44, 48) and UNII-2A band (52, 56,
60, 64) can coexist.
UNII-1 and UNII-2A are represented by bits 0x1 and 0x2 respectively in
this implementation. The user space command should set the bits by
applying the following algorithm:
1) To disable only the UNII-1 band channels, set the value as 0x1.
2) To disable only the UNII-2A band channels, set the value as 0x2.
3) To disable both the UNII-1 and UNII-2A band channels, set the
value as 0x3.
4) To restore both the UNII-1 and UNII-2A band channels, set the
value as 0x0.
Change-Id: I8ff747e53b079ee9e0dc762980aee0eea32b23a5
CRs-Fixed: 2571546
During pdev create callback, pdev reference cannot be taken. Hence,
channel change callbacks cannot be called during pdev create. So
call the callbacks during regulatory_pdev_open. Also dont check
if regulatory_pdev_open fails.
Change-Id: I9d444f952418be983e4ac2182581d03bba02b198
CRs-Fixed: 2572487
Regulatory module calls registered callbacks when channel list is changed.
But channel list may not have been received when path for callbacks is
reached. So keep a track if channel list has been received. If not, do
not call the callbacks.
Change-Id: I2e1a6e442b0d5c79e786806e00b1c50c9491dae0
CRs-Fixed: 2563759
Update regdb with QCA regulatory database version 30 with following
changes:
1. Change APL11 and APL19 RD defs to FCC Radar Patterns.
2. Change 2g reg domain for Argentina to ETSIC
3. Change 5g reg domain for Argentina to APL16 for WIN and
APL17 for MCL and DSRC.
4. Change 2g reg domain for Indonesia to ETSID
5. Change APL2 power to 20.
6. Change Radar detection pattern for APL11 to FCC
7. Change CTL for APL14 to MKK
8. Change Radar detection pattern for APL19 to FCC
9. Add new reg domain APL24
10. Change ETSID power to 20.
11. Add full reg domain APL2_ETSID
12. Add full reg domain APL16_ETSIC
13. Add full reg domain APL17_ETSIC
14. Add full reg domain APL24_ETSIC
Change-Id: I8ce9696caefee89a9ab5606667c1619634e248c5
CRs-Fixed: 2548580
Add an API wlan_reg_chan_opclass_to_freq, that takes IEEE Channel
number and opclass as input and gives the channel center frequency
as output.
Change-Id: I09733d9dc27beb8f16037aa8653acededf32b715
CRs-Fixed: 2555042
As a part of the intermittent regulatory update, implement the following
changes,
- The country Japan should map to MKK17_MKKC regulatory domain.
- For regulatory domain MKK17_MKKC, channel 144 should be disabled by
default.
Change-Id: Ic920456fa885d9ed2b8d0419c6a261707eb10b4d
CRs-Fixed: 2560339
Add API to know whether 6ghz is supported. Also add API to know
whether an operating class is 6ghz operating class.
Change-Id: I75747502c0033e31d119e58a2254b220646bba10
CRs-Fixed: 2556998
Add starting frequency to each operating class. Further add behavior
limit to each operating class, if any. Behaviour limit is used for
80p80, 40 mhz low primary, etc operating class identification. Also
add 6-ghz operating classes 131-135 to the global operating class.
Also add APIs that are based on frequency instead of channel number.
Change-Id: Ic8756aada6c31ed2164f767ff1ae584b8bf055d2
CRs-Fixed: 2533419
4.9 GHz channels cannot be checked using channel number since channel
number can conflict with 2.4 GHz and 6 Ghz channels. So use frequency to
check if channel is 4.9 Ghz.
Change-Id: Ie201d2722edbc7f20ee4faa115910d92afaa3414
CRs-Fixed: 2552810
A component can register callback with regulatory component before channel
list is available.Therefore initialize channel map at time of regulatory
init. Also, call callback when pdev current channel list
is computed, at time of nol channel update.
Change-Id: I551e0ea3391710538f694c50fa7dc6f795f3196c
CRs-Fixed: 2555403
Update the APIs mentioned below, to handle invalid channel number and
freq value of less than or equal to 0:
1) wlan_reg_chan_band_to_freq
2) wlan_reg_freq_to_chan
3) wlan_reg_chan_to_freq
4) wlan_reg_legacy_chan_to_freq
Change-Id: I122658c974c550ff16bcfe1b664799a609c7ffcf
CRs-Fixed: 2550286
Print floods are observed in the APIs below:
1) reg_get_curr_regdomain
2) reg_is_etsi13_regdmn
3) reg_freq_to_chan
Add a new macro reg_err_rl and assign QDF_TRACE_ERROR_RL. Use reg_err_rl
instead of reg_err, to avoid print flood.
Change-Id: I5c1da71febd61449bfbff508797c60bb88849122
CRs-Fixed: 2552008
In reg_set_5g_channel_params if the input channel bandwidth
is 5MHz then while getting the next lower bandwidth out of
bound access occurs.
Fix out of bound access in getting next lower bandwidth value.
Change-Id: I309909661f0357d482387e92353024400a042295
CRs-Fixed: 2525496
Based on the ini "ignore_fw_reg_offload_ind" ignore regulatory
offload indicatin from fw.
Change-Id: Ia95b5bdda6ee1fcc2b07f28f997a7c80afcbc32b
CRs-Fixed: 2533001
Default pdev id is redundant now. Therefore remove def_pdev_id from
the regulatory component.
Change-Id: I383f904e373df0e7d02fb0e2d00141fcacebe82a
CRs-Fixed: 2505161
--Treat SRD channels as PASSIVE if INI enable_srd_chan_in_master_mode
is 0. Add API reg_modify_chan_list_for_srd_channels for this purpose.
Mark channels as PASSIVE in both driver and kernel. Do not add this API
for WIN use-cases.
--Make default value of enable_srd_chan_in_master_mode as 1. WIN needs
default value as 1. MCC can over-ride with INI.
--When pdev is added, compute pdev current channel list only after pdev
private object is attached to the pdev. Computation of current channel
list accesses the private object via the pdev.
--When a pdev is added and deleted, set and reset def_pdev_id
correctly. Currently reset is not being done when pdev is destroyed.
--When programming current country to the firmware, do not use
def_pdev_id, since def_pdev_id can be -1. Ask for response for all phys.
Program pending reply for every phy, since the reg-domain for all phys
need to be re-programmed.
--Remove reg_reset_reg_rules when pdev is processed, after addition of
master channel list. The psoc copy of master reg rules need not be
cleaned up.
Change-Id: I5eaa457b8819d7a22d2e592d1b79fff15b364f40
CRs-Fixed: 2491045
Ensure that at a time only one Agile Spectral scan is
happening across all the 5G pdevs in SBS mode.
CRs-Fixed: 2517522
Change-Id: If31a4451b82ce1d7d8a46bc604ca91bf4b6dac29
Rectify three issues in the Regulatory APIs as follows:
1) Within the API reg_update_nol_ch_for_freq, replace the call of
reg_get_chan_enum with reg_get_chan_enum_for_freq, as
reg_update_nol_ch_for_freq is a frequency based API.
2) Change the return type of wlan_reg_get_channel_reg_power_for_freq
to uint8_t and change the datatype of its parameter, freq, from uint32_t
to uint16_t.
3) Place the API wlan_reg_chan_to_freq, under the macro
CONFIG_CHAN_NUM_API, as it uses IEEE channel number as a parameter.
Change-Id: I1bc1d767d34cd97ca971bd7e12b685a55fb9a494
CRs-Fixed: 2531183
Add new APIs that return minimum and maximum channel frequency,
supported by regulatory domain.
Change-Id: I878bd6f4ff8fdbe28661769033c37a000aebf582
CRs-Fixed: 2538143
Make band related changes given below:
1. Add the API wlan_reg_chan_band_to_freq, that takes IEEE Channel Number
and bands as input and returns the Channel center frequency.
2. Add the API wlan_reg_freq_to_band, that takes frequency as input and
returns the corresponding band.
Change-Id: I8554f6a9c24e7508e8a551c5f318b643741f13c8
CRs-Fixed: 2523257
Add conversion from frequency to channel, for frequency falling
within two consecutive supported channels. Use the master
channel list of the pdev for the same. Add new API
wlan_reg_legacy_chan_to_freq to convert legacy 2G and 5G channel
number to frequency. Existing API wlan_reg_chan_to_freq would be
slowly deprecated.
Change-Id: Id7e1939b9e05b78c17751d13bb0b02a891f999ad
CRs-Fixed: 2526886
Validate user provided agile center frequency and throw
an error if it is invalid.
CRs-Fixed: 2529280
Change-Id: Ibb43dda98d29d8bc8360d1a204c67b64ca987ca6
Add the API wlan_reg_get_band_channel_list, to get the channel list from
the current channel list based on the input bandmask provided.
The bandmask may have more than one bands as input.
Change-Id: I082a5dd6a9ddb449d64d13e636f42ad58d2de16b
CRs-Fixed: 2523254