Search Linux Wireless

Re: [PATCH/RFC 0/3] hwsim user-space frame processing

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2010-03-11 at 23:43 -0500, Bob Copeland wrote:
> This patchset moves the forwarding of frames in mac80211 hwsim
> into user-space.  This gives the ability to simulate loss,
> retransmission delays, collisions, etc. in a controlled environment
> while still using the whole stack.
> 
> A few disclaimers:
> 
>  - We don't expire pending (transmitted but not status-reported) packets.
>    This is a nice DoS waiting to happen, so that needs to be fixed.
> 
>  - This breaks the in-kernel forwarding.  It may be useful to still
>    do that for quick-and-dirty testing, via modparam or something.
> 
>  - It really wants a configuration ioctl that happens before the device
>    is registered, so you can set up the rate set and so forth.  The ABI
>    needs work in general.
> 
> How to use:
> 
> 1. Write a program to open /dev/mac80211_hwsim_control for as many radios
>    as you want, and shuffle packets between the file descriptors.  Or
>    suitably modify my proof-of-concept:
> 
>    http://bobcopeland.com/srcs/wifi_sim.tar.gz
> 
> 2. Set up network namespaces, and put the devices in separate namespaces.
> This may no longer be necessary, I haven't kept up.
> 
> 3. Run hostapd on one interface and connect to it from the other(s).
> 
> I keep this patch to unbreak netns, which will likely explode your computer:

This is easier and will work without exploding, but NM will stop working
with this patch:

--- wireless-testing.orig/net/mac80211/iface.c	2010-02-09 09:09:30.000000000 +0100
+++ wireless-testing/net/mac80211/iface.c	2010-02-09 09:09:49.000000000 +0100
@@ -858,7 +858,7 @@ int ieee80211_if_add(struct ieee80211_lo
 
 	memcpy(ndev->dev_addr, local->hw.wiphy->perm_addr, ETH_ALEN);
 	memcpy(ndev->perm_addr, ndev->dev_addr, ETH_ALEN);
-	SET_NETDEV_DEV(ndev, wiphy_dev(local->hw.wiphy));
+//	SET_NETDEV_DEV(ndev, wiphy_dev(local->hw.wiphy));
 
 	/* don't use IEEE80211_DEV_TO_SUB_IF because it checks too much */
 	sdata = netdev_priv(ndev);


johannes

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux