qcacmn: Add MCL/SAP DCS process after AFC event update

When AFC event come and update 6 GHz SP channels' state and power
attribution, SAP which already started on 5 GHz or 6 GHz channel
can move in or out from SP channel, which has higher tx power limit.

SAP target channel/bandwidth is decided by ACS channel select callback
register to SAP module, which will take channel max tx power limit
into account.

After target channel/bandwidth determined, SAPs move to same target
channel/bandwidth with eCSA process. If violate any concurrency
limitation, AFC DCS process should abort.

Add AFC component id and reference id.

Change-Id: Iba6933a30c0957eabf549fd6c8442bed547e8152
CRs-Fixed: 3204172
Šī revīzija ir iekļauta:
Will Huang
2022-05-10 16:34:50 +08:00
revīziju iesūtīja Madan Koyyalamudi
vecāks 051821c54f
revīzija dc9e47060f
10 mainīti faili ar 630 papildinājumiem un 3 dzēšanām

Parādīt failu

@@ -28,12 +28,14 @@
* @WLAN_HOST_DCS_CWIM: continuous wave interference
* @WLAN_HOST_DCS_WLANIM: wlan interference stats
* @WLAN_HOST_DCS_AWGNIM: additive white Gaussian noise (awgn) interference
* @WLAN_HOST_DCS_AFC: AFC data update 6 GHz SP channels
*/
enum wlan_host_dcs_type {
WLAN_HOST_DCS_NONE = 0, /* 0x0 */
WLAN_HOST_DCS_CWIM = BIT(0), /* 0x1 */
WLAN_HOST_DCS_WLANIM = BIT(1), /* 0x2 */
WLAN_HOST_DCS_AWGNIM = BIT(2), /* 0x4 */
WLAN_HOST_DCS_AFC = BIT(3), /* 0x8 */
};
/**

Parādīt failu

@@ -1,5 +1,6 @@
/*
* Copyright (c) 2020-2021, The Linux Foundation. All rights reserved.
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -36,5 +37,13 @@
*/
QDF_STATUS tgt_dcs_process_event(struct wlan_objmgr_psoc *psoc,
struct wlan_host_dcs_event *event);
#ifdef CONFIG_AFC_SUPPORT
/**
* tgt_afc_trigger_dcs() - AFC event DCS process
* @pdev: pointer to pdev object
*
* Return: QDF_STATUS
*/
QDF_STATUS tgt_afc_trigger_dcs(struct wlan_objmgr_pdev *pdev);
#endif
#endif /* __WLAN_DCS_TGT_API_H__ */

Parādīt failu

@@ -1,6 +1,6 @@
/*
* Copyright (c) 2020-2021, The Linux Foundation. All rights reserved.
* Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved.
* Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -49,6 +49,21 @@ typedef QDF_STATUS (*dcs_switch_chan_cb)(struct wlan_objmgr_vdev *vdev,
qdf_freq_t tgt_freq,
enum phy_ch_width tgt_width);
/**
* typedef dcs_afc_select_chan_cb() - DCS callback for AFC channel selection
* @arg: pointer to argument
* @vdev_id: vdev id
* @cur_freq: current channel frequency
* @cur_bw: current channel bandwidth
* @pref_bw: pointer to bandwidth of prefer bandwidth when input, and target
* bandwidth switch to when output
*/
typedef qdf_freq_t (*dcs_afc_select_chan_cb)(void *arg,
uint32_t vdev_id,
qdf_freq_t cur_freq,
enum phy_ch_width cur_bw,
enum phy_ch_width *pref_bw);
#ifdef DCS_INTERFERENCE_DETECTION
/**
* ucfg_dcs_register_cb() - API to register dcs callback
@@ -90,6 +105,18 @@ void ucfg_dcs_register_user_cb(struct wlan_objmgr_psoc *psoc,
QDF_STATUS ucfg_dcs_register_awgn_cb(struct wlan_objmgr_psoc *psoc,
dcs_switch_chan_cb cb);
/**
* ucfg_dcs_register_afc_sel_chan_cb() - API to register SAP channel selection
* callback for AFC DCS
* @psoc: pointer to psoc object
* @cb: dcs user callback to be registered
* @arg: argument
*
* Return: QDF_STATUS
*/
QDF_STATUS ucfg_dcs_register_afc_sel_chan_cb(struct wlan_objmgr_psoc *psoc,
dcs_afc_select_chan_cb cb,
void *arg);
/**
* ucfg_wlan_dcs_cmd(): API to send dcs command
* @psoc: pointer to psoc object