All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andreas Wendleder <gonsolo@gmail.com>
To: linux-wireless@vger.kernel.org
Cc: Johannes Berg <johannes@sipsolutions.net>,
	b43-dev@lists.infradead.org, Michael Buesch <m@bues.ch>,
	Alessio Ferri <alessio.ferri@mythread.it>,
	kvalo@kernel.org, julian.calaby@gmail.com, jpeisach@ubuntu.com,
	linux-kernel@vger.kernel.org
Subject: [PATCH wireless-next 1/2] wifi: b43: reprogram the MAC filter after an interface restart
Date: Wed, 14 Oct 2026 16:32:24 +0200	[thread overview]
Message-ID: <20261014143225.82149-2-gonsolo@gmail.com> (raw)
In-Reply-To: <20261014143225.82149-1-gonsolo@gmail.com>

b43_op_start() clears wl->filter_flags, but mac80211 computes @changed
for b43_op_configure_filter() against the flags it cached from the
previous run. After a down/up it can report no change, so
b43_adjust_opmode() is not called and MACCTL keeps the cleared filter.

Compare the requested flags with what the hardware was programmed with
and add the difference to @changed.

Signed-off-by: Andreas Wendleder <gonsolo@gmail.com>
---
 drivers/net/wireless/broadcom/b43/main.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/net/wireless/broadcom/b43/main.c b/drivers/net/wireless/broadcom/b43/main.c
index 8f4aff3..57a5935 100644
--- a/drivers/net/wireless/broadcom/b43/main.c
+++ b/drivers/net/wireless/broadcom/b43/main.c
@@ -4318,6 +4318,14 @@ static void b43_op_configure_filter(struct ieee80211_hw *hw,
 		   FIF_OTHER_BSS |
 		   FIF_BCN_PRBRESP_PROMISC;
 
+	/*
+	 * b43_op_start() zeroes wl->filter_flags, but mac80211 computes
+	 * @changed against its own cached flags, so after an interface
+	 * restart it reports no change and MACCTL kept the zeroed filter.
+	 * Compare against what the hardware was actually programmed with.
+	 */
+	if (wl->filter_flags != *fflags)
+		changed |= wl->filter_flags ^ *fflags;
 	wl->filter_flags = *fflags;
 
 	if (changed && b43_status(dev) >= B43_STAT_INITIALIZED)

WARNING: multiple messages have this Message-ID (diff)
From: Andreas Wendleder <gonsolo@gmail.com>
To: linux-wireless@vger.kernel.org
Cc: julian.calaby@gmail.com, kvalo@kernel.org,
	linux-kernel@vger.kernel.org, b43-dev@lists.infradead.org,
	Michael Buesch <m@bues.ch>,
	Johannes Berg <johannes@sipsolutions.net>
Subject: [PATCH wireless-next 1/2] wifi: b43: reprogram the MAC filter after an interface restart
Date: Wed, 14 Oct 2026 16:32:24 +0200	[thread overview]
Message-ID: <20261014143225.82149-2-gonsolo@gmail.com> (raw)
In-Reply-To: <20261014143225.82149-1-gonsolo@gmail.com>

b43_op_start() clears wl->filter_flags, but mac80211 computes @changed
for b43_op_configure_filter() against the flags it cached from the
previous run. After a down/up it can report no change, so
b43_adjust_opmode() is not called and MACCTL keeps the cleared filter.

Compare the requested flags with what the hardware was programmed with
and add the difference to @changed.

Signed-off-by: Andreas Wendleder <gonsolo@gmail.com>
---
 drivers/net/wireless/broadcom/b43/main.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/net/wireless/broadcom/b43/main.c b/drivers/net/wireless/broadcom/b43/main.c
index 8f4aff3..57a5935 100644
--- a/drivers/net/wireless/broadcom/b43/main.c
+++ b/drivers/net/wireless/broadcom/b43/main.c
@@ -4318,6 +4318,14 @@ static void b43_op_configure_filter(struct ieee80211_hw *hw,
 		   FIF_OTHER_BSS |
 		   FIF_BCN_PRBRESP_PROMISC;
 
+	/*
+	 * b43_op_start() zeroes wl->filter_flags, but mac80211 computes
+	 * @changed against its own cached flags, so after an interface
+	 * restart it reports no change and MACCTL kept the zeroed filter.
+	 * Compare against what the hardware was actually programmed with.
+	 */
+	if (wl->filter_flags != *fflags)
+		changed |= wl->filter_flags ^ *fflags;
 	wl->filter_flags = *fflags;
 
 	if (changed && b43_status(dev) >= B43_STAT_INITIALIZED)

_______________________________________________
b43-dev mailing list
b43-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/b43-dev

  reply	other threads:[~2026-10-14 14:32 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-14 14:32 [PATCH wireless-next 0/2] wifi: b43: MAC filter and 64-bit DMA fixes for the BCM4360 Andreas Wendleder
2026-10-14 14:32 ` Andreas Wendleder
2026-10-14 14:32 ` Andreas Wendleder [this message]
2026-10-14 14:32   ` [PATCH wireless-next 1/2] wifi: b43: reprogram the MAC filter after an interface restart Andreas Wendleder
2026-10-14 14:32 ` [PATCH wireless-next 2/2] wifi: b43: handle 64-bit DMA engines whose index registers hold bus addresses Andreas Wendleder
2026-10-14 14:32   ` Andreas Wendleder

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=20261014143225.82149-2-gonsolo@gmail.com \
    --to=gonsolo@gmail.com \
    --cc=alessio.ferri@mythread.it \
    --cc=b43-dev@lists.infradead.org \
    --cc=johannes@sipsolutions.net \
    --cc=jpeisach@ubuntu.com \
    --cc=julian.calaby@gmail.com \
    --cc=kvalo@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=m@bues.ch \
    /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.