# problem with dhcpcd and ath5k...

## adramalech707

okay so i just update some config files and everything seemed to work on the next reboot and a couple more....but i actually did start to find issues with wireless networking once i changed to testing ~amd64...

before i would turn on the laptop and /etc/init.d/net.wlan0 started up and searched and accessed the ap of what ever wireless routers info i had written in /etc/wpa_supplicant/wpa_supplicant.conf....

now i have to dhcpcd every time i boot up because i guess the way my wireless adapter worked before didn't setup correctly....

i am using dhcpcd 5.1.5, wpa_supplicant 0.7.1, ath5k module(which the wireless adapter says it is using from the kernel as my driver which it should), and kernel 2.6.32-gentoo-r6

now what i get from /etc/init.d/net.wlan0 start is this : 

```

> sudo /etc/init.d/net.wlan0 start

   * bring up interface wlan0

   *    starting wpa_supplicant on wlan0...

Unsupported driver 'ath5k'.

  *     start-stop-dameon: failed to start '/usr/sbin/wpa_supplicant'

  *  ERROR: net.wlan0 failed to start

>
```

now i am wondering if this is a bug in the configuration file of where the directory of modules are that wlan0 uses to get internet access...i did have to update the dhcpcd.conf file with dispatch-conf which led me to my next discovery dhcpcd doesn't work...

if i do pass -L flag it will just say it timed out and couldn't find a carrier...

if i don't pass -L it says it is switching to IPv4LL and then it says:

```

> sudo dhcpcd wlan0

dhcpcd: version 5.1.5 starting

dhcpcd: wlan0: waiting for carrier

dhcpcd: timed out

dhcpcd: allowing 8 seconds for IPv4LL timeout

dhcpcd: timed out

> 

```

when i go to do ifconfig and iwconfig wlan0 and iwlist wlan0 scanning it shows that ath5k is working because it shows me routers when i scan and lspci -v shows that the kernel driver is infact being used...

any suggestions would be greatly appreciated i have worked countless hours on trying to figure out how this happened...

----------

## USTruck

Hello,

Can you post a result of : lspci 

Thanks

I have two station under 2.6.32 with ath5k without problem.

EDIT : post lsusb too if necessary

----------

## adramalech707

okay here you go i did lspci then lsusb and then lspci -v to show the wifi card...

