# Trouble getting atheros wifi card to work

## turner2501

Hi,

  I'm warning readers that the first part of this thread will be on topic but later parts (as it deals with getting wifi to work) will be less and less on topic... we'll manage that as it goes.

  I've got an Asus EeePC 701 with the Atheros AR5006EG if I'm not mistaken...  I've been trying to get the wifi working with my router set with no security at all, but I get stuck at the early point where I get the actual interface (i read it would be ath0).

  I've been following leads here and there (geeentoo.org, madwifi-ng)... they all looked promising but none really got it working.  Probably because I'm doing something else wrong.

  Below, I've attached a few general questions that should clarify some of my confusion.  Also, after that, I've included the output of a script i made (in php) to include all relevant information and tests.  If anything's missing, just ask!  Major problem is that I do not have the internet at home now, can only use another computer at an internet cafe or I can plug my eeepc at a friends house (but due to human sheduling issues, that's a difficult possibility).  If you have ideas to go around these too, that'd be nice!

--------------------------

Q1) What determines if an interface can exist or not?  Is it just a question of having the proper device driver compiled in the kernel or as a module or is there more to it?

Q2) Once all the modules/support is installed, what makes the interface appear in ifconfig?  Is it just the /etc/init.d/net.XXX script or a combination of that script with a few lines in /etc/conf.d/net?  Or is there more to it?  If I remember right, ifconfig -a should display all supported interface...

Q3) Is it possible to get the ath0 interface (or whichever) come up in ifconfig without a valid connection? (ie, to get this step working before I adventure further in the network config: ESSID, dhcp, etc...)

Q4) Does it makes a difference what kernel type (vanilla vs gentoo) or kernel version (2.4,2.6,etc) I use when using kernel patches or third-party ebuilds (like madwifi in this case)?

Q5) When using patches or custom ebuilds (for k.modules), I believe I need to reapply the patch after a new kernel download or make distclean.  Is it the same for an ebuild?  Should I digest the ebuild again and then emerge it?

Q6) In make menuconfig, do I need anything for a wireless driver to work (madwifi for ex.) or is it going to supply all it needs?  I've seen it does require stuff like CRYPTO and WIRELESS, so I did put those as built-in, is this enough?

Q7) Can someone provide an example /etc/conf.d/net with wireless for a basic setup (like my router only supports WEP, WPA and WPAPSK).

--------------------------

(posting from windows... sorry)

====[CMD: echo "----- EeePC Wifi issue marker -----" >> /var/log/messages ]=====

===========================================================[CMD: uname -a ]=====

Linux satelite 2.6.23-gentoo-r9 #2 SMP Mon Mar 31 13:30:40 EDT 2008 i686 Intel(R) Celeron(R) M processor 900MHz GenuineIntel GNU/Linux

===================================================[CMD: lspci | grep Eth ]=====

01:00.0 Ethernet controller: Atheros Communications, Inc. AR5006EG 802.11 b/g Wireless PCI Express Adapter (rev 01)

03:00.0 Ethernet controller: Attansic Technology Corp. L2 100 Mbit Ethernet Adapter (rev a0)

================================================[CMD: lsmod | grep -v snd ]=====

Module                  Size  Used by

atl2                   26904  0 

ath_pci                77216  0 

wlan                  150128  1 ath_pci

ath_hal               191696  1 ath_pci

