developer | 1d9da7d | 2023-04-15 12:45:34 +0800 | [diff] [blame^] | 1 | From 90338d1909357f0fac0ec1f0ead5f4a9b47524b9 Mon Sep 17 00:00:00 2001 |
developer | e2cc0fa | 2022-03-29 17:31:03 +0800 | [diff] [blame] | 2 | From: Shayne Chen <shayne.chen@mediatek.com> |
| 3 | Date: Tue, 29 Mar 2022 16:06:30 +0800 |
developer | ed7222c | 2023-04-14 07:19:52 +0800 | [diff] [blame] | 4 | Subject: [PATCH 02/17] nl80211: mtk: extend CAC time for weather radar |
developer | 3e4199d | 2022-10-19 14:18:06 +0800 | [diff] [blame] | 5 | channels |
developer | e2cc0fa | 2022-03-29 17:31:03 +0800 | [diff] [blame] | 6 | |
| 7 | Signed-off-by: Shayne Chen <shayne.chen@mediatek.com> |
| 8 | --- |
| 9 | net/wireless/nl80211.c | 7 +++++++ |
| 10 | 1 file changed, 7 insertions(+) |
| 11 | |
| 12 | diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c |
developer | 3e4199d | 2022-10-19 14:18:06 +0800 | [diff] [blame] | 13 | index bc6b5ac..3c6c1df 100644 |
developer | e2cc0fa | 2022-03-29 17:31:03 +0800 | [diff] [blame] | 14 | --- a/net/wireless/nl80211.c |
| 15 | +++ b/net/wireless/nl80211.c |
developer | 3e4199d | 2022-10-19 14:18:06 +0800 | [diff] [blame] | 16 | @@ -9354,6 +9354,13 @@ static int nl80211_start_radar_detection(struct sk_buff *skb, |
developer | e2cc0fa | 2022-03-29 17:31:03 +0800 | [diff] [blame] | 17 | if (WARN_ON(!cac_time_ms)) |
| 18 | cac_time_ms = IEEE80211_DFS_MIN_CAC_TIME_MS; |
| 19 | |
| 20 | + if ((dfs_region == NL80211_DFS_ETSI) && |
developer | beb7437 | 2022-05-06 16:53:33 +0800 | [diff] [blame] | 21 | + (((chandef.width == NL80211_CHAN_WIDTH_160) && |
developer | e2cc0fa | 2022-03-29 17:31:03 +0800 | [diff] [blame] | 22 | + (chandef.center_freq2 >= 5580 && chandef.center_freq2 <= 5640)) || |
developer | beb7437 | 2022-05-06 16:53:33 +0800 | [diff] [blame] | 23 | + (chandef.center_freq1 >= 5580 && chandef.center_freq1 <= 5640))) |
developer | e2cc0fa | 2022-03-29 17:31:03 +0800 | [diff] [blame] | 24 | + cac_time_ms = 600000; |
| 25 | + pr_info("%s: region = %u, cetner freq1 = %u, center freq2 = %u, cac time ms = %u\n", __func__, dfs_region, chandef.center_freq1, chandef.center_freq2, cac_time_ms); |
| 26 | + |
| 27 | err = rdev_start_radar_detection(rdev, dev, &chandef, cac_time_ms); |
| 28 | if (!err) { |
| 29 | wdev->chandef = chandef; |
| 30 | -- |
developer | ed7222c | 2023-04-14 07:19:52 +0800 | [diff] [blame] | 31 | 2.18.0 |
developer | e2cc0fa | 2022-03-29 17:31:03 +0800 | [diff] [blame] | 32 | |