[pkg-wpa-devel] r859 - in /hostapd/trunk/debian: changelog patches/20_madwifi_headers.dpatch

paravoid at users.alioth.debian.org paravoid at users.alioth.debian.org
Sun Jul 22 18:39:55 UTC 2007


Author: paravoid
Date: Sun Jul 22 18:39:55 2007
New Revision: 859

URL: http://svn.debian.org/wsvn/pkg-wpa/?sc=1&rev=859
Log:
* Update madwifi includes to r2583. This might break old installations, but
  will fix setups with 6-month old madwifi. (Closes: #408642)

Modified:
    hostapd/trunk/debian/changelog
    hostapd/trunk/debian/patches/20_madwifi_headers.dpatch

Modified: hostapd/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-wpa/hostapd/trunk/debian/changelog?rev=859&op=diff
==============================================================================
--- hostapd/trunk/debian/changelog (original)
+++ hostapd/trunk/debian/changelog Sun Jul 22 18:39:55 2007
@@ -12,8 +12,10 @@
   * Move /e/n/if-pre-up.d/hostap to zz-hostap to correctly work with madwifi
     setups that create the interface in pre-up. Thanks to Elmar Hoffmann.
     (Closes: #427713)
-
- -- Faidon Liambotis <paravoid at debian.org>  Sun, 22 Jul 2007 21:23:05 +0300
+  * Update madwifi includes to r2583. This might break old installations, but
+    will fix setups with 6-month old madwifi. (Closes: #408642)
+
+ -- Faidon Liambotis <paravoid at debian.org>  Sun, 22 Jul 2007 21:38:02 +0300
 
 hostapd (1:0.5.7-1) unstable; urgency=low
 

Modified: hostapd/trunk/debian/patches/20_madwifi_headers.dpatch
URL: http://svn.debian.org/wsvn/pkg-wpa/hostapd/trunk/debian/patches/20_madwifi_headers.dpatch?rev=859&op=diff
==============================================================================
--- hostapd/trunk/debian/patches/20_madwifi_headers.dpatch (original)
+++ hostapd/trunk/debian/patches/20_madwifi_headers.dpatch Sun Jul 22 18:39:55 2007
@@ -2,13 +2,13 @@
 ## wpa_madwifing_r2157_includes.patch by Kel Modderman <kel at otaku42.de>
 ##
 ## All lines beginning with `## DP:' are a description of the patch.
-## DP: Includes for madwifi private ioctl's (madwifi.org svn trunk r2157).
+## DP: Includes for madwifi private ioctl's (madwifi.org svn trunk r2583).
 
 @DPATCH@
-diff -Nrup wpa_supplicant.orig/driver_madwifi/include/compat.h wpa_supplicant/driver_madwifi/include/compat.h
---- wpa_supplicant.orig/driver_madwifi/include/compat.h	1970-01-01 10:00:00.000000000 +1000
-+++ wpa_supplicant/driver_madwifi/include/compat.h	2007-02-25 00:16:43.000000000 +1000
-@@ -0,0 +1,127 @@
+diff -urNad trunk~/driver_madwifi/include/compat.h trunk/driver_madwifi/include/compat.h
+--- trunk~/driver_madwifi/include/compat.h	1970-01-01 02:00:00.000000000 +0200
++++ trunk/driver_madwifi/include/compat.h	2007-07-22 21:34:44.000000000 +0300
+@@ -0,0 +1,147 @@
 +/*-
 + * Copyright (c) 2002-2005 Sam Leffler, Errno Consulting
 + * All rights reserved.
@@ -44,7 +44,7 @@
 + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 + * THE POSSIBILITY OF SUCH DAMAGES.
 + *
-+ * $Id: compat.h 2141 2007-02-21 06:46:24Z proski $
++ * $Id: compat.h 2562 2007-07-08 05:55:31Z proski $
 + */
 +#ifndef _ATH_COMPAT_H_
 +#define _ATH_COMPAT_H_
@@ -65,8 +65,8 @@
 +
 +#ifndef container_of
 +#define container_of(ptr, type, member) ({			\
-+        const typeof( ((type *)0)->member ) *__mptr = (ptr);	\
-+        (type *)( (char *)__mptr - offsetof(type,member) );})
++	    const typeof( ((type *)0)->member ) *__mptr = (ptr);	\
++	    (type *)( (char *)__mptr - offsetof(type,member) );})
 +#endif
 +
 +/*
@@ -78,7 +78,7 @@
 +/* roundup() appears in Linux 2.6.18 */
 +#include <linux/kernel.h>
 +#ifndef roundup
-+#define	roundup(x, y)	((((x)+((y)-1))/(y))*(y))  /* to any y */ 
++#define	roundup(x, y)	((((x)+((y)-1))/(y))*(y))  /* to any y */
 +#endif
 +
 +#define	howmany(x, y)	(((x)+((y)-1))/(y))
@@ -127,19 +127,39 @@
 + * Fixes for Linux API changes
 + */
 +#ifdef __KERNEL__
++
 +#include <linux/version.h>
 +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,21)
 +#define ATH_REGISTER_SYSCTL_TABLE(t) register_sysctl_table(t, 1)
 +#else
 +#define ATH_REGISTER_SYSCTL_TABLE(t) register_sysctl_table(t)
 +#endif
++
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,9)
++#define __user
++#define __kernel
++#define __iomem
 +#endif
 +
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,22)
++#define skb_end_pointer(_skb) ((_skb)->end)
++#define skb_tail_pointer(_skb) ((_skb)->tail)
++#define skb_set_network_header(_skb, _offset) \
++	do { (_skb)->nh.raw = (_skb)->data + (_offset); } while(0)
++#define skb_reset_network_header(_skb) \
++	do { (_skb)->nh.raw = (_skb)->data; } while(0)
++#define skb_mac_header(_skb) ((_skb)->mac.raw)
++#define skb_reset_mac_header(_skb) \
++	do { (_skb)->mac.raw = (_skb)->data; } while(0)
++#endif
++
++#endif /* __KERNEL__ */
++
 +#endif /* _ATH_COMPAT_H_ */
