Skip to content

Commit 37a0dd6

Browse files
Muna Sinadakvalo
authored andcommitted
wifi: ath12k: add 320 MHz bandwidth enums
Add 320 MHz bandwidth as a new bandwidth enum for ATH12k driver. This is extending existing bandwidth related enums to include 320 MHz. This is a precursor to supporting 320 MHz in the future. Sanity test performed to confirm that there was no impact in existing bandwidths. Additionally update QuIC copyright to include 2023 in hal_rx.h. Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.1.1-00125-QCAHKSWPL_SILICONZ-1 Signed-off-by: Muna Sinada <[email protected]> Acked-by: Jeff Johnson <[email protected]> Signed-off-by: Kalle Valo <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 62e3136 commit 37a0dd6

File tree

6 files changed

+16
-3
lines changed

6 files changed

+16
-3
lines changed

drivers/net/wireless/ath/ath12k/dp_mon.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1091,7 +1091,7 @@ static void ath12k_dp_mon_rx_deliver_msdu(struct ath12k *ar, struct napi_struct
10911091
spin_unlock_bh(&ar->ab->base_lock);
10921092

10931093
ath12k_dbg(ar->ab, ATH12K_DBG_DATA,
1094-
"rx skb %pK len %u peer %pM %u %s %s%s%s%s%s%s%s %srate_idx %u vht_nss %u freq %u band %u flag 0x%x fcs-err %i mic-err %i amsdu-more %i\n",
1094+
"rx skb %pK len %u peer %pM %u %s %s%s%s%s%s%s%s%s %srate_idx %u vht_nss %u freq %u band %u flag 0x%x fcs-err %i mic-err %i amsdu-more %i\n",
10951095
msdu,
10961096
msdu->len,
10971097
peer ? peer->addr : NULL,
@@ -1104,6 +1104,7 @@ static void ath12k_dp_mon_rx_deliver_msdu(struct ath12k *ar, struct napi_struct
11041104
(status->bw == RATE_INFO_BW_40) ? "40" : "",
11051105
(status->bw == RATE_INFO_BW_80) ? "80" : "",
11061106
(status->bw == RATE_INFO_BW_160) ? "160" : "",
1107+
(status->bw == RATE_INFO_BW_320) ? "320" : "",
11071108
status->enc_flags & RX_ENC_FLAG_SHORT_GI ? "sgi " : "",
11081109
status->rate_idx,
11091110
status->nss,

drivers/net/wireless/ath/ath12k/dp_rx.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2417,7 +2417,7 @@ static void ath12k_dp_rx_deliver_msdu(struct ath12k *ar, struct napi_struct *nap
24172417
spin_unlock_bh(&ab->base_lock);
24182418

24192419
ath12k_dbg(ab, ATH12K_DBG_DATA,
2420-
"rx skb %pK len %u peer %pM %d %s sn %u %s%s%s%s%s%s%s%s rate_idx %u vht_nss %u freq %u band %u flag 0x%x fcs-err %i mic-err %i amsdu-more %i\n",
2420+
"rx skb %pK len %u peer %pM %d %s sn %u %s%s%s%s%s%s%s%s%s rate_idx %u vht_nss %u freq %u band %u flag 0x%x fcs-err %i mic-err %i amsdu-more %i\n",
24212421
msdu,
24222422
msdu->len,
24232423
peer ? peer->addr : NULL,
@@ -2431,6 +2431,7 @@ static void ath12k_dp_rx_deliver_msdu(struct ath12k *ar, struct napi_struct *nap
24312431
(status->bw == RATE_INFO_BW_40) ? "40" : "",
24322432
(status->bw == RATE_INFO_BW_80) ? "80" : "",
24332433
(status->bw == RATE_INFO_BW_160) ? "160" : "",
2434+
(status->bw == RATE_INFO_BW_320) ? "320" : "",
24342435
status->enc_flags & RX_ENC_FLAG_SHORT_GI ? "sgi " : "",
24352436
status->rate_idx,
24362437
status->nss,

drivers/net/wireless/ath/ath12k/hal_rx.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/* SPDX-License-Identifier: BSD-3-Clause-Clear */
22
/*
33
* Copyright (c) 2018-2021 The Linux Foundation. All rights reserved.
4-
* Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
4+
* Copyright (c) 2021-2023 Qualcomm Innovation Center, Inc. All rights reserved.
55
*/
66

77
#ifndef ATH12K_HAL_RX_H
@@ -61,6 +61,7 @@ enum hal_rx_bw {
6161
HAL_RX_BW_40MHZ,
6262
HAL_RX_BW_80MHZ,
6363
HAL_RX_BW_160MHZ,
64+
HAL_RX_BW_320MHZ,
6465
HAL_RX_BW_MAX,
6566
};
6667

drivers/net/wireless/ath/ath12k/mac.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -343,6 +343,9 @@ ath12k_mac_bw_to_mac80211_bw(enum ath12k_supported_bw bw)
343343
case ATH12K_BW_160:
344344
ret = RATE_INFO_BW_160;
345345
break;
346+
case ATH12K_BW_320:
347+
ret = RATE_INFO_BW_320;
348+
break;
346349
}
347350

348351
return ret;
@@ -359,6 +362,8 @@ enum ath12k_supported_bw ath12k_mac_mac80211_bw_to_ath12k_bw(enum rate_info_bw b
359362
return ATH12K_BW_80;
360363
case RATE_INFO_BW_160:
361364
return ATH12K_BW_160;
365+
case RATE_INFO_BW_320:
366+
return ATH12K_BW_320;
362367
default:
363368
return ATH12K_BW_20;
364369
}
@@ -3726,6 +3731,9 @@ static u32 ath12k_mac_ieee80211_sta_bw_to_wmi(struct ath12k *ar,
37263731
case IEEE80211_STA_RX_BW_160:
37273732
bw = WMI_PEER_CHWIDTH_160MHZ;
37283733
break;
3734+
case IEEE80211_STA_RX_BW_320:
3735+
bw = WMI_PEER_CHWIDTH_320MHZ;
3736+
break;
37293737
default:
37303738
ath12k_warn(ar->ab, "Invalid bandwidth %d in rc update for %pM\n",
37313739
sta->deflink.bandwidth, sta->addr);

drivers/net/wireless/ath/ath12k/mac.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ enum ath12k_supported_bw {
4343
ATH12K_BW_40 = 1,
4444
ATH12K_BW_80 = 2,
4545
ATH12K_BW_160 = 3,
46+
ATH12K_BW_320 = 4,
4647
};
4748

4849
extern const struct htt_rx_ring_tlv_filter ath12k_mac_mon_status_filter_default;

drivers/net/wireless/ath/ath12k/wmi.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2222,6 +2222,7 @@ enum wmi_peer_chwidth {
22222222
WMI_PEER_CHWIDTH_40MHZ = 1,
22232223
WMI_PEER_CHWIDTH_80MHZ = 2,
22242224
WMI_PEER_CHWIDTH_160MHZ = 3,
2225+
WMI_PEER_CHWIDTH_320MHZ = 4,
22252226
};
22262227

22272228
enum wmi_beacon_gen_mode {

0 commit comments

Comments
 (0)