[pkg-wpa-devel] r1660 - in /iw/trunk: ./ debian/ debian/patches/

slh-guest at users.alioth.debian.org slh-guest at users.alioth.debian.org
Wed Jan 18 16:58:57 UTC 2012


Author: slh-guest
Date: Wed Jan 18 16:58:57 2012
New Revision: 1660

URL: http://svn.debian.org/wsvn/pkg-wpa/?sc=1&rev=1660
Log:
* New upstream release:
  - iw: add HT options for ibss

Added:
    iw/trunk/ieee80211.h
      - copied unchanged from r1659, iw/branches/upstream/current/ieee80211.h
Removed:
    iw/trunk/debian/patches/always-use-libnl-3.2-as-3.2-not-3.0.patch
    iw/trunk/debian/patches/fix-compilation-against-libnl-3.x.patch
    iw/trunk/debian/patches/iw_fix-regression-in-tx-power-validation.patch
Modified:
    iw/trunk/Makefile
    iw/trunk/debian/changelog
    iw/trunk/debian/patches/dont-use-git-on-the-buildd.patch
    iw/trunk/debian/patches/series
    iw/trunk/event.c
    iw/trunk/genl.c
    iw/trunk/ibss.c
    iw/trunk/info.c
    iw/trunk/interface.c
    iw/trunk/iw.8
    iw/trunk/iw.c
    iw/trunk/iw.h
    iw/trunk/nl80211.h
    iw/trunk/phy.c
    iw/trunk/reg.c
    iw/trunk/scan.c
    iw/trunk/util.c
    iw/trunk/version.sh

Modified: iw/trunk/Makefile
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/Makefile?rev=1660&op=diff
==============================================================================
--- iw/trunk/Makefile (original)
+++ iw/trunk/Makefile Wed Jan 18 16:58:57 2012
@@ -25,6 +25,8 @@
 NL1FOUND := $(shell $(PKG_CONFIG) --atleast-version=1 libnl-1 && echo Y)
 NL2FOUND := $(shell $(PKG_CONFIG) --atleast-version=2 libnl-2.0 && echo Y)
 NL3FOUND := $(shell $(PKG_CONFIG) --atleast-version=3 libnl-3.0 && echo Y)
+NL31FOUND := $(shell $(PKG_CONFIG) --exact-version=3.1 libnl-3.1 && echo Y)
+NL3xFOUND := $(shell $(PKG_CONFIG) --atleast-version=3.2 libnl-3.0 && echo Y)
 
 ifeq ($(NL1FOUND),Y)
 NLLIBNAME = libnl-1
@@ -36,10 +38,26 @@
 NLLIBNAME = libnl-2.0
 endif
 
+ifeq ($(NL3xFOUND),Y)
+# libnl 3.2 might be found as 3.2 and 3.0
+NL3FOUND = N
+CFLAGS += -DCONFIG_LIBNL30
+LIBS += -lnl-genl-3
+NLLIBNAME = libnl-3.0
+endif
+
 ifeq ($(NL3FOUND),Y)
 CFLAGS += -DCONFIG_LIBNL30
 LIBS += -lnl-genl
 NLLIBNAME = libnl-3.0
+endif
+
+# nl-3.1 has a broken libnl-gnl-3.1.pc file
+# as show by pkg-config --debug --libs --cflags --exact-version=3.1 libnl-genl-3.1;echo $?
+ifeq ($(NL31FOUND),Y)
+CFLAGS += -DCONFIG_LIBNL30
+LIBS += -lnl-genl
+NLLIBNAME = libnl-3.1
 endif
 
 ifeq ($(NLLIBNAME),)
@@ -57,20 +75,7 @@
 NQ=echo
 endif
 
-all: version_check $(ALL)
-
-version_check:
-ifeq ($(NL3FOUND),Y)
-else
-ifeq ($(NL2FOUND),Y)
-else
-ifeq ($(NL1FOUND),Y)
-else
-	$(error No libnl found)
-endif
-endif
-endif
-
+all: $(ALL)
 
 VERSION_OBJS := $(filter-out version.o, $(OBJS))
 

Modified: iw/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/debian/changelog?rev=1660&op=diff
==============================================================================
--- iw/trunk/debian/changelog (original)
+++ iw/trunk/debian/changelog Wed Jan 18 16:58:57 2012
@@ -1,8 +1,10 @@
-iw (3.2-2) UNRELEASED; urgency=low
+iw (3.3-1) UNRELEASED; urgency=low
 
   * NOT RELEASED YET
+  * New upstream release:
+    - iw: add HT options for ibss
 
