ath11k_nss: Bump version 6.6.15 to 6.9.9

Signed-off-by: Sean Khan <datapronix@protonmail.com>
This commit is contained in:
Sean Khan 2024-07-13 03:03:05 -04:00
parent 177f3f0601
commit 6ec201e486
83 changed files with 995 additions and 2125 deletions

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -5530,7 +5530,7 @@ static int ath10k_mac_set_txbf_conf(stru
@@ -5527,7 +5527,7 @@ static int ath10k_mac_set_txbf_conf(stru
ar->wmi.vdev_param->txbf, value);
}
@ -9,7 +9,7 @@
struct ieee80211_vif *vif)
{
struct ath10k_vif *arvif = (void *)vif->drv_priv;
@@ -5552,6 +5552,7 @@ static void ath10k_update_vif_offload(st
@@ -5549,6 +5549,7 @@ static void ath10k_update_vif_offload(st
ath10k_warn(ar, "failed to set vdev %i TX encapsulation: %d\n",
arvif->vdev_id, ret);
}

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath10k/pci.c
+++ b/drivers/net/wireless/ath/ath10k/pci.c
@@ -1974,6 +1974,7 @@ static int ath10k_pci_hif_start(struct a
@@ -1975,6 +1975,7 @@ static int ath10k_pci_hif_start(struct a
ath10k_dbg(ar, ATH10K_DBG_BOOT, "boot hif start\n");
@ -10,7 +10,7 @@
ath10k_pci_irq_enable(ar);
--- a/drivers/net/wireless/ath/ath10k/sdio.c
+++ b/drivers/net/wireless/ath/ath10k/sdio.c
@@ -1862,6 +1862,7 @@ static int ath10k_sdio_hif_start(struct
@@ -1863,6 +1863,7 @@ static int ath10k_sdio_hif_start(struct
struct ath10k_sdio *ar_sdio = ath10k_sdio_priv(ar);
int ret;
@ -20,7 +20,7 @@
/* Sleep 20 ms before HIF interrupts are disabled.
--- a/drivers/net/wireless/ath/ath10k/core.c
+++ b/drivers/net/wireless/ath/ath10k/core.c
@@ -3702,6 +3702,9 @@ struct ath10k *ath10k_core_create(size_t
@@ -3722,6 +3722,9 @@ struct ath10k *ath10k_core_create(size_t
ath10k_core_set_coverage_class_work);
init_dummy_netdev(&ar->napi_dev);

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -4178,22 +4178,28 @@ static int ath11k_clear_peer_keys(struct
@@ -4186,22 +4186,28 @@ static int ath11k_clear_peer_keys(struct
int ret;
int i;
u32 flags = 0;
@ -35,7 +35,7 @@
DISABLE_KEY, addr, flags);
if (ret < 0 && first_errno == 0)
first_errno = ret;
@@ -4201,10 +4207,6 @@ static int ath11k_clear_peer_keys(struct
@@ -4209,10 +4215,6 @@ static int ath11k_clear_peer_keys(struct
if (ret < 0)
ath11k_warn(ab, "failed to remove peer key %d: %d\n",
i, ret);

View File

@ -20,7 +20,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -41,6 +41,8 @@
@@ -44,6 +44,8 @@
#define ATH11K_INVALID_HW_MAC_ID 0xFF
#define ATH11K_CONNECTION_LOSS_HZ (3 * HZ)
@ -29,7 +29,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
/* SMBIOS type containing Board Data File Name Extension */
#define ATH11K_SMBIOS_BDF_EXT_TYPE 0xF8
@@ -376,6 +378,17 @@ struct ath11k_vif_iter {
@@ -415,6 +417,17 @@ struct ath11k_vif_iter {
struct ath11k_vif *arvif;
};
@ -47,7 +47,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
struct ath11k_rx_peer_stats {
u64 num_msdu;
u64 num_mpdu_fcs_ok;
@@ -387,10 +400,6 @@ struct ath11k_rx_peer_stats {
@@ -426,10 +439,6 @@ struct ath11k_rx_peer_stats {
u64 non_ampdu_msdu_count;
u64 stbc_count;
u64 beamformed_count;
@ -58,7 +58,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
u64 coding_count[HAL_RX_SU_MU_CODING_MAX];
u64 tid_count[IEEE80211_NUM_TIDS + 1];
u64 pream_cnt[HAL_RX_PREAMBLE_MAX];
@@ -398,6 +407,8 @@ struct ath11k_rx_peer_stats {
@@ -437,6 +446,8 @@ struct ath11k_rx_peer_stats {
u64 rx_duration;
u64 dcm_count;
u64 ru_alloc_cnt[HAL_RX_RU_ALLOC_TYPE_MAX];
@ -69,7 +69,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
#define ATH11K_HE_MCS_NUM 12
--- a/drivers/net/wireless/ath/ath11k/debugfs_sta.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs_sta.c
@@ -10,6 +10,7 @@
@@ -11,6 +11,7 @@
#include "peer.h"
#include "debug.h"
#include "dp_tx.h"
@ -77,7 +77,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
#include "debugfs_htt_stats.h"
void ath11k_debugfs_sta_add_tx_stats(struct ath11k_sta *arsta,
@@ -247,8 +248,14 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
@@ -248,8 +249,14 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
struct ath11k *ar = arsta->arvif->ar;
struct ath11k_rx_peer_stats *rx_stats = arsta->rx_stats;
int len = 0, i, retval = 0;
@ -93,7 +93,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
if (!rx_stats)
return -ENOENT;
@@ -279,14 +286,6 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
@@ -280,14 +287,6 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
rx_stats->num_mpdu_fcs_ok);
len += scnprintf(buf + len, size - len, "Num of MPDUs with FCS error: %llu\n",
rx_stats->num_mpdu_fcs_err);
@ -108,7 +108,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
len += scnprintf(buf + len, size - len, "BCC %llu LDPC %llu\n",
rx_stats->coding_count[0], rx_stats->coding_count[1]);
len += scnprintf(buf + len, size - len,
@@ -301,14 +300,96 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
@@ -302,14 +301,96 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
len += scnprintf(buf + len, size - len, "TID(0-15) Legacy TID(16):");
for (i = 0; i <= IEEE80211_NUM_TIDS; i++)
len += scnprintf(buf + len, size - len, "%llu ", rx_stats->tid_count[i]);
@ -212,7 +212,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
len += scnprintf(buf + len, size - len,
"\nDCM: %llu\nRU: 26 %llu 52: %llu 106: %llu 242: %llu 484: %llu 996: %llu\n",
rx_stats->dcm_count, rx_stats->ru_alloc_cnt[0],
@@ -847,6 +928,40 @@ static const struct file_operations fops
@@ -848,6 +929,40 @@ static const struct file_operations fops
.llseek = default_llseek,
};
@ -253,7 +253,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
void ath11k_debugfs_sta_op_add(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
struct ieee80211_sta *sta, struct dentry *dir)
{
@@ -855,9 +970,12 @@ void ath11k_debugfs_sta_op_add(struct ie
@@ -856,9 +971,12 @@ void ath11k_debugfs_sta_op_add(struct ie
if (ath11k_debugfs_is_extd_tx_stats_enabled(ar))
debugfs_create_file("tx_stats", 0400, dir, sta,
&fops_tx_stats);
@ -269,7 +269,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
&fops_htt_peer_stats);
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -2762,10 +2762,43 @@ exit:
@@ -2763,10 +2763,43 @@ exit:
return total_msdu_reaped;
}
@ -313,7 +313,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
u32 num_msdu;
int i;
@@ -2775,6 +2808,8 @@ static void ath11k_dp_rx_update_peer_sta
@@ -2776,6 +2809,8 @@ static void ath11k_dp_rx_update_peer_sta
arsta->rssi_comb = ppdu_info->rssi_comb;
ewma_avg_rssi_add(&arsta->avg_rssi, ppdu_info->rssi_comb);
@ -322,7 +322,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
num_msdu = ppdu_info->tcp_msdu_count + ppdu_info->tcp_ack_msdu_count +
ppdu_info->udp_msdu_count + ppdu_info->other_msdu_count;
@@ -2791,18 +2826,6 @@ static void ath11k_dp_rx_update_peer_sta
@@ -2792,18 +2827,6 @@ static void ath11k_dp_rx_update_peer_sta
ppdu_info->tid = IEEE80211_NUM_TIDS;
}
@ -341,7 +341,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
if (ppdu_info->ldpc < HAL_RX_SU_MU_CODING_MAX)
rx_stats->coding_count[ppdu_info->ldpc] += num_msdu;
@@ -2831,8 +2854,6 @@ static void ath11k_dp_rx_update_peer_sta
@@ -2832,8 +2855,6 @@ static void ath11k_dp_rx_update_peer_sta
rx_stats->dcm_count += ppdu_info->dcm;
rx_stats->ru_alloc_cnt[ppdu_info->ru_alloc] += num_msdu;
@ -350,7 +350,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
BUILD_BUG_ON(ARRAY_SIZE(arsta->chain_signal) >
ARRAY_SIZE(ppdu_info->rssi_chain_pri20));
@@ -2841,6 +2862,52 @@ static void ath11k_dp_rx_update_peer_sta
@@ -2842,6 +2863,52 @@ static void ath11k_dp_rx_update_peer_sta
rx_stats->rx_duration += ppdu_info->rx_duration;
arsta->rx_duration = rx_stats->rx_duration;
@ -433,7 +433,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
int ath11k_dp_rx_ampdu_stop(struct ath11k *ar,
--- a/drivers/net/wireless/ath/ath11k/hal_rx.c
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.c
@@ -975,44 +975,78 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -976,44 +976,78 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
ppdu_info->is_stbc = FIELD_GET(HAL_RX_HT_SIG_INFO_INFO1_STBC,
info1);
ppdu_info->ldpc = FIELD_GET(HAL_RX_HT_SIG_INFO_INFO1_FEC_CODING, info1);
@ -536,7 +536,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
ppdu_info->reception_type = HAL_RX_RECEPTION_TYPE_SU;
break;
}
@@ -1470,6 +1504,9 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -1471,6 +1505,9 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
peer_id = ath11k_hal_rx_mpduinfo_get_peerid(ab, mpdu_info);
if (peer_id)
ppdu_info->peer_id = peer_id;
@ -548,7 +548,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
case HAL_RXPCU_PPDU_END_INFO: {
--- a/drivers/net/wireless/ath/ath11k/hal_rx.h
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.h
@@ -19,7 +19,11 @@ struct hal_rx_wbm_rel_info {
@@ -20,7 +20,11 @@ struct hal_rx_wbm_rel_info {
#define VHT_SIG_SU_NSS_MASK 0x7
#define HAL_RX_MAX_MCS 12
@ -560,7 +560,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
struct hal_rx_mon_status_tlv_hdr {
u32 hdr;
@@ -103,6 +107,22 @@ struct hal_rx_user_status {
@@ -104,6 +108,22 @@ struct hal_rx_user_status {
u32 mpdu_err_byte_count;
};
@ -583,7 +583,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
#define HAL_TLV_STATUS_PPDU_NOT_DONE HAL_RX_MON_STATUS_PPDU_NOT_DONE
#define HAL_TLV_STATUS_PPDU_DONE HAL_RX_MON_STATUS_PPDU_DONE
#define HAL_TLV_STATUS_BUF_DONE HAL_RX_MON_STATUS_BUF_DONE
@@ -127,6 +147,7 @@ struct hal_rx_mon_ppdu_info {
@@ -128,6 +148,7 @@ struct hal_rx_mon_ppdu_info {
u32 num_mpdu_fcs_ok;
u32 num_mpdu_fcs_err;
u32 preamble_type;
@ -661,7 +661,7 @@ Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
#define ATH11K_TX_RING_MASK_0 BIT(0)
--- a/drivers/net/wireless/ath/ath11k/hw.h
+++ b/drivers/net/wireless/ath/ath11k/hw.h
@@ -269,6 +269,7 @@ struct ath11k_hw_ops {
@@ -270,6 +270,7 @@ struct ath11k_hw_ops {
bool (*rx_desc_mac_addr2_valid)(struct hal_rx_desc *desc);
u8* (*rx_desc_mpdu_start_addr2)(struct hal_rx_desc *desc);
u32 (*get_ring_selector)(struct sk_buff *skb);

View File

@ -15,15 +15,15 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -29,6 +29,7 @@
@@ -31,6 +31,7 @@
#include "dbring.h"
#include "spectral.h"
#include "wow.h"
+#include "rx_desc.h"
#include "fw.h"
#define SM(_v, _f) (((_v) << _f##_LSB) & _f##_MASK)
@@ -469,6 +470,8 @@ struct ath11k_htt_data_stats {
@@ -508,6 +509,8 @@ struct ath11k_htt_data_stats {
u64 bw[ATH11K_COUNTER_TYPE_MAX][ATH11K_BW_NUM];
u64 nss[ATH11K_COUNTER_TYPE_MAX][ATH11K_NSS_NUM];
u64 gi[ATH11K_COUNTER_TYPE_MAX][ATH11K_GI_NUM];
@ -32,7 +32,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
};
struct ath11k_htt_tx_stats {
@@ -476,6 +479,9 @@ struct ath11k_htt_tx_stats {
@@ -515,6 +518,9 @@ struct ath11k_htt_tx_stats {
u64 tx_duration;
u64 ba_fails;
u64 ack_fails;
@ -42,7 +42,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
};
struct ath11k_per_ppdu_tx_stats {
@@ -592,11 +598,16 @@ struct ath11k_per_peer_tx_stats {
@@ -631,11 +637,16 @@ struct ath11k_per_peer_tx_stats {
u32 succ_bytes;
u32 retry_bytes;
u32 failed_bytes;
@ -62,7 +62,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/debugfs_sta.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs_sta.c
@@ -13,13 +13,39 @@
@@ -14,13 +14,39 @@
#include "dp_rx.h"
#include "debugfs_htt_stats.h"
@ -103,7 +103,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
if (!arsta->tx_stats)
return;
@@ -64,6 +90,43 @@ void ath11k_debugfs_sta_add_tx_stats(str
@@ -65,6 +91,43 @@ void ath11k_debugfs_sta_add_tx_stats(str
STATS_OP_FMT(RETRY).legacy[1][mcs] += peer_stats->retry_pkts;
}
@ -147,7 +147,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
if (peer_stats->is_ampdu) {
tx_stats->ba_fails += peer_stats->ba_fails;
@@ -124,6 +187,17 @@ void ath11k_debugfs_sta_add_tx_stats(str
@@ -125,6 +188,17 @@ void ath11k_debugfs_sta_add_tx_stats(str
STATS_OP_FMT(RETRY).gi[1][gi] += peer_stats->retry_pkts;
tx_stats->tx_duration += peer_stats->duration;
@ -165,7 +165,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
}
void ath11k_debugfs_sta_update_txcompl(struct ath11k *ar,
@@ -140,12 +214,13 @@ static ssize_t ath11k_dbg_sta_dump_tx_st
@@ -141,12 +215,13 @@ static ssize_t ath11k_dbg_sta_dump_tx_st
struct ath11k_sta *arsta = ath11k_sta_to_arsta(sta);
struct ath11k *ar = arsta->arvif->ar;
struct ath11k_htt_data_stats *stats;
@ -181,7 +181,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
if (!arsta->tx_stats)
return -ENOENT;
@@ -163,45 +238,46 @@ static ssize_t ath11k_dbg_sta_dump_tx_st
@@ -164,45 +239,46 @@ static ssize_t ath11k_dbg_sta_dump_tx_st
len += scnprintf(buf + len, size - len, "%s_%s\n",
str_name[k],
str[j]);
@ -237,7 +237,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
stats->gi[j][0], stats->gi[j][1],
stats->gi[j][2], stats->gi[j][3]);
len += scnprintf(buf + len, size - len,
@@ -210,10 +286,68 @@ static ssize_t ath11k_dbg_sta_dump_tx_st
@@ -211,10 +287,68 @@ static ssize_t ath11k_dbg_sta_dump_tx_st
for (i = 0; i < ATH11K_LEGACY_NUM; i++)
len += scnprintf(buf + len, size - len, "%llu ",
stats->legacy[j][i]);
@ -307,7 +307,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
len += scnprintf(buf + len, size - len,
"\nTX duration\n %llu usecs\n",
arsta->tx_stats->tx_duration);
@@ -221,6 +355,7 @@ static ssize_t ath11k_dbg_sta_dump_tx_st
@@ -222,6 +356,7 @@ static ssize_t ath11k_dbg_sta_dump_tx_st
"BA fails\n %llu\n", arsta->tx_stats->ba_fails);
len += scnprintf(buf + len, size - len,
"ack fails\n %llu\n", arsta->tx_stats->ack_fails);
@ -447,7 +447,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
};
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -1252,9 +1252,10 @@ static int ath11k_htt_tlv_ppdu_stats_par
@@ -1253,9 +1253,10 @@ static int ath11k_htt_tlv_ppdu_stats_par
void *data)
{
struct htt_ppdu_stats_info *ppdu_info;
@ -459,7 +459,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
ppdu_info = data;
@@ -1267,6 +1268,26 @@ static int ath11k_htt_tlv_ppdu_stats_par
@@ -1268,6 +1269,26 @@ static int ath11k_htt_tlv_ppdu_stats_par
}
memcpy((void *)&ppdu_info->ppdu_stats.common, ptr,
sizeof(struct htt_ppdu_stats_common));
@ -486,7 +486,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
break;
case HTT_PPDU_STATS_TAG_USR_RATE:
if (len < sizeof(struct htt_ppdu_stats_user_rate)) {
@@ -1299,6 +1320,7 @@ static int ath11k_htt_tlv_ppdu_stats_par
@@ -1300,6 +1321,7 @@ static int ath11k_htt_tlv_ppdu_stats_par
peer_id);
if (cur_user < 0)
return -EINVAL;
@ -494,7 +494,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
user_stats = &ppdu_info->ppdu_stats.user_stats[cur_user];
user_stats->peer_id = peer_id;
user_stats->is_valid_peer_id = true;
@@ -1327,44 +1349,30 @@ static int ath11k_htt_tlv_ppdu_stats_par
@@ -1328,44 +1350,30 @@ static int ath11k_htt_tlv_ppdu_stats_par
sizeof(struct htt_ppdu_stats_usr_cmpltn_ack_ba_status));
user_stats->tlv_flags |= BIT(tag);
break;
@ -559,7 +559,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
return 0;
}
@@ -1382,8 +1390,8 @@ ath11k_update_per_peer_tx_stats(struct a
@@ -1383,8 +1391,8 @@ ath11k_update_per_peer_tx_stats(struct a
struct htt_ppdu_stats_common *common = &ppdu_stats->common;
int ret;
u8 flags, mcs, nss, bw, sgi, dcm, rate_idx = 0;
@ -570,7 +570,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
u32 tx_duration = 0;
u8 tid = HTT_PPDU_STATS_NON_QOS_TID;
bool is_ampdu = false;
@@ -1414,6 +1422,11 @@ ath11k_update_per_peer_tx_stats(struct a
@@ -1415,6 +1423,11 @@ ath11k_update_per_peer_tx_stats(struct a
mcs = HTT_USR_RATE_MCS(user_rate->rate_flags);
sgi = HTT_USR_RATE_GI(user_rate->rate_flags);
dcm = HTT_USR_RATE_DCM(user_rate->rate_flags);
@ -582,7 +582,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
/* Note: If host configured fixed rates and in some other special
* cases, the broadcast/management frames are sent in different rates.
@@ -1508,6 +1521,12 @@ ath11k_update_per_peer_tx_stats(struct a
@@ -1509,6 +1522,12 @@ ath11k_update_per_peer_tx_stats(struct a
peer_stats->ba_fails =
HTT_USR_CMPLTN_LONG_RETRY(usr_stats->cmpltn_cmn.flags) +
HTT_USR_CMPLTN_SHORT_RETRY(usr_stats->cmpltn_cmn.flags);
@ -595,7 +595,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
if (ath11k_debugfs_is_extd_tx_stats_enabled(ar))
ath11k_debugfs_sta_add_tx_stats(arsta, peer_stats, rate_idx);
@@ -1560,13 +1579,89 @@ struct htt_ppdu_stats_info *ath11k_dp_ht
@@ -1561,13 +1580,89 @@ struct htt_ppdu_stats_info *ath11k_dp_ht
return ppdu_info;
}
@ -686,7 +686,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
u8 pdev_id;
u32 ppdu_id, len;
@@ -1601,6 +1696,47 @@ static int ath11k_htt_pull_ppdu_stats(st
@@ -1602,6 +1697,47 @@ static int ath11k_htt_pull_ppdu_stats(st
goto out_unlock_data;
}
@ -736,7 +736,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/rx_desc.h
+++ b/drivers/net/wireless/ath/ath11k/rx_desc.h
@@ -1494,6 +1494,11 @@ struct hal_rx_desc {
@@ -1495,6 +1495,11 @@ struct hal_rx_desc {
} u;
} __packed;

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -27,10 +27,10 @@ module_param_named(crypto_mode, ath11k_c
@@ -28,10 +28,10 @@ module_param_named(crypto_mode, ath11k_c
MODULE_PARM_DESC(crypto_mode, "crypto mode: 0-hardware, 1-software");
/* frame mode values are mapped as per enum ath11k_hw_txrx_mode */

View File

@ -15,7 +15,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/debugfs_sta.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs_sta.c
@@ -525,13 +525,6 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
@@ -526,13 +526,6 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
rx_stats->byte_stats.rx_rate[i],
(i + 1) % (he_rates_avail ? 12 : 8) ? "\t" : "\n");
@ -31,7 +31,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
spin_unlock_bh(&ar->ab->base_lock);
--- a/drivers/net/wireless/ath/ath11k/hal_rx.c
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.c
@@ -1478,6 +1478,7 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -1479,6 +1479,7 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
ab->wmi_ab.svc_map);
struct hal_rx_phyrx_rssi_legacy_info *rssi =
(struct hal_rx_phyrx_rssi_legacy_info *)tlv_data;
@ -39,7 +39,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
/* TODO: Please note that the combined rssi will not be accurate
* in MU case. Rssi in MU needs to be retrieved from
@@ -1487,6 +1488,22 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -1488,6 +1489,22 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
FIELD_GET(HAL_RX_PHYRX_RSSI_LEGACY_INFO_INFO0_RSSI_COMB,
__le32_to_cpu(rssi->info0));
@ -64,7 +64,7 @@ Signed-off-by: Miles Hu <milehu@codeaurora.org>
ppdu_info->rssi_chain_pri20[i] =
--- a/drivers/net/wireless/ath/ath11k/hal_rx.h
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.h
@@ -414,6 +414,15 @@ struct hal_rx_he_sig_b2_ofdma_info {
@@ -415,6 +415,15 @@ struct hal_rx_he_sig_b2_ofdma_info {
#define HAL_RX_PHYRX_RSSI_LEGACY_INFO_INFO0_RSSI_COMB GENMASK(15, 8)

View File

@ -5,7 +5,7 @@
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -5451,8 +5451,11 @@ int ath11k_dp_rx_process_mon_status(stru
@@ -5452,8 +5452,11 @@ int ath11k_dp_rx_process_mon_status(stru
goto next_skb;
}
@ -21,7 +21,7 @@
trace_ath11k_htt_rxdesc(ar, skb->data, log_type, rx_buf_sz);
--- a/drivers/net/wireless/ath/ath11k/hal_rx.c
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.c
@@ -900,6 +900,9 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -901,6 +901,9 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
ppdu_info->ast_index =
FIELD_GET(HAL_RX_PPDU_END_USER_STATS_INFO2_AST_INDEX,
__le32_to_cpu(eu_stats->info2));
@ -33,7 +33,7 @@
__le32_to_cpu(eu_stats->info7))) - 1;
--- a/drivers/net/wireless/ath/ath11k/hal_rx.h
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.h
@@ -70,6 +70,7 @@ enum hal_rx_reception_type {
@@ -71,6 +71,7 @@ enum hal_rx_reception_type {
};
#define HAL_RX_FCS_LEN 4
@ -41,7 +41,7 @@
enum hal_rx_mon_status {
HAL_RX_MON_STATUS_PPDU_NOT_DONE,
@@ -171,6 +172,7 @@ struct hal_rx_mon_ppdu_info {
@@ -172,6 +173,7 @@ struct hal_rx_mon_ppdu_info {
u8 rssi_comb;
u8 rssi_chain_pri20[HAL_RX_MAX_NSS];
u16 tid;

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath11k/debugfs_sta.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs_sta.c
@@ -524,6 +524,12 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
@@ -525,6 +525,12 @@ static ssize_t ath11k_dbg_sta_dump_rx_st
len += scnprintf(buf + len, size - len, "%10llu%s",
rx_stats->byte_stats.rx_rate[i],
(i + 1) % (he_rates_avail ? 12 : 8) ? "\t" : "\n");
@ -15,7 +15,7 @@
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -2901,11 +2901,12 @@ exit:
@@ -2902,11 +2902,12 @@ exit:
static void
ath11k_dp_rx_update_peer_rate_table_stats(struct ath11k_rx_peer_stats *rx_stats,
struct hal_rx_mon_ppdu_info *ppdu_info,
@ -30,7 +30,7 @@
u32 bw_idx = ppdu_info->bw;
u32 gi_idx = ppdu_info->gi;
@@ -2927,10 +2928,13 @@ ath11k_dp_rx_update_peer_rate_table_stat
@@ -2928,10 +2929,13 @@ ath11k_dp_rx_update_peer_rate_table_stat
}
rx_stats->pkt_stats.rx_rate[rate_idx] += num_msdu;
@ -46,7 +46,7 @@
struct hal_rx_mon_ppdu_info *ppdu_info)
{
struct ath11k_rx_peer_stats *rx_stats = arsta->rx_stats;
@@ -2988,7 +2992,6 @@ static void ath11k_dp_rx_update_peer_sta
@@ -2989,7 +2993,6 @@ static void ath11k_dp_rx_update_peer_sta
rx_stats->num_mpdu_fcs_ok += ppdu_info->num_mpdu_fcs_ok;
rx_stats->num_mpdu_fcs_err += ppdu_info->num_mpdu_fcs_err;
rx_stats->dcm_count += ppdu_info->dcm;
@ -54,7 +54,7 @@
BUILD_BUG_ON(ARRAY_SIZE(arsta->chain_signal) >
ARRAY_SIZE(ppdu_info->rssi_chain_pri20));
@@ -3006,10 +3009,10 @@ static void ath11k_dp_rx_update_peer_sta
@@ -3007,10 +3010,10 @@ static void ath11k_dp_rx_update_peer_sta
if (ppdu_info->preamble_type == HAL_RX_PREAMBLE_11N &&
ppdu_info->mcs <= HAL_RX_MAX_MCS_HT) {
@ -69,7 +69,7 @@
}
if (ppdu_info->preamble_type == HAL_RX_PREAMBLE_11AC &&
@@ -3042,7 +3045,120 @@ static void ath11k_dp_rx_update_peer_sta
@@ -3043,7 +3046,120 @@ static void ath11k_dp_rx_update_peer_sta
rx_stats->byte_stats.bw_count[ppdu_info->bw] += ppdu_info->mpdu_len;
}
@ -191,7 +191,7 @@
}
@@ -5380,6 +5496,55 @@ static void ath11k_dp_rx_mon_dest_proces
@@ -5381,6 +5497,55 @@ static void ath11k_dp_rx_mon_dest_proces
}
}
@ -247,7 +247,7 @@
int ath11k_dp_rx_process_mon_status(struct ath11k_base *ab, int mac_id,
struct napi_struct *napi, int budget)
{
@@ -5453,8 +5618,13 @@ int ath11k_dp_rx_process_mon_status(stru
@@ -5454,8 +5619,13 @@ int ath11k_dp_rx_process_mon_status(stru
if ((ppdu_info->fc_valid) &&
(ppdu_info->ast_index != HAL_AST_IDX_INVALID)) {
@ -265,7 +265,7 @@
if (ath11k_debugfs_is_pktlog_peer_valid(ar, peer->addr))
--- a/drivers/net/wireless/ath/ath11k/hal_rx.c
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.c
@@ -804,7 +804,6 @@ void ath11k_hal_reo_init_cmd_ring(struct
@@ -805,7 +805,6 @@ void ath11k_hal_reo_init_cmd_ring(struct
}
}
@ -273,7 +273,7 @@
static inline void
ath11k_hal_rx_handle_ofdma_info(void *rx_tlv,
struct hal_rx_user_status *rx_user_status)
@@ -836,6 +835,8 @@ ath11k_hal_rx_populate_mu_user_info(void
@@ -837,6 +836,8 @@ ath11k_hal_rx_populate_mu_user_info(void
{
rx_user_status->ast_index = ppdu_info->ast_index;
rx_user_status->tid = ppdu_info->tid;
@ -282,7 +282,7 @@
rx_user_status->tcp_msdu_count =
ppdu_info->tcp_msdu_count;
rx_user_status->udp_msdu_count =
@@ -859,6 +860,9 @@ ath11k_hal_rx_populate_mu_user_info(void
@@ -860,6 +861,9 @@ ath11k_hal_rx_populate_mu_user_info(void
ppdu_info->num_mpdu_fcs_ok;
rx_user_status->mpdu_cnt_fcs_err =
ppdu_info->num_mpdu_fcs_err;
@ -292,7 +292,7 @@
ath11k_hal_rx_populate_byte_count(rx_tlv, ppdu_info, rx_user_status);
}
@@ -888,6 +892,14 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -889,6 +893,14 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
__le32_to_cpu(ppdu_start->info0));
ppdu_info->chan_num = __le32_to_cpu(ppdu_start->chan_num);
ppdu_info->ppdu_ts = __le32_to_cpu(ppdu_start->ppdu_start_ts);
@ -307,7 +307,7 @@
break;
}
case HAL_RX_PPDU_END_USER_STATS: {
@@ -942,15 +954,16 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -943,15 +955,16 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
if (userid < HAL_MAX_UL_MU_USERS) {
struct hal_rx_user_status *rxuser_stats =
@ -327,7 +327,7 @@
__le32_to_cpu(eu_stats->rsvd1[1]);
break;
@@ -958,12 +971,12 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -959,12 +972,12 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
case HAL_RX_PPDU_END_USER_STATS_EXT: {
struct hal_rx_ppdu_end_user_stats_ext *eu_stats =
(struct hal_rx_ppdu_end_user_stats_ext *)tlv_data;
@ -348,7 +348,7 @@
case HAL_PHYRX_HT_SIG: {
--- a/drivers/net/wireless/ath/ath11k/hal_rx.h
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.h
@@ -72,6 +72,10 @@ enum hal_rx_reception_type {
@@ -73,6 +73,10 @@ enum hal_rx_reception_type {
#define HAL_RX_FCS_LEN 4
#define HAL_AST_IDX_INVALID 0xFFFF
@ -359,7 +359,7 @@
enum hal_rx_mon_status {
HAL_RX_MON_STATUS_PPDU_NOT_DONE,
HAL_RX_MON_STATUS_PPDU_DONE,
@@ -82,14 +86,15 @@ struct hal_rx_user_status {
@@ -83,14 +87,15 @@ struct hal_rx_user_status {
u32 mcs:4,
nss:3,
ofdma_info_valid:1,
@ -378,7 +378,7 @@
u16 udp_msdu_count;
u16 other_msdu_count;
u16 frame_control;
@@ -103,7 +108,7 @@ struct hal_rx_user_status {
@@ -104,7 +109,7 @@ struct hal_rx_user_status {
u8 rs_flags;
u32 mpdu_cnt_fcs_ok;
u32 mpdu_cnt_fcs_err;
@ -387,7 +387,7 @@
u32 mpdu_ok_byte_count;
u32 mpdu_err_byte_count;
};
@@ -144,6 +149,7 @@ struct hal_sw_mon_ring_entries {
@@ -145,6 +150,7 @@ struct hal_sw_mon_ring_entries {
struct hal_rx_mon_ppdu_info {
u32 ppdu_id;
@ -395,7 +395,7 @@
u32 ppdu_ts;
u32 num_mpdu_fcs_ok;
u32 num_mpdu_fcs_err;
@@ -212,9 +218,20 @@ struct hal_rx_mon_ppdu_info {
@@ -213,9 +219,20 @@ struct hal_rx_mon_ppdu_info {
u8 ltf_size;
u8 rxpcu_filter_pass;
char rssi_chain[8][8];

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -2305,6 +2305,42 @@ static void ath11k_dp_rx_h_undecap_eth(s
@@ -2306,6 +2306,42 @@ static void ath11k_dp_rx_h_undecap_eth(s
ether_addr_copy(ieee80211_get_SA(hdr), sa);
}
@ -43,7 +43,7 @@
static void ath11k_dp_rx_h_undecap(struct ath11k *ar, struct sk_buff *msdu,
struct hal_rx_desc *rx_desc,
enum hal_encrypt_type enctype,
@@ -2346,7 +2382,8 @@ static void ath11k_dp_rx_h_undecap(struc
@@ -2347,7 +2383,8 @@ static void ath11k_dp_rx_h_undecap(struc
enctype, status);
break;
case DP_RX_DECAP_TYPE_8023:

View File

@ -1,7 +1,23 @@
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -314,6 +314,16 @@ struct ath11k_rekey_data {
bool enable_offload;
@@ -17,6 +17,7 @@
#include <linux/average.h>
#include <linux/firmware.h>
+#include "fw.h"
#include "qmi.h"
#include "htc.h"
#include "wmi.h"
@@ -32,7 +33,6 @@
#include "spectral.h"
#include "wow.h"
#include "rx_desc.h"
-#include "fw.h"
#define SM(_v, _f) (((_v) << _f##_LSB) & _f##_MASK)
@@ -355,6 +355,16 @@ struct ath11k_reg_tpc_power_info {
struct ath11k_chan_power_info chan_power_info[IEEE80211_MAX_NUM_PWR_LEVEL];
};
+#define ATH11K_STATS_MGMT_FRM_TYPE_MAX 16
@ -17,18 +33,17 @@
struct ath11k_vif {
u32 vdev_id;
enum wmi_vdev_type vdev_type;
@@ -372,6 +382,8 @@ struct ath11k_vif {
#ifdef CPTCFG_ATH11K_DEBUGFS
struct dentry *debugfs_twt;
#endif /* CPTCFG_ATH11K_DEBUGFS */
+
@@ -411,6 +421,7 @@ struct ath11k_vif {
struct ath11k_rekey_data rekey_data;
struct ath11k_reg_tpc_power_info reg_tpc_info;
+ struct ath11k_mgmt_frame_stats mgmt_stats;
};
struct ath11k_vif_iter {
--- a/drivers/net/wireless/ath/ath11k/debugfs.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs.c
@@ -1588,6 +1588,87 @@ static const struct file_operations fops
@@ -1589,6 +1589,87 @@ static const struct file_operations fops
.llseek = default_llseek,
};
@ -116,7 +131,7 @@
int ath11k_debugfs_register(struct ath11k *ar)
{
struct ath11k_base *ab = ar->ab;
@@ -1620,6 +1701,9 @@ int ath11k_debugfs_register(struct ath11
@@ -1621,6 +1702,9 @@ int ath11k_debugfs_register(struct ath11
debugfs_create_file("fw_dbglog_config", 0600,
ar->debug.debugfs_pdev, ar,
&fops_fw_dbglog);
@ -128,7 +143,7 @@
debugfs_create_file("dfs_simulate_radar", 0200,
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -6148,9 +6148,9 @@ static int ath11k_mac_mgmt_tx(struct ath
@@ -5934,9 +5934,9 @@ static int ath11k_mac_mgmt_tx(struct ath
*/
if (is_prb_rsp &&
atomic_read(&ar->num_pending_mgmt_tx) > ATH11K_PRB_RSP_DROP_THRESHOLD) {
@ -140,7 +155,7 @@
}
if (skb_queue_len_lockless(q) >= ATH11K_TX_MGMT_NUM_PENDING_MAX) {
@@ -6176,9 +6176,11 @@ static void ath11k_mac_op_tx(struct ieee
@@ -5962,9 +5962,11 @@ static void ath11k_mac_op_tx(struct ieee
struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data;
struct ieee80211_key_conf *key = info->control.hw_key;
@ -152,7 +167,7 @@
int ret;
memset(skb_cb, 0, sizeof(*skb_cb));
@@ -6192,12 +6194,21 @@ static void ath11k_mac_op_tx(struct ieee
@@ -5978,12 +5980,21 @@ static void ath11k_mac_op_tx(struct ieee
if (info_flags & IEEE80211_TX_CTL_HW_80211_ENCAP) {
skb_cb->flags |= ATH11K_SKB_HW_80211_ENCAP;
} else if (ieee80211_is_mgmt(hdr->frame_control)) {
@ -198,7 +213,7 @@
int peer_id;
--- a/drivers/net/wireless/ath/ath11k/wmi.c
+++ b/drivers/net/wireless/ath/ath11k/wmi.c
@@ -5823,6 +5823,12 @@ static int wmi_process_mgmt_tx_comp(stru
@@ -5896,6 +5896,12 @@ static int wmi_process_mgmt_tx_comp(stru
struct sk_buff *msdu;
struct ieee80211_tx_info *info;
struct ath11k_skb_cb *skb_cb;
@ -211,7 +226,7 @@
int num_mgmt;
spin_lock_bh(&ar->txmgmt_idr_lock);
@@ -5850,6 +5856,31 @@ static int wmi_process_mgmt_tx_comp(stru
@@ -5923,6 +5929,31 @@ static int wmi_process_mgmt_tx_comp(stru
info->status.ack_signal = tx_compl_param->ack_rssi;
}
@ -243,7 +258,7 @@
ieee80211_tx_status_irqsafe(ar->hw, msdu);
num_mgmt = atomic_dec_if_positive(&ar->num_pending_mgmt_tx);
@@ -7519,6 +7550,11 @@ static void ath11k_mgmt_rx_event(struct
@@ -7500,6 +7531,11 @@ static void ath11k_mgmt_rx_event(struct
struct ieee80211_hdr *hdr;
u16 fc;
struct ieee80211_supported_band *sband;
@ -255,7 +270,7 @@
if (ath11k_pull_mgmt_rx_params_tlv(ab, skb, &rx_ev) != 0) {
ath11k_warn(ab, "failed to extract mgmt rx event");
@@ -7584,7 +7620,34 @@ static void ath11k_mgmt_rx_event(struct
@@ -7565,7 +7601,34 @@ static void ath11k_mgmt_rx_event(struct
hdr = (struct ieee80211_hdr *)skb->data;
fc = le16_to_cpu(hdr->frame_control);

View File

@ -34,7 +34,7 @@ Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -2189,5 +2189,17 @@ err_sc_free:
@@ -2294,5 +2294,17 @@ err_sc_free:
}
EXPORT_SYMBOL(ath11k_core_alloc);
@ -54,7 +54,7 @@ Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
MODULE_LICENSE("Dual BSD/GPL");
--- a/drivers/net/wireless/ath/ath11k/debugfs.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs.c
@@ -16,6 +16,8 @@
@@ -17,6 +17,8 @@
#include "peer.h"
#include "hif.h"
@ -63,7 +63,7 @@ Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
static const char *htt_bp_umac_ring[HTT_SW_UMAC_RING_IDX_MAX] = {
"REO2SW1_RING",
"REO2SW2_RING",
@@ -991,8 +993,6 @@ int ath11k_debugfs_pdev_create(struct at
@@ -992,8 +994,6 @@ int ath11k_debugfs_pdev_create(struct at
void ath11k_debugfs_pdev_destroy(struct ath11k_base *ab)
{
@ -72,7 +72,7 @@ Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
}
int ath11k_debugfs_soc_create(struct ath11k_base *ab)
@@ -1045,6 +1045,24 @@ void ath11k_debugfs_soc_destroy(struct a
@@ -1046,6 +1046,24 @@ void ath11k_debugfs_soc_destroy(struct a
}
EXPORT_SYMBOL(ath11k_debugfs_soc_destroy);
@ -97,7 +97,7 @@ Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
void ath11k_debugfs_fw_stats_init(struct ath11k *ar)
{
struct dentry *fwstats_dir = debugfs_create_dir("fw_stats",
@@ -1675,6 +1693,9 @@ int ath11k_debugfs_register(struct ath11
@@ -1676,6 +1694,9 @@ int ath11k_debugfs_register(struct ath11
char pdev_name[10];
char buf[100] = {0};
@ -107,7 +107,7 @@ Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
snprintf(pdev_name, sizeof(pdev_name), "%s%u", "mac", ar->pdev_idx);
ar->debug.debugfs_pdev = debugfs_create_dir(pdev_name, ab->debugfs_soc);
@@ -1752,6 +1773,9 @@ void ath11k_debugfs_unregister(struct at
@@ -1753,6 +1774,9 @@ void ath11k_debugfs_unregister(struct at
kfree(dbr_debug);
ar->debug.dbr_debug[i] = NULL;
}
@ -119,7 +119,7 @@ Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
static ssize_t ath11k_write_twt_add_dialog(struct file *file,
--- a/drivers/net/wireless/ath/ath11k/debugfs.h
+++ b/drivers/net/wireless/ath/ath11k/debugfs.h
@@ -263,6 +263,8 @@ struct ath11k_fw_dbglog {
@@ -264,6 +264,8 @@ struct ath11k_fw_dbglog {
};
#ifdef CPTCFG_ATH11K_DEBUGFS
@ -128,7 +128,7 @@ Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
int ath11k_debugfs_soc_create(struct ath11k_base *ab);
void ath11k_debugfs_soc_destroy(struct ath11k_base *ab);
int ath11k_debugfs_pdev_create(struct ath11k_base *ab);
@@ -314,6 +316,15 @@ void ath11k_debugfs_add_dbring_entry(str
@@ -315,6 +317,15 @@ void ath11k_debugfs_add_dbring_entry(str
struct hal_srng *srng);
#else

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -9580,6 +9580,8 @@ static int __ath11k_mac_register(struct
@@ -10159,6 +10159,8 @@ static int __ath11k_mac_register(struct
wiphy_ext_feature_set(ar->hw->wiphy,
NL80211_EXT_FEATURE_ACK_SIGNAL_SUPPORT);
@ -11,7 +11,7 @@
ar->hw->offchannel_tx_hw_queue = ATH11K_HW_MAX_QUEUES - 1;
--- a/drivers/net/wireless/ath/ath11k/wmi.c
+++ b/drivers/net/wireless/ath/ath11k/wmi.c
@@ -4065,6 +4065,7 @@ ath11k_wmi_copy_resource_config(struct w
@@ -4128,6 +4128,7 @@ ath11k_wmi_copy_resource_config(struct w
wmi_cfg->max_bssid_rx_filters = tg_cfg->max_bssid_rx_filters;
wmi_cfg->use_pdev_id = tg_cfg->use_pdev_id;
wmi_cfg->flag1 = tg_cfg->flag1;

View File

@ -38,7 +38,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
depends on m
--- a/drivers/net/wireless/ath/ath11k/Makefile
+++ b/drivers/net/wireless/ath/ath11k/Makefile
@@ -25,6 +25,7 @@ ath11k-$(CPTCFG_ATH11K_TRACING) += trace
@@ -26,6 +26,7 @@ ath11k-$(CPTCFG_ATH11K_TRACING) += trace
ath11k-$(CPTCFG_ATH11K_THERMAL) += thermal.o
ath11k-$(CPTCFG_ATH11K_SPECTRAL) += spectral.o
ath11k-$(CONFIG_PM) += wow.o
@ -2760,7 +2760,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
+#endif
--- a/drivers/net/wireless/ath/ath11k/hif.h
+++ b/drivers/net/wireless/ath/ath11k/hif.h
@@ -30,6 +30,7 @@ struct ath11k_hif_ops {
@@ -31,6 +31,7 @@ struct ath11k_hif_ops {
void (*ce_irq_enable)(struct ath11k_base *ab);
void (*ce_irq_disable)(struct ath11k_base *ab);
void (*get_ce_msi_idx)(struct ath11k_base *ab, u32 ce_id, u32 *msi_idx);
@ -2768,7 +2768,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
};
static inline void ath11k_hif_ce_irq_enable(struct ath11k_base *ab)
@@ -136,6 +137,14 @@ static inline void ath11k_get_msi_addres
@@ -137,6 +138,14 @@ static inline void ath11k_get_msi_addres
ab->hif.ops->get_msi_address(ab, msi_addr_lo, msi_addr_hi);
}
@ -2785,7 +2785,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
{
--- a/drivers/net/wireless/ath/ath11k/pci.c
+++ b/drivers/net/wireless/ath/ath11k/pci.c
@@ -67,6 +67,20 @@ static u32 ath11k_pci_get_window_start(s
@@ -70,6 +70,20 @@ static u32 ath11k_pci_get_window_start(s
return ATH11K_PCI_WINDOW_START;
}
@ -2806,7 +2806,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
static inline void ath11k_pci_select_window(struct ath11k_pci *ab_pci, u32 offset)
{
struct ath11k_base *ab = ab_pci->ab;
@@ -710,6 +724,7 @@ static const struct ath11k_hif_ops ath11
@@ -723,6 +737,7 @@ static const struct ath11k_hif_ops ath11
.map_service_to_pipe = ath11k_pcic_map_service_to_pipe,
.ce_irq_enable = ath11k_pci_hif_ce_irq_enable,
.ce_irq_disable = ath11k_pci_hif_ce_irq_disable,
@ -2816,7 +2816,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -992,6 +992,29 @@ unlock_exit:
@@ -993,6 +993,29 @@ unlock_exit:
spin_unlock_bh(&ab->base_lock);
}
@ -2895,7 +2895,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
{
--- a/drivers/net/wireless/ath/ath11k/wmi.h
+++ b/drivers/net/wireless/ath/ath11k/wmi.h
@@ -2873,6 +2873,27 @@ struct pdev_set_regdomain_params {
@@ -2894,6 +2894,27 @@ struct pdev_set_regdomain_params {
u32 pdev_id;
};
@ -2923,7 +2923,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct rx_reorder_queue_remove_params {
u8 *peer_macaddr;
u16 vdev_id;
@@ -3121,6 +3142,16 @@ struct wmi_pdev_set_regdomain_cmd {
@@ -3142,6 +3163,16 @@ struct wmi_pdev_set_regdomain_cmd {
u32 dfs_domain;
} __packed;
@ -2940,7 +2940,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct wmi_peer_set_param_cmd {
u32 tlv_header;
u32 vdev_id;
@@ -6362,6 +6393,8 @@ int ath11k_wmi_send_peer_create_cmd(stru
@@ -6384,6 +6415,8 @@ int ath11k_wmi_send_peer_create_cmd(stru
int ath11k_wmi_vdev_set_param_cmd(struct ath11k *ar, u32 vdev_id,
u32 param_id, u32 param_value);
@ -2998,7 +2998,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
int ath11k_dp_pdev_reo_setup(struct ath11k_base *ab);
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -6367,6 +6367,16 @@ static int ath11k_mac_op_start(struct ie
@@ -6153,6 +6153,16 @@ static int ath11k_mac_op_start(struct ie
goto err;
}
@ -3017,7 +3017,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
/* TODO: Do we need to enable ANI? */
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -849,6 +849,8 @@ struct ath11k_soc_dp_tx_err_stats {
@@ -887,6 +887,8 @@ struct ath11k_soc_dp_tx_err_stats {
* idr unavailable etc.
*/
atomic_t misc_fail;
@ -3026,7 +3026,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
};
struct ath11k_soc_dp_stats {
@@ -935,6 +937,7 @@ struct ath11k_base {
@@ -973,6 +975,7 @@ struct ath11k_base {
struct list_head peers;
wait_queue_head_t peer_mapping_wq;
u8 mac_addr[ETH_ALEN];

View File

@ -24,7 +24,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/ahb.c
+++ b/drivers/net/wireless/ath/ath11k/ahb.c
@@ -525,6 +525,12 @@ static int ath11k_ahb_config_ext_irq(str
@@ -526,6 +526,12 @@ static int ath11k_ahb_config_ext_irq(str
int i, j;
int irq;
int ret;
@ -37,7 +37,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
for (i = 0; i < ATH11K_EXT_IRQ_GRP_NUM_MAX; i++) {
struct ath11k_ext_irq_grp *irq_grp = &ab->ext_irq_grp[i];
@@ -537,20 +543,20 @@ static int ath11k_ahb_config_ext_irq(str
@@ -538,20 +544,20 @@ static int ath11k_ahb_config_ext_irq(str
ath11k_ahb_ext_grp_napi_poll);
for (j = 0; j < ATH11K_EXT_IRQ_NUM_MAX; j++) {
@ -62,7 +62,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
irq_grp->irqs[num_irq++] = wbm2host_rx_release;
if (ab->hw_params.ring_mask->reo_status[i] & BIT(j))
@@ -563,7 +569,7 @@ static int ath11k_ahb_config_ext_irq(str
@@ -564,7 +570,7 @@ static int ath11k_ahb_config_ext_irq(str
ath11k_hw_get_mac_from_pdev_id(hw, j);
}
@ -71,7 +71,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
irq_grp->irqs[num_irq++] =
host2rxdma_host_buf_ring_mac1 -
ath11k_hw_get_mac_from_pdev_id(hw, j);
@@ -904,6 +910,7 @@ static int ath11k_ahb_setup_resources(st
@@ -905,6 +911,7 @@ static int ath11k_ahb_setup_resources(st
}
ab->mem = mem;
@ -81,9 +81,9 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
return 0;
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -17,6 +17,12 @@
#include "hif.h"
@@ -18,6 +18,12 @@
#include "wow.h"
#include "fw.h"
+unsigned int nss_offload;
+#ifdef CPTCFG_ATH11K_NSS_SUPPORT
@ -94,7 +94,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
unsigned int ath11k_debug_mask;
EXPORT_SYMBOL(ath11k_debug_mask);
module_param_named(debug_mask, ath11k_debug_mask, uint, 0644);
@@ -1528,10 +1534,16 @@ static int ath11k_core_pdev_create(struc
@@ -1624,10 +1630,16 @@ static int ath11k_core_pdev_create(struc
goto err_pdev_debug;
}
@ -112,7 +112,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
}
ret = ath11k_thermal_register(ab);
@@ -1553,6 +1565,8 @@ err_thermal_unregister:
@@ -1649,6 +1661,8 @@ err_thermal_unregister:
ath11k_thermal_unregister(ab);
err_mac_unregister:
ath11k_mac_unregister(ab);
@ -121,7 +121,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
err_dp_pdev_free:
ath11k_dp_pdev_free(ab);
err_pdev_debug:
@@ -1566,6 +1580,10 @@ static void ath11k_core_pdev_destroy(str
@@ -1662,6 +1676,10 @@ static void ath11k_core_pdev_destroy(str
ath11k_spectral_deinit(ab);
ath11k_thermal_unregister(ab);
ath11k_mac_unregister(ab);
@ -132,7 +132,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ath11k_hif_irq_disable(ab);
ath11k_dp_pdev_free(ab);
ath11k_debugfs_pdev_destroy(ab);
@@ -1772,6 +1790,10 @@ static int ath11k_core_reconfigure_on_cr
@@ -1868,6 +1886,10 @@ static int ath11k_core_reconfigure_on_cr
int ret;
mutex_lock(&ab->core_lock);
@ -141,10 +141,10 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
+ ab->nss.enabled = false;
+
ath11k_thermal_unregister(ab);
ath11k_hif_irq_disable(ab);
ath11k_dp_pdev_free(ab);
@@ -2095,6 +2117,10 @@ int ath11k_core_pre_init(struct ath11k_b
ath11k_err(ab, "failed to get hw params: %d\n", ret);
ath11k_spectral_deinit(ab);
@@ -2199,6 +2221,10 @@ int ath11k_core_pre_init(struct ath11k_b
ath11k_err(ab, "failed to pre init firmware: %d", ret);
return ret;
}
+ ab->nss.enabled = nss_offload;
@ -156,7 +156,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
}
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -30,6 +30,7 @@
@@ -33,6 +33,7 @@
#include "spectral.h"
#include "wow.h"
#include "rx_desc.h"
@ -164,9 +164,9 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
#define SM(_v, _f) (((_v) << _f##_LSB) & _f##_MASK)
@@ -384,6 +385,9 @@ struct ath11k_vif {
#endif /* CPTCFG_ATH11K_DEBUGFS */
@@ -422,6 +423,9 @@ struct ath11k_vif {
struct ath11k_reg_tpc_power_info reg_tpc_info;
struct ath11k_mgmt_frame_stats mgmt_stats;
+#ifdef CPTCFG_ATH11K_NSS_SUPPORT
+ struct arvif_nss nss;
@ -174,7 +174,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
};
struct ath11k_vif_iter {
@@ -537,6 +541,9 @@ struct ath11k_sta {
@@ -575,6 +579,9 @@ struct ath11k_sta {
#endif
bool use_4addr_set;
@ -184,9 +184,9 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
u16 tcl_metadata;
/* Protected with ar->data_lock */
@@ -632,6 +639,9 @@ struct ath11k {
@@ -669,6 +676,9 @@ struct ath11k {
struct ath11k_pdev *pdev;
struct ieee80211_hw *hw;
struct ieee80211_ops *ops;
struct ath11k_pdev_wmi *wmi;
+#ifdef CPTCFG_ATH11K_NSS_SUPPORT
+ struct ath11k_nss nss;
@ -194,7 +194,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct ath11k_pdev_dp dp;
u8 mac_addr[ETH_ALEN];
struct ath11k_he ar_he;
@@ -892,9 +902,11 @@ struct ath11k_base {
@@ -930,9 +940,11 @@ struct ath11k_base {
struct ath11k_htc htc;
struct ath11k_dp dp;
@ -227,7 +227,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
if (ret) {
ath11k_warn(ab, "failed to set default routing %d peer :%pM vdev_id :%d\n",
@@ -132,6 +137,18 @@ static int ath11k_dp_srng_calculate_msi_
@@ -135,6 +140,18 @@ static int ath11k_dp_srng_calculate_msi_
{
const u8 *grp_mask;
@ -246,7 +246,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
switch (type) {
case HAL_WBM2SW_RELEASE:
if (ring_num == DP_RX_RELEASE_RING_NUM) {
@@ -778,14 +795,16 @@ int ath11k_dp_service_srng(struct ath11k
@@ -792,14 +809,16 @@ int ath11k_dp_service_srng(struct ath11k
int work_done = 0;
int i, j;
int tot_work_done = 0;
@ -268,7 +268,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
work_done = ath11k_dp_process_rx_err(ab, napi, budget);
budget -= work_done;
tot_work_done += work_done;
@@ -793,7 +812,7 @@ int ath11k_dp_service_srng(struct ath11k
@@ -807,7 +826,7 @@ int ath11k_dp_service_srng(struct ath11k
goto done;
}
@ -277,7 +277,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
work_done = ath11k_dp_rx_process_wbm_err(ab,
napi,
budget);
@@ -804,7 +823,7 @@ int ath11k_dp_service_srng(struct ath11k
@@ -818,7 +837,7 @@ int ath11k_dp_service_srng(struct ath11k
goto done;
}
@ -286,7 +286,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
i = fls(ab->hw_params.ring_mask->rx[grp_id]) - 1;
work_done = ath11k_dp_process_rx(ab, i, napi,
budget);
@@ -838,7 +857,7 @@ int ath11k_dp_service_srng(struct ath11k
@@ -852,7 +871,7 @@ int ath11k_dp_service_srng(struct ath11k
if (ab->hw_params.ring_mask->reo_status[grp_id])
ath11k_dp_process_reo_status(ab);
@ -307,7 +307,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -17,6 +17,7 @@
@@ -18,6 +18,7 @@
#include "hal_rx.h"
#include "dp_tx.h"
#include "peer.h"
@ -315,7 +315,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
#define ATH11K_DP_RX_FRAGMENT_TIMEOUT_MS (2 * HZ)
@@ -213,8 +214,8 @@ static inline u8 ath11k_dp_rx_h_mpdu_sta
@@ -214,8 +215,8 @@ static inline u8 ath11k_dp_rx_h_mpdu_sta
return ab->hw_params.hw_ops->rx_desc_get_mpdu_tid(desc);
}
@ -326,7 +326,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
{
return ab->hw_params.hw_ops->rx_desc_get_mpdu_peer_id(desc);
}
@@ -225,8 +226,8 @@ static inline u8 ath11k_dp_rx_h_msdu_end
@@ -226,8 +227,8 @@ static inline u8 ath11k_dp_rx_h_msdu_end
return ab->hw_params.hw_ops->rx_desc_get_l3_pad_bytes(desc);
}
@ -337,7 +337,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
{
return ab->hw_params.hw_ops->rx_desc_get_first_msdu(desc);
}
@@ -283,7 +284,7 @@ static inline void ath11k_dp_rxdesc_set_
@@ -284,7 +285,7 @@ static inline void ath11k_dp_rxdesc_set_
ab->hw_params.hw_ops->rx_desc_set_msdu_len(desc, len);
}
@ -346,7 +346,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct hal_rx_desc *desc)
{
struct rx_attention *attn = ath11k_dp_rx_get_attention(ab, desc);
@@ -498,7 +499,9 @@ static int ath11k_dp_rxdma_pdev_buf_setu
@@ -499,7 +500,9 @@ static int ath11k_dp_rxdma_pdev_buf_setu
struct dp_rxdma_ring *rx_ring = &dp->rx_refill_buf_ring;
int i;
@ -357,7 +357,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
if (ar->ab->hw_params.rxdma1_enable) {
rx_ring = &dp->rxdma_mon_buf_ring;
@@ -2035,7 +2038,7 @@ static void ath11k_dp_rx_h_csum_offload(
@@ -2036,7 +2039,7 @@ static void ath11k_dp_rx_h_csum_offload(
CHECKSUM_NONE : CHECKSUM_UNNECESSARY;
}
@ -366,7 +366,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
enum hal_encrypt_type enctype)
{
switch (enctype) {
@@ -2062,7 +2065,7 @@ static int ath11k_dp_rx_crypto_mic_len(s
@@ -2063,7 +2066,7 @@ static int ath11k_dp_rx_crypto_mic_len(s
return 0;
}
@ -375,7 +375,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
enum hal_encrypt_type enctype)
{
switch (enctype) {
@@ -2090,7 +2093,7 @@ static int ath11k_dp_rx_crypto_param_len
@@ -2091,7 +2094,7 @@ static int ath11k_dp_rx_crypto_param_len
return 0;
}
@ -384,7 +384,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
enum hal_encrypt_type enctype)
{
switch (enctype) {
@@ -2826,6 +2829,22 @@ static void ath11k_dp_rx_process_receive
@@ -2827,6 +2830,22 @@ static void ath11k_dp_rx_process_receive
}
}
@ -407,7 +407,17 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
int ath11k_dp_process_rx(struct ath11k_base *ab, int ring_id,
struct napi_struct *napi, int budget)
{
@@ -3133,6 +3152,13 @@ static void ath11k_dp_rx_update_user_sta
@@ -3126,7 +3145,8 @@ static void ath11k_dp_rx_update_user_sta
peer = ath11k_peer_find_by_ast(ar->ab, user_stats->ast_index);
if (peer == NULL) {
- ath11k_warn(ar->ab, "peer ast idx %d can't be found\n",
+ if (!ar->ab->nss.enabled)
+ ath11k_warn(ar->ab, "peer ast idx %d can't be found\n",
user_stats->ast_index);
return;
}
@@ -3134,6 +3154,13 @@ static void ath11k_dp_rx_update_user_sta
arsta = (struct ath11k_sta *)peer->sta->drv_priv;
rx_stats = arsta->rx_stats;
@ -421,7 +431,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
if (!rx_stats)
return;
@@ -3209,8 +3235,10 @@ static void ath11k_dp_rx_update_peer_mu_
@@ -3210,8 +3237,10 @@ static void ath11k_dp_rx_update_peer_mu_
{
u32 num_users, i;
@ -433,7 +443,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
num_users = ppdu_info->num_users;
if (num_users > HAL_MAX_UL_MU_USERS)
@@ -5613,7 +5641,7 @@ int ath11k_dp_rx_process_mon_status(stru
@@ -5614,7 +5643,7 @@ int ath11k_dp_rx_process_mon_status(stru
struct sk_buff *skb;
struct sk_buff_head skb_list;
struct ath11k_peer *peer;
@ -442,7 +452,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
int num_buffs_reaped = 0;
u32 rx_buf_sz;
u16 log_type;
@@ -5681,6 +5709,7 @@ int ath11k_dp_rx_process_mon_status(stru
@@ -5682,6 +5711,7 @@ int ath11k_dp_rx_process_mon_status(stru
if (ppdu_info->reception_type == HAL_RX_RECEPTION_TYPE_SU) {
arsta = (struct ath11k_sta *)peer->sta->drv_priv;
ath11k_dp_rx_update_peer_su_stats(arsta, ppdu_info);
@ -484,7 +494,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
HAL_REO_EXCEPTION,
--- a/drivers/net/wireless/ath/ath11k/hal_rx.c
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.c
@@ -938,6 +938,12 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
@@ -939,6 +939,12 @@ ath11k_hal_rx_parse_mon_status_tlv(struc
ppdu_info->num_mpdu_fcs_err =
FIELD_GET(HAL_RX_PPDU_END_USER_STATS_INFO0_MPDU_CNT_FCS_ERR,
info0);
@ -507,7 +517,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
#define CHAN2G(_channel, _freq, _flags) { \
.band = NL80211_BAND_2GHZ, \
@@ -1603,6 +1604,11 @@ static void ath11k_control_beaconing(str
@@ -1593,6 +1594,11 @@ static void ath11k_control_beaconing(str
lockdep_assert_held(&arvif->ar->conf_mutex);
if (!info->enable_beacon) {
@ -519,7 +529,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ret = ath11k_wmi_vdev_down(ar, arvif->vdev_id);
if (ret)
ath11k_warn(ar->ab, "failed to down vdev_id %i: %d\n",
@@ -1642,6 +1648,12 @@ static void ath11k_control_beaconing(str
@@ -1632,6 +1638,12 @@ static void ath11k_control_beaconing(str
arvif->is_up = true;
@ -532,7 +542,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ath11k_dbg(ar->ab, ATH11K_DBG_MAC, "vdev %d up\n", arvif->vdev_id);
}
@@ -3075,6 +3087,12 @@ static void ath11k_bss_assoc(struct ieee
@@ -3070,6 +3082,12 @@ static void ath11k_bss_assoc(struct ieee
"vdev %d up (associated) bssid %pM aid %d\n",
arvif->vdev_id, bss_conf->bssid, vif->cfg.aid);
@ -545,7 +555,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
spin_lock_bh(&ar->ab->base_lock);
peer = ath11k_peer_find(ar->ab, arvif->vdev_id, arvif->bssid);
@@ -3117,6 +3135,10 @@ static void ath11k_bss_disassoc(struct i
@@ -3112,6 +3130,10 @@ static void ath11k_bss_disassoc(struct i
lockdep_assert_held(&ar->conf_mutex);
@ -556,8 +566,8 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ath11k_dbg(ar->ab, ATH11K_DBG_MAC, "vdev %i disassoc bssid %pM\n",
arvif->vdev_id, arvif->bssid);
@@ -3397,6 +3419,28 @@ static int ath11k_mac_config_obss_pd(str
return 0;
@@ -3404,6 +3426,28 @@ static bool ath11k_mac_supports_station_
chandef->chan->band == NL80211_BAND_6GHZ;
}
+static void ath11k_mac_op_nss_bss_info_changed(struct ieee80211_hw *hw,
@ -585,7 +595,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
static void ath11k_mac_op_bss_info_changed(struct ieee80211_hw *hw,
struct ieee80211_vif *vif,
struct ieee80211_bss_conf *info,
@@ -4295,6 +4339,26 @@ static int ath11k_mac_op_set_key(struct
@@ -4303,6 +4347,26 @@ static int ath11k_mac_op_set_key(struct
spin_lock_bh(&ab->base_lock);
peer = ath11k_peer_find(ab, arvif->vdev_id, peer_addr);
@ -612,7 +622,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
if (peer && cmd == SET_KEY) {
peer->keys[key->keyidx] = key;
if (key->flags & IEEE80211_KEY_FLAG_PAIRWISE) {
@@ -4333,9 +4397,8 @@ static int ath11k_mac_op_set_key(struct
@@ -4341,9 +4405,8 @@ static int ath11k_mac_op_set_key(struct
break;
}
}
@ -623,7 +633,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
exit:
mutex_unlock(&ar->conf_mutex);
return ret;
@@ -6216,10 +6279,14 @@ static void ath11k_mac_op_tx(struct ieee
@@ -6002,10 +6065,14 @@ static void ath11k_mac_op_tx(struct ieee
if (control->sta)
arsta = ath11k_sta_to_arsta(control->sta);
@ -639,7 +649,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
}
}
@@ -6241,6 +6308,8 @@ static int ath11k_mac_config_mon_status_
@@ -6027,6 +6094,8 @@ static int ath11k_mac_config_mon_status_
if (enable) {
tlv_filter = ath11k_mac_mon_status_filter_default;
@ -648,7 +658,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
if (ath11k_debugfs_rx_filter(ar))
tlv_filter.rx_filter = ath11k_debugfs_rx_filter(ar);
}
@@ -6539,7 +6608,7 @@ static int ath11k_mac_setup_vdev_create_
@@ -6325,7 +6394,7 @@ static int ath11k_mac_setup_vdev_create_
return 0;
}
@ -657,7 +667,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct ieee80211_vif *vif)
{
struct ath11k *ar = hw->priv;
@@ -6585,6 +6654,8 @@ static void ath11k_mac_op_update_vif_off
@@ -6371,6 +6440,8 @@ static void ath11k_mac_op_update_vif_off
arvif->vdev_id, ret);
vif->offload_flags &= ~IEEE80211_OFFLOAD_DECAP_ENABLED;
}
@ -666,7 +676,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
}
static bool ath11k_mac_vif_ap_active_any(struct ath11k_base *ab)
@@ -6715,6 +6786,8 @@ static int ath11k_mac_vdev_delete(struct
@@ -6501,6 +6572,8 @@ static int ath11k_mac_vdev_delete(struct
reinit_completion(&ar->vdev_delete_done);
@ -675,7 +685,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ret = ath11k_wmi_vdev_delete(ar, arvif->vdev_id);
if (ret) {
ath11k_warn(ar->ab, "failed to delete WMI vdev %d: %d\n",
@@ -6855,7 +6928,34 @@ static int ath11k_mac_op_add_interface(s
@@ -6634,7 +6707,34 @@ static int ath11k_mac_op_add_interface(s
list_add(&arvif->list, &ar->arvifs);
spin_unlock_bh(&ar->data_lock);
@ -711,7 +721,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
nss = get_num_chains(ar->cfg_tx_chainmask) ? : 1;
ret = ath11k_wmi_vdev_set_param_cmd(ar, arvif->vdev_id,
@@ -6979,6 +7079,7 @@ err_peer_del:
@@ -6764,6 +6864,7 @@ err_peer_del:
}
err_vdev_del:
@ -719,7 +729,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ath11k_mac_vdev_delete(ar, arvif);
spin_lock_bh(&ar->data_lock);
list_del(&arvif->list);
@@ -7489,6 +7590,10 @@ ath11k_mac_update_vif_chan(struct ath11k
@@ -7281,6 +7382,10 @@ ath11k_mac_update_vif_chan(struct ath11k
arvif->vdev_id, ret);
continue;
}
@ -730,7 +740,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
}
/* Restart the internal monitor vdev on new channel */
@@ -8717,6 +8822,8 @@ static void ath11k_mac_op_sta_statistics
@@ -8982,6 +9087,8 @@ static void ath11k_mac_op_sta_statistics
sinfo->signal_avg = ewma_avg_rssi_read(&arsta->avg_rssi) +
ATH11K_DEFAULT_NOISE_FLOOR;
sinfo->filled |= BIT_ULL(NL80211_STA_INFO_SIGNAL_AVG);
@ -739,7 +749,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
}
#if IS_ENABLED(CONFIG_IPV6)
@@ -9144,6 +9251,7 @@ static const struct ieee80211_ops ath11k
@@ -9674,6 +9781,7 @@ static const struct ieee80211_ops ath11k
.update_vif_offload = ath11k_mac_op_update_vif_offload,
.config = ath11k_mac_op_config,
.bss_info_changed = ath11k_mac_op_bss_info_changed,
@ -747,7 +757,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
.configure_filter = ath11k_mac_op_configure_filter,
.hw_scan = ath11k_mac_op_hw_scan,
.cancel_hw_scan = ath11k_mac_op_cancel_hw_scan,
@@ -9530,7 +9638,8 @@ static int __ath11k_mac_register(struct
@@ -10109,7 +10217,8 @@ static int __ath11k_mac_register(struct
ieee80211_hw_set(ar->hw, TX_AMPDU_SETUP_IN_HW);
ieee80211_hw_set(ar->hw, SUPPORTS_REORDERING_BUFFER);
ieee80211_hw_set(ar->hw, SUPPORTS_AMSDU_IN_AMPDU);
@ -757,7 +767,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
}
ar->hw->wiphy->features |= NL80211_FEATURE_STATIC_SMPS;
@@ -9645,6 +9754,9 @@ static int __ath11k_mac_register(struct
@@ -10224,6 +10333,9 @@ static int __ath11k_mac_register(struct
ab->hw_params.bios_sar_capa)
ar->hw->wiphy->sar_capa = ab->hw_params.bios_sar_capa;
@ -838,7 +848,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct ieee80211_key_conf *keys[WMI_MAX_KEY_INDEX + 1];
--- a/drivers/net/wireless/ath/ath11k/pci.c
+++ b/drivers/net/wireless/ath/ath11k/pci.c
@@ -570,6 +570,7 @@ static int ath11k_pci_claim(struct ath11
@@ -583,6 +583,7 @@ static int ath11k_pci_claim(struct ath11
}
ab->mem_ce = ab->mem;
@ -848,7 +858,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
return 0;
--- a/drivers/net/wireless/ath/ath11k/debugfs.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs.c
@@ -10,11 +10,10 @@
@@ -11,11 +11,10 @@
#include "core.h"
#include "debug.h"
#include "wmi.h"
@ -861,7 +871,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct dentry *debugfs_ath11k;
@@ -665,6 +664,7 @@ static ssize_t ath11k_write_extd_rx_stat
@@ -666,6 +665,7 @@ static ssize_t ath11k_write_extd_rx_stat
HTT_RX_FP_DATA_FILTER_FLASG3;
} else {
tlv_filter = ath11k_mac_mon_status_filter_default;
@ -869,7 +879,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
}
ar->debug.rx_filter = tlv_filter.rx_filter;
@@ -1687,6 +1687,76 @@ static const struct file_operations fops
@@ -1688,6 +1688,76 @@ static const struct file_operations fops
.open = simple_open
};
@ -946,7 +956,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
int ath11k_debugfs_register(struct ath11k *ar)
{
struct ath11k_base *ab = ar->ab;
@@ -1753,6 +1823,11 @@ int ath11k_debugfs_register(struct ath11
@@ -1754,6 +1824,11 @@ int ath11k_debugfs_register(struct ath11
&fops_reset_ps_duration);
}
@ -971,7 +981,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(skb);
--- a/drivers/net/wireless/ath/ath11k/dp_tx.h
+++ b/drivers/net/wireless/ath/ath11k/dp_tx.h
@@ -38,6 +38,8 @@ int ath11k_dp_tx_htt_rx_filter_setup(str
@@ -39,6 +39,8 @@ int ath11k_dp_tx_htt_rx_filter_setup(str
int mac_id, enum hal_ring_type ring_type,
int rx_buf_size,
struct htt_rx_ring_tlv_filter *tlv_filter);
@ -1185,7 +1195,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ath11k_hif_write32(ab, reo_base + HAL_REO1_DEST_RING_CTRL_IX_3,
--- a/drivers/net/wireless/ath/ath11k/pcic.c
+++ b/drivers/net/wireless/ath/ath11k/pcic.c
@@ -571,6 +571,12 @@ static int ath11k_pcic_ext_irq_config(st
@@ -582,6 +582,12 @@ static int ath11k_pcic_ext_irq_config(st
netif_napi_add(&irq_grp->napi_ndev, &irq_grp->napi,
ath11k_pcic_ext_grp_napi_poll);
@ -1200,7 +1210,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ab->hw_params.ring_mask->rx_err[i] ||
--- a/local-symbols
+++ b/local-symbols
@@ -170,6 +170,7 @@ WCN36XX_DEBUGFS=
@@ -163,6 +163,7 @@ WCN36XX_DEBUGFS=
ATH11K=
ATH11K_AHB=
ATH11K_PCI=

View File

@ -40,7 +40,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
[WMI_TAG_11D_NEW_COUNTRY_EVENT] = {
.min_len = sizeof(struct wmi_11d_new_cc_ev) },
[WMI_TAG_PER_CHAIN_RSSI_STATS] = {
@@ -8727,6 +8729,74 @@ exit:
@@ -8708,6 +8710,74 @@ exit:
kfree(tb);
}
@ -54,7 +54,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
+ struct ath11k *ar;
+ int ret;
+
+ tb = ath11k_wmi_tlv_parse_alloc(ab, skb->data, skb->len, GFP_ATOMIC);
+ tb = ath11k_wmi_tlv_parse_alloc(ab, skb, GFP_ATOMIC);
+ if (IS_ERR(tb)) {
+ ret = PTR_ERR(tb);
+ ath11k_warn(ab, "failed to parse tlv: %d\n", ret);
@ -115,7 +115,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
static void ath11k_wmi_tlv_op_rx(struct ath11k_base *ab, struct sk_buff *skb)
{
struct wmi_cmd_hdr *cmd_hdr;
@@ -8845,6 +8915,9 @@ static void ath11k_wmi_tlv_op_rx(struct
@@ -8826,6 +8896,9 @@ static void ath11k_wmi_tlv_op_rx(struct
case WMI_11D_NEW_COUNTRY_EVENTID:
ath11k_reg_11d_new_cc_event(ab, skb);
break;
@ -127,7 +127,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
break;
--- a/drivers/net/wireless/ath/ath11k/wmi.h
+++ b/drivers/net/wireless/ath/ath11k/wmi.h
@@ -759,6 +759,7 @@ enum wmi_tlv_event_id {
@@ -776,6 +776,7 @@ enum wmi_tlv_event_id {
WMI_READ_DATA_FROM_FLASH_EVENTID,
WMI_REPORT_RX_AGGR_FAILURE_EVENTID,
WMI_PKGID_EVENTID,
@ -135,7 +135,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
WMI_GPIO_INPUT_EVENTID = WMI_TLV_CMD(WMI_GRP_GPIO),
WMI_UPLOADH_EVENTID,
WMI_CAPTUREH_EVENTID,
@@ -1869,6 +1870,7 @@ enum wmi_tlv_tag {
@@ -1888,6 +1889,7 @@ enum wmi_tlv_tag {
WMI_TAG_NDP_EVENT,
WMI_TAG_PDEV_PEER_PKTLOG_FILTER_CMD = 0x301,
WMI_TAG_PDEV_PEER_PKTLOG_FILTER_INFO,
@ -143,7 +143,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
WMI_TAG_FILS_DISCOVERY_TMPL_CMD = 0x344,
WMI_TAG_PDEV_SRG_BSS_COLOR_BITMAP_CMD = 0x37b,
WMI_TAG_PDEV_SRG_PARTIAL_BSSID_BITMAP_CMD,
@@ -4868,6 +4870,16 @@ struct wmi_pdev_temperature_event {
@@ -4890,6 +4892,16 @@ struct wmi_pdev_temperature_event {
u32 pdev_id;
} __packed;

View File

@ -21,7 +21,7 @@ Signed-off-by: Seevalamuthu Mariappan <seevalam@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -119,6 +119,7 @@ struct ath11k_skb_cb {
@@ -122,6 +122,7 @@ struct ath11k_skb_cb {
u32 cipher;
struct ath11k *ar;
struct ieee80211_vif *vif;
@ -162,7 +162,7 @@ Signed-off-by: Seevalamuthu Mariappan <seevalam@codeaurora.org>
if (ts->acked) {
--- a/drivers/net/wireless/ath/ath11k/dp_tx.h
+++ b/drivers/net/wireless/ath/ath11k/dp_tx.h
@@ -16,6 +16,204 @@ struct ath11k_dp_htt_wbm_tx_status {
@@ -17,6 +17,204 @@ struct ath11k_dp_htt_wbm_tx_status {
u16 peer_id;
};
@ -369,7 +369,7 @@ Signed-off-by: Seevalamuthu Mariappan <seevalam@codeaurora.org>
int ath11k_dp_tx(struct ath11k *ar, struct ath11k_vif *arvif,
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -9771,6 +9771,9 @@ static int __ath11k_mac_register(struct
@@ -10350,6 +10350,9 @@ static int __ath11k_mac_register(struct
*/
ar->hw->wiphy->interface_modes &= ~BIT(NL80211_IFTYPE_MONITOR);

View File

@ -93,9 +93,9 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
bool smp2p_wow_exit;
bool support_fw_mac_sequence;
+ const struct ath11k_num_vdevs_peers *num_vdevs_peers;
bool support_dual_stations;
};
struct ath11k_hw_ops {
--- a/drivers/net/wireless/ath/ath11k/qmi.h
+++ b/drivers/net/wireless/ath/ath11k/qmi.h
@@ -29,6 +29,12 @@
@ -125,7 +125,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
ATH11K_QMI_FILE_TYPE_BDF_GOLDEN,
--- a/local-symbols
+++ b/local-symbols
@@ -171,6 +171,8 @@ ATH11K=
@@ -164,6 +164,8 @@ ATH11K=
ATH11K_AHB=
ATH11K_PCI=
ATH11K_NSS_SUPPORT=
@ -136,7 +136,23 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
ATH11K_TRACING=
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -887,6 +887,11 @@ struct ath11k_msi_config {
@@ -17,7 +17,6 @@
#include <linux/average.h>
#include <linux/firmware.h>
-#include "fw.h"
#include "qmi.h"
#include "htc.h"
#include "wmi.h"
@@ -34,6 +33,7 @@
#include "wow.h"
#include "rx_desc.h"
#include "nss.h"
+#include "fw.h"
#define SM(_v, _f) (((_v) << _f##_LSB) & _f##_MASK)
@@ -925,6 +925,11 @@ struct ath11k_msi_config {
u16 hw_rev;
};
@ -148,9 +164,9 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
/* Master structure to hold the hw data which may be used in core module */
struct ath11k_base {
enum ath11k_hw_rev hw_rev;
@@ -1032,6 +1037,8 @@ struct ath11k_base {
const struct ath11k_pci_ops *ops;
} pci;
@@ -1082,6 +1087,8 @@ struct ath11k_base {
DECLARE_BITMAP(fw_features, ATH11K_FW_FEATURE_COUNT);
} fw;
+ atomic_t num_max_allowed;
+
@ -219,7 +235,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -42,6 +42,8 @@ bool ath11k_ftm_mode;
@@ -43,6 +43,8 @@ bool ath11k_ftm_mode;
module_param_named(ftm_mode, ath11k_ftm_mode, bool, 0444);
MODULE_PARM_DESC(ftm_mode, "Boots up in factory test mode");
@ -228,15 +244,15 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
static struct ath11k_hw_params ath11k_hw_params[] = {
{
.hw_rev = ATH11K_HW_IPQ8074,
@@ -127,6 +129,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -128,6 +130,7 @@ static struct ath11k_hw_params ath11k_hw
.tcl_ring_retry = true,
.tx_ring_size = DP_TCL_DATA_RING_SIZE,
.smp2p_wow_exit = false,
+ .num_vdevs_peers = ath11k_vdevs_peers,
.support_dual_stations = false,
},
{
.hw_rev = ATH11K_HW_IPQ6018_HW10,
@@ -177,7 +180,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -179,7 +182,7 @@ static struct ath11k_hw_params ath11k_hw
.coldboot_cal_mm = false,
.coldboot_cal_ftm = false,
.cbcal_restart_fw = true,
@ -245,59 +261,59 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
.num_vdevs = 16 + 1,
.num_peers = 512,
.supports_suspend = false,
@@ -259,7 +262,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -262,7 +265,7 @@ static struct ath11k_hw_params ath11k_hw
.coldboot_cal_mm = false,
.coldboot_cal_ftm = false,
.cbcal_restart_fw = false,
- .fw_mem_mode = 0,
+ .fw_mem_mode = ATH11K_QMI_TARGET_MEM_MODE,
.num_vdevs = 16 + 1,
.num_vdevs = 2 + 1,
.num_peers = 512,
.supports_suspend = true,
@@ -426,7 +429,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -431,7 +434,7 @@ static struct ath11k_hw_params ath11k_hw
.coldboot_cal_mm = false,
.coldboot_cal_ftm = false,
.cbcal_restart_fw = false,
- .fw_mem_mode = 0,
+ .fw_mem_mode = ATH11K_QMI_TARGET_MEM_MODE,
.num_vdevs = 16 + 1,
.num_vdevs = 2 + 1,
.num_peers = 512,
.supports_suspend = true,
@@ -462,6 +465,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -467,6 +470,7 @@ static struct ath11k_hw_params ath11k_hw
.tx_ring_size = DP_TCL_DATA_RING_SIZE,
.smp2p_wow_exit = false,
.support_fw_mac_sequence = true,
+ .num_vdevs_peers = ath11k_vdevs_peers,
.support_dual_stations = true,
},
{
.name = "wcn6855 hw2.1",
@@ -509,7 +513,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -515,7 +519,7 @@ static struct ath11k_hw_params ath11k_hw
.coldboot_cal_mm = false,
.coldboot_cal_ftm = false,
.cbcal_restart_fw = false,
- .fw_mem_mode = 0,
+ .fw_mem_mode = ATH11K_QMI_TARGET_MEM_MODE,
.num_vdevs = 16 + 1,
.num_vdevs = 2 + 1,
.num_peers = 512,
.supports_suspend = true,
@@ -545,6 +549,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -551,6 +555,7 @@ static struct ath11k_hw_params ath11k_hw
.tx_ring_size = DP_TCL_DATA_RING_SIZE,
.smp2p_wow_exit = false,
.support_fw_mac_sequence = true,
+ .num_vdevs_peers = ath11k_vdevs_peers,
.support_dual_stations = true,
},
{
.name = "wcn6750 hw1.0",
@@ -593,7 +598,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -600,7 +605,7 @@ static struct ath11k_hw_params ath11k_hw
.coldboot_cal_mm = true,
.coldboot_cal_ftm = true,
.cbcal_restart_fw = false,
- .fw_mem_mode = 0,
+ .fw_mem_mode = ATH11K_QMI_TARGET_MEM_MODE,
.num_vdevs = 16 + 1,
.num_vdevs = 3,
.num_peers = 512,
.supports_suspend = false,
@@ -672,7 +677,7 @@ static struct ath11k_hw_params ath11k_hw
@@ -680,7 +685,7 @@ static struct ath11k_hw_params ath11k_hw
.supports_monitor = false,
.supports_sta_ps = false,
.supports_shadow_regs = false,
@ -306,14 +322,18 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
.num_vdevs = 16 + 1,
.num_peers = 512,
.supports_regdb = false,
@@ -707,6 +712,22 @@ static struct ath11k_hw_params ath11k_hw
@@ -715,6 +720,7 @@ static struct ath11k_hw_params ath11k_hw
.tx_ring_size = DP_TCL_DATA_RING_SIZE,
.smp2p_wow_exit = false,
.support_fw_mac_sequence = false,
+ .num_vdevs_peers = ath11k_vdevs_peers,
+ },
+};
+
.support_dual_stations = false,
},
{
@@ -805,6 +811,21 @@ static struct ath11k_hw_params ath11k_hw
},
};
+static const struct ath11k_num_vdevs_peers ath11k_vdevs_peers[] = {
+ {
+ .num_vdevs = (16 + 1),
@ -326,6 +346,9 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
+ {
+ .num_vdevs = 8,
+ .num_peers = 128,
},
};
+ },
+};
+
static inline struct ath11k_pdev *ath11k_core_get_single_pdev(struct ath11k_base *ab)
{
WARN_ON(!ab->hw_params.single_pdev_only);

View File

@ -26,7 +26,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -642,6 +642,7 @@ struct ath11k {
@@ -679,6 +679,7 @@ struct ath11k {
struct ath11k_pdev_wmi *wmi;
#ifdef CPTCFG_ATH11K_NSS_SUPPORT
struct ath11k_nss nss;
@ -34,7 +34,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
#endif
struct ath11k_pdev_dp dp;
u8 mac_addr[ETH_ALEN];
@@ -1047,6 +1048,9 @@ struct ath11k_base {
@@ -1097,6 +1098,9 @@ struct ath11k_base {
} testmode;
#endif
@ -67,7 +67,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
struct htt_resp_msg {
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -1857,6 +1857,8 @@ void ath11k_dp_htt_htc_t2h_msg_handler(s
@@ -1858,6 +1858,8 @@ void ath11k_dp_htt_htc_t2h_msg_handler(s
u16 peer_mac_h16;
u16 ast_hash;
u16 hw_peer_id;
@ -76,7 +76,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
ath11k_dbg(ab, ATH11K_DBG_DP_HTT, "dp_htt rx msg type :0x%0x\n", type);
@@ -1892,15 +1894,29 @@ void ath11k_dp_htt_htc_t2h_msg_handler(s
@@ -1893,15 +1895,29 @@ void ath11k_dp_htt_htc_t2h_msg_handler(s
resp->peer_map_ev.info2);
hw_peer_id = FIELD_GET(HTT_T2H_PEER_MAP_INFO1_HW_PEER_ID,
resp->peer_map_ev.info1);
@ -837,7 +837,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
int ath11k_wmi_send_pdev_set_regdomain(struct ath11k *ar,
struct pdev_set_regdomain_params *param)
{
@@ -6363,6 +6410,36 @@ static int ath11k_pull_peer_assoc_conf_e
@@ -6436,6 +6483,36 @@ static int ath11k_pull_peer_assoc_conf_e
return 0;
}
@ -848,7 +848,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
+ const struct wmi_wds_addr_event *ev;
+ int ret;
+
+ tb = ath11k_wmi_tlv_parse_alloc(ab, skb->data, skb->len, GFP_ATOMIC);
+ tb = ath11k_wmi_tlv_parse_alloc(ab, skb, GFP_ATOMIC);
+ if (IS_ERR(tb)) {
+ ret = PTR_ERR(tb);
+ ath11k_warn(ab, "failed to parse tlv: %d\n", ret);
@ -874,7 +874,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
static void ath11k_wmi_pull_pdev_stats_base(const struct wmi_pdev_stats_base *src,
struct ath11k_fw_stats_pdev *dst)
{
@@ -7278,6 +7355,7 @@ static int ath11k_wmi_tlv_rdy_parse(stru
@@ -7260,6 +7337,7 @@ static int ath11k_wmi_tlv_rdy_parse(stru
ether_addr_copy(ab->mac_addr,
fixed_param.ready_event_min.mac_addr.addr);
@ -882,7 +882,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
ab->pktlog_defs_checksum = fixed_param.pktlog_defs_checksum;
break;
case WMI_TAG_ARRAY_FIXED_STRUCT:
@@ -8797,6 +8875,22 @@ exit:
@@ -8778,6 +8856,22 @@ exit:
kfree(tb);
}
@ -905,7 +905,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
static void ath11k_wmi_tlv_op_rx(struct ath11k_base *ab, struct sk_buff *skb)
{
struct wmi_cmd_hdr *cmd_hdr;
@@ -8927,6 +9021,9 @@ static void ath11k_wmi_tlv_op_rx(struct
@@ -8908,6 +9002,9 @@ static void ath11k_wmi_tlv_op_rx(struct
case WMI_GTK_OFFLOAD_STATUS_EVENTID:
ath11k_wmi_gtk_offload_status_event(ab, skb);
break;
@ -917,7 +917,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
break;
--- a/drivers/net/wireless/ath/ath11k/wmi.h
+++ b/drivers/net/wireless/ath/ath11k/wmi.h
@@ -3011,6 +3011,21 @@ struct wmi_peer_delete_cmd {
@@ -3032,6 +3032,21 @@ struct wmi_peer_delete_cmd {
struct wmi_mac_addr peer_macaddr;
} __packed;
@ -939,7 +939,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
struct wmi_peer_reorder_queue_setup_cmd {
u32 tlv_header;
u32 vdev_id;
@@ -4613,6 +4628,21 @@ struct wmi_probe_resp_tx_status_event {
@@ -4635,6 +4650,21 @@ struct wmi_probe_resp_tx_status_event {
u32 tx_status;
} __packed;
@ -961,7 +961,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
/*
* PDEV statistics
*/
@@ -6412,6 +6442,9 @@ int ath11k_wmi_set_sta_ps_param(struct a
@@ -6434,6 +6464,9 @@ int ath11k_wmi_set_sta_ps_param(struct a
int ath11k_wmi_force_fw_hang_cmd(struct ath11k *ar, u32 type, u32 delay_time_ms);
int ath11k_wmi_send_peer_delete_cmd(struct ath11k *ar,
const u8 *peer_addr, u8 vdev_id);

View File

@ -22,7 +22,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -6129,6 +6129,16 @@ static int ath11k_mac_mgmt_tx_wmi(struct
@@ -5915,6 +5915,16 @@ static int ath11k_mac_mgmt_tx_wmi(struct
ATH11K_SKB_CB(skb)->paddr = paddr;
@ -39,7 +39,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
ret = ath11k_wmi_mgmt_send(ar, arvif->vdev_id, buf_id, skb);
if (ret) {
ath11k_warn(ar->ab, "failed to send mgmt frame: %d\n", ret);
@@ -6196,8 +6206,8 @@ static void ath11k_mgmt_over_wmi_tx_work
@@ -5982,8 +5992,8 @@ static void ath11k_mgmt_over_wmi_tx_work
}
}
@ -50,7 +50,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
{
struct sk_buff_head *q = &ar->wmi_mgmt_tx_queue;
@@ -6259,7 +6269,7 @@ static void ath11k_mac_op_tx(struct ieee
@@ -6045,7 +6055,7 @@ static void ath11k_mac_op_tx(struct ieee
} else if (ieee80211_is_mgmt(hdr->frame_control)) {
frm_type = FIELD_GET(IEEE80211_FCTL_STYPE, hdr->frame_control);
is_prb_rsp = ieee80211_is_probe_resp(hdr->frame_control);
@ -59,7 +59,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
if (ret) {
if (ret != -EBUSY)
ath11k_warn(ar->ab, "failed to queue management frame %d\n",
@@ -6274,6 +6284,20 @@ static void ath11k_mac_op_tx(struct ieee
@@ -6060,6 +6070,20 @@ static void ath11k_mac_op_tx(struct ieee
spin_unlock_bh(&ar->data_lock);
}
return;
@ -147,7 +147,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
int ath11k_wmi_vdev_create(struct ath11k *ar, u8 *macaddr,
struct vdev_create_params *param)
{
@@ -5905,8 +5954,8 @@ static int ath11k_pull_mgmt_rx_params_tl
@@ -5978,8 +6027,8 @@ static int ath11k_pull_mgmt_rx_params_tl
return 0;
}
@ -158,7 +158,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
{
struct sk_buff *msdu;
struct ieee80211_tx_info *info;
@@ -5944,6 +5993,11 @@ static int wmi_process_mgmt_tx_comp(stru
@@ -6017,6 +6066,11 @@ static int wmi_process_mgmt_tx_comp(stru
info->status.ack_signal = tx_compl_param->ack_rssi;
}
@ -170,7 +170,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
hdr = (struct ieee80211_hdr *)msdu->data;
frm_type = FIELD_GET(IEEE80211_FCTL_STYPE, hdr->frame_control);
@@ -5962,10 +6016,13 @@ static int wmi_process_mgmt_tx_comp(stru
@@ -6035,10 +6089,13 @@ static int wmi_process_mgmt_tx_comp(stru
arvif = ath11k_vif_to_arvif(vif);
mgmt_stats = &arvif->mgmt_stats;
@ -188,7 +188,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
spin_unlock_bh(&ar->data_lock);
skip_mgmt_stats:
@@ -5987,12 +6044,13 @@ skip_mgmt_stats:
@@ -6060,12 +6117,13 @@ skip_mgmt_stats:
return 0;
}
@ -205,8 +205,8 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
+ const struct wmi_tx_compl_event *ev;
int ret;
tb = ath11k_wmi_tlv_parse_alloc(ab, skb->data, skb->len, GFP_ATOMIC);
@@ -6002,7 +6060,7 @@ static int ath11k_pull_mgmt_tx_compl_par
tb = ath11k_wmi_tlv_parse_alloc(ab, skb, GFP_ATOMIC);
@@ -6075,7 +6133,7 @@ static int ath11k_pull_mgmt_tx_compl_par
return ret;
}
@ -215,7 +215,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
if (!ev) {
ath11k_warn(ab, "failed to fetch mgmt tx compl ev");
kfree(tb);
@@ -7810,10 +7868,11 @@ exit:
@@ -7791,10 +7849,11 @@ exit:
static void ath11k_mgmt_tx_compl_event(struct ath11k_base *ab, struct sk_buff *skb)
{
@ -229,7 +229,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
ath11k_warn(ab, "failed to extract mgmt tx compl event");
return;
}
@@ -7826,7 +7885,7 @@ static void ath11k_mgmt_tx_compl_event(s
@@ -7807,7 +7866,7 @@ static void ath11k_mgmt_tx_compl_event(s
goto exit;
}
@ -238,7 +238,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
ath11k_dbg(ab, ATH11K_DBG_MGMT,
"event mgmt tx compl ev pdev_id %d, desc_id %d, status %d ack_rssi %d",
@@ -7837,6 +7896,36 @@ exit:
@@ -7818,6 +7877,36 @@ exit:
rcu_read_unlock();
}
@ -275,7 +275,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
static struct ath11k *ath11k_get_ar_on_scan_state(struct ath11k_base *ab,
u32 vdev_id,
enum ath11k_scan_state state)
@@ -9024,6 +9113,10 @@ static void ath11k_wmi_tlv_op_rx(struct
@@ -9005,6 +9094,10 @@ static void ath11k_wmi_tlv_op_rx(struct
case WMI_WDS_PEER_EVENTID:
ath11k_wmi_wds_peer_event(ab, skb);
break;
@ -288,7 +288,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
break;
--- a/drivers/net/wireless/ath/ath11k/wmi.h
+++ b/drivers/net/wireless/ath/ath11k/wmi.h
@@ -363,6 +363,7 @@ enum wmi_tlv_cmd_id {
@@ -380,6 +380,7 @@ enum wmi_tlv_cmd_id {
WMI_BSS_COLOR_CHANGE_ENABLE_CMDID,
WMI_VDEV_BCN_OFFLOAD_QUIET_CONFIG_CMDID,
WMI_FILS_DISCOVERY_TMPL_CMDID,
@ -296,7 +296,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
WMI_ADDBA_CLEAR_RESP_CMDID = WMI_TLV_CMD(WMI_GRP_BA_NEG),
WMI_ADDBA_SEND_CMDID,
WMI_ADDBA_STATUS_CMDID,
@@ -693,6 +694,8 @@ enum wmi_tlv_event_id {
@@ -710,6 +711,8 @@ enum wmi_tlv_event_id {
WMI_TBTTOFFSET_EXT_UPDATE_EVENTID,
WMI_OFFCHAN_DATA_TX_COMPLETION_EVENTID,
WMI_HOST_FILS_DISCOVERY_EVENTID,
@ -305,17 +305,17 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
WMI_TX_DELBA_COMPLETE_EVENTID = WMI_TLV_CMD(WMI_GRP_BA_NEG),
WMI_TX_ADDBA_COMPLETE_EVENTID,
WMI_BA_RSP_SSN_EVENTID,
@@ -1880,6 +1883,9 @@ enum wmi_tlv_tag {
@@ -1899,6 +1902,9 @@ enum wmi_tlv_tag {
WMI_TAG_PDEV_NON_SRG_OBSS_BSSID_ENABLE_BITMAP_CMD,
WMI_TAG_REGULATORY_RULE_EXT_STRUCT = 0x3A9,
WMI_TAG_REG_CHAN_LIST_CC_EXT_EVENT,
+ /* TODO add all the missing cmds */
+ WMI_TAG_QOS_NULL_FRAME_TX_SEND = 0x3A6,
+ WMI_TAG_QOS_NULL_FRAME_TX_STATUS,
WMI_TAG_VDEV_SET_TPC_POWER_CMD = 0x3B5,
WMI_TAG_VDEV_CH_POWER_INFO,
WMI_TAG_PDEV_SET_BIOS_SAR_TABLE_CMD = 0x3D8,
WMI_TAG_PDEV_SET_BIOS_GEO_TABLE_CMD,
WMI_TAG_MAX
@@ -2109,7 +2115,17 @@ enum wmi_tlv_service {
@@ -2130,7 +2136,17 @@ enum wmi_tlv_service {
WMI_TLV_SERVICE_PEER_POWER_SAVE_DURATION_SUPPORT = 246,
WMI_TLV_SERVICE_SRG_SRP_SPATIAL_REUSE_SUPPORT = 249,
WMI_TLV_SERVICE_MBSS_PARAM_IN_VDEV_START_SUPPORT = 253,
@ -333,7 +333,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
/* The second 128 bits */
WMI_MAX_EXT_SERVICE = 256,
@@ -3831,6 +3847,7 @@ struct wmi_scan_prob_req_oui_cmd {
@@ -3877,6 +3893,7 @@ struct wmi_scan_prob_req_oui_cmd {
} __packed;
#define WMI_MGMT_SEND_DOWNLD_LEN 64
@ -341,7 +341,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
#define WMI_TX_PARAMS_DWORD0_POWER GENMASK(7, 0)
#define WMI_TX_PARAMS_DWORD0_MCS_MASK GENMASK(19, 8)
@@ -3841,9 +3858,10 @@ struct wmi_scan_prob_req_oui_cmd {
@@ -3887,9 +3904,10 @@ struct wmi_scan_prob_req_oui_cmd {
#define WMI_TX_PARAMS_DWORD1_BW_MASK GENMASK(14, 8)
#define WMI_TX_PARAMS_DWORD1_PREAMBLE_TYPE GENMASK(19, 15)
#define WMI_TX_PARAMS_DWORD1_FRAME_TYPE BIT(20)
@ -354,7 +354,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
u32 tlv_header;
u32 tx_params_dword0;
u32 tx_params_dword1;
@@ -4959,7 +4977,7 @@ struct wmi_rssi_ctl_ext {
@@ -4981,7 +4999,7 @@ struct wmi_rssi_ctl_ext {
u32 rssi_ctl_ext[MAX_ANTENNA_EIGHT - ATH_MAX_ANTENNA];
};
@ -363,7 +363,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
u32 desc_id;
u32 status;
u32 pdev_id;
@@ -5790,6 +5808,17 @@ struct wmi_debug_log_config_cmd_fixed_pa
@@ -5813,6 +5831,17 @@ struct wmi_debug_log_config_cmd_fixed_pa
u32 value;
} __packed;
@ -381,7 +381,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
#define WMI_MAX_MEM_REQS 32
#define MAX_RADIOS 3
@@ -6400,6 +6429,8 @@ int ath11k_wmi_cmd_send(struct ath11k_pd
@@ -6422,6 +6451,8 @@ int ath11k_wmi_cmd_send(struct ath11k_pd
struct sk_buff *ath11k_wmi_alloc_skb(struct ath11k_wmi_base *wmi_sc, u32 len);
int ath11k_wmi_mgmt_send(struct ath11k *ar, u32 vdev_id, u32 buf_id,
struct sk_buff *frame);

View File

@ -33,7 +33,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -389,6 +389,7 @@ struct ath11k_vif {
@@ -427,6 +427,7 @@ struct ath11k_vif {
#ifdef CPTCFG_ATH11K_NSS_SUPPORT
struct arvif_nss nss;
#endif
@ -43,7 +43,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
struct ath11k_vif_iter {
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -4739,6 +4739,11 @@ static void ath11k_sta_rc_update_wk(stru
@@ -4755,6 +4755,11 @@ static void ath11k_sta_rc_update_wk(stru
arvif = arsta->arvif;
ar = arvif->ar;
@ -55,7 +55,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
if (WARN_ON(ath11k_mac_vif_chan(arvif->vif, &def)))
return;
@@ -4910,17 +4915,28 @@ err_rc_bw_changed:
@@ -4924,17 +4929,28 @@ err_rc_bw_changed:
static void ath11k_sta_set_4addr_wk(struct work_struct *wk)
{
struct ath11k *ar;
@ -86,7 +86,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
"setting USE_4ADDR for peer %pM\n", sta->addr);
ret = ath11k_wmi_set_peer_param(ar, sta->addr,
@@ -4928,8 +4944,93 @@ static void ath11k_sta_set_4addr_wk(stru
@@ -4942,8 +4958,93 @@ static void ath11k_sta_set_4addr_wk(stru
WMI_PEER_USE_4ADDR, 1);
if (ret)
@ -181,7 +181,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
}
static int ath11k_mac_inc_num_stations(struct ath11k_vif *arvif,
@@ -5259,9 +5360,32 @@ static void ath11k_mac_op_sta_set_4addr(
@@ -5045,9 +5146,32 @@ static void ath11k_mac_op_sta_set_4addr(
struct ieee80211_sta *sta, bool enabled)
{
struct ath11k *ar = hw->priv;
@ -214,7 +214,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
ieee80211_queue_work(ar->hw, &arsta->set_4addr_wk);
arsta->use_4addr_set = true;
}
@@ -6641,6 +6765,9 @@ static int ath11k_mac_op_update_vif_offl
@@ -6427,6 +6551,9 @@ static int ath11k_mac_op_update_vif_offl
u32 param_id, param_value;
int ret;
@ -224,7 +224,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
param_id = WMI_VDEV_PARAM_TX_ENCAP_TYPE;
if (ath11k_frame_mode != ATH11K_HW_TXRX_ETHERNET ||
(vif->type != NL80211_IFTYPE_STATION &&
@@ -6861,7 +6988,8 @@ static int ath11k_mac_op_add_interface(s
@@ -6647,7 +6774,8 @@ static int ath11k_mac_op_add_interface(s
goto err;
}
@ -234,7 +234,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
ath11k_warn(ab, "failed to create vdev %u, reached max vdev limit %d\n",
ar->num_created_vdevs, TARGET_NUM_VDEVS(ab));
ret = -EBUSY;
@@ -6881,6 +7009,28 @@ static int ath11k_mac_op_add_interface(s
@@ -6660,6 +6788,28 @@ static int ath11k_mac_op_add_interface(s
arvif->vif = vif;
INIT_LIST_HEAD(&arvif->list);
@ -263,7 +263,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
INIT_DELAYED_WORK(&arvif->connection_loss_work,
ath11k_mac_vif_sta_connection_loss_work);
@@ -6910,6 +7060,7 @@ static int ath11k_mac_op_add_interface(s
@@ -6689,6 +6839,7 @@ static int ath11k_mac_op_add_interface(s
fallthrough;
case NL80211_IFTYPE_AP:
arvif->vdev_type = WMI_VDEV_TYPE_AP;
@ -271,7 +271,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
break;
case NL80211_IFTYPE_MONITOR:
arvif->vdev_type = WMI_VDEV_TYPE_MONITOR;
@@ -7132,13 +7283,30 @@ static void ath11k_mac_op_remove_interfa
@@ -6917,13 +7068,30 @@ static void ath11k_mac_op_remove_interfa
struct ath11k *ar = hw->priv;
struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
struct ath11k_base *ab = ar->ab;
@ -304,7 +304,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
ath11k_dbg(ab, ATH11K_DBG_MAC, "remove interface (vdev %d)\n",
arvif->vdev_id);
@@ -7155,6 +7323,14 @@ static void ath11k_mac_op_remove_interfa
@@ -6940,6 +7108,14 @@ static void ath11k_mac_op_remove_interfa
if (ret)
ath11k_warn(ab, "failed to submit AP self-peer removal on vdev %d: %d\n",
arvif->vdev_id, ret);
@ -319,9 +319,9 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
}
ret = ath11k_mac_vdev_delete(ar, arvif);
@@ -7198,8 +7374,7 @@ err_vdev_del:
ath11k_debugfs_remove_interface(arvif);
@@ -6981,8 +7157,7 @@ err_vdev_del:
/* Recalc txpower for remaining vdev */
ath11k_mac_txpower_recalc(ar);
- /* TODO: recal traffic pause state based on the available vdevs */
-
@ -329,7 +329,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
mutex_unlock(&ar->conf_mutex);
}
@@ -7259,16 +7434,17 @@ static int ath11k_mac_op_ampdu_action(st
@@ -7042,16 +7217,17 @@ static int ath11k_mac_op_ampdu_action(st
struct ieee80211_ampdu_params *params)
{
struct ath11k *ar = hw->priv;
@ -349,7 +349,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
break;
case IEEE80211_AMPDU_TX_START:
case IEEE80211_AMPDU_TX_STOP_CONT:
@@ -8791,6 +8967,7 @@ static void ath11k_mac_op_sta_statistics
@@ -9056,6 +9232,7 @@ static void ath11k_mac_op_sta_statistics
{
struct ath11k_sta *arsta = ath11k_sta_to_arsta(sta);
struct ath11k *ar = arsta->arvif->ar;
@ -357,7 +357,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
s8 signal;
bool db2dbm = test_bit(WMI_TLV_SERVICE_HW_DB2DBM_CONVERSION_SUPPORT,
ar->ab->wmi_ab.svc_map);
@@ -8847,7 +9024,8 @@ static void ath11k_mac_op_sta_statistics
@@ -9112,7 +9289,8 @@ static void ath11k_mac_op_sta_statistics
ATH11K_DEFAULT_NOISE_FLOOR;
sinfo->filled |= BIT_ULL(NL80211_STA_INFO_SIGNAL_AVG);
@ -369,7 +369,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
#if IS_ENABLED(CONFIG_IPV6)
--- a/drivers/net/wireless/ath/ath11k/wmi.h
+++ b/drivers/net/wireless/ath/ath11k/wmi.h
@@ -5082,6 +5082,8 @@ enum wmi_vdev_subtype {
@@ -5105,6 +5105,8 @@ enum wmi_vdev_subtype {
WMI_VDEV_SUBTYPE_MESH_11S,
};
@ -380,7 +380,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
WMI_STA_PS_PARAM_TX_WAKE_THRESHOLD = 1,
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -1121,12 +1121,13 @@ err_mem_free:
@@ -1122,12 +1122,13 @@ err_mem_free:
return ret;
}
@ -396,7 +396,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
int ret;
ret = ath11k_peer_rx_tid_setup(ar, params->sta->addr, vdev_id,
@@ -1138,13 +1139,13 @@ int ath11k_dp_rx_ampdu_start(struct ath1
@@ -1139,13 +1140,13 @@ int ath11k_dp_rx_ampdu_start(struct ath1
return ret;
}

View File

@ -36,7 +36,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -99,6 +99,11 @@ enum ath11k_crypt_mode {
@@ -102,6 +102,11 @@ enum ath11k_crypt_mode {
ATH11K_CRYPT_MODE_SW,
};
@ -48,7 +48,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
static inline enum wme_ac ath11k_tid_to_ac(u32 tid)
{
return (((tid == 0) || (tid == 3)) ? WME_AC_BE :
@@ -326,6 +331,20 @@ struct ath11k_mgmt_frame_stats {
@@ -367,6 +372,20 @@ struct ath11k_mgmt_frame_stats {
u32 tx_compl_fail[ATH11K_STATS_MGMT_FRM_TYPE_MAX];
};
@ -69,7 +69,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
struct ath11k_vif {
u32 vdev_id;
enum wmi_vdev_type vdev_type;
@@ -390,6 +409,11 @@ struct ath11k_vif {
@@ -428,6 +447,11 @@ struct ath11k_vif {
struct arvif_nss nss;
#endif
struct list_head ap_vlan_arvifs;
@ -83,7 +83,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
struct ath11k_vif_iter {
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -346,6 +346,10 @@ enum nl80211_he_gi ath11k_mac_he_gi_to_n
@@ -343,6 +343,10 @@ enum nl80211_he_gi ath11k_mac_he_gi_to_n
return ret;
}
@ -94,7 +94,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
u8 ath11k_mac_bw_to_mac80211_bw(u8 bw)
{
u8 ret = 0;
@@ -718,6 +722,33 @@ u8 ath11k_mac_get_target_pdev_id(struct
@@ -715,6 +719,33 @@ u8 ath11k_mac_get_target_pdev_id(struct
return ar->ab->target_pdev_ids[0].pdev_id;
}
@ -128,7 +128,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
static void ath11k_pdev_caps_update(struct ath11k *ar)
{
struct ath11k_base *ab = ar->ab;
@@ -4167,6 +4198,9 @@ static int ath11k_install_key(struct ath
@@ -4175,6 +4206,9 @@ static int ath11k_install_key(struct ath
if (test_bit(ATH11K_FLAG_HW_CRYPTO_DISABLED, &ar->ab->dev_flags))
return 0;
@ -138,7 +138,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
if (cmd == DISABLE_KEY) {
arg.key_cipher = WMI_CIPHER_NONE;
arg.key_data = NULL;
@@ -4256,15 +4290,40 @@ static int ath11k_clear_peer_keys(struct
@@ -4264,15 +4298,40 @@ static int ath11k_clear_peer_keys(struct
return first_errno;
}
@ -181,7 +181,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
const u8 *peer_addr;
int ret = 0;
u32 flags = 0;
@@ -4282,17 +4341,38 @@ static int ath11k_mac_op_set_key(struct
@@ -4290,17 +4349,38 @@ static int ath11k_mac_op_set_key(struct
if (key->keyidx > WMI_MAX_KEY_INDEX)
return -ENOSPC;
@ -224,7 +224,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
/* the peer should not disappear in mid-way (unless FW goes awry) since
* we already hold conf_mutex. we just make sure its there now.
*/
@@ -4337,6 +4417,74 @@ static int ath11k_mac_op_set_key(struct
@@ -4345,6 +4425,74 @@ static int ath11k_mac_op_set_key(struct
goto exit;
}
@ -299,7 +299,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
spin_lock_bh(&ab->base_lock);
peer = ath11k_peer_find(ab, arvif->vdev_id, peer_addr);
@@ -4359,6 +4507,27 @@ static int ath11k_mac_op_set_key(struct
@@ -4367,6 +4515,27 @@ static int ath11k_mac_op_set_key(struct
goto unlock;
}
@ -327,7 +327,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
if (peer && cmd == SET_KEY) {
peer->keys[key->keyidx] = key;
if (key->flags & IEEE80211_KEY_FLAG_PAIRWISE) {
@@ -4368,18 +4537,23 @@ static int ath11k_mac_op_set_key(struct
@@ -4376,18 +4545,23 @@ static int ath11k_mac_op_set_key(struct
peer->mcast_keyidx = key->keyidx;
peer->sec_type_grp = ath11k_dp_tx_get_encrypt_type(key->cipher);
}
@ -354,8 +354,81 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
switch (key->cipher) {
case WLAN_CIPHER_SUITE_TKIP:
@@ -5186,6 +5360,33 @@ static u32 ath11k_mac_ieee80211_sta_bw_t
return bw;
@@ -6792,7 +6966,7 @@ static int ath11k_mac_op_add_interface(s
if ((vif->type == NL80211_IFTYPE_AP_VLAN ||
vif->type == NL80211_IFTYPE_STATION) && ab->nss.enabled) {
if (ath11k_frame_mode == ATH11K_HW_TXRX_ETHERNET &&
- ieee80211_set_hw_80211_encap(vif, true)) {
+ (vif->offload_flags & IEEE80211_OFFLOAD_ENCAP_ENABLED)) {
vif->offload_flags |= IEEE80211_OFFLOAD_ENCAP_4ADDR;
arvif->nss.encap = ATH11K_HW_TXRX_ETHERNET;
arvif->nss.decap = ATH11K_HW_TXRX_ETHERNET;
@@ -6805,6 +6979,7 @@ static int ath11k_mac_op_add_interface(s
vif->addr, ret);
goto err;
}
+ INIT_LIST_HEAD(&arvif->dyn_vlan_cfg);
mutex_unlock(&ar->conf_mutex);
return ret;
}
@@ -6829,6 +7004,20 @@ static int ath11k_mac_op_add_interface(s
arvif->vdev_id = bit;
arvif->vdev_subtype = WMI_VDEV_SUBTYPE_NONE;
+ spin_lock_bh(&ar->data_lock);
+ /* Configure vlan specific parameters */
+ for (i = 0; i < ATH11K_FREE_GROUP_IDX_MAP_MAX; i++)
+ arvif->free_groupidx_map[i] = 0xFFFFFFFFL;
+ /* Group idx 0 is not valid for VLAN*/
+ arvif->free_groupidx_map[0] &= ~(1L);
+ spin_unlock_bh(&ar->data_lock);
+
+ arvif->vlan_keyid_map = kzalloc(4096, GFP_KERNEL);
+ if (!arvif->vlan_keyid_map) {
+ ret = -ENOMEM;
+ goto err;
+ }
+
switch (vif->type) {
case NL80211_IFTYPE_UNSPECIFIED:
case NL80211_IFTYPE_STATION:
@@ -6869,7 +7058,7 @@ static int ath11k_mac_op_add_interface(s
if (ret) {
ath11k_warn(ab, "failed to create WMI vdev %d: %d\n",
arvif->vdev_id, ret);
- goto err;
+ goto err_keyid;
}
ar->num_created_vdevs++;
@@ -7034,7 +7223,7 @@ err_peer_del:
if (fbret) {
ath11k_warn(ar->ab, "fallback fail to delete peer addr %pM vdev_id %d ret %d\n",
vif->addr, arvif->vdev_id, fbret);
- goto err;
+ goto err_keyid;
}
}
@@ -7045,6 +7234,8 @@ err_vdev_del:
list_del(&arvif->list);
spin_unlock_bh(&ar->data_lock);
+err_keyid:
+ kfree(arvif->vlan_keyid_map);
err:
mutex_unlock(&ar->conf_mutex);
@@ -7142,6 +7333,7 @@ err_vdev_del:
list_del(&arvif->list);
spin_unlock_bh(&ar->data_lock);
+ kfree(arvif->vlan_keyid_map);
ath11k_peer_cleanup(ar, arvif->vdev_id);
idr_for_each(&ar->txmgmt_idr,
@@ -9835,6 +10027,33 @@ static int ath11k_mac_station_remove(str
return ret;
}
+static int ath11k_mac_cfg_dyn_vlan(struct ath11k_base *ab,
@ -388,7 +461,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
static int ath11k_mac_op_sta_state(struct ieee80211_hw *hw,
struct ieee80211_vif *vif,
struct ieee80211_sta *sta,
@@ -5295,6 +5496,34 @@ static int ath11k_mac_op_sta_state(struc
@@ -9924,6 +10143,34 @@ static int ath11k_mac_op_sta_state(struc
if (ret)
ath11k_warn(ar->ab, "Unable to authorize peer %pM vdev %d: %d\n",
sta->addr, arvif->vdev_id, ret);
@ -421,82 +494,9 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
+ sta->addr, ret);
+ }
}
} else if (old_state == IEEE80211_STA_AUTHORIZED &&
new_state == IEEE80211_STA_ASSOC) {
@@ -7013,7 +7242,7 @@ static int ath11k_mac_op_add_interface(s
if ((vif->type == NL80211_IFTYPE_AP_VLAN ||
vif->type == NL80211_IFTYPE_STATION) && ab->nss.enabled) {
if (ath11k_frame_mode == ATH11K_HW_TXRX_ETHERNET &&
- ieee80211_set_hw_80211_encap(vif, true)) {
+ (vif->offload_flags & IEEE80211_OFFLOAD_ENCAP_ENABLED)) {
vif->offload_flags |= IEEE80211_OFFLOAD_ENCAP_4ADDR;
arvif->nss.encap = ATH11K_HW_TXRX_ETHERNET;
arvif->nss.decap = ATH11K_HW_TXRX_ETHERNET;
@@ -7026,6 +7255,7 @@ static int ath11k_mac_op_add_interface(s
vif->addr, ret);
goto err;
}
+ INIT_LIST_HEAD(&arvif->dyn_vlan_cfg);
mutex_unlock(&ar->conf_mutex);
return ret;
}
@@ -7050,6 +7280,20 @@ static int ath11k_mac_op_add_interface(s
arvif->vdev_id = bit;
arvif->vdev_subtype = WMI_VDEV_SUBTYPE_NONE;
+ spin_lock_bh(&ar->data_lock);
+ /* Configure vlan specific parameters */
+ for (i = 0; i < ATH11K_FREE_GROUP_IDX_MAP_MAX; i++)
+ arvif->free_groupidx_map[i] = 0xFFFFFFFFL;
+ /* Group idx 0 is not valid for VLAN*/
+ arvif->free_groupidx_map[0] &= ~(1L);
+ spin_unlock_bh(&ar->data_lock);
+
+ arvif->vlan_keyid_map = kzalloc(4096, GFP_KERNEL);
+ if (!arvif->vlan_keyid_map) {
+ ret = -ENOMEM;
+ goto err;
+ }
+
switch (vif->type) {
case NL80211_IFTYPE_UNSPECIFIED:
case NL80211_IFTYPE_STATION:
@@ -7090,7 +7334,7 @@ static int ath11k_mac_op_add_interface(s
if (ret) {
ath11k_warn(ab, "failed to create WMI vdev %d: %d\n",
arvif->vdev_id, ret);
- goto err;
+ goto err_keyid;
}
ar->num_created_vdevs++;
@@ -7249,7 +7493,7 @@ err_peer_del:
if (fbret) {
ath11k_warn(ar->ab, "fallback fail to delete peer addr %pM vdev_id %d ret %d\n",
vif->addr, arvif->vdev_id, fbret);
- goto err;
+ goto err_keyid;
}
}
@@ -7260,6 +7504,8 @@ err_vdev_del:
list_del(&arvif->list);
spin_unlock_bh(&ar->data_lock);
+err_keyid:
+ kfree(arvif->vlan_keyid_map);
err:
mutex_unlock(&ar->conf_mutex);
@@ -7357,6 +7603,7 @@ err_vdev_del:
list_del(&arvif->list);
spin_unlock_bh(&ar->data_lock);
+ kfree(arvif->vlan_keyid_map);
ath11k_peer_cleanup(ar, arvif->vdev_id);
idr_for_each(&ar->txmgmt_idr,
@@ -9956,8 +10203,11 @@ static int __ath11k_mac_register(struct
if (!ret &&
@@ -10535,8 +10782,11 @@ static int __ath11k_mac_register(struct
ab->hw_params.bios_sar_capa)
ar->hw->wiphy->sar_capa = ab->hw_params.bios_sar_capa;
@ -519,7 +519,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
if (arg->key_rsc_counter)
memcpy(&cmd->key_rsc_counter, &arg->key_rsc_counter,
@@ -4213,6 +4214,7 @@ ath11k_wmi_copy_resource_config(struct w
@@ -4276,6 +4277,7 @@ ath11k_wmi_copy_resource_config(struct w
wmi_cfg->flags2 = WMI_RSRC_CFG_FLAG2_CALC_NEXT_DTIM_COUNT_SET;
wmi_cfg->ema_max_vap_cnt = tg_cfg->ema_max_vap_cnt;
wmi_cfg->ema_max_profile_period = tg_cfg->ema_max_profile_period;
@ -527,7 +527,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
}
static int ath11k_init_cmd_send(struct ath11k_pdev_wmi *wmi,
@@ -4435,6 +4437,9 @@ int ath11k_wmi_cmd_init(struct ath11k_ba
@@ -4498,6 +4500,9 @@ int ath11k_wmi_cmd_init(struct ath11k_ba
memset(&init_param, 0, sizeof(init_param));
memset(&config, 0, sizeof(config));
@ -539,7 +539,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
if (test_bit(WMI_TLV_SERVICE_REG_CC_EXT_EVENT_SUPPORT,
--- a/drivers/net/wireless/ath/ath11k/wmi.h
+++ b/drivers/net/wireless/ath/ath11k/wmi.h
@@ -3703,6 +3703,7 @@ struct wmi_vdev_install_key_arg {
@@ -3749,6 +3749,7 @@ struct wmi_vdev_install_key_arg {
u32 vdev_id;
const u8 *macaddr;
u32 key_idx;
@ -547,7 +547,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
u32 key_flags;
u32 key_cipher;
u32 key_len;
@@ -5786,6 +5787,7 @@ struct target_resource_config {
@@ -5809,6 +5810,7 @@ struct target_resource_config {
u32 bpf_instruction_size;
u32 max_bssid_rx_filters;
u32 use_pdev_id;

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -1076,6 +1076,7 @@ struct ath11k_base {
@@ -1126,6 +1126,7 @@ struct ath11k_base {
u32 max_ast_index;
u32 num_ast_entries;
@ -10,7 +10,7 @@
};
--- a/drivers/net/wireless/ath/ath11k/debugfs.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs.c
@@ -973,6 +973,79 @@ static const struct file_operations fops
@@ -974,6 +974,79 @@ static const struct file_operations fops
.llseek = default_llseek,
};
@ -90,7 +90,7 @@
int ath11k_debugfs_pdev_create(struct ath11k_base *ab)
{
if (test_bit(ATH11K_FLAG_REGISTERED, &ab->dev_flags))
@@ -1022,6 +1095,8 @@ int ath11k_debugfs_soc_create(struct ath
@@ -1023,6 +1096,8 @@ int ath11k_debugfs_soc_create(struct ath
ret = PTR_ERR(ab->debugfs_soc);
goto out;
}

View File

@ -54,7 +54,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
tx_ring->tx_status_head =
--- a/drivers/net/wireless/ath/ath11k/hal.c
+++ b/drivers/net/wireless/ath/ath11k/hal.c
@@ -653,7 +653,8 @@ u32 *ath11k_hal_srng_dst_get_next_entry(
@@ -668,7 +668,8 @@ u32 *ath11k_hal_srng_dst_get_next_entry(
desc = srng->ring_base_vaddr + srng->u.dst_ring.tp;
@ -64,7 +64,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
/* wrap around to start of ring*/
if (srng->u.dst_ring.tp == srng->ring_size)
@@ -666,8 +667,63 @@ u32 *ath11k_hal_srng_dst_get_next_entry(
@@ -681,8 +682,63 @@ u32 *ath11k_hal_srng_dst_get_next_entry(
return desc;
}
@ -131,7 +131,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/hal.h
+++ b/drivers/net/wireless/ath/ath11k/hal.h
@@ -945,8 +945,12 @@ void ath11k_hal_srng_get_params(struct a
@@ -946,8 +946,12 @@ void ath11k_hal_srng_get_params(struct a
u32 *ath11k_hal_srng_dst_get_next_entry(struct ath11k_base *ab,
struct hal_srng *srng);
u32 *ath11k_hal_srng_dst_peek(struct ath11k_base *ab, struct hal_srng *srng);

View File

@ -23,7 +23,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -143,6 +143,7 @@ struct ath11k_skb_rxcb {
@@ -146,6 +146,7 @@ struct ath11k_skb_rxcb {
u8 tid;
u16 peer_id;
u16 seq_no;
@ -33,7 +33,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
enum ath11k_hw_rev {
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -340,6 +340,12 @@ static int ath11k_dp_purge_mon_ring(stru
@@ -341,6 +341,12 @@ static int ath11k_dp_purge_mon_ring(stru
return -ETIMEDOUT;
}
@ -46,7 +46,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
/* Returns number of Rx buffers replenished */
int ath11k_dp_rxbufs_replenish(struct ath11k_base *ab, int mac_id,
struct dp_rxdma_ring *rx_ring,
@@ -1664,7 +1670,7 @@ int ath11k_dp_htt_tlv_iter(struct ath11k
@@ -1665,7 +1671,7 @@ int ath11k_dp_htt_tlv_iter(struct ath11k
len -= sizeof(*tlv);
if (tlv_len > len) {
@ -55,7 +55,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
tlv_tag, ptr - begin, len, tlv_len);
return -EINVAL;
}
@@ -2454,10 +2460,60 @@ ath11k_dp_rx_h_find_peer(struct ath11k_b
@@ -2455,10 +2461,60 @@ ath11k_dp_rx_h_find_peer(struct ath11k_b
return peer;
}
@ -117,7 +117,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
{
bool fill_crypto_hdr;
enum hal_encrypt_type enctype;
@@ -2468,9 +2524,13 @@ static void ath11k_dp_rx_h_mpdu(struct a
@@ -2469,9 +2525,13 @@ static void ath11k_dp_rx_h_mpdu(struct a
struct rx_attention *rx_attention;
u32 err_bitmap;
@ -132,7 +132,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
rxcb->is_mcbc = fill_crypto_hdr;
if (rxcb->is_mcbc) {
@@ -2481,6 +2541,26 @@ static void ath11k_dp_rx_h_mpdu(struct a
@@ -2482,6 +2542,26 @@ static void ath11k_dp_rx_h_mpdu(struct a
spin_lock_bh(&ar->ab->base_lock);
peer = ath11k_dp_rx_h_find_peer(ar->ab, msdu);
if (peer) {
@ -159,7 +159,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
if (rxcb->is_mcbc)
enctype = peer->sec_type_grp;
else
@@ -2490,6 +2570,8 @@ static void ath11k_dp_rx_h_mpdu(struct a
@@ -2491,6 +2571,8 @@ static void ath11k_dp_rx_h_mpdu(struct a
}
spin_unlock_bh(&ar->ab->base_lock);
@ -168,7 +168,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
rx_attention = ath11k_dp_rx_get_attention(ar->ab, rx_desc);
err_bitmap = ath11k_dp_rx_h_attn_mpdu_err(rx_attention);
if (enctype != HAL_ENCRYPT_TYPE_OPEN && !err_bitmap)
@@ -2731,7 +2813,8 @@ static void ath11k_dp_rx_deliver_msdu(st
@@ -2732,7 +2814,8 @@ static void ath11k_dp_rx_deliver_msdu(st
static int ath11k_dp_rx_process_msdu(struct ath11k *ar,
struct sk_buff *msdu,
struct sk_buff_head *msdu_list,
@ -178,7 +178,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
{
struct ath11k_base *ab = ar->ab;
struct hal_rx_desc *rx_desc, *lrx_desc;
@@ -2798,8 +2881,13 @@ static int ath11k_dp_rx_process_msdu(str
@@ -2799,8 +2882,13 @@ static int ath11k_dp_rx_process_msdu(str
}
}
@ -193,7 +193,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
rx_status->flag |= RX_FLAG_SKIP_MONITOR | RX_FLAG_DUP_VALIDATED;
@@ -2814,10 +2902,12 @@ static void ath11k_dp_rx_process_receive
@@ -2815,10 +2903,12 @@ static void ath11k_dp_rx_process_receive
struct sk_buff_head *msdu_list,
int mac_id)
{
@ -206,7 +206,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
if (skb_queue_empty(msdu_list))
return;
@@ -2834,7 +2924,12 @@ static void ath11k_dp_rx_process_receive
@@ -2835,7 +2925,12 @@ static void ath11k_dp_rx_process_receive
}
while ((msdu = __skb_dequeue(msdu_list))) {
@ -220,7 +220,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
if (unlikely(ret)) {
ath11k_dbg(ab, ATH11K_DBG_DATA,
"Unable to process msdu %d", ret);
@@ -2842,7 +2937,10 @@ static void ath11k_dp_rx_process_receive
@@ -2843,7 +2938,10 @@ static void ath11k_dp_rx_process_receive
continue;
}
@ -232,7 +232,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
}
}
@@ -2851,11 +2949,12 @@ void ath11k_dp_rx_from_nss(struct ath11k
@@ -2852,11 +2950,12 @@ void ath11k_dp_rx_from_nss(struct ath11k
{
struct ieee80211_rx_status rx_status = {0};
struct ath11k_skb_rxcb *rxcb;
@ -246,7 +246,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
rx_status.flag |= RX_FLAG_SKIP_MONITOR | RX_FLAG_DUP_VALIDATED;
@@ -4322,6 +4421,7 @@ static int ath11k_dp_rx_h_null_q_desc(st
@@ -4324,6 +4423,7 @@ static int ath11k_dp_rx_h_null_q_desc(st
struct ieee80211_rx_status *status,
struct sk_buff_head *msdu_list)
{
@ -254,7 +254,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
u16 msdu_len;
struct hal_rx_desc *desc = (struct hal_rx_desc *)msdu->data;
struct rx_attention *rx_attention;
@@ -4371,7 +4471,8 @@ static int ath11k_dp_rx_h_null_q_desc(st
@@ -4373,7 +4473,8 @@ static int ath11k_dp_rx_h_null_q_desc(st
}
ath11k_dp_rx_h_ppdu(ar, desc, status);
@ -318,7 +318,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
.rx_desc_get_mpdu_fc_valid = ath11k_hw_qcn9074_rx_desc_get_mpdu_fc_valid,
--- a/drivers/net/wireless/ath/ath11k/hw.h
+++ b/drivers/net/wireless/ath/ath11k/hw.h
@@ -260,6 +260,7 @@ struct ath11k_hw_ops {
@@ -261,6 +261,7 @@ struct ath11k_hw_ops {
u32 (*rx_desc_get_encrypt_type)(struct hal_rx_desc *desc);
u8 (*rx_desc_get_decap_type)(struct hal_rx_desc *desc);
u8 (*rx_desc_get_mesh_ctl)(struct hal_rx_desc *desc);
@ -328,7 +328,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
bool (*rx_desc_get_mpdu_fc_valid)(struct hal_rx_desc *desc);
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -5527,6 +5527,14 @@ static int ath11k_mac_op_sta_state(struc
@@ -10197,6 +10197,14 @@ static int ath11k_mac_op_sta_state(struc
}
} else if (old_state == IEEE80211_STA_AUTHORIZED &&
new_state == IEEE80211_STA_ASSOC) {

View File

@ -26,7 +26,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -115,6 +115,7 @@ static inline enum wme_ac ath11k_tid_to_
@@ -118,6 +118,7 @@ static inline enum wme_ac ath11k_tid_to_
enum ath11k_skb_flags {
ATH11K_SKB_HW_80211_ENCAP = BIT(0),
ATH11K_SKB_CIPHER_SET = BIT(1),
@ -34,7 +34,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
};
struct ath11k_skb_cb {
@@ -883,10 +884,13 @@ struct ath11k_dp_ring_bp_stats {
@@ -921,10 +922,13 @@ struct ath11k_dp_ring_bp_stats {
struct ath11k_soc_dp_tx_err_stats {
/* TCL Ring Descriptor unavailable */
u32 desc_na[DP_TCL_NUM_RING_MAX];
@ -50,7 +50,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
};
--- a/drivers/net/wireless/ath/ath11k/dp.c
+++ b/drivers/net/wireless/ath/ath11k/dp.c
@@ -358,7 +358,7 @@ void ath11k_dp_stop_shadow_timers(struct
@@ -372,7 +372,7 @@ void ath11k_dp_stop_shadow_timers(struct
if (!ab->hw_params.supports_shadow_regs)
return;
@ -59,7 +59,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
ath11k_dp_shadow_stop_timer(ab, &ab->dp.tx_ring_timer[i]);
ath11k_dp_shadow_stop_timer(ab, &ab->dp.reo_cmd_timer);
@@ -373,7 +373,7 @@ static void ath11k_dp_srng_common_cleanu
@@ -387,7 +387,7 @@ static void ath11k_dp_srng_common_cleanu
ath11k_dp_srng_cleanup(ab, &dp->wbm_desc_rel_ring);
ath11k_dp_srng_cleanup(ab, &dp->tcl_cmd_ring);
ath11k_dp_srng_cleanup(ab, &dp->tcl_status_ring);
@ -68,7 +68,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
ath11k_dp_srng_cleanup(ab, &dp->tx_ring[i].tcl_data_ring);
ath11k_dp_srng_cleanup(ab, &dp->tx_ring[i].tcl_comp_ring);
}
@@ -407,6 +407,11 @@ static int ath11k_dp_srng_common_setup(s
@@ -421,6 +421,11 @@ static int ath11k_dp_srng_common_setup(s
goto err;
}
@ -80,7 +80,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
ret = ath11k_dp_srng_setup(ab, &dp->tcl_status_ring, HAL_TCL_STATUS,
0, 0, DP_TCL_STATUS_RING_SIZE);
if (ret) {
@@ -414,7 +419,7 @@ static int ath11k_dp_srng_common_setup(s
@@ -428,7 +433,7 @@ static int ath11k_dp_srng_common_setup(s
goto err;
}
@ -89,7 +89,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
tcl_num = ab->hw_params.hal_params->tcl2wbm_rbm_map[i].tcl_ring_num;
wbm_num = ab->hw_params.hal_params->tcl2wbm_rbm_map[i].wbm_ring_num;
@@ -437,7 +442,7 @@ static int ath11k_dp_srng_common_setup(s
@@ -451,7 +456,7 @@ static int ath11k_dp_srng_common_setup(s
}
srng = &ab->hal.srng_list[dp->tx_ring[i].tcl_data_ring.ring_id];
@ -98,7 +98,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
ath11k_dp_shadow_init_timer(ab, &dp->tx_ring_timer[i],
ATH11K_SHADOW_DP_TIMER_INTERVAL,
@@ -1051,7 +1056,7 @@ void ath11k_dp_free(struct ath11k_base *
@@ -1065,7 +1070,7 @@ void ath11k_dp_free(struct ath11k_base *
ath11k_dp_reo_cmd_list_cleanup(ab);
@ -107,7 +107,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
spin_lock_bh(&dp->tx_ring[i].tx_idr_lock);
idr_for_each(&dp->tx_ring[i].txbuf_idr,
ath11k_dp_tx_pending_cleanup, ab);
@@ -1102,7 +1107,7 @@ int ath11k_dp_alloc(struct ath11k_base *
@@ -1116,7 +1121,7 @@ int ath11k_dp_alloc(struct ath11k_base *
size = sizeof(struct hal_wbm_release_ring) * DP_TX_COMP_RING_SIZE;
@ -130,7 +130,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
if (unlikely(!(info->flags & IEEE80211_TX_CTL_HW_80211_ENCAP) &&
!ieee80211_is_data(hdr->frame_control)))
return -ENOTSUPP;
return -EOPNOTSUPP;
- pool_id = skb_get_queue_mapping(skb) & (ATH11K_HW_MAX_QUEUES - 1);
+ max_tx_ring = ab->hw_params.max_tx_ring;
@ -430,7 +430,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -6664,12 +6664,22 @@ static void ath11k_mac_op_tx(struct ieee
@@ -6387,12 +6387,22 @@ static void ath11k_mac_op_tx(struct ieee
if (control->sta)
arsta = ath11k_sta_to_arsta(control->sta);
@ -438,7 +438,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
+ * the skb from driver. Own tx packets on monitor will also be disabled.
+ */
+ if ((info->flags & (IEEE80211_TX_CTL_REQ_TX_STATUS | IEEE80211_TX_INTFL_NL80211_FRAME_TX)) ||
+ info->ack_frame_id || vif->type == NL80211_IFTYPE_MESH_POINT ||
+ info->status_data || vif->type == NL80211_IFTYPE_MESH_POINT ||
+ test_bit(ATH11K_FLAG_MONITOR_VDEV_CREATED, &ar->monitor_flags))
+ skb_cb->flags |= ATH11K_SKB_TX_STATUS;
+
@ -454,7 +454,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
ieee80211_free_txskb(ar->hw, skb);
return;
}
@@ -7617,7 +7627,7 @@ err_vdev_del:
@@ -7339,7 +7349,7 @@ err_vdev_del:
idr_for_each(&ar->txmgmt_idr,
ath11k_mac_vif_txmgmt_idr_remove, vif);
@ -465,7 +465,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
ath11k_mac_vif_unref, vif);
--- a/drivers/net/wireless/ath/ath11k/debugfs.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs.c
@@ -832,10 +832,22 @@ static ssize_t ath11k_debugfs_dump_soc_d
@@ -833,10 +833,22 @@ static ssize_t ath11k_debugfs_dump_soc_d
len += scnprintf(buf + len, size - len, "ring%d: %u\n",
i, soc_stats->tx_err.desc_na[i]);
@ -490,7 +490,7 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
if (len > size)
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -188,7 +188,6 @@ static struct ath11k_hw_params ath11k_hw
@@ -190,7 +190,6 @@ static struct ath11k_hw_params ath11k_hw
.supports_regdb = false,
.fix_l1ss = true,
.credit_flow = false,
@ -498,16 +498,16 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
.hal_params = &ath11k_hw_hal_params_ipq8074,
.supports_dynamic_smps_6ghz = false,
.alloc_cacheable_memory = true,
@@ -213,6 +212,8 @@ static struct ath11k_hw_params ath11k_hw
.tx_ring_size = DP_TCL_DATA_RING_SIZE,
@@ -216,6 +215,8 @@ static struct ath11k_hw_params ath11k_hw
.smp2p_wow_exit = false,
.support_fw_mac_sequence = false,
.support_dual_stations = false,
+ /* In addition to TCL ring use TCL_CMD ring also for tx */
+ .max_tx_ring = DP_TCL_NUM_RING_MAX + 1,
},
{
.name = "qca6390 hw2.0",
@@ -355,7 +356,6 @@ static struct ath11k_hw_params ath11k_hw
@@ -359,7 +360,6 @@ static struct ath11k_hw_params ath11k_hw
.supports_regdb = false,
.fix_l1ss = true,
.credit_flow = false,
@ -515,16 +515,16 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
.hal_params = &ath11k_hw_hal_params_ipq8074,
.supports_dynamic_smps_6ghz = true,
.alloc_cacheable_memory = true,
@@ -380,6 +380,8 @@ static struct ath11k_hw_params ath11k_hw
.tx_ring_size = DP_TCL_DATA_RING_SIZE,
@@ -385,6 +385,8 @@ static struct ath11k_hw_params ath11k_hw
.smp2p_wow_exit = false,
.support_fw_mac_sequence = false,
.support_dual_stations = false,
+ /* In addition to TCL ring use TCL_CMD ring also for tx */
+ .max_tx_ring = DP_TCL_NUM_RING_MAX + 1,
},
{
.name = "wcn6855 hw2.0",
@@ -2143,6 +2145,9 @@ int ath11k_core_pre_init(struct ath11k_b
@@ -2247,6 +2249,9 @@ int ath11k_core_pre_init(struct ath11k_b
if (nss_offload)
ab->nss.stats_enabled = 1;

View File

@ -36,7 +36,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/Makefile
+++ b/drivers/net/wireless/ath/ath11k/Makefile
@@ -27,6 +27,10 @@ ath11k-$(CPTCFG_ATH11K_SPECTRAL) += spec
@@ -28,6 +28,10 @@ ath11k-$(CPTCFG_ATH11K_SPECTRAL) += spec
ath11k-$(CONFIG_PM) += wow.o
ath11k-$(CPTCFG_ATH11K_NSS_SUPPORT) += nss.o
@ -1046,7 +1046,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
#define HTT_PPDU_STATS_MAX_USERS 37
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -1409,6 +1409,71 @@ static int ath11k_htt_tlv_ppdu_stats_par
@@ -1410,6 +1410,71 @@ static int ath11k_htt_tlv_ppdu_stats_par
return 0;
}
@ -1118,7 +1118,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
static void
ath11k_update_per_peer_tx_stats(struct ath11k *ar,
struct htt_ppdu_stats *ppdu_stats, u8 user)
@@ -1432,6 +1497,9 @@ ath11k_update_per_peer_tx_stats(struct a
@@ -1433,6 +1498,9 @@ ath11k_update_per_peer_tx_stats(struct a
if (!(usr_stats->tlv_flags & BIT(HTT_PPDU_STATS_TAG_USR_RATE)))
return;
@ -1128,7 +1128,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
if (usr_stats->tlv_flags & BIT(HTT_PPDU_STATS_TAG_USR_COMPLTN_COMMON))
is_ampdu =
HTT_USR_CMPLTN_IS_AMPDU(usr_stats->cmpltn_cmn.flags);
@@ -1565,6 +1633,8 @@ ath11k_update_per_peer_tx_stats(struct a
@@ -1566,6 +1634,8 @@ ath11k_update_per_peer_tx_stats(struct a
ath11k_debugfs_sta_add_tx_stats(arsta, peer_stats, rate_idx);
}
@ -1137,7 +1137,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
spin_unlock_bh(&ab->base_lock);
rcu_read_unlock();
}
@@ -1685,6 +1755,69 @@ int ath11k_dp_htt_tlv_iter(struct ath11k
@@ -1686,6 +1756,69 @@ int ath11k_dp_htt_tlv_iter(struct ath11k
return 0;
}
@ -1207,7 +1207,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
static int ath11k_htt_pull_ppdu_stats(struct ath11k_base *ab,
struct sk_buff *skb)
{
@@ -1703,6 +1836,15 @@ static int ath11k_htt_pull_ppdu_stats(st
@@ -1704,6 +1837,15 @@ static int ath11k_htt_pull_ppdu_stats(st
pdev_id = FIELD_GET(HTT_T2H_PPDU_STATS_INFO_PDEV_ID, msg->info);
ppdu_id = msg->ppdu_id;
@ -1223,7 +1223,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
rcu_read_lock();
ar = ath11k_mac_get_ar_by_pdev_id(ab, pdev_id);
if (!ar) {
@@ -1770,6 +1912,12 @@ static int ath11k_htt_pull_ppdu_stats(st
@@ -1771,6 +1913,12 @@ static int ath11k_htt_pull_ppdu_stats(st
}
}
@ -1238,7 +1238,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -3469,6 +3469,18 @@ static void ath11k_mac_op_nss_bss_info_c
@@ -3476,6 +3476,18 @@ static void ath11k_mac_op_nss_bss_info_c
ath11k_warn(ar->ab, "failed to set ap_isolate in nss %d\n", ret);
}
@ -1257,8 +1257,8 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
mutex_unlock(&ar->conf_mutex);
}
@@ -9707,6 +9719,28 @@ err_fallback:
return 0;
@@ -10237,6 +10249,28 @@ static int ath11k_mac_op_sta_state(struc
return ret;
}
+#ifdef CPTCFG_ATH11K_NSS_MESH_SUPPORT
@ -1286,7 +1286,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
static const struct ieee80211_ops ath11k_ops = {
.tx = ath11k_mac_op_tx,
.wake_tx_queue = ieee80211_handle_wake_tx_queue,
@@ -9764,6 +9798,9 @@ static const struct ieee80211_ops ath11k
@@ -10295,6 +10329,9 @@ static const struct ieee80211_ops ath11k
.set_sar_specs = ath11k_mac_op_set_bios_sar_specs,
.remain_on_channel = ath11k_mac_op_remain_on_channel,
.cancel_remain_on_channel = ath11k_mac_op_cancel_remain_on_channel,
@ -1296,7 +1296,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
};
static void ath11k_mac_update_ch_list(struct ath11k *ar,
@@ -10225,6 +10262,8 @@ static int __ath11k_mac_register(struct
@@ -10804,6 +10841,8 @@ static int __ath11k_mac_register(struct
ieee80211_hw_set(ar->hw, SUPPORTS_NSS_OFFLOAD);
wiphy_ext_feature_set(ar->hw->wiphy,
NL80211_EXT_FEATURE_VLAN_OFFLOAD);
@ -3337,7 +3337,7 @@ Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@codeaurora.org>
ATH11K_DBG_WMI = 0x00000002,
--- a/local-symbols
+++ b/local-symbols
@@ -171,6 +171,7 @@ ATH11K=
@@ -164,6 +164,7 @@ ATH11K=
ATH11K_AHB=
ATH11K_PCI=
ATH11K_NSS_SUPPORT=

View File

@ -23,7 +23,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -7636,8 +7636,10 @@ err_vdev_del:
@@ -7358,8 +7358,10 @@ err_vdev_del:
kfree(arvif->vlan_keyid_map);
ath11k_peer_cleanup(ar, arvif->vdev_id);
@ -36,7 +36,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
spin_lock_bh(&ab->dp.tx_ring[i].tx_idr_lock);
--- a/drivers/net/wireless/ath/ath11k/wmi.c
+++ b/drivers/net/wireless/ath/ath11k/wmi.c
@@ -5966,13 +5966,13 @@ static int wmi_process_tx_comp(struct at
@@ -6039,13 +6039,13 @@ static int wmi_process_tx_comp(struct at
struct ieee80211_tx_info *info;
struct ath11k_skb_cb *skb_cb;
struct ieee80211_hdr *hdr;
@ -51,7 +51,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
spin_lock_bh(&ar->txmgmt_idr_lock);
msdu = idr_find(&ar->txmgmt_idr, tx_compl_param->desc_id);
@@ -5980,6 +5980,7 @@ static int wmi_process_tx_comp(struct at
@@ -6053,6 +6053,7 @@ static int wmi_process_tx_comp(struct at
ath11k_warn(ar->ab, "received mgmt tx compl for invalid msdu_id: %d\n",
tx_compl_param->desc_id);
spin_unlock_bh(&ar->txmgmt_idr_lock);
@ -59,7 +59,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
return -ENOENT;
}
@@ -5988,6 +5989,28 @@ static int wmi_process_tx_comp(struct at
@@ -6061,6 +6062,28 @@ static int wmi_process_tx_comp(struct at
skb_cb = ATH11K_SKB_CB(msdu);
dma_unmap_single(ar->ab->dev, skb_cb->paddr, msdu->len, DMA_TO_DEVICE);
@ -88,7 +88,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
info = IEEE80211_SKB_CB(msdu);
if ((!(info->flags & IEEE80211_TX_CTL_NO_ACK)) &&
@@ -6003,34 +6026,6 @@ static int wmi_process_tx_comp(struct at
@@ -6076,34 +6099,6 @@ static int wmi_process_tx_comp(struct at
*/
info->status.rates[0].idx = -1;

View File

@ -46,7 +46,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/ahb.c
+++ b/drivers/net/wireless/ath/ath11k/ahb.c
@@ -1245,6 +1245,7 @@ static void ath11k_ahb_remove_prepare(st
@@ -1239,6 +1239,7 @@ static void ath11k_ahb_remove_prepare(st
set_bit(ATH11K_FLAG_UNREGISTERING, &ab->dev_flags);
cancel_work_sync(&ab->restart_work);
cancel_work_sync(&ab->qmi.event_work);
@ -56,7 +56,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
static void ath11k_ahb_free_resources(struct ath11k_base *ab)
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -2211,6 +2211,7 @@ struct ath11k_base *ath11k_core_alloc(st
@@ -2316,6 +2316,7 @@ struct ath11k_base *ath11k_core_alloc(st
mutex_init(&ab->core_lock);
mutex_init(&ab->tbl_mtx_lock);
@ -64,7 +64,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
spin_lock_init(&ab->base_lock);
mutex_init(&ab->vdev_id_11d_lock);
init_completion(&ab->reset_complete);
@@ -2224,6 +2225,8 @@ struct ath11k_base *ath11k_core_alloc(st
@@ -2329,6 +2330,8 @@ struct ath11k_base *ath11k_core_alloc(st
INIT_WORK(&ab->restart_work, ath11k_core_restart);
INIT_WORK(&ab->update_11d_work, ath11k_update_11d);
INIT_WORK(&ab->reset_work, ath11k_core_reset);
@ -75,15 +75,15 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
init_completion(&ab->wow.wakeup_completed);
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -31,6 +31,7 @@
@@ -33,6 +33,7 @@
#include "wow.h"
#include "rx_desc.h"
#include "nss.h"
+#include "peer.h"
#include "fw.h"
#define SM(_v, _f) (((_v) << _f##_LSB) & _f##_MASK)
@@ -1080,6 +1081,9 @@ struct ath11k_base {
@@ -1130,6 +1131,9 @@ struct ath11k_base {
u32 max_ast_index;
u32 num_ast_entries;
@ -183,7 +183,7 @@ Signed-off-by: Rameshkumar Sundaram <ramess@codeaurora.org>
}
--- a/drivers/net/wireless/ath/ath11k/pci.c
+++ b/drivers/net/wireless/ath/ath11k/pci.c
@@ -972,6 +972,7 @@ static void ath11k_pci_remove(struct pci
@@ -1004,6 +1004,7 @@ static void ath11k_pci_remove(struct pci
}
set_bit(ATH11K_FLAG_UNREGISTERING, &ab->dev_flags);

View File

@ -18,7 +18,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dp.c
+++ b/drivers/net/wireless/ath/ath11k/dp.c
@@ -376,6 +376,8 @@ static void ath11k_dp_srng_common_cleanu
@@ -390,6 +390,8 @@ static void ath11k_dp_srng_common_cleanu
for (i = 0; i < DP_TCL_NUM_RING_MAX; i++) {
ath11k_dp_srng_cleanup(ab, &dp->tx_ring[i].tcl_data_ring);
ath11k_dp_srng_cleanup(ab, &dp->tx_ring[i].tcl_comp_ring);
@ -27,7 +27,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
}
ath11k_dp_srng_cleanup(ab, &dp->reo_reinject_ring);
ath11k_dp_srng_cleanup(ab, &dp->rx_rel_ring);
@@ -388,7 +390,7 @@ static int ath11k_dp_srng_common_setup(s
@@ -402,7 +404,7 @@ static int ath11k_dp_srng_common_setup(s
{
struct ath11k_dp *dp = &ab->dp;
struct hal_srng *srng;
@ -36,7 +36,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
u8 tcl_num, wbm_num;
ret = ath11k_dp_srng_setup(ab, &dp->wbm_desc_rel_ring,
@@ -447,6 +449,18 @@ static int ath11k_dp_srng_common_setup(s
@@ -461,6 +463,18 @@ static int ath11k_dp_srng_common_setup(s
ath11k_dp_shadow_init_timer(ab, &dp->tx_ring_timer[i],
ATH11K_SHADOW_DP_TIMER_INTERVAL,
dp->tx_ring[i].tcl_data_ring.ring_id);
@ -55,7 +55,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
}
ret = ath11k_dp_srng_setup(ab, &dp->reo_reinject_ring, HAL_REO_REINJECT,
@@ -1031,9 +1045,8 @@ void ath11k_dp_vdev_tx_attach(struct ath
@@ -1045,9 +1059,8 @@ void ath11k_dp_vdev_tx_attach(struct ath
ath11k_dp_update_vdev_search(arvif);
}
@ -66,7 +66,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
struct sk_buff *msdu = skb;
dma_unmap_single(ab->dev, ATH11K_SKB_CB(msdu)->paddr, msdu->len,
@@ -1047,21 +1060,28 @@ static int ath11k_dp_tx_pending_cleanup(
@@ -1061,21 +1074,28 @@ static int ath11k_dp_tx_pending_cleanup(
void ath11k_dp_free(struct ath11k_base *ab)
{
struct ath11k_dp *dp = &ab->dp;

View File

@ -58,7 +58,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
tcl_cmd.info3 = FIELD_PREP(HAL_TCL_DATA_CMD_INFO3_DSCP_TID_TABLE_IDX,
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -10148,6 +10148,8 @@ static int __ath11k_mac_register(struct
@@ -10727,6 +10727,8 @@ static int __ath11k_mac_register(struct
ieee80211_hw_set(ar->hw, USES_RSS);
}

View File

@ -16,7 +16,7 @@ Signed-off-by: Anilkumar Kolli <quic_akolli@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -5953,12 +5953,23 @@ int ath11k_dp_rx_process_mon_status(stru
@@ -5955,12 +5955,23 @@ int ath11k_dp_rx_process_mon_status(stru
pmon->mon_ppdu_status = DP_PPDU_STATUS_START;
}
@ -43,7 +43,7 @@ Signed-off-by: Anilkumar Kolli <quic_akolli@quicinc.com>
rcu_read_lock();
spin_lock_bh(&ab->base_lock);
peer = ath11k_peer_find_by_id(ab, ppdu_info->peer_id);
@@ -6282,6 +6293,13 @@ static int ath11k_dp_full_mon_process_rx
@@ -6284,6 +6295,13 @@ static int ath11k_dp_full_mon_process_rx
spin_lock_bh(&pmon->mon_lock);
@ -57,7 +57,7 @@ Signed-off-by: Anilkumar Kolli <quic_akolli@quicinc.com>
sw_mon_entries = &pmon->sw_mon_entries;
rx_mon_stats = &pmon->rx_mon_stats;
@@ -6321,7 +6339,6 @@ static int ath11k_dp_full_mon_process_rx
@@ -6323,7 +6341,6 @@ static int ath11k_dp_full_mon_process_rx
}
rx_mon_stats->dest_ppdu_done++;
@ -65,7 +65,7 @@ Signed-off-by: Anilkumar Kolli <quic_akolli@quicinc.com>
pmon->buf_state = DP_MON_STATUS_LAG;
pmon->mon_status_paddr = sw_mon_entries->mon_status_paddr;
pmon->hold_mon_dst_ring = true;
@@ -6352,16 +6369,10 @@ reap_status_ring:
@@ -6354,16 +6371,10 @@ reap_status_ring:
int ath11k_dp_rx_process_mon_rings(struct ath11k_base *ab, int mac_id,
struct napi_struct *napi, int budget)
{

View File

@ -35,7 +35,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -3660,6 +3660,46 @@ ath11k_dp_rx_mon_update_status_buf_state
@@ -3662,6 +3662,46 @@ ath11k_dp_rx_mon_update_status_buf_state
}
}
@ -82,7 +82,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
static int ath11k_dp_rx_reap_mon_status_ring(struct ath11k_base *ab, int mac_id,
int *budget, struct sk_buff_head *skb_list)
{
@@ -3673,6 +3713,7 @@ static int ath11k_dp_rx_reap_mon_status_
@@ -3675,6 +3715,7 @@ static int ath11k_dp_rx_reap_mon_status_
struct sk_buff *skb;
struct ath11k_skb_rxcb *rxcb;
struct hal_tlv_hdr *tlv;
@ -90,7 +90,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
u32 cookie;
int buf_id, srng_id;
dma_addr_t paddr;
@@ -3692,8 +3733,7 @@ static int ath11k_dp_rx_reap_mon_status_
@@ -3694,8 +3735,7 @@ static int ath11k_dp_rx_reap_mon_status_
ath11k_hal_srng_access_begin(ab, srng);
while (*budget) {
*budget -= 1;
@ -100,7 +100,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
if (!rx_mon_status_desc) {
pmon->buf_state = DP_MON_STATUS_REPLINISH;
break;
@@ -3724,18 +3764,43 @@ static int ath11k_dp_rx_reap_mon_status_
@@ -3726,18 +3766,43 @@ static int ath11k_dp_rx_reap_mon_status_
tlv = (struct hal_tlv_hdr *)skb->data;
if (FIELD_GET(HAL_TLV_HDR_TAG, tlv->tl) !=
HAL_RX_STATUS_BUFFER_DONE) {
@ -157,7 +157,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
spin_lock_bh(&rx_ring->idr_lock);
--- a/drivers/net/wireless/ath/ath11k/hal.c
+++ b/drivers/net/wireless/ath/ath11k/hal.c
@@ -837,6 +837,20 @@ u32 *ath11k_hal_srng_src_get_next_reaped
@@ -852,6 +852,20 @@ u32 *ath11k_hal_srng_src_get_next_reaped
return desc;
}
@ -180,7 +180,7 @@ Signed-off-by: Venkateswara Naralasetty <quic_vnaralas@quicinc.com>
lockdep_assert_held(&srng->lock);
--- a/drivers/net/wireless/ath/ath11k/hal.h
+++ b/drivers/net/wireless/ath/ath11k/hal.h
@@ -952,6 +952,8 @@ int ath11k_hal_srng_dst_num_free(struct
@@ -953,6 +953,8 @@ int ath11k_hal_srng_dst_num_free(struct
void ath11k_hal_srng_dst_invalidate_entry(struct ath11k_base *ab,
struct hal_srng *srng, int entries);
u32 *ath11k_hal_srng_src_peek(struct ath11k_base *ab, struct hal_srng *srng);

View File

@ -38,7 +38,7 @@ Signed-off-by: Aditya Kumar Singh <quic_adisi@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -1837,6 +1837,11 @@ static int ath11k_core_reconfigure_on_cr
@@ -1932,6 +1932,11 @@ static int ath11k_core_reconfigure_on_cr
clear_bit(ATH11K_FLAG_CRASH_FLUSH, &ab->dev_flags);

View File

@ -17,7 +17,7 @@ Signed-off-by: Hari Chandrakanthan <quic_haric@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dbring.c
+++ b/drivers/net/wireless/ath/ath11k/dbring.c
@@ -80,6 +80,8 @@ static int ath11k_dbring_bufs_replenish(
@@ -81,6 +81,8 @@ static int ath11k_dbring_bufs_replenish(
buff->paddr = paddr;

View File

@ -46,7 +46,7 @@ Signed-off-by: Nagarajan Maran <quic_nmaran@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -396,8 +396,8 @@ int ath11k_dp_rxbufs_replenish(struct at
@@ -397,8 +397,8 @@ int ath11k_dp_rxbufs_replenish(struct at
goto fail_free_skb;
spin_lock_bh(&rx_ring->idr_lock);
@ -57,7 +57,7 @@ Signed-off-by: Nagarajan Maran <quic_nmaran@quicinc.com>
spin_unlock_bh(&rx_ring->idr_lock);
if (buf_id <= 0)
goto fail_dma_unmap;
@@ -3141,6 +3141,16 @@ try_again:
@@ -3142,6 +3142,16 @@ try_again:
while (likely(desc =
(struct hal_reo_dest_ring *)ath11k_hal_srng_dst_get_next_entry(ab,
srng))) {
@ -74,7 +74,7 @@ Signed-off-by: Nagarajan Maran <quic_nmaran@quicinc.com>
cookie = FIELD_GET(BUFFER_ADDR_INFO1_SW_COOKIE,
desc->buf_addr_info.info1);
buf_id = FIELD_GET(DP_RXDMA_BUF_COOKIE_BUF_ID,
@@ -3171,8 +3181,6 @@ try_again:
@@ -3172,8 +3182,6 @@ try_again:
num_buffs_reaped[mac_id]++;

View File

@ -17,7 +17,7 @@ Signed-off-by: Karthikeyan Kathirvel <quic_kathirve@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -4894,12 +4894,6 @@ static int ath11k_station_disassoc(struc
@@ -4902,12 +4902,6 @@ static int ath11k_station_disassoc(struc
return ret;
}
@ -30,7 +30,7 @@ Signed-off-by: Karthikeyan Kathirvel <quic_kathirve@quicinc.com>
return 0;
}
@@ -5490,6 +5484,17 @@ static int ath11k_mac_op_sta_state(struc
@@ -10149,6 +10143,17 @@ static int ath11k_mac_op_sta_state(struc
arsta->bw = ath11k_mac_ieee80211_sta_bw_to_wmi(ar, sta);
arsta->bw_prev = arsta->bw;
spin_unlock_bh(&ar->data_lock);

View File

@ -24,7 +24,7 @@ Signed-off-by: Ramya Gnanasekar <quic_rgnanase@quicinc.com>
u32 ppdu_id;
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -1288,7 +1288,7 @@ static int ath11k_htt_tlv_ppdu_stats_par
@@ -1289,7 +1289,7 @@ static int ath11k_htt_tlv_ppdu_stats_par
struct htt_ppdu_user_stats *user_stats = NULL;
int cur_user;
u16 peer_id;
@ -33,7 +33,7 @@ Signed-off-by: Ramya Gnanasekar <quic_rgnanase@quicinc.com>
ppdu_info = data;
@@ -1369,6 +1369,8 @@ static int ath11k_htt_tlv_ppdu_stats_par
@@ -1370,6 +1370,8 @@ static int ath11k_htt_tlv_ppdu_stats_par
return -EINVAL;
}
@ -42,7 +42,7 @@ Signed-off-by: Ramya Gnanasekar <quic_rgnanase@quicinc.com>
peer_id =
((struct htt_ppdu_stats_usr_cmpltn_ack_ba_status *)ptr)->sw_peer_id;
cur_user = ath11k_get_ppdu_user_index(&ppdu_info->ppdu_stats,
@@ -1380,6 +1382,7 @@ static int ath11k_htt_tlv_ppdu_stats_par
@@ -1381,6 +1383,7 @@ static int ath11k_htt_tlv_ppdu_stats_par
user_stats->is_valid_peer_id = true;
memcpy((void *)&user_stats->ack_ba, ptr,
sizeof(struct htt_ppdu_stats_usr_cmpltn_ack_ba_status));

View File

@ -41,7 +41,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -902,6 +902,9 @@ struct ath11k_soc_dp_stats {
@@ -940,6 +940,9 @@ struct ath11k_soc_dp_stats {
u32 rxdma_error[HAL_REO_ENTR_RING_RXDMA_ECODE_MAX];
u32 reo_error[HAL_REO_DEST_RING_ERROR_CODE_MAX];
u32 hal_reo_error[DP_REO_DST_RING_MAX];
@ -53,7 +53,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
};
--- a/drivers/net/wireless/ath/ath11k/debugfs.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs.c
@@ -848,6 +848,18 @@ static ssize_t ath11k_debugfs_dump_soc_d
@@ -849,6 +849,18 @@ static ssize_t ath11k_debugfs_dump_soc_d
"\nNSS Transmit Failures: %d\n",
atomic_read(&soc_stats->tx_err.nss_tx_fail));
@ -74,7 +74,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
if (len > size)
--- a/drivers/net/wireless/ath/ath11k/dp.c
+++ b/drivers/net/wireless/ath/ath11k/dp.c
@@ -1102,8 +1102,10 @@ int ath11k_dp_alloc(struct ath11k_base *
@@ -1116,8 +1116,10 @@ int ath11k_dp_alloc(struct ath11k_base *
INIT_LIST_HEAD(&dp->reo_cmd_list);
INIT_LIST_HEAD(&dp->reo_cmd_cache_flush_list);
@ -125,7 +125,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
};
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -21,6 +21,9 @@
@@ -22,6 +22,9 @@
#define ATH11K_DP_RX_FRAGMENT_TIMEOUT_MS (2 * HZ)
@ -135,7 +135,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
static inline
u8 *ath11k_dp_rx_h_80211_hdr(struct ath11k_base *ab, struct hal_rx_desc *desc)
{
@@ -672,13 +675,50 @@ static int ath11k_dp_rx_pdev_srng_alloc(
@@ -673,13 +676,50 @@ static int ath11k_dp_rx_pdev_srng_alloc(
return 0;
}
@ -186,7 +186,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
spin_lock_bh(&dp->reo_cmd_lock);
list_for_each_entry_safe(cmd, tmp, &dp->reo_cmd_list, list) {
list_del(&cmd->list);
@@ -724,14 +764,18 @@ static void ath11k_dp_reo_cmd_free(struc
@@ -725,14 +765,18 @@ static void ath11k_dp_reo_cmd_free(struc
}
}
@ -207,7 +207,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
desc_sz = ath11k_hal_reo_qdesc_size(0, HAL_DESC_REO_NON_QOS_TID);
while (tot_desc_sz > desc_sz) {
@@ -742,11 +786,17 @@ static void ath11k_dp_reo_cache_flush(st
@@ -743,11 +787,17 @@ static void ath11k_dp_reo_cache_flush(st
HAL_REO_CMD_FLUSH_CACHE, &cmd,
NULL);
if (ret)
@ -228,7 +228,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
memset(&cmd, 0, sizeof(cmd));
cmd.addr_lo = lower_32_bits(rx_tid->paddr);
cmd.addr_hi = upper_32_bits(rx_tid->paddr);
@@ -754,24 +804,21 @@ static void ath11k_dp_reo_cache_flush(st
@@ -755,24 +805,21 @@ static void ath11k_dp_reo_cache_flush(st
ret = ath11k_dp_tx_send_reo_cmd(ab, rx_tid,
HAL_REO_CMD_FLUSH_CACHE,
&cmd, ath11k_dp_reo_cmd_free);
@ -259,7 +259,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
goto free_desc;
} else if (status != HAL_REO_CMD_SUCCESS) {
/* Shouldn't happen! Cleanup in case of other failure? */
@@ -780,6 +827,29 @@ static void ath11k_dp_rx_tid_del_func(st
@@ -781,6 +828,29 @@ static void ath11k_dp_rx_tid_del_func(st
return;
}
@ -289,7 +289,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
elem = kzalloc(sizeof(*elem), GFP_ATOMIC);
if (!elem)
goto free_desc;
@@ -797,13 +867,20 @@ static void ath11k_dp_rx_tid_del_func(st
@@ -798,13 +868,20 @@ static void ath11k_dp_rx_tid_del_func(st
if (dp->reo_cmd_cache_flush_count > DP_REO_DESC_FREE_THRESHOLD ||
time_after(jiffies, elem->ts +
msecs_to_jiffies(DP_REO_DESC_FREE_TIMEOUT_MS))) {
@ -314,7 +314,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
}
}
spin_unlock_bh(&dp->reo_cmd_lock);
@@ -819,34 +896,48 @@ free_desc:
@@ -820,34 +897,48 @@ free_desc:
void ath11k_peer_rx_tid_delete(struct ath11k *ar,
struct ath11k_peer *peer, u8 tid)
{

View File

@ -36,7 +36,7 @@ Signed-off-by: Rajat Soni <quic_rajson@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -6784,7 +6784,9 @@ static int ath11k_mac_op_start(struct ie
@@ -6496,7 +6496,9 @@ static int ath11k_mac_op_start(struct ie
break;
case ATH11K_STATE_RESTARTING:
ar->state = ATH11K_STATE_RESTARTED;

View File

@ -27,7 +27,7 @@ Signed-off-by: Hari Chandrakanthan <quic_haric@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -8462,6 +8462,8 @@ static int ath11k_mac_flush_tx_complete(
@@ -8655,6 +8655,8 @@ static int ath11k_mac_flush_tx_complete(
ret = -ETIMEDOUT;
}

View File

@ -13,7 +13,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -10139,6 +10139,7 @@ static int __ath11k_mac_register(struct
@@ -10718,6 +10718,7 @@ static int __ath11k_mac_register(struct
ieee80211_hw_set(ar->hw, QUEUE_CONTROL);
ieee80211_hw_set(ar->hw, SUPPORTS_TX_FRAG);
ieee80211_hw_set(ar->hw, REPORTS_LOW_ACK);

View File

@ -48,7 +48,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -6089,7 +6089,9 @@ int ath11k_dp_rx_process_mon_status(stru
@@ -6091,7 +6091,9 @@ int ath11k_dp_rx_process_mon_status(stru
if (!num_buffs_reaped)
goto exit;
@ -59,7 +59,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
ppdu_info->peer_id = HAL_INVALID_PEERID;
while ((skb = __skb_dequeue(&skb_list))) {
@@ -6107,7 +6109,6 @@ int ath11k_dp_rx_process_mon_status(stru
@@ -6109,7 +6111,6 @@ int ath11k_dp_rx_process_mon_status(stru
if (log_type != ATH11K_PKTLOG_TYPE_INVALID)
trace_ath11k_htt_rxdesc(ar, skb->data, log_type, rx_buf_sz);
@ -67,7 +67,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
ppdu_info->peer_id = HAL_INVALID_PEERID;
hal_status = ath11k_hal_rx_parse_mon_status(ab, ppdu_info, skb);
@@ -6135,6 +6136,7 @@ int ath11k_dp_rx_process_mon_status(stru
@@ -6137,6 +6138,7 @@ int ath11k_dp_rx_process_mon_status(stru
if ((ppdu_info->peer_id == HAL_INVALID_PEERID ||
hal_status != HAL_RX_MON_STATUS_PPDU_DONE)) {
dev_kfree_skb_any(skb);
@ -77,7 +77,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
rcu_read_lock();
--- a/drivers/net/wireless/ath/ath11k/hal_rx.h
+++ b/drivers/net/wireless/ath/ath11k/hal_rx.h
@@ -221,6 +221,7 @@ struct hal_rx_mon_ppdu_info {
@@ -222,6 +222,7 @@ struct hal_rx_mon_ppdu_info {
u32 num_users;
u32 mpdu_fcs_ok_bitmap[HAL_RX_NUM_WORDS_PER_PPDU_BITMAP];
struct hal_rx_user_status userstats[HAL_MAX_UL_MU_USERS];

View File

@ -40,7 +40,7 @@ Signed-off-by: Balamurugan Selvarajan <quic_bselvara@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -392,9 +392,9 @@ int ath11k_dp_rxbufs_replenish(struct at
@@ -393,9 +393,9 @@ int ath11k_dp_rxbufs_replenish(struct at
skb->data);
}
@ -53,7 +53,7 @@ Signed-off-by: Balamurugan Selvarajan <quic_bselvara@quicinc.com>
if (dma_mapping_error(ab->dev, paddr))
goto fail_free_skb;
@@ -430,8 +430,8 @@ fail_idr_remove:
@@ -431,8 +431,8 @@ fail_idr_remove:
idr_remove(&rx_ring->bufs_idr, buf_id);
spin_unlock_bh(&rx_ring->idr_lock);
fail_dma_unmap:

View File

@ -1,58 +0,0 @@
Received: from bqiang-Celadon-RN.qca.qualcomm.com (10.80.80.8) by
From: Baochen Qiang <quic_bqiang@quicinc.com>
To: <ath11k@lists.infradead.org>
Subject: [PATCH 1/4] wifi: ath11k: remove invalid peer create logic
Date: Tue, 23 Jan 2024 10:56:57 +0800
In ath11k_mac_op_assign_vif_chanctx(), there is a logic to
create peer using ar->mac_addr for a STA vdev. This is invalid
because a STA vdev should have a peer created using AP's
MAC address. Besides, if we run into that logic, it means a peer
has already been created earlier, we should not create it again.
So remove it.
This is found during code review.
Tested-on: QCA6390 hw2.0 PCI WLAN.HST.1.0.1-01740-QCAHSTSWPLZ_V2_TO_X86-1
Tested-on: WCN6855 hw2.1 PCI WLAN.HSP.1.1-03125-QCAHSPSWPL_V1_V2_SILICONZ_LITE-3.6510.23
Tested-on: QCN9074 hw1.0 PCI WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
Signed-off-by: Baochen Qiang <quic_bqiang@quicinc.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
---
drivers/net/wireless/ath/ath11k/mac.c | 16 ----------------
1 file changed, 16 deletions(-)
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -8216,7 +8216,6 @@ ath11k_mac_op_assign_vif_chanctx(struct
struct ath11k_base *ab = ar->ab;
struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
int ret;
- struct peer_create_params param;
mutex_lock(&ar->conf_mutex);
@@ -8239,21 +8238,6 @@ ath11k_mac_op_assign_vif_chanctx(struct
goto out;
}
- if (ab->hw_params.vdev_start_delay &&
- arvif->vdev_type != WMI_VDEV_TYPE_AP &&
- arvif->vdev_type != WMI_VDEV_TYPE_MONITOR) {
- param.vdev_id = arvif->vdev_id;
- param.peer_type = WMI_PEER_TYPE_DEFAULT;
- param.peer_addr = ar->mac_addr;
-
- ret = ath11k_peer_create(ar, arvif, NULL, &param);
- if (ret) {
- ath11k_warn(ab, "failed to create peer after vdev start delay: %d",
- ret);
- goto out;
- }
- }
-
if (arvif->vdev_type == WMI_VDEV_TYPE_MONITOR) {
ret = ath11k_mac_monitor_start(ar);
if (ret) {

View File

@ -1,52 +0,0 @@
From: Baochen Qiang <quic_bqiang@quicinc.com>
To: <ath11k@lists.infradead.org>
Subject: [PATCH 2/4] wifi: ath11k: rename ath11k_start_vdev_delay()
Date: Tue, 23 Jan 2024 10:56:58 +0800
Rename ath11k_start_vdev_delay() as ath11k_mac_start_vdev_delay()
to follow naming convention.
Tested-on: QCA6390 hw2.0 PCI WLAN.HST.1.0.1-01740-QCAHSTSWPLZ_V2_TO_X86-1
Tested-on: WCN6855 hw2.1 PCI WLAN.HSP.1.1-03125-QCAHSPSWPL_V1_V2_SILICONZ_LITE-3.6510.23
Tested-on: QCN9074 hw1.0 PCI WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
Signed-off-by: Baochen Qiang <quic_bqiang@quicinc.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
---
drivers/net/wireless/ath/ath11k/mac.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -256,8 +256,8 @@ static const u32 ath11k_smps_map[] = {
[WLAN_HT_CAP_SM_PS_DISABLED] = WMI_PEER_SMPS_PS_NONE,
};
-static int ath11k_start_vdev_delay(struct ieee80211_hw *hw,
- struct ieee80211_vif *vif);
+static int ath11k_mac_start_vdev_delay(struct ieee80211_hw *hw,
+ struct ieee80211_vif *vif);
enum nl80211_he_ru_alloc ath11k_mac_phy_he_ru_to_nl80211_he_ru_alloc(u16 ru_phy)
{
@@ -5314,7 +5314,7 @@ static int ath11k_mac_station_add(struct
if (ab->hw_params.vdev_start_delay &&
!arvif->is_started &&
arvif->vdev_type != WMI_VDEV_TYPE_AP) {
- ret = ath11k_start_vdev_delay(ar->hw, vif);
+ ret = ath11k_mac_start_vdev_delay(ar->hw, vif);
if (ret) {
ath11k_warn(ab, "failed to delay vdev start: %d\n", ret);
goto free_tx_stats;
@@ -8159,8 +8159,8 @@ unlock:
mutex_unlock(&ar->conf_mutex);
}
-static int ath11k_start_vdev_delay(struct ieee80211_hw *hw,
- struct ieee80211_vif *vif)
+static int ath11k_mac_start_vdev_delay(struct ieee80211_hw *hw,
+ struct ieee80211_vif *vif)
{
struct ath11k *ar = hw->priv;
struct ath11k_base *ab = ar->ab;

View File

@ -1,601 +0,0 @@
From: Baochen Qiang <quic_bqiang@quicinc.com>
To: <ath11k@lists.infradead.org>
Subject: [PATCH 3/4] wifi: ath11k: avoid forward declaration of
ath11k_mac_start_vdev_delay()
Date: Tue, 23 Jan 2024 10:56:59 +0800
Currently ath11k_mac_start_vdev_delay() needs a forward declaration because
it is defined after where it is called. Avoid this by re-arranging
ath11k_mac_station_add() and ath11k_mac_op_sta_state().
No functional changes. Compile tested only.
Signed-off-by: Baochen Qiang <quic_bqiang@quicinc.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
---
drivers/net/wireless/ath/ath11k/mac.c | 459 +++++++++++++-------------
1 file changed, 228 insertions(+), 231 deletions(-)
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -256,9 +256,6 @@ static const u32 ath11k_smps_map[] = {
[WLAN_HT_CAP_SM_PS_DISABLED] = WMI_PEER_SMPS_PS_NONE,
};
-static int ath11k_mac_start_vdev_delay(struct ieee80211_hw *hw,
- struct ieee80211_vif *vif);
-
enum nl80211_he_ru_alloc ath11k_mac_phy_he_ru_to_nl80211_he_ru_alloc(u16 ru_phy)
{
enum nl80211_he_ru_alloc ret;
@@ -5244,100 +5241,6 @@ static void ath11k_mac_dec_num_stations(
ar->num_stations--;
}
-static int ath11k_mac_station_add(struct ath11k *ar,
- struct ieee80211_vif *vif,
- struct ieee80211_sta *sta)
-{
- struct ath11k_base *ab = ar->ab;
- struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
- struct ath11k_sta *arsta = ath11k_sta_to_arsta(sta);
- struct peer_create_params peer_param;
- int ret;
-
- lockdep_assert_held(&ar->conf_mutex);
-
- ret = ath11k_mac_inc_num_stations(arvif, sta);
- if (ret) {
- ath11k_warn(ab, "refusing to associate station: too many connected already (%d)\n",
- ar->max_num_stations);
- goto exit;
- }
-
- arsta->rx_stats = kzalloc(sizeof(*arsta->rx_stats), GFP_KERNEL);
- if (!arsta->rx_stats) {
- ret = -ENOMEM;
- goto dec_num_station;
- }
-
- peer_param.vdev_id = arvif->vdev_id;
- peer_param.peer_addr = sta->addr;
- peer_param.peer_type = WMI_PEER_TYPE_DEFAULT;
-
- ret = ath11k_peer_create(ar, arvif, sta, &peer_param);
- if (ret) {
- ath11k_warn(ab, "Failed to add peer: %pM for VDEV: %d\n",
- sta->addr, arvif->vdev_id);
- goto free_rx_stats;
- }
-
- ath11k_dbg(ab, ATH11K_DBG_MAC, "Added peer: %pM for VDEV: %d\n",
- sta->addr, arvif->vdev_id);
-
- if (ath11k_debugfs_is_extd_tx_stats_enabled(ar)) {
- arsta->tx_stats = kzalloc(sizeof(*arsta->tx_stats), GFP_KERNEL);
- if (!arsta->tx_stats) {
- ret = -ENOMEM;
- goto free_peer;
- }
- }
-
- if (ieee80211_vif_is_mesh(vif)) {
- ath11k_dbg(ab, ATH11K_DBG_MAC,
- "setting USE_4ADDR for mesh STA %pM\n", sta->addr);
- ret = ath11k_wmi_set_peer_param(ar, sta->addr,
- arvif->vdev_id,
- WMI_PEER_USE_4ADDR, 1);
- if (ret) {
- ath11k_warn(ab, "failed to set mesh STA %pM 4addr capability: %d\n",
- sta->addr, ret);
- goto free_tx_stats;
- }
- }
-
- ret = ath11k_dp_peer_setup(ar, arvif->vdev_id, sta->addr);
- if (ret) {
- ath11k_warn(ab, "failed to setup dp for peer %pM on vdev %i (%d)\n",
- sta->addr, arvif->vdev_id, ret);
- goto free_tx_stats;
- }
-
- if (ab->hw_params.vdev_start_delay &&
- !arvif->is_started &&
- arvif->vdev_type != WMI_VDEV_TYPE_AP) {
- ret = ath11k_mac_start_vdev_delay(ar->hw, vif);
- if (ret) {
- ath11k_warn(ab, "failed to delay vdev start: %d\n", ret);
- goto free_tx_stats;
- }
- }
-
- ewma_avg_rssi_init(&arsta->avg_rssi);
- return 0;
-
-free_tx_stats:
- kfree(arsta->tx_stats);
- arsta->tx_stats = NULL;
-free_peer:
- ath11k_peer_delete(ar, arvif->vdev_id, sta->addr);
-free_rx_stats:
- kfree(arsta->rx_stats);
- arsta->rx_stats = NULL;
-dec_num_station:
- ath11k_mac_dec_num_stations(arvif, sta);
-exit:
- return ret;
-}
-
static u32 ath11k_mac_ieee80211_sta_bw_to_wmi(struct ath11k *ar,
struct ieee80211_sta *sta)
{
@@ -5393,187 +5296,6 @@ static int ath11k_mac_cfg_dyn_vlan(struc
return ret;
}
-static int ath11k_mac_op_sta_state(struct ieee80211_hw *hw,
- struct ieee80211_vif *vif,
- struct ieee80211_sta *sta,
- enum ieee80211_sta_state old_state,
- enum ieee80211_sta_state new_state)
-{
- struct ath11k *ar = hw->priv;
- struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
- struct ath11k_sta *arsta = ath11k_sta_to_arsta(sta);
- struct ath11k_peer *peer;
- int ret = 0;
-
- /* cancel must be done outside the mutex to avoid deadlock */
- if ((old_state == IEEE80211_STA_NONE &&
- new_state == IEEE80211_STA_NOTEXIST)) {
- cancel_work_sync(&arsta->update_wk);
- cancel_work_sync(&arsta->set_4addr_wk);
- }
-
- mutex_lock(&ar->conf_mutex);
-
- if (old_state == IEEE80211_STA_NOTEXIST &&
- new_state == IEEE80211_STA_NONE) {
- memset(arsta, 0, sizeof(*arsta));
- arsta->arvif = arvif;
- arsta->peer_ps_state = WMI_PEER_PS_STATE_DISABLED;
- INIT_WORK(&arsta->update_wk, ath11k_sta_rc_update_wk);
- INIT_WORK(&arsta->set_4addr_wk, ath11k_sta_set_4addr_wk);
-
- ret = ath11k_mac_station_add(ar, vif, sta);
- if (ret)
- ath11k_warn(ar->ab, "Failed to add station: %pM for VDEV: %d\n",
- sta->addr, arvif->vdev_id);
- } else if ((old_state == IEEE80211_STA_NONE &&
- new_state == IEEE80211_STA_NOTEXIST)) {
- bool skip_peer_delete = ar->ab->hw_params.vdev_start_delay &&
- vif->type == NL80211_IFTYPE_STATION;
-
- ath11k_dp_peer_cleanup(ar, arvif->vdev_id, sta->addr);
-
- if (!skip_peer_delete) {
- ret = ath11k_peer_delete(ar, arvif->vdev_id, sta->addr);
- if (ret)
- ath11k_warn(ar->ab,
- "Failed to delete peer: %pM for VDEV: %d\n",
- sta->addr, arvif->vdev_id);
- else
- ath11k_dbg(ar->ab,
- ATH11K_DBG_MAC,
- "Removed peer: %pM for VDEV: %d\n",
- sta->addr, arvif->vdev_id);
- }
-
- ath11k_mac_dec_num_stations(arvif, sta);
- mutex_lock(&ar->ab->tbl_mtx_lock);
- spin_lock_bh(&ar->ab->base_lock);
- peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
- if (skip_peer_delete && peer) {
- peer->sta = NULL;
- } else if (peer && peer->sta == sta) {
- ath11k_warn(ar->ab, "Found peer entry %pM n vdev %i after it was supposedly removed\n",
- vif->addr, arvif->vdev_id);
- ath11k_peer_rhash_delete(ar->ab, peer);
- peer->sta = NULL;
- list_del(&peer->list);
- kfree(peer);
- ar->num_peers--;
- }
- spin_unlock_bh(&ar->ab->base_lock);
- mutex_unlock(&ar->ab->tbl_mtx_lock);
-
- kfree(arsta->tx_stats);
- arsta->tx_stats = NULL;
-
- kfree(arsta->rx_stats);
- arsta->rx_stats = NULL;
- } else if (old_state == IEEE80211_STA_AUTH &&
- new_state == IEEE80211_STA_ASSOC &&
- (vif->type == NL80211_IFTYPE_AP ||
- vif->type == NL80211_IFTYPE_MESH_POINT ||
- vif->type == NL80211_IFTYPE_ADHOC)) {
- ret = ath11k_station_assoc(ar, vif, sta, false);
- if (ret)
- ath11k_warn(ar->ab, "Failed to associate station: %pM\n",
- sta->addr);
-
- spin_lock_bh(&ar->data_lock);
- /* Set arsta bw and prev bw */
- arsta->bw = ath11k_mac_ieee80211_sta_bw_to_wmi(ar, sta);
- arsta->bw_prev = arsta->bw;
- spin_unlock_bh(&ar->data_lock);
-
- /* Driver should clear the peer keys during mac80211's ref ptr
- * gets cleared in __sta_info_destroy_part2 (trans from
- * IEEE80211_STA_AUTHORIZED to IEEE80211_STA_ASSOC)
- */
- ret = ath11k_clear_peer_keys(arvif, sta->addr);
- if (ret) {
- ath11k_warn(ar->ab, "failed to clear all peer keys for vdev %i: %d\n",
- arvif->vdev_id, ret);
- return ret;
- }
- } else if (old_state == IEEE80211_STA_ASSOC &&
- new_state == IEEE80211_STA_AUTHORIZED) {
- spin_lock_bh(&ar->ab->base_lock);
-
- peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
- if (peer)
- peer->is_authorized = true;
-
- spin_unlock_bh(&ar->ab->base_lock);
-
- if (vif->type == NL80211_IFTYPE_STATION && arvif->is_up) {
- ret = ath11k_wmi_set_peer_param(ar, sta->addr,
- arvif->vdev_id,
- WMI_PEER_AUTHORIZE,
- 1);
- if (ret)
- ath11k_warn(ar->ab, "Unable to authorize peer %pM vdev %d: %d\n",
- sta->addr, arvif->vdev_id, ret);
- } else if (ar->ab->nss.enabled &&
- vif->type == NL80211_IFTYPE_AP_VLAN &&
- !arsta->use_4addr_set) {
-
- if (ar->state == ATH11K_STATE_RESTARTED) {
- /* During ieee80211_reconfig(), at this point, nss ext vdev peer is not
- * authorized. Hence ath11k_mac_cfg_dyn_vlan() will return error. We save
- * the state vars here and use it later once nss ext vdev is authorized
- * in ath11k_mac_op_set_key() */
- struct ath11k_dyn_vlan_cfg *ar_dyn_vlan_cfg;
- ar_dyn_vlan_cfg = kzalloc(sizeof(*ar_dyn_vlan_cfg), GFP_ATOMIC);
-
- if (!ar_dyn_vlan_cfg) {
- ath11k_warn(ar->ab, "failed to save state for dynamic AP_VLAN configuration (%d)",
- -ENOSPC);
- } else {
- INIT_LIST_HEAD(&ar_dyn_vlan_cfg->cfg_list);
- ar_dyn_vlan_cfg->arvif = arvif;
- ar_dyn_vlan_cfg->sta = sta;
- /* save it to arvif (AP_VLAN) list */
- list_add_tail(&ar_dyn_vlan_cfg->cfg_list, &arvif->dyn_vlan_cfg);
- }
- } else {
- ret = ath11k_mac_cfg_dyn_vlan(ar->ab, arvif, sta);
- if (ret)
- ath11k_warn(ar->ab, "failed to cfg dyn vlan for peer %pM: %d\n",
- sta->addr, ret);
- }
- }
- } else if (old_state == IEEE80211_STA_AUTHORIZED &&
- new_state == IEEE80211_STA_ASSOC) {
-
- spin_lock_bh(&ar->ab->base_lock);
- peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
- if (peer)
- peer->is_authorized = false;
- spin_unlock_bh(&ar->ab->base_lock);
- } else if (old_state == IEEE80211_STA_AUTHORIZED &&
- new_state == IEEE80211_STA_ASSOC) {
- spin_lock_bh(&ar->ab->base_lock);
-
- peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
- if (peer)
- peer->is_authorized = false;
-
- spin_unlock_bh(&ar->ab->base_lock);
- } else if (old_state == IEEE80211_STA_ASSOC &&
- new_state == IEEE80211_STA_AUTH &&
- (vif->type == NL80211_IFTYPE_AP ||
- vif->type == NL80211_IFTYPE_MESH_POINT ||
- vif->type == NL80211_IFTYPE_ADHOC)) {
- ret = ath11k_station_disassoc(ar, vif, sta);
- if (ret)
- ath11k_warn(ar->ab, "Failed to disassociate station: %pM\n",
- sta->addr);
- }
-
- mutex_unlock(&ar->conf_mutex);
- return ret;
-}
-
static int ath11k_mac_op_sta_set_txpwr(struct ieee80211_hw *hw,
struct ieee80211_vif *vif,
struct ieee80211_sta *sta)
@@ -9736,6 +9458,281 @@ ath11k_mac_op_config_mesh_offload_path(s
}
#endif
+static int ath11k_mac_station_add(struct ath11k *ar,
+ struct ieee80211_vif *vif,
+ struct ieee80211_sta *sta)
+{
+ struct ath11k_base *ab = ar->ab;
+ struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
+ struct ath11k_sta *arsta = ath11k_sta_to_arsta(sta);
+ struct peer_create_params peer_param;
+ int ret;
+
+ lockdep_assert_held(&ar->conf_mutex);
+
+ ret = ath11k_mac_inc_num_stations(arvif, sta);
+ if (ret) {
+ ath11k_warn(ab, "refusing to associate station: too many connected already (%d)\n",
+ ar->max_num_stations);
+ goto exit;
+ }
+
+ arsta->rx_stats = kzalloc(sizeof(*arsta->rx_stats), GFP_KERNEL);
+ if (!arsta->rx_stats) {
+ ret = -ENOMEM;
+ goto dec_num_station;
+ }
+
+ peer_param.vdev_id = arvif->vdev_id;
+ peer_param.peer_addr = sta->addr;
+ peer_param.peer_type = WMI_PEER_TYPE_DEFAULT;
+
+ ret = ath11k_peer_create(ar, arvif, sta, &peer_param);
+ if (ret) {
+ ath11k_warn(ab, "Failed to add peer: %pM for VDEV: %d\n",
+ sta->addr, arvif->vdev_id);
+ goto free_rx_stats;
+ }
+
+ ath11k_dbg(ab, ATH11K_DBG_MAC, "Added peer: %pM for VDEV: %d\n",
+ sta->addr, arvif->vdev_id);
+
+ if (ath11k_debugfs_is_extd_tx_stats_enabled(ar)) {
+ arsta->tx_stats = kzalloc(sizeof(*arsta->tx_stats), GFP_KERNEL);
+ if (!arsta->tx_stats) {
+ ret = -ENOMEM;
+ goto free_peer;
+ }
+ }
+
+ if (ieee80211_vif_is_mesh(vif)) {
+ ath11k_dbg(ab, ATH11K_DBG_MAC,
+ "setting USE_4ADDR for mesh STA %pM\n", sta->addr);
+ ret = ath11k_wmi_set_peer_param(ar, sta->addr,
+ arvif->vdev_id,
+ WMI_PEER_USE_4ADDR, 1);
+ if (ret) {
+ ath11k_warn(ab, "failed to set mesh STA %pM 4addr capability: %d\n",
+ sta->addr, ret);
+ goto free_tx_stats;
+ }
+ }
+
+ ret = ath11k_dp_peer_setup(ar, arvif->vdev_id, sta->addr);
+ if (ret) {
+ ath11k_warn(ab, "failed to setup dp for peer %pM on vdev %i (%d)\n",
+ sta->addr, arvif->vdev_id, ret);
+ goto free_tx_stats;
+ }
+
+ if (ab->hw_params.vdev_start_delay &&
+ !arvif->is_started &&
+ arvif->vdev_type != WMI_VDEV_TYPE_AP) {
+ ret = ath11k_mac_start_vdev_delay(ar->hw, vif);
+ if (ret) {
+ ath11k_warn(ab, "failed to delay vdev start: %d\n", ret);
+ goto free_tx_stats;
+ }
+ }
+
+ ewma_avg_rssi_init(&arsta->avg_rssi);
+ return 0;
+
+free_tx_stats:
+ kfree(arsta->tx_stats);
+ arsta->tx_stats = NULL;
+free_peer:
+ ath11k_peer_delete(ar, arvif->vdev_id, sta->addr);
+free_rx_stats:
+ kfree(arsta->rx_stats);
+ arsta->rx_stats = NULL;
+dec_num_station:
+ ath11k_mac_dec_num_stations(arvif, sta);
+exit:
+ return ret;
+}
+
+static int ath11k_mac_op_sta_state(struct ieee80211_hw *hw,
+ struct ieee80211_vif *vif,
+ struct ieee80211_sta *sta,
+ enum ieee80211_sta_state old_state,
+ enum ieee80211_sta_state new_state)
+{
+ struct ath11k *ar = hw->priv;
+ struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
+ struct ath11k_sta *arsta = ath11k_sta_to_arsta(sta);
+ struct ath11k_peer *peer;
+ int ret = 0;
+
+ /* cancel must be done outside the mutex to avoid deadlock */
+ if ((old_state == IEEE80211_STA_NONE &&
+ new_state == IEEE80211_STA_NOTEXIST)) {
+ cancel_work_sync(&arsta->update_wk);
+ cancel_work_sync(&arsta->set_4addr_wk);
+ }
+
+ mutex_lock(&ar->conf_mutex);
+
+ if (old_state == IEEE80211_STA_NOTEXIST &&
+ new_state == IEEE80211_STA_NONE) {
+ memset(arsta, 0, sizeof(*arsta));
+ arsta->arvif = arvif;
+ arsta->peer_ps_state = WMI_PEER_PS_STATE_DISABLED;
+ INIT_WORK(&arsta->update_wk, ath11k_sta_rc_update_wk);
+ INIT_WORK(&arsta->set_4addr_wk, ath11k_sta_set_4addr_wk);
+
+ ret = ath11k_mac_station_add(ar, vif, sta);
+ if (ret)
+ ath11k_warn(ar->ab, "Failed to add station: %pM for VDEV: %d\n",
+ sta->addr, arvif->vdev_id);
+ } else if ((old_state == IEEE80211_STA_NONE &&
+ new_state == IEEE80211_STA_NOTEXIST)) {
+ bool skip_peer_delete = ar->ab->hw_params.vdev_start_delay &&
+ vif->type == NL80211_IFTYPE_STATION;
+
+ ath11k_dp_peer_cleanup(ar, arvif->vdev_id, sta->addr);
+
+ if (!skip_peer_delete) {
+ ret = ath11k_peer_delete(ar, arvif->vdev_id, sta->addr);
+ if (ret)
+ ath11k_warn(ar->ab,
+ "Failed to delete peer: %pM for VDEV: %d\n",
+ sta->addr, arvif->vdev_id);
+ else
+ ath11k_dbg(ar->ab,
+ ATH11K_DBG_MAC,
+ "Removed peer: %pM for VDEV: %d\n",
+ sta->addr, arvif->vdev_id);
+ }
+
+ ath11k_mac_dec_num_stations(arvif, sta);
+ mutex_lock(&ar->ab->tbl_mtx_lock);
+ spin_lock_bh(&ar->ab->base_lock);
+ peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
+ if (skip_peer_delete && peer) {
+ peer->sta = NULL;
+ } else if (peer && peer->sta == sta) {
+ ath11k_warn(ar->ab, "Found peer entry %pM n vdev %i after it was supposedly removed\n",
+ vif->addr, arvif->vdev_id);
+ ath11k_peer_rhash_delete(ar->ab, peer);
+ peer->sta = NULL;
+ list_del(&peer->list);
+ kfree(peer);
+ ar->num_peers--;
+ }
+ spin_unlock_bh(&ar->ab->base_lock);
+ mutex_unlock(&ar->ab->tbl_mtx_lock);
+
+ kfree(arsta->tx_stats);
+ arsta->tx_stats = NULL;
+
+ kfree(arsta->rx_stats);
+ arsta->rx_stats = NULL;
+ } else if (old_state == IEEE80211_STA_AUTH &&
+ new_state == IEEE80211_STA_ASSOC &&
+ (vif->type == NL80211_IFTYPE_AP ||
+ vif->type == NL80211_IFTYPE_MESH_POINT ||
+ vif->type == NL80211_IFTYPE_ADHOC)) {
+ ret = ath11k_station_assoc(ar, vif, sta, false);
+ if (ret)
+ ath11k_warn(ar->ab, "Failed to associate station: %pM\n",
+ sta->addr);
+
+ spin_lock_bh(&ar->data_lock);
+ /* Set arsta bw and prev bw */
+ arsta->bw = ath11k_mac_ieee80211_sta_bw_to_wmi(ar, sta);
+ arsta->bw_prev = arsta->bw;
+ spin_unlock_bh(&ar->data_lock);
+
+ /* Driver should clear the peer keys during mac80211's ref ptr
+ * gets cleared in __sta_info_destroy_part2 (trans from
+ * IEEE80211_STA_AUTHORIZED to IEEE80211_STA_ASSOC)
+ */
+ ret = ath11k_clear_peer_keys(arvif, sta->addr);
+ if (ret) {
+ ath11k_warn(ar->ab, "failed to clear all peer keys for vdev %i: %d\n",
+ arvif->vdev_id, ret);
+ return ret;
+ }
+ } else if (old_state == IEEE80211_STA_ASSOC &&
+ new_state == IEEE80211_STA_AUTHORIZED) {
+ spin_lock_bh(&ar->ab->base_lock);
+
+ peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
+ if (peer)
+ peer->is_authorized = true;
+
+ spin_unlock_bh(&ar->ab->base_lock);
+
+ if (vif->type == NL80211_IFTYPE_STATION && arvif->is_up) {
+ ret = ath11k_wmi_set_peer_param(ar, sta->addr,
+ arvif->vdev_id,
+ WMI_PEER_AUTHORIZE,
+ 1);
+ if (ret)
+ ath11k_warn(ar->ab, "Unable to authorize peer %pM vdev %d: %d\n",
+ sta->addr, arvif->vdev_id, ret);
+ } else if (ar->ab->nss.enabled &&
+ vif->type == NL80211_IFTYPE_AP_VLAN &&
+ !arsta->use_4addr_set) {
+
+ if (ar->state == ATH11K_STATE_RESTARTED) {
+ /* During ieee80211_reconfig(), at this point, nss ext vdev peer is not
+ * authorized. Hence ath11k_mac_cfg_dyn_vlan() will return error. We save
+ * the state vars here and use it later once nss ext vdev is authorized
+ * in ath11k_mac_op_set_key() */
+ struct ath11k_dyn_vlan_cfg *ar_dyn_vlan_cfg;
+ ar_dyn_vlan_cfg = kzalloc(sizeof(*ar_dyn_vlan_cfg), GFP_ATOMIC);
+
+ if (!ar_dyn_vlan_cfg) {
+ ath11k_warn(ar->ab, "failed to save state for dynamic AP_VLAN configuration (%d)",
+ -ENOSPC);
+ } else {
+ INIT_LIST_HEAD(&ar_dyn_vlan_cfg->cfg_list);
+ ar_dyn_vlan_cfg->arvif = arvif;
+ ar_dyn_vlan_cfg->sta = sta;
+ /* save it to arvif (AP_VLAN) list */
+ list_add_tail(&ar_dyn_vlan_cfg->cfg_list, &arvif->dyn_vlan_cfg);
+ }
+ } else {
+ ret = ath11k_mac_cfg_dyn_vlan(ar->ab, arvif, sta);
+ if (ret)
+ ath11k_warn(ar->ab, "failed to cfg dyn vlan for peer %pM: %d\n",
+ sta->addr, ret);
+ }
+ }
+ } else if (old_state == IEEE80211_STA_AUTHORIZED &&
+ new_state == IEEE80211_STA_ASSOC) {
+
+ spin_lock_bh(&ar->ab->base_lock);
+ peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
+ if (peer)
+ peer->is_authorized = false;
+ spin_unlock_bh(&ar->ab->base_lock);
+ } else if (old_state == IEEE80211_STA_AUTHORIZED &&
+ new_state == IEEE80211_STA_ASSOC) {
+ spin_lock_bh(&ar->ab->base_lock);
+
+ peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
+ if (peer)
+ peer->is_authorized = false;
+
+ spin_unlock_bh(&ar->ab->base_lock);
+ } else if (old_state == IEEE80211_STA_ASSOC &&
+ new_state == IEEE80211_STA_AUTH &&
+ (vif->type == NL80211_IFTYPE_AP ||
+ vif->type == NL80211_IFTYPE_MESH_POINT ||
+ vif->type == NL80211_IFTYPE_ADHOC)) {
+ ret = ath11k_station_disassoc(ar, vif, sta);
+ if (ret)
+ ath11k_warn(ar->ab, "Failed to disassociate station: %pM\n",
+ sta->addr);
+ }
+
+ mutex_unlock(&ar->conf_mutex);
+ return ret;
+}
+
static const struct ieee80211_ops ath11k_ops = {
.tx = ath11k_mac_op_tx,
.wake_tx_queue = ieee80211_handle_wake_tx_queue,

View File

@ -1,257 +0,0 @@
From: Baochen Qiang <quic_bqiang@quicinc.com>
To: <ath11k@lists.infradead.org>
Subject: [PATCH 4/4] wifi: ath11k: fix connection failure due to unexpected
peer delete
Date: Tue, 23 Jan 2024 10:57:00 +0800
Currently ath11k_mac_op_unassign_vif_chanctx() deletes peer but
ath11k_mac_op_assign_vif_chanctx() doesn't create it. This results in
connection failure if MAC80211 calls drv_unassign_vif_chanctx() and
drv_assign_vif_chanctx() during AUTH and ASSOC, see below log:
[ 102.372431] wlan0: authenticated
[ 102.372585] ath11k_pci 0000:01:00.0: wlan0: disabling HT/VHT/HE as WMM/QoS is not supported by the AP
[ 102.372593] ath11k_pci 0000:01:00.0: mac chanctx unassign ptr ffff895084638598 vdev_id 0
[ 102.372808] ath11k_pci 0000:01:00.0: WMI vdev stop id 0x0
[ 102.383114] ath11k_pci 0000:01:00.0: vdev stopped for vdev id 0
[ 102.384689] ath11k_pci 0000:01:00.0: WMI peer delete vdev_id 0 peer_addr 20:e5:2a:21:c4:51
[ 102.396676] ath11k_pci 0000:01:00.0: htt peer unmap vdev 0 peer 20:e5:2a:21:c4:51 id 3
[ 102.396711] ath11k_pci 0000:01:00.0: peer delete resp for vdev id 0 addr 20:e5:2a:21:c4:51
[ 102.396722] ath11k_pci 0000:01:00.0: mac removed peer 20:e5:2a:21:c4:51 vdev 0 after vdev stop
[ 102.396780] ath11k_pci 0000:01:00.0: mac chanctx assign ptr ffff895084639c18 vdev_id 0
[ 102.400628] wlan0: associate with 20:e5:2a:21:c4:51 (try 1/3)
[ 102.508864] wlan0: associate with 20:e5:2a:21:c4:51 (try 2/3)
[ 102.612815] wlan0: associate with 20:e5:2a:21:c4:51 (try 3/3)
[ 102.720846] wlan0: association with 20:e5:2a:21:c4:51 timed out
The peer delete logic in ath11k_mac_op_unassign_vif_chanctx() is
introduced by commit b4a0f54156ac ("ath11k: move peer delete after
vdev stop of station for QCA6390 and WCN6855") to fix firmware
crash issue caused by unexpected vdev stop/peer delete sequence.
Actually for a STA interface peer should be deleted in
ath11k_mac_op_sta_state() when STA's state changes from
IEEE80211_STA_NONE to IEEE80211_STA_NOTEXIST, which also coincides
with current peer creation design that peer is created during
IEEE80211_STA_NOTEXIST -> IEEE80211_STA_NONE transition. So move
peer delete back to ath11k_mac_op_sta_state(), also stop vdev before
deleting peer to fix the firmware crash issue mentioned there. In
this way the connection failure mentioned here is also fixed.
Tested-on: QCA6390 hw2.0 PCI WLAN.HST.1.0.1-01740-QCAHSTSWPLZ_V2_TO_X86-1
Tested-on: WCN6855 hw2.1 PCI WLAN.HSP.1.1-03125-QCAHSPSWPL_V1_V2_SILICONZ_LITE-3.6510.23
Tested-on: QCN9074 hw1.0 PCI WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
Fixes: b4a0f54156ac ("ath11k: move peer delete after vdev stop of station for QCA6390 and WCN6855")
Signed-off-by: Baochen Qiang <quic_bqiang@quicinc.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
---
drivers/net/wireless/ath/ath11k/mac.c | 139 ++++++++++++++++----------
1 file changed, 85 insertions(+), 54 deletions(-)
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -7928,6 +7928,30 @@ static int ath11k_mac_start_vdev_delay(s
return 0;
}
+static int ath11k_mac_stop_vdev_early(struct ieee80211_hw *hw,
+ struct ieee80211_vif *vif)
+{
+ struct ath11k *ar = hw->priv;
+ struct ath11k_base *ab = ar->ab;
+ struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
+ int ret;
+
+ if (WARN_ON(!arvif->is_started))
+ return -EBUSY;
+
+ ret = ath11k_mac_vdev_stop(arvif);
+ if (ret) {
+ ath11k_warn(ab, "failed to stop vdev %i: %d\n",
+ arvif->vdev_id, ret);
+ return ret;
+ }
+
+ arvif->is_started = false;
+
+ /* TODO: Setup ps and cts/rts protection */
+ return 0;
+}
+
static int
ath11k_mac_op_assign_vif_chanctx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif,
@@ -7972,15 +7996,17 @@ ath11k_mac_op_assign_vif_chanctx(struct
goto out;
}
- ret = ath11k_mac_vdev_start(arvif, ctx);
- if (ret) {
- ath11k_warn(ab, "failed to start vdev %i addr %pM on freq %d: %d\n",
- arvif->vdev_id, vif->addr,
- ctx->def.chan->center_freq, ret);
- goto out;
- }
+ if (!arvif->is_started) {
+ ret = ath11k_mac_vdev_start(arvif, ctx);
+ if (ret) {
+ ath11k_warn(ab, "failed to start vdev %i addr %pM on freq %d: %d\n",
+ arvif->vdev_id, vif->addr,
+ ctx->def.chan->center_freq, ret);
+ goto out;
+ }
- arvif->is_started = true;
+ arvif->is_started = true;
+ }
if (arvif->vdev_type != WMI_VDEV_TYPE_MONITOR &&
test_bit(ATH11K_FLAG_MONITOR_VDEV_CREATED, &ar->monitor_flags)) {
@@ -8020,8 +8046,6 @@ ath11k_mac_op_unassign_vif_chanctx(struc
"chanctx unassign ptr %p vdev_id %i\n",
ctx, arvif->vdev_id);
- WARN_ON(!arvif->is_started);
-
if (ab->hw_params.vdev_start_delay &&
arvif->vdev_type == WMI_VDEV_TYPE_MONITOR) {
spin_lock_bh(&ab->base_lock);
@@ -8045,24 +8069,13 @@ ath11k_mac_op_unassign_vif_chanctx(struc
return;
}
- ret = ath11k_mac_vdev_stop(arvif);
- if (ret)
- ath11k_warn(ab, "failed to stop vdev %i: %d\n",
- arvif->vdev_id, ret);
-
- arvif->is_started = false;
-
- if (ab->hw_params.vdev_start_delay &&
- arvif->vdev_type == WMI_VDEV_TYPE_STA) {
- ret = ath11k_peer_delete(ar, arvif->vdev_id, arvif->bssid);
+ if (arvif->is_started) {
+ ret = ath11k_mac_vdev_stop(arvif);
if (ret)
- ath11k_warn(ar->ab,
- "failed to delete peer %pM for vdev %d: %d\n",
- arvif->bssid, arvif->vdev_id, ret);
- else
- ath11k_dbg(ar->ab, ATH11K_DBG_MAC,
- "removed peer %pM vdev %d after vdev stop\n",
- arvif->bssid, arvif->vdev_id);
+ ath11k_warn(ab, "failed to stop vdev %i: %d\n",
+ arvif->vdev_id, ret);
+
+ arvif->is_started = false;
}
if (ab->hw_params.vdev_start_delay &&
@@ -9552,6 +9565,46 @@ exit:
return ret;
}
+static int ath11k_mac_station_remove(struct ath11k *ar,
+ struct ieee80211_vif *vif,
+ struct ieee80211_sta *sta)
+{
+ struct ath11k_base *ab = ar->ab;
+ struct ath11k_vif *arvif = ath11k_vif_to_arvif(vif);
+ struct ath11k_sta *arsta = ath11k_sta_to_arsta(sta);
+ int ret;
+
+ if (ab->hw_params.vdev_start_delay &&
+ arvif->is_started &&
+ arvif->vdev_type != WMI_VDEV_TYPE_AP) {
+ ret = ath11k_mac_stop_vdev_early(ar->hw, vif);
+ if (ret) {
+ ath11k_warn(ab, "failed to do early vdev stop: %d\n", ret);
+ return ret;
+ }
+ }
+
+ ath11k_dp_peer_cleanup(ar, arvif->vdev_id, sta->addr);
+
+ ret = ath11k_peer_delete(ar, arvif->vdev_id, sta->addr);
+ if (ret)
+ ath11k_warn(ab, "Failed to delete peer: %pM for VDEV: %d\n",
+ sta->addr, arvif->vdev_id);
+ else
+ ath11k_dbg(ab, ATH11K_DBG_MAC, "Removed peer: %pM for VDEV: %d\n",
+ sta->addr, arvif->vdev_id);
+
+ ath11k_mac_dec_num_stations(arvif, sta);
+
+ kfree(arsta->tx_stats);
+ arsta->tx_stats = NULL;
+
+ kfree(arsta->rx_stats);
+ arsta->rx_stats = NULL;
+
+ return ret;
+}
+
static int ath11k_mac_op_sta_state(struct ieee80211_hw *hw,
struct ieee80211_vif *vif,
struct ieee80211_sta *sta,
@@ -9587,31 +9640,15 @@ static int ath11k_mac_op_sta_state(struc
sta->addr, arvif->vdev_id);
} else if ((old_state == IEEE80211_STA_NONE &&
new_state == IEEE80211_STA_NOTEXIST)) {
- bool skip_peer_delete = ar->ab->hw_params.vdev_start_delay &&
- vif->type == NL80211_IFTYPE_STATION;
-
- ath11k_dp_peer_cleanup(ar, arvif->vdev_id, sta->addr);
-
- if (!skip_peer_delete) {
- ret = ath11k_peer_delete(ar, arvif->vdev_id, sta->addr);
- if (ret)
- ath11k_warn(ar->ab,
- "Failed to delete peer: %pM for VDEV: %d\n",
- sta->addr, arvif->vdev_id);
- else
- ath11k_dbg(ar->ab,
- ATH11K_DBG_MAC,
- "Removed peer: %pM for VDEV: %d\n",
- sta->addr, arvif->vdev_id);
- }
+ ret = ath11k_mac_station_remove(ar, vif, sta);
+ if (ret)
+ ath11k_warn(ar->ab, "Failed to remove station: %pM for VDEV: %d\n",
+ sta->addr, arvif->vdev_id);
- ath11k_mac_dec_num_stations(arvif, sta);
mutex_lock(&ar->ab->tbl_mtx_lock);
spin_lock_bh(&ar->ab->base_lock);
peer = ath11k_peer_find(ar->ab, arvif->vdev_id, sta->addr);
- if (skip_peer_delete && peer) {
- peer->sta = NULL;
- } else if (peer && peer->sta == sta) {
+ if (peer && peer->sta == sta) {
ath11k_warn(ar->ab, "Found peer entry %pM n vdev %i after it was supposedly removed\n",
vif->addr, arvif->vdev_id);
ath11k_peer_rhash_delete(ar->ab, peer);
@@ -9622,12 +9659,6 @@ static int ath11k_mac_op_sta_state(struc
}
spin_unlock_bh(&ar->ab->base_lock);
mutex_unlock(&ar->ab->tbl_mtx_lock);
-
- kfree(arsta->tx_stats);
- arsta->tx_stats = NULL;
-
- kfree(arsta->rx_stats);
- arsta->rx_stats = NULL;
} else if (old_state == IEEE80211_STA_AUTH &&
new_state == IEEE80211_STA_ASSOC &&
(vif->type == NL80211_IFTYPE_AP ||
@@ -10200,6 +10231,8 @@ static int __ath11k_mac_register(struct
wiphy_ext_feature_set(ar->hw->wiphy, NL80211_EXT_FEATURE_ACK_SIGNAL_SUPPORT);
+ wiphy_ext_feature_set(ar->hw->wiphy, NL80211_EXT_FEATURE_ACK_SIGNAL_SUPPORT);
+
ar->hw->queues = ATH11K_HW_MAX_QUEUES;
ar->hw->wiphy->tx_queue_len = ATH11K_QUEUE_LEN;
ar->hw->offchannel_tx_hw_queue = ATH11K_HW_MAX_QUEUES - 1;

View File

@ -27,9 +27,9 @@
depends on ATH11K && EVENT_TRACING
--- a/drivers/net/wireless/ath/ath11k/Makefile
+++ b/drivers/net/wireless/ath/ath11k/Makefile
@@ -19,7 +19,9 @@ ath11k-y += core.o \
hw.o \
pcic.o
@@ -20,7 +20,9 @@ ath11k-y += core.o \
pcic.o \
fw.o
-ath11k-$(CPTCFG_ATH11K_DEBUGFS) += debugfs.o debugfs_htt_stats.o debugfs_sta.o
+ath11k-$(CPTCFG_ATH11K_DEBUGFS) += debugfs.o
@ -40,7 +40,7 @@
ath11k-$(CPTCFG_ATH11K_THERMAL) += thermal.o
--- a/drivers/net/wireless/ath/ath11k/debugfs.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs.c
@@ -1875,7 +1875,9 @@ int ath11k_debugfs_register(struct ath11
@@ -1876,7 +1876,9 @@ int ath11k_debugfs_register(struct ath11
snprintf(buf, 100, "../../ath11k/%pd2", ar->debug.debugfs_pdev);
debugfs_create_symlink("ath11k", ar->hw->wiphy->debugfsdir, buf);
@ -52,7 +52,7 @@
--- a/drivers/net/wireless/ath/ath11k/debugfs_sta.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs_sta.c
@@ -11,7 +11,9 @@
@@ -12,7 +12,9 @@
#include "debug.h"
#include "dp_tx.h"
#include "dp_rx.h"
@ -62,7 +62,7 @@
static inline u32 ath11k_he_tones_in_ru_to_nl80211_he_ru_alloc(u16 ru_tones)
{
@@ -551,6 +553,7 @@ static const struct file_operations fops
@@ -552,6 +554,7 @@ static const struct file_operations fops
.llseek = default_llseek,
};
@ -70,7 +70,7 @@
static int
ath11k_dbg_sta_open_htt_peer_stats(struct inode *inode, struct file *file)
{
@@ -622,6 +625,7 @@ static const struct file_operations fops
@@ -623,6 +626,7 @@ static const struct file_operations fops
.owner = THIS_MODULE,
.llseek = default_llseek,
};
@ -78,7 +78,7 @@
static ssize_t ath11k_dbg_sta_write_peer_pktlog(struct file *file,
const char __user *buf,
@@ -906,6 +910,7 @@ static const struct file_operations fops
@@ -907,6 +911,7 @@ static const struct file_operations fops
.llseek = default_llseek,
};
@ -86,7 +86,7 @@
static ssize_t
ath11k_write_htt_peer_stats_reset(struct file *file,
const char __user *user_buf,
@@ -965,6 +970,7 @@ static const struct file_operations fops
@@ -966,6 +971,7 @@ static const struct file_operations fops
.owner = THIS_MODULE,
.llseek = default_llseek,
};
@ -94,7 +94,7 @@
static ssize_t ath11k_dbg_sta_read_peer_ps_state(struct file *file,
char __user *user_buf,
@@ -1111,8 +1117,10 @@ void ath11k_debugfs_sta_op_add(struct ie
@@ -1112,8 +1118,10 @@ void ath11k_debugfs_sta_op_add(struct ie
&fops_reset_rx_stats);
}
@ -105,7 +105,7 @@
debugfs_create_file("peer_pktlog", 0644, dir, sta,
&fops_peer_pktlog);
@@ -1122,10 +1130,12 @@ void ath11k_debugfs_sta_op_add(struct ie
@@ -1123,10 +1131,12 @@ void ath11k_debugfs_sta_op_add(struct ie
debugfs_create_file("addba_resp", 0200, dir, sta, &fops_addba_resp);
debugfs_create_file("delba", 0200, dir, sta, &fops_delba);
@ -120,7 +120,7 @@
&fops_peer_ps_state);
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -1723,8 +1723,10 @@ ath11k_update_per_peer_tx_stats(struct a
@@ -1724,8 +1724,10 @@ ath11k_update_per_peer_tx_stats(struct a
peer_stats->mu_pos = mu_pos;
peer_stats->ru_tones = arsta->txrate.he_ru_alloc;
@ -131,7 +131,7 @@
}
usr_stats->rate_stats_updated = true;
@@ -2170,7 +2172,9 @@ void ath11k_dp_htt_htc_t2h_msg_handler(s
@@ -2171,7 +2173,9 @@ void ath11k_dp_htt_htc_t2h_msg_handler(s
ath11k_htt_pull_ppdu_stats(ab, skb);
break;
case HTT_T2H_MSG_TYPE_EXT_STATS_CONF:
@ -176,18 +176,18 @@
spin_unlock_bh(&ab->base_lock);
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -9809,7 +9809,7 @@ static const struct ieee80211_ops ath11k
@@ -10327,7 +10327,7 @@ static const struct ieee80211_ops ath11k
.set_wakeup = ath11k_wow_op_set_wakeup,
#endif
-#ifdef CPTCFG_ATH11K_DEBUGFS
+#ifdef CPTCFG_ATH11K_DEBUGFS_STA
.vif_add_debugfs = ath11k_debugfs_op_vif_add,
.sta_add_debugfs = ath11k_debugfs_sta_op_add,
#endif
--- a/local-symbols
+++ b/local-symbols
@@ -176,6 +176,8 @@ ATH11K_MEM_PROFILE_256M=
@@ -169,6 +169,8 @@ ATH11K_MEM_PROFILE_256M=
ATH11K_MEM_PROFILE_512M=
ATH11K_DEBUG=
ATH11K_DEBUGFS=

View File

@ -18,7 +18,7 @@ Signed-off-by: Sarika Sharma <quic_sarishar@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -2202,6 +2202,7 @@ static int ath11k_dp_rx_msdu_coalesce(st
@@ -2203,6 +2203,7 @@ static int ath11k_dp_rx_msdu_coalesce(st
struct hal_rx_desc *ldesc;
int space_extra, rem_len, buf_len;
u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz;
@ -26,7 +26,7 @@ Signed-off-by: Sarika Sharma <quic_sarishar@quicinc.com>
/* As the msdu is spread across multiple rx buffers,
* find the offset to the start of msdu for computing
@@ -2250,7 +2251,8 @@ static int ath11k_dp_rx_msdu_coalesce(st
@@ -2251,7 +2252,8 @@ static int ath11k_dp_rx_msdu_coalesce(st
rem_len = msdu_len - buf_first_len;
while ((skb = __skb_dequeue(msdu_list)) != NULL && rem_len > 0) {
rxcb = ATH11K_SKB_RXCB(skb);
@ -36,7 +36,7 @@ Signed-off-by: Sarika Sharma <quic_sarishar@quicinc.com>
buf_len = DP_RX_BUFFER_SIZE - hal_rx_desc_sz;
else
buf_len = rem_len;
@@ -2268,7 +2270,7 @@ static int ath11k_dp_rx_msdu_coalesce(st
@@ -2269,7 +2271,7 @@ static int ath11k_dp_rx_msdu_coalesce(st
dev_kfree_skb_any(skb);
rem_len -= buf_len;

View File

@ -12,7 +12,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
--- a/drivers/net/wireless/ath/ath11k/debugfs.c
+++ b/drivers/net/wireless/ath/ath11k/debugfs.c
@@ -668,6 +668,7 @@ static ssize_t ath11k_write_extd_rx_stat
@@ -669,6 +669,7 @@ static ssize_t ath11k_write_extd_rx_stat
}
ar->debug.rx_filter = tlv_filter.rx_filter;
@ -20,7 +20,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
for (i = 0; i < ab->hw_params.num_rxmda_per_pdev; i++) {
ring_id = ar->dp.rx_mon_status_refill_ring[i].refill_buf_ring.ring_id;
@@ -1228,6 +1229,7 @@ static ssize_t ath11k_write_pktlog_filte
@@ -1229,6 +1230,7 @@ static ssize_t ath11k_write_pktlog_filte
}
/* Clear rx filter set for monitor mode and rx status */
@ -179,7 +179,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
#define HTT_RX_FULL_MON_MODE_CFG_CMD_INFO0_MSG_TYPE GENMASK(7, 0)
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -73,6 +73,12 @@ static inline bool ath11k_dp_rx_h_mpdu_s
@@ -74,6 +74,12 @@ static inline bool ath11k_dp_rx_h_mpdu_s
return ab->hw_params.hw_ops->rx_desc_get_mpdu_fc_valid(desc);
}
@ -192,7 +192,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
static inline bool ath11k_dp_rx_h_mpdu_start_more_frags(struct ath11k_base *ab,
struct sk_buff *skb)
{
@@ -309,6 +315,35 @@ static u8 *ath11k_dp_rxdesc_mpdu_start_a
@@ -310,6 +316,35 @@ static u8 *ath11k_dp_rxdesc_mpdu_start_a
return ab->hw_params.hw_ops->rx_desc_mpdu_start_addr2(desc);
}
@ -228,7 +228,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
static void ath11k_dp_service_mon_ring(struct timer_list *t)
{
struct ath11k_base *ab = from_timer(ab, t, mon_reap_timer);
@@ -2389,6 +2424,49 @@ int ath11k_dp_rx_crypto_icv_len(struct a
@@ -2390,6 +2425,49 @@ int ath11k_dp_rx_crypto_icv_len(struct a
return 0;
}
@ -278,7 +278,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
static void ath11k_dp_rx_h_undecap_nwifi(struct ath11k *ar,
struct sk_buff *msdu,
u8 *first_hdr,
@@ -2402,7 +2480,8 @@ static void ath11k_dp_rx_h_undecap_nwifi
@@ -2403,7 +2481,8 @@ static void ath11k_dp_rx_h_undecap_nwifi
u8 da[ETH_ALEN];
u8 sa[ETH_ALEN];
u16 qos_ctl = 0;
@ -288,7 +288,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
/* copy SA & DA and pull decapped header */
hdr = (struct ieee80211_hdr *)msdu->data;
@@ -2411,7 +2490,7 @@ static void ath11k_dp_rx_h_undecap_nwifi
@@ -2412,7 +2491,7 @@ static void ath11k_dp_rx_h_undecap_nwifi
ether_addr_copy(sa, ieee80211_get_SA(hdr));
skb_pull(msdu, ieee80211_hdrlen(hdr->frame_control));
@ -297,7 +297,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
/* original 802.11 header is valid for the first msdu
* hence we can reuse the same header
*/
@@ -2441,16 +2520,23 @@ static void ath11k_dp_rx_h_undecap_nwifi
@@ -2442,16 +2521,23 @@ static void ath11k_dp_rx_h_undecap_nwifi
/* copy decap header before overwriting for reuse below */
memcpy(decap_hdr, (uint8_t *)hdr, hdr_len);
@ -326,7 +326,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
memcpy(skb_push(msdu,
IEEE80211_QOS_CTL_LEN), &qos_ctl,
IEEE80211_QOS_CTL_LEN);
@@ -2566,6 +2652,20 @@ static void ath11k_dp_rx_h_undecap_eth(s
@@ -2567,6 +2653,20 @@ static void ath11k_dp_rx_h_undecap_eth(s
u8 da[ETH_ALEN];
u8 sa[ETH_ALEN];
void *rfc1042;
@ -347,7 +347,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
rfc1042 = ath11k_dp_rx_h_find_rfc1042(ar, msdu, enctype);
if (WARN_ON_ONCE(!rfc1042))
@@ -2594,6 +2694,7 @@ static void ath11k_dp_rx_h_undecap_eth(s
@@ -2595,6 +2695,7 @@ static void ath11k_dp_rx_h_undecap_eth(s
memcpy(skb_push(msdu, hdr_len), hdr, hdr_len);
@ -355,7 +355,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
/* original 802.11 header has a different DA and in
* case of 4addr it may also have different SA
*/
@@ -2612,6 +2713,7 @@ static void ath11k_dp_rx_h_undecap_snap(
@@ -2613,6 +2714,7 @@ static void ath11k_dp_rx_h_undecap_snap(
size_t hdr_len;
u8 l3_pad_bytes;
struct hal_rx_desc *rx_desc;
@ -363,7 +363,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
/* Delivered decapped frame:
* [amsdu header] <-- replaced with 802.11 hdr
@@ -2625,6 +2727,11 @@ static void ath11k_dp_rx_h_undecap_snap(
@@ -2626,6 +2728,11 @@ static void ath11k_dp_rx_h_undecap_snap(
skb_put(msdu, l3_pad_bytes);
skb_pull(msdu, sizeof(struct ath11k_dp_amsdu_subframe_hdr) + l3_pad_bytes);
@ -375,7 +375,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
hdr = (struct ieee80211_hdr *)first_hdr;
hdr_len = ieee80211_hdrlen(hdr->frame_control);
@@ -3098,6 +3205,20 @@ static int ath11k_dp_rx_process_msdu(str
@@ -3099,6 +3206,20 @@ static int ath11k_dp_rx_process_msdu(str
goto free_out;
}
@ -396,7 +396,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
rxcb = ATH11K_SKB_RXCB(msdu);
rxcb->rx_desc = rx_desc;
msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(ab, rx_desc);
@@ -3110,8 +3231,9 @@ static int ath11k_dp_rx_process_msdu(str
@@ -3111,8 +3232,9 @@ static int ath11k_dp_rx_process_msdu(str
hdr_status = ath11k_dp_rx_h_80211_hdr(ab, rx_desc);
ret = -EINVAL;
ath11k_warn(ab, "invalid msdu len %u\n", msdu_len);
@ -408,7 +408,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
ath11k_dbg_dump(ab, ATH11K_DBG_DATA, NULL, "", rx_desc,
sizeof(struct hal_rx_desc));
goto free_out;
@@ -4070,6 +4192,7 @@ static int ath11k_dp_rx_h_verify_tkip_mi
@@ -4072,6 +4194,7 @@ static int ath11k_dp_rx_h_verify_tkip_mi
hdr = (struct ieee80211_hdr *)(msdu->data + hal_rx_desc_sz);
hdr_len = ieee80211_hdrlen(hdr->frame_control);
@ -416,7 +416,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
head_len = hdr_len + hal_rx_desc_sz + IEEE80211_TKIP_IV_LEN;
tail_len = IEEE80211_CCMP_MIC_LEN + IEEE80211_TKIP_ICV_LEN + FCS_LEN;
@@ -4350,8 +4473,8 @@ static void ath11k_dp_rx_h_sort_frags(st
@@ -4352,8 +4475,8 @@ static void ath11k_dp_rx_h_sort_frags(st
static u64 ath11k_dp_rx_h_get_pn(struct ath11k *ar, struct sk_buff *skb)
{
@ -426,7 +426,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
u8 *ehdr;
u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz;
@@ -4581,8 +4704,9 @@ ath11k_dp_process_rx_err_buf(struct ath1
@@ -4583,8 +4706,9 @@ ath11k_dp_process_rx_err_buf(struct ath1
if ((msdu_len + hal_rx_desc_sz) > DP_RX_BUFFER_SIZE) {
hdr_status = ath11k_dp_rx_h_80211_hdr(ar->ab, rx_desc);
ath11k_warn(ar->ab, "invalid msdu leng %u", msdu_len);
@ -438,7 +438,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
ath11k_dbg_dump(ar->ab, ATH11K_DBG_DATA, NULL, "", rx_desc,
sizeof(struct hal_rx_desc));
dev_kfree_skb_any(msdu);
@@ -5207,6 +5331,47 @@ void ath11k_dp_rx_pdev_free(struct ath11
@@ -5209,6 +5333,47 @@ void ath11k_dp_rx_pdev_free(struct ath11
ath11k_dp_rxdma_pdev_buf_free(ar);
}
@ -486,7 +486,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
int ath11k_dp_rx_pdev_alloc(struct ath11k_base *ab, int mac_id)
{
struct ath11k *ar = ab->pdevs[mac_id].ar;
@@ -5300,6 +5465,12 @@ config_refill_ring:
@@ -5302,6 +5467,12 @@ config_refill_ring:
}
}
@ -914,7 +914,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
struct ath11k_hw_ring_mask {
u8 tx[ATH11K_EXT_IRQ_GRP_NUM_MAX];
u8 rx_mon_status[ATH11K_EXT_IRQ_GRP_NUM_MAX];
@@ -287,6 +297,16 @@ struct ath11k_hw_ops {
@@ -288,6 +298,16 @@ struct ath11k_hw_ops {
u8* (*rx_desc_mpdu_start_addr2)(struct hal_rx_desc *desc);
u32 (*get_ring_selector)(struct sk_buff *skb);
u32 (*rx_desc_get_hal_mpdu_len)(struct hal_rx_mpdu_info *mpdu_info);
@ -933,7 +933,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
extern const struct ath11k_hw_ops ipq8074_ops;
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -6448,6 +6448,7 @@ static int ath11k_mac_config_mon_status_
@@ -6438,6 +6438,7 @@ static int ath11k_mac_config_mon_status_
tlv_filter.rx_filter = ath11k_debugfs_rx_filter(ar);
}
@ -943,7 +943,7 @@ Signed-off-by: Ramya Gnanasekar <rgnanase@codeaurora.org>
ret = ath11k_dp_tx_htt_rx_filter_setup(ar->ab, ring_id,
--- a/drivers/net/wireless/ath/ath11k/rx_desc.h
+++ b/drivers/net/wireless/ath/ath11k/rx_desc.h
@@ -1507,4 +1507,17 @@ struct hal_rx_desc {
@@ -1508,4 +1508,17 @@ struct hal_rx_desc {
#define RU_484 18
#define RU_996 37

View File

@ -28,7 +28,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
}
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -3385,18 +3385,16 @@ try_again:
@@ -3386,18 +3386,16 @@ try_again:
ar = ab->pdevs[mac_id].ar;
rx_ring = &ar->dp.rx_refill_buf_ring;
spin_lock_bh(&rx_ring->idr_lock);
@ -50,7 +50,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
dma_unmap_single(ab->dev, rxcb->paddr,
msdu->len + skb_tailroom(msdu),
DMA_FROM_DEVICE);
@@ -4667,17 +4665,14 @@ ath11k_dp_process_rx_err_buf(struct ath1
@@ -4669,17 +4667,14 @@ ath11k_dp_process_rx_err_buf(struct ath1
u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz;
spin_lock_bh(&rx_ring->idr_lock);
@ -70,7 +70,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
rxcb = ATH11K_SKB_RXCB(msdu);
dma_unmap_single(ar->ab->dev, rxcb->paddr,
msdu->len + skb_tailroom(msdu),
@@ -5083,18 +5078,16 @@ int ath11k_dp_rx_process_wbm_err(struct
@@ -5085,18 +5080,16 @@ int ath11k_dp_rx_process_wbm_err(struct
rx_ring = &ar->dp.rx_refill_buf_ring;
spin_lock_bh(&rx_ring->idr_lock);
@ -92,7 +92,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
dma_unmap_single(ab->dev, rxcb->paddr,
msdu->len + skb_tailroom(msdu),
DMA_FROM_DEVICE);
@@ -5209,16 +5202,14 @@ int ath11k_dp_process_rxdma_err(struct a
@@ -5211,16 +5204,14 @@ int ath11k_dp_process_rxdma_err(struct a
msdu_cookies[i]);
spin_lock_bh(&rx_ring->idr_lock);
@ -111,7 +111,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
rxcb = ATH11K_SKB_RXCB(skb);
dma_unmap_single(ab->dev, rxcb->paddr,
@@ -6423,16 +6414,14 @@ ath11k_dp_rx_full_mon_mpdu_pop(struct at
@@ -6425,16 +6416,14 @@ ath11k_dp_rx_full_mon_mpdu_pop(struct at
msdu_list.sw_cookie[i]);
spin_lock_bh(&rx_ring->idr_lock);

View File

@ -18,7 +18,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/core.h
+++ b/drivers/net/wireless/ath/ath11k/core.h
@@ -662,6 +662,11 @@ struct ath11k_per_peer_tx_stats {
@@ -700,6 +700,11 @@ struct ath11k_per_peer_tx_stats {
#define ATH11K_FLUSH_TIMEOUT (5 * HZ)
#define ATH11K_VDEV_DELETE_TIMEOUT_HZ (5 * HZ)
@ -30,17 +30,17 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
struct ath11k {
struct ath11k_base *ab;
struct ath11k_pdev *pdev;
@@ -811,6 +816,7 @@ struct ath11k {
/* protected by conf_mutex */
@@ -849,6 +854,7 @@ struct ath11k {
bool ps_state_enable;
bool ps_timekeeper_enable;
s8 max_allowed_tx_power;
+ struct ath11k_rx_buf_id rx_buf_id;
};
struct ath11k_band_cap {
--- a/drivers/net/wireless/ath/ath11k/dp.c
+++ b/drivers/net/wireless/ath/ath11k/dp.c
@@ -897,7 +897,7 @@ int ath11k_dp_service_srng(struct ath11k
@@ -911,7 +911,7 @@ int ath11k_dp_service_srng(struct ath11k
hal_params = ab->hw_params.hal_params;
ath11k_dp_rxbufs_replenish(ab, id, rx_ring, 0,
@ -51,7 +51,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
}
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -388,7 +388,8 @@ static inline u8 ath11k_dp_rx_h_msdu_sta
@@ -389,7 +389,8 @@ static inline u8 ath11k_dp_rx_h_msdu_sta
int ath11k_dp_rxbufs_replenish(struct ath11k_base *ab, int mac_id,
struct dp_rxdma_ring *rx_ring,
int req_entries,
@ -61,7 +61,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
{
struct hal_srng *srng;
u32 *desc;
@@ -396,9 +397,15 @@ int ath11k_dp_rxbufs_replenish(struct at
@@ -397,9 +398,15 @@ int ath11k_dp_rxbufs_replenish(struct at
int num_free;
int num_remain;
int buf_id;
@ -77,7 +77,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
req_entries = min(req_entries, rx_ring->bufs_max);
srng = &ab->hal.srng_list[rx_ring->refill_buf_ring.ring_id];
@@ -434,8 +441,14 @@ int ath11k_dp_rxbufs_replenish(struct at
@@ -435,8 +442,14 @@ int ath11k_dp_rxbufs_replenish(struct at
goto fail_free_skb;
spin_lock_bh(&rx_ring->idr_lock);
@ -92,7 +92,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
spin_unlock_bh(&rx_ring->idr_lock);
if (buf_id <= 0)
goto fail_dma_unmap;
@@ -458,6 +471,12 @@ int ath11k_dp_rxbufs_replenish(struct at
@@ -459,6 +472,12 @@ int ath11k_dp_rxbufs_replenish(struct at
spin_unlock_bh(&srng->lock);
@ -105,7 +105,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
return req_entries - num_remain;
fail_idr_remove:
@@ -532,7 +551,7 @@ static int ath11k_dp_rxdma_ring_buf_setu
@@ -533,7 +552,7 @@ static int ath11k_dp_rxdma_ring_buf_setu
rx_ring->bufs_max = num_entries;
ath11k_dp_rxbufs_replenish(ar->ab, dp->mac_id, rx_ring, num_entries,
@ -114,7 +114,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
return 0;
}
@@ -3347,11 +3366,14 @@ int ath11k_dp_process_rx(struct ath11k_b
@@ -3348,11 +3367,14 @@ int ath11k_dp_process_rx(struct ath11k_b
struct ath11k *ar;
struct hal_reo_dest_ring *desc;
enum hal_reo_dest_ring_push_reason push_reason;
@ -130,7 +130,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
srng = &ab->hal.srng_list[dp->reo_dst_ring[ring_id].ring_id];
@@ -3384,8 +3406,15 @@ try_again:
@@ -3385,8 +3407,15 @@ try_again:
ar = ab->pdevs[mac_id].ar;
rx_ring = &ar->dp.rx_refill_buf_ring;
@ -147,7 +147,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
spin_unlock_bh(&rx_ring->idr_lock);
if (unlikely(!msdu)) {
ath11k_warn(ab, "frame rx with invalid buf_id %d\n",
@@ -3463,9 +3492,12 @@ try_again:
@@ -3464,9 +3493,12 @@ try_again:
rx_ring = &ar->dp.rx_refill_buf_ring;
ath11k_dp_rxbufs_replenish(ab, i, rx_ring, num_buffs_reaped[i],
@ -161,7 +161,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
return total_msdu_reaped;
}
@@ -4827,7 +4859,7 @@ exit:
@@ -4829,7 +4861,7 @@ exit:
rx_ring = &ar->dp.rx_refill_buf_ring;
ath11k_dp_rxbufs_replenish(ab, i, rx_ring, n_bufs_reaped[i],
@ -170,7 +170,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
}
return tot_n_bufs_reaped;
@@ -5043,14 +5075,17 @@ int ath11k_dp_rx_process_wbm_err(struct
@@ -5045,14 +5077,17 @@ int ath11k_dp_rx_process_wbm_err(struct
struct sk_buff *msdu;
struct sk_buff_head msdu_list[MAX_RADIOS];
struct ath11k_skb_rxcb *rxcb;
@ -189,7 +189,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
srng = &ab->hal.srng_list[dp->rx_rel_ring.ring_id];
@@ -5076,9 +5111,15 @@ int ath11k_dp_rx_process_wbm_err(struct
@@ -5078,9 +5113,15 @@ int ath11k_dp_rx_process_wbm_err(struct
ar = ab->pdevs[mac_id].ar;
rx_ring = &ar->dp.rx_refill_buf_ring;
@ -206,7 +206,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
spin_unlock_bh(&rx_ring->idr_lock);
if (!msdu) {
ath11k_warn(ab, "frame rx with invalid buf_id %d pdev %d\n",
@@ -5123,7 +5164,7 @@ int ath11k_dp_rx_process_wbm_err(struct
@@ -5125,7 +5166,7 @@ int ath11k_dp_rx_process_wbm_err(struct
rx_ring = &ar->dp.rx_refill_buf_ring;
ath11k_dp_rxbufs_replenish(ab, i, rx_ring, num_buffs_reaped[i],
@ -215,7 +215,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
}
rcu_read_lock();
@@ -5145,6 +5186,8 @@ int ath11k_dp_rx_process_wbm_err(struct
@@ -5147,6 +5188,8 @@ int ath11k_dp_rx_process_wbm_err(struct
}
rcu_read_unlock();
done:
@ -224,7 +224,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
return total_num_buffs_reaped;
}
@@ -5230,7 +5273,7 @@ int ath11k_dp_process_rxdma_err(struct a
@@ -5232,7 +5275,7 @@ int ath11k_dp_process_rxdma_err(struct a
if (num_buf_freed)
ath11k_dp_rxbufs_replenish(ab, mac_id, rx_ring, num_buf_freed,
@ -233,7 +233,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
return budget - quota;
}
@@ -6176,12 +6219,12 @@ static void ath11k_dp_rx_mon_dest_proces
@@ -6178,12 +6221,12 @@ static void ath11k_dp_rx_mon_dest_proces
ath11k_dp_rxbufs_replenish(ar->ab, dp->mac_id,
&dp->rxdma_mon_buf_ring,
rx_bufs_used,
@ -248,7 +248,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
}
}
@@ -6691,7 +6734,7 @@ next_entry:
@@ -6693,7 +6736,7 @@ next_entry:
ath11k_dp_rxbufs_replenish(ar->ab, dp->mac_id,
&dp->rxdma_mon_buf_ring,
rx_bufs_used,

View File

@ -35,7 +35,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/dp_rx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_rx.c
@@ -2454,16 +2454,27 @@ static void ath11k_get_dot11_hdr_from_rx
@@ -2455,16 +2455,27 @@ static void ath11k_get_dot11_hdr_from_rx
size_t hdr_len, crypto_len;
struct ieee80211_hdr *hdr;
u16 fc, qos_ctl = 0;
@ -63,7 +63,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
skb_push(msdu, hdr_len);
hdr = (struct ieee80211_hdr *)msdu->data;
hdr->frame_control = fc;
@@ -2499,6 +2510,7 @@ static void ath11k_dp_rx_h_undecap_nwifi
@@ -2500,6 +2511,7 @@ static void ath11k_dp_rx_h_undecap_nwifi
u8 da[ETH_ALEN];
u8 sa[ETH_ALEN];
u16 qos_ctl = 0;
@ -71,7 +71,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
u8 *qos, *crypto_hdr;
bool add_qos_ctrl = false;
@@ -2543,26 +2555,46 @@ static void ath11k_dp_rx_h_undecap_nwifi
@@ -2544,26 +2556,46 @@ static void ath11k_dp_rx_h_undecap_nwifi
}
if (!(status->flag & RX_FLAG_IV_STRIPPED)) {
@ -123,7 +123,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
memcpy(skb_push(msdu, hdr_len), hdr, hdr_len);
/* original 802.11 header has a different DA and in
@@ -2671,6 +2703,7 @@ static void ath11k_dp_rx_h_undecap_eth(s
@@ -2672,6 +2704,7 @@ static void ath11k_dp_rx_h_undecap_eth(s
u8 da[ETH_ALEN];
u8 sa[ETH_ALEN];
void *rfc1042;
@ -131,7 +131,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
struct ath11k_skb_rxcb *rxcb = ATH11K_SKB_RXCB(msdu);
struct ath11k_dp_rfc1042_hdr rfc = {0xaa, 0xaa, 0x03, {0x00, 0x00, 0x00}};
@@ -2680,6 +2713,11 @@ static void ath11k_dp_rx_h_undecap_eth(s
@@ -2681,6 +2714,11 @@ static void ath11k_dp_rx_h_undecap_eth(s
ether_addr_copy(sa, eth->h_source);
rfc.snap_type = eth->h_proto;
skb_pull(msdu, sizeof(struct ethhdr));
@ -143,7 +143,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
memcpy(skb_push(msdu, sizeof(struct ath11k_dp_rfc1042_hdr)), &rfc,
sizeof(struct ath11k_dp_rfc1042_hdr));
ath11k_get_dot11_hdr_from_rx_desc(ar, msdu, rxcb, status, enctype);
@@ -2697,6 +2735,11 @@ static void ath11k_dp_rx_h_undecap_eth(s
@@ -2698,6 +2736,11 @@ static void ath11k_dp_rx_h_undecap_eth(s
skb_pull(msdu, sizeof(struct ethhdr));
/* push rfc1042/llc/snap */
@ -155,7 +155,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
memcpy(skb_push(msdu, sizeof(struct ath11k_dp_rfc1042_hdr)), rfc1042,
sizeof(struct ath11k_dp_rfc1042_hdr));
@@ -2705,12 +2748,22 @@ static void ath11k_dp_rx_h_undecap_eth(s
@@ -2706,12 +2749,22 @@ static void ath11k_dp_rx_h_undecap_eth(s
hdr_len = ieee80211_hdrlen(hdr->frame_control);
if (!(status->flag & RX_FLAG_IV_STRIPPED)) {
@ -182,7 +182,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
memcpy(skb_push(msdu, hdr_len), hdr, hdr_len);
exit:
@@ -2731,6 +2784,7 @@ static void ath11k_dp_rx_h_undecap_snap(
@@ -2732,6 +2785,7 @@ static void ath11k_dp_rx_h_undecap_snap(
struct ieee80211_hdr *hdr;
size_t hdr_len;
u8 l3_pad_bytes;
@ -190,7 +190,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
struct hal_rx_desc *rx_desc;
struct ath11k_skb_rxcb *rxcb = ATH11K_SKB_RXCB(msdu);
@@ -2755,12 +2809,22 @@ static void ath11k_dp_rx_h_undecap_snap(
@@ -2756,12 +2810,22 @@ static void ath11k_dp_rx_h_undecap_snap(
hdr_len = ieee80211_hdrlen(hdr->frame_control);
if (!(status->flag & RX_FLAG_IV_STRIPPED)) {
@ -217,7 +217,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
memcpy(skb_push(msdu, hdr_len), hdr, hdr_len);
}
@@ -2889,7 +2953,7 @@ static void ath11k_dp_rx_h_mpdu(struct a
@@ -2890,7 +2954,7 @@ static void ath11k_dp_rx_h_mpdu(struct a
struct ieee80211_rx_status *rx_status,
bool *fast_rx)
{
@ -226,7 +226,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
enum hal_encrypt_type enctype;
bool is_decrypted = false;
struct ath11k_skb_rxcb *rxcb;
@@ -3122,10 +3186,16 @@ static void ath11k_dp_rx_deliver_msdu(st
@@ -3123,10 +3187,16 @@ static void ath11k_dp_rx_deliver_msdu(st
u8 decap = DP_RX_DECAP_TYPE_RAW;
bool is_mcbc = rxcb->is_mcbc;
bool is_eapol = rxcb->is_eapol;
@ -243,7 +243,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
he = skb_push(msdu, sizeof(known));
memcpy(he, &known, sizeof(known));
status->flag |= RX_FLAG_RADIOTAP_HE;
@@ -3181,6 +3251,7 @@ static void ath11k_dp_rx_deliver_msdu(st
@@ -3182,6 +3252,7 @@ static void ath11k_dp_rx_deliver_msdu(st
!(is_mcbc && rx_status->flag & RX_FLAG_DECRYPTED))
rx_status->flag |= RX_FLAG_8023;

View File

@ -20,7 +20,7 @@ Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -1601,27 +1601,6 @@ static int ath11k_mac_setup_bcn_tmpl(str
@@ -1594,27 +1594,6 @@ static int ath11k_mac_setup_bcn_tmpl(str
return ath11k_mac_setup_bcn_tmpl_mbssid(arvif);
}
@ -32,7 +32,7 @@ Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
- return;
-
- if (vif->bss_conf.color_change_active &&
- ieee80211_beacon_cntdwn_is_complete(vif)) {
- ieee80211_beacon_cntdwn_is_complete(vif, 0)) {
- arvif->bcca_zero_sent = true;
- ieee80211_color_change_finish(vif);
- return;
@ -41,7 +41,7 @@ Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
- arvif->bcca_zero_sent = false;
-
- if (vif->bss_conf.color_change_active)
- ieee80211_beacon_update_cntdwn(vif);
- ieee80211_beacon_update_cntdwn(vif, 0);
- ath11k_mac_setup_bcn_tmpl(arvif);
-}
-
@ -50,7 +50,7 @@ Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
{
--- a/drivers/net/wireless/ath/ath11k/mac.h
+++ b/drivers/net/wireless/ath/ath11k/mac.h
@@ -170,7 +170,6 @@ enum ath11k_supported_bw ath11k_mac_mac8
@@ -171,7 +171,6 @@ enum ath11k_supported_bw ath11k_mac_mac8
enum hal_encrypt_type ath11k_dp_tx_get_encrypt_type(u32 cipher);
void ath11k_mac_handle_beacon(struct ath11k *ar, struct sk_buff *skb);
void ath11k_mac_handle_beacon_miss(struct ath11k *ar, u32 vdev_id);
@ -72,7 +72,7 @@ Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
}
cmd->buf_len = bcn->len;
@@ -7586,7 +7587,6 @@ static void ath11k_bcn_tx_status_event(s
@@ -7567,7 +7568,6 @@ static void ath11k_bcn_tx_status_event(s
rcu_read_unlock();
return;
}
@ -80,7 +80,7 @@ Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
rcu_read_unlock();
}
@@ -8500,10 +8500,7 @@ ath11k_wmi_process_csa_switch_count_even
@@ -8481,10 +8481,7 @@ ath11k_wmi_process_csa_switch_count_even
{
int i;
struct ath11k_vif *arvif;
@ -92,19 +92,19 @@ Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
rcu_read_lock();
for (i = 0; i < ev->num_vdevs; i++) {
@@ -8515,8 +8512,18 @@ ath11k_wmi_process_csa_switch_count_even
@@ -8496,8 +8493,18 @@ ath11k_wmi_process_csa_switch_count_even
continue;
}
- if (arvif->is_up && arvif->vif->bss_conf.csa_active)
- ieee80211_csa_finish(arvif->vif);
- ieee80211_csa_finish(arvif->vif, 0);
+ bss_conf = &arvif->vif->bss_conf;
+ if (arvif->is_up && (bss_conf->csa_active || bss_conf->color_change_active)) {
+ if (!ev->current_switch_count) {
+ if (bss_conf->csa_active)
+ ieee80211_csa_finish(arvif->vif);
+ ieee80211_csa_finish(arvif->vif, 0);
+ } else if (ev->current_switch_count > 1) {
+ ieee80211_beacon_update_cntdwn(arvif->vif);
+ ieee80211_beacon_update_cntdwn(arvif->vif, 0);
+ } else {
+ if (bss_conf->color_change_active)
+ ieee80211_color_change_finish(arvif->vif);

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath11k/ahb.c
+++ b/drivers/net/wireless/ath/ath11k/ahb.c
@@ -494,8 +494,7 @@ static int ath11k_ahb_ext_grp_napi_poll(
@@ -495,8 +495,7 @@ static int ath11k_ahb_ext_grp_napi_poll(
int work_done;
work_done = ath11k_dp_service_srng(ab, irq_grp, budget);
@ -10,7 +10,7 @@
ath11k_ahb_ext_grp_enable(irq_grp);
}
@@ -526,6 +525,7 @@ static int ath11k_ahb_config_ext_irq(str
@@ -527,6 +526,7 @@ static int ath11k_ahb_config_ext_irq(str
int irq;
int ret;
bool nss_offload;
@ -18,7 +18,7 @@
/* TCL Completion, REO Dest, ERR, Exception and h2rxdma rings are offloaded
* to nss when its enabled, hence don't enable these interrupts
@@ -539,8 +539,12 @@ static int ath11k_ahb_config_ext_irq(str
@@ -540,8 +540,12 @@ static int ath11k_ahb_config_ext_irq(str
irq_grp->ab = ab;
irq_grp->grp_id = i;
init_dummy_netdev(&irq_grp->napi_ndev);
@ -31,7 +31,7 @@
for (j = 0; j < ATH11K_EXT_IRQ_NUM_MAX; j++) {
if (!nss_offload && ab->hw_params.ring_mask->tx[i] & BIT(j)) {
@@ -604,6 +608,8 @@ static int ath11k_ahb_config_ext_irq(str
@@ -605,6 +609,8 @@ static int ath11k_ahb_config_ext_irq(str
}
}
@ -42,7 +42,7 @@
--- a/drivers/net/wireless/ath/ath11k/pcic.c
+++ b/drivers/net/wireless/ath/ath11k/pcic.c
@@ -505,8 +505,7 @@ static int ath11k_pcic_ext_grp_napi_poll
@@ -516,8 +516,7 @@ static int ath11k_pcic_ext_grp_napi_poll
int i;
work_done = ath11k_dp_service_srng(ab, irq_grp, budget);
@ -52,7 +52,7 @@
for (i = 0; i < irq_grp->num_irq; i++)
enable_irq(irq_grp->ab->irq_num[irq_grp->irqs[i]]);
}
@@ -550,6 +549,7 @@ static int ath11k_pcic_ext_irq_config(st
@@ -561,6 +560,7 @@ static int ath11k_pcic_ext_irq_config(st
int i, j, ret, num_vectors = 0;
u32 user_base_data = 0, base_vector = 0;
unsigned long irq_flags;
@ -60,7 +60,7 @@
ret = ath11k_pcic_get_user_msi_assignment(ab, "DP", &num_vectors,
&user_base_data,
@@ -568,8 +568,12 @@ static int ath11k_pcic_ext_irq_config(st
@@ -579,8 +579,12 @@ static int ath11k_pcic_ext_irq_config(st
irq_grp->ab = ab;
irq_grp->grp_id = i;
init_dummy_netdev(&irq_grp->napi_ndev);
@ -73,7 +73,7 @@
/* tcl, reo, rx_err, wbm release, rxdma rings are offloaded to nss. */
if (ab->nss.enabled &&
@@ -616,6 +620,8 @@ static int ath11k_pcic_ext_irq_config(st
@@ -627,6 +631,8 @@ static int ath11k_pcic_ext_irq_config(st
ath11k_pcic_ext_grp_disable(irq_grp);
}

View File

@ -1,134 +0,0 @@
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -9247,7 +9247,7 @@ void cfg80211_bss_flush(struct wiphy *wi
* @count: the number of TBTTs until the color change happens
* @color_bitmap: representations of the colors that the local BSS is aware of
*/
-int cfg80211_bss_color_notify(struct net_device *dev,
+int cfg80211_bss_color_notify(struct net_device *dev, gfp_t gfp,
enum nl80211_commands cmd, u8 count,
u64 color_bitmap);
@@ -9257,9 +9257,9 @@ int cfg80211_bss_color_notify(struct net
* @color_bitmap: representations of the colors that the local BSS is aware of
*/
static inline int cfg80211_obss_color_collision_notify(struct net_device *dev,
- u64 color_bitmap)
+ u64 color_bitmap, gfp_t gfp)
{
- return cfg80211_bss_color_notify(dev, NL80211_CMD_OBSS_COLOR_COLLISION,
+ return cfg80211_bss_color_notify(dev, gfp, NL80211_CMD_OBSS_COLOR_COLLISION,
0, color_bitmap);
}
@@ -9273,7 +9273,7 @@ static inline int cfg80211_obss_color_co
static inline int cfg80211_color_change_started_notify(struct net_device *dev,
u8 count)
{
- return cfg80211_bss_color_notify(dev, NL80211_CMD_COLOR_CHANGE_STARTED,
+ return cfg80211_bss_color_notify(dev, GFP_KERNEL, NL80211_CMD_COLOR_CHANGE_STARTED,
count, 0);
}
@@ -9285,7 +9285,7 @@ static inline int cfg80211_color_change_
*/
static inline int cfg80211_color_change_aborted_notify(struct net_device *dev)
{
- return cfg80211_bss_color_notify(dev, NL80211_CMD_COLOR_CHANGE_ABORTED,
+ return cfg80211_bss_color_notify(dev, GFP_KERNEL, NL80211_CMD_COLOR_CHANGE_ABORTED,
0, 0);
}
@@ -9297,7 +9297,7 @@ static inline int cfg80211_color_change_
*/
static inline int cfg80211_color_change_notify(struct net_device *dev)
{
- return cfg80211_bss_color_notify(dev,
+ return cfg80211_bss_color_notify(dev, GFP_KERNEL,
NL80211_CMD_COLOR_CHANGE_COMPLETED,
0, 0);
}
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -4779,7 +4779,7 @@ void ieee80211_color_collision_detection
struct ieee80211_sub_if_data *sdata = link->sdata;
sdata_lock(sdata);
- cfg80211_obss_color_collision_notify(sdata->dev, link->color_bitmap);
+ cfg80211_obss_color_collision_notify(sdata->dev, link->color_bitmap, GFP_KERNEL);
sdata_unlock(sdata);
}
--- a/net/mac80211/debugfs_netdev.c
+++ b/net/mac80211/debugfs_netdev.c
@@ -889,7 +889,7 @@ void ieee80211_debugfs_add_netdev(struct
{
char buf[10+IFNAMSIZ];
- sprintf(buf, "netdev:%s", sdata->name);
+ snprintf(buf, 10 + IFNAMSIZ, "netdev:%s", sdata->name);
sdata->vif.debugfs_dir = debugfs_create_dir(buf,
sdata->local->hw.wiphy->debugfsdir);
sdata->debugfs.subdir_stations = debugfs_create_dir("stations",
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
@@ -1414,18 +1414,6 @@ static void __sta_info_destroy_part2(str
WARN_ON_ONCE(ret);
}
- /* Flush queues before removing keys, as that might remove them
- * from hardware, and then depending on the offload method, any
- * frames sitting on hardware queues might be sent out without
- * any encryption at all.
- */
- if (local->ops->set_key) {
- if (local->ops->flush_sta)
- drv_flush_sta(local, sta->sdata, sta);
- else
- ieee80211_flush_queues(local, sta->sdata, false);
- }
-
/* now keys can no longer be reached */
ieee80211_free_sta_keys(local, sta);
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -19484,7 +19484,7 @@ void cfg80211_ch_switch_started_notify(s
}
EXPORT_SYMBOL(cfg80211_ch_switch_started_notify);
-int cfg80211_bss_color_notify(struct net_device *dev,
+int cfg80211_bss_color_notify(struct net_device *dev, gfp_t gfp,
enum nl80211_commands cmd, u8 count,
u64 color_bitmap)
{
@@ -19498,7 +19498,7 @@ int cfg80211_bss_color_notify(struct net
trace_cfg80211_bss_color_notify(dev, cmd, count, color_bitmap);
- msg = nlmsg_new(NLMSG_DEFAULT_SIZE, GFP_KERNEL);
+ msg = nlmsg_new(NLMSG_DEFAULT_SIZE, gfp);
if (!msg)
return -ENOMEM;
@@ -19521,7 +19521,7 @@ int cfg80211_bss_color_notify(struct net
genlmsg_end(msg, hdr);
return genlmsg_multicast_netns(&nl80211_fam, wiphy_net(&rdev->wiphy),
- msg, 0, NL80211_MCGRP_MLME, GFP_KERNEL);
+ msg, 0, NL80211_MCGRP_MLME, gfp);
nla_put_failure:
nlmsg_free(msg);
--- a/backport-include/linux/netdevice.h
+++ b/backport-include/linux/netdevice.h
@@ -70,6 +70,9 @@ static inline void netif_trans_update(st
(_dev)->needs_free_netdev = true;
#endif
+#define netdev_tstats(dev) dev->tstats
+#define netdev_assign_tstats(dev, e) dev->tstats = (e);
+
#if LINUX_VERSION_IS_LESS(4,15,0)
static inline int _bp_netdev_upper_dev_link(struct net_device *dev,
struct net_device *upper_dev)

View File

@ -1,6 +1,6 @@
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -4689,8 +4689,7 @@ netdev_tx_t ieee80211_subif_start_xmit_8
@@ -4716,8 +4716,7 @@ netdev_tx_t ieee80211_subif_start_xmit_8
if (!key)
key = rcu_dereference(sdata->default_unicast_key);

View File

@ -14,9 +14,20 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
net/mac80211/util.c | 16 ++++++++++++++++
3 files changed, 30 insertions(+)
--- a/backport-include/linux/netdevice.h
+++ b/backport-include/linux/netdevice.h
@@ -4,6 +4,8 @@
#include <linux/version.h>
#include <backport/magic.h>
+#define netdev_tstats(dev) dev->tstats
+
#if LINUX_VERSION_IS_LESS(4,15,0)
static inline int _bp_netdev_upper_dev_link(struct net_device *dev,
struct net_device *upper_dev)
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -380,6 +380,20 @@ enum ieee80211_bss_change {
@@ -404,6 +404,20 @@ enum ieee80211_bss_change {
/* when adding here, make sure to change ieee80211_reconfig */
};
@ -37,7 +48,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
/*
* The maximum number of IPv4 addresses listed for ARP filtering. If the number
* of addresses for an interface increase beyond this value, hardware ARP
@@ -683,6 +697,7 @@ struct ieee80211_fils_discovery {
@@ -703,6 +717,7 @@ struct ieee80211_fils_discovery {
* beamformee
* @eht_mu_beamformer: in AP-mode, does this BSS enable operation as an EHT MU
* beamformer
@ -45,7 +56,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
*/
struct ieee80211_bss_conf {
struct ieee80211_vif *vif;
@@ -776,6 +791,7 @@ struct ieee80211_bss_conf {
@@ -795,6 +810,7 @@ struct ieee80211_bss_conf {
bool eht_su_beamformer;
bool eht_su_beamformee;
bool eht_mu_beamformer;
@ -53,7 +64,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
};
/**
@@ -1413,7 +1429,7 @@ ieee80211_tx_info_clear_status(struct ie
@@ -1445,7 +1461,7 @@ ieee80211_tx_info_clear_status(struct ie
* @RX_FLAG_AMPDU_EOF_BIT_KNOWN: The EOF value is known
* @RX_FLAG_RADIOTAP_HE: HE radiotap data is present
* (&struct ieee80211_radiotap_he, mac80211 will fill in
@ -62,7 +73,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
* - DATA3_DATA_MCS
* - DATA3_DATA_DCM
* - DATA3_CODING
@@ -1421,7 +1437,7 @@ ieee80211_tx_info_clear_status(struct ie
@@ -1453,7 +1469,7 @@ ieee80211_tx_info_clear_status(struct ie
* - DATA5_DATA_BW_RU_ALLOC
* - DATA6_NSTS
* - DATA3_STBC
@ -71,8 +82,8 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
* from the RX info data, so leave those zeroed when building this data)
* @RX_FLAG_RADIOTAP_HE_MU: HE MU radiotap data is present
* (&struct ieee80211_radiotap_he_mu)
@@ -1996,6 +2012,16 @@ static inline bool lockdep_vif_mutex_hel
lockdep_vif_mutex_held(vif))
@@ -2084,6 +2100,16 @@ static inline bool lockdep_vif_wiphy_mut
lockdep_vif_wiphy_mutex_held(vif))
/**
+ * ieee80211_vif_to_wdev_relaxed - return a wdev struct from a vif
@ -88,24 +99,24 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
* enum ieee80211_key_flags - key flags
*
* These flags are used for communication about keys between the driver
@@ -2687,6 +2713,8 @@ struct ieee80211_txq {
* @IEEE80211_HW_MLO_MCAST_MULTI_LINK_TX: Hardware/driver handles transmitting
* multicast frames on all links, mac80211 should not do that.
@@ -2788,6 +2814,8 @@ struct ieee80211_txq {
* implements MLO, so operation can continue on other links when one
* link is switching.
*
+ * @IEEE80211_HW_SUPPORTS_NSS_OFFLOAD: Hardware/driver supports NSS offload
+ *
* @NUM_IEEE80211_HW_FLAGS: number of hardware flags, used for sizing arrays
*/
enum ieee80211_hw_flags {
@@ -2744,6 +2772,7 @@ enum ieee80211_hw_flags {
IEEE80211_HW_SUPPORTS_CONC_MON_RX_DECAP,
IEEE80211_HW_DETECTS_COLOR_COLLISION,
@@ -2847,6 +2875,7 @@ enum ieee80211_hw_flags {
IEEE80211_HW_MLO_MCAST_MULTI_LINK_TX,
IEEE80211_HW_DISALLOW_PUNCTURING,
IEEE80211_HW_HANDLES_QUIET_CSA,
+ IEEE80211_HW_SUPPORTS_NSS_OFFLOAD,
/* keep last, obviously */
NUM_IEEE80211_HW_FLAGS
@@ -3756,6 +3785,10 @@ struct ieee80211_prep_tx_info {
@@ -3860,6 +3889,10 @@ struct ieee80211_prep_tx_info {
* non-MLO connections.
* The callback can sleep.
*
@ -116,7 +127,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
* @prepare_multicast: Prepare for multicast filter configuration.
* This callback is optional, and its return value is passed
* to configure_filter(). This callback must be atomic.
@@ -4307,7 +4340,9 @@ struct ieee80211_ops {
@@ -4425,7 +4458,9 @@ struct ieee80211_ops {
struct ieee80211_vif *vif,
struct ieee80211_bss_conf *info,
u64 changed);
@ -127,7 +138,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
int (*start_ap)(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
struct ieee80211_bss_conf *link_conf);
void (*stop_ap)(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
@@ -4612,7 +4647,7 @@ struct ieee80211_ops {
@@ -4735,7 +4770,7 @@ struct ieee80211_ops {
int (*reset_tid_config)(struct ieee80211_hw *hw,
struct ieee80211_vif *vif,
struct ieee80211_sta *sta, u8 tids);
@ -138,17 +149,17 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
struct ieee80211_sta *sta, bool enabled);
--- a/net/mac80211/debugfs.c
+++ b/net/mac80211/debugfs.c
@@ -505,6 +505,7 @@ static const char *hw_flag_names[] = {
FLAG(SUPPORTS_CONC_MON_RX_DECAP),
FLAG(DETECTS_COLOR_COLLISION),
@@ -508,6 +508,7 @@ static const char *hw_flag_names[] = {
FLAG(MLO_MCAST_MULTI_LINK_TX),
FLAG(DISALLOW_PUNCTURING),
FLAG(HANDLES_QUIET_CSA),
+ FLAG(SUPPORTS_NSS_OFFLOAD),
#undef FLAG
};
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -868,6 +868,22 @@ struct wireless_dev *ieee80211_vif_to_wd
@@ -874,6 +874,22 @@ struct wireless_dev *ieee80211_vif_to_wd
}
EXPORT_SYMBOL_GPL(ieee80211_vif_to_wdev);
@ -173,7 +184,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
* the suspend->resume cycle. Since we can't check each caller
--- a/net/mac80211/main.c
+++ b/net/mac80211/main.c
@@ -291,6 +291,17 @@ void ieee80211_link_info_change_notify(s
@@ -413,6 +413,17 @@ void ieee80211_link_info_change_notify(s
drv_link_info_changed(local, sdata, link->conf, link->link_id, changed);
}
@ -191,7 +202,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
u64 ieee80211_reset_erp_info(struct ieee80211_sub_if_data *sdata)
{
sdata->vif.bss_conf.use_cts_prot = false;
@@ -691,12 +702,6 @@ struct ieee80211_hw *ieee80211_alloc_hw_
@@ -844,12 +855,6 @@ struct ieee80211_hw *ieee80211_alloc_hw_
NL80211_FEATURE_FULL_AP_CLIENT_STATE;
wiphy_ext_feature_set(wiphy, NL80211_EXT_FEATURE_FILS_STA);
wiphy_ext_feature_set(wiphy,
@ -204,7 +215,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
NL80211_EXT_FEATURE_SCAN_FREQ_KHZ);
wiphy_ext_feature_set(wiphy,
NL80211_EXT_FEATURE_POWERED_ADDR_CHANGE);
@@ -1005,6 +1010,18 @@ int ieee80211_register_hw(struct ieee802
@@ -1180,6 +1185,18 @@ int ieee80211_register_hw(struct ieee802
return -EINVAL;
}
@ -225,7 +236,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
return -EINVAL;
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
@@ -2390,6 +2390,9 @@ sta_get_last_rx_stats(struct sta_info *s
@@ -2416,6 +2416,9 @@ sta_get_last_rx_stats(struct sta_info *s
struct ieee80211_sta_rx_stats *stats = &sta->deflink.rx_stats;
int cpu;
@ -237,7 +248,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -1029,11 +1029,23 @@ ieee80211_tx_h_stats(struct ieee80211_tx
@@ -1027,11 +1027,23 @@ ieee80211_tx_h_stats(struct ieee80211_tx
{
struct sk_buff *skb;
int ac = -1;
@ -261,26 +272,29 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ac = skb_get_queue_mapping(skb);
tx->sta->deflink.tx_stats.bytes[ac] += skb->len;
}
@@ -2858,7 +2870,9 @@ static struct sk_buff *ieee80211_build_h
if (unlikely(!multicast && ((skb->sk &&
skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS) ||
- ctrl_flags & IEEE80211_TX_CTL_REQ_TX_STATUS)))
@@ -2877,7 +2889,9 @@ static struct sk_buff *ieee80211_build_h
if (unlikely(!multicast &&
((skb->sk &&
skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS) ||
- ctrl_flags & IEEE80211_TX_CTL_REQ_TX_STATUS)))
+ ctrl_flags & IEEE80211_TX_CTL_REQ_TX_STATUS) &&
+ !(ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD) &&
+ ieee80211_is_data(fc) && !ieee80211_is_qos_nullfunc(fc))))
info_id = ieee80211_store_ack_skb(local, skb, &info_flags,
cookie);
@@ -4642,13 +4656,16 @@ static void ieee80211_8023_xmit(struct i
@@ -4666,7 +4680,8 @@ static void ieee80211_8023_xmit(struct i
}
if (unlikely(skb->sk &&
- skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS))
- skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS)) {
+ skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS &&
+ !ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD)))
info->ack_frame_id = ieee80211_store_ack_skb(local, skb,
&info->flags, NULL);
+ !ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD))) {
info->status_data = ieee80211_store_ack_skb(local, skb,
&info->flags, NULL);
if (info->status_data)
@@ -4674,8 +4689,10 @@ static void ieee80211_8023_xmit(struct i
}
dev_sw_netstats_tx_add(dev, skbs, len);
- sta->deflink.tx_stats.packets[queue] += skbs;
@ -294,7 +308,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
--- a/net/wireless/util.c
+++ b/net/wireless/util.c
@@ -2447,6 +2447,9 @@ bool cfg80211_does_bw_fit_range(const st
@@ -2627,6 +2627,9 @@ bool cfg80211_does_bw_fit_range(const st
int cfg80211_sinfo_alloc_tid_stats(struct station_info *sinfo, gfp_t gfp)
{
@ -306,7 +320,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
gfp);
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -2678,7 +2678,7 @@ static int ieee80211_change_bss(struct w
@@ -2676,7 +2676,7 @@ static int ieee80211_change_bss(struct w
struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
struct ieee80211_link_data *link;
struct ieee80211_supported_band *sband;
@ -315,7 +329,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
link = ieee80211_link_or_deflink(sdata, params->link_id, true);
if (IS_ERR(link))
@@ -2728,6 +2728,8 @@ static int ieee80211_change_bss(struct w
@@ -2726,6 +2726,8 @@ static int ieee80211_change_bss(struct w
sdata->flags |= IEEE80211_SDATA_DONT_BRIDGE_PACKETS;
else
sdata->flags &= ~IEEE80211_SDATA_DONT_BRIDGE_PACKETS;
@ -324,7 +338,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
ieee80211_check_fast_rx_iface(sdata);
}
@@ -2756,6 +2758,8 @@ static int ieee80211_change_bss(struct w
@@ -2754,6 +2756,8 @@ static int ieee80211_change_bss(struct w
ieee80211_link_info_change_notify(sdata, link, changed);
@ -335,7 +349,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -172,6 +172,23 @@ void drv_link_info_changed(struct ieee80
@@ -180,6 +180,23 @@ void drv_link_info_changed(struct ieee80
struct ieee80211_bss_conf *info,
int link_id, u64 changed);
@ -361,7 +375,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
{
--- a/net/mac80211/ieee80211_i.h
+++ b/net/mac80211/ieee80211_i.h
@@ -1844,6 +1844,8 @@ void ieee80211_vif_cfg_change_notify(str
@@ -1842,6 +1842,8 @@ void ieee80211_vif_cfg_change_notify(str
void ieee80211_link_info_change_notify(struct ieee80211_sub_if_data *sdata,
struct ieee80211_link_data *link,
u64 changed);
@ -372,7 +386,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
--- a/net/mac80211/trace.h
+++ b/net/mac80211/trace.h
@@ -389,6 +389,38 @@ TRACE_EVENT(drv_config,
@@ -412,6 +412,38 @@ TRACE_EVENT(drv_config,
LOCAL_PR_ARG, __entry->changed, CHANDEF_PR_ARG
)
);
@ -413,7 +427,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
TP_PROTO(struct ieee80211_local *local,
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@ -969,7 +969,8 @@ static bool ieee80211_set_sdata_offload_
@@ -982,7 +982,8 @@ static bool ieee80211_set_sdata_offload_
local->hw.wiphy->frag_threshold != (u32)-1)
flags &= ~IEEE80211_OFFLOAD_ENCAP_ENABLED;
@ -425,7 +439,7 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
flags &= ~IEEE80211_OFFLOAD_ENCAP_ENABLED;
--- a/net/mac80211/Kconfig
+++ b/net/mac80211/Kconfig
@@ -104,6 +104,15 @@ menuconfig MAC80211_DEBUG_MENU
@@ -115,6 +115,15 @@ menuconfig MAC80211_DEBUG_MENU
help
This option collects various mac80211 debug settings.
@ -443,11 +457,11 @@ Signed-off-by: Sriram R <srirrama@codeaurora.org>
depends on MAC80211_DEBUG_MENU
--- a/local-symbols
+++ b/local-symbols
@@ -65,6 +65,7 @@ MAC80211_MESH_PS_DEBUG=
@@ -59,6 +59,7 @@ MAC80211_MESH_PS_DEBUG=
MAC80211_TDLS_DEBUG=
MAC80211_DEBUG_COUNTERS=
MAC80211_STA_HASH_MAX_SIZE=
+MAC80211_NSS_SUPPORT=
QCOM_AOSS_QMP=
QCOM_COMMAND_DB=
QCOM_CPR=
QCOM_GENI_SE=

View File

@ -18,9 +18,9 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -6216,7 +6216,13 @@ start_xmit:
mutex_lock(&local->mtx);
@@ -6259,7 +6259,13 @@ int ieee80211_tx_control_port(struct wip
start_xmit:
local_bh_disable();
- __ieee80211_subif_start_xmit(skb, skb->dev, flags, ctrl_flags, cookie);
+
@ -32,4 +32,4 @@ Signed-off-by: P Praneesh <ppranees@codeaurora.org>
+
local_bh_enable();
mutex_unlock(&local->mtx);
return 0;

View File

@ -31,9 +31,9 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -9327,4 +9327,15 @@ bool cfg80211_valid_disable_subchannel_b
*/
void cfg80211_links_removed(struct net_device *dev, u16 link_mask);
@@ -9574,4 +9574,15 @@ ssize_t wiphy_locked_debugfs_write(struc
void *data);
#endif
+/**
+ * cfg80211_update_muedca_params_event - Notify the updated MU-EDCA parameters
@ -49,7 +49,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
#endif /* __NET_CFG80211_H */
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -7368,6 +7368,20 @@ u32 ieee80211_calc_rx_airtime(struct iee
@@ -7506,6 +7506,20 @@ u32 ieee80211_calc_rx_airtime(struct iee
int len);
/**
@ -72,9 +72,9 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
* This function calculates the estimated airtime usage of a frame based on the
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -1314,6 +1314,10 @@
* Multi-Link reconfiguration. %NL80211_ATTR_MLO_LINKS is used to provide
* information about the removed STA MLD setup links.
@@ -1334,6 +1334,10 @@
* %NL80211_ATTR_MLO_TTLM_ULINK attributes are used to specify the
* TID to Link mapping for downlink/uplink traffic.
*
+ * @NL80211_CMD_UPDATE_HE_MUEDCA_PARAMS: Updated MU-EDCA parameters from driver.
+ * This event is used to update dynamic MU-EDCA parameters in Beacon frame,
@ -83,26 +83,26 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
* @NL80211_CMD_MAX: highest used command number
* @__NL80211_CMD_AFTER_LAST: internal use
*/
@@ -1569,6 +1573,7 @@ enum nl80211_commands {
@@ -1591,6 +1595,7 @@ enum nl80211_commands {
NL80211_CMD_LINKS_REMOVED,
NL80211_CMD_SET_TID_TO_LINK_MAPPING,
+ NL80211_CMD_UPDATE_HE_MUEDCA_PARAMS,
/* add new commands above here */
/* used to define NL80211_CMD_MAX below */
@@ -2815,6 +2820,8 @@ enum nl80211_commands {
* @NL80211_ATTR_MLO_LINK_DISABLED: Flag attribute indicating that the link is
* disabled.
@@ -2868,6 +2873,8 @@ enum nl80211_commands {
* nested item, it contains attributes defined in
* &enum nl80211_if_combination_attrs.
*
+ * @NL80211_ATTR_HE_MUEDCA_PARAMS: MU-EDCA AC parameters for the
+ * %NL80211_CMD_UPDATE_HE_MUEDCA_PARAMS command.
* @NUM_NL80211_ATTR: total number of nl80211_attrs available
* @NL80211_ATTR_MAX: highest attribute number currently defined
* @__NL80211_ATTR_AFTER_LAST: internal use
@@ -3353,6 +3360,8 @@ enum nl80211_attrs {
NL80211_ATTR_MLO_LINK_DISABLED,
@@ -3416,6 +3423,8 @@ enum nl80211_attrs {
NL80211_ATTR_WIPHY_RADIOS,
NL80211_ATTR_WIPHY_INTERFACE_COMBINATIONS,
+ NL80211_ATTR_HE_MUEDCA_PARAMS,
+
@ -111,7 +111,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
__NL80211_ATTR_AFTER_LAST,
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -7954,3 +7954,15 @@ void ieee80211_disable_rssi_reports(stru
@@ -8727,3 +8727,15 @@ void ieee80211_disable_rssi_reports(stru
_ieee80211_enable_rssi_reports(sdata, 0, 0);
}
EXPORT_SYMBOL(ieee80211_disable_rssi_reports);
@ -129,7 +129,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
+EXPORT_SYMBOL(ieee80211_update_muedca_params);
--- a/net/mac80211/trace.h
+++ b/net/mac80211/trace.h
@@ -3092,6 +3092,26 @@ TRACE_EVENT(stop_queue,
@@ -3125,6 +3125,26 @@ TRACE_EVENT(stop_queue,
)
);
@ -153,22 +153,22 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
+ )
+);
+
#endif /* !__MAC80211_DRIVER_TRACE || TRACE_HEADER_MULTI_READ */
#undef TRACE_INCLUDE_PATH
TRACE_EVENT(drv_can_neg_ttlm,
TP_PROTO(struct ieee80211_local *local,
struct ieee80211_sub_if_data *sdata,
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -812,6 +812,7 @@ static const struct nla_policy nl80211_p
@@ -820,6 +820,7 @@ static const struct nla_policy nl80211_p
[NL80211_ATTR_HW_TIMESTAMP_ENABLED] = { .type = NLA_FLAG },
[NL80211_ATTR_EMA_RNR_ELEMS] = { .type = NLA_NESTED },
[NL80211_ATTR_MLO_LINK_DISABLED] = { .type = NLA_FLAG },
+ [NL80211_ATTR_HE_MUEDCA_PARAMS] = NLA_POLICY_EXACT_LEN(sizeof(struct ieee80211_mu_edca_param_set)),
};
/* policy for the key attributes */
@@ -20211,6 +20212,42 @@ nla_put_failure:
[NL80211_ATTR_BSS_DUMP_INCLUDE_USE_DATA] = { .type = NLA_FLAG },
[NL80211_ATTR_MLO_TTLM_DLINK] = NLA_POLICY_EXACT_LEN(sizeof(u16) * 8),
[NL80211_ATTR_MLO_TTLM_ULINK] = NLA_POLICY_EXACT_LEN(sizeof(u16) * 8),
@@ -20324,6 +20325,42 @@ void cfg80211_schedule_channels_check(st
}
EXPORT_SYMBOL(cfg80211_update_owe_info_event);
EXPORT_SYMBOL(cfg80211_schedule_channels_check);
+void cfg80211_update_muedca_params_event(struct wiphy *wiphy,
+ struct ieee80211_mu_edca_param_set
@ -211,7 +211,7 @@ Signed-off-by: Muna Sinada <msinada@codeaurora.org>
int __init nl80211_init(void)
--- a/net/wireless/trace.h
+++ b/net/wireless/trace.h
@@ -3805,6 +3805,46 @@ TRACE_EVENT(cfg80211_update_owe_info_eve
@@ -3809,6 +3809,46 @@ TRACE_EVENT(cfg80211_update_owe_info_eve
__entry->assoc_link_id, __entry->peer_mld_addr)
);

View File

@ -29,7 +29,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
/* misc utils */
static __le16 ieee80211_duration(struct ieee80211_tx_data *tx,
@@ -4271,6 +4274,8 @@ void __ieee80211_subif_start_xmit(struct
@@ -4293,6 +4296,8 @@ void __ieee80211_subif_start_xmit(struct
struct sta_info *sta;
struct sk_buff *next;
int len = skb->len;
@ -38,7 +38,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
if (unlikely(!ieee80211_sdata_running(sdata) || skb->len < ETH_HLEN)) {
kfree_skb(skb);
@@ -4292,6 +4297,19 @@ void __ieee80211_subif_start_xmit(struct
@@ -4314,6 +4319,19 @@ void __ieee80211_subif_start_xmit(struct
if (IS_ERR(sta))
sta = NULL;

View File

@ -40,7 +40,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
extern const struct cfg80211_ops mac80211_config_ops;
@@ -1120,6 +1123,9 @@ struct ieee80211_sub_if_data {
@@ -1171,6 +1174,9 @@ struct ieee80211_sub_if_data {
struct dentry *default_beacon_key;
} debugfs;
#endif
@ -65,9 +65,9 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
/**
* DOC: Interface list locking
*
@@ -752,6 +758,13 @@ static int ieee80211_stop(struct net_dev
cancel_work_sync(&sdata->activate_links_work);
@@ -763,6 +769,13 @@ static int ieee80211_stop(struct net_dev
ieee80211_stop_mbssid(sdata);
}
+#ifdef CPTCFG_MAC80211_NSS_SUPPORT
+ if (sdata->nssctx) {
@ -77,9 +77,9 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
+#endif
+
wiphy_lock(sdata->local->hw.wiphy);
ieee80211_do_stop(sdata, true);
wiphy_unlock(sdata->local->hw.wiphy);
@@ -1219,6 +1232,34 @@ void ieee80211_del_virtual_monitor(struc
wiphy_work_cancel(sdata->local->hw.wiphy, &sdata->activate_links_work);
@@ -1217,6 +1230,34 @@ void ieee80211_del_virtual_monitor(struc
kfree(sdata);
}
@ -114,7 +114,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
/*
* NOTE: Be very careful when changing this function, it must NOT return
* an error on interface type changes that have been pre-checked, so most
@@ -1450,6 +1491,21 @@ int ieee80211_do_open(struct wireless_de
@@ -1444,6 +1485,21 @@ int ieee80211_do_open(struct wireless_de
ieee80211_recalc_ps(local);
@ -138,7 +138,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
return 0;
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -2569,6 +2569,58 @@ static bool ieee80211_frame_allowed(stru
@@ -2606,6 +2606,58 @@ static bool ieee80211_frame_allowed(stru
return true;
}
@ -197,7 +197,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
static void ieee80211_deliver_skb_to_local_stack(struct sk_buff *skb,
struct ieee80211_rx_data *rx)
{
@@ -2608,11 +2660,15 @@ static void ieee80211_deliver_skb_to_loc
@@ -2645,11 +2697,15 @@ static void ieee80211_deliver_skb_to_loc
!ether_addr_equal(ehdr->h_dest, sdata->vif.addr)))
ether_addr_copy(ehdr->h_dest, sdata->vif.addr);
@ -215,7 +215,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -1727,6 +1727,16 @@ static bool ieee80211_tx_frags(struct ie
@@ -1725,6 +1725,16 @@ static bool ieee80211_tx_frags(struct ie
}
} else {
@ -232,7 +232,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
/*
* Since queue is stopped, queue up frames for
* later transmission from the tx-pending
@@ -4504,6 +4514,35 @@ static void ieee80211_mlo_multicast_tx(s
@@ -4526,6 +4536,35 @@ static void ieee80211_mlo_multicast_tx(s
kfree_skb(skb);
}
@ -268,7 +268,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
/**
* ieee80211_subif_start_xmit - netif start_xmit function for 802.3 vifs
* @skb: packet to be sent
@@ -4517,6 +4556,10 @@ netdev_tx_t ieee80211_subif_start_xmit(s
@@ -4541,6 +4580,10 @@ netdev_tx_t ieee80211_subif_start_xmit(s
struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
const struct ethhdr *eth = (void *)skb->data;
@ -279,7 +279,7 @@ Signed-off-by: Sowmiya Sree Elavalagan <ssreeela@codeaurora.org>
if (likely(!is_multicast_ether_addr(eth->h_dest)))
goto normal;
@@ -4703,6 +4746,9 @@ netdev_tx_t ieee80211_subif_start_xmit_8
@@ -4730,6 +4773,9 @@ netdev_tx_t ieee80211_subif_start_xmit_8
struct ieee80211_key *key;
struct sta_info *sta;

View File

@ -21,7 +21,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -5105,6 +5105,17 @@ void ieee80211_sta_pspoll(struct ieee802
@@ -5234,6 +5234,17 @@ void ieee80211_sta_pspoll(struct ieee802
*/
void ieee80211_sta_uapsd_trigger(struct ieee80211_sta *sta, u8 tid);
@ -41,7 +41,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
* This is enough for the radiotap header.
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -2180,7 +2180,13 @@ static int ieee80211_change_station(stru
@@ -2189,7 +2189,13 @@ static int ieee80211_change_station(stru
rcu_assign_pointer(vlansdata->u.vlan.sta, sta);
__ieee80211_check_fast_rx_iface(vlansdata);
@ -58,9 +58,9 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
if (sta->sdata->vif.type == NL80211_IFTYPE_AP_VLAN &&
--- a/net/mac80211/driver-ops.c
+++ b/net/mac80211/driver-ops.c
@@ -59,10 +59,9 @@ int drv_add_interface(struct ieee80211_l
@@ -62,10 +62,9 @@ int drv_add_interface(struct ieee80211_l
might_sleep();
lockdep_assert_wiphy(local->hw.wiphy);
- if (WARN_ON(sdata->vif.type == NL80211_IFTYPE_AP_VLAN ||
- (sdata->vif.type == NL80211_IFTYPE_MONITOR &&
@ -73,7 +73,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
trace_drv_add_interface(local, sdata);
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@ -676,6 +676,9 @@ static void ieee80211_do_stop(struct iee
@@ -686,6 +686,9 @@ static void ieee80211_do_stop(struct iee
switch (sdata->vif.type) {
case NL80211_IFTYPE_AP_VLAN:
@ -83,7 +83,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
break;
case NL80211_IFTYPE_MONITOR:
if (local->monitors == 0)
@@ -960,6 +963,7 @@ static bool ieee80211_iftype_supports_hd
@@ -973,6 +976,7 @@ static bool ieee80211_iftype_supports_hd
switch (iftype) {
/* P2P GO and client are mapped to AP/STATION types */
case NL80211_IFTYPE_AP:
@ -91,7 +91,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
case NL80211_IFTYPE_STATION:
return true;
default:
@@ -1014,7 +1018,8 @@ static void ieee80211_set_vif_encap_ops(
@@ -1027,7 +1031,8 @@ static void ieee80211_set_vif_encap_ops(
struct ieee80211_sub_if_data *bss = sdata;
bool enabled;
@ -101,7 +101,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
if (!sdata->bss)
return;
@@ -1359,10 +1364,17 @@ int ieee80211_do_open(struct wireless_de
@@ -1353,10 +1358,17 @@ int ieee80211_do_open(struct wireless_de
switch (sdata->vif.type) {
case NL80211_IFTYPE_AP_VLAN:
@ -122,7 +122,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
netif_carrier_off(dev);
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -1656,6 +1656,12 @@ void ieee80211_sta_uapsd_trigger(struct
@@ -1683,6 +1683,12 @@ void ieee80211_sta_uapsd_trigger(struct
}
EXPORT_SYMBOL(ieee80211_sta_uapsd_trigger);
@ -137,7 +137,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
{
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -4308,8 +4308,11 @@ void __ieee80211_subif_start_xmit(struct
@@ -4330,8 +4330,11 @@ void __ieee80211_subif_start_xmit(struct
sta = NULL;
if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN) {
@ -151,7 +151,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
if (ap_sdata->vif.offload_flags & IEEE80211_OFFLOAD_ENCAP_ENABLED &&
!is_multicast_ether_addr(skb->data)) {
if (sta)
@@ -4699,7 +4702,8 @@ static void ieee80211_8023_xmit(struct i
@@ -4723,7 +4726,8 @@ static void ieee80211_8023_xmit(struct i
info->hw_queue = sdata->vif.hw_queue[queue];
@ -163,17 +163,17 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -2410,6 +2410,9 @@ static void ieee80211_assign_chanctx(str
if (!local->use_chanctx)
return;
@@ -1664,6 +1664,9 @@ static void ieee80211_assign_chanctx(str
lockdep_assert_wiphy(local->hw.wiphy);
+ if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN)
+ return;
+
mutex_lock(&local->chanctx_mtx);
conf = rcu_dereference_protected(link->conf->chanctx_conf,
lockdep_is_held(&local->chanctx_mtx));
@@ -2615,7 +2618,8 @@ int ieee80211_reconfig(struct ieee80211_
lockdep_is_held(&local->hw.wiphy->mtx));
if (conf) {
@@ -1869,7 +1872,8 @@ int ieee80211_reconfig(struct ieee80211_
}
list_for_each_entry(sdata, &local->interfaces, list) {
@ -183,7 +183,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
sdata->vif.type != NL80211_IFTYPE_MONITOR &&
ieee80211_sdata_running(sdata)) {
res = drv_add_interface(local, sdata);
@@ -2630,7 +2634,8 @@ int ieee80211_reconfig(struct ieee80211_
@@ -1884,7 +1888,8 @@ int ieee80211_reconfig(struct ieee80211_
if (res) {
list_for_each_entry_continue_reverse(sdata, &local->interfaces,
list)
@ -195,7 +195,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
drv_remove_interface(local, sdata);
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -5259,7 +5259,8 @@ static bool ieee80211_assoc_success(stru
@@ -5297,7 +5297,8 @@ static bool ieee80211_assoc_success(stru
* If we're using 4-addr mode, let the AP know that we're
* doing so, so that it can create the STA VLAN on its side
*/
@ -207,9 +207,9 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
/*
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -1457,7 +1457,9 @@ static inline void drv_sta_set_4addr(str
struct ieee80211_sub_if_data *sdata,
struct ieee80211_sta *sta, bool enabled)
@@ -619,7 +619,9 @@ static inline void drv_sta_rate_tbl_upda
struct ieee80211_sub_if_data *sdata,
struct ieee80211_sta *sta)
{
- sdata = get_bss_sdata(sdata);
+ if (!ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD))

View File

@ -24,7 +24,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -2093,6 +2093,8 @@ enum ieee80211_key_flags {
@@ -2184,6 +2184,8 @@ enum ieee80211_key_flags {
* @tx_pn: PN used for TX keys, may be used by the driver as well if it
* needs to do software PN assignment by itself (e.g. due to TSO)
* @flags: key flags, see &enum ieee80211_key_flags.
@ -33,7 +33,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
* @keyidx: the key index (0-3)
* @keylen: key material length
* @key: key material. For ALG_TKIP the key is encoded as a 256-bit (32 byte)
@@ -2112,6 +2114,7 @@ struct ieee80211_key_conf {
@@ -2203,6 +2205,7 @@ struct ieee80211_key_conf {
u8 hw_key_idx;
s8 keyidx;
u16 flags;
@ -43,7 +43,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
u8 key[];
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -538,6 +538,7 @@ static int ieee80211_add_key(struct wiph
@@ -535,6 +535,7 @@ static int ieee80211_add_key(struct wiph
break;
case NL80211_IFTYPE_AP:
case NL80211_IFTYPE_AP_VLAN:
@ -53,9 +53,9 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
key->conf.flags |= IEEE80211_KEY_FLAG_RX_MGMT;
--- a/net/mac80211/driver-ops.c
+++ b/net/mac80211/driver-ops.c
@@ -116,7 +116,11 @@ int drv_sta_state(struct ieee80211_local
@@ -134,7 +134,11 @@ int drv_sta_state(struct ieee80211_local
might_sleep();
lockdep_assert_wiphy(local->hw.wiphy);
- sdata = get_bss_sdata(sdata);
+ if (!ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD) ||
@ -68,9 +68,9 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -453,7 +453,9 @@ static inline int drv_sta_add(struct iee
@@ -474,7 +474,9 @@ static inline int drv_sta_add(struct iee
might_sleep();
lockdep_assert_wiphy(local->hw.wiphy);
- sdata = get_bss_sdata(sdata);
+ if (!ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD))
@ -81,7 +81,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
--- a/net/mac80211/key.c
+++ b/net/mac80211/key.c
@@ -166,7 +166,8 @@ static int ieee80211_key_enable_hw_accel
@@ -160,7 +160,8 @@ static int ieee80211_key_enable_hw_accel
if (sta && !sta->uploaded)
goto out_unsupported;
@ -91,7 +91,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
/*
* The driver doesn't know anything about VLAN interfaces.
* Hence, don't send GTKs for VLAN interfaces to the driver.
@@ -610,6 +611,8 @@ ieee80211_key_alloc(u32 cipher, int idx,
@@ -606,6 +607,8 @@ ieee80211_key_alloc(u32 cipher, int idx,
*/
key->conf.flags = 0;
key->flags = 0;
@ -102,7 +102,7 @@ Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
key->conf.cipher = cipher;
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -4658,16 +4658,25 @@ static void ieee80211_8023_xmit(struct i
@@ -4682,16 +4682,25 @@ static void ieee80211_8023_xmit(struct i
struct ieee80211_key *key, struct sk_buff *skb)
{
struct ieee80211_tx_info *info;

View File

@ -20,7 +20,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
--- a/net/mac80211/ieee80211_i.h
+++ b/net/mac80211/ieee80211_i.h
@@ -207,6 +207,7 @@ enum ieee80211_rx_flags {
@@ -216,6 +216,7 @@ enum ieee80211_rx_flags {
};
struct ieee80211_rx_data {
@ -30,7 +30,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
struct ieee80211_local *local;
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -4687,19 +4687,21 @@ static void ieee80211_8023_xmit(struct i
@@ -4711,19 +4711,21 @@ static void ieee80211_8023_xmit(struct i
ieee80211_aggr_check(sdata, sta, skb);
@ -64,7 +64,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
}
skb = ieee80211_tx_skb_fixup(skb, ieee80211_sdata_netdev_features(sdata));
@@ -4756,7 +4758,7 @@ netdev_tx_t ieee80211_subif_start_xmit_8
@@ -4783,7 +4785,7 @@ netdev_tx_t ieee80211_subif_start_xmit_8
{
struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
struct ethhdr *ehdr = (struct ethhdr *)skb->data;
@ -73,7 +73,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
struct sta_info *sta;
#ifdef CPTCFG_MAC80211_NSS_SUPPORT
@@ -4774,9 +4776,13 @@ netdev_tx_t ieee80211_subif_start_xmit_8
@@ -4801,9 +4803,13 @@ netdev_tx_t ieee80211_subif_start_xmit_8
goto out;
}
@ -90,7 +90,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
goto skip_offload;
key = rcu_dereference(sta->ptk[sta->ptk_idx]);
@@ -4787,6 +4793,7 @@ netdev_tx_t ieee80211_subif_start_xmit_8
@@ -4814,6 +4820,7 @@ netdev_tx_t ieee80211_subif_start_xmit_8
goto skip_offload;
sk_pacing_shift_update(skb->sk, sdata->local->hw.tx_sk_pacing_shift);
@ -98,9 +98,9 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
ieee80211_8023_xmit(sdata, dev, sta, key, skb);
goto out;
@@ -6293,13 +6300,7 @@ start_xmit:
mutex_lock(&local->mtx);
@@ -6336,13 +6343,7 @@ int ieee80211_tx_control_port(struct wip
start_xmit:
local_bh_disable();
-
- /* added hardware encap check for ethernet mode */
@ -112,4 +112,4 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
+ __ieee80211_subif_start_xmit(skb, skb->dev, flags, ctrl_flags, cookie);
local_bh_enable();
mutex_unlock(&local->mtx);
return 0;

View File

@ -48,7 +48,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
/**
* enum ieee80211_max_queues - maximum number of queues
*
@@ -387,11 +390,17 @@ enum ieee80211_bss_change {
@@ -411,11 +414,17 @@ enum ieee80211_bss_change {
* to indicate which NSS BSS parameter changed.
*
* @BSS_CHANGED_NSS_AP_ISOLATE: AP Isolate feature in NSS mode
@ -66,7 +66,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
};
/*
@@ -790,6 +799,11 @@ struct ieee80211_bss_conf {
@@ -809,6 +818,11 @@ struct ieee80211_bss_conf {
bool he_full_ul_mumimo;
bool eht_su_beamformer;
bool eht_su_beamformee;
@ -78,7 +78,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
bool eht_mu_beamformer;
bool nss_ap_isolate;
};
@@ -1275,6 +1289,8 @@ struct ieee80211_rate_status {
@@ -1302,6 +1316,8 @@ struct ieee80211_rate_status {
* @ack_hwtstamp: Hardware timestamp of the received ack in nanoseconds
* Only needed for Timing measurement and Fine timing measurement action
* frames. Only reported by devices that have timestamping enabled.
@ -87,7 +87,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
*/
struct ieee80211_tx_status {
struct ieee80211_sta *sta;
@@ -1285,6 +1301,8 @@ struct ieee80211_tx_status {
@@ -1312,6 +1328,8 @@ struct ieee80211_tx_status {
u8 n_rates;
struct list_head *free_list;
@ -96,31 +96,31 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
};
/**
@@ -1782,6 +1800,7 @@ struct ieee80211_channel_switch {
* this is not pure P2P vif.
* @IEEE80211_VIF_DISABLE_SMPS_OVERRIDE: disable user configuration of
* SMPS mode via debugfs.
@@ -1820,6 +1838,7 @@ struct ieee80211_channel_switch {
* operation on this interface and request a channel context without
* the AP definition. Use this e.g. because the device is able to
* handle OFDMA (downlink and trigger for uplink) on a per-AP basis.
+ * @IEEE80211_HW_NSS_OFFLOAD_DEBUG_MODE: It enables the debug mode of nss offload.
*/
enum ieee80211_vif_flags {
IEEE80211_VIF_BEACON_FILTER = BIT(0),
@@ -1789,6 +1808,7 @@ enum ieee80211_vif_flags {
IEEE80211_VIF_SUPPORTS_UAPSD = BIT(2),
@@ -1828,6 +1847,7 @@ enum ieee80211_vif_flags {
IEEE80211_VIF_GET_NOA_UPDATE = BIT(3),
IEEE80211_VIF_DISABLE_SMPS_OVERRIDE = BIT(4),
+ IEEE80211_VIF_NSS_OFFLOAD_DEBUG_MODE = BIT(5),
IEEE80211_VIF_EML_ACTIVE = BIT(4),
IEEE80211_VIF_IGNORE_OFDMA_WIDER_BW = BIT(5),
+ IEEE80211_VIF_NSS_OFFLOAD_DEBUG_MODE = BIT(6),
};
@@ -2776,6 +2796,7 @@ enum ieee80211_hw_flags {
IEEE80211_HW_DETECTS_COLOR_COLLISION,
IEEE80211_HW_MLO_MCAST_MULTI_LINK_TX,
@@ -2879,6 +2899,7 @@ enum ieee80211_hw_flags {
IEEE80211_HW_DISALLOW_PUNCTURING,
IEEE80211_HW_HANDLES_QUIET_CSA,
IEEE80211_HW_SUPPORTS_NSS_OFFLOAD,
+ IEEE80211_HW_SUPPORTS_MESH_NSS_OFFLOAD,
/* keep last, obviously */
NUM_IEEE80211_HW_FLAGS
@@ -4276,6 +4297,8 @@ struct ieee80211_prep_tx_info {
@@ -4388,6 +4409,8 @@ struct ieee80211_prep_tx_info {
* @set_sar_specs: Update the SAR (TX power) settings.
* @sta_set_decap_offload: Called to notify the driver when a station is allowed
* to use rx decapsulation offload
@ -129,7 +129,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
* @add_twt_setup: Update hw with TWT agreement parameters received from the peer.
* This callback allows the hw to check if requested parameters
* are supported and if there is enough room for a new agreement.
@@ -4659,6 +4682,12 @@ struct ieee80211_ops {
@@ -4782,6 +4805,12 @@ struct ieee80211_ops {
void (*sta_set_decap_offload)(struct ieee80211_hw *hw,
struct ieee80211_vif *vif,
struct ieee80211_sta *sta, bool enabled);
@ -142,9 +142,9 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
void (*add_twt_setup)(struct ieee80211_hw *hw,
struct ieee80211_sta *sta,
struct ieee80211_twt_setup *twt);
@@ -7517,4 +7546,100 @@ int ieee80211_set_active_links(struct ie
void ieee80211_set_active_links_async(struct ieee80211_vif *vif,
u16 active_links);
@@ -7667,4 +7696,100 @@ int ieee80211_emulate_switch_vif_chanctx
int n_vifs,
enum ieee80211_chanctx_switch_mode mode);
+/* Defines for Mesh NSS offload */
+
@ -245,7 +245,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
#endif /* MAC80211_H */
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -2522,6 +2522,7 @@ static int ieee80211_update_mesh_config(
@@ -2519,6 +2519,7 @@ static int ieee80211_update_mesh_config(
struct mesh_config *conf;
struct ieee80211_sub_if_data *sdata;
struct ieee80211_if_mesh *ifmsh;
@ -253,7 +253,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
sdata = IEEE80211_DEV_TO_SUB_IF(dev);
ifmsh = &sdata->u.mesh;
@@ -2538,8 +2539,11 @@ static int ieee80211_update_mesh_config(
@@ -2535,8 +2536,11 @@ static int ieee80211_update_mesh_config(
conf->dot11MeshMaxPeerLinks = nconf->dot11MeshMaxPeerLinks;
if (_chg_mesh_attr(NL80211_MESHCONF_MAX_RETRIES, mask))
conf->dot11MeshMaxRetries = nconf->dot11MeshMaxRetries;
@ -266,7 +266,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
if (_chg_mesh_attr(NL80211_MESHCONF_ELEMENT_TTL, mask))
conf->element_ttl = nconf->element_ttl;
if (_chg_mesh_attr(NL80211_MESHCONF_AUTO_OPEN_PLINKS, mask)) {
@@ -2553,8 +2557,12 @@ static int ieee80211_update_mesh_config(
@@ -2550,8 +2554,12 @@ static int ieee80211_update_mesh_config(
if (_chg_mesh_attr(NL80211_MESHCONF_HWMP_MAX_PREQ_RETRIES, mask))
conf->dot11MeshHWMPmaxPREQretries =
nconf->dot11MeshHWMPmaxPREQretries;
@ -280,7 +280,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
if (_chg_mesh_attr(NL80211_MESHCONF_MIN_DISCOVERY_TIMEOUT, mask))
conf->min_discovery_timeout = nconf->min_discovery_timeout;
if (_chg_mesh_attr(NL80211_MESHCONF_HWMP_ACTIVE_PATH_TIMEOUT, mask))
@@ -2589,8 +2597,12 @@ static int ieee80211_update_mesh_config(
@@ -2586,8 +2594,12 @@ static int ieee80211_update_mesh_config(
if (_chg_mesh_attr(NL80211_MESHCONF_HWMP_RANN_INTERVAL, mask))
conf->dot11MeshHWMPRannInterval =
nconf->dot11MeshHWMPRannInterval;
@ -294,7 +294,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
if (_chg_mesh_attr(NL80211_MESHCONF_RSSI_THRESHOLD, mask)) {
/* our RSSI threshold implementation is supported only for
* devices that report signal in dBm.
@@ -2632,6 +2644,7 @@ static int ieee80211_update_mesh_config(
@@ -2629,6 +2641,7 @@ static int ieee80211_update_mesh_config(
conf->dot11MeshConnectedToAuthServer =
nconf->dot11MeshConnectedToAuthServer;
ieee80211_mbss_info_change_notify(sdata, BSS_CHANGED_BEACON);
@ -317,7 +317,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
#ifdef CPTCFG_MAC80211_TDLS_DEBUG
#define MAC80211_TDLS_DEBUG 1
#else
@@ -215,6 +221,10 @@ do { \
@@ -216,6 +222,10 @@ do { \
_sdata_dbg(MAC80211_MESH_PS_DEBUG, \
sdata, fmt, ##__VA_ARGS__)
@ -330,9 +330,9 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
sdata, fmt, ##__VA_ARGS__)
--- a/net/mac80211/debugfs.c
+++ b/net/mac80211/debugfs.c
@@ -506,6 +506,7 @@ static const char *hw_flag_names[] = {
FLAG(DETECTS_COLOR_COLLISION),
FLAG(MLO_MCAST_MULTI_LINK_TX),
@@ -509,6 +509,7 @@ static const char *hw_flag_names[] = {
FLAG(DISALLOW_PUNCTURING),
FLAG(HANDLES_QUIET_CSA),
FLAG(SUPPORTS_NSS_OFFLOAD),
+ FLAG(SUPPORTS_MESH_NSS_OFFLOAD),
#undef FLAG
@ -340,7 +340,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
--- a/net/mac80211/driver-ops.c
+++ b/net/mac80211/driver-ops.c
@@ -579,3 +579,23 @@ int drv_change_sta_links(struct ieee8021
@@ -621,3 +621,23 @@ int drv_change_sta_links(struct ieee8021
return 0;
}
@ -364,22 +364,9 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
+ /* TODO: trace event */
+}
+#endif
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -1571,4 +1571,10 @@ int drv_change_sta_links(struct ieee8021
struct ieee80211_sta *sta,
u16 old_links, u16 new_links);
+#ifdef CPTCFG_MAC80211_MESH
+void drv_config_mesh_offload_path(struct ieee80211_local *local,
+ struct ieee80211_sub_if_data *sdata,
+ enum ieee80211_mesh_path_offld_cmd cmd,
+ struct ieee80211_mesh_path_offld *path);
+#endif /* CPTCFG_MAC80211_MESH */
#endif /* __MAC80211_DRIVER_OPS */
--- a/net/mac80211/mesh.h
+++ b/net/mac80211/mesh.h
@@ -320,6 +320,10 @@ void mesh_rx_path_sel_frame(struct ieee8
@@ -321,6 +321,10 @@ void mesh_rx_path_sel_frame(struct ieee8
struct ieee80211_mgmt *mgmt, size_t len);
struct mesh_path *
mesh_path_add(struct ieee80211_sub_if_data *sdata, const u8 *dst);
@ -390,7 +377,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
int mesh_path_add_gate(struct mesh_path *mpath);
int mesh_path_send_to_gates(struct mesh_path *mpath);
@@ -361,6 +365,7 @@ void mesh_path_discard_frame(struct ieee
@@ -362,6 +366,7 @@ void mesh_path_discard_frame(struct ieee
void mesh_path_tx_root_frame(struct ieee80211_sub_if_data *sdata);
bool mesh_action_is_path_sel(struct ieee80211_mgmt *mgmt);
@ -400,7 +387,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
struct ieee80211_mesh_fast_tx_key *key);
--- a/net/mac80211/mesh_hwmp.c
+++ b/net/mac80211/mesh_hwmp.c
@@ -365,6 +365,13 @@ u32 airtime_link_metric_get(struct ieee8
@@ -367,6 +367,13 @@ u32 airtime_link_metric_get(struct ieee8
return (u32)result;
}
@ -414,7 +401,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
/**
* hwmp_route_info_get - Update routing info to originator and transmitter
*
@@ -388,9 +395,10 @@ static u32 hwmp_route_info_get(struct ie
@@ -390,9 +397,10 @@ static u32 hwmp_route_info_get(struct ie
{
struct ieee80211_local *local = sdata->local;
struct mesh_path *mpath;
@ -426,7 +413,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
u32 orig_sn, orig_metric;
unsigned long orig_lifetime, exp_time;
u32 last_hop_metric, new_metric;
@@ -492,7 +500,10 @@ static u32 hwmp_route_info_get(struct ie
@@ -494,7 +502,10 @@ static u32 hwmp_route_info_get(struct ie
}
if (fresh_info) {
@ -438,7 +425,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
mpath->path_change_count++;
flush_mpath = true;
}
@@ -514,6 +525,8 @@ static u32 hwmp_route_info_get(struct ie
@@ -516,6 +527,8 @@ static u32 hwmp_route_info_get(struct ie
/* draft says preq_id should be saved to, but there does
* not seem to be any use for it, skipping by now
*/
@ -447,7 +434,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
} else
spin_unlock_bh(&mpath->state_lock);
}
@@ -544,7 +557,14 @@ static u32 hwmp_route_info_get(struct ie
@@ -546,7 +559,14 @@ static u32 hwmp_route_info_get(struct ie
}
if (fresh_info) {
@ -463,7 +450,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
mpath->path_change_count++;
flush_mpath = true;
}
@@ -561,6 +581,8 @@ static u32 hwmp_route_info_get(struct ie
@@ -563,6 +583,8 @@ static u32 hwmp_route_info_get(struct ie
/* init it at a low value - 0 start is tricky */
ewma_mesh_fail_avg_add(&sta->mesh->fail_avg, 1);
mesh_path_tx_pending(mpath);
@ -472,7 +459,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
} else
spin_unlock_bh(&mpath->state_lock);
}
@@ -697,15 +719,6 @@ static void hwmp_preq_frame_process(stru
@@ -699,15 +721,6 @@ static void hwmp_preq_frame_process(stru
}
}
@ -488,7 +475,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
static void hwmp_prep_frame_process(struct ieee80211_sub_if_data *sdata,
struct ieee80211_mgmt *mgmt,
const u8 *prep_elem, u32 metric)
@@ -1349,3 +1362,274 @@ void mesh_path_tx_root_frame(struct ieee
@@ -1351,3 +1364,274 @@ void mesh_path_tx_root_frame(struct ieee
return;
}
}
@ -765,7 +752,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
+EXPORT_SYMBOL(ieee80211_mesh_path_offld_change_notify);
--- a/net/mac80211/mesh_pathtbl.c
+++ b/net/mac80211/mesh_pathtbl.c
@@ -15,6 +15,7 @@
@@ -16,6 +16,7 @@
#include "ieee80211_i.h"
#include "mesh.h"
#include <linux/rhashtable.h>
@ -773,7 +760,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
static void mesh_path_free_rcu(struct mesh_table *tbl, struct mesh_path *mpath);
@@ -103,6 +104,63 @@ static void mesh_table_free(struct mesh_
@@ -104,6 +105,63 @@ static void mesh_table_free(struct mesh_
mesh_path_rht_free, tbl);
}
@ -837,7 +824,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
/**
* mesh_path_assign_nexthop - update mesh path next hop
*
@@ -240,16 +298,23 @@ static void mesh_path_move_to_queue(stru
@@ -241,16 +299,23 @@ static void mesh_path_move_to_queue(stru
static struct mesh_path *mpath_lookup(struct mesh_table *tbl, const u8 *dst,
@ -862,7 +849,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
}
return mpath;
}
@@ -266,13 +331,13 @@ static struct mesh_path *mpath_lookup(st
@@ -267,13 +332,13 @@ static struct mesh_path *mpath_lookup(st
struct mesh_path *
mesh_path_lookup(struct ieee80211_sub_if_data *sdata, const u8 *dst)
{
@ -878,7 +865,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
}
static struct mesh_path *
@@ -334,6 +399,7 @@ mpp_path_lookup_by_idx(struct ieee80211_
@@ -337,6 +402,7 @@ mpp_path_lookup_by_idx(struct ieee80211_
int mesh_path_add_gate(struct mesh_path *mpath)
{
struct mesh_table *tbl;
@ -886,7 +873,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
int err;
rcu_read_lock();
@@ -346,6 +412,7 @@ int mesh_path_add_gate(struct mesh_path
@@ -349,6 +415,7 @@ int mesh_path_add_gate(struct mesh_path
goto err_rcu;
}
mpath->is_gate = true;
@ -894,7 +881,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
mpath->sdata->u.mesh.num_gates++;
spin_lock(&tbl->gates_lock);
@@ -354,6 +421,8 @@ int mesh_path_add_gate(struct mesh_path
@@ -357,6 +424,8 @@ int mesh_path_add_gate(struct mesh_path
spin_unlock_bh(&mpath->state_lock);
@ -903,7 +890,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
mpath_dbg(mpath->sdata,
"Mesh path: Recorded new gate: %pM. %d known gates\n",
mpath->dst, mpath->sdata->u.mesh.num_gates);
@@ -370,16 +439,21 @@ err_rcu:
@@ -373,16 +442,21 @@ err_rcu:
*/
static void mesh_gate_del(struct mesh_table *tbl, struct mesh_path *mpath)
{
@ -925,7 +912,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
mpath_dbg(mpath->sdata,
"Mesh path: Deleted gate: %pM. %d known gates\n",
mpath->dst, mpath->sdata->u.mesh.num_gates);
@@ -667,17 +741,8 @@ void mesh_fast_tx_flush_addr(struct ieee
@@ -668,17 +742,8 @@ void mesh_fast_tx_flush_addr(struct ieee
spin_unlock_bh(&cache->walk_lock);
}
@ -945,7 +932,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
{
struct mesh_table *tbl;
struct mesh_path *mpath, *new_mpath;
@@ -718,8 +783,36 @@ struct mesh_path *mesh_path_add(struct i
@@ -719,8 +784,36 @@ struct mesh_path *mesh_path_add(struct i
return new_mpath;
}
@ -984,7 +971,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
{
struct mesh_table *tbl;
struct mesh_path *new_mpath;
@@ -757,6 +850,25 @@ int mpp_path_add(struct ieee80211_sub_if
@@ -758,6 +851,25 @@ int mpp_path_add(struct ieee80211_sub_if
return ret;
}
@ -1010,7 +997,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
/**
* mesh_plink_broken - deactivates paths and sends perr when a link breaks
@@ -807,8 +919,29 @@ static void mesh_path_free_rcu(struct me
@@ -808,8 +920,29 @@ static void mesh_path_free_rcu(struct me
kfree_rcu(mpath, rcu);
}
@ -1041,7 +1028,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
hlist_del_rcu(&mpath->walk_list);
rhashtable_remove_fast(&tbl->rhead, &mpath->rhash, mesh_rht_params);
if (tbl == &mpath->sdata->u.mesh.mpp_paths)
@@ -816,6 +949,11 @@ static void __mesh_path_del(struct mesh_
@@ -817,6 +950,11 @@ static void __mesh_path_del(struct mesh_
else
mesh_fast_tx_flush_mpath(mpath);
mesh_path_free_rcu(tbl, mpath);
@ -1053,7 +1040,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
}
/**
@@ -839,7 +977,7 @@ void mesh_path_flush_by_nexthop(struct s
@@ -840,7 +978,7 @@ void mesh_path_flush_by_nexthop(struct s
spin_lock_bh(&tbl->walk_lock);
hlist_for_each_entry_safe(mpath, n, &tbl->walk_head, walk_list) {
if (rcu_access_pointer(mpath->next_hop) == sta)
@ -1062,7 +1049,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
}
spin_unlock_bh(&tbl->walk_lock);
}
@@ -854,19 +992,19 @@ static void mpp_flush_by_proxy(struct ie
@@ -855,19 +993,19 @@ static void mpp_flush_by_proxy(struct ie
spin_lock_bh(&tbl->walk_lock);
hlist_for_each_entry_safe(mpath, n, &tbl->walk_head, walk_list) {
if (ether_addr_equal(mpath->mpp, proxy))
@ -1123,7 +1110,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
sdata->u.mesh.mesh_paths_generation++;
return err;
}
@@ -1031,7 +1169,10 @@ void mesh_path_flush_pending(struct mesh
@@ -1046,7 +1184,10 @@ void mesh_path_flush_pending(struct mesh
*/
void mesh_path_fix_nexthop(struct mesh_path *mpath, struct sta_info *next_hop)
{
@ -1134,7 +1121,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
mesh_path_assign_nexthop(mpath, next_hop);
mpath->sn = 0xffff;
mpath->metric = 0;
@@ -1045,6 +1186,8 @@ void mesh_path_fix_nexthop(struct mesh_p
@@ -1060,6 +1201,8 @@ void mesh_path_fix_nexthop(struct mesh_p
/* init it at a low value - 0 start is tricky */
ewma_mesh_fail_avg_add(&next_hop->mesh->fail_avg, 1);
mesh_path_tx_pending(mpath);
@ -1143,7 +1130,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
}
void mesh_pathtbl_init(struct ieee80211_sub_if_data *sdata)
@@ -1056,7 +1199,7 @@ void mesh_pathtbl_init(struct ieee80211_
@@ -1071,7 +1214,7 @@ void mesh_pathtbl_init(struct ieee80211_
static
void mesh_path_tbl_expire(struct ieee80211_sub_if_data *sdata,
@ -1152,7 +1139,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
{
struct mesh_path *mpath;
struct hlist_node *n;
@@ -1066,15 +1209,15 @@ void mesh_path_tbl_expire(struct ieee802
@@ -1081,15 +1224,15 @@ void mesh_path_tbl_expire(struct ieee802
if ((!(mpath->flags & MESH_PATH_RESOLVING)) &&
(!(mpath->flags & MESH_PATH_FIXED)) &&
time_after(jiffies, mpath->exp_time + MESH_PATH_EXPIRE))
@ -1173,7 +1160,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
void mesh_pathtbl_unregister(struct ieee80211_sub_if_data *sdata)
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -2620,7 +2620,7 @@ static struct sk_buff *ieee80211_build_h
@@ -2638,7 +2638,7 @@ static struct sk_buff *ieee80211_build_h
bool multicast;
u16 info_id = 0;
struct ieee80211_chanctx_conf *chanctx_conf = NULL;
@ -1182,7 +1169,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
int ret;
u8 link_id = u32_get_bits(ctrl_flags, IEEE80211_TX_CTRL_MLO_LINK);
@@ -2632,6 +2632,9 @@ static struct sk_buff *ieee80211_build_h
@@ -2650,6 +2650,9 @@ static struct sk_buff *ieee80211_build_h
info_flags |= IEEE80211_TX_CTL_REQ_TX_STATUS;
#endif
@ -1192,7 +1179,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
/* convert Ethernet header to proper 802.11 header (based on
* operation mode) */
ethertype = (skb->data[12] << 8) | skb->data[13];
@@ -2702,6 +2705,13 @@ static struct sk_buff *ieee80211_build_h
@@ -2720,6 +2723,13 @@ static struct sk_buff *ieee80211_build_h
break;
#ifdef CPTCFG_MAC80211_MESH
case NL80211_IFTYPE_MESH_POINT:
@ -1206,22 +1193,17 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
if (!is_multicast_ether_addr(skb->data)) {
struct sta_info *next_hop;
bool mpp_lookup = true;
@@ -2965,10 +2975,10 @@ static struct sk_buff *ieee80211_build_h
@@ -2984,6 +2994,9 @@ static struct sk_buff *ieee80211_build_h
skb_reset_mac_header(skb);
- info = IEEE80211_SKB_CB(skb);
- memset(info, 0, sizeof(*info));
-
- info->flags = info_flags;
+#ifdef CPTCFG_MAC80211_MESH
+nss_mesh:
+#endif
+ info->flags |= info_flags;
info->ack_frame_id = info_id;
info->band = band;
info = IEEE80211_SKB_CB(skb);
memset(info, 0, sizeof(*info));
@@ -4285,6 +4295,7 @@ void __ieee80211_subif_start_xmit(struct
@@ -4307,6 +4320,7 @@ void __ieee80211_subif_start_xmit(struct
struct sk_buff *next;
int len = skb->len;
struct ieee80211_key *key = NULL;
@ -1229,7 +1211,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
struct ieee80211_sub_if_data *ap_sdata;
if (unlikely(!ieee80211_sdata_running(sdata) || skb->len < ETH_HLEN)) {
@@ -4359,9 +4370,15 @@ void __ieee80211_subif_start_xmit(struct
@@ -4381,9 +4395,15 @@ void __ieee80211_subif_start_xmit(struct
goto out;
}
@ -1248,3 +1230,16 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
}
goto out;
out_free:
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -1737,4 +1737,10 @@ drv_can_neg_ttlm(struct ieee80211_local
return res;
}
+#ifdef CPTCFG_MAC80211_MESH
+void drv_config_mesh_offload_path(struct ieee80211_local *local,
+ struct ieee80211_sub_if_data *sdata,
+ enum ieee80211_mesh_path_offld_cmd cmd,
+ struct ieee80211_mesh_path_offld *path);
+#endif /* CPTCFG_MAC80211_MESH */
#endif /* __MAC80211_DRIVER_OPS */

View File

@ -16,7 +16,7 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -2738,6 +2738,8 @@ struct ieee80211_txq {
@@ -2839,6 +2839,8 @@ struct ieee80211_txq {
*
* @IEEE80211_HW_SUPPORTS_NSS_OFFLOAD: Hardware/driver supports NSS offload
*
@ -25,8 +25,8 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
* @NUM_IEEE80211_HW_FLAGS: number of hardware flags, used for sizing arrays
*/
enum ieee80211_hw_flags {
@@ -2797,6 +2799,7 @@ enum ieee80211_hw_flags {
IEEE80211_HW_MLO_MCAST_MULTI_LINK_TX,
@@ -2900,6 +2902,7 @@ enum ieee80211_hw_flags {
IEEE80211_HW_HANDLES_QUIET_CSA,
IEEE80211_HW_SUPPORTS_NSS_OFFLOAD,
IEEE80211_HW_SUPPORTS_MESH_NSS_OFFLOAD,
+ IEEE80211_HW_SUPPORTS_TID_CLASS_OFFLOAD,
@ -35,8 +35,8 @@ Signed-off-by: Gautham Kumar Senthilkumaran <quic_gauthamk@quicinc.com>
NUM_IEEE80211_HW_FLAGS
--- a/net/mac80211/debugfs.c
+++ b/net/mac80211/debugfs.c
@@ -507,6 +507,7 @@ static const char *hw_flag_names[] = {
FLAG(MLO_MCAST_MULTI_LINK_TX),
@@ -510,6 +510,7 @@ static const char *hw_flag_names[] = {
FLAG(HANDLES_QUIET_CSA),
FLAG(SUPPORTS_NSS_OFFLOAD),
FLAG(SUPPORTS_MESH_NSS_OFFLOAD),
+ FLAG(SUPPORTS_TID_CLASS_OFFLOAD),

View File

@ -14,7 +14,7 @@ Signed-off-by: Aloka Dixit <quic_alokad@quicinc.com>
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -4770,6 +4770,67 @@ out_free:
@@ -4800,6 +4800,67 @@ out_free:
kfree_skb(skb);
}
@ -43,7 +43,7 @@ Signed-off-by: Aloka Dixit <quic_alokad@quicinc.com>
+
+ if (unlikely(skb->sk &&
+ skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS))
+ info->ack_frame_id = ieee80211_store_ack_skb(local, skb,
+ info->status_data = ieee80211_store_ack_skb(local, skb,
+ &info->flags, NULL);
+
+ info->flags |= IEEE80211_TX_CTL_HW_80211_ENCAP;
@ -82,7 +82,7 @@ Signed-off-by: Aloka Dixit <quic_alokad@quicinc.com>
netdev_tx_t ieee80211_subif_start_xmit_8023(struct sk_buff *skb,
struct net_device *dev)
{
@@ -4809,6 +4870,11 @@ netdev_tx_t ieee80211_subif_start_xmit_8
@@ -4839,6 +4900,11 @@ netdev_tx_t ieee80211_subif_start_xmit_8
if (key && (!(key->flags & KEY_FLAG_UPLOADED_TO_HARDWARE)))
goto skip_offload;

View File

@ -20,7 +20,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -1750,6 +1750,8 @@ static void sta_apply_mesh_params(struct
@@ -1759,6 +1759,8 @@ static void sta_apply_mesh_params(struct
/* init at low value */
ewma_mesh_tx_rate_avg_add(&sta->mesh->tx_rate_avg, 10);
@ -29,7 +29,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
break;
case NL80211_PLINK_LISTEN:
case NL80211_PLINK_BLOCKED:
@@ -1764,6 +1766,7 @@ static void sta_apply_mesh_params(struct
@@ -1773,6 +1775,7 @@ static void sta_apply_mesh_params(struct
ieee80211_mps_sta_status_update(sta);
changed |= ieee80211_mps_set_sta_local_pm(sta,
NL80211_MESH_POWER_UNKNOWN);
@ -39,7 +39,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
/* nothing */
--- a/net/mac80211/mesh_plink.c
+++ b/net/mac80211/mesh_plink.c
@@ -381,6 +381,8 @@ static u64 __mesh_plink_deactivate(struc
@@ -389,6 +389,8 @@ static u64 __mesh_plink_deactivate(struc
changed |= ieee80211_mps_set_sta_local_pm(sta,
NL80211_MESH_POWER_UNKNOWN);
@ -48,7 +48,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
return changed;
}
@@ -846,6 +848,7 @@ static u64 mesh_plink_establish(struct i
@@ -856,6 +858,7 @@ static u64 mesh_plink_establish(struct i
mpl_dbg(sdata, "Mesh plink with %pM ESTABLISHED\n", sta->sta.addr);
ieee80211_mps_sta_status_update(sta);
changed |= ieee80211_mps_set_sta_local_pm(sta, mshcfg->power_mode);
@ -56,7 +56,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
return changed;
}
@@ -864,7 +867,7 @@ static u64 mesh_plink_fsm(struct ieee802
@@ -874,7 +877,7 @@ static u64 mesh_plink_fsm(struct ieee802
struct mesh_config *mshcfg = &sdata->u.mesh.mshcfg;
enum ieee80211_self_protected_actioncode action = 0;
u64 changed = 0;
@ -65,7 +65,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
mpl_dbg(sdata, "peer %pM in state %s got event %s\n", sta->sta.addr,
mplstates[sta->mesh->plink_state], mplevents[event]);
@@ -924,6 +927,7 @@ static u64 mesh_plink_fsm(struct ieee802
@@ -934,6 +937,7 @@ static u64 mesh_plink_fsm(struct ieee802
break;
case CNF_ACPT:
changed |= mesh_plink_establish(sdata, sta);
@ -73,7 +73,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
break;
default:
break;
@@ -939,6 +943,7 @@ static u64 mesh_plink_fsm(struct ieee802
@@ -949,6 +953,7 @@ static u64 mesh_plink_fsm(struct ieee802
break;
case OPN_ACPT:
changed |= mesh_plink_establish(sdata, sta);
@ -81,7 +81,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
action = WLAN_SP_MESH_PEERING_CONFIRM;
break;
default:
@@ -985,6 +990,10 @@ static u64 mesh_plink_fsm(struct ieee802
@@ -995,6 +1000,10 @@ static u64 mesh_plink_fsm(struct ieee802
break;
}
spin_unlock_bh(&sta->mesh->plink_lock);
@ -94,7 +94,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
if (action) {
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -4653,10 +4653,15 @@ void ieee80211_check_fast_rx(struct sta_
@@ -4711,10 +4711,15 @@ void ieee80211_check_fast_rx(struct sta_
break;
case NL80211_IFTYPE_MESH_POINT:
@ -112,7 +112,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
break;
default:
goto clear;
@@ -4697,7 +4702,7 @@ void ieee80211_check_fast_rx(struct sta_
@@ -4755,7 +4760,7 @@ void ieee80211_check_fast_rx(struct sta_
__release(check_fast_rx);
if (assign)
@ -121,7 +121,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
offload_flags = get_bss_sdata(sdata)->vif.offload_flags;
offload = offload_flags & IEEE80211_OFFLOAD_DECAP_ENABLED;
@@ -4879,6 +4884,10 @@ static bool ieee80211_invoke_fast_rx(str
@@ -4937,6 +4942,10 @@ static bool ieee80211_invoke_fast_rx(str
u8 sa[ETH_ALEN];
} addrs __aligned(2);
struct ieee80211_sta_rx_stats *stats;
@ -132,7 +132,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
/* for parallel-rx, we need to have DUP_VALIDATED, otherwise we write
* to a common data structure; drivers can implement that per queue
@@ -4928,6 +4937,37 @@ static bool ieee80211_invoke_fast_rx(str
@@ -4986,6 +4995,37 @@ static bool ieee80211_invoke_fast_rx(str
snap_offs += IEEE80211_CCMP_HDR_LEN;
}
@ -170,7 +170,7 @@ Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
if (!ieee80211_vif_is_mesh(&rx->sdata->vif) &&
!(status->rx_flags & IEEE80211_RX_AMSDU)) {
if (!pskb_may_pull(skb, snap_offs + sizeof(*payload)))
@@ -4965,9 +5005,33 @@ static bool ieee80211_invoke_fast_rx(str
@@ -5023,9 +5063,33 @@ static bool ieee80211_invoke_fast_rx(str
return true;
}

View File

@ -33,7 +33,7 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -4704,7 +4704,7 @@ static void ieee80211_8023_xmit(struct i
@@ -4731,7 +4731,7 @@ static void ieee80211_8023_xmit(struct i
ieee80211_aggr_check(sdata, sta, skb);
@ -42,8 +42,8 @@ Signed-off-by: Tamizh Chelvam <quic_tamizhr@quicinc.com>
tid = skb->priority & IEEE80211_QOS_CTL_TAG1D_MASK;
tid_tx = rcu_dereference(sta->ampdu_mlme.tid_tx[tid]);
if (tid_tx) {
@@ -4755,7 +4755,7 @@ static void ieee80211_8023_xmit(struct i
&info->flags, NULL);
@@ -4785,7 +4785,7 @@ static void ieee80211_8023_xmit(struct i
}
dev_sw_netstats_tx_add(dev, skbs, len);
- if (!ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD)) {

View File

@ -1,52 +0,0 @@
From b3215eee07d071137e6977d60eee3cf685241fbb Mon Sep 17 00:00:00 2001
From: Hari Chandrakanthan <quic_haric@quicinc.com>
Date: Thu, 3 Feb 2022 13:55:53 +0530
Subject: [PATCH] mac80211 : fix mixed declaration
Fix mixed declaration in the api ieee80211_parse_ch_switch_ie
Signed-off-by: Hari Chandrakanthan <quic_haric@quicinc.com>
---
net/mac80211/spectmgmt.c | 22 +++++++++-------------
1 file changed, 9 insertions(+), 13 deletions(-)
--- a/net/mac80211/spectmgmt.c
+++ b/net/mac80211/spectmgmt.c
@@ -33,7 +33,10 @@ int ieee80211_parse_ch_switch_ie(struct
struct cfg80211_chan_def new_vht_chandef = {};
const struct ieee80211_sec_chan_offs_ie *sec_chan_offs;
const struct ieee80211_wide_bw_chansw_ie *wide_bw_chansw_ie;
+ struct ieee80211_vht_operation vht_oper;
+ struct ieee80211_ht_operation ht_oper;
int secondary_channel_offset = -1;
+ u8 new_seg1;
memset(csa_ie, 0, sizeof(*csa_ie));
@@ -133,20 +136,13 @@ int ieee80211_parse_ch_switch_ie(struct
}
if (wide_bw_chansw_ie) {
- u8 new_seg1 = wide_bw_chansw_ie->new_center_freq_seg1;
- struct ieee80211_vht_operation vht_oper = {
- .chan_width =
- wide_bw_chansw_ie->new_channel_width,
- .center_freq_seg0_idx =
- wide_bw_chansw_ie->new_center_freq_seg0,
- .center_freq_seg1_idx = new_seg1,
+ new_seg1 = wide_bw_chansw_ie->new_center_freq_seg1;
+ vht_oper.chan_width = wide_bw_chansw_ie->new_channel_width;
+ vht_oper.center_freq_seg0_idx = wide_bw_chansw_ie->new_center_freq_seg0;
+ vht_oper.center_freq_seg1_idx = new_seg1;
/* .basic_mcs_set doesn't matter */
- };
- struct ieee80211_ht_operation ht_oper = {
- .operation_mode =
- cpu_to_le16(new_seg1 <<
- IEEE80211_HT_OP_MODE_CCFS2_SHIFT),
- };
+ ht_oper.operation_mode = cpu_to_le16(new_seg1 <<
+ IEEE80211_HT_OP_MODE_CCFS2_SHIFT);
/* default, for the case of IEEE80211_VHT_CHANWIDTH_USE_HT,
* to the previously parsed chandef

View File

@ -1,34 +0,0 @@
From 9c7571646a01eedb85350dfce12b499a0267ab2b Mon Sep 17 00:00:00 2001
From: Hari Chandrakanthan <quic_haric@quicinc.com>
Date: Thu, 3 Feb 2022 14:01:57 +0530
Subject: [PATCH] mac80211 : fix bw change to 40Mhz during channel switch
When AP reduces its channel bandwidth to 40Mhz, the associated
sta reduces the channel bandwidth to 20Mhz.
From spec 802.11 ac, section 8.4.2.165 :
The Wide Bandwidth Channel Switch subelement is present under the following conditions:
1.Channel switching to a BSS operating channel width of 40 MHz or wider
2.Extended channel switching to a BSS operating channel width of 80 MHz or wider
So when wide bandwidth channel switch subelement is present,
the default bandwidth is chosen as 40Mhz.
Signed-off-by: Hari Chandrakanthan <quic_haric@quicinc.com>
---
net/mac80211/spectmgmt.c | 4 ++++
1 file changed, 4 insertions(+)
--- a/net/mac80211/spectmgmt.c
+++ b/net/mac80211/spectmgmt.c
@@ -136,6 +136,10 @@ int ieee80211_parse_ch_switch_ie(struct
}
if (wide_bw_chansw_ie) {
+ csa_ie->chandef.width = NL80211_CHAN_WIDTH_40;
+ csa_ie->chandef.center_freq1 =
+ ieee80211_channel_to_frequency(wide_bw_chansw_ie->new_center_freq_seg0,
+ new_chan->band);
new_seg1 = wide_bw_chansw_ie->new_center_freq_seg1;
vht_oper.chan_width = wide_bw_chansw_ie->new_channel_width;
vht_oper.center_freq_seg0_idx = wide_bw_chansw_ie->new_center_freq_seg0;

View File

@ -21,7 +21,7 @@ Signed-off-by: Nagarajan Maran <quic_nmaran@quicinc.com>
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@ -998,7 +998,8 @@ static bool ieee80211_set_sdata_offload_
@@ -1011,7 +1011,8 @@ static bool ieee80211_set_sdata_offload_
flags |= IEEE80211_OFFLOAD_DECAP_ENABLED;
if (local->monitors &&

View File

@ -14,7 +14,7 @@ Signed-off-by: P Praneesh <quic_ppranees@quicinc.com>
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -1410,8 +1410,6 @@ ieee80211_tx_info_clear_status(struct ie
@@ -1442,8 +1442,6 @@ ieee80211_tx_info_clear_status(struct ie
* @RX_FLAG_AMPDU_IS_LAST: this subframe is the last subframe of the A-MPDU
* @RX_FLAG_AMPDU_DELIM_CRC_ERROR: A delimiter CRC error has been detected
* on this subframe
@ -23,7 +23,7 @@ Signed-off-by: P Praneesh <quic_ppranees@quicinc.com>
* @RX_FLAG_MIC_STRIPPED: The mic was stripped of this packet. Decryption was
* done by the hardware
* @RX_FLAG_ONLY_MONITOR: Report frame only to monitor interfaces without
@@ -1468,39 +1466,38 @@ ieee80211_tx_info_clear_status(struct ie
@@ -1500,39 +1498,38 @@ ieee80211_tx_info_clear_status(struct ie
* hardware or driver)
*/
enum mac80211_rx_flags {
@ -34,14 +34,7 @@ Signed-off-by: P Praneesh <quic_ppranees@quicinc.com>
- RX_FLAG_IV_STRIPPED = BIT(4),
- RX_FLAG_FAILED_FCS_CRC = BIT(5),
- RX_FLAG_FAILED_PLCP_CRC = BIT(6),
+ RX_FLAG_MMIC_ERROR = BIT(0),
+ RX_FLAG_DECRYPTED = BIT(1),
+ RX_FLAG_ONLY_MONITOR = BIT(2),
+ RX_FLAG_MMIC_STRIPPED = BIT(3),
+ RX_FLAG_IV_STRIPPED = BIT(4),
+ RX_FLAG_FAILED_FCS_CRC = BIT(5),
+ RX_FLAG_FAILED_PLCP_CRC = BIT(6),
/* one free bit at 7 */
- RX_FLAG_MACTIME_IS_RTAP_TS64 = BIT(7),
- RX_FLAG_NO_SIGNAL_VAL = BIT(8),
- RX_FLAG_AMPDU_DETAILS = BIT(9),
- RX_FLAG_PN_VALIDATED = BIT(10),
@ -67,36 +60,44 @@ Signed-off-by: P Praneesh <quic_ppranees@quicinc.com>
- RX_FLAG_RADIOTAP_LSIG = BIT(28),
- RX_FLAG_NO_PSDU = BIT(29),
- RX_FLAG_8023 = BIT(30),
+ RX_FLAG_NO_SIGNAL_VAL = BIT(8),
+ RX_FLAG_AMPDU_DETAILS = BIT(9),
+ RX_FLAG_PN_VALIDATED = BIT(10),
+ RX_FLAG_DUP_VALIDATED = BIT(11),
+ RX_FLAG_AMPDU_LAST_KNOWN = BIT(12),
+ RX_FLAG_AMPDU_IS_LAST = BIT(13),
+ RX_FLAG_AMPDU_DELIM_CRC_ERROR = BIT(14),
+ RX_FLAG_MACTIME = BIT(15) | BIT(16),
+ RX_FLAG_MACTIME_PLCP_START = 1 << 15,
+ RX_FLAG_MACTIME_START = 2 << 15,
+ RX_FLAG_MACTIME_END = 3 << 15,
+ RX_FLAG_SKIP_MONITOR = BIT(17),
+ RX_FLAG_AMSDU_MORE = BIT(18),
+ RX_FLAG_RADIOTAP_TLV_AT_END = BIT(19),
+ RX_FLAG_MIC_STRIPPED = BIT(20),
+ RX_FLAG_ALLOW_SAME_PN = BIT(21),
+ RX_FLAG_ICV_STRIPPED = BIT(22),
+ RX_FLAG_AMPDU_EOF_BIT = BIT(23),
+ RX_FLAG_AMPDU_EOF_BIT_KNOWN = BIT(24),
+ RX_FLAG_RADIOTAP_HE = BIT(25),
+ RX_FLAG_RADIOTAP_HE_MU = BIT(26),
+ RX_FLAG_RADIOTAP_LSIG = BIT(27),
+ RX_FLAG_NO_PSDU = BIT(28),
+ RX_FLAG_8023 = BIT(29),
+ RX_FLAG_MMIC_ERROR = BIT(0),
+ RX_FLAG_DECRYPTED = BIT(1),
+ RX_FLAG_ONLY_MONITOR = BIT(2),
+ RX_FLAG_MMIC_STRIPPED = BIT(3),
+ RX_FLAG_IV_STRIPPED = BIT(4),
+ RX_FLAG_FAILED_FCS_CRC = BIT(5),
+ RX_FLAG_FAILED_PLCP_CRC = BIT(6),
+ RX_FLAG_MACTIME_IS_RTAP_TS64 = BIT(7),
+ RX_FLAG_NO_SIGNAL_VAL = BIT(8),
+ RX_FLAG_AMPDU_DETAILS = BIT(9),
+ RX_FLAG_PN_VALIDATED = BIT(10),
+ RX_FLAG_DUP_VALIDATED = BIT(11),
+ RX_FLAG_AMPDU_LAST_KNOWN = BIT(12),
+ RX_FLAG_AMPDU_IS_LAST = BIT(13),
+ RX_FLAG_AMPDU_DELIM_CRC_ERROR = BIT(14),
+ RX_FLAG_MACTIME = BIT(15) | BIT(16),
+ RX_FLAG_MACTIME_PLCP_START = 1 << 15,
+ RX_FLAG_MACTIME_START = 2 << 15,
+ RX_FLAG_MACTIME_END = 3 << 15,
+ RX_FLAG_SKIP_MONITOR = BIT(17),
+ RX_FLAG_AMSDU_MORE = BIT(18),
+ RX_FLAG_RADIOTAP_TLV_AT_END = BIT(19),
+ RX_FLAG_MIC_STRIPPED = BIT(20),
+ RX_FLAG_ALLOW_SAME_PN = BIT(21),
+ RX_FLAG_ICV_STRIPPED = BIT(22),
+ RX_FLAG_AMPDU_EOF_BIT = BIT(23),
+ RX_FLAG_AMPDU_EOF_BIT_KNOWN = BIT(24),
+ RX_FLAG_RADIOTAP_HE = BIT(25),
+ RX_FLAG_RADIOTAP_HE_MU = BIT(26),
+ RX_FLAG_RADIOTAP_LSIG = BIT(27),
+ RX_FLAG_NO_PSDU = BIT(28),
+ RX_FLAG_8023 = BIT(29),
};
/**
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -507,18 +507,13 @@ ieee80211_add_rx_radiotap_header(struct
@@ -508,18 +508,13 @@ ieee80211_add_rx_radiotap_header(struct
flags |= IEEE80211_RADIOTAP_AMPDU_IS_LAST;
if (status->flag & RX_FLAG_AMPDU_DELIM_CRC_ERROR)
flags |= IEEE80211_RADIOTAP_AMPDU_DELIM_CRC_ERR;

View File

@ -44,7 +44,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
/* misc utils */
static __le16 ieee80211_duration(struct ieee80211_tx_data *tx,
@@ -4328,7 +4329,7 @@ void __ieee80211_subif_start_xmit(struct
@@ -4353,7 +4354,7 @@ void __ieee80211_subif_start_xmit(struct
!is_multicast_ether_addr(skb->data)) {
if (sta)
key = rcu_dereference(sta->ptk[sta->ptk_idx]);
@ -53,7 +53,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
rcu_read_unlock();
return;
}
@@ -4374,7 +4375,7 @@ void __ieee80211_subif_start_xmit(struct
@@ -4399,7 +4400,7 @@ void __ieee80211_subif_start_xmit(struct
if (info->flags & IEEE80211_TX_CTL_HW_80211_ENCAP) {
if (sta)
key = rcu_dereference(sta->ptk[sta->ptk_idx]);
@ -62,7 +62,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
} else {
dev_sw_netstats_tx_add(dev, 1, skb->len);
ieee80211_xmit(sdata, sta, skb);
@@ -4672,7 +4673,8 @@ static bool ieee80211_tx_8023(struct iee
@@ -4699,7 +4700,8 @@ static bool ieee80211_tx_8023(struct iee
static void ieee80211_8023_xmit(struct ieee80211_sub_if_data *sdata,
struct net_device *dev, struct sta_info *sta,
@ -72,7 +72,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
{
struct ieee80211_tx_info *info;
struct ethhdr *ehdr = (struct ethhdr *)skb->data;
@@ -4728,6 +4730,7 @@ static void ieee80211_8023_xmit(struct i
@@ -4755,6 +4757,7 @@ static void ieee80211_8023_xmit(struct i
info = IEEE80211_SKB_CB(skb);
memset(info, 0, sizeof(*info));
@ -80,23 +80,23 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
info->hw_queue = sdata->vif.hw_queue[queue];
if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN &&
@@ -4748,11 +4751,12 @@ static void ieee80211_8023_xmit(struct i
@@ -4775,11 +4778,12 @@ static void ieee80211_8023_xmit(struct i
memcpy(IEEE80211_SKB_CB(seg), info, sizeof(*info));
}
- if (unlikely(skb->sk &&
- skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS &&
+ if (unlikely(((skb->sk &&
+ skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS) ||
+ skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS) ||
+ ((ctrl_flags & IEEE80211_TX_CTL_REQ_TX_STATUS) && !multicast)) &&
!ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD)))
info->ack_frame_id = ieee80211_store_ack_skb(local, skb,
- &info->flags, NULL);
+ &info->flags, cookie);
dev_sw_netstats_tx_add(dev, skbs, len);
if (!ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD) && sta) {
@@ -4772,7 +4776,8 @@ out_free:
!ieee80211_hw_check(&local->hw, SUPPORTS_NSS_OFFLOAD))) {
info->status_data = ieee80211_store_ack_skb(local, skb,
- &info->flags, NULL);
+ &info->flags, cookie);
if (info->status_data)
info->status_data_idr = 1;
}
@@ -4802,7 +4806,8 @@ out_free:
void ieee80211_8023_xmit_ap(struct ieee80211_sub_if_data *sdata,
struct net_device *dev, struct sta_info *sta,
@ -106,7 +106,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
{
struct ieee80211_tx_info *info;
struct ieee80211_local *local = sdata->local;
@@ -4781,6 +4786,9 @@ void ieee80211_8023_xmit_ap(struct ieee8
@@ -4811,6 +4816,9 @@ void ieee80211_8023_xmit_ap(struct ieee8
unsigned long flags;
int q;
u16 q_map;
@ -116,7 +116,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
/*
* If the skb is shared we need to obtain our own copy.
@@ -4792,11 +4800,13 @@ void ieee80211_8023_xmit_ap(struct ieee8
@@ -4822,11 +4830,13 @@ void ieee80211_8023_xmit_ap(struct ieee8
info = IEEE80211_SKB_CB(skb);
memset(info, 0, sizeof(*info));
@ -127,13 +127,13 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
+ if (unlikely((skb->sk &&
+ skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS) ||
+ ((ctrl_flags & IEEE80211_TX_CTL_REQ_TX_STATUS) && !multicast)))
info->ack_frame_id = ieee80211_store_ack_skb(local, skb,
info->status_data = ieee80211_store_ack_skb(local, skb,
- &info->flags, NULL);
+ &info->flags, cookie);
info->flags |= IEEE80211_TX_CTL_HW_80211_ENCAP;
info->control.vif = &sdata->vif;
@@ -4830,14 +4840,23 @@ void ieee80211_8023_xmit_ap(struct ieee8
@@ -4860,14 +4870,23 @@ void ieee80211_8023_xmit_ap(struct ieee8
drv_tx(local, &control, skb);
}
@ -158,7 +158,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
#ifdef CPTCFG_MAC80211_NSS_SUPPORT
ieee80211_xmit_nss_fixup(skb, dev);
@@ -4853,14 +4872,15 @@ netdev_tx_t ieee80211_subif_start_xmit_8
@@ -4883,14 +4902,15 @@ netdev_tx_t ieee80211_subif_start_xmit_8
kfree_skb(skb);
goto out;
}
@ -176,7 +176,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
goto skip_offload;
key = rcu_dereference(sta->ptk[sta->ptk_idx]);
@@ -4871,13 +4891,13 @@ netdev_tx_t ieee80211_subif_start_xmit_8
@@ -4901,13 +4921,13 @@ netdev_tx_t ieee80211_subif_start_xmit_8
goto skip_offload;
if (sdata->vif.type == NL80211_IFTYPE_AP) {
@ -192,9 +192,9 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
goto out;
skip_offload:
@@ -6383,7 +6403,10 @@ start_xmit:
mutex_lock(&local->mtx);
@@ -6429,7 +6449,10 @@ int ieee80211_tx_control_port(struct wip
start_xmit:
local_bh_disable();
- __ieee80211_subif_start_xmit(skb, skb->dev, flags, ctrl_flags, cookie);
+ if (sdata->vif.offload_flags & IEEE80211_OFFLOAD_ENCAP_ENABLED)
@ -203,4 +203,4 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
+ __ieee80211_subif_start_xmit(skb, skb->dev, flags, ctrl_flags, cookie);
local_bh_enable();
mutex_unlock(&local->mtx);
return 0;

View File

@ -72,7 +72,7 @@ Signed-off-by: P Praneesh <quic_ppranees@quicinc.com>
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -2349,7 +2349,7 @@ static void mpath_set_pinfo(struct mesh_
@@ -2346,7 +2346,7 @@ static void mpath_set_pinfo(struct mesh_
if (mpath->flags & MESH_PATH_RESOLVED)
pinfo->flags |= NL80211_MPATH_FLAG_RESOLVED;
pinfo->hop_count = mpath->hop_count;
@ -83,7 +83,7 @@ Signed-off-by: P Praneesh <quic_ppranees@quicinc.com>
static int ieee80211_get_mpath(struct wiphy *wiphy, struct net_device *dev,
--- a/net/mac80211/mesh.h
+++ b/net/mac80211/mesh.h
@@ -126,7 +126,7 @@ struct mesh_path {
@@ -127,7 +127,7 @@ struct mesh_path {
unsigned long fast_tx_check;
bool is_root;
bool is_gate;
@ -94,7 +94,7 @@ Signed-off-by: P Praneesh <quic_ppranees@quicinc.com>
#define MESH_FAST_TX_CACHE_MAX_SIZE 512
--- a/net/mac80211/mesh_hwmp.c
+++ b/net/mac80211/mesh_hwmp.c
@@ -504,7 +504,7 @@ static u32 hwmp_route_info_get(struct ie
@@ -506,7 +506,7 @@ static u32 hwmp_route_info_get(struct ie
if (next_hop)
ether_addr_copy(old_next_hop_addr, next_hop->sta.addr);
if (next_hop != sta) {
@ -103,7 +103,7 @@ Signed-off-by: P Praneesh <quic_ppranees@quicinc.com>
flush_mpath = true;
}
mesh_path_assign_nexthop(mpath, sta);
@@ -565,7 +565,7 @@ static u32 hwmp_route_info_get(struct ie
@@ -567,7 +567,7 @@ static u32 hwmp_route_info_get(struct ie
if (next_hop)
ether_addr_copy(old_next_hop_addr, next_hop->sta.addr);
if (next_hop != sta) {

View File

@ -16,7 +16,7 @@ Signed-off-by: Maharaja Kennadyrajan <quic_mkenna@quicinc.com>
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
@@ -2385,7 +2385,7 @@ void ieee80211_sta_update_pending_airtim
@@ -2411,7 +2411,7 @@ void ieee80211_sta_update_pending_airtim
}
static struct ieee80211_sta_rx_stats *
@ -25,7 +25,7 @@ Signed-off-by: Maharaja Kennadyrajan <quic_mkenna@quicinc.com>
{
struct ieee80211_sta_rx_stats *stats = &sta->deflink.rx_stats;
int cpu;
@@ -2398,8 +2398,13 @@ sta_get_last_rx_stats(struct sta_info *s
@@ -2424,8 +2424,13 @@ sta_get_last_rx_stats(struct sta_info *s
for_each_possible_cpu(cpu) {
struct ieee80211_sta_rx_stats *cpustats;
@ -39,7 +39,7 @@ Signed-off-by: Maharaja Kennadyrajan <quic_mkenna@quicinc.com>
if (time_after(cpustats->last_rx, stats->last_rx))
stats = cpustats;
@@ -2476,7 +2481,7 @@ static void sta_stats_decode_rate(struct
@@ -2502,7 +2507,7 @@ static void sta_stats_decode_rate(struct
static int sta_set_rate_info_rx(struct sta_info *sta, struct rate_info *rinfo)
{
@ -48,7 +48,7 @@ Signed-off-by: Maharaja Kennadyrajan <quic_mkenna@quicinc.com>
if (rate == STA_STATS_RATE_INVALID)
return -EINVAL;
@@ -2576,7 +2581,7 @@ void sta_set_sinfo(struct sta_info *sta,
@@ -2602,7 +2607,7 @@ void sta_set_sinfo(struct sta_info *sta,
int i, ac, cpu;
struct ieee80211_sta_rx_stats *last_rxstats;
@ -57,7 +57,7 @@ Signed-off-by: Maharaja Kennadyrajan <quic_mkenna@quicinc.com>
sinfo->generation = sdata->local->sta_generation;
@@ -2859,7 +2864,7 @@ u32 sta_get_expected_throughput(struct s
@@ -2886,7 +2891,7 @@ u32 sta_get_expected_throughput(struct s
unsigned long ieee80211_sta_last_active(struct sta_info *sta)
{

View File

@ -31,7 +31,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
static void ieee80211_8023_xmit(struct ieee80211_sub_if_data *sdata,
struct net_device *dev, struct sta_info *sta,
struct ieee80211_key *key, struct sk_buff *skb,
@@ -3642,7 +3644,7 @@ ieee80211_sdata_netdev_features(struct i
@@ -3668,7 +3670,7 @@ ieee80211_sdata_netdev_features(struct i
}
static struct sk_buff *
@ -40,7 +40,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
{
if (skb_is_gso(skb)) {
struct sk_buff *segs;
@@ -3660,7 +3662,7 @@ ieee80211_tx_skb_fixup(struct sk_buff *s
@@ -3686,7 +3688,7 @@ ieee80211_tx_skb_fixup(struct sk_buff *s
if (skb_needs_linearize(skb, features) && __skb_linearize(skb))
goto free;
@ -49,7 +49,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
int ofs = skb_checksum_start_offset(skb);
if (skb->encapsulation)
@@ -3806,7 +3808,7 @@ static bool ieee80211_xmit_fast(struct i
@@ -3832,7 +3834,7 @@ static bool ieee80211_xmit_fast(struct i
memcpy(&eth, skb->data, ETH_HLEN - 2);
/* after this point (skb is modified) we cannot return false */
@ -58,7 +58,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
if (!skb)
return true;
@@ -4352,7 +4354,7 @@ void __ieee80211_subif_start_xmit(struct
@@ -4377,7 +4379,7 @@ void __ieee80211_subif_start_xmit(struct
* things so we cannot really handle checksum or GSO offload.
* fix it up in software before we handle anything else.
*/
@ -67,7 +67,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
if (!skb) {
len = 0;
goto out;
@@ -4723,7 +4725,7 @@ static void ieee80211_8023_xmit(struct i
@@ -4750,7 +4752,7 @@ static void ieee80211_8023_xmit(struct i
}
}
@ -78,7 +78,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@ -2269,6 +2269,10 @@ int ieee80211_if_add(struct ieee80211_lo
@@ -2263,6 +2263,10 @@ int ieee80211_if_add(struct ieee80211_lo
ndev->features |= local->hw.netdev_features;
ndev->priv_flags |= IFF_LIVE_ADDR_CHANGE;
@ -100,7 +100,7 @@ Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
static int mesh_allocated;
static struct kmem_cache *rm_cache;
@@ -797,7 +799,7 @@ bool ieee80211_mesh_xmit_fast(struct iee
@@ -779,7 +781,7 @@ bool ieee80211_mesh_xmit_fast(struct iee
if (skb->sk && skb_shinfo(skb)->tx_flags & SKBTX_WIFI_STATUS)
return false;

View File

@ -23,7 +23,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -2737,6 +2737,9 @@ struct ieee80211_txq {
@@ -2838,6 +2838,9 @@ struct ieee80211_txq {
*
* @IEEE80211_HW_SUPPORTS_TID_CLASS_OFFLOAD: Hardware suports tid calssification offload.
*
@ -33,7 +33,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
* @NUM_IEEE80211_HW_FLAGS: number of hardware flags, used for sizing arrays
*/
enum ieee80211_hw_flags {
@@ -2797,6 +2800,7 @@ enum ieee80211_hw_flags {
@@ -2900,6 +2903,7 @@ enum ieee80211_hw_flags {
IEEE80211_HW_SUPPORTS_NSS_OFFLOAD,
IEEE80211_HW_SUPPORTS_MESH_NSS_OFFLOAD,
IEEE80211_HW_SUPPORTS_TID_CLASS_OFFLOAD,
@ -43,7 +43,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
NUM_IEEE80211_HW_FLAGS
--- a/net/mac80211/debugfs.c
+++ b/net/mac80211/debugfs.c
@@ -508,6 +508,7 @@ static const char *hw_flag_names[] = {
@@ -511,6 +511,7 @@ static const char *hw_flag_names[] = {
FLAG(SUPPORTS_NSS_OFFLOAD),
FLAG(SUPPORTS_MESH_NSS_OFFLOAD),
FLAG(SUPPORTS_TID_CLASS_OFFLOAD),
@ -53,7 +53,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -1603,6 +1603,9 @@ int ieee80211_txq_setup_flows(struct iee
@@ -1601,6 +1601,9 @@ int ieee80211_txq_setup_flows(struct iee
bool supp_vht = false;
enum nl80211_band band;
@ -63,7 +63,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
ret = fq_init(fq, 4096);
if (ret)
return ret;
@@ -1650,6 +1653,9 @@ void ieee80211_txq_teardown_flows(struct
@@ -1648,6 +1651,9 @@ void ieee80211_txq_teardown_flows(struct
{
struct fq *fq = &local->fq;
@ -73,7 +73,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
kfree(local->cvars);
local->cvars = NULL;
@@ -1666,7 +1672,8 @@ static bool ieee80211_queue_skb(struct i
@@ -1664,7 +1670,8 @@ static bool ieee80211_queue_skb(struct i
struct ieee80211_vif *vif;
struct txq_info *txqi;
@ -83,7 +83,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
return false;
if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN)
@@ -4337,7 +4344,8 @@ void __ieee80211_subif_start_xmit(struct
@@ -4362,7 +4369,8 @@ void __ieee80211_subif_start_xmit(struct
}
}
@ -93,7 +93,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
ieee80211_aggr_check(sdata, sta, skb);
if (sta) {
@@ -4689,8 +4697,10 @@ static void ieee80211_8023_xmit(struct i
@@ -4716,8 +4724,10 @@ static void ieee80211_8023_xmit(struct i
bool multicast;
u8 tid;
@ -106,7 +106,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
multicast = is_multicast_ether_addr(ra);
@@ -6387,9 +6397,12 @@ int ieee80211_tx_control_port(struct wip
@@ -6436,9 +6446,12 @@ int ieee80211_tx_control_port(struct wip
}
if (!IS_ERR(sta)) {
@ -123,7 +123,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
* for MLO STA, the SA should be the AP MLD address, but
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -4524,6 +4524,9 @@ static int ieee80211_get_txq_stats(struc
@@ -4565,6 +4565,9 @@ static int ieee80211_get_txq_stats(struc
struct ieee80211_sub_if_data *sdata;
int ret = 0;
@ -135,7 +135,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
--- a/net/mac80211/main.c
+++ b/net/mac80211/main.c
@@ -839,7 +839,10 @@ struct ieee80211_hw *ieee80211_alloc_hw_
@@ -993,7 +993,10 @@ struct ieee80211_hw *ieee80211_alloc_hw_
atomic_set(&local->agg_queue_stop[i], 0);
}
tasklet_setup(&local->tx_pending_tasklet, ieee80211_tx_pending);
@ -149,7 +149,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
skb_queue_head_init(&local->skb_queue);
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -1549,6 +1549,9 @@ static void sta_ps_start(struct sta_info
@@ -1576,6 +1576,9 @@ static void sta_ps_start(struct sta_info
ieee80211_clear_fast_xmit(sta);
@ -161,9 +161,9 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
struct txq_info *txqi = to_txq_info(txq);
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
@@ -140,15 +140,17 @@ static void __cleanup_single_sta(struct
atomic_dec(&ps->num_sta_ps);
}
@@ -118,15 +118,17 @@ void ieee80211_purge_sta_txqs(struct sta
struct ieee80211_local *local = sta->sdata->local;
int i;
- for (i = 0; i < ARRAY_SIZE(sta->sta.txq); i++) {
- struct txq_info *txqi;
@ -183,9 +183,9 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
+ ieee80211_txq_purge(local, txqi);
+ }
}
}
for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) {
@@ -430,7 +432,9 @@ void sta_info_free(struct ieee80211_loca
@@ -436,7 +438,9 @@ void sta_info_free(struct ieee80211_loca
sta_dbg(sta->sdata, "Destroyed STA %pM\n", sta->sta.addr);
@ -196,7 +196,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
kfree(rcu_dereference_raw(sta->sta.rates));
#ifdef CPTCFG_MAC80211_MESH
kfree(sta->mesh);
@@ -532,8 +536,6 @@ __sta_info_alloc(struct ieee80211_sub_if
@@ -537,8 +541,6 @@ __sta_info_alloc(struct ieee80211_sub_if
struct ieee80211_local *local = sdata->local;
struct ieee80211_hw *hw = &local->hw;
struct sta_info *sta;
@ -205,7 +205,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
int i;
sta = kzalloc(sizeof(*sta) + hw->sta_data_size, gfp);
@@ -611,18 +613,22 @@ __sta_info_alloc(struct ieee80211_sub_if
@@ -615,18 +617,22 @@ __sta_info_alloc(struct ieee80211_sub_if
sta->last_connected = ktime_get_seconds();
@ -237,7 +237,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
}
if (sta_prepare_rate_control(local, sta, gfp))
@@ -696,7 +702,8 @@ __sta_info_alloc(struct ieee80211_sub_if
@@ -700,7 +706,8 @@ __sta_info_alloc(struct ieee80211_sub_if
return sta;
free_txq:
@ -247,7 +247,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
free:
sta_info_free_link(&sta->deflink);
#ifdef CPTCFG_MAC80211_MESH
@@ -1691,11 +1698,13 @@ void ieee80211_sta_ps_deliver_wakeup(str
@@ -1719,11 +1726,13 @@ void ieee80211_sta_ps_deliver_wakeup(str
if (!ieee80211_hw_check(&local->hw, AP_LINK_PS))
drv_sta_notify(local, sdata, STA_NOTIFY_AWAKE, &sta->sta);
@ -265,7 +265,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
}
skb_queue_head_init(&pending);
@@ -2110,6 +2119,9 @@ ieee80211_sta_ps_deliver_response(struct
@@ -2138,6 +2147,9 @@ ieee80211_sta_ps_deliver_response(struct
* TIM recalculation.
*/
@ -275,7 +275,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
for (tid = 0; tid < ARRAY_SIZE(sta->sta.txq); tid++) {
if (!sta->sta.txq[tid] ||
!(driver_release_tids & BIT(tid)) ||
@@ -2546,7 +2558,7 @@ static void sta_set_tidstats(struct sta_
@@ -2572,7 +2584,7 @@ static void sta_set_tidstats(struct sta_
tidstats->tx_msdu_failed = sta->deflink.status_stats.msdu_failed[tid];
}
@ -284,7 +284,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
spin_lock_bh(&local->fq.lock);
rcu_read_lock();
@@ -2874,6 +2886,9 @@ unsigned long ieee80211_sta_last_active(
@@ -2901,6 +2913,9 @@ unsigned long ieee80211_sta_last_active(
static void sta_update_codel_params(struct sta_info *sta, u32 thr)
{
@ -316,7 +316,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
--- a/net/mac80211/mesh.c
+++ b/net/mac80211/mesh.c
@@ -832,7 +832,8 @@ bool ieee80211_mesh_xmit_fast(struct iee
@@ -814,7 +814,8 @@ bool ieee80211_mesh_xmit_fast(struct iee
if (!skb)
return true;
@ -328,7 +328,7 @@ Signed-off-by: Yuvasree Sivasankaran <quic_ysivasan@quicinc.com>
if ((meshhdr->flags & MESH_FLAGS_AE) == MESH_FLAGS_AE_A5_A6) {
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -477,10 +477,8 @@ static void __ieee80211_wake_queue(struc
@@ -470,10 +470,8 @@ static void __ieee80211_wake_queue(struc
* release someone's lock, but it is fine because all the callers of
* __ieee80211_wake_queue call it right before releasing the lock.
*/

View File

@ -10,7 +10,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -4651,16 +4651,14 @@ void ieee80211_check_fast_rx(struct sta_
@@ -4709,16 +4709,14 @@ void ieee80211_check_fast_rx(struct sta_
break;
case NL80211_IFTYPE_MESH_POINT:
@ -30,7 +30,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
default:
goto clear;
}
@@ -4882,10 +4880,7 @@ static bool ieee80211_invoke_fast_rx(str
@@ -4940,10 +4938,7 @@ static bool ieee80211_invoke_fast_rx(str
u8 sa[ETH_ALEN];
} addrs __aligned(2);
struct ieee80211_sta_rx_stats *stats;
@ -41,7 +41,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
/* for parallel-rx, we need to have DUP_VALIDATED, otherwise we write
* to a common data structure; drivers can implement that per queue
@@ -4935,37 +4930,6 @@ static bool ieee80211_invoke_fast_rx(str
@@ -4993,37 +4988,6 @@ static bool ieee80211_invoke_fast_rx(str
snap_offs += IEEE80211_CCMP_HDR_LEN;
}
@ -79,7 +79,7 @@ Signed-off-by: Aaradhana Sahu <quic_aarasahu@quicinc.com>
if (!ieee80211_vif_is_mesh(&rx->sdata->vif) &&
!(status->rx_flags & IEEE80211_RX_AMSDU)) {
if (!pskb_may_pull(skb, snap_offs + sizeof(*payload)))
@@ -5003,30 +4967,6 @@ static bool ieee80211_invoke_fast_rx(str
@@ -5061,30 +5025,6 @@ static bool ieee80211_invoke_fast_rx(str
return true;
}

View File

@ -25,7 +25,7 @@ Signed-off-by: Manish Dharanenthiran <quic_mdharane@quicinc.com>
--- a/net/mac80211/ieee80211_i.h
+++ b/net/mac80211/ieee80211_i.h
@@ -682,7 +682,7 @@ struct ieee80211_if_mesh {
@@ -728,7 +728,7 @@ struct ieee80211_if_mesh {
struct timer_list mesh_path_root_timer;
unsigned long wrkq_flags;
@ -36,7 +36,7 @@ Signed-off-by: Manish Dharanenthiran <quic_mdharane@quicinc.com>
--- a/net/mac80211/mesh.c
+++ b/net/mac80211/mesh.c
@@ -1184,7 +1184,7 @@ void ieee80211_mbss_info_change_notify(s
@@ -1168,7 +1168,7 @@ void ieee80211_mbss_info_change_notify(s
/* if we race with running work, worst case this work becomes a noop */
for_each_set_bit(bit, &bits, sizeof(changed) * BITS_PER_BYTE)
@ -45,7 +45,7 @@ Signed-off-by: Manish Dharanenthiran <quic_mdharane@quicinc.com>
set_bit(MESH_WORK_MBSS_CHANGED, &ifmsh->wrkq_flags);
wiphy_work_queue(sdata->local->hw.wiphy, &sdata->work);
}
@@ -1266,7 +1266,7 @@ void ieee80211_stop_mesh(struct ieee8021
@@ -1250,7 +1250,7 @@ void ieee80211_stop_mesh(struct ieee8021
/* clear any mesh work (for next join) we may have accrued */
ifmsh->wrkq_flags = 0;
@ -54,7 +54,7 @@ Signed-off-by: Manish Dharanenthiran <quic_mdharane@quicinc.com>
local->fif_other_bss--;
atomic_dec(&local->iff_allmultis);
@@ -1733,9 +1733,9 @@ static void mesh_bss_info_changed(struct
@@ -1719,9 +1719,9 @@ static void mesh_bss_info_changed(struct
u32 bit;
u64 changed = 0;

View File

@ -1,6 +1,6 @@
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
@@ -2386,10 +2386,7 @@ void ieee80211_sta_update_pending_airtim
@@ -2412,10 +2412,7 @@ void ieee80211_sta_update_pending_airtim
atomic_sub(tx_airtime, &local->aql_total_pending_airtime);
tx_pending = atomic_sub_return(tx_airtime,
&local->aql_ac_pending_airtime[ac]);