summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorLuis R. Rodriguez <lrodriguez@atheros.com>2009-01-07 17:43:34 -0800
committerJohn W. Linville <linville@tuxdriver.com>2009-01-29 15:59:59 -0500
commit3e0c3ff36c4c7b9e39af7d600e399664ca04e817 (patch)
tree837fa4d480d5f18bfb7bdb5f59c0caf5341d38eb /include
parent560e28e14f69ad3440a6e8c283dcfd37e1e41c2d (diff)
cfg80211: allow multiple driver regulatory_hints()
We add support for multiple drivers to provide a regulatory_hint() on a system by adding a wiphy specific regulatory domain cache. This allows drivers to keep around cache their own regulatory domain structure queried from CRDA. We handle conflicts by intersecting multiple regulatory domains, each driver will stick to its own regulatory domain though unless a country IE has been received and processed. If the user already requested a regulatory domain and a driver requests the same regulatory domain then simply copy to the driver's regd the same regulatory domain and do not call CRDA, do not collect $200. Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com> Acked-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'include')
-rw-r--r--include/net/wireless.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/net/wireless.h b/include/net/wireless.h
index 21c5d966142d..9e73aae40c5d 100644
--- a/include/net/wireless.h
+++ b/include/net/wireless.h
@@ -187,6 +187,10 @@ struct ieee80211_supported_band {
* we will disregard the first regulatory hint (when the
* initiator is %REGDOM_SET_BY_CORE).
* @reg_notifier: the driver's regulatory notification callback
+ * @regd: the driver's regulatory domain, if one was requested via
+ * the regulatory_hint() API. This can be used by the driver
+ * on the reg_notifier() if it chooses to ignore future
+ * regulatory domain changes caused by other drivers.
*/
struct wiphy {
/* assign these fields before you register the wiphy */
@@ -213,6 +217,8 @@ struct wiphy {
/* fields below are read-only, assigned by cfg80211 */
+ const struct ieee80211_regdomain *regd;
+
/* the item in /sys/class/ieee80211/ points to this,
* you need use set_wiphy_dev() (see below) */
struct device dev;