Gentoo Archives: gentoo-user

From: "Norman Rieß" <norman@×××××××××.org>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Atheros kernel driver and my wireless access point setup
Date: Thu, 11 Jun 2009 01:34:29
Message-Id: 4A305F1F.2090006@smash-net.org
In Reply to: Re: [gentoo-user] Atheros kernel driver and my wireless access point setup by Jason Carson
1 Jason Carson schrieb:
2 >> Jason Carson schrieb:
3 >>
4 >>> Alright, I have done everything you have suggested but when hostapd
5 >>> tries
6 >>> to start I am getting this error...
7 >>>
8 >>> penguin ~ # /etc/init.d/hostapd start
9 >>> * Starting hostapd...
10 >>> Configuration file: /etc/hostapd/hostapd.conf
11 >>> Failed to set interface wlan0 to master mode.
12 >>> nl80211 driver initialization failed.
13 >>> ELOOP: remaining socket: sock=5 eloop_data=0x80f1a38 user_data=(nil)
14 >>> handler=0x8091790
15 >>> * start-stop-daemon: failed to start `/usr/sbin/hostapd'
16 >>> [ !! ]
17 >>> * ERROR: hostapd failed to start
18 >>>
19 >>> Do you have any idea why this is happening?
20 >>>
21 >>>
22 >>>
23 >>>
24 >> Not quite...
25 >> What kernelsettings do you activate for you wlan?
26 >>
27 >>
28 >>
29 > I used the kernel settings mentioned here...
30 > http://linuxwireless.org/en/users/Drivers/ath5k#Enabling_ath5k
31 > ...but I built everything directly into the kernel, NOT as modules.
32 >
33 > I have attached my .config to this email so you can see if I am missing
34 > anything.
35 I also activated
36
37 CONFIG_HOSTAP=y
38 CONFIG_HOSTAP_FIRMWARE=y
39 CONFIG_HOSTAP_FIRMWARE_NVRAM=y
40
41 but i think i found the real reason.
42 I checked the 2.6.29.x ath5k base.c and found, that the AP code is still
43 dormant.
44 You need to apply this patch:
45
46 --- linux-2.6.29/drivers/net/wireless/ath5k/base.c 2009-02-10
47 06:11:43.186470883 +0100
48 +++ linux-2.6.29/drivers/net/wireless/ath5k/base.c.old
49 2008-11-14 09:36:40.000000000 +0100
50 @@ -522,6 +501,7 @@
51 hw->wiphy->interface_modes =
52 BIT(NL80211_IFTYPE_STATION) |
53 BIT(NL80211_IFTYPE_ADHOC) |
54 + BIT(NL80211_IFTYPE_AP) |
55 BIT(NL80211_IFTYPE_MESH_POINT);
56
57 hw->extra_tx_headroom = 2;
58
59 Open the file
60 /usr/src/linux-<yourversion>/drivers/net/wireless/ath5k/base.c, search for
61
62 hw->wiphy->interface_modes
63
64 and the apply the line
65
66 BIT(NL80211_IFTYPE_AP) |
67
68 between these lines.
69 Rebuild and install the kernel.
70
71 Background: The AP code is there, but it is not activated yet. This line
72 activates it.
73 I thought newer 2.6.29er kernels do not have this restriction, so i did
74 not think of this, but apparently they do.

Replies

Subject Author
Re: [gentoo-user] Atheros kernel driver and my wireless access point setup Jason Carson <jason@×××××××××××.ca>