]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
cfg80211: split wext compatibility to separate header
authorJohannes Berg <johannes.berg@intel.com>
Wed, 13 Jul 2011 08:39:09 +0000 (10:39 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 8 Aug 2011 18:24:59 +0000 (14:24 -0400)
A lot of drivers erroneously use wext constants
and don't notice since cfg80211.h includes them.
Make this more split up so drivers needing wext
compatibility from cfg80211 need to explicitly
include that from cfg80211-wext.h.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ipw2x00/ipw2200.c
drivers/net/wireless/orinoco/wext.c
include/net/cfg80211-wext.h [new file with mode: 0644]
include/net/cfg80211.h
net/wireless/scan.c
net/wireless/wext-compat.c
net/wireless/wext-sme.c

index 87813c33bdc2a4f1632cc2007242ef8e2c067379..4395977d536969c208ab148957b04eaf3441369e 100644 (file)
@@ -32,6 +32,7 @@
 
 #include <linux/sched.h>
 #include <linux/slab.h>
+#include <net/cfg80211-wext.h>
 #include "ipw2200.h"
 
 
index bbb9beb206b1b9e8e590fa28c9d0e1dacca39670..33747e131a968e19f409de68e4edc92b6b2063e5 100644 (file)
@@ -9,6 +9,7 @@
 #include <linux/ieee80211.h>
 #include <net/iw_handler.h>
 #include <net/cfg80211.h>
+#include <net/cfg80211-wext.h>
 
 #include "hermes.h"
 #include "hermes_rid.h"
diff --git a/include/net/cfg80211-wext.h b/include/net/cfg80211-wext.h
new file mode 100644 (file)
index 0000000..2040642
--- /dev/null
@@ -0,0 +1,124 @@
+#ifndef __NET_CFG80211_WEXT_H
+#define __NET_CFG80211_WEXT_H
+/*
+ * 802.11 device and configuration interface -- wext handlers
+ *
+ * Copyright 2006-2010 Johannes Berg <johannes@sipsolutions.net>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include <linux/netdevice.h>
+#include <linux/wireless.h>
+#include <net/iw_handler.h>
+
+/*
+ * Temporary wext handlers & helper functions
+ *
+ * These are used only by drivers that aren't yet fully
+ * converted to cfg80211.
+ */
+int cfg80211_wext_giwname(struct net_device *dev,
+                         struct iw_request_info *info,
+                         char *name, char *extra);
+int cfg80211_wext_siwmode(struct net_device *dev, struct iw_request_info *info,
+                         u32 *mode, char *extra);
+int cfg80211_wext_giwmode(struct net_device *dev, struct iw_request_info *info,
+                         u32 *mode, char *extra);
+int cfg80211_wext_siwscan(struct net_device *dev,
+                         struct iw_request_info *info,
+                         union iwreq_data *wrqu, char *extra);
+int cfg80211_wext_giwscan(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_point *data, char *extra);
+int cfg80211_wext_siwmlme(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_point *data, char *extra);
+int cfg80211_wext_giwrange(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_point *data, char *extra);
+int cfg80211_wext_siwgenie(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_point *data, char *extra);
+int cfg80211_wext_siwauth(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_param *data, char *extra);
+int cfg80211_wext_giwauth(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_param *data, char *extra);
+
+int cfg80211_wext_siwfreq(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_freq *freq, char *extra);
+int cfg80211_wext_giwfreq(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_freq *freq, char *extra);
+int cfg80211_wext_siwessid(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_point *data, char *ssid);
+int cfg80211_wext_giwessid(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_point *data, char *ssid);
+int cfg80211_wext_siwrate(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_param *rate, char *extra);
+int cfg80211_wext_giwrate(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_param *rate, char *extra);
+
+int cfg80211_wext_siwrts(struct net_device *dev,
+                        struct iw_request_info *info,
+                        struct iw_param *rts, char *extra);
+int cfg80211_wext_giwrts(struct net_device *dev,
+                        struct iw_request_info *info,
+                        struct iw_param *rts, char *extra);
+int cfg80211_wext_siwfrag(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_param *frag, char *extra);
+int cfg80211_wext_giwfrag(struct net_device *dev,
+                         struct iw_request_info *info,
+                         struct iw_param *frag, char *extra);
+int cfg80211_wext_siwretry(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_param *retry, char *extra);
+int cfg80211_wext_giwretry(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_param *retry, char *extra);
+int cfg80211_wext_siwencodeext(struct net_device *dev,
+                              struct iw_request_info *info,
+                              struct iw_point *erq, char *extra);
+int cfg80211_wext_siwencode(struct net_device *dev,
+                           struct iw_request_info *info,
+                           struct iw_point *erq, char *keybuf);
+int cfg80211_wext_giwencode(struct net_device *dev,
+                           struct iw_request_info *info,
+                           struct iw_point *erq, char *keybuf);
+int cfg80211_wext_siwtxpower(struct net_device *dev,
+                            struct iw_request_info *info,
+                            union iwreq_data *data, char *keybuf);
+int cfg80211_wext_giwtxpower(struct net_device *dev,
+                            struct iw_request_info *info,
+                            union iwreq_data *data, char *keybuf);
+struct iw_statistics *cfg80211_wireless_stats(struct net_device *dev);
+
+int cfg80211_wext_siwpower(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_param *wrq, char *extra);
+int cfg80211_wext_giwpower(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_param *wrq, char *extra);
+
+int cfg80211_wext_siwap(struct net_device *dev,
+                       struct iw_request_info *info,
+                       struct sockaddr *ap_addr, char *extra);
+int cfg80211_wext_giwap(struct net_device *dev,
+                       struct iw_request_info *info,
+                       struct sockaddr *ap_addr, char *extra);
+
+int cfg80211_wext_siwpmksa(struct net_device *dev,
+                          struct iw_request_info *info,
+                          struct iw_point *data, char *extra);
+
+#endif /* __NET_CFG80211_WEXT_H */
index d17f47fc9e31b9a3298b1911b5c46c9fb34d3400..44e72cc13055497d289992053bb84aede2bb39e0 100644 (file)
 #include <linux/ieee80211.h>
 #include <net/regulatory.h>
 
-/* remove once we remove the wext stuff */
-#include <net/iw_handler.h>
-#include <linux/wireless.h>
-
-
 /**
  * DOC: Introduction
  *
@@ -2392,113 +2387,6 @@ extern int freq_reg_info(struct wiphy *wiphy,
                         u32 desired_bw_khz,
                         const struct ieee80211_reg_rule **reg_rule);
 
-/*
- * Temporary wext handlers & helper functions
- *
- * In the future cfg80211 will simply assign the entire wext handler
- * structure to netdevs it manages, but we're not there yet.
- */
-int cfg80211_wext_giwname(struct net_device *dev,
-                         struct iw_request_info *info,
-                         char *name, char *extra);
-int cfg80211_wext_siwmode(struct net_device *dev, struct iw_request_info *info,
-                         u32 *mode, char *extra);
-int cfg80211_wext_giwmode(struct net_device *dev, struct iw_request_info *info,
-                         u32 *mode, char *extra);
-int cfg80211_wext_siwscan(struct net_device *dev,
-                         struct iw_request_info *info,
-                         union iwreq_data *wrqu, char *extra);
-int cfg80211_wext_giwscan(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_point *data, char *extra);
-int cfg80211_wext_siwmlme(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_point *data, char *extra);
-int cfg80211_wext_giwrange(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_point *data, char *extra);
-int cfg80211_wext_siwgenie(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_point *data, char *extra);
-int cfg80211_wext_siwauth(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_param *data, char *extra);
-int cfg80211_wext_giwauth(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_param *data, char *extra);
-
-int cfg80211_wext_siwfreq(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_freq *freq, char *extra);
-int cfg80211_wext_giwfreq(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_freq *freq, char *extra);
-int cfg80211_wext_siwessid(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_point *data, char *ssid);
-int cfg80211_wext_giwessid(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_point *data, char *ssid);
-int cfg80211_wext_siwrate(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_param *rate, char *extra);
-int cfg80211_wext_giwrate(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_param *rate, char *extra);
-
-int cfg80211_wext_siwrts(struct net_device *dev,
-                        struct iw_request_info *info,
-                        struct iw_param *rts, char *extra);
-int cfg80211_wext_giwrts(struct net_device *dev,
-                        struct iw_request_info *info,
-                        struct iw_param *rts, char *extra);
-int cfg80211_wext_siwfrag(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_param *frag, char *extra);
-int cfg80211_wext_giwfrag(struct net_device *dev,
-                         struct iw_request_info *info,
-                         struct iw_param *frag, char *extra);
-int cfg80211_wext_siwretry(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_param *retry, char *extra);
-int cfg80211_wext_giwretry(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_param *retry, char *extra);
-int cfg80211_wext_siwencodeext(struct net_device *dev,
-                              struct iw_request_info *info,
-                              struct iw_point *erq, char *extra);
-int cfg80211_wext_siwencode(struct net_device *dev,
-                           struct iw_request_info *info,
-                           struct iw_point *erq, char *keybuf);
-int cfg80211_wext_giwencode(struct net_device *dev,
-                           struct iw_request_info *info,
-                           struct iw_point *erq, char *keybuf);
-int cfg80211_wext_siwtxpower(struct net_device *dev,
-                            struct iw_request_info *info,
-                            union iwreq_data *data, char *keybuf);
-int cfg80211_wext_giwtxpower(struct net_device *dev,
-                            struct iw_request_info *info,
-                            union iwreq_data *data, char *keybuf);
-struct iw_statistics *cfg80211_wireless_stats(struct net_device *dev);
-
-int cfg80211_wext_siwpower(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_param *wrq, char *extra);
-int cfg80211_wext_giwpower(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_param *wrq, char *extra);
-
-int cfg80211_wext_siwap(struct net_device *dev,
-                       struct iw_request_info *info,
-                       struct sockaddr *ap_addr, char *extra);
-int cfg80211_wext_giwap(struct net_device *dev,
-                       struct iw_request_info *info,
-                       struct sockaddr *ap_addr, char *extra);
-
-int cfg80211_wext_siwpmksa(struct net_device *dev,
-                          struct iw_request_info *info,
-                          struct iw_point *data, char *extra);
-
 /*
  * callbacks for asynchronous cfg80211 methods, notification
  * functions and BSS handling helpers
index 2936cb809152cd77451147c22045924396026bbc..b0f0039669536164f0f9d67147030f3f43c8a0a0 100644 (file)
@@ -12,6 +12,7 @@
 #include <linux/etherdevice.h>
 #include <net/arp.h>
 #include <net/cfg80211.h>
+#include <net/cfg80211-wext.h>
 #include <net/iw_handler.h>
 #include "core.h"
 #include "nl80211.h"
index 0bf169bb770ed695b9829b234511ba0ce576cb58..355a63a46c428be4bd948453bd699a5f5970de50 100644 (file)
@@ -15,6 +15,7 @@
 #include <linux/slab.h>
 #include <net/iw_handler.h>
 #include <net/cfg80211.h>
+#include <net/cfg80211-wext.h>
 #include "wext-compat.h"
 #include "core.h"
 
index 6fffe62d7c25b27cc9c6d6bc58635aa91f333e9f..494a12ff446f5d3ff7cef3f371c920f17b7eb52c 100644 (file)
@@ -9,6 +9,7 @@
 #include <linux/if_arp.h>
 #include <linux/slab.h>
 #include <net/cfg80211.h>
+#include <net/cfg80211-wext.h>
 #include "wext-compat.h"
 #include "nl80211.h"