|
6 | 6 | * Copyright 2009 Johannes Berg <johannes@sipsolutions.net> |
7 | 7 | */ |
8 | 8 |
|
| 9 | +#include <linux/export.h> |
9 | 10 | #include <net/cfg80211.h> |
10 | 11 | #include "core.h" |
11 | 12 |
|
@@ -44,9 +45,9 @@ rdev_freq_to_chan(struct cfg80211_registered_device *rdev, |
44 | 45 | return chan; |
45 | 46 | } |
46 | 47 |
|
47 | | -static bool can_beacon_sec_chan(struct wiphy *wiphy, |
48 | | - struct ieee80211_channel *chan, |
49 | | - enum nl80211_channel_type channel_type) |
| 48 | +int cfg80211_can_beacon_sec_chan(struct wiphy *wiphy, |
| 49 | + struct ieee80211_channel *chan, |
| 50 | + enum nl80211_channel_type channel_type) |
50 | 51 | { |
51 | 52 | struct ieee80211_channel *sec_chan; |
52 | 53 | int diff; |
@@ -75,6 +76,7 @@ static bool can_beacon_sec_chan(struct wiphy *wiphy, |
75 | 76 |
|
76 | 77 | return true; |
77 | 78 | } |
| 79 | +EXPORT_SYMBOL(cfg80211_can_beacon_sec_chan); |
78 | 80 |
|
79 | 81 | int cfg80211_set_freq(struct cfg80211_registered_device *rdev, |
80 | 82 | struct wireless_dev *wdev, int freq, |
@@ -109,8 +111,8 @@ int cfg80211_set_freq(struct cfg80211_registered_device *rdev, |
109 | 111 | switch (channel_type) { |
110 | 112 | case NL80211_CHAN_HT40PLUS: |
111 | 113 | case NL80211_CHAN_HT40MINUS: |
112 | | - if (!can_beacon_sec_chan(&rdev->wiphy, chan, |
113 | | - channel_type)) { |
| 114 | + if (!cfg80211_can_beacon_sec_chan(&rdev->wiphy, chan, |
| 115 | + channel_type)) { |
114 | 116 | printk(KERN_DEBUG |
115 | 117 | "cfg80211: Secondary channel not " |
116 | 118 | "allowed to initiate communication\n"); |
|
0 commit comments