-diff -Nrup wpa_supplicant.orig/driver_madwifi/net80211/ieee80211_crypto.h wpa_supplicant/driver_madwifi/net80211/ieee80211_crypto.h
---- wpa_supplicant.orig/driver_madwifi/net80211/ieee80211_crypto.h	1970-01-01 10:00:00.000000000 +1000
-+++ wpa_supplicant/driver_madwifi/net80211/ieee80211_crypto.h	2006-04-12 21:36:10.000000000 +1000
-@@ -0,0 +1,205 @@
+diff -urNad trunk~/driver_madwifi/net80211/_ieee80211.h trunk/driver_madwifi/net80211/_ieee80211.h
+--- trunk~/driver_madwifi/net80211/_ieee80211.h	1970-01-01 02:00:00.000000000 +0200
++++ trunk/driver_madwifi/net80211/_ieee80211.h	2007-07-22 21:34:16.000000000 +0300
+@@ -0,0 +1,244 @@
 +/*-
 + * Copyright (c) 2001 Atsushi Onoe
 + * Copyright (c) 2002-2005 Sam Leffler, Errno Consulting
@@ -171,216 +191,7 @@
 + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
 + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 + *
-+ * $Id: ieee80211_crypto.h 1441 2006-02-06 16:03:21Z mrenzmann $
-+ */
-+#ifndef _NET80211_IEEE80211_CRYPTO_H_
-+#define _NET80211_IEEE80211_CRYPTO_H_
-+
-+/*
-+ * 802.11 protocol crypto-related definitions.
-+ */
-+#define	IEEE80211_KEYBUF_SIZE	16
-+#define	IEEE80211_MICBUF_SIZE	(8 + 8)		/* space for both tx+rx keys */
-+#define IEEE80211_TID_SIZE	17		/* total number of TIDs */
-+
-+/*
-+ * Old WEP-style key.  Deprecated.
-+ */
-+struct ieee80211_wepkey {
-+	u_int wk_len;				/* key length in bytes */
-+	u_int8_t wk_key[IEEE80211_KEYBUF_SIZE];
-+};
-+
-+struct ieee80211_cipher;
-+
-+/*
-+ * Crypto key state.  There is sufficient room for all supported
-+ * ciphers (see below).  The underlying ciphers are handled
-+ * separately through loadable cipher modules that register with
-+ * the generic crypto support.  A key has a reference to an instance
-+ * of the cipher; any per-key state is hung off wk_private by the
-+ * cipher when it is attached.  Ciphers are automatically called
-+ * to detach and cleanup any such state when the key is deleted.
-+ *
-+ * The generic crypto support handles encap/decap of cipher-related
-+ * frame contents for both hardware- and software-based implementations.
-+ * A key requiring software crypto support is automatically flagged and
-+ * the cipher is expected to honor this and do the necessary work.
-+ * Ciphers such as TKIP may also support mixed hardware/software
-+ * encrypt/decrypt and MIC processing.
-+ */
-+/* XXX need key index typedef */
-+/* XXX pack better? */
-+/* XXX 48-bit rsc/tsc */
-+struct ieee80211_key {
-+	u_int8_t wk_keylen;		/* key length in bytes */
-+	u_int8_t wk_flags;
-+#define	IEEE80211_KEY_XMIT	0x01	/* key used for xmit */
-+#define	IEEE80211_KEY_RECV	0x02	/* key used for recv */
-+#define	IEEE80211_KEY_GROUP	0x04	/* key used for WPA group operation */
-+#define	IEEE80211_KEY_SWCRYPT	0x10	/* host-based encrypt/decrypt */
-+#define	IEEE80211_KEY_SWMIC	0x20	/* host-based enmic/demic */
-+	u_int16_t wk_keyix;		/* key index */
-+	u_int8_t wk_key[IEEE80211_KEYBUF_SIZE+IEEE80211_MICBUF_SIZE];
-+#define	wk_txmic	wk_key+IEEE80211_KEYBUF_SIZE+0	/* XXX can't () right */
-+#define	wk_rxmic	wk_key+IEEE80211_KEYBUF_SIZE+8	/* XXX can't () right */
-+	u_int64_t wk_keyrsc[IEEE80211_TID_SIZE];	/* key receive sequence counter */
-+	u_int64_t wk_keytsc;		/* key transmit sequence counter */
-+	const struct ieee80211_cipher *wk_cipher;
-+	void *wk_private;		/* private cipher state */
-+};
-+#define	IEEE80211_KEY_COMMON 		/* common flags passed in by apps */\
-+	(IEEE80211_KEY_XMIT | IEEE80211_KEY_RECV | IEEE80211_KEY_GROUP)
-+
-+/*
-+ * NB: these values are ordered carefully; there are lots of
-+ * of implications in any reordering.  In particular beware
-+ * that 4 is not used to avoid conflicting with IEEE80211_F_PRIVACY.
-+ */
-+#define	IEEE80211_CIPHER_WEP		0
-+#define	IEEE80211_CIPHER_TKIP		1
-+#define	IEEE80211_CIPHER_AES_OCB	2
-+#define	IEEE80211_CIPHER_AES_CCM	3
-+#define	IEEE80211_CIPHER_CKIP		5
-+#define	IEEE80211_CIPHER_NONE		6	/* pseudo value */
-+
-+#define	IEEE80211_CIPHER_MAX		(IEEE80211_CIPHER_NONE+1)
-+
-+#define	IEEE80211_KEYIX_NONE	((u_int16_t) - 1)
-+
-+#if defined(__KERNEL__) || defined(_KERNEL)
-+
-+struct ieee80211com;
-+struct ieee80211vap;
-+struct ieee80211_node;
-+struct sk_buff;
-+
-+void ieee80211_crypto_attach(struct ieee80211com *);
-+void ieee80211_crypto_detach(struct ieee80211com *);
-+void ieee80211_crypto_vattach(struct ieee80211vap *);
-+void ieee80211_crypto_vdetach(struct ieee80211vap *);
-+int ieee80211_crypto_newkey(struct ieee80211vap *, int, int,
-+	struct ieee80211_key *);
-+int ieee80211_crypto_delkey(struct ieee80211vap *, struct ieee80211_key *,
-+	struct ieee80211_node *);
-+int ieee80211_crypto_setkey(struct ieee80211vap *, struct ieee80211_key *,
-+	const u_int8_t macaddr[IEEE80211_ADDR_LEN], struct ieee80211_node *);
-+void ieee80211_crypto_delglobalkeys(struct ieee80211vap *);
-+
-+/*
-+ * Template for a supported cipher.  Ciphers register with the
-+ * crypto code and are typically loaded as separate modules
-+ * (the null cipher is always present).
-+ * XXX may need refcnts
-+ */
-+struct ieee80211_cipher {
-+	const char *ic_name;		/* printable name */
-+	u_int ic_cipher;			/* IEEE80211_CIPHER_* */
-+	u_int ic_header;			/* size of privacy header (bytes) */
-+	u_int ic_trailer;		/* size of privacy trailer (bytes) */
-+	u_int ic_miclen;			/* size of mic trailer (bytes) */
-+	void *(*ic_attach)(struct ieee80211vap *, struct ieee80211_key *);
-+	void (*ic_detach)(struct ieee80211_key *);
-+	int (*ic_setkey)(struct ieee80211_key *);
-+	int (*ic_encap)(struct ieee80211_key *, struct sk_buff *, u_int8_t);
-+	int (*ic_decap)(struct ieee80211_key *, struct sk_buff *, int);
-+	int (*ic_enmic)(struct ieee80211_key *, struct sk_buff *, int);
-+	int (*ic_demic)(struct ieee80211_key *, struct sk_buff *, int);
-+};
-+extern const struct ieee80211_cipher ieee80211_cipher_none;
-+
-+void ieee80211_crypto_register(const struct ieee80211_cipher *);
-+void ieee80211_crypto_unregister(const struct ieee80211_cipher *);
-+int ieee80211_crypto_available(u_int);
-+
-+struct ieee80211_key *ieee80211_crypto_encap(struct ieee80211_node *,
-+	struct sk_buff *);
-+struct ieee80211_key *ieee80211_crypto_decap(struct ieee80211_node *,
-+	struct sk_buff *, int);
-+
-+/*
-+ * Check and remove any MIC.
-+ */
-+static __inline int
-+ieee80211_crypto_demic(struct ieee80211vap *vap, struct ieee80211_key *k,
-+	struct sk_buff *skb, int hdrlen)
-+{
-+	const struct ieee80211_cipher *cip = k->wk_cipher;
-+	return (cip->ic_miclen > 0 ? cip->ic_demic(k, skb, hdrlen) : 1);
-+}
-+
-+/*
-+ * Add any MIC.
-+ */
-+static __inline int
-+ieee80211_crypto_enmic(struct ieee80211vap *vap, struct ieee80211_key *k,
-+	struct sk_buff *skb, int force)
-+{
-+	const struct ieee80211_cipher *cip = k->wk_cipher;
-+	return (cip->ic_miclen > 0 ? cip->ic_enmic(k, skb, force) : 1);
-+}
-+
-+/* 
-+ * Reset key state to an unused state.  The crypto
-+ * key allocation mechanism ensures other state (e.g.
-+ * key data) is properly setup before a key is used.
-+ */
-+static __inline void
-+ieee80211_crypto_resetkey(struct ieee80211vap *vap, struct ieee80211_key *k,
-+	u_int16_t ix)
-+{
-+	k->wk_cipher = &ieee80211_cipher_none;;
-+	k->wk_private = k->wk_cipher->ic_attach(vap, k);
-+	k->wk_keyix = ix;
-+	k->wk_flags = IEEE80211_KEY_XMIT | IEEE80211_KEY_RECV;
-+}
-+
-+/*
-+ * Crypto-related notification methods.
-+ */
-+void ieee80211_notify_replay_failure(struct ieee80211vap *,
-+	const struct ieee80211_frame *, const struct ieee80211_key *,
-+	u_int64_t rsc);
-+void ieee80211_notify_michael_failure(struct ieee80211vap *,
-+	const struct ieee80211_frame *, u_int keyix);
-+#endif /* defined(__KERNEL__) || defined(_KERNEL) */
-+#endif /* _NET80211_IEEE80211_CRYPTO_H_ */
-diff -Nrup wpa_supplicant.orig/driver_madwifi/net80211/_ieee80211.h wpa_supplicant/driver_madwifi/net80211/_ieee80211.h
---- wpa_supplicant.orig/driver_madwifi/net80211/_ieee80211.h	1970-01-01 10:00:00.000000000 +1000
-+++ wpa_supplicant/driver_madwifi/net80211/_ieee80211.h	2006-04-12 21:36:10.000000000 +1000
-@@ -0,0 +1,243 @@
-+/*-
-+ * Copyright (c) 2001 Atsushi Onoe
-+ * Copyright (c) 2002-2005 Sam Leffler, Errno Consulting
-+ * All rights reserved.
-+ *
-+ * Redistribution and use in source and binary forms, with or without
-+ * modification, are permitted provided that the following conditions
-+ * are met:
-+ * 1. Redistributions of source code must retain the above copyright
-+ *    notice, this list of conditions and the following disclaimer.
-+ * 2. Redistributions in binary form must reproduce the above copyright
-+ *    notice, this list of conditions and the following disclaimer in the
-+ *    documentation and/or other materials provided with the distribution.
-+ * 3. The name of the author may not be used to endorse or promote products
-+ *    derived from this software without specific prior written permission.
-+ *
-+ * Alternatively, this software may be distributed under the terms of the
-+ * GNU General Public License ("GPL") version 2 as published by the Free
-+ * Software Foundation.
-+ *
-+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
-+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
-+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
-+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
-+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
-+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
-+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-+ *
-+ * $Id: _ieee80211.h 1441 2006-02-06 16:03:21Z mrenzmann $
++ * $Id: _ieee80211.h 2513 2007-06-25 03:48:07Z mentor $
 + */
 +#ifndef _NET80211__IEEE80211_H_
 +#define _NET80211__IEEE80211_H_
@@ -393,7 +204,7 @@
 +};
 +#define	IEEE80211_T_CCK	IEEE80211_T_DS	/* more common nomenclature */
 +
-+/* XXX not really a mode; there are really multiple PHY's */
++/* XXX: not really a mode; there are really multiple PHYs */
 +enum ieee80211_phymode {
 +	IEEE80211_MODE_AUTO	= 0,	/* autoselect */
 +	IEEE80211_MODE_11A	= 1,	/* 5GHz, OFDM */
@@ -479,7 +290,8 @@
 +#define	IEEE80211_CHAN_ANY	0xffff	/* token for ``any channel'' */
 +#define	IEEE80211_CHAN_ANYC 	((struct ieee80211_channel *) IEEE80211_CHAN_ANY)
 +
-+#define	IEEE80211_RADAR_11HCOUNT	1
++#define	IEEE80211_RADAR_11HCOUNT		1
++#define IEEE80211_DEFAULT_CHANCHANGE_TBTT_COUNT	3
 +#define	IEEE80211_RADAR_TEST_MUTE_CHAN	36	/* Move to channel 36 for mute test */
 +
 +/* bits 0-3 are for private use by drivers */
@@ -592,10 +404,10 @@
 +	u_int8_t pad2;
 +};
 +#endif /* _NET80211__IEEE80211_H_ */