- -- Stefan Lippers-Hollmann <s.l-h at gmx.de>  Fri, 30 Dec 2011 16:35:25 +0100
+ -- Stefan Lippers-Hollmann <s.l-h at gmx.de>  Wed, 18 Jan 2012 17:53:16 +0100
 
 iw (3.2-1) unstable; urgency=low
 

Modified: iw/trunk/debian/patches/dont-use-git-on-the-buildd.patch
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/debian/patches/dont-use-git-on-the-buildd.patch?rev=1660&op=diff
==============================================================================
--- iw/trunk/debian/patches/dont-use-git-on-the-buildd.patch (original)
+++ iw/trunk/debian/patches/dont-use-git-on-the-buildd.patch Wed Jan 18 16:58:57 2012
@@ -34,7 +34,7 @@
 --- a/version.sh
 +++ b/version.sh
 @@ -3,21 +3,7 @@
- VERSION="3.2"
+ VERSION="3.3"
  OUT="$1"
  
 -if head=`git rev-parse --verify HEAD 2>/dev/null`; then

Modified: iw/trunk/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/debian/patches/series?rev=1660&op=diff
==============================================================================
--- iw/trunk/debian/patches/series (original)
+++ iw/trunk/debian/patches/series Wed Jan 18 16:58:57 2012
@@ -1,4 +1,1 @@
 dont-use-git-on-the-buildd.patch
-iw_fix-regression-in-tx-power-validation.patch
-fix-compilation-against-libnl-3.x.patch
-always-use-libnl-3.2-as-3.2-not-3.0.patch

Modified: iw/trunk/event.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/event.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/event.c (original)
+++ iw/trunk/event.c Wed Jan 18 16:58:57 2012
@@ -321,6 +321,10 @@
 		mac_addr_n2a(macbuf, nla_data(tb[NL80211_ATTR_MAC]));
 		printf("new station %s\n", macbuf);
 		break;
+	case NL80211_CMD_DEL_STATION:
+		mac_addr_n2a(macbuf, nla_data(tb[NL80211_ATTR_MAC]));
+		printf("del station %s\n", macbuf);
+		break;
 	case NL80211_CMD_JOIN_IBSS:
 		mac_addr_n2a(macbuf, nla_data(tb[NL80211_ATTR_MAC]));
 		printf("IBSS %s joined\n", macbuf);

Modified: iw/trunk/genl.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/genl.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/genl.c (original)
+++ iw/trunk/genl.c Wed Jan 18 16:58:57 2012
@@ -5,7 +5,7 @@
 #include <asm/errno.h>
 #include <netlink/genl/genl.h>
 #include <netlink/genl/family.h>
-#include <netlink/genl/ctrl.h>  
+#include <netlink/genl/ctrl.h>
 #include <netlink/msg.h>
 #include <netlink/attr.h>
 #include <linux/genetlink.h>
@@ -43,7 +43,7 @@
 	nla_parse(tb, CTRL_ATTR_MAX, genlmsg_attrdata(gnlh, 0),
 		  genlmsg_attrlen(gnlh, 0), NULL);
 
-        if (!tb[CTRL_ATTR_MCAST_GROUPS])
+	if (!tb[CTRL_ATTR_MCAST_GROUPS])
 		return NL_SKIP;
 
 	nla_for_each_nested(mcgrp, tb[CTRL_ATTR_MCAST_GROUPS], rem_mcgrp) {
@@ -61,7 +61,7 @@
 		grp->id = nla_get_u32(tb_mcgrp[CTRL_ATTR_MCAST_GRP_ID]);
 		break;
 	}
-	
+
 	return NL_SKIP;
 }
 
@@ -87,7 +87,7 @@
 
 	ctrlid = genl_ctrl_resolve(sock, "nlctrl");
 
