* [PATCH] carl9170: remove get_tid_h
@ 2021-04-02 21:31 Christophe JAILLET
2021-04-02 21:52 ` Christian Lamparter
2021-04-18 6:36 ` Kalle Valo
0 siblings, 2 replies; 3+ messages in thread
From: Christophe JAILLET @ 2021-04-02 21:31 UTC (permalink / raw)
To: chunkeey, kvalo, davem, kuba
Cc: linux-wireless, netdev, linux-kernel, kernel-janitors,
Christophe JAILLET
'get_tid_h()' is the same as 'ieee80211_get_tid()'.
So this function can be removed to save a few lines of code.
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
---
drivers/net/wireless/ath/carl9170/carl9170.h | 7 +------
drivers/net/wireless/ath/carl9170/tx.c | 2 +-
2 files changed, 2 insertions(+), 7 deletions(-)
diff --git a/drivers/net/wireless/ath/carl9170/carl9170.h b/drivers/net/wireless/ath/carl9170/carl9170.h
index 0d38100d6e4f..84a8ce0784b1 100644
--- a/drivers/net/wireless/ath/carl9170/carl9170.h
+++ b/drivers/net/wireless/ath/carl9170/carl9170.h
@@ -631,14 +631,9 @@ static inline u16 carl9170_get_seq(struct sk_buff *skb)
return get_seq_h(carl9170_get_hdr(skb));
}
-static inline u16 get_tid_h(struct ieee80211_hdr *hdr)
-{
- return (ieee80211_get_qos_ctl(hdr))[0] & IEEE80211_QOS_CTL_TID_MASK;
-}
-
static inline u16 carl9170_get_tid(struct sk_buff *skb)
{
- return get_tid_h(carl9170_get_hdr(skb));
+ return ieee80211_get_tid(carl9170_get_hdr(skb));
}
static inline struct ieee80211_vif *
diff --git a/drivers/net/wireless/ath/carl9170/tx.c b/drivers/net/wireless/ath/carl9170/tx.c
index 6b8446ff48c8..88444fe6d1c6 100644
--- a/drivers/net/wireless/ath/carl9170/tx.c
+++ b/drivers/net/wireless/ath/carl9170/tx.c
@@ -394,7 +394,7 @@ static void carl9170_tx_status_process_ampdu(struct ar9170 *ar,
if (unlikely(!sta))
goto out_rcu;
- tid = get_tid_h(hdr);
+ tid = ieee80211_get_tid(hdr);
sta_info = (void *) sta->drv_priv;
tid_info = rcu_dereference(sta_info->agg[tid]);
--
2.27.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] carl9170: remove get_tid_h
2021-04-02 21:31 [PATCH] carl9170: remove get_tid_h Christophe JAILLET
@ 2021-04-02 21:52 ` Christian Lamparter
2021-04-18 6:36 ` Kalle Valo
1 sibling, 0 replies; 3+ messages in thread
From: Christian Lamparter @ 2021-04-02 21:52 UTC (permalink / raw)
To: Christophe JAILLET, kvalo, davem, kuba
Cc: linux-wireless, netdev, linux-kernel, kernel-janitors
On 02/04/2021 23:31, Christophe JAILLET wrote:
> 'get_tid_h()' is the same as 'ieee80211_get_tid()'.
> So this function can be removed to save a few lines of code.
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Acked-by: Christian Lamparter <chunkeey@gmail.com>
> ---
> drivers/net/wireless/ath/carl9170/carl9170.h | 7 +------
> drivers/net/wireless/ath/carl9170/tx.c | 2 +-
> 2 files changed, 2 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/carl9170/carl9170.h b/drivers/net/wireless/ath/carl9170/carl9170.h
> index 0d38100d6e4f..84a8ce0784b1 100644
> --- a/drivers/net/wireless/ath/carl9170/carl9170.h
> +++ b/drivers/net/wireless/ath/carl9170/carl9170.h
> @@ -631,14 +631,9 @@ static inline u16 carl9170_get_seq(struct sk_buff *skb)
> return get_seq_h(carl9170_get_hdr(skb));
> }
>
> -static inline u16 get_tid_h(struct ieee80211_hdr *hdr)
> -{
> - return (ieee80211_get_qos_ctl(hdr))[0] & IEEE80211_QOS_CTL_TID_MASK;
> -}
> -
> static inline u16 carl9170_get_tid(struct sk_buff *skb)
> {
> - return get_tid_h(carl9170_get_hdr(skb));
> + return ieee80211_get_tid(carl9170_get_hdr(skb));
> }
>
> static inline struct ieee80211_vif *
> diff --git a/drivers/net/wireless/ath/carl9170/tx.c b/drivers/net/wireless/ath/carl9170/tx.c
> index 6b8446ff48c8..88444fe6d1c6 100644
> --- a/drivers/net/wireless/ath/carl9170/tx.c
> +++ b/drivers/net/wireless/ath/carl9170/tx.c
> @@ -394,7 +394,7 @@ static void carl9170_tx_status_process_ampdu(struct ar9170 *ar,
> if (unlikely(!sta))
> goto out_rcu;
>
> - tid = get_tid_h(hdr);
> + tid = ieee80211_get_tid(hdr);
>
> sta_info = (void *) sta->drv_priv;
> tid_info = rcu_dereference(sta_info->agg[tid]);
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] carl9170: remove get_tid_h
2021-04-02 21:31 [PATCH] carl9170: remove get_tid_h Christophe JAILLET
2021-04-02 21:52 ` Christian Lamparter
@ 2021-04-18 6:36 ` Kalle Valo
1 sibling, 0 replies; 3+ messages in thread
From: Kalle Valo @ 2021-04-18 6:36 UTC (permalink / raw)
To: Christophe JAILLET
Cc: chunkeey, davem, kuba, linux-wireless, netdev, linux-kernel,
kernel-janitors, Christophe JAILLET
Christophe JAILLET <christophe.jaillet@wanadoo.fr> wrote:
> 'get_tid_h()' is the same as 'ieee80211_get_tid()'.
> So this function can be removed to save a few lines of code.
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> Acked-by: Christian Lamparter <chunkeey@gmail.com>
Patch applied to wireless-drivers-next.git, thanks.
cf366b154704 carl9170: remove get_tid_h
--
https://patchwork.kernel.org/project/linux-wireless/patch/68efad7a597159e22771d37fc8b4a8a613866d60.1617399010.git.christophe.jaillet@wanadoo.fr/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-04-18 6:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-02 21:31 [PATCH] carl9170: remove get_tid_h Christophe JAILLET
2021-04-02 21:52 ` Christian Lamparter
2021-04-18 6:36 ` Kalle Valo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).