Re: [Madwifi-users] random i/o errors when creating v.interfaces
Status: Beta
Brought to you by:
otaku
From: Pavel R. <pr...@gn...> - 2008-06-24 22:43:12
|
On Tue, 2008-06-24 at 18:38 -0400, Simon wrote: > Hi, > I have an eeepc and i'm using madwifi-ng-r3366+ar5007. I've been using it > for I think as long as it's out. Everything has been working perfectly fine to > my knowledge except when trying to create multiple virtual interfaces. > > I am a newbie in terms of wireless and madwifi. However, I've been learning > a lot. So here's something I've been trying to do: say, create a managed > interface as wlan0 and a master interface as wlan1, usually works fine. If I > try to create a monitor interface on wlan2, it gives me an input/output error > and the interface is not created. I've tried several combinations and so far, I > believe the problem is random, that's why I haven't written down a specific list > of issues... > > It is probably a different problem, but I noticed that if I play around the > interfaces like that for some time, then even deleting all and recreating a > single managed interface will fail in the same fashion (as if it was > saturated!)... the only solution I found was a reboot. Reloading ath_pci should help: rmmod ath_pci modprobe ath_pci > I wanted to know if this was a known bug or if it was part of the > specification (such as the sharing of the physical layer for all these > v.interfaces)? And if it is a problem, what information could help diagnose? I > guess an extract of dmesg and /var/log/messages + the output in > /var/log/messages when creating the interface...? There are limitations, but there are also bugs. The code for VAP creation and deletion needs work. I'm not sure anyone would seriously bother with all that, considering that MadWifi is supposed to be replaced with ath5k, but if you want, you can debug and fix it. First of all, please use more recent code, so that your patches can be applied. There is a branch in Subversion with the AR5007 support, you can check it out with svn co https://svn.madwifi.org/madwifi/branches/madwifi-hal-0.10.5.6 The logic to create VAPs is in ath_vap_create(), and the destroying VAPs is done in ath_vap_delete(). Both are in ath/if_ath.c. You can easily see that the VAP deletion doesn't undo all changes done by the VAP creation. In particular, changes to ic->ic_opmode are not reverted. A fix would be to have a common function that would set ic->ic_opmode and other hardware-global parameters for the new set of VAPs. Also, it's possible to create VAP more than once. That's the easiest way to confuse MadWifi so that new managed interfaces cannot be created: modprobe ath_pci autocreate=none wlanconfig wlan0 create wlandev wifi0 wlanmode ap wlanconfig wlan0 create wlandev wifi0 wlanmode sta wlanconfig wlan0 destroy wlanconfig wlan0 create wlandev wifi0 wlanmode sta This should not be allowed. -- Regards, Pavel Roskin |