-        genlmsg_put(msg, 0, 0, ctrlid, 0,
+	genlmsg_put(msg, 0, 0, ctrlid, 0,
 		    0, CTRL_CMD_GETFAMILY, 0);
 
 	ret = -ENOBUFS;

Modified: iw/trunk/ibss.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/ibss.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/ibss.c (original)
+++ iw/trunk/ibss.c Wed Jan 18 16:58:57 2012
@@ -3,6 +3,7 @@
 #endif
 #include <errno.h>
 #include <string.h>
+#include <strings.h>
 
 #include <netlink/genl/genl.h>
 #include <netlink/genl/family.h>
@@ -27,6 +28,17 @@
 	char *value = NULL, *sptr = NULL;
 	float rate;
 	int bintval;
+	int i;
+	static const struct {
+		const char *name;
+		unsigned int val;
+	} htmap[] = {
+		{ .name = "HT20", .val = NL80211_CHAN_HT20, },
+		{ .name = "HT40+", .val = NL80211_CHAN_HT40PLUS, },
+		{ .name = "HT40-", .val = NL80211_CHAN_HT40MINUS, },
+		{ .name = "NOHT", .val = NL80211_CHAN_NO_HT, },
+	};
+	unsigned int htval;
 
 	if (argc < 2)
 		return 1;
@@ -43,6 +55,22 @@
 		return 1;
 	argv++;
 	argc--;
+
+	if (argc) {
+		for (i = 0; i < ARRAY_SIZE(htmap); i++) {
+			if (strcasecmp(htmap[i].name, argv[0]) == 0) {
+				htval = htmap[i].val;
+				break;
+			}
+		}
+		if (i != ARRAY_SIZE(htmap)) {
+			NLA_PUT_U32(msg, NL80211_ATTR_WIPHY_CHANNEL_TYPE,
+				    htval);
+			argv++;
+			argc--;
+		}
+
+	}
 
 	if (argc && strcmp(argv[0], "fixed-freq") == 0) {
 		NLA_PUT_FLAG(msg, NL80211_ATTR_FREQ_FIXED);
@@ -134,7 +162,7 @@
 	NL80211_CMD_LEAVE_IBSS, 0, CIB_NETDEV, leave_ibss,
 	"Leave the current IBSS cell.");
 COMMAND(ibss, join,
-	"<SSID> <freq in MHz> [fixed-freq] [<fixed bssid>] [beacon-interval <TU>]"
+	"<SSID> <freq in MHz> [HT20|HT40+|HT40-|NOHT] [fixed-freq] [<fixed bssid>] [beacon-interval <TU>]"
 	" [basic-rates <rate in Mbps,rate2,...>] [mcast-rate <rate in Mbps>] "
 	"[key d:0:abcde]",
 	NL80211_CMD_JOIN_IBSS, 0, CIB_NETDEV, join_ibss,

Modified: iw/trunk/info.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/info.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/info.c (original)
+++ iw/trunk/info.c Wed Jan 18 16:58:57 2012
@@ -400,6 +400,44 @@
 	if (tb_msg[NL80211_ATTR_SUPPORT_AP_UAPSD])
 		printf("\tDevice supports AP-side u-APSD.\n");
 
+	if (tb_msg[NL80211_ATTR_HT_CAPABILITY_MASK]) {
+		struct ieee80211_ht_cap *cm;
+		printf("\tHT Capability overrides:\n");
+		if (nla_len(tb_msg[NL80211_ATTR_HT_CAPABILITY_MASK]) >= sizeof(*cm)) {
+			cm = nla_data(tb_msg[NL80211_ATTR_HT_CAPABILITY_MASK]);
+			printf("\t\t * MCS: %02hhx %02hhx %02hhx %02hhx %02hhx %02hhx"
+			       " %02hhx %02hhx %02hhx %02hhx\n",
+			       cm->mcs.rx_mask[0], cm->mcs.rx_mask[1],
+			       cm->mcs.rx_mask[2], cm->mcs.rx_mask[3],
+			       cm->mcs.rx_mask[4], cm->mcs.rx_mask[5],
+			       cm->mcs.rx_mask[6], cm->mcs.rx_mask[7],
+			       cm->mcs.rx_mask[8], cm->mcs.rx_mask[9]);
+			if (cm->cap_info & htole16(IEEE80211_HT_CAP_MAX_AMSDU))
+				printf("\t\t * maximum A-MSDU length\n");
+			if (cm->cap_info & htole16(IEEE80211_HT_CAP_SUP_WIDTH_20_40))
+				printf("\t\t * supported channel width\n");
+			if (cm->cap_info & htole16(IEEE80211_HT_CAP_SGI_40))
+				printf("\t\t * short GI for 40 MHz\n");
+			if (cm->ampdu_params_info & IEEE80211_HT_AMPDU_PARM_FACTOR)
+				printf("\t\t * max A-MPDU length exponent\n");
+			if (cm->ampdu_params_info & IEEE80211_HT_AMPDU_PARM_DENSITY)
+				printf("\t\t * min MPDU start spacing\n");
+		} else {
+			printf("\tERROR: capabilities mask is too short, expected: %d, received: %d\n",
+			       (int)(sizeof(*cm)),
+			       (int)(nla_len(tb_msg[NL80211_ATTR_HT_CAPABILITY_MASK])));
+		}
+	}
+
+	if (tb_msg[NL80211_ATTR_FEATURE_FLAGS]) {
+		if (nla_get_u32(tb_msg[NL80211_ATTR_FEATURE_FLAGS]) &
+				NL80211_FEATURE_SK_TX_STATUS)
+			printf("\tDevice supports TX status socket option.\n");
+		if (nla_get_u32(tb_msg[NL80211_ATTR_FEATURE_FLAGS]) &
+				NL80211_FEATURE_HT_IBSS)
+			printf("\tDevice supports HT-IBSS.\n");
+	}
+
 	return NL_SKIP;
 }
 

Modified: iw/trunk/interface.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/interface.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/interface.c (original)
+++ iw/trunk/interface.c Wed Jan 18 16:58:57 2012
@@ -386,6 +386,33 @@
 	NL80211_CMD_SET_INTERFACE, 0, CIB_NETDEV, handle_interface_4addr,
 	"Set interface 4addr (WDS) mode.");
 
