In version 0.9.3-r2, the madwifi-ng driver does not detect my AR5211 Atheros card. It works fine if I downgrade to 0.9.2.1. When the drivers are inserted into the kernel, there are no messages in dmesg about it detecting the card, and the wifi0 device isn't created. eta madwifi-ng # lspci -s 02:02.0 -vvvv 02:02.0 Ethernet controller: Atheros Communications, Inc. AR5211 802.11ab NIC (rev 01) Subsystem: Unknown device 17ab:8310 Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV+ VGASnoop- ParErr- Stepping- SERR+ FastB2B- Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- Latency: 168 (2500ns min, 7000ns max), Cache Line Size: 32 bytes Interrupt: pin A routed to IRQ 11 Region 0: Memory at c0210000 (32-bit, non-prefetchable) [size=64K] Capabilities: [44] Power Management version 2 Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-) Status: D0 PME-Enable- DSel=0 DScale=2 PME- dmesg output from new (broken) version: ath_hal: module license 'Proprietary' taints kernel. ath_hal: 0.9.18.0 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413, RF5413) wlan: 0.8.4.2 (0.9.3) ath_pci: 0.9.4.5 (0.9.3) dmesg output from old (working) version: ath_hal: 0.9.17.2 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413, RF5413) wlan: 0.8.4.2 (0.9.2.1) ath_rate_sample: 1.2 (0.9.2.1) ath_pci: 0.9.4.5 (0.9.2.1) ACPI: PCI Interrupt 0000:02:02.0[A] -> Link [LNKC] -> GSI 11 (level, low) -> IRQ 11 wifi0: 11a rates: 6Mbps 9Mbps 12Mbps 18Mbps 24Mbps 36Mbps 48Mbps 54Mbps wifi0: 11b rates: 1Mbps 2Mbps 5.5Mbps 11Mbps wifi0: H/W encryption support: WEP AES wifi0: mac 4.2 phy 3.0 5ghz radio 1.7 2ghz radio 2.3 wifi0: Use hw queue 0 for WME_AC_BE traffic wifi0: Use hw queue 0 for WME_AC_BK traffic wifi0: Use hw queue 0 for WME_AC_VI traffic wifi0: Use hw queue 0 for WME_AC_VO traffic wifi0: Use hw queue 8 for CAB traffic wifi0: Use hw queue 9 for beacons couldn't load module 'wlan_scan_sta' (-38) unable to load wlan_scan_sta wifi0: Atheros 5211: mem=0xc0210000, irq=11
emerge --info ?
eta ~ # emerge --info Portage 2.1.2.3 (default-linux/x86/2006.1, gcc-4.1.2, glibc-2.5-r1, 2.6.19-gentoo-r2 i686) ================================================================= System uname: 2.6.19-gentoo-r2 i686 Intel(R) Pentium(R) M processor 1600MHz Gentoo Base System release 1.12.10 Timestamp of tree: Tue, 10 Apr 2007 18:20:01 +0000 dev-java/java-config: 1.3.7, 2.0.31-r5 dev-lang/python: 2.4.4 dev-python/pycrypto: 2.0.1-r5 sys-apps/sandbox: 1.2.18.1 sys-devel/autoconf: 2.13, 2.61 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10 sys-devel/binutils: 2.17 sys-devel/gcc-config: 1.3.15-r1 sys-devel/libtool: 1.5.23b virtual/os-headers: 2.6.20-r2 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-march=pentium-m -fomit-frame-pointer -O3 -pipe -mfpmath=sse" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/share/X11/xkb" CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c" CXXFLAGS="-march=pentium-m -fomit-frame-pointer -O3 -pipe -mfpmath=sse" DISTDIR="/usr/portage/distfiles" FEATURES="distlocks metadata-transfer sandbox sfperms strict" GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo" LINGUAS="en_US" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage" USE="X aac aiglx alsa apache2 bash-completion berkdb bitmap-fonts bzip2 cairo cli cracklib crypt cups dbus dga doc dri dvi fontconfig gdbm glitz gtk iconv isdnlog ithreads jpeg libg++ madwifi midi mmx mmxext ncurses no-old-linux nptl nptlonly openal opengl pam pcre pdf perl png ppds pppd readline reflection samba sdl session spell spl sse sse2 ssl svg tcpd tetex threads tiff timidity truetype truetype-fonts type1-fonts vim-syntax vorbis win32codecs x86 xorg zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_US" USERLAND="GNU" VIDEO_CARDS="radeon" Unset: CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS My PORTDIR_OVERLAY only contains stuff related to X11.
Not a dev but I'd like to help get to the bottom of this. How are the drivers being inserted, by udev, modules.autoload.d scripts or manually? What are the contents of your /etc/modules.d/ath_pci? Does a rate control module get inserted? (I do not see one your dmesg output for 0.9.3) Could you try compiling with only -O2 and without -mfpmath=sse in your CFLAGS and CXXFLAGS?
(In reply to comment #3) > Not a dev but I'd like to help get to the bottom of this. > > How are the drivers being inserted, by udev, modules.autoload.d scripts or > manually? > What are the contents of your /etc/modules.d/ath_pci? > Does a rate control module get inserted? (I do not see one your dmesg output > for 0.9.3) > Could you try compiling with only -O2 and without -mfpmath=sse in your CFLAGS > and CXXFLAGS? > The modules are loaded via modules.autoload.d. I think the version that works loads ath_rate_sample when the device loads. Manually loading any of the rate modules does not fix the problem. Also compiling only with -O2 does not fix the problem.
I have tried to recreate this problem multiple times on a few machines but I haven't been successful. But I also don't have an AR5211 to work with, only AR5212s. Typically you shouldn't have to have modules.autoload.d/kernel-2.6 entries to load the modules. udev should pick them up and load them automatically. Options are set in /etc/modules.d/ath_pci. I believe this to most likely be an upstream regression or, perhaps, though much less likely (because udev is not detecting or loading the modules) a configuration problem. I am sorry I don't think I can be of much further help at this time. =/
Would you attach your kernel config? Preferably by using: zcat /proc/config.gz
Created attachment 120380 [details] Kernel configuration My kernel configuration obtained using zcat /proc/config.gz
You said that you think the bug may be related to upstream. Should I submit the bug there and resolve the bug as UPSTREAM?
I don't know what roll this machine plays in your operations but if you can/if it is available, could you try the following: 1. Recompile/install a new kernel with CONFIG_KMOD=y 2. Comment out any ath* or wlan* modules in your /etc/modules.autoload.d/* scripts 3. If you have an old /etc/udev/rules.d/65-madwifi.rules remove it 4. Remerge latest madwifi-ng & madwifi-ng-tools against your new kernel 5. Remerge wpa_supplicant or hostapd if you use them (they need to pull in headers from new madwifi-ng) 6. Your /etc/modules.d/ath_pci should only have comments. If you are making this machine an access point itself (such as with hostapd), /etc/modules.d/ath_pci should have a single uncommented line (in addition to the comments): options ath_pci autocreate=ap 7. Run "update-modules -f" 8. Reboot Sorry for all the work but I am hoping it works.
Sorry I missed something. In addition to setting CONFIG_KMOD=y, you should also set CONFIG_CRYPTO_HMAC=y when you compile your new kernel. All other directions remain the same.
That fixed it. Thanks for all your help. I am resolving the bug as INVALID.
(In reply to comment #11) > That fixed it. Thanks for all your help. I am resolving the bug as INVALID. > Please reopen the bug, this needs to be discussed/worked on. For future reference I believe common bugzilla etiquette to be that CLOSING of the bug ticket is left to the bug assignee.
Steev, According to upstream: "Automatic module loading support (CONFIG_KMOD) is recommended; otherwise, care will have to be taken to manually load needed modules." http://www.madwifi.org/changeset/2168 It seems there are a number of people don't have CONFIG_KMOD enabled and have issues upgrading to >=madwifi-ng-0.9.3 because of it. I found this to be the same issue in this persons case: http://forums.gentoo.org/viewtopic.php?p=4074849#4074849 I suspect these guys are also experiencing the same: http://forums.gentoo.org/viewtopic-t-561546-highlight-madwifi.html http://forums.gentoo.org/viewtopic-t-534096-highlight-madwifi.html http://forums.gentoo.org/viewtopic-t-553455-highlight-madwifi.html They typically resort to trying to load the modules at startup via /etc/modules.autoload.d/*, some with success. The ones who are unsuccessful tend to downgrade to one of the security-issue ridden -0.9.2* releases. There might even be an issue in madwifi-ng with the order in which modules must be loaded when loaded manually. UDEV appears to do a good job of loading the correct modules in order, creates the interfaces on its own and needs no help so long as CONFIG_KMOD is enabled. However, CONFIG_KMOD is supposedly not an absolute _requirement_ for madwifi-ng to work. I think we should either: 1. Not require CONFIG_KMOD but inform the user. -It is recommended that they enable CONFIG_KMOD and let udev handle all the module loading automatically. -This will make /etc/modules.autoload.d/* entries unnecessary. -madwifi-ng driver configuration options are available in /etc/modules.d/ath_pci 2. Check for and require CONFIG_KMOD to be enabled. Then inform them: -No entrys in /etc/modules.autoload.d/* are necessary, please remove them. Note: There is already a warning about old 65-madwifi.rules in place. -All configuration options with respect to madwifi-ng drivers should be set in /etc/modules.d/ath_pci UDEV+CONFIG_KMOD is the most correct, cleanest and from the DEV perspective, supportable way to do it. But CONFIG_KMOD supposedly isn't strictly required and I don't know if we want to fail the build for someone who doesn't have CONFIG_KMOD enabled and is currently using /etc/modules.autoload.d/* -- even if it is unnecessary and was never officially recommended. Thoughts?
Sorry, I'm kind of new to bugzilla. Either way would be more helpful than it is now. I would think that warning the user would be better than explicitly forbidding use without CONFIG_KMOD, for cases where CONFIG_KMOD is explicitly not wanted.
Not ignoring this bug, though it may seem that way from my lack of comments, I will have more later, but I am at work currently, and when I get home I need to sleep, and then I will respond/fix up the ebuilds.
Added the check and it errors if CONFIG_KMOD is not set. Could you please test this David? Thanks for the report, and thanks again Gordon for your work. Sorry it took so long.
Sorry, but I can't help any more. I've since moved on to another Linux distribution (for reasons unrelated to this bug) and don't run Gentoo any more. Thanks for your help in solving the problem.
(In reply to comment #16) > Added the check and it errors if CONFIG_KMOD is not set. Could you please test > this David? Thanks for the report, and thanks again Gordon for your work. > Sorry it took so long. > It doesn't work. I believe the issue is that you are checking for CONFIG_CONFIG_KMOD, there is an extra CONFIG. I will paste the output from my attempt at emerging it: * Messages for package net-wireless/madwifi-ng-0.9.3.3: * CONFIG_CONFIG_KMOD: is not set when it should be. * Please check to make sure these options are set correctly. * Failure to do so may cause unexpected problems. * Once you have satisfied these options, please try merging * this package again. * * ERROR: net-wireless/madwifi-ng-0.9.3.3 failed. * Call stack: * ebuild.sh, line 1717: Called dyn_setup * ebuild.sh, line 768: Called qa_call 'pkg_setup' * ebuild.sh, line 44: Called pkg_setup * madwifi-ng-0.9.3.3.ebuild, line 34: Called linux-mod_pkg_setup * linux-mod.eclass, line 465: Called linux-info_pkg_setup * linux-info.eclass, line 576: Called check_extra_config * linux-info.eclass, line 475: Called die * The specific snippet of code: * die "Incorrect kernel configuration options" * The die message: * Incorrect kernel configuration options * * If you need support, post the topmost build error, and the call stack if relevant. * A complete build log is located at '/var/tmp/portage/net-wireless/madwifi-ng-0.9.3.3/temp/build.log'. * Looking at the other items in the CONFIG_CONFIG field of the .ebuild file it seems like the script adds the CONFIG_ prefix for you. I bet that changing the list to be just: CONFIG_CHECK="CRYPTO WIRELESS_EXT SYSCTL KMOD" would work