Message ID | 20240626045216.3754013-4-quic_adisi@quicinc.com (mailing list archive) |
---|---|
State | Changes Requested |
Delegated to: | Johannes Berg |
Headers | show |
Series | wifi: cfg80211/mac80211: add DFS support for MLO | expand |
On Wed, 2024-06-26 at 10:22 +0530, Aditya Kumar Singh wrote: > Currently if any of the link is beaconing, CAC can not be started. > > However, with MLO, it is possible that interface is beaconing already on a > link that did not require CAC, but now another link is being started that > does require CAC. Hence, same check does not apply to MLO. > > Add changes to check the link under consideration is beaconing or not in > case of MLO. Also this really doesn't even do what it says, since it just checks link 0 ... I think some reordering here would be better. I'm also not sure it all needs to be in this many patches? Might be easier to have fewer, and put e.g. patch 6 first since it's just trivial prep. johannes
On 6/26/24 17:55, Johannes Berg wrote: > On Wed, 2024-06-26 at 10:22 +0530, Aditya Kumar Singh wrote: >> Currently if any of the link is beaconing, CAC can not be started. >> >> However, with MLO, it is possible that interface is beaconing already on a >> link that did not require CAC, but now another link is being started that >> does require CAC. Hence, same check does not apply to MLO. >> >> Add changes to check the link under consideration is beaconing or not in >> case of MLO. > > Also this really doesn't even do what it says, since it just checks link > 0 ... I think some reordering here would be better. > > I'm also not sure it all needs to be in this many patches? Might be > easier to have fewer, and put e.g. patch 6 first since it's just trivial > prep. > Sure will do.
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index b44332dc52be..7420a966997f 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -10025,7 +10025,20 @@ static int nl80211_start_radar_detection(struct sk_buff *skb, goto unlock; } - if (cfg80211_beaconing_iface_active(wdev) || wdev->links[0].cac_started) { + if (cfg80211_beaconing_iface_active(wdev)) { + /* During MLO other link(s) can beacon, only the current link + * can not already beacon + */ + if (wdev->valid_links && + !wdev->links[0].ap.beacon_interval) { + /* nothing */ + } else { + err = -EBUSY; + goto unlock; + } + } + + if (wdev->links[0].cac_started) { err = -EBUSY; goto unlock; }
Currently if any of the link is beaconing, CAC can not be started. However, with MLO, it is possible that interface is beaconing already on a link that did not require CAC, but now another link is being started that does require CAC. Hence, same check does not apply to MLO. Add changes to check the link under consideration is beaconing or not in case of MLO. Signed-off-by: Aditya Kumar Singh <quic_adisi@quicinc.com> --- net/wireless/nl80211.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-)