+static int handle_interface_noack_map(struct nl80211_state *state,
+				      struct nl_cb *cb,
+				      struct nl_msg *msg,
+				      int argc, char **argv)
+{
+	uint16_t noack_map;
+	char *end;
+
+	if (argc != 1)
+		return 1;
+
+	noack_map = strtoul(argv[0], &end, 16);
+	if (*end)
+		return 1;
+
+	NLA_PUT_U16(msg, NL80211_ATTR_NOACK_MAP, noack_map);
+
+	return 0;
+ nla_put_failure:
+	return -ENOBUFS;
+
+}
+COMMAND(set, noack_map, "<map>",
+	NL80211_CMD_SET_NOACK_MAP, 0, CIB_NETDEV, handle_interface_noack_map,
+	"Set the NoAck map for the TIDs. (0x0009 = BE, 0x0006 = BK, 0x0030 = VI, 0x00C0 = VO)");
+
+
 static int handle_interface_wds_peer(struct nl80211_state *state,
 				     struct nl_cb *cb,
 				     struct nl_msg *msg,

Modified: iw/trunk/iw.8
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/iw.8?rev=1660&op=diff
==============================================================================
--- iw/trunk/iw.8 (original)
+++ iw/trunk/iw.8 Wed Jan 18 16:58:57 2012
@@ -7,7 +7,7 @@
 .in +8
 .ti -8
 .B iw
-.RI [ " OPTIONS " ] " " { " 
+.RI [ " OPTIONS " ] " " { "
 .BR help " |"
 .RI ""OBJECT " " COMMAND " }"
 .sp

Modified: iw/trunk/iw.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/iw.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/iw.c (original)
+++ iw/trunk/iw.c Wed Jan 18 16:58:57 2012
@@ -13,10 +13,10 @@
 #include <fcntl.h>
 #include <unistd.h>
 #include <stdbool.h>
-                     
+
 #include <netlink/genl/genl.h>
 #include <netlink/genl/family.h>
-#include <netlink/genl/ctrl.h>  
+#include <netlink/genl/ctrl.h>
 #include <netlink/msg.h>
 #include <netlink/attr.h>
 
@@ -34,16 +34,6 @@
 {
 	nl_handle_destroy(h);
 }
-
-static inline int __genl_ctrl_alloc_cache(struct nl_sock *h, struct nl_cache **cache)
-{
-	struct nl_cache *tmp = genl_ctrl_alloc_cache(h);
-	if (!tmp)
-		return -ENOMEM;
-	*cache = tmp;
-	return 0;
-}
-#define genl_ctrl_alloc_cache __genl_ctrl_alloc_cache
 #endif /* CONFIG_LIBNL20 && CONFIG_LIBNL30 */
 
 int iw_debug = 0;
@@ -64,23 +54,15 @@
 		goto out_handle_destroy;
 	}
 
-	if (genl_ctrl_alloc_cache(state->nl_sock, &state->nl_cache)) {
-		fprintf(stderr, "Failed to allocate generic netlink cache.\n");
-		err = -ENOMEM;
-		goto out_handle_destroy;
-	}
-
-	state->nl80211 = genl_ctrl_search_by_name(state->nl_cache, "nl80211");
-	if (!state->nl80211) {
+	state->nl80211_id = genl_ctrl_resolve(state->nl_sock, "nl80211");
+	if (state->nl80211_id < 0) {
 		fprintf(stderr, "nl80211 not found.\n");
 		err = -ENOENT;
-		goto out_cache_free;
+		goto out_handle_destroy;
 	}
 
 	return 0;
 
- out_cache_free:
-	nl_cache_free(state->nl_cache);
  out_handle_destroy:
 	nl_socket_free(state->nl_sock);
 	return err;
@@ -88,8 +70,6 @@
 
 static void nl80211_cleanup(struct nl80211_state *state)
 {
-	genl_family_put(state->nl80211);
-	nl_cache_free(state->nl_cache);
 	nl_socket_free(state->nl_sock);
 }
 
@@ -387,7 +367,7 @@
 		goto out_free_msg;
 	}
 
-	genlmsg_put(msg, 0, 0, genl_family_get_id(state->nl80211), 0,
+	genlmsg_put(msg, 0, 0, state->nl80211_id, 0,
 		    cmd->nl_msg_flags, cmd->cmd, 0);
 
 	switch (command_idby) {

Modified: iw/trunk/iw.h
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/iw.h?rev=1660&op=diff
==============================================================================
--- iw/trunk/iw.h (original)
+++ iw/trunk/iw.h Wed Jan 18 16:58:57 2012
@@ -6,8 +6,10 @@
 #include <netlink/genl/genl.h>
 #include <netlink/genl/family.h>
 #include <netlink/genl/ctrl.h>
+#include <endian.h>
 
 #include "nl80211.h"
+#include "ieee80211.h"
 
 #define ETH_ALEN 6
 
@@ -18,8 +20,7 @@
 
 struct nl80211_state {
 	struct nl_sock *nl_sock;
-	struct nl_cache *nl_cache;
-	struct genl_family *nl80211;
+	int nl80211_id;
 };
 
 enum command_identify_by {

Modified: iw/trunk/nl80211.h
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/nl80211.h?rev=1660&op=diff
==============================================================================
--- iw/trunk/nl80211.h (original)
+++ iw/trunk/nl80211.h Wed Jan 18 16:58:57 2012
@@ -509,6 +509,38 @@
  * @NL80211_CMD_TDLS_OPER: Perform a high-level TDLS command (e.g. link setup).
  * @NL80211_CMD_TDLS_MGMT: Send a TDLS management frame.
  *
+ * @NL80211_CMD_UNEXPECTED_FRAME: Used by an application controlling an AP
+ *	(or GO) interface (i.e. hostapd) to ask for unexpected frames to
+ *	implement sending deauth to stations that send unexpected class 3
+ *	frames. Also used as the event sent by the kernel when such a frame
+ *	is received.
+ *	For the event, the %NL80211_ATTR_MAC attribute carries the TA and
+ *	other attributes like the interface index are present.
+ *	If used as the command it must have an interface index and you can
+ *	only unsubscribe from the event by closing the socket. Subscription
+ *	is also for %NL80211_CMD_UNEXPECTED_4ADDR_FRAME events.
+ *
+ * @NL80211_CMD_UNEXPECTED_4ADDR_FRAME: Sent as an event indicating that the
+ *	associated station identified by %NL80211_ATTR_MAC sent a 4addr frame
+ *	and wasn't already in a 4-addr VLAN. The event will be sent similarly
+ *	to the %NL80211_CMD_UNEXPECTED_FRAME event, to the same listener.
+ *
+ * @NL80211_CMD_PROBE_CLIENT: Probe an associated station on an AP interface
+ *	by sending a null data frame to it and reporting when the frame is
+ *	acknowleged. This is used to allow timing out inactive clients. Uses
+ *	%NL80211_ATTR_IFINDEX and %NL80211_ATTR_MAC. The command returns a
+ *	direct reply with an %NL80211_ATTR_COOKIE that is later used to match
+ *	up the event with the request. The event includes the same data and
+ *	has %NL80211_ATTR_ACK set if the frame was ACKed.
+ *
+ * @NL80211_CMD_REGISTER_BEACONS: Register this socket to receive beacons from
+ *	other BSSes when any interfaces are in AP mode. This helps implement
+ *	OLBC handling in hostapd. Beacons are reported in %NL80211_CMD_FRAME
+ *	messages. Note that per PHY only one application may register.
+ *
+ * @NL80211_CMD_SET_NOACK_MAP: sets a bitmap for the individual TIDs whether
+ *      No Acknowledgement Policy should be applied.
+ *
  * @NL80211_CMD_MAX: highest used command number
  * @__NL80211_CMD_AFTER_LAST: internal use
  */
@@ -637,6 +669,16 @@
 
 	NL80211_CMD_TDLS_OPER,
 	NL80211_CMD_TDLS_MGMT,
+
+	NL80211_CMD_UNEXPECTED_FRAME,
+
+	NL80211_CMD_PROBE_CLIENT,
+
+	NL80211_CMD_REGISTER_BEACONS,
+
+	NL80211_CMD_UNEXPECTED_4ADDR_FRAME,
+
+	NL80211_CMD_SET_NOACK_MAP,
 
 	/* add new commands above here */
 
@@ -657,6 +699,8 @@
 #define NL80211_CMD_DEAUTHENTICATE NL80211_CMD_DEAUTHENTICATE
 #define NL80211_CMD_DISASSOCIATE NL80211_CMD_DISASSOCIATE
 #define NL80211_CMD_REG_BEACON_HINT NL80211_CMD_REG_BEACON_HINT
+
+#define NL80211_ATTR_FEATURE_FLAGS NL80211_ATTR_FEATURE_FLAGS
 
 /* source-level API compatibility */
 #define NL80211_CMD_GET_MESH_PARAMS NL80211_CMD_GET_MESH_CONFIG
@@ -1109,6 +1153,46 @@
  *	%NL80211_CMD_TDLS_MGMT. Otherwise %NL80211_CMD_TDLS_OPER should be
  *	used for asking the driver to perform a TDLS operation.
  *
+ * @NL80211_ATTR_DEVICE_AP_SME: This u32 attribute may be listed for devices
+ *	that have AP support to indicate that they have the AP SME integrated
+ *	with support for the features listed in this attribute, see
+ *	&enum nl80211_ap_sme_features.
+ *
+ * @NL80211_ATTR_DONT_WAIT_FOR_ACK: Used with %NL80211_CMD_FRAME, this tells
+ *	the driver to not wait for an acknowledgement. Note that due to this,
+ *	it will also not give a status callback nor return a cookie. This is
+ *	mostly useful for probe responses to save airtime.
+ *
+ * @NL80211_ATTR_FEATURE_FLAGS: This u32 attribute contains flags from
+ *	&enum nl80211_feature_flags and is advertised in wiphy information.
+ * @NL80211_ATTR_PROBE_RESP_OFFLOAD: Indicates that the HW responds to probe
+ *
+ *	requests while operating in AP-mode.
+ *	This attribute holds a bitmap of the supported protocols for
+ *	offloading (see &enum nl80211_probe_resp_offload_support_attr).
+ *
+ * @NL80211_ATTR_PROBE_RESP: Probe Response template data. Contains the entire
+ *	probe-response frame. The DA field in the 802.11 header is zero-ed out,
+ *	to be filled by the FW.
+ * @NL80211_ATTR_DISABLE_HT:  Force HT capable interfaces to disable
+ *      this feature.  Currently, only supported in mac80211 drivers.
+ * @NL80211_ATTR_HT_CAPABILITY_MASK: Specify which bits of the
+ *      ATTR_HT_CAPABILITY to which attention should be paid.
+ *      Currently, only mac80211 NICs support this feature.
+ *      The values that may be configured are:
+ *       MCS rates, MAX-AMSDU, HT-20-40 and HT_CAP_SGI_40
+ *       AMPDU density and AMPDU factor.
+ *      All values are treated as suggestions and may be ignored
+ *      by the driver as required.  The actual values may be seen in
+ *      the station debugfs ht_caps file.
+ *
+ * @NL80211_ATTR_DFS_REGION: region for regulatory rules which this country
+ *    abides to when initiating radiation on DFS channels. A country maps
+ *    to one DFS region.
+ *
+ * @NL80211_ATTR_NOACK_MAP: This u16 bitmap contains the No Ack Policy of
+ *      up to 16 TIDs.
+ *
  * @NL80211_ATTR_MAX: highest attribute number currently defined
  * @__NL80211_ATTR_AFTER_LAST: internal use
  */
@@ -1336,6 +1420,23 @@
 	NL80211_ATTR_TDLS_OPERATION,
 	NL80211_ATTR_TDLS_SUPPORT,
 	NL80211_ATTR_TDLS_EXTERNAL_SETUP,
+
+	NL80211_ATTR_DEVICE_AP_SME,
+
+	NL80211_ATTR_DONT_WAIT_FOR_ACK,
+
+	NL80211_ATTR_FEATURE_FLAGS,
+
+	NL80211_ATTR_PROBE_RESP_OFFLOAD,
+
+	NL80211_ATTR_PROBE_RESP,
+
+	NL80211_ATTR_DFS_REGION,
+
+	NL80211_ATTR_DISABLE_HT,
+	NL80211_ATTR_HT_CAPABILITY_MASK,
+
+	NL80211_ATTR_NOACK_MAP,
 
 	/* add attributes here, update the policy in nl80211.c */
 
@@ -1371,6 +1472,7 @@
 #define NL80211_ATTR_AKM_SUITES NL80211_ATTR_AKM_SUITES
 #define NL80211_ATTR_KEY NL80211_ATTR_KEY
 #define NL80211_ATTR_KEYS NL80211_ATTR_KEYS
+#define NL80211_ATTR_FEATURE_FLAGS NL80211_ATTR_FEATURE_FLAGS
 
 #define NL80211_MAX_SUPP_RATES			32
 #define NL80211_MAX_SUPP_REG_RULES		32
@@ -1845,6 +1947,21 @@
 };
 
 /**
+ * enum nl80211_dfs_regions - regulatory DFS regions
+ *
+ * @NL80211_DFS_UNSET: Country has no DFS master region specified
+ * @NL80211_DFS_FCC_: Country follows DFS master rules from FCC
+ * @NL80211_DFS_FCC_: Country follows DFS master rules from ETSI
+ * @NL80211_DFS_JP_: Country follows DFS master rules from JP/MKK/Telec
+ */
+enum nl80211_dfs_regions {
+	NL80211_DFS_UNSET	= 0,
+	NL80211_DFS_FCC		= 1,
+	NL80211_DFS_ETSI	= 2,
+	NL80211_DFS_JP		= 3,
+};
+
+/**
  * enum nl80211_survey_info - survey information
  *
  * These attribute types are used with %NL80211_ATTR_SURVEY_INFO
@@ -1976,6 +2093,10 @@
  * @NL80211_MESHCONF_GATE_ANNOUNCEMENTS: Advertise that this mesh station has
  * access to a broader network beyond the MBSS.  This is done via Root
  * Announcement frames.
+ *
+ * @NL80211_MESHCONF_HWMP_PERR_MIN_INTERVAL: The minimum interval of time (in
+ * TUs) during which a mesh STA can send only one Action frame containing a
+ * PERR element.
  *
  * @NL80211_MESHCONF_ATTR_MAX: highest possible mesh configuration attribute
  *
@@ -2000,6 +2121,7 @@
 	NL80211_MESHCONF_ELEMENT_TTL,
 	NL80211_MESHCONF_HWMP_RANN_INTERVAL,
 	NL80211_MESHCONF_GATE_ANNOUNCEMENTS,
+	NL80211_MESHCONF_HWMP_PERR_MIN_INTERVAL,
 
 	/* keep last */
 	__NL80211_MESHCONF_ATTR_AFTER_LAST,
@@ -2650,4 +2772,45 @@
 	NL80211_TDLS_DISABLE_LINK,
 };
 
+/*
+ * enum nl80211_ap_sme_features - device-integrated AP features
+ * Reserved for future use, no bits are defined in
+ * NL80211_ATTR_DEVICE_AP_SME yet.
+enum nl80211_ap_sme_features {
+};
+ */
+
+/**
+ * enum nl80211_feature_flags - device/driver features
+ * @NL80211_FEATURE_SK_TX_STATUS: This driver supports reflecting back
+ *	TX status to the socket error queue when requested with the
+ *	socket option.
+ * @NL80211_FEATURE_HT_IBSS: This driver supports IBSS with HT datarates.
+ */
+enum nl80211_feature_flags {
+	NL80211_FEATURE_SK_TX_STATUS	= 1 << 0,
+	NL80211_FEATURE_HT_IBSS		= 1 << 1,
+};
+
+/**
+ * enum nl80211_probe_resp_offload_support_attr - optional supported
+ *	protocols for probe-response offloading by the driver/FW.
+ *	To be used with the %NL80211_ATTR_PROBE_RESP_OFFLOAD attribute.
+ *	Each enum value represents a bit in the bitmap of supported
+ *	protocols. Typically a subset of probe-requests belonging to a
+ *	supported protocol will be excluded from offload and uploaded
+ *	to the host.
+ *
+ * @NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS: Support for WPS ver. 1
+ * @NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS2: Support for WPS ver. 2
+ * @NL80211_PROBE_RESP_OFFLOAD_SUPPORT_P2P: Support for P2P
+ * @NL80211_PROBE_RESP_OFFLOAD_SUPPORT_80211U: Support for 802.11u
+ */
+enum nl80211_probe_resp_offload_support_attr {
+	NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS =	1<<0,
+	NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS2 =	1<<1,
+	NL80211_PROBE_RESP_OFFLOAD_SUPPORT_P2P =	1<<2,
+	NL80211_PROBE_RESP_OFFLOAD_SUPPORT_80211U =	1<<3,
+};
+
 #endif /* __LINUX_NL80211_H */

Modified: iw/trunk/phy.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/phy.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/phy.c (original)
+++ iw/trunk/phy.c Wed Jan 18 16:58:57 2012
@@ -176,7 +176,7 @@
 		return 1;
 
 	NLA_PUT_U32(msg, NL80211_ATTR_PID,
-		    strtoul(argv[0], &end, 10)); 
+		    strtoul(argv[0], &end, 10));
 
 	if (*end != '\0')
 		return 1;
@@ -293,7 +293,7 @@
 		}
 
 		mbm = strtol(argv[1], &endptr, 10);
-		if (!*endptr)
+		if (*endptr)
 			return 2;
 		NLA_PUT_U32(msg, NL80211_ATTR_WIPHY_TX_POWER_LEVEL, mbm);
 	} else if (argc != 1)

