[PATCH 7/8] nl80211 driver: use monitor rather than management interface
Jouni Malinen
j
Mon Dec 24 19:13:12 PST 2007
On Mon, Dec 24, 2007 at 12:14:38PM +0100, Johannes Berg wrote:
> This patch makes the nl80211 driver use a monitor rather than a
> management interface for receiving management frames. Monitor
> interfaces use radiotap so a radiotap parser (thanks to Andy Green)
> is also included.
Couple of questions below..
> --- hostap.orig/hostapd/driver_nl80211.c 2007-12-24 12:10:05.000000000 +0100
> +++ hostap/hostapd/driver_nl80211.c 2007-12-24 12:14:15.000000000 +0100
> +static int i802_send_mgmt_frame(void *priv, const void *data, size_t len,
> int flags)
> {
> + /*
> + * ugh, guess what, the generic code sets one of the version
> + * bits to request tx callback
> + */
> + hdr->frame_control &= ~host_to_le16(BIT(1));
> + return sendmsg(drv->monitor_sock, &msg, flags);
How is the TX callback/status requested with the radiotap version? It
looks like there is a flag (IEEE80211_RADIOTAP_TX_FLAGS) for figuring
out status for frames that were reported, but it was not immediately
obvious to me when that information would be provided back to userspace
for injected frames. Is this enabled for all injected frames by default
or there something in the radiotap header that requests this?
> --- /dev/null 1970-01-01 00:00:00.000000000 +0000
> +++ hostap/hostapd/radiotap.c 2007-12-24 12:10:59.000000000 +0100
> @@ -0,0 +1,290 @@
> +/*
> + * Radiotap parser
> + *
> + * Copyright 2007 Andy Green <andy at warmcat.com>
> + *
> + * 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.
> + *
> + * Alternatively, this software may be distributed under the terms of BSD
> + * license.
Hmm.. This is based on code from Linux kernel (net/wireless/radiotap.c).
Right? And that file does not seem to indicate anything special about
license, so I would assume it is GPLv2. Has Andy licensed this code
under dual-GPL/BSD license?
> --- /dev/null 1970-01-01 00:00:00.000000000 +0000
> +++ hostap/hostapd/radiotap.h 2007-12-24 12:10:59.000000000 +0100
> @@ -0,0 +1,242 @@
> +/* $FreeBSD: src/sys/net80211/ieee80211_radiotap.h,v 1.5 2005/01/22 20:12:05 sam Exp $ */
> +/* $NetBSD: ieee80211_radiotap.h,v 1.11 2005/06/22 06:16:02 dyoung Exp $ */
> +
> +/*-
> + * Copyright (c) 2003, 2004 David Young. All rights reserved.
..
Do we need to distribute this file with hostapd? Is there not a standard
user space header for defining radiotap headers? This file has slightly
different license terms from rest of the files and as such, adds extra
complexity on that area.
--
Jouni Malinen PGP id EFC895FA
More information about the Hostap
mailing list