=========================================[CMD: /etc/init.d/net.ath0 start ]=====

 [32;01m*[0m Starting ath0

 [32;01m*[0m   Starting to bring up interface ath0

 [32;01m*[0m   Bringing up ath0

 [32;01m*[0m     dhcp

 [31;01m*[0m       network interface ath0 does not exist

 [31;01m*[0m       Please verify hardware or kernel module (driver)

[A[122C  [34;01m[ [31;01m!![34;01m ][0m

========================================[CMD: /etc/init.d/net.ath0 status ]=====

 [31;01m*[0m status:  stopped

=========================================[CMD: /etc/init.d/net.ath1 start ]=====

 [32;01m*[0m Starting ath1

 [32;01m*[0m   Starting to bring up interface ath1

 [32;01m*[0m   Bringing up ath1

 [32;01m*[0m     dhcp

 [31;01m*[0m       network interface ath1 does not exist

 [31;01m*[0m       Please verify hardware or kernel module (driver)

[A[122C  [34;01m[ [31;01m!![34;01m ][0m

========================================[CMD: /etc/init.d/net.ath1 status ]=====

 [31;01m*[0m status:  stopped

========================================[CMD: /etc/init.d/net.wlan0 start ]=====

 [32;01m*[0m Starting wlan0

 [32;01m*[0m   Starting to bring up interface wlan0

 [33;01m*[0m   Configuration not set for wlan0 - assuming DHCP

 [32;01m*[0m   Bringing up wlan0

 [32;01m*[0m     dhcp

 [31;01m*[0m       network interface wlan0 does not exist

 [31;01m*[0m       Please verify hardware or kernel module (driver)

[A[122C  [34;01m[ [31;01m!![34;01m ][0m

=======================================[CMD: /etc/init.d/net.wlan0 status ]=====

 [31;01m*[0m status:  stopped

========================================[CMD: /etc/init.d/net.wlan1 start ]=====

 [32;01m*[0m Starting wlan1

 [32;01m*[0m   Starting to bring up interface wlan1

 [33;01m*[0m   Configuration not set for wlan1 - assuming DHCP

 [32;01m*[0m   Bringing up wlan1

 [32;01m*[0m     dhcp

 [31;01m*[0m       network interface wlan1 does not exist

 [31;01m*[0m       Please verify hardware or kernel module (driver)

[A[122C  [34;01m[ [31;01m!![34;01m ][0m

=======================================[CMD: /etc/init.d/net.wlan1 status ]=====

 [31;01m*[0m status:  stopped

========================================[CMD: /etc/init.d/net.wifi0 start ]=====

 [32;01m*[0m Starting wifi0

 [32;01m*[0m   Starting to bring up interface wifi0

 [33;01m*[0m   Configuration not set for wifi0 - assuming DHCP

 [32;01m*[0m   Bringing up wifi0

 [32;01m*[0m     dhcp

 [31;01m*[0m       network interface wifi0 does not exist

 [31;01m*[0m       Please verify hardware or kernel module (driver)

[A[122C  [34;01m[ [31;01m!![34;01m ][0m

=======================================[CMD: /etc/init.d/net.wifi0 status ]=====

 [31;01m*[0m status:  stopped

========================================[CMD: /etc/init.d/net.wifi1 start ]=====

 [32;01m*[0m Starting wifi1

 [32;01m*[0m   Starting to bring up interface wifi1

 [33;01m*[0m   Configuration not set for wifi1 - assuming DHCP

 [32;01m*[0m   Bringing up wifi1

 [32;01m*[0m     dhcp

 [31;01m*[0m       network interface wifi1 does not exist

 [31;01m*[0m       Please verify hardware or kernel module (driver)

[A[122C  [34;01m[ [31;01m!![34;01m ][0m

=======================================[CMD: /etc/init.d/net.wifi1 status ]=====

 [31;01m*[0m status:  stopped

=====[CMD: tail -n 50 /var/log/messages | grep -e "rc-scripts" -e "EeePC" ]=====

Apr  1 15:14:22 satelite rc-scripts: network interface ath0 does not exist

Apr  1 15:14:22 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:22 satelite rc-scripts: status:  stopped

Apr  1 15:14:24 satelite rc-scripts: network interface ath1 does not exist

Apr  1 15:14:24 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:24 satelite rc-scripts: status:  stopped

Apr  1 15:14:26 satelite rc-scripts: Configuration not set for wlan0 - assuming DHCP

Apr  1 15:14:26 satelite rc-scripts: network interface wlan0 does not exist

Apr  1 15:14:26 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:26 satelite rc-scripts: status:  stopped

Apr  1 15:14:27 satelite rc-scripts: Configuration not set for wlan1 - assuming DHCP

Apr  1 15:14:27 satelite rc-scripts: network interface wlan1 does not exist

Apr  1 15:14:27 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:28 satelite rc-scripts: status:  stopped

Apr  1 15:14:29 satelite rc-scripts: Configuration not set for wifi0 - assuming DHCP

Apr  1 15:14:29 satelite rc-scripts: network interface wifi0 does not exist

Apr  1 15:14:29 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:29 satelite rc-scripts: status:  stopped

Apr  1 15:14:31 satelite rc-scripts: Configuration not set for wifi1 - assuming DHCP

Apr  1 15:14:31 satelite rc-scripts: network interface wifi1 does not exist

Apr  1 15:14:31 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:31 satelite rc-scripts: status:  stopped

----- EeePC Wifi issue marker -----

Apr  1 15:14:44 satelite rc-scripts: network interface ath0 does not exist

Apr  1 15:14:44 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:44 satelite rc-scripts: status:  stopped

Apr  1 15:14:46 satelite rc-scripts: network interface ath1 does not exist

Apr  1 15:14:46 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:46 satelite rc-scripts: status:  stopped

Apr  1 15:14:47 satelite rc-scripts: Configuration not set for wlan0 - assuming DHCP

Apr  1 15:14:47 satelite rc-scripts: network interface wlan0 does not exist

Apr  1 15:14:48 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:48 satelite rc-scripts: status:  stopped

Apr  1 15:14:49 satelite rc-scripts: Configuration not set for wlan1 - assuming DHCP

Apr  1 15:14:49 satelite rc-scripts: network interface wlan1 does not exist

Apr  1 15:14:49 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:50 satelite rc-scripts: status:  stopped

Apr  1 15:14:51 satelite rc-scripts: Configuration not set for wifi0 - assuming DHCP

Apr  1 15:14:51 satelite rc-scripts: network interface wifi0 does not exist

Apr  1 15:14:51 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:51 satelite rc-scripts: status:  stopped

Apr  1 15:14:53 satelite rc-scripts: Configuration not set for wifi1 - assuming DHCP

Apr  1 15:14:53 satelite rc-scripts: network interface wifi1 does not exist

Apr  1 15:14:53 satelite rc-scripts: Please verify hardware or kernel module (driver)

Apr  1 15:14:53 satelite rc-scripts: status:  stopped

========================================================[CMD: ifconfig -a ]=====

eth1      Link encap:Ethernet  HWaddr 00:1D:60:89:E5:36  

          inet addr:169.254.92.239  Bcast:169.254.255.255  Mask:255.255.0.0

          UP BROADCAST MULTICAST  MTU:1500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:1

          collisions:0 txqueuelen:1000 

          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

          Memory:fbfc0000-fc000000 

lo        Link encap:Local Loopback  

          inet addr:127.0.0.1  Mask:255.0.0.0

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0 

          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

===========================================================[CMD: iwconfig ]=====

lo        no wireless extensions.

eth1      no wireless extensions.

----------

## paulbiz

Hi,

I don't know about the EeePC 701 specifically but I believe some AR5007 gets mis-reported as being AR5006EG... experimental AR5007 support is in latest madwifi CVS (but 32-bits only). Maybe it's worth checking deeper to make sure which chipset you have.

check these madwifi bugs for the info on AR5006 and AR5007:

http://madwifi.org/ticket/859

http://madwifi.org/ticket/1679

----------

## civilian

I have the same problem. After checking around, it seems that the 701 does indeed have an AR5007. Why would lspci misreport the model? After all lspci works independently from drivers if I'm not mistaken.

----------

## paulbiz

 *civilian wrote:*   

> I have the same problem. After checking around, it seems that the 701 does indeed have an AR5007. Why would lspci misreport the model? After all lspci works independently from drivers if I'm not mistaken.

 

The descriptive data for lspci comes from PCI ID project. The actual database is probably in /usr/share/misc/pci.ids on your system.

I think either of two things:

1) Wrong ID is in the chip

2) PCI ID database has wrong data

It seems the only way to see if your AR5006EG is really a 5007 is to check the chip itself (or the FCC sticker on the bottom of the laptop) to see what you've really physically got.

----------

## civilian

It is odd how easily I would miss a sticker like that.

The official card is AR5BXB63.

According to some google links AR5BXB63=AR5007EG and according to others AR5BXB63=AR5006x.

I'm going to assume that it is 5007 since the current madwifi supports 5006.

----------

## turner2501

Glad to read your replies, i thought I was getting mad with those experimental drivers! =D

I finally got to a friends place and I can plug my eeepc on the ethernet to continue installing.

I used the ebuild from AllanJB that you can find on the wiki page and unmasked all versions, I'm now compiling the one from svn.

I'll be reading the first ticket, since I'm already following the 1679 and I'll post back about this.

----------

## turner2501

Well, not yet victorious...  I've tried to recompile my kernel from scratch using vanilla-sources-2.6.24, which worked fine.  Then proceded to emerge =madwifi-ng-0.9.3.3...  My point is that once this is done, all patches in the 1679 ticket will apply fine and give the support.  

However, I could not emerge madwifi, the build failed

 * Preparing ath_hal module

../scripts/get_arch.mk:44: *** ARCH mismatch: supplied "x86", determined "i386".  Stop.

-------------

This error really left me speechless, anyone can give me some light?  (I've modified my make.conf, recompiled kernel, etc...)

----------

## paulbiz

 *turner2501 wrote:*   

> Well, not yet victorious...  I've tried to recompile my kernel from scratch using vanilla-sources-2.6.24, which worked fine.  Then proceded to emerge =madwifi-ng-0.9.3.3...  My point is that once this is done, all patches in the 1679 ticket will apply fine and give the support.  
> 
> However, I could not emerge madwifi, the build failed
> 
>  * Preparing ath_hal module
> ...

 

That error came from the recent merge of amd64 and x86 kernel and should be fixed in the next public release of madwifi-ng. Check this bug for info and patches: https://bugs.gentoo.org/show_bug.cgi?id=205116

Also, one of the gentoo overlays (i can't remember which, je_fro perhaps) has a madwifi-ng live SVN ebuild which will pull the up-to-the-second sources from the madwifi-ng development server. Those sources should be fixed and contain the latest & greatest.

----------

## turner2501

Thanks paulbiz for clarifying...

it's very sad that I'll have to wait until it starts working again...

But I wonder...  It's going to work in a later version, like 0.9.5 or something similar... not in 0.9.3.3.  All the patches that I found were to be applied on the 0.9.3.3...  I've read somewhere we could expect the support to be in the next madwifi release, but... that's a trout slap at my patience!  :Wink: 

I had tried by svn, the ebuild I had found had an 9999 version which actually pulled everything from svn.  Though, I don't have internet at home and I'd use my eeepc in a cafe with free wireless (the waitresses usually stare strangelly when I ask for an rj45 cable with my coffee)...  and so, since it didn't work one shot, I can't really retry from svn.  But I will!

----------

## paulbiz

Ah, your patience will be tested indeed. Perhaps ndiswrapper + windows drivers will be the path for you to take.  :Smile:  (I'm using ndiswrapper with mine now, until native 64-bit drivers are available in madwifi)

----------

## turner2501

Patience is exhausted a long time ago, I'm now building irritation, and soon my pressure gauge will probably explode.  But all I care is at one point I will find a quick step-by-step way to make wifi work on any eeepc and that's what's important...  (One day the support will even be built-in so I'm not to complain...).

----------

## paulbiz

The ticket on madwifi's bug tracker has some news, it looks like there is a new HAL that supports this chipset, even in x86_64. You can try to apply it yourself, or wait for a new SVN build of madwifi.

http://madwifi.org/ticket/1679

----------

## mimosinnet

There is this article in the Gentoo Wiki in case you have any issue with the Atheros 5xxx card or want to add your knowledge to the wiki.

Cheers!

----------