Modified: iw/trunk/reg.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/reg.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/reg.c (original)
+++ iw/trunk/reg.c Wed Jan 18 16:58:57 2012
@@ -110,12 +110,12 @@
 	struct nlattr *nl_rule;
 	int rem_rule;
 	static struct nla_policy reg_rule_policy[NL80211_FREQUENCY_ATTR_MAX + 1] = {
-		[NL80211_ATTR_REG_RULE_FLAGS]           = { .type = NLA_U32 },
-		[NL80211_ATTR_FREQ_RANGE_START]         = { .type = NLA_U32 },
-		[NL80211_ATTR_FREQ_RANGE_END]           = { .type = NLA_U32 },
-		[NL80211_ATTR_FREQ_RANGE_MAX_BW]        = { .type = NLA_U32 },
-		[NL80211_ATTR_POWER_RULE_MAX_ANT_GAIN]  = { .type = NLA_U32 },
-		[NL80211_ATTR_POWER_RULE_MAX_EIRP]      = { .type = NLA_U32 },
+		[NL80211_ATTR_REG_RULE_FLAGS]		= { .type = NLA_U32 },
+		[NL80211_ATTR_FREQ_RANGE_START]		= { .type = NLA_U32 },
+		[NL80211_ATTR_FREQ_RANGE_END]		= { .type = NLA_U32 },
+		[NL80211_ATTR_FREQ_RANGE_MAX_BW]	= { .type = NLA_U32 },
+		[NL80211_ATTR_POWER_RULE_MAX_ANT_GAIN]	= { .type = NLA_U32 },
+		[NL80211_ATTR_POWER_RULE_MAX_EIRP]	= { .type = NLA_U32 },
 	};
 
 	nla_parse(tb_msg, NL80211_ATTR_MAX, genlmsg_attrdata(gnlh, 0),

Modified: iw/trunk/scan.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/scan.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/scan.c (original)
+++ iw/trunk/scan.c Wed Jan 18 16:58:57 2012
@@ -707,7 +707,7 @@
 
 	for (i = 0; i < 4; i++) {
 		printf("\n\t\t * %s:", aci_tbl[(data[0] >> 5) & 3]);
-		if (data[4] & 0x10)
+		if (data[0] & 0x10)
 			printf(" acm");
 		printf(" CW %d-%d", (1 << (data[1] & 0xf)) - 1,
 				    (1 << (data[1] >> 4)) - 1);
@@ -1219,7 +1219,7 @@
 		int age = nla_get_u32(bss[NL80211_BSS_SEEN_MS_AGO]);
 		printf("\tlast seen: %d ms ago\n", age);
 	}
-	
+
 	if (bss[NL80211_BSS_INFORMATION_ELEMENTS] && show--) {
 		if (bss[NL80211_BSS_BEACON_IES])
 			printf("\tInformation elements from Probe Response "

Modified: iw/trunk/util.c
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/util.c?rev=1660&op=diff
==============================================================================
--- iw/trunk/util.c (original)
+++ iw/trunk/util.c Wed Jan 18 16:58:57 2012
@@ -387,7 +387,7 @@
 
 static void print_mcs_index(const __u8 *mcs)
 {
-	unsigned int mcs_bit, prev_bit = -2, prev_cont = 0;
+	int mcs_bit, prev_bit = -2, prev_cont = 0;
 
 	for (mcs_bit = 0; mcs_bit <= 76; mcs_bit++) {
 		unsigned int mcs_octet = mcs_bit/8;
@@ -461,7 +461,7 @@
 	if (max_ampdu_length) {
 		printf("\t\tMaximum RX AMPDU length %d bytes (exponent: 0x0%02x)\n",
 		       max_ampdu_length, exponent);
-        } else {
+	} else {
 		printf("\t\tMaximum RX AMPDU length: unrecognized bytes "
 		       "(exponent: %d)\n", exponent);
 	}
@@ -469,8 +469,8 @@
 
 void print_ampdu_spacing(__u8 spacing)
 {
-        printf("\t\tMinimum RX AMPDU time spacing: %s (0x%02x)\n",
-               print_ampdu_space(spacing), spacing);
+	printf("\t\tMinimum RX AMPDU time spacing: %s (0x%02x)\n",
+	       print_ampdu_space(spacing), spacing);
 }
 
 void print_ht_capability(__u16 cap)

Modified: iw/trunk/version.sh
URL: http://svn.debian.org/wsvn/pkg-wpa/iw/trunk/version.sh?rev=1660&op=diff
==============================================================================
--- iw/trunk/version.sh (original)
+++ iw/trunk/version.sh Wed Jan 18 16:58:57 2012
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-VERSION="3.2"
+VERSION="3.3"
 OUT="$1"
 
 if head=`git rev-parse --verify HEAD 2>/dev/null`; then




More information about the Pkg-wpa-devel mailing list