-diff -Nrup wpa_supplicant.orig/driver_madwifi/net80211/ieee80211.h wpa_supplicant/driver_madwifi/net80211/ieee80211.h
---- wpa_supplicant.orig/driver_madwifi/net80211/ieee80211.h	1970-01-01 10:00:00.000000000 +1000
-+++ wpa_supplicant/driver_madwifi/net80211/ieee80211.h	2007-02-08 21:25:30.000000000 +1000
-@@ -0,0 +1,939 @@
+diff -urNad trunk~/driver_madwifi/net80211/ieee80211.h trunk/driver_madwifi/net80211/ieee80211.h
+--- trunk~/driver_madwifi/net80211/ieee80211.h	1970-01-01 02:00:00.000000000 +0200
++++ trunk/driver_madwifi/net80211/ieee80211.h	2007-07-22 21:34:16.000000000 +0300
+@@ -0,0 +1,940 @@
 +/*-
 + * Copyright (c) 2001 Atsushi Onoe
 + * Copyright (c) 2002-2005 Sam Leffler, Errno Consulting
@@ -627,7 +439,7 @@
 + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
 + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 + *
-+ * $Id: ieee80211.h 2028 2007-01-30 03:51:52Z proski $
++ * $Id: ieee80211.h 2513 2007-06-25 03:48:07Z mentor $
 + */
 +#ifndef _NET80211_IEEE80211_H_
 +#define _NET80211_IEEE80211_H_
@@ -649,7 +461,7 @@
 +	u_int16_t i_crc;
 +} __packed;
 +
