ath11k: add multiple bssid support
PATCH v5 1/1 ath11k: add multiple bssid support
Add the required wmi support and make use of it in the beacon template code. We need to split the beacon code up into 2 code paths so that we can also send EMA templates.
Signed-off-by John Crispin <[email protected]>
---
The patch depends on the multiple bssid and bss color series.
Changes in V5
* rebase on latest next tree
drivers/net/wireless/ath/ath11k/hw.c | 2 + drivers/net/wireless/ath/ath11k/mac.c | 184 ++++++++++++++++++++++---- drivers/net/wireless/ath/ath11k/wmi.c | 30 ++++- drivers/net/wireless/ath/ath11k/wmi.h | 88 +++++++++++- 4 files changed, 269 insertions(+), 35 deletions(-)
drivers/net/wireless/ath/ath11k/hw.c +2 -0
@@ -129,6 +129,8 @@ static void ath11k_init_wmi_config_ipq8074(struct ath11k_base *ab, config->peer_map_unmap_v2_support =1 ; config->twt_ap_pdev_count =2 ; config->twt_ap_sta_count =1000 ; + config->ema_max_vap_cnt =16 ; + config->ema_max_profile_period =8 ; } static int ath11k_hw_mac_id_to_pdev_id_ipq8074(struct ath11k_hw_params *hw,
drivers/net/wireless/ath/ath11k/mac.c +159 -25
320 lines not on this page · raw message
drivers/net/wireless/ath/ath11k/wmi.c +23 -7
@@ -647,6 +647,7 @@ int ath11k_wmi_vdev_create(struct ath11k *ar, u8 *macaddr, cmd->vdev_subtype = param->subtype; cmd->num_cfg_txrx_streams =WMI_NUM_SUPPORTED_BAND_MAX ; cmd->pdev_id = param->pdev_id; +ether_addr_copy (cmd->vdev_macaddr.addr, macaddr); ptr = skb->data +sizeof (*cmd);
@@ -861,6 +862,12 @@ int ath11k_wmi_vdev_start(struct ath11k *ar, struct wmi_vdev_start_req_arg *arg, cmd->flags |=WMI_VDEV_START_HIDDEN_SSID ;if (arg->pmf_enabled) cmd->flags |=WMI_VDEV_START_PMF_ENABLED ; + +if (test_bit (WMI_TLV_SERVICE_MBSS_PARAM_IN_VDEV_START_SUPPORT , + ar->ab->wmi_ab.svc_map)) { + cmd->mbss_capability_flags = arg->mbss_capability_flags; + cmd->vdevid_trans = arg->vdevid_trans; + } } cmd->flags |=WMI_VDEV_START_LDPC_RX_ENABLED ;
@@ -904,7 +911,7 @@ int ath11k_wmi_vdev_start(struct ath11k *ar, struct wmi_vdev_start_req_arg *arg,return ret; } -int ath11k_wmi_vdev_up (struct ath11k *ar,u32 vdev_id,u32 aid,const u8 *bssid) +int ath11k_wmi_vdev_up (struct ath11k *ar,struct vdev_up_params *params) {struct ath11k_pdev_wmi *wmi = ar->wmi;struct wmi_vdev_up_cmd *cmd;
@@ -919,10 +926,14 @@ int ath11k_wmi_vdev_up(struct ath11k *ar, u32 vdev_id, u32 aid, const u8 *bssid) cmd->tlv_header =FIELD_PREP (WMI_TLV_TAG ,WMI_TAG_VDEV_UP_CMD ) |FIELD_PREP (WMI_TLV_LEN ,sizeof (*cmd) -TLV_HDR_SIZE ); - cmd->vdev_id = vdev_id; - cmd->vdev_assoc_id = aid; + cmd->vdev_id = params->vdev_id; + cmd->vdev_assoc_id = params->aid; + cmd->profile_idx = params->profile_idx; + cmd->profile_num = params->profile_num; -ether_addr_copy (cmd->vdev_bssid.addr, bssid); +if (params->trans_bssid) +ether_addr_copy (cmd->trans_bssid.addr, params->trans_bssid); +ether_addr_copy (cmd->vdev_bssid.addr, params->bssid); ret =ath11k_wmi_cmd_send (wmi, skb,WMI_VDEV_UP_CMDID );if (ret) {
@@ -931,8 +942,9 @@ int ath11k_wmi_vdev_up(struct ath11k *ar, u32 vdev_id, u32 aid, const u8 *bssid) }ath11k_dbg (ar->ab,ATH11K_DBG_WMI , -"WMI mgmt vdev up id 0x%x assoc id %d bssid %pM\n" , - vdev_id, aid, bssid); +"WMI mgmt vdev up id 0x%x assoc id %d idx %d num %d bssid %pM trans_bssid %pM\n" , + params->vdev_id, params->aid, params->profile_idx, params->profile_num, + params->bssid, params->trans_bssid);return ret; }
@@ -1579,7 +1591,7 @@ int ath11k_wmi_send_bcn_offload_control_cmd(struct ath11k *ar,int ath11k_wmi_bcn_tmpl (struct ath11k *ar,u32 vdev_id,struct ieee80211_mutable_offsets *offs, -struct sk_buff *bcn) +struct sk_buff *bcn,u32 ema_params) {struct ath11k_pdev_wmi *wmi = ar->wmi;struct wmi_bcn_tmpl_cmd *cmd;
@@ -1604,6 +1616,8 @@ int ath11k_wmi_bcn_tmpl(struct ath11k *ar, u32 vdev_id, cmd->csa_switch_count_offset = offs->cntdwn_counter_offs[0 ]; cmd->ext_csa_switch_count_offset = offs->cntdwn_counter_offs[1 ]; cmd->buf_len = bcn->len; + cmd->mbssid_ie_offset = offs->multiple_bssid_offset; + cmd->ema_params = ema_params; ptr = skb->data +sizeof (*cmd);
@@ -3203,6 +3217,8 @@ ath11k_wmi_copy_resource_config(struct wmi_resource_config *wmi_cfg, wmi_cfg->sched_params = tg_cfg->sched_params; wmi_cfg->twt_ap_pdev_count = tg_cfg->twt_ap_pdev_count; wmi_cfg->twt_ap_sta_count = tg_cfg->twt_ap_sta_count; + wmi_cfg->ema_max_vap_cnt = tg_cfg->ema_max_vap_cnt; + wmi_cfg->ema_max_profile_period = tg_cfg->ema_max_profile_period; } static int ath11k_init_cmd_send(struct ath11k_pdev_wmi *wmi,
drivers/net/wireless/ath/ath11k/wmi.h +85 -3
155 lines not on this page · raw message
Signature · 7 lines
2.25.1 -- ath11k mailing list [email protected] http://lists.infradead.org/mailman/listinfo/ath11k