Following is the list of changes :-
1. Add an API dfs_agile_precac_cleanup to reset all dfs variables
while going from running to init state.
2. Add a parameter is_chan_found to dfs_prepare_agile_precac_chan and
make it true if a channel is available for PrCAC/RCAC.
3. Post event done to Agile SM when firmware returns ocac complete for
a particular agile channel.
4. Post event done if preCAC timer expires from driver for a particular
agile channel.
5. Remove the zero second timer mechanism of starting of Agile PreCAC,
instead regulate it completely using the Agile SM.
6. Add API dfs_is_agile_cac_enabled which checks if either PreCAC/RCAC
is enabled. Events are not posted to the Agile SM if none of these
are enabled.
7. Add API dfs_abort_agile_precac used to send abort to F/W for that
specific DFS index.
8. Add API dfs_init_agile_start_evt_handler to handle the start event in
init state of Agile SM. This checks if a channel is available for
PreCAC/RCAC.
9. In init and running state of the SM handle events for both PreCAC and
RCAC, while complete state is for RCAC alone.
10. Following is the algorithm implemented in the Agile SM :
The Agile SM is per psoc, create it when the psoc is created.
|
On receiving the VAP start resp, send a start event to the SM in
init state. In the start event handler check if a PreCAC/RCAC channel
is available and if found configure the agile channel params and send
a WMI to F/W.
|
A OCAC complete is received on completion of CAC by F/W or the host
timer might expire. In either case mark the channel as CAC done.
Check if interCAC was running and the channel is the des chan, if so
a primary channel change is automatically triggered.
|
In the event of mode switch/scan start/VAP down/primary channel change
while PreCAC is running a stop event is received. Clear all dfs
structures and go to init state.
|
On receiving a radar in the Agile channel, go to the init state and
set event as start. Radar in primary channel is taken care of by
ensuing VAP down up.
|
When no other channels are pending PreCAC, clean all dfs structures
and remain in the init state. PreCAC uses only init and running
states of the SM.
Change-Id: I231c79d381c7c3e192bea8ebff1ee6b5dc4a3cfa
Both (ETSI) PreCAC and RCAC are going to use use the same state
machine. The state machine drives the Agile engine and not very specific
to RCAC or PreCAC, therefore let the state machine be called agile state
machine and change the names of all the associated variables accordingly.
In this preparatory change, modify names of all APIs, states and events
to make them common to Agile RCAC and Agile PreCAC
Change-Id: I83835e0295bc97e1099c0e01fc6b2fce62437872
If START request is deferred due to RESTART pending logic, in few cases
it is leading to configuring two channels to FW.
This change checks desired channel of START req deferred VDEVs and updates
the desired channel with RESTART VDEV's desired channel
Change-Id: Ic69c10c08fd4d83aafcab97a71ce906564ab51f6
CRs-Fixed: 2713931
While finding RCAC frequency, if you're current bandwidth is 165MHz
(pine 80p80MHz), add 80p80_enabled flag for Rolling CAC random
channel selection, which allows the channel selection logic to
fallback to 160MHz bandwidth and find a channel.
CRs-Fixed: 2738917
Change-Id: I70add1b2a3c3252b1bd6bf99cffc9b9727be4f56
Currently, per-user information in Tx PPDU completion is allocated for
37 users though FW may send information for fewer number of users. In
new scheme, FW provides number of users in USERS_INFO TLV and host can
allocate the per-user struct based on this number. This can save memory
while processing each completion message.
Make related changes in tx capture files to use pointer instead of fixed
size member.
CRs-Fixed: 2730933
Change-Id: I8709665a481d64dc4ab086ce9b27e8837c38b53f
Enable ATF stats fearure commands and remove get_atf_stats.
Get ATF Stats command will be added as IOCTL command to use in
wlanconfig.
Change-Id: Ib029abf5401d9002151bbaa9eef1c199df3daa0c
Debugfs is added to store the last 30 ppdu desc and display
as readable format to user. Feature of storing ppdu desc is
enabled through debugfs and it is not enabled by default.
Change-Id: I85ff52760462abd9a6e33d082db45d8179e67c0d
During 6G development, CONFIG_CHAN_NUM_APIs are kept for backward
compatability. Remove CONFIG_CHAN_NUM_API macro and remove all the
references to any function defined/declared under the macro.
CRs-Fixed: 2711597
Change-Id: Iac5d57e4e0fb1fa54b0225a5cb206e8f1fe1353d
Currently, same user can be processed multiple times, which leads to
release ref count wrongly, with this, some of the users in PPDU
desc are never processed and can possibly cause memory leak.
Added a flag in PPDU user to indicate that the user is already
processed.
CRs-Fixed: 2718150
Change-Id: Ia00e0ad12999578157e9f8a6df0ad4763f828c88
when secondary unicast from station takes rx_to_tx path
and reaches host, enqueue directly to nss ap node.
Change-Id: I03b3e9488683376fa9a12c574ba230ebaa55c98d
For some peers, tx capture tid init is not invoked,
It is resulting in ppdu_desc leak.
Invoking tid init on tid peer update, if tid is not
initialized.
Change-Id: Ia49c7e6d093a42e57e8d9239a60ad0b8dabfcc5b
CRs-Fixed: 2718150
Skip protocol tag updating from msdu end TLV protocol tag meta data
when there is RXDMA REO entrance push error on monitor destination ring.
The attention and msdu end TLV is not updated reliably when there
is RXDMA REO entrance push error such as FCS error on monitor
destination ring.
Change-Id: I47ab7da3a239080c1ab608c5001f65c4849b7b3a
In autochannel switch feature, a user configured primary channel
is prioritized for preCAC and after preCAC completion, the channel
is used as the primary operating channel of the device.
To acheive this, the existing preCAC lists were reordered since
every entry of the list was of a fixed 80MHz bandwidth and the
channels to be prioritized were also provided as 80MHz. i.e the list
entry to be prioritized will be made as the list HEAD.
This logic was only possible because the preCAC lists were channels
of 80MHz bandwidth. After the agile 160MHz changes, the preCAC lists
were now of variable bandwidth, from 20-160MHz. Reordering a 160MHz
channel will not allow the expected 80MHz channel to run first.
To fix this issue in autochannel switch algorithm, instead of
reordering the lists,
1. Remember the user desired channels to be prioritized in
dfs structure.
2. Before picking a channel for preCAC, see if the autoswitch desired
channel is configured
3. If yes, check the preCAC state of those channels.
4. If the preCAC state is "PRECAC_REQUIRED", use this channel to run
preCAC.
CRs-Fixed: 2723206
Change-Id: Icd6d01adfae6dfa63d0733c5dae6d6494a660190
As part of vdev start response, dfs_precac_agile_start() is
called which is intended to set the agile active bit for
the VAP's pdev and start preCAC if possible and not already
running. The active bit for a dfs/pdev indicates that there
is at least one active VAP for that dfs/pdev object.
To set the "agile_precac_active" bit, the "cur_precac_dfs_index"
is used instead of the index of the "dfs" that calls the function.
"cur_precac_dfs_index" need not always indicate the "dfs" that
calls the function.
Consider a case where there are two active 5G radios (DBS_SBS),
both with preCAC enabled. For the first vdev start response of
radio A, dfs_precac_agile_start() is called which sets the agile
precac active bit for radio A and starts preCAC. Now for the
first vdev start response of radio B, dfs_precac_agile_start will
set the current preCAC index as active, which is radio A (which
was already set). The agile preCAC active bit is never set for
radio B even though it has an active VAP and agile capable.
Because of this, after radio A completes preCAC, radio B does
not get a chance to run preCAC for it's channels.
Set the agile precac active bit for the calling radio,
irrespective of which pdev is currently running preCAC, to allow
preCAC when the radio get's a chance.
CRs-Fixed: 2705681
Change-Id: Id11c910c69c85ce9ae03e7989e784a272d5cd905
Remove double validation of ppdu_user tx_ratekbps
and ppdu_user rate index while updating per peer
Tx statistics
Change-Id: I9d4b65556928b21ee6caa10fb15193c8705ad2af
Bring up a Cascade AP in HT80 mode, country DK and enable preCAC config.
During vap start, a preCAC channel is chosen by invoking
tgt_dfs_find_vht80_precac_chan_freq() and then
dfs_start_precac_timer_for_freq() is invoked to start the preCAC timer.
In dfs_start_precac_timer_for_freq(), the dfs pdev object is fetched
indexing cur_precac_dfs_index in DFS SOC object as follows:
"dfs_soc_obj->dfs_priv[dfs_soc_obj->cur_precac_dfs_index].dfs".
The cur_precac_dfs_index is initialized to 0xFF in dfs_rcac_sm_create().
This index is then over-written to the current DFS pdev index in case
of agile preCAC in dfs_prepare_agile_precac_chan() API. This API is not
invoked in case of legacy preCAC and hence cur_precac_dfs_index continues
to hold 0xFF. This leads to kernel paging request failure
and the system crashes.
Initialize 'cur_precac_dfs_index' to dfs->dfs_psoc_idx which holds
the index of the active dfs pdev.
CRs-Fixed: 2708233
Change-Id: I3aae7ea8f611d72bfe23c20cc2a34d94bba83485