-+#define IEEE80211_PLCP_SFD      0xF3A0 
++#define IEEE80211_PLCP_SFD      0xF3A0
 +#define IEEE80211_PLCP_SERVICE  0x00
 +
 +/*
@@ -790,164 +602,164 @@
 + * XXX belongs elsewhere
 + */
 +enum CountryCode {
-+    CTRY_ALBANIA              = 8,       /* Albania */
-+    CTRY_ALGERIA              = 12,      /* Algeria */
-+    CTRY_ARGENTINA            = 32,      /* Argentina */
-+    CTRY_ARMENIA              = 51,      /* Armenia */
-+    CTRY_AUSTRALIA            = 36,      /* Australia */
-+    CTRY_AUSTRIA              = 40,      /* Austria */
-+    CTRY_AZERBAIJAN           = 31,      /* Azerbaijan */
-+    CTRY_BAHRAIN              = 48,      /* Bahrain */
-+    CTRY_BELARUS              = 112,     /* Belarus */
-+    CTRY_BELGIUM              = 56,      /* Belgium */
-+    CTRY_BELIZE               = 84,      /* Belize */
-+    CTRY_BOLIVIA              = 68,      /* Bolivia */
-+    CTRY_BRAZIL               = 76,      /* Brazil */
-+    CTRY_BRUNEI_DARUSSALAM    = 96,      /* Brunei Darussalam */
-+    CTRY_BULGARIA             = 100,     /* Bulgaria */
-+    CTRY_CANADA               = 124,     /* Canada */
-+    CTRY_CHILE                = 152,     /* Chile */
-+    CTRY_CHINA                = 156,     /* People's Republic of China */
-+    CTRY_COLOMBIA             = 170,     /* Colombia */
-+    CTRY_COSTA_RICA           = 188,     /* Costa Rica */
-+    CTRY_CROATIA              = 191,     /* Croatia */
-+    CTRY_CYPRUS               = 196,
-+    CTRY_CZECH                = 203,     /* Czech Republic */
-+    CTRY_DENMARK              = 208,     /* Denmark */
-+    CTRY_DOMINICAN_REPUBLIC   = 214,     /* Dominican Republic */
-+    CTRY_ECUADOR              = 218,     /* Ecuador */
-+    CTRY_EGYPT                = 818,     /* Egypt */
-+    CTRY_EL_SALVADOR          = 222,     /* El Salvador */
-+    CTRY_ESTONIA              = 233,     /* Estonia */
-+    CTRY_FAEROE_ISLANDS       = 234,     /* Faeroe Islands */
-+    CTRY_FINLAND              = 246,     /* Finland */
-+    CTRY_FRANCE               = 250,     /* France */
-+    CTRY_FRANCE2              = 255,     /* France2 */
-+    CTRY_GEORGIA              = 268,     /* Georgia */
-+    CTRY_GERMANY              = 276,     /* Germany */
-+    CTRY_GREECE               = 300,     /* Greece */
-+    CTRY_GUATEMALA            = 320,     /* Guatemala */
-+    CTRY_HONDURAS             = 340,     /* Honduras */
-+    CTRY_HONG_KONG            = 344,     /* Hong Kong S.A.R., P.R.C. */
-+    CTRY_HUNGARY              = 348,     /* Hungary */
-+    CTRY_ICELAND              = 352,     /* Iceland */
-+    CTRY_INDIA                = 356,     /* India */
-+    CTRY_INDONESIA            = 360,     /* Indonesia */
-+    CTRY_IRAN                 = 364,     /* Iran */
-+    CTRY_IRAQ                 = 368,     /* Iraq */
-+    CTRY_IRELAND              = 372,     /* Ireland */
-+    CTRY_ISRAEL               = 376,     /* Israel */
-+    CTRY_ITALY                = 380,     /* Italy */
-+    CTRY_JAMAICA              = 388,     /* Jamaica */
-+    CTRY_JAPAN                = 392,     /* Japan */
-+    CTRY_JAPAN1               = 393,     /* Japan (JP1) */
-+    CTRY_JAPAN2               = 394,     /* Japan (JP0) */
-+    CTRY_JAPAN3               = 395,     /* Japan (JP1-1) */
-+    CTRY_JAPAN4               = 396,     /* Japan (JE1) */
-+    CTRY_JAPAN5               = 397,     /* Japan (JE2) */
-+    CTRY_JAPAN6               = 399,	 /* Japan (JP6) */
-+    CTRY_JAPAN7               = 900,	 /* Japan */
-+    CTRY_JAPAN8               = 901,	 /* Japan */
-+    CTRY_JAPAN9               = 902,	 /* Japan */
-+    CTRY_JAPAN10	      = 903,	 /* Japan */
-+    CTRY_JAPAN11	      = 904,	 /* Japan */
-+    CTRY_JAPAN12	      = 905,	 /* Japan */
-+    CTRY_JAPAN13	      = 906,	 /* Japan */
-+    CTRY_JAPAN14	      = 907,	 /* Japan */
-+    CTRY_JAPAN15	      = 908,	 /* Japan */
-+    CTRY_JAPAN16	      = 909,	 /* Japan */
-+    CTRY_JAPAN17	      = 910,	 /* Japan */
-+    CTRY_JAPAN18	      = 911,	 /* Japan */
-+    CTRY_JAPAN19	      = 912,	 /* Japan */
-+    CTRY_JAPAN20	      = 913,	 /* Japan */
-+    CTRY_JAPAN21	      = 914,	 /* Japan */
-+    CTRY_JAPAN22	      = 915,	 /* Japan */
-+    CTRY_JAPAN23	      = 916,	 /* Japan */
-+    CTRY_JAPAN24	      = 917,	 /* Japan */
-+    CTRY_JAPAN25	      = 918,	 /* Japan */
-+    CTRY_JAPAN26	      = 919,	 /* Japan */
-+    CTRY_JAPAN27	      = 920,	 /* Japan */
-+    CTRY_JAPAN28	      = 921,	 /* Japan */
-+    CTRY_JAPAN29	      = 922,	 /* Japan */
-+    CTRY_JAPAN30	      = 923,	 /* Japan */
-+    CTRY_JAPAN31	      = 924,	 /* Japan */
-+    CTRY_JAPAN32	      = 925,	 /* Japan */
-+    CTRY_JAPAN33	      = 926,	 /* Japan */
-+    CTRY_JAPAN34	      = 927,	 /* Japan */
-+    CTRY_JAPAN35	      = 928,	 /* Japan */
-+    CTRY_JAPAN36	      = 929,	 /* Japan */
-+    CTRY_JAPAN37	      = 930,	 /* Japan */
-+    CTRY_JAPAN38	      = 931,	 /* Japan */
-+    CTRY_JAPAN39	      = 932,	 /* Japan */
-+    CTRY_JAPAN40	      = 933,	 /* Japan */
-+    CTRY_JAPAN41	      = 934,	 /* Japan */
-+    CTRY_JAPAN42	      = 935,	 /* Japan */
-+    CTRY_JAPAN43	      = 936,	 /* Japan */
-+    CTRY_JAPAN44	      = 937,	 /* Japan */
-+    CTRY_JAPAN45	      = 938,	 /* Japan */
-+    CTRY_JAPAN46	      = 939,	 /* Japan */
-+    CTRY_JAPAN47	      = 940,	 /* Japan */
-+    CTRY_JAPAN48	      = 941,	 /* Japan */
-+    CTRY_JORDAN               = 400,     /* Jordan */
-+    CTRY_KAZAKHSTAN           = 398,     /* Kazakhstan */
-+    CTRY_KENYA                = 404,     /* Kenya */
-+    CTRY_KOREA_NORTH          = 408,     /* North Korea */
-+    CTRY_KOREA_ROC            = 410,     /* South Korea */
-+    CTRY_KOREA_ROC2           = 411,     /* South Korea */
-+    CTRY_KUWAIT               = 414,     /* Kuwait */
-+    CTRY_LATVIA               = 428,     /* Latvia */
-+    CTRY_LEBANON              = 422,     /* Lebanon */
-+    CTRY_LIBYA                = 434,     /* Libya */
-+    CTRY_LIECHTENSTEIN        = 438,     /* Liechtenstein */
-+    CTRY_LITHUANIA            = 440,     /* Lithuania */
-+    CTRY_LUXEMBOURG           = 442,     /* Luxembourg */
-+    CTRY_MACAU                = 446,     /* Macau */
-+    CTRY_MACEDONIA            = 807,     /* the Former Yugoslav Republic of Macedonia */
-+    CTRY_MALAYSIA             = 458,     /* Malaysia */
-+    CTRY_MEXICO               = 484,     /* Mexico */
-+    CTRY_MONACO               = 492,     /* Principality of Monaco */
-+    CTRY_MOROCCO              = 504,     /* Morocco */
-+    CTRY_NETHERLANDS          = 528,     /* Netherlands */
-+    CTRY_NEW_ZEALAND          = 554,     /* New Zealand */
-+    CTRY_NICARAGUA            = 558,     /* Nicaragua */
-+    CTRY_NORWAY               = 578,     /* Norway */
-+    CTRY_OMAN                 = 512,     /* Oman */
-+    CTRY_PAKISTAN             = 586,     /* Islamic Republic of Pakistan */
-+    CTRY_PANAMA               = 591,     /* Panama */
-+    CTRY_PARAGUAY             = 600,     /* Paraguay */
-+    CTRY_PERU                 = 604,     /* Peru */
-+    CTRY_PHILIPPINES          = 608,     /* Republic of the Philippines */
-+    CTRY_POLAND               = 616,     /* Poland */
-+    CTRY_PORTUGAL             = 620,     /* Portugal */
-+    CTRY_PUERTO_RICO          = 630,     /* Puerto Rico */
-+    CTRY_QATAR                = 634,     /* Qatar */
-+    CTRY_ROMANIA              = 642,     /* Romania */
-+    CTRY_RUSSIA               = 643,     /* Russia */
-+    CTRY_SAUDI_ARABIA         = 682,     /* Saudi Arabia */
-+    CTRY_SINGAPORE            = 702,     /* Singapore */
-+    CTRY_SLOVAKIA             = 703,     /* Slovak Republic */
-+    CTRY_SLOVENIA             = 705,     /* Slovenia */
-+    CTRY_SOUTH_AFRICA         = 710,     /* South Africa */
-+    CTRY_SPAIN                = 724,     /* Spain */
-+    CTRY_SWEDEN               = 752,     /* Sweden */
-+    CTRY_SWITZERLAND          = 756,     /* Switzerland */
-+    CTRY_SYRIA                = 760,     /* Syria */
-+    CTRY_TAIWAN               = 158,     /* Taiwan */
-+    CTRY_THAILAND             = 764,     /* Thailand */
-+    CTRY_TRINIDAD_Y_TOBAGO    = 780,     /* Trinidad y Tobago */
-+    CTRY_TUNISIA              = 788,     /* Tunisia */
-+    CTRY_TURKEY               = 792,     /* Turkey */
-+    CTRY_UAE                  = 784,     /* U.A.E. */
-+    CTRY_UKRAINE              = 804,     /* Ukraine */
-+    CTRY_UNITED_KINGDOM       = 826,     /* United Kingdom */
-+    CTRY_UNITED_STATES        = 840,     /* United States */
-+    CTRY_UNITED_STATES_FCC49  = 842,     /* United States (Public Safety)*/
-+    CTRY_URUGUAY              = 858,     /* Uruguay */
-+    CTRY_UZBEKISTAN           = 860,     /* Uzbekistan */
-+    CTRY_VENEZUELA            = 862,     /* Venezuela */
-+    CTRY_VIET_NAM             = 704,     /* Viet Nam */
-+    CTRY_YEMEN                = 887,     /* Yemen */
-+    CTRY_ZIMBABWE             = 716      /* Zimbabwe */
++	CTRY_ALBANIA              = 8,       /* Albania */
++	CTRY_ALGERIA              = 12,      /* Algeria */
++	CTRY_ARGENTINA            = 32,      /* Argentina */
++	CTRY_ARMENIA              = 51,      /* Armenia */
++	CTRY_AUSTRALIA            = 36,      /* Australia */
++	CTRY_AUSTRIA              = 40,      /* Austria */
++	CTRY_AZERBAIJAN           = 31,      /* Azerbaijan */
++	CTRY_BAHRAIN              = 48,      /* Bahrain */
++	CTRY_BELARUS              = 112,     /* Belarus */
++	CTRY_BELGIUM              = 56,      /* Belgium */
++	CTRY_BELIZE               = 84,      /* Belize */
++	CTRY_BOLIVIA              = 68,      /* Bolivia */
++	CTRY_BRAZIL               = 76,      /* Brazil */
++	CTRY_BRUNEI_DARUSSALAM    = 96,      /* Brunei Darussalam */
++	CTRY_BULGARIA             = 100,     /* Bulgaria */
++	CTRY_CANADA               = 124,     /* Canada */
++	CTRY_CHILE                = 152,     /* Chile */
++	CTRY_CHINA                = 156,     /* People's Republic of China */
++	CTRY_COLOMBIA             = 170,     /* Colombia */
++	CTRY_COSTA_RICA           = 188,     /* Costa Rica */
++	CTRY_CROATIA              = 191,     /* Croatia */
++	CTRY_CYPRUS               = 196,
++	CTRY_CZECH                = 203,     /* Czech Republic */
++	CTRY_DENMARK              = 208,     /* Denmark */
++	CTRY_DOMINICAN_REPUBLIC   = 214,     /* Dominican Republic */
++	CTRY_ECUADOR              = 218,     /* Ecuador */
++	CTRY_EGYPT                = 818,     /* Egypt */
++	CTRY_EL_SALVADOR          = 222,     /* El Salvador */
++	CTRY_ESTONIA              = 233,     /* Estonia */
++	CTRY_FAEROE_ISLANDS       = 234,     /* Faeroe Islands */
++	CTRY_FINLAND              = 246,     /* Finland */
++	CTRY_FRANCE               = 250,     /* France */
++	CTRY_FRANCE2              = 255,     /* France2 */
++	CTRY_GEORGIA              = 268,     /* Georgia */
++	CTRY_GERMANY              = 276,     /* Germany */
++	CTRY_GREECE               = 300,     /* Greece */
++	CTRY_GUATEMALA            = 320,     /* Guatemala */
++	CTRY_HONDURAS             = 340,     /* Honduras */
++	CTRY_HONG_KONG            = 344,     /* Hong Kong S.A.R., P.R.C. */
++	CTRY_HUNGARY              = 348,     /* Hungary */
++	CTRY_ICELAND              = 352,     /* Iceland */
++	CTRY_INDIA                = 356,     /* India */
++	CTRY_INDONESIA            = 360,     /* Indonesia */
++	CTRY_IRAN                 = 364,     /* Iran */
++	CTRY_IRAQ                 = 368,     /* Iraq */
++	CTRY_IRELAND              = 372,     /* Ireland */
++	CTRY_ISRAEL               = 376,     /* Israel */
++	CTRY_ITALY                = 380,     /* Italy */
++	CTRY_JAMAICA              = 388,     /* Jamaica */
++	CTRY_JAPAN                = 392,     /* Japan */
++	CTRY_JAPAN1               = 393,     /* Japan (JP1) */
++	CTRY_JAPAN2               = 394,     /* Japan (JP0) */
++	CTRY_JAPAN3               = 395,     /* Japan (JP1-1) */
++	CTRY_JAPAN4               = 396,     /* Japan (JE1) */
++	CTRY_JAPAN5               = 397,     /* Japan (JE2) */
++	CTRY_JAPAN6               = 399,	 /* Japan (JP6) */
++	CTRY_JAPAN7               = 900,	 /* Japan */
++	CTRY_JAPAN8               = 901,	 /* Japan */
++	CTRY_JAPAN9               = 902,	 /* Japan */
++	CTRY_JAPAN10	      = 903,	 /* Japan */
++	CTRY_JAPAN11	      = 904,	 /* Japan */
++	CTRY_JAPAN12	      = 905,	 /* Japan */
++	CTRY_JAPAN13	      = 906,	 /* Japan */
++	CTRY_JAPAN14	      = 907,	 /* Japan */
++	CTRY_JAPAN15	      = 908,	 /* Japan */
++	CTRY_JAPAN16	      = 909,	 /* Japan */
++	CTRY_JAPAN17	      = 910,	 /* Japan */
++	CTRY_JAPAN18	      = 911,	 /* Japan */
++	CTRY_JAPAN19	      = 912,	 /* Japan */
++	CTRY_JAPAN20	      = 913,	 /* Japan */
++	CTRY_JAPAN21	      = 914,	 /* Japan */
++	CTRY_JAPAN22	      = 915,	 /* Japan */
++	CTRY_JAPAN23	      = 916,	 /* Japan */
++	CTRY_JAPAN24	      = 917,	 /* Japan */
++	CTRY_JAPAN25	      = 918,	 /* Japan */
++	CTRY_JAPAN26	      = 919,	 /* Japan */
++	CTRY_JAPAN27	      = 920,	 /* Japan */
++	CTRY_JAPAN28	      = 921,	 /* Japan */
++	CTRY_JAPAN29	      = 922,	 /* Japan */
++	CTRY_JAPAN30	      = 923,	 /* Japan */
++	CTRY_JAPAN31	      = 924,	 /* Japan */
++	CTRY_JAPAN32	      = 925,	 /* Japan */
++	CTRY_JAPAN33	      = 926,	 /* Japan */
++	CTRY_JAPAN34	      = 927,	 /* Japan */
++	CTRY_JAPAN35	      = 928,	 /* Japan */
++	CTRY_JAPAN36	      = 929,	 /* Japan */
++	CTRY_JAPAN37	      = 930,	 /* Japan */
++	CTRY_JAPAN38	      = 931,	 /* Japan */
++	CTRY_JAPAN39	      = 932,	 /* Japan */
++	CTRY_JAPAN40	      = 933,	 /* Japan */
++	CTRY_JAPAN41	      = 934,	 /* Japan */
++	CTRY_JAPAN42	      = 935,	 /* Japan */
++	CTRY_JAPAN43	      = 936,	 /* Japan */
++	CTRY_JAPAN44	      = 937,	 /* Japan */
++	CTRY_JAPAN45	      = 938,	 /* Japan */
++	CTRY_JAPAN46	      = 939,	 /* Japan */
++	CTRY_JAPAN47	      = 940,	 /* Japan */
++	CTRY_JAPAN48	      = 941,	 /* Japan */
++	CTRY_JORDAN               = 400,     /* Jordan */
++	CTRY_KAZAKHSTAN           = 398,     /* Kazakhstan */
++	CTRY_KENYA                = 404,     /* Kenya */
++	CTRY_KOREA_NORTH          = 408,     /* North Korea */
++	CTRY_KOREA_ROC            = 410,     /* South Korea */
++	CTRY_KOREA_ROC2           = 411,     /* South Korea */
++	CTRY_KUWAIT               = 414,     /* Kuwait */
++	CTRY_LATVIA               = 428,     /* Latvia */
++	CTRY_LEBANON              = 422,     /* Lebanon */
++	CTRY_LIBYA                = 434,     /* Libya */
++	CTRY_LIECHTENSTEIN        = 438,     /* Liechtenstein */
++	CTRY_LITHUANIA            = 440,     /* Lithuania */
++	CTRY_LUXEMBOURG           = 442,     /* Luxembourg */
++	CTRY_MACAU                = 446,     /* Macau */
++	CTRY_MACEDONIA            = 807,     /* the Former Yugoslav Republic of Macedonia */
++	CTRY_MALAYSIA             = 458,     /* Malaysia */
++	CTRY_MEXICO               = 484,     /* Mexico */
++	CTRY_MONACO               = 492,     /* Principality of Monaco */
++	CTRY_MOROCCO              = 504,     /* Morocco */
++	CTRY_NETHERLANDS          = 528,     /* Netherlands */
++	CTRY_NEW_ZEALAND          = 554,     /* New Zealand */
++	CTRY_NICARAGUA            = 558,     /* Nicaragua */
++	CTRY_NORWAY               = 578,     /* Norway */
++	CTRY_OMAN                 = 512,     /* Oman */
++	CTRY_PAKISTAN             = 586,     /* Islamic Republic of Pakistan */
++	CTRY_PANAMA               = 591,     /* Panama */
++	CTRY_PARAGUAY             = 600,     /* Paraguay */
++	CTRY_PERU                 = 604,     /* Peru */
++	CTRY_PHILIPPINES          = 608,     /* Republic of the Philippines */
++	CTRY_POLAND               = 616,     /* Poland */
++	CTRY_PORTUGAL             = 620,     /* Portugal */
++	CTRY_PUERTO_RICO          = 630,     /* Puerto Rico */
++	CTRY_QATAR                = 634,     /* Qatar */
++	CTRY_ROMANIA              = 642,     /* Romania */
++	CTRY_RUSSIA               = 643,     /* Russia */
++	CTRY_SAUDI_ARABIA         = 682,     /* Saudi Arabia */
++	CTRY_SINGAPORE            = 702,     /* Singapore */
++	CTRY_SLOVAKIA             = 703,     /* Slovak Republic */
++	CTRY_SLOVENIA             = 705,     /* Slovenia */
++	CTRY_SOUTH_AFRICA         = 710,     /* South Africa */
++	CTRY_SPAIN                = 724,     /* Spain */
++	CTRY_SWEDEN               = 752,     /* Sweden */
++	CTRY_SWITZERLAND          = 756,     /* Switzerland */
++	CTRY_SYRIA                = 760,     /* Syria */
++	CTRY_TAIWAN               = 158,     /* Taiwan */
++	CTRY_THAILAND             = 764,     /* Thailand */
++	CTRY_TRINIDAD_Y_TOBAGO    = 780,     /* Trinidad y Tobago */
++	CTRY_TUNISIA              = 788,     /* Tunisia */
++	CTRY_TURKEY               = 792,     /* Turkey */
++	CTRY_UAE                  = 784,     /* U.A.E. */
++	CTRY_UKRAINE              = 804,     /* Ukraine */
++	CTRY_UNITED_KINGDOM       = 826,     /* United Kingdom */
++	CTRY_UNITED_STATES        = 840,     /* United States */
++	CTRY_UNITED_STATES_FCC49  = 842,     /* United States (Public Safety)*/
++	CTRY_URUGUAY              = 858,     /* Uruguay */
++	CTRY_UZBEKISTAN           = 860,     /* Uzbekistan */
++	CTRY_VENEZUELA            = 862,     /* Venezuela */
++	CTRY_VIET_NAM             = 704,     /* Viet Nam */
++	CTRY_YEMEN                = 887,     /* Yemen */
++	CTRY_ZIMBABWE             = 716      /* Zimbabwe */
 +};
 +
 +/* 
@@ -956,7 +768,7 @@
 +struct ieee80211_ie {
 +	u_int8_t id;
 +	u_int8_t len;
-+	u_int8_t info[];
++	u_int8_t info[0];
 +} __packed;
 +
 +/* 
@@ -985,7 +797,7 @@
 +#define IEEE80211_CSA_PROTECTION_PERIOD 3
 +
 +/* maximum allowed deviance of measurement of intervals between CSA in Beacons */
