All of lore.kernel.org
 help / color / mirror / Atom feed
From: gregory.greenman@intel.com
To: johannes@sipsolutions.net
Cc: linux-wireless@vger.kernel.org,
	Johannes Berg <johannes.berg@intel.com>,
	Gregory Greenman <gregory.greenman@intel.com>
Subject: [PATCH 03/16] wifi: mac80211: don't translate beacon/presp addrs
Date: Sun,  4 Jun 2023 12:11:15 +0300	[thread overview]
Message-ID: <20230604120651.62adead1b43a.Ifc25eed26ebf3b269f60b1ec10060156d0e7ec0d@changeid> (raw)
In-Reply-To: <20230604091128.609335-1-gregory.greenman@intel.com>

From: Johannes Berg <johannes.berg@intel.com>

Don't do link address translation for beacons and probe responses,
this leads to reporting multiple scan list entries for the same AP
(one with the MLD address) which just breaks things.

We might need to extend this in the future for some other (action)
frames that aren't MLD addressed.

Fixes: 42fb9148c078 ("wifi: mac80211: do link->MLD address translation on RX")
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
---
 net/mac80211/rx.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
index 58222c077898..d996aa2579df 100644
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -4965,7 +4965,9 @@ static bool ieee80211_prepare_and_rx_handle(struct ieee80211_rx_data *rx,
 	}
 
 	if (unlikely(rx->sta && rx->sta->sta.mlo) &&
-	    is_unicast_ether_addr(hdr->addr1)) {
+	    is_unicast_ether_addr(hdr->addr1) &&
+	    !ieee80211_is_probe_resp(hdr->frame_control) &&
+	    !ieee80211_is_beacon(hdr->frame_control)) {
 		/* translate to MLD addresses */
 		if (ether_addr_equal(link->conf->addr, hdr->addr1))
 			ether_addr_copy(hdr->addr1, rx->sdata->vif.addr);
-- 
2.38.1


  parent reply	other threads:[~2023-06-04  9:11 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-04  9:11 [PATCH 00/16] cfg80211/mac80211 patches from our internal tree 2023-06-04 gregory.greenman
2023-06-04  9:11 ` [PATCH 01/16] wifi: mac80211: use u64 to hold enum ieee80211_bss_change flags gregory.greenman
2023-06-04  9:11 ` [PATCH 02/16] wifi: mac80211: refactor ieee80211_select_link_key() gregory.greenman
2023-06-04  9:11 ` gregory.greenman [this message]
2023-06-04  9:11 ` [PATCH 04/16] wifi: mac80211: mlme: fix non-inheritence element gregory.greenman
2023-06-04  9:11 ` [PATCH 05/16] wifi: mac80211: provide a helper to fetch the medium synchronization delay gregory.greenman
2023-06-04  9:11 ` [PATCH 06/16] wifi: cfg80211: reject bad AP MLD address gregory.greenman
2023-06-04  9:11 ` [PATCH 07/16] wifi: mac80211_hwsim: check the return value of nla_put_u32 gregory.greenman
2023-06-04  9:11 ` [PATCH 08/16] wifi: mac80211: recalc min chandef for new STA links gregory.greenman
2023-06-04  9:11 ` [PATCH 09/16] wifi: mac80211: move sta_info_move_state() up gregory.greenman
2023-06-04  9:11 ` [PATCH 10/16] wifi: mac80211: batch recalc during STA flush gregory.greenman
2023-06-04  9:11 ` [PATCH 11/16] wifi: mac80211: use correct iftype HE cap gregory.greenman
2023-06-04  9:11 ` [PATCH 12/16] wifi: mac80211: add helpers to access sband iftype data gregory.greenman
2023-06-04  9:11 ` [PATCH 13/16] wifi: mac80211: remove typecast in a call to ieee80211_config_bw() gregory.greenman
2023-06-06 13:18   ` Nicolas Escande
2023-06-06 13:22     ` Johannes Berg
2023-06-04  9:11 ` [PATCH 14/16] wifi: mac80211: Modify type of "changed" variable gregory.greenman
2023-12-02 17:56   ` Jeff Johnson
2023-12-03 16:48     ` Jeff Johnson
2023-12-03 18:42       ` Johannes Berg
2023-06-04  9:11 ` [PATCH 15/16] wifi: mac80211_hwsim: Fix possible NULL dereference gregory.greenman
2023-06-04  9:11 ` [PATCH 16/16] wifi: mac80211: stop warning after reconfig failures gregory.greenman

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=20230604120651.62adead1b43a.Ifc25eed26ebf3b269f60b1ec10060156d0e7ec0d@changeid \
    --to=gregory.greenman@intel.com \
    --cc=johannes.berg@intel.com \
    --cc=johannes@sipsolutions.net \
    --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 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.