All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dmitry Antipov <dmantipov@yandex.ru>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: Felix Fietkau <nbd@nbd.name>, Kalle Valo <kvalo@kernel.org>,
	linux-wireless@vger.kernel.org, lvc-project@linuxtesting.org,
	syzbot+fdc5123366fb9c3fdc6d@syzkaller.appspotmail.com
Subject: Re: [PATCH] wifi: mac80211: don't ask rate control with zero rate mask if scanning
Date: Wed, 24 Jan 2024 18:11:16 +0300	[thread overview]
Message-ID: <6499241c-8508-45de-816b-f36c1a202801@yandex.ru> (raw)
In-Reply-To: <58970b94a314414402a932576ec54188c0675016.camel@sipsolutions.net>

On 1/19/24 20:19, Johannes Berg wrote:

> I was trying to let you come up with a patch for learning, but I think
> at this point just making one illustrates better what I'm thinking ...
> Here's one, but I haven't even compiled this:

Hmm... this:

> --- a/net/mac80211/tx.c
> +++ b/net/mac80211/tx.c
> @@ -701,7 +701,9 @@ ieee80211_tx_h_rate_ctrl(struct ieee80211_tx_data *tx)
>   	txrc.bss_conf = &tx->sdata->vif.bss_conf;
>   	txrc.skb = tx->skb;
>   	txrc.reported_rate.idx = -1;
> -	txrc.rate_idx_mask = tx->sdata->rc_rateidx_mask[info->band];
> +
> +	if (!(info->control.flags & IEEE80211_TX_CTRL_SCAN_TX))
> +		txrc.rate_idx_mask = tx->sdata->rc_rateidx_mask[info->band];
>   
>   	if (tx->sdata->rc_has_mcs_mask[info->band])
>   		txrc.rate_idx_mcs_mask =

leaves 'rate_idx_mask' unset (i.e. zero) even for band 0 and then
causes the same WARN_ONCE() even earlier (before switching to band 1).

Dmitry

  reply	other threads:[~2024-01-24 15:11 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-17 12:48 [PATCH] wifi: mac80211: don't ask rate control with zero rate mask if scanning Dmitry Antipov
2024-01-18 13:46 ` Johannes Berg
2024-01-19  8:07   ` Dmitry Antipov
2024-01-19 17:19     ` Johannes Berg
2024-01-24 15:11       ` Dmitry Antipov [this message]
2024-01-25  9:07       ` [PATCH 0/1] " Dmitry Antipov
2024-01-25  9:07         ` [PATCH 1/1] wifi: mac80211: ignore the bitrate mask when scanning Dmitry Antipov
2024-01-26 10:06           ` Johannes Berg
2024-01-26 10:05         ` [PATCH 0/1] Re: wifi: mac80211: don't ask rate control with zero rate mask if scanning Johannes Berg

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=6499241c-8508-45de-816b-f36c1a202801@yandex.ru \
    --to=dmantipov@yandex.ru \
    --cc=johannes@sipsolutions.net \
    --cc=kvalo@kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=lvc-project@linuxtesting.org \
    --cc=nbd@nbd.name \
    --cc=syzbot+fdc5123366fb9c3fdc6d@syzkaller.appspotmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.