-+#define IEEE80211_CSA_SANITY_THRESHOLD 100    
++#define IEEE80211_CSA_SANITY_THRESHOLD 100
 +
 +
 +/* does frame have QoS sequence control data */
@@ -1112,7 +924,7 @@
 +	u_int8_t athAdvCap_id;		/* IEEE80211_ELEMID_VENDOR */
 +	u_int8_t athAdvCap_len;		/* length in bytes */
 +	u_int8_t athAdvCap_oui[3];	/* 0x00, 0x03, 0x7f */
-+	u_int8_t athAdvCap_type;		/* OUI type */
++	u_int8_t athAdvCap_type;	/* OUI type */
 +	u_int8_t athAdvCap_subtype;	/* OUI subtype */
 +	u_int8_t athAdvCap_version;	/* spec revision */
 +	u_int8_t athAdvCap_capability;	/* Capability info */
@@ -1260,7 +1072,7 @@
 +	u_int32_t wpa_authsels[8];	/* selectors */
 +	u_int16_t wpa_caps;		/* 802.11i capabilities */
 +	u_int16_t wpa_pmkidcnt;		/* 802.11i pmkid count */
-+	u_int16_t wpa_pmkids[8];		/* 802.11i pmkids */
++	u_int16_t wpa_pmkids[8];	/* 802.11i pmkids */
 +} __packed;
 +
 +/*
@@ -1344,9 +1156,10 @@
 +#define	ATH_OUI			0x7f0300		/* Atheros OUI */
 +#define	ATH_OUI_TYPE		0x01
 +#define	ATH_OUI_SUBTYPE		0x01
-+#define ATH_OUI_VERSION		0x00
++#define	ATH_OUI_VERSION		0x00
 +#define	ATH_OUI_TYPE_XR		0x03
-+#define	ATH_OUI_VER_XR		0x01
++#define	ATH_OUI_SUBTYPE_XR	0x01
++#define	ATH_OUI_VER_XR		0x00
 +
 +#define	WPA_OUI			0xf25000
 +#define	WPA_OUI_TYPE		0x01
@@ -1498,7 +1311,7 @@
 +#define	IEEE80211_MTU_MIN		32
 +
 +#define	IEEE80211_MAX_LEN		(2300 + IEEE80211_CRC_LEN + \
-+    (IEEE80211_WEP_IVLEN + IEEE80211_WEP_KIDLEN + IEEE80211_WEP_CRCLEN))
++	(IEEE80211_WEP_IVLEN + IEEE80211_WEP_KIDLEN + IEEE80211_WEP_CRCLEN))
 +#define	IEEE80211_ACK_LEN \
 +	(sizeof(struct ieee80211_frame_ack) + IEEE80211_CRC_LEN)
 +#define	IEEE80211_MIN_LEN \
