1 From 86f85575a3f6a20cef1c8bb98e78585fe3a53ccc Mon Sep 17 00:00:00 2001
2 From: Govindaraj Saminathan <quic_gsaminat@quicinc.com>
3 Date: Fri, 26 May 2023 12:41:06 +0300
4 Subject: [PATCH 82/84] wifi: ath11k: remove unused function
7 The function ath11k_tm_event_wmi() is only defined and it is not used
8 anywhere. Hence remove the unused.
10 Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
12 Signed-off-by: Govindaraj Saminathan <quic_gsaminat@quicinc.com>
13 Signed-off-by: Raj Kumar Bhagat <quic_rajkbhag@quicinc.com>
14 Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
15 Link: https://lore.kernel.org/r/20230517135934.16408-2-quic_rajkbhag@quicinc.com
17 drivers/net/wireless/ath/ath11k/testmode.c | 64 +---------------------
18 drivers/net/wireless/ath/ath11k/testmode.h | 8 +--
19 2 files changed, 2 insertions(+), 70 deletions(-)
21 --- a/drivers/net/wireless/ath/ath11k/testmode.c
22 +++ b/drivers/net/wireless/ath/ath11k/testmode.c
24 // SPDX-License-Identifier: BSD-3-Clause-Clear
26 * Copyright (c) 2018-2019 The Linux Foundation. All rights reserved.
27 + * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
31 @@ -20,69 +21,6 @@ static const struct nla_policy ath11k_tm
32 [ATH11K_TM_ATTR_VERSION_MINOR] = { .type = NLA_U32 },
35 -/* Returns true if callee consumes the skb and the skb should be discarded.
36 - * Returns false if skb is not used. Does not sleep.
38 -bool ath11k_tm_event_wmi(struct ath11k *ar, u32 cmd_id, struct sk_buff *skb)
40 - struct sk_buff *nl_skb;
44 - ath11k_dbg(ar->ab, ATH11K_DBG_TESTMODE,
45 - "testmode event wmi cmd_id %d skb %pK skb->len %d\n",
46 - cmd_id, skb, skb->len);
48 - ath11k_dbg_dump(ar->ab, ATH11K_DBG_TESTMODE, NULL, "", skb->data, skb->len);
50 - spin_lock_bh(&ar->data_lock);
54 - nl_skb = cfg80211_testmode_alloc_event_skb(ar->hw->wiphy,
55 - 2 * sizeof(u32) + skb->len,
59 - "failed to allocate skb for testmode wmi event\n");
63 - ret = nla_put_u32(nl_skb, ATH11K_TM_ATTR_CMD, ATH11K_TM_CMD_WMI);
66 - "failed to put testmode wmi event cmd attribute: %d\n",
72 - ret = nla_put_u32(nl_skb, ATH11K_TM_ATTR_WMI_CMDID, cmd_id);
75 - "failed to put testmode wmi even cmd_id: %d\n",
81 - ret = nla_put(nl_skb, ATH11K_TM_ATTR_DATA, skb->len, skb->data);
84 - "failed to copy skb to testmode wmi event: %d\n",
90 - cfg80211_testmode_event(nl_skb, GFP_ATOMIC);
93 - spin_unlock_bh(&ar->data_lock);
98 static int ath11k_tm_cmd_get_version(struct ath11k *ar, struct nlattr *tb[])
101 --- a/drivers/net/wireless/ath/ath11k/testmode.h
102 +++ b/drivers/net/wireless/ath/ath11k/testmode.h
104 /* SPDX-License-Identifier: BSD-3-Clause-Clear */
106 * Copyright (c) 2018-2019 The Linux Foundation. All rights reserved.
107 + * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
112 #ifdef CPTCFG_NL80211_TESTMODE
114 -bool ath11k_tm_event_wmi(struct ath11k *ar, u32 cmd_id, struct sk_buff *skb);
115 int ath11k_tm_cmd(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
116 void *data, int len);
120 -static inline bool ath11k_tm_event_wmi(struct ath11k *ar, u32 cmd_id,
121 - struct sk_buff *skb)
126 static inline int ath11k_tm_cmd(struct ieee80211_hw *hw,
127 struct ieee80211_vif *vif,