```

//lspci

00:00.0 Host bridge: Advanced Micro Devices [AMD] RS780 Host Bridge

00:01.0 PCI bridge: Hewlett-Packard Company Device 9602

00:04.0 PCI bridge: Advanced Micro Devices [AMD] RS780 PCI to PCI bridge (PCIE port 0)

00:05.0 PCI bridge: Advanced Micro Devices [AMD] RS780 PCI to PCI bridge (PCIE port 1)

00:06.0 PCI bridge: Advanced Micro Devices [AMD] RS780 PCI to PCI bridge (PCIE port 2)

00:07.0 PCI bridge: Advanced Micro Devices [AMD] RS780 PCI to PCI bridge (PCIE port 3)

00:11.0 SATA controller: ATI Technologies Inc SB700/SB800 SATA Controller [AHCI mode]

00:12.0 USB Controller: ATI Technologies Inc SB700/SB800 USB OHCI0 Controller

00:12.1 USB Controller: ATI Technologies Inc SB700 USB OHCI1 Controller

00:12.2 USB Controller: ATI Technologies Inc SB700/SB800 USB EHCI Controller

00:13.0 USB Controller: ATI Technologies Inc SB700/SB800 USB OHCI0 Controller

00:13.1 USB Controller: ATI Technologies Inc SB700 USB OHCI1 Controller

00:13.2 USB Controller: ATI Technologies Inc SB700/SB800 USB EHCI Controller

00:14.0 SMBus: ATI Technologies Inc SBx00 SMBus Controller (rev 3a)

00:14.1 IDE interface: ATI Technologies Inc SB700/SB800 IDE Controller

00:14.2 Audio device: ATI Technologies Inc SBx00 Azalia (Intel HDA)

00:14.3 ISA bridge: ATI Technologies Inc SB700/SB800 LPC host controller

00:14.4 PCI bridge: ATI Technologies Inc SBx00 PCI to PCI Bridge

00:18.0 Host bridge: Advanced Micro Devices [AMD] Mobile K10 [Turion X2, Athlon X2, Sempron] HyperTransport Configuration (rev 40)

00:18.1 Host bridge: Advanced Micro Devices [AMD] Family 11h [Turion X2, Athlon X2, Sempron] Address Map

00:18.2 Host bridge: Advanced Micro Devices [AMD] Mobile K10 [Turion X2, Athlon X2, Sempron] DRAM Controller

00:18.3 Host bridge: Advanced Micro Devices [AMD] Mobile K10 [Turion X2, Athlon X2, Sempron] Miscellaneous Control

00:18.4 Host bridge: Advanced Micro Devices [AMD] Mobile K10 [Turion X2, Athlon X2, Sempron] Link Control

01:05.0 VGA compatible controller: ATI Technologies Inc RS780M/RS780MN [Radeon HD 3200 Graphics]

01:05.1 Audio device: ATI Technologies Inc RS780 Azalia controller

08:00.0 System peripheral: JMicron Technology Corp. SD/MMC Host Controller

08:00.2 SD Host controller: JMicron Technology Corp. Standard SD Host Controller

08:00.3 System peripheral: JMicron Technology Corp. MS Host Controller

08:00.4 System peripheral: JMicron Technology Corp. xD Host Controller

09:00.0 Ethernet controller: Atheros Communications Inc. AR5001 Wireless Network Adapter (rev 01)

0a:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8101E/RTL8102E PCI Express Fast Ethernet controller (rev 02)

//lsusb

Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Bus 001 Device 002: ID 046d:09b8 Logitech, Inc. 

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

//lspci -v 

09:00.0 Ethernet controller: Atheros Communications Inc. AR5001 Wireless Network Adapter (rev 01)

   Subsystem: Hewlett-Packard Company Device 137a

   Flags: bus master, fast devsel, latency 0, IRQ 18

   Memory at d1100000 (64-bit, non-prefetchable) [size=64K]

   Capabilities: [40] Power Management version 2

   Capabilities: [50] MSI: Enable- Count=1/1 Maskable- 64bit-

   Capabilities: [60] Express Legacy Endpoint, MSI 00

   Capabilities: [90] MSI-X: Enable- Count=1 Masked-

   Capabilities: [100] Advanced Error Reporting

   Capabilities: [140] Virtual Channel <?>

   Kernel driver in use: ath5k

   Kernel modules: ath5k

```

----------

## Rexilion

It seems like wpa_supplicant is started with incorrect parameters, for example if I do this:

Alpha ~ # wpa_supplicant -c /etc/wpa_supplicant/wpa_supplicant.conf -ieth0 -Dath5k       

Unsupported driver 'ath5k'.

The error is the exact same I see in your logs. The correct values are: (for the ath5k driver supported cards, more exist of course   :Razz:  ) 

- wext or

- nl80211

The problem is that wpa_supplicant needs a 'driver' to controll the wireless card driver (ath5k) (makes sense ey   :Confused:  ). In the old days, that generic 'driver' was wext (remember wireless extensions  :Question:  ), right now those are being phased out in favour of nl80211 (all new   :Very Happy:  ). I don't know how the configuration mechanism you use works (etc/conf.d/wireless). But, you used the value ath5k somewhere where you should have used wext or nl80211.

These 'drivers' only provide a generic interface to control your wireless card.

Btw, if you are not sure which one works best, you could also try to use wext,nl80211 as a driver. wpa_supplicant will then try wext first and then nl80211. Or you could go more bleeding edge (if possible, otherwise it will just fallback to wext) and do nl80211,wext (nl80211 is newer, but I don't know if it works good with ath5k).

If you don't know, please post the contents of /etc/conf.d/wireless   :Smile: 

----------