@@ -1506,7 +1319,7 @@
 +
 +/*
 + * The 802.11 spec says at most 2007 stations may be
-+ * associated at once.  For most AP's this is way more
++ * associated at once.  For most APs this is way more
 + * than is feasible so we use a default of 128.  This
 + * number may be overridden by the driver and/or by
 + * user configuration.
@@ -1535,10 +1348,10 @@
 +#define IEEE80211_TSF_LEN		8
 +
 +#endif /* _NET80211_IEEE80211_H_ */
-diff -Nrup wpa_supplicant.orig/driver_madwifi/net80211/ieee80211_ioctl.h wpa_supplicant/driver_madwifi/net80211/ieee80211_ioctl.h
---- wpa_supplicant.orig/driver_madwifi/net80211/ieee80211_ioctl.h	1970-01-01 10:00:00.000000000 +1000
-+++ wpa_supplicant/driver_madwifi/net80211/ieee80211_ioctl.h	2007-02-08 21:25:30.000000000 +1000
-@@ -0,0 +1,660 @@
+diff -urNad trunk~/driver_madwifi/net80211/ieee80211_crypto.h trunk/driver_madwifi/net80211/ieee80211_crypto.h
+--- trunk~/driver_madwifi/net80211/ieee80211_crypto.h	1970-01-01 02:00:00.000000000 +0200
++++ trunk/driver_madwifi/net80211/ieee80211_crypto.h	2007-07-22 21:34:16.000000000 +0300
+@@ -0,0 +1,207 @@
 +/*-
 + * Copyright (c) 2001 Atsushi Onoe
 + * Copyright (c) 2002-2005 Sam Leffler, Errno Consulting
@@ -1570,7 +1383,218 @@
 + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
 + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 + *
-+ * $Id: ieee80211_ioctl.h 1856 2006-12-14 01:38:00Z scottr $
++ * $Id: ieee80211_crypto.h 2278 2007-04-16 12:32:29Z proski $
++ */
++#ifndef _NET80211_IEEE80211_CRYPTO_H_
++#define _NET80211_IEEE80211_CRYPTO_H_
++
++/*
++ * 802.11 protocol crypto-related definitions.
++ */
++#define	IEEE80211_KEYBUF_SIZE	16
++#define	IEEE80211_MICBUF_SIZE	(8 + 8)		/* space for both TX & RX keys */
++#define IEEE80211_TID_SIZE	17		/* total number of TIDs */
++
++/*
++ * Old WEP-style key.  Deprecated.
++ */
++struct ieee80211_wepkey {
++	u_int wk_len;				/* key length in bytes */
++	u_int8_t wk_key[IEEE80211_KEYBUF_SIZE];
++};
++
++struct ieee80211_cipher;
++
++/*
++ * Crypto key state.  There is sufficient room for all supported
++ * ciphers (see below).  The underlying ciphers are handled
++ * separately through loadable cipher modules that register with
++ * the generic crypto support.  A key has a reference to an instance
++ * of the cipher; any per-key state is hung off wk_private by the
++ * cipher when it is attached.  Ciphers are automatically called
++ * to detach and cleanup any such state when the key is deleted.
++ *
++ * The generic crypto support handles encap/decap of cipher-related
++ * frame contents for both hardware- and software-based implementations.
++ * A key requiring software crypto support is automatically flagged and
++ * the cipher is expected to honor this and do the necessary work.
++ * Ciphers such as TKIP may also support mixed hardware/software
++ * encrypt/decrypt and MIC processing.
++ */
++
++typedef u_int16_t ieee80211_keyix_t;
++
++/* XXX pack better? */
++/* XXX 48-bit rsc/tsc */
++struct ieee80211_key {
++	u_int8_t wk_keylen;		/* key length in bytes */
++	u_int8_t wk_flags;
++#define	IEEE80211_KEY_XMIT	0x01	/* key used for xmit */
++#define	IEEE80211_KEY_RECV	0x02	/* key used for recv */
++#define	IEEE80211_KEY_GROUP	0x04	/* key used for WPA group operation */
++#define	IEEE80211_KEY_SWCRYPT	0x10	/* host-based encrypt/decrypt */
++#define	IEEE80211_KEY_SWMIC	0x20	/* host-based enmic/demic */
++	ieee80211_keyix_t wk_keyix;	/* key index */
++	u_int8_t wk_key[IEEE80211_KEYBUF_SIZE+IEEE80211_MICBUF_SIZE];
++#define	wk_txmic	wk_key+IEEE80211_KEYBUF_SIZE+0	/* XXX can't () right */
++#define	wk_rxmic	wk_key+IEEE80211_KEYBUF_SIZE+8	/* XXX can't () right */
++	u_int64_t wk_keyrsc[IEEE80211_TID_SIZE];	/* key receive sequence counter */
++	u_int64_t wk_keytsc;		/* key transmit sequence counter */
++	const struct ieee80211_cipher *wk_cipher;
++	void *wk_private;		/* private cipher state */
++};
++#define	IEEE80211_KEY_COMMON 		/* common flags passed in by apps */\
++	(IEEE80211_KEY_XMIT | IEEE80211_KEY_RECV | IEEE80211_KEY_GROUP)
++
++/*
++ * NB: these values are ordered carefully; there are lots of
++ * of implications in any reordering.  In particular beware
++ * that 4 is not used to avoid conflicting with IEEE80211_F_PRIVACY.
++ */
++#define	IEEE80211_CIPHER_WEP		0
++#define	IEEE80211_CIPHER_TKIP		1
++#define	IEEE80211_CIPHER_AES_OCB	2
++#define	IEEE80211_CIPHER_AES_CCM	3
++#define	IEEE80211_CIPHER_CKIP		5
++#define	IEEE80211_CIPHER_NONE		6	/* pseudo value */
++
++#define	IEEE80211_CIPHER_MAX		(IEEE80211_CIPHER_NONE + 1)
++
++#define	IEEE80211_KEYIX_NONE	((ieee80211_keyix_t) -1)
++
++#if defined(__KERNEL__) || defined(_KERNEL)
++
++struct ieee80211com;
++struct ieee80211vap;
++struct ieee80211_node;
++struct sk_buff;
++
++void ieee80211_crypto_attach(struct ieee80211com *);
++void ieee80211_crypto_detach(struct ieee80211com *);
++void ieee80211_crypto_vattach(struct ieee80211vap *);
++void ieee80211_crypto_vdetach(struct ieee80211vap *);
++int ieee80211_crypto_newkey(struct ieee80211vap *, int, int,
++	struct ieee80211_key *);
++int ieee80211_crypto_delkey(struct ieee80211vap *, struct ieee80211_key *,
++	struct ieee80211_node *);
++int ieee80211_crypto_setkey(struct ieee80211vap *, struct ieee80211_key *,
++	const u_int8_t macaddr[IEEE80211_ADDR_LEN], struct ieee80211_node *);
++void ieee80211_crypto_delglobalkeys(struct ieee80211vap *);
++
++/*
++ * Template for a supported cipher.  Ciphers register with the
++ * crypto code and are typically loaded as separate modules
++ * (the null cipher is always present).
++ * XXX may need refcnts
++ */
++struct ieee80211_cipher {
++	const char *ic_name;		/* printable name */
++	u_int ic_cipher;		/* IEEE80211_CIPHER_* */
++	u_int ic_header;		/* size of privacy header (bytes) */
++	u_int ic_trailer;		/* size of privacy trailer (bytes) */
++	u_int ic_miclen;		/* size of mic trailer (bytes) */
++	void *(*ic_attach)(struct ieee80211vap *, struct ieee80211_key *);
++	void (*ic_detach)(struct ieee80211_key *);
++	int (*ic_setkey)(struct ieee80211_key *);
++	int (*ic_encap)(struct ieee80211_key *, struct sk_buff *, u_int8_t);
++	int (*ic_decap)(struct ieee80211_key *, struct sk_buff *, int);
++	int (*ic_enmic)(struct ieee80211_key *, struct sk_buff *, int);
++	int (*ic_demic)(struct ieee80211_key *, struct sk_buff *, int);
++};
++extern const struct ieee80211_cipher ieee80211_cipher_none;
++
++void ieee80211_crypto_register(const struct ieee80211_cipher *);
++void ieee80211_crypto_unregister(const struct ieee80211_cipher *);
++int ieee80211_crypto_available(struct ieee80211vap*, u_int);
++
++struct ieee80211_key *ieee80211_crypto_encap(struct ieee80211_node *,
++	struct sk_buff *);
++struct ieee80211_key *ieee80211_crypto_decap(struct ieee80211_node *,
++	struct sk_buff *, int);
++
++/*
++ * Check and remove any MIC.
++ */
++static __inline int
++ieee80211_crypto_demic(struct ieee80211vap *vap, struct ieee80211_key *k,
++	struct sk_buff *skb, int hdrlen)
++{
++	const struct ieee80211_cipher *cip = k->wk_cipher;
++	return (cip->ic_miclen > 0 ? cip->ic_demic(k, skb, hdrlen) : 1);
++}
++
++/*
++ * Add any MIC.
++ */
++static __inline int
++ieee80211_crypto_enmic(struct ieee80211vap *vap, struct ieee80211_key *k,
++	struct sk_buff *skb, int force)
++{
++	const struct ieee80211_cipher *cip = k->wk_cipher;
++	return (cip->ic_miclen > 0 ? cip->ic_enmic(k, skb, force) : 1);
++}
++
++/* 
++ * Reset key state to an unused state.  The crypto
++ * key allocation mechanism ensures other state (e.g.
++ * key data) is properly setup before a key is used.
++ */
++static __inline void
++ieee80211_crypto_resetkey(struct ieee80211vap *vap, struct ieee80211_key *k,
++	ieee80211_keyix_t ix)
++{
++	k->wk_cipher = &ieee80211_cipher_none;;
++	k->wk_private = k->wk_cipher->ic_attach(vap, k);
++	k->wk_keyix = ix;
++	k->wk_flags = IEEE80211_KEY_XMIT | IEEE80211_KEY_RECV;
++}
++
++/*
++ * Crypto-related notification methods.
++ */
++void ieee80211_notify_replay_failure(struct ieee80211vap *,
++	const struct ieee80211_frame *, const struct ieee80211_key *,
++	u_int64_t rsc);
++void ieee80211_notify_michael_failure(struct ieee80211vap *,
++	const struct ieee80211_frame *, ieee80211_keyix_t keyix);
++#endif /* defined(__KERNEL__) || defined(_KERNEL) */
++#endif /* _NET80211_IEEE80211_CRYPTO_H_ */
+diff -urNad trunk~/driver_madwifi/net80211/ieee80211_ioctl.h trunk/driver_madwifi/net80211/ieee80211_ioctl.h
+--- trunk~/driver_madwifi/net80211/ieee80211_ioctl.h	1970-01-01 02:00:00.000000000 +0200
++++ trunk/driver_madwifi/net80211/ieee80211_ioctl.h	2007-07-22 21:34:16.000000000 +0300
+@@ -0,0 +1,664 @@
++/*-
++ * Copyright (c) 2001 Atsushi Onoe
++ * Copyright (c) 2002-2005 Sam Leffler, Errno Consulting
++ * All rights reserved.
++ *
++ * Redistribution and use in source and binary forms, with or without
++ * modification, are permitted provided that the following conditions
++ * are met:
++ * 1. Redistributions of source code must retain the above copyright
++ *    notice, this list of conditions and the following disclaimer.
++ * 2. Redistributions in binary form must reproduce the above copyright
++ *    notice, this list of conditions and the following disclaimer in the
++ *    documentation and/or other materials provided with the distribution.
++ * 3. The name of the author may not be used to endorse or promote products
++ *    derived from this software without specific prior written permission.
++ *
++ * Alternatively, this software may be distributed under the terms of the
++ * GNU General Public License ("GPL") version 2 as published by the Free
++ * Software Foundation.
++ *
++ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
++ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
++ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
++ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
++ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
++ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
++ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
++ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
++ *
++ * $Id: ieee80211_ioctl.h 2583 2007-07-12 15:18:23Z mentor $
 + */
 +#ifndef _NET80211_IEEE80211_IOCTL_H_
 +#define _NET80211_IEEE80211_IOCTL_H_
