[openwrt/openwrt] ath10k-ct: fix build warnings on 6.12 kernel

LEDE Commits lede-commits at lists.infradead.org
Sat May 3 11:27:29 PDT 2025


hauke pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/bb192c47662a1563a4c0e052f5319350e4611319

commit bb192c47662a1563a4c0e052f5319350e4611319
Author: Shiji Yang <yangshiji66 at outlook.com>
AuthorDate: Mon Apr 28 23:48:12 2025 +0800

    ath10k-ct: fix build warnings on 6.12 kernel
    
    This patch fixes a lot of missing-prototypes warnings for the
    upcoming 6.12 kernel.
    
    Signed-off-by: Shiji Yang <yangshiji66 at outlook.com>
    Link: https://github.com/openwrt/openwrt/pull/18637
    Signed-off-by: Hauke Mehrtens <hauke at hauke-m.de>
---
 ...ix-missing-prototypes-warnings-on-6.12-ke.patch | 79 ++++++++++++++++++++++
 .../202-ath10k-use-tpt-trigger-by-default.patch    |  2 +-
 ...ath10k-always-use-mac80211-loss-detection.patch |  2 +-
 3 files changed, 81 insertions(+), 2 deletions(-)

diff --git a/package/kernel/ath10k-ct/patches/005-ath10k-ct-fix-missing-prototypes-warnings-on-6.12-ke.patch b/package/kernel/ath10k-ct/patches/005-ath10k-ct-fix-missing-prototypes-warnings-on-6.12-ke.patch
new file mode 100644
index 0000000000..84f3d1896b
--- /dev/null
+++ b/package/kernel/ath10k-ct/patches/005-ath10k-ct-fix-missing-prototypes-warnings-on-6.12-ke.patch
@@ -0,0 +1,79 @@
+From: Shiji Yang <yangshiji66 at outlook.com>
+Date: Mon, 28 Apr 2025 23:40:15 +0800
+Subject: [PATCH] ath10k-ct: fix missing-prototypes warnings on 6.12 kernel
+
+Fix various missing-prototypes warnings by:
+
+* Mark functions only used in current source file as static.
+* Comment out unused functions.
+
+/workspaces/openwrt/build_dir/target-x86_64_musl/linux-x86_64/ath10k-ct-regular/ath10k-ct-2025.03.14~63f5b605/ath10k-6.14/debug.c:425:6: error: no previous prototype for 'ath10k_debug_fw_ratepwr_table_process' [-Werror=missing-prototypes]
+  425 | void ath10k_debug_fw_ratepwr_table_process(struct ath10k *ar, struct sk_buff *skb)
+      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+/workspaces/openwrt/build_dir/target-x86_64_musl/linux-x86_64/ath10k-ct-regular/ath10k-ct-2025.03.14~63f5b605/ath10k-6.14/debug.c:437:6: error: no previous prototype for 'ath10k_debug_fw_powerctl_table_process' [-Werror=missing-prototypes]
+  437 | void ath10k_debug_fw_powerctl_table_process(struct ath10k *ar, struct sk_buff *skb)
+      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+/workspaces/openwrt/build_dir/target-x86_64_musl/linux-x86_64/ath10k-ct-regular/ath10k-ct-2025.03.14~63f5b605/ath10k-6.14/debug.c:884:5: error: no previous prototype for 'ath10k_refresh_target_pdev_ext_ct_stats' [-Werror=missing-prototypes]
+  884 | int ath10k_refresh_target_pdev_ext_ct_stats(struct ath10k *ar)
+      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+/workspaces/openwrt/build_dir/target-x86_64_musl/linux-x86_64/ath10k-ct-regular/ath10k-ct-2025.03.14~63f5b605/ath10k-6.14/htt_tx.c:1190:6: error: no previous prototype for 'ieee80211_is_robust_mgmt_frame_tx' [-Werror=missing-prototypes]
+ 1190 | bool ieee80211_is_robust_mgmt_frame_tx(struct ieee80211_hdr *hdr)
+      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+/workspaces/openwrt/build_dir/target-x86_64_musl/linux-x86_64/ath10k-ct-regular/ath10k-ct-2025.03.14~63f5b605/ath10k-6.14/wmi.c:3203:5: error: no previous prototype for 'ath10k_wmi_event_txbf_cv_mesg' [-Werror=missing-prototypes]
+ 3203 | int ath10k_wmi_event_txbf_cv_mesg(struct ath10k *ar, struct sk_buff *skb)
+      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Signed-off-by: Shiji Yang <yangshiji66 at outlook.com>
+---
+ ath10k-6.14/debug.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/ath10k-6.14/debug.c
++++ b/ath10k-6.14/debug.c
+@@ -422,6 +422,7 @@ static void ath10k_debug_fw_stats_reset(
+ 	spin_unlock_bh(&ar->data_lock);
+ }
+ 
++/*
+ void ath10k_debug_fw_ratepwr_table_process(struct ath10k *ar, struct sk_buff *skb)
+ {
+ 	size_t sz = skb->len;
+@@ -445,6 +446,7 @@ void ath10k_debug_fw_powerctl_table_proc
+ 	memcpy(ar->debug.powerctl_tbl.data, skb->data, sz);
+ 	complete(&ar->debug.powerctl_tbl_complete);
+ }
++*/
+ 
+ void ath10k_debug_fw_stats_process(struct ath10k *ar, struct sk_buff *skb)
+ {
+@@ -881,7 +883,7 @@ static int ath10k_refresh_target_rx_reor
+ 	return 0; /* fail silently if firmware does not support this option. */
+ }
+ 
+-int ath10k_refresh_target_pdev_ext_ct_stats(struct ath10k *ar)
++static int ath10k_refresh_target_pdev_ext_ct_stats(struct ath10k *ar)
+ {
+ 	if (test_bit(ATH10K_FW_FEATURE_CUST_STATS_CT,
+ 		     ar->running_fw->fw_file.fw_features))
+--- a/ath10k-6.14/htt_tx.c
++++ b/ath10k-6.14/htt_tx.c
+@@ -1187,7 +1187,7 @@ static u8 ath10k_htt_tx_get_tid(struct s
+  * since we do tx hw crypt, and it won't actually be encrypted even when this flag is
+  * set.
+  */
+-bool ieee80211_is_robust_mgmt_frame_tx(struct ieee80211_hdr *hdr)
++static bool ieee80211_is_robust_mgmt_frame_tx(struct ieee80211_hdr *hdr)
+ {
+         if (ieee80211_is_disassoc(hdr->frame_control) ||
+             ieee80211_is_deauth(hdr->frame_control))
+--- a/ath10k-6.14/wmi.c
++++ b/ath10k-6.14/wmi.c
+@@ -3200,7 +3200,7 @@ printme:
+ 	return 0;
+ }
+ 
+-int ath10k_wmi_event_txbf_cv_mesg(struct ath10k *ar, struct sk_buff *skb)
++static int ath10k_wmi_event_txbf_cv_mesg(struct ath10k *ar, struct sk_buff *skb)
+ {
+ 	struct wmi_txbf_cv_event *ev;
+ 
diff --git a/package/kernel/ath10k-ct/patches/202-ath10k-use-tpt-trigger-by-default.patch b/package/kernel/ath10k-ct/patches/202-ath10k-use-tpt-trigger-by-default.patch
index 34dd2101b9..47c4ad6079 100644
--- a/package/kernel/ath10k-ct/patches/202-ath10k-use-tpt-trigger-by-default.patch
+++ b/package/kernel/ath10k-ct/patches/202-ath10k-use-tpt-trigger-by-default.patch
@@ -40,7 +40,7 @@ Signed-off-by: Mathias Kresin <dev at kresin.me>
  	if (ret)
 --- a/ath10k-6.14/mac.c
 +++ b/ath10k-6.14/mac.c
-@@ -11651,7 +11651,7 @@ int ath10k_mac_register(struct ath10k *a
+@@ -11652,7 +11652,7 @@ int ath10k_mac_register(struct ath10k *a
  	ar->hw->weight_multiplier = ATH10K_AIRTIME_WEIGHT_MULTIPLIER;
  
  #ifdef CPTCFG_MAC80211_LEDS
diff --git a/package/kernel/ath10k-ct/patches/988-ath10k-always-use-mac80211-loss-detection.patch b/package/kernel/ath10k-ct/patches/988-ath10k-always-use-mac80211-loss-detection.patch
index 665581e4ab..e1bb1c7fa1 100644
--- a/package/kernel/ath10k-ct/patches/988-ath10k-always-use-mac80211-loss-detection.patch
+++ b/package/kernel/ath10k-ct/patches/988-ath10k-always-use-mac80211-loss-detection.patch
@@ -18,7 +18,7 @@ Signed-off-by: David Bauer <mail at david-bauer.net>
 
 --- a/ath10k-6.14/mac.c
 +++ b/ath10k-6.14/mac.c
-@@ -11337,7 +11337,6 @@ int ath10k_mac_register(struct ath10k *a
+@@ -11338,7 +11338,6 @@ int ath10k_mac_register(struct ath10k *a
  	ieee80211_hw_set(ar->hw, CHANCTX_STA_CSA);
  	ieee80211_hw_set(ar->hw, QUEUE_CONTROL);
  	ieee80211_hw_set(ar->hw, SUPPORTS_TX_FRAG);




More information about the lede-commits mailing list