From: Lorenzo Bianconi <lorenzo@kernel.org>
To: nbd@nbd.name
Cc: lorenzo.bianconi@redhat.com, linux-wireless@vger.kernel.org,
ryder.lee@mediatek.com, evelyn.tsai@mediatek.com,
owen.peng@mediatek.com, devicetree@vger.kernel.org,
robh@kernel.org
Subject: [PATCH v2 4/6] mt76: mt7915: report radar pattern if detected by rdd2
Date: Wed, 12 Jan 2022 18:53:53 +0100 [thread overview]
Message-ID: <db122b67bacde6e00677494a66ce6080b59f9924.1642009736.git.lorenzo@kernel.org> (raw)
In-Reply-To: <cover.1642009736.git.lorenzo@kernel.org>
Report radar pattern to mac80211 if detected by the
offchannel chain.
Tested-by: Evelyn Tsai <evelyn.tsai@mediatek.com>
Tested-by: Owen Peng <owen.peng@mediatek.com>
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
---
drivers/net/wireless/mediatek/mt76/mt7915/mcu.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c
index dddefeebc7dd..e42900b2545f 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c
@@ -358,7 +358,12 @@ mt7915_mcu_rx_radar_detected(struct mt7915_dev *dev, struct sk_buff *skb)
if (r->band_idx && dev->mt76.phy2)
mphy = dev->mt76.phy2;
- ieee80211_radar_detected(mphy->hw);
+ if (r->band_idx == MT_RX_SEL2)
+ cfg80211_background_radar_event(mphy->hw->wiphy,
+ &dev->rdd2_chandef,
+ GFP_ATOMIC);
+ else
+ ieee80211_radar_detected(mphy->hw);
dev->hw_pattern++;
}
--
2.34.1
next prev parent reply other threads:[~2022-01-12 17:54 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-12 17:53 [PATCH v2 0/6] introduce background radar support for mt7915 driver Lorenzo Bianconi
2022-01-12 17:53 ` [PATCH v2 1/6] mt76: mt7915: introduce mt7915_set_radar_background routine Lorenzo Bianconi
2022-01-12 17:53 ` [PATCH v2 2/6] mt76: mt7915: enable radar trigger on rdd2 Lorenzo Bianconi
2022-01-12 17:53 ` [PATCH v2 3/6] mt76: mt7915: introduce rdd_monitor debugfs node Lorenzo Bianconi
2022-01-12 17:53 ` Lorenzo Bianconi [this message]
2022-01-12 17:53 ` [PATCH v2 5/6] mt76: mt7915: enable radar background detection Lorenzo Bianconi
2022-01-12 17:53 ` [PATCH v2 6/6] dt-bindings:net:wireless:mediatek,mt76: add disable-radar-offchan Lorenzo Bianconi
2022-01-20 13:02 ` Kalle Valo
2022-01-20 13:18 ` Lorenzo Bianconi
2022-01-22 1:07 ` Rob Herring
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=db122b67bacde6e00677494a66ce6080b59f9924.1642009736.git.lorenzo@kernel.org \
--to=lorenzo@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=evelyn.tsai@mediatek.com \
--cc=linux-wireless@vger.kernel.org \
--cc=lorenzo.bianconi@redhat.com \
--cc=nbd@nbd.name \
--cc=owen.peng@mediatek.com \
--cc=robh@kernel.org \
--cc=ryder.lee@mediatek.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).