@@ -1746,7 +1770,7 @@
 +struct ieee80211req_key {
 +	u_int8_t ik_type;		/* key/cipher type */
 +	u_int8_t ik_pad;
-+	u_int16_t ik_keyix;		/* key index */
++	ieee80211_keyix_t ik_keyix;	/* key index */
 +	u_int8_t ik_keylen;		/* key length in bytes */
 +	u_int8_t ik_flags;
 +/* NB: IEEE80211_KEY_XMIT and IEEE80211_KEY_RECV defined elsewhere */
@@ -1762,7 +1786,8 @@
 + * to IEEE80211_KEYIX_NONE when deleting a unicast key.
 + */
 +struct ieee80211req_del_key {
-+	u_int8_t idk_keyix;		/* key index */
++	/* XXX: This should be ieee80211_keyix_t, but it changes API/ABI for hostapd */
++	u_int8_t idk_keyix;	/* key index */
 +	u_int8_t idk_macaddr[IEEE80211_ADDR_LEN];
 +};
 +
@@ -1790,7 +1815,7 @@
 + * MAC ACL operations.
 + */
 +enum {
-+	IEEE80211_MACCMD_POLICY_OPEN	= 0,	/* set policy: no ACL's */
++	IEEE80211_MACCMD_POLICY_OPEN	= 0,	/* set policy: no ACLs */
 +	IEEE80211_MACCMD_POLICY_ALLOW	= 1,	/* set policy: allow traffic */
 +	IEEE80211_MACCMD_POLICY_DENY	= 2,	/* set policy: deny traffic */
 +	IEEE80211_MACCMD_FLUSH		= 3,	/* flush ACL database */
@@ -2059,12 +2084,14 @@
 +#define	IEEE80211_IOCTL_CHANSWITCH	(SIOCIWFIRSTPRIV+8)
 +#define	IEEE80211_IOCTL_GET_APPIEBUF	(SIOCIWFIRSTPRIV+9)
 +#define	IEEE80211_IOCTL_SET_APPIEBUF	(SIOCIWFIRSTPRIV+10)
++#define	IEEE80211_IOCTL_READREG		(SIOCIWFIRSTPRIV+11)
 +#define	IEEE80211_IOCTL_FILTERFRAME	(SIOCIWFIRSTPRIV+12)
 +#define	IEEE80211_IOCTL_GETCHANINFO	(SIOCIWFIRSTPRIV+13)
 +#define	IEEE80211_IOCTL_SETOPTIE	(SIOCIWFIRSTPRIV+14)
 +#define	IEEE80211_IOCTL_GETOPTIE	(SIOCIWFIRSTPRIV+15)
 +#define	IEEE80211_IOCTL_SETMLME		(SIOCIWFIRSTPRIV+16)
 +#define	IEEE80211_IOCTL_SETKEY		(SIOCIWFIRSTPRIV+18)
++#define	IEEE80211_IOCTL_WRITEREG	(SIOCIWFIRSTPRIV+19)
 +#define	IEEE80211_IOCTL_DELKEY		(SIOCIWFIRSTPRIV+20)
 +#define	IEEE80211_IOCTL_ADDMAC		(SIOCIWFIRSTPRIV+22)
 +#define	IEEE80211_IOCTL_DELMAC		(SIOCIWFIRSTPRIV+24)
@@ -2078,68 +2105,69 @@
 +	IEEE80211_WMMPARAMS_AIFS       	= 3,
 +	IEEE80211_WMMPARAMS_TXOPLIMIT	= 4,
 +	IEEE80211_WMMPARAMS_ACM		= 5,
-+	IEEE80211_WMMPARAMS_NOACKPOLICY	= 6,	
++	IEEE80211_WMMPARAMS_NOACKPOLICY	= 6,
 +};
 +enum {
-+	IEEE80211_PARAM_TURBO		= 1,	/* turbo mode */
-+	IEEE80211_PARAM_MODE		= 2,	/* phy mode (11a, 11b, etc.) */
-+	IEEE80211_PARAM_AUTHMODE	= 3,	/* authentication mode */
-+	IEEE80211_PARAM_PROTMODE	= 4,	/* 802.11g protection */
-+	IEEE80211_PARAM_MCASTCIPHER	= 5,	/* multicast/default cipher */
-+	IEEE80211_PARAM_MCASTKEYLEN	= 6,	/* multicast key length */
-+	IEEE80211_PARAM_UCASTCIPHERS	= 7,	/* unicast cipher suites */
-+	IEEE80211_PARAM_UCASTCIPHER	= 8,	/* unicast cipher */
-+	IEEE80211_PARAM_UCASTKEYLEN	= 9,	/* unicast key length */
-+	IEEE80211_PARAM_WPA		= 10,	/* WPA mode (0,1,2) */
-+	IEEE80211_PARAM_ROAMING		= 12,	/* roaming mode */
-+	IEEE80211_PARAM_PRIVACY		= 13,	/* privacy invoked */
-+	IEEE80211_PARAM_COUNTERMEASURES	= 14,	/* WPA/TKIP countermeasures */
-+	IEEE80211_PARAM_DROPUNENCRYPTED	= 15,	/* discard unencrypted frames */
-+	IEEE80211_PARAM_DRIVER_CAPS	= 16,	/* driver capabilities */
-+	IEEE80211_PARAM_MACCMD		= 17,	/* MAC ACL operation */
-+	IEEE80211_PARAM_WMM		= 18,	/* WMM mode (on, off) */
-+	IEEE80211_PARAM_HIDESSID	= 19,	/* hide SSID mode (on, off) */
-+	IEEE80211_PARAM_APBRIDGE    	= 20,   /* AP inter-sta bridging */
-+	IEEE80211_PARAM_KEYMGTALGS	= 21,	/* key management algorithms */
-+	IEEE80211_PARAM_RSNCAPS		= 22,	/* RSN capabilities */
-+	IEEE80211_PARAM_INACT		= 23,	/* station inactivity timeout */
-+	IEEE80211_PARAM_INACT_AUTH	= 24,	/* station auth inact timeout */
-+	IEEE80211_PARAM_INACT_INIT	= 25,	/* station init inact timeout */
-+	IEEE80211_PARAM_ABOLT		= 26,	/* Atheros Adv. Capabilities */
-+	IEEE80211_PARAM_DTIM_PERIOD	= 28,	/* DTIM period (beacons) */
-+	IEEE80211_PARAM_BEACON_INTERVAL	= 29,	/* beacon interval (ms) */
-+	IEEE80211_PARAM_DOTH		= 30,	/* 11.h is on/off */
-+	IEEE80211_PARAM_PWRTARGET	= 31,	/* Current Channel Pwr Constraint */
-+	IEEE80211_PARAM_GENREASSOC	= 32,	/* Generate a reassociation request */
-+	IEEE80211_PARAM_COMPRESSION	= 33,	/* compression */
-+	IEEE80211_PARAM_FF		= 34,	/* fast frames support  */
-+	IEEE80211_PARAM_XR		= 35,	/* XR support */
-+	IEEE80211_PARAM_BURST		= 36,	/* burst mode */
-+	IEEE80211_PARAM_PUREG		= 37,	/* pure 11g (no 11b stations) */
-+	IEEE80211_PARAM_AR		= 38,	/* AR support */
-+	IEEE80211_PARAM_WDS		= 39,	/* Enable 4 address processing */
-+	IEEE80211_PARAM_BGSCAN		= 40,	/* bg scanning (on, off) */
-+	IEEE80211_PARAM_BGSCAN_IDLE	= 41,	/* bg scan idle threshold */
-+	IEEE80211_PARAM_BGSCAN_INTERVAL	= 42,	/* bg scan interval */
-+	IEEE80211_PARAM_MCAST_RATE	= 43,	/* Multicast Tx Rate */
-+	IEEE80211_PARAM_COVERAGE_CLASS	= 44,	/* coverage class */
-+	IEEE80211_PARAM_COUNTRY_IE	= 45,	/* enable country IE */
-+	IEEE80211_PARAM_SCANVALID	= 46,	/* scan cache valid threshold */
-+	IEEE80211_PARAM_ROAM_RSSI_11A	= 47,	/* rssi threshold in 11a */
-+	IEEE80211_PARAM_ROAM_RSSI_11B	= 48,	/* rssi threshold in 11b */
-+	IEEE80211_PARAM_ROAM_RSSI_11G	= 49,	/* rssi threshold in 11g */
-+	IEEE80211_PARAM_ROAM_RATE_11A	= 50,	/* tx rate threshold in 11a */
-+	IEEE80211_PARAM_ROAM_RATE_11B	= 51,	/* tx rate threshold in 11b */
-+	IEEE80211_PARAM_ROAM_RATE_11G	= 52,	/* tx rate threshold in 11g */
-+	IEEE80211_PARAM_UAPSDINFO	= 53,	/* value for qos info field */
-+	IEEE80211_PARAM_SLEEP		= 54,	/* force sleep/wake */
-+	IEEE80211_PARAM_QOSNULL		= 55,	/* force sleep/wake */
-+	IEEE80211_PARAM_PSPOLL		= 56,	/* force ps-poll generation (sta only) */
-+	IEEE80211_PARAM_EOSPDROP	= 57,	/* force uapsd EOSP drop (ap only) */
-+	IEEE80211_PARAM_MARKDFS		= 58,	/* mark a dfs interference channel when found */
-+	IEEE80211_PARAM_REGCLASS	= 59,	/* enable regclass ids in country IE */
-+	IEEE80211_PARAM_DROPUNENC_EAPOL	= 60,	/* drop unencrypted eapol frames */
-+ 	IEEE80211_PARAM_SHPREAMBLE	= 61,	/* Short Preamble */
++	IEEE80211_PARAM_TURBO			= 1,	/* turbo mode */
++	IEEE80211_PARAM_MODE			= 2,	/* phy mode (11a, 11b, etc.) */
++	IEEE80211_PARAM_AUTHMODE		= 3,	/* authentication mode */
++	IEEE80211_PARAM_PROTMODE		= 4,	/* 802.11g protection */
++	IEEE80211_PARAM_MCASTCIPHER		= 5,	/* multicast/default cipher */
++	IEEE80211_PARAM_MCASTKEYLEN		= 6,	/* multicast key length */
++	IEEE80211_PARAM_UCASTCIPHERS		= 7,	/* unicast cipher suites */
++	IEEE80211_PARAM_UCASTCIPHER		= 8,	/* unicast cipher */
++	IEEE80211_PARAM_UCASTKEYLEN		= 9,	/* unicast key length */
++	IEEE80211_PARAM_WPA			= 10,	/* WPA mode (0,1,2) */
++	IEEE80211_PARAM_ROAMING			= 12,	/* roaming mode */
++	IEEE80211_PARAM_PRIVACY			= 13,	/* privacy invoked */
++	IEEE80211_PARAM_COUNTERMEASURES		= 14,	/* WPA/TKIP countermeasures */
++	IEEE80211_PARAM_DROPUNENCRYPTED		= 15,	/* discard unencrypted frames */
++	IEEE80211_PARAM_DRIVER_CAPS		= 16,	/* driver capabilities */
++	IEEE80211_PARAM_MACCMD			= 17,	/* MAC ACL operation */
++	IEEE80211_PARAM_WMM			= 18,	/* WMM mode (on, off) */
++	IEEE80211_PARAM_HIDESSID		= 19,	/* hide SSID mode (on, off) */
++	IEEE80211_PARAM_APBRIDGE    		= 20,   /* AP inter-sta bridging */
++	IEEE80211_PARAM_KEYMGTALGS		= 21,	/* key management algorithms */
++	IEEE80211_PARAM_RSNCAPS			= 22,	/* RSN capabilities */
++	IEEE80211_PARAM_INACT			= 23,	/* station inactivity timeout */
++	IEEE80211_PARAM_INACT_AUTH		= 24,	/* station auth inact timeout */
++	IEEE80211_PARAM_INACT_INIT		= 25,	/* station init inact timeout */
++	IEEE80211_PARAM_ABOLT			= 26,	/* Atheros Adv. Capabilities */
++	IEEE80211_PARAM_DTIM_PERIOD		= 28,	/* DTIM period (beacons) */
++	IEEE80211_PARAM_BEACON_INTERVAL		= 29,	/* beacon interval (ms) */
++	IEEE80211_PARAM_DOTH			= 30,	/* 11.h is on/off */
++	IEEE80211_PARAM_PWRTARGET		= 31,	/* Current Channel Pwr Constraint */
++	IEEE80211_PARAM_GENREASSOC		= 32,	/* Generate a reassociation request */
++	IEEE80211_PARAM_COMPRESSION		= 33,	/* compression */
++	IEEE80211_PARAM_FF			= 34,	/* fast frames support  */
++	IEEE80211_PARAM_XR			= 35,	/* XR support */
++	IEEE80211_PARAM_BURST			= 36,	/* burst mode */
++	IEEE80211_PARAM_PUREG			= 37,	/* pure 11g (no 11b stations) */
++	IEEE80211_PARAM_AR			= 38,	/* AR support */
++	IEEE80211_PARAM_WDS			= 39,	/* Enable 4 address processing */
++	IEEE80211_PARAM_BGSCAN			= 40,	/* bg scanning (on, off) */
++	IEEE80211_PARAM_BGSCAN_IDLE		= 41,	/* bg scan idle threshold */
++	IEEE80211_PARAM_BGSCAN_INTERVAL		= 42,	/* bg scan interval */
++	IEEE80211_PARAM_MCAST_RATE		= 43,	/* Multicast Tx Rate */
++	IEEE80211_PARAM_COVERAGE_CLASS		= 44,	/* coverage class */
++	IEEE80211_PARAM_COUNTRY_IE		= 45,	/* enable country IE */
++	IEEE80211_PARAM_SCANVALID		= 46,	/* scan cache valid threshold */
++	IEEE80211_PARAM_ROAM_RSSI_11A		= 47,	/* rssi threshold in 11a */
++	IEEE80211_PARAM_ROAM_RSSI_11B		= 48,	/* rssi threshold in 11b */
++	IEEE80211_PARAM_ROAM_RSSI_11G		= 49,	/* rssi threshold in 11g */
++	IEEE80211_PARAM_ROAM_RATE_11A		= 50,	/* tx rate threshold in 11a */
++	IEEE80211_PARAM_ROAM_RATE_11B		= 51,	/* tx rate threshold in 11b */
++	IEEE80211_PARAM_ROAM_RATE_11G		= 52,	/* tx rate threshold in 11g */
++	IEEE80211_PARAM_UAPSDINFO		= 53,	/* value for qos info field */
++	IEEE80211_PARAM_SLEEP			= 54,	/* force sleep/wake */
++	IEEE80211_PARAM_QOSNULL			= 55,	/* force sleep/wake */
++	IEEE80211_PARAM_PSPOLL			= 56,	/* force ps-poll generation (sta only) */
++	IEEE80211_PARAM_EOSPDROP		= 57,	/* force uapsd EOSP drop (ap only) */
++	IEEE80211_PARAM_MARKDFS			= 58,	/* mark a dfs interference channel when found */
++	IEEE80211_PARAM_REGCLASS		= 59,	/* enable regclass ids in country IE */
++	IEEE80211_PARAM_DROPUNENC_EAPOL		= 60,	/* drop unencrypted eapol frames */
++ 	IEEE80211_PARAM_SHPREAMBLE		= 61,	/* Short Preamble */
++	IEEE80211_PARAM_DUMPREGS		= 62,   /* Pretty printed dump of Atheros hardware registers */
 +};
 +
 +#define	SIOCG80211STATS			(SIOCDEVPRIVATE+2)
@@ -2175,7 +2203,7 @@
 +struct ieee80211req_getset_appiebuf {
 +	u_int32_t	app_frmtype;		/* management frame type for which buffer is added */
 +	u_int32_t	app_buflen;		/* application-supplied buffer length */
-+	u_int8_t	app_buf[];		/* application-supplied IE(s) */
++	u_int8_t	app_buf[0];		/* application-supplied IE(s) */
 +};
 +
 +/* Flags ORed by application to set filter for receiving management frames */




More information about the Pkg-wpa-devel mailing list