From: Johannes Berg <johannes@sipsolutions.net>
To: greearb@candelatech.com, linux-wireless@vger.kernel.org
Subject: Re: [RFC PATCH 2/2] wifi: mac80211: Assign tx-stats to the proper link.
Date: Tue, 03 Sep 2024 12:13:57 +0200 [thread overview]
Message-ID: <ff685160d8d3c09db31fc8a77963eae2b0eca5b3.camel@sipsolutions.net> (raw)
In-Reply-To: <20240828155458.1990497-2-greearb@candelatech.com>
On Wed, 2024-08-28 at 08:54 -0700, greearb@candelatech.com wrote:
> From: Ben Greear <greearb@candelatech.com>
>
> For drivers that can report the tx link-id, account tx
> stats against that link. If we cannot determine tx link,
> then use deflink.
Strictly speaking, that's not what happens, since the link bits in the
SKB CB might be set on outgoing frames, and then will still be there on
the status.
Also using deflink is totally useless for MLO, so maybe just don't do
anything at all? But might be simpler to just do deflink and document
that the driver must set this? But not sure that really works so well
for drivers now.
> +static struct link_sta_info*
> +ieee80211_get_tx_link_sta(struct sta_info *sta, struct ieee80211_tx_info *info)
> +{
> + u8 link_id = u32_get_bits(info->control.flags, IEEE80211_TX_CTRL_MLO_LINK);
> + struct link_sta_info *l_sta_info;
We usually call that 'link_sta' ...
> @@ -48,6 +65,7 @@ static void ieee80211_handle_filtered_frame(struct ieee80211_local *local,
> struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
> struct ieee80211_hdr *hdr = (void *)skb->data;
> int ac;
> + struct link_sta_info *link_sta = ieee80211_get_tx_link_sta(sta, info);
and even you do, please be consistent with existing code and yourself.
>
> + link_sta = ieee80211_get_tx_link_sta(sta, info);
Does it really make sense to keep repeating this, rather than passing an
argument?
johannes
next prev parent reply other threads:[~2024-09-03 10:14 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-28 15:54 [RFC PATCH 1/2] wifi: iwlwifi: Report link-id for transmitted frames greearb
2024-08-28 15:54 ` [RFC PATCH 2/2] wifi: mac80211: Assign tx-stats to the proper link greearb
2024-09-03 10:13 ` Johannes Berg [this message]
2024-09-03 14:51 ` Ben Greear
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ff685160d8d3c09db31fc8a77963eae2b0eca5b3.camel@sipsolutions.net \
--to=johannes@sipsolutions.net \
--cc=greearb@candelatech.com \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox