mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-10 14:19:09 -04:00
qcacmn: Allow all bands in DFS chanwidth check
With the current implementation, the chanwidth of the Agile channel (for both PreCAC/RCAC) is the same as (or less than) as the chanwidth of DFS curchan. The width of the DFS curchan is determined in the function dfs_find_curchwidth_and_center_chan_for_freq which calls a macro WLAN_IS_CHAN_11AXA_HE80 for 80 MHz which checks if the channel is a 5G channel and 80 MHz. As a result, for wideband (i.e radio has both 5 and 6Ghz channels), if the curchan is a 6GHz channel this check fails which leads to invalid chanwidth and RCAC does not start. Fix this by checking the chanwidth of the DFS curchan for both 5GHz and 6GHz in case of 11AX. Change-Id: I9aef64cea1d442fc31b2314da08baba7769650f2
This commit is contained in:
parent
223c1e5865
commit
86f1d1d9b3
1 changed files with 45 additions and 12 deletions
|
|
@ -35,6 +35,9 @@
|
|||
/* 5 GHz spectrum channel */
|
||||
#define WLAN_CHAN_5GHZ 0x0000000000000100
|
||||
|
||||
/* 6 GHz spectrum channel */
|
||||
#define WLAN_CHAN_6GHZ 0x0000001000000000
|
||||
|
||||
/* Radar found on channel */
|
||||
#define WLAN_CHAN_DFS_RADAR 0x0000000000001000
|
||||
|
||||
|
|
@ -193,44 +196,74 @@
|
|||
#define WLAN_CHAN_11AXA_HE20 \
|
||||
(WLAN_CHAN_5GHZ | WLAN_CHAN_HE20)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE20_6G \
|
||||
(WLAN_CHAN_6GHZ | WLAN_CHAN_HE20)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE40PLUS \
|
||||
(WLAN_CHAN_5GHZ | WLAN_CHAN_HE40PLUS)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE40PLUS_6G \
|
||||
(WLAN_CHAN_6GHZ | WLAN_CHAN_HE40PLUS)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE40MINUS \
|
||||
(WLAN_CHAN_5GHZ | WLAN_CHAN_HE40MINUS)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE40MINUS_6G \
|
||||
(WLAN_CHAN_6GHZ | WLAN_CHAN_HE40MINUS)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE80 \
|
||||
(WLAN_CHAN_5GHZ | WLAN_CHAN_HE80)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE80_6G \
|
||||
(WLAN_CHAN_6GHZ | WLAN_CHAN_HE80)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE160 \
|
||||
(WLAN_CHAN_5GHZ | WLAN_CHAN_HE160)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE160_6G \
|
||||
(WLAN_CHAN_6GHZ | WLAN_CHAN_HE160)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE80_80 \
|
||||
(WLAN_CHAN_5GHZ | WLAN_CHAN_HE80_80)
|
||||
|
||||
#define WLAN_CHAN_11AXA_HE80_80_6G \
|
||||
(WLAN_CHAN_6GHZ | WLAN_CHAN_HE80_80)
|
||||
|
||||
#define WLAN_IS_CHAN_11AXA_HE20(_c) \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE20) == \
|
||||
WLAN_CHAN_11AXA_HE20)
|
||||
((((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE20) == \
|
||||
WLAN_CHAN_11AXA_HE20) || \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE20_6G) == \
|
||||
WLAN_CHAN_11AXA_HE20_6G))
|
||||
|
||||
#define WLAN_IS_CHAN_11AXA_HE40PLUS(_c) \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE40PLUS) == \
|
||||
WLAN_CHAN_11AXA_HE40PLUS)
|
||||
((((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE40PLUS) == \
|
||||
WLAN_CHAN_11AXA_HE40PLUS) || \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE40PLUS_6G) == \
|
||||
WLAN_CHAN_11AXA_HE40PLUS_6G))
|
||||
|
||||
#define WLAN_IS_CHAN_11AXA_HE40MINUS(_c) \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE40MINUS) == \
|
||||
WLAN_CHAN_11AXA_HE40MINUS)
|
||||
((((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE40MINUS) == \
|
||||
WLAN_CHAN_11AXA_HE40MINUS) || \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE40MINUS_6G) == \
|
||||
WLAN_CHAN_11AXA_HE40MINUS_6G))
|
||||
|
||||
#define WLAN_IS_CHAN_11AXA_HE80(_c) \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE80) == \
|
||||
WLAN_CHAN_11AXA_HE80)
|
||||
((((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE80) == \
|
||||
WLAN_CHAN_11AXA_HE80) || \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE80_6G) == \
|
||||
WLAN_CHAN_11AXA_HE80_6G))
|
||||
|
||||
#define WLAN_IS_CHAN_11AXA_HE160(_c) \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE160) == \
|
||||
WLAN_CHAN_11AXA_HE160)
|
||||
((((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE160) == \
|
||||
WLAN_CHAN_11AXA_HE160) || \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE160_6G) == \
|
||||
WLAN_CHAN_11AXA_HE160_6G))
|
||||
|
||||
#define WLAN_IS_CHAN_11AXA_HE80_80(_c) \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE80_80) == \
|
||||
WLAN_CHAN_11AXA_HE80_80)
|
||||
((((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE80_80) == \
|
||||
WLAN_CHAN_11AXA_HE80_80) || \
|
||||
(((_c)->dfs_ch_flags & WLAN_CHAN_11AXA_HE80_80_6G) == \
|
||||
WLAN_CHAN_11AXA_HE80_80_6G))
|
||||
|
||||
#define WLAN_IS_CHAN_DFS(_c) \
|
||||
(((_c)->dfs_ch_flagext & \
|
||||
|
|
|
|||
Loading…
Reference in a new issue