Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 120519 - madwifi-tools wlanconfig integration to Gentoo's rc-scripts
Summary: madwifi-tools wlanconfig integration to Gentoo's rc-scripts
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] baselayout (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Mobile Herd (OBSOLETE)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-27 02:50 UTC by Antti Mäkelä
Modified: 2006-06-28 23:41 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Madwifi rcscript (madwifi,3.04 KB, text/plain)
2006-01-27 02:51 UTC, Antti Mäkelä
Details
wlanconfig.sh (wlanconfig.sh,1.19 KB, text/plain)
2006-06-28 13:31 UTC, Sven Wegener
Details
wlanconfig.sh (wlanconfig.sh,1.65 KB, text/plain)
2006-06-28 16:11 UTC, Sven Wegener
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Antti Mäkelä 2006-01-27 02:50:45 UTC
As discussed in bug #118516, here's my first attempt in creating a "wlanconfig" module. It's based on the bridging module and works in the main task => creating the athX devices. The module is placed at /lib/rcscripts/net.modules.d/madwifi.

The required configuration in /etc/conf.d/net is

madwifi_wifi0="ath0"
config_wifi0=( "null" )

and /etc/conf.d/wireless one needs to specify the mode.

# Set the mode of the interface (managed, ad-hoc, master or auto)
# The default is auto
# If it's ad-hoc or master you also may need to specify the channel below
#mode_eth0="auto"
mode_ath0="ad-hoc"

All the other parameters work as expected (Altough you cannot do any mode-changing, such as dropping to ad-hoc for scan).

Enjoy and try it out..Tested with baselayout 1.11.14-r3. I don't know how this integrates with the changes in 1.12.
Comment 1 Antti Mäkelä 2006-01-27 02:51:34 UTC
Created attachment 78278 [details]
Madwifi rcscript

Place this to /lib/rcscripts/net.modules.d/madwifi.
Comment 2 Antti Mäkelä 2006-01-27 02:53:05 UTC
Oh, and you can specify multiple athX interfaces. 

What needs work is the error handling and bringing down the athX-ifaces gracefully when going down.
Comment 3 Antti Mäkelä 2006-01-27 02:54:45 UTC
Oh and one last thing: To use this, you need to get rid of the udev rule mentioned in bug #118516 (the file /etc/udev/rules.d/65-madwifi.rules). 
Comment 4 Roy Marples (RETIRED) gentoo-dev 2006-01-27 11:10:27 UTC
This module will not be accepted into baselayout as it is device specific. That's not to say that this module is bad as it looks good and appears to work.

Either solution could be bundled with the madwifi-tools ebuild, but I prefer the udev solution myself as that does not depend on any baselayout version (the module API has changed a bit for baselayout-1.12).
Comment 5 Antti Mäkelä 2006-01-27 11:42:09 UTC
  Baselayout or madwifi-tools, whichever is better. I went with baselayout due to the same logic as bridging is in baselayout (should't the bridge module be installed with bridge-utils, then?)

  Anyway I'm opposed to the udev idea (as I mentioned with in the other bug report) because it deviates from the single location for all net&wireless settings (ie. it's putting stuff outside /etc/conf.d/). 
  It wouldn't be so bad if madwifi-driver would allow changing the mode from managed to ad-hoc via iwconfig (and thus,  would work like any other card, ie. one single "ath0" would be enough for all needs). However, that is not going to happen for a long while.

Comment 6 Roy Marples (RETIRED) gentoo-dev 2006-01-27 11:50:13 UTC
(In reply to comment #5)
> should't the bridge module be installed with bridge-utils, then?

Yes it should and will be shortly after baselayout-1.12 goes stable.

>   Anyway I'm opposed to the udev idea (as I mentioned with in the other bug
> report) because it deviates from the single location for all net&wireless
> settings (ie. it's putting stuff outside /etc/conf.d/). 
>   It wouldn't be so bad if madwifi-driver would allow changing the mode from
> managed to ad-hoc via iwconfig (and thus,  would work like any other card, ie.
> one single "ath0" would be enough for all needs). However, that is not going to
> happen for a long while.

Whereas I happen to be apposed to the whole wlanconfig idea and prefer the way things used to be before this madwifi-ng stuff. I'm also the person that has the final say as what goes into the baselayout modules.

At the end of the day, me saying no is probably the best idea as it leaves the final solution with the mobile team in deciding which they prefer - udev or a baselayout module.
Comment 7 Henrik Brix Andersen 2006-01-30 03:17:20 UTC
I would prefer the current approach of using an udev rule. If the other approach is to be used, it will have to be maintained by someone else.
Comment 8 Antti Mäkelä 2006-01-30 03:38:55 UTC
(In reply to comment #7)
> I would prefer the current approach of using an udev rule. If the other
> approach is to be used, it will have to be maintained by someone else.

I doubt that I have enough experience with Gentoo core to start actively maintaining this - especially if it requires running ~ARCH baselayout (with the API changes and all). I'm happy in using this with my own laptop(s), but not quite confident enough in starting to offer this as a "production"-quality piece of scriptwriting..

Any other takers?

Oh well, I hope http://madwifi.org/ticket/176 get's resolved sometime before the Atheros chipset is completely obsolete.
Comment 9 Henrik Brix Andersen 2006-01-30 14:06:29 UTC
I'm sorry, but I will close this as WONTFIX. Thank you for working on this, though. Keep up the good work, and keep the high quality bug reports coming. :)
Comment 10 Sven Wegener gentoo-dev 2006-06-28 13:31:14 UTC
Created attachment 90373 [details]
wlanconfig.sh

Sorry to comment on this quite old bug, but I'd like to have a baselayout module for the madwifi cards. The udev rule has been deprecated. It was only creating one ath* device, taking the next available free number. But wlanconfig allows us to name the interface and create more than one for a base interface. Now the kernel module still creates only one interface automatically. With the baselayout module more can be created when needed.

My code does it the other way round, instead of hooking wifi* and creating the interfaces as a result, it hooks the ath* config and dynamically creates the interface on a specified base interface.
Comment 11 Sven Wegener gentoo-dev 2006-06-28 16:11:29 UTC
Created attachment 90387 [details]
wlanconfig.sh

small touchup
Comment 12 Roy Marples (RETIRED) gentoo-dev 2006-06-28 23:41:03 UTC
(In reply to comment #10)
> Sorry to comment on this quite old bug, but I'd like to have a baselayout
> module for the madwifi cards.

baselayout will not provide one

> The udev rule has been deprecated. It was only
> creating one ath* device, taking the next available free number. But wlanconfig
> allows us to name the interface and create more than one for a base interface.
> Now the kernel module still creates only one interface automatically.

Things are now back to normal - yay.