1 |
On May 6, 2011, at 4:14 PM, Mick wrote: |
2 |
|
3 |
> On Friday 06 May 2011 18:04:31 John Nielsen wrote: |
4 |
>> Doesn't look like this went through the first time; re-sending without |
5 |
>> attachment. |
6 |
>> |
7 |
>> On May 5, 2011, at 6:52 PM, Paul Hartman wrote: |
8 |
>>> On Thu, May 5, 2011 at 12:40 PM, John Nielsen <lists@××××××××.net> wrote: |
9 |
>>>> I am trying to set up a 5GHz wireless access point on an Alix 3d2 board |
10 |
>>>> with an AR9220 (ath9k "Merlin") PCI card. I have done so successfully |
11 |
>>>> using Fedora 14 on identical hardware but I would greatly prefer to use |
12 |
>>>> Gentoo so I can use a more recent kernel and customize things |
13 |
>>>> appropriately for the platform. |
14 |
>>> |
15 |
>>> It seems like everything is pretty much the same, other than the |
16 |
>>> kernel (and presumably the ath9k driver). But I would look at the udev |
17 |
>>> rules for CRDA to be sure they match and are being applied the same on |
18 |
>>> both systems. You shouldn't ever need to "iw reg set" on a system with |
19 |
>>> CRDA, it should do it for you. So I wonder if you're setting it, and |
20 |
>>> then CRDA is immediately setting it back to 00... |
21 |
>> |
22 |
>> The udev rule for CRDA is the same on both systems, and matches what is |
23 |
>> shown on http://wireless.kernel.org/en/developers/Regulatory/CRDA. The |
24 |
>> Fedora box also has a magic rule to call /sbin/setregdomain when an 80211 |
25 |
>> interface is added, which is a shell script that infers the regdomain from |
26 |
>> the currently set timezone. The punch line of the script is simply a call |
27 |
>> to "iw reg set $COUNTRY" |
28 |
>> |
29 |
>> However, I'm not sure crda is being called appropriately on the Gentoo box. |
30 |
> On the Fedora machine I see this in dmesg: |
31 |
>>>> [ 17.248674] cfg80211: Calling CRDA for country: US |
32 |
>>>> [ 18.848206] cfg80211: Regulatory domain changed to country: US |
33 |
>> |
34 |
>> and I don't ever see anything similar on the Gentoo machine, even when |
35 |
>> running "iw reg set" by hand. Further, I don't see anything in the output |
36 |
>> of "udevadm monitor --environment kernel". |
37 |
>> |
38 |
>> I just dropped the kernel from the Fedora machine on to the Gentoo box and |
39 |
>> (somewhat surprisingly) it works just fine. The reg domain gets set no |
40 |
>> problem, hostapd starts, life is good--except that now I feel like I've |
41 |
>> sinned against nature and I'd like to get my own, smaller kernel back. |
42 |
>> |
43 |
>> While it's possible the new kernel version is broken I rather suspect that |
44 |
>> I have configured it badly. I set out to configure a minimal kernel with |
45 |
>> just the features and drivers I want on this hardware and no need for |
46 |
>> modules or an initramfs. Does cfg80211 need to be a module to work |
47 |
>> properly? I wouldn't think so. |
48 |
>> |
49 |
>> I'll do some more experimenting but in the mean time here's my kernel |
50 |
>> config in case anyone has ideas on what could be wrong. Thanks! |
51 |
>> |
52 |
>> Config file here: http://pastebin.com/S68ye6Pz |
53 |
> |
54 |
> I suggest that you run a diff --suppress-common-lines -y between the Fedora |
55 |
> and your own kernel to find out what's different between the two as far as |
56 |
> your driver is concerned. |
57 |
|
58 |
The outright diff was far too verbose to be useful, but looking at "lsmod" output when running the Fedora kernel was instructive. I recognized everything as being in by Gentoo kernel except for "rfkill", which was listed as a dependency of cfg80211. Long story short, I got it working like I want by: |
59 |
|
60 |
1) Including RFKILL in my kernel config and |
61 |
2) Building cfg80211, mac80211, rfkill, and all parts of the ath9k driver as modules |
62 |
|
63 |
Just adding RFKILL to a static (module-less) kernel didn't fix it, and just building cfg80211 and friends as modules without RFKILL also didn't fix it; I had to do both. |
64 |
|
65 |
Thanks all for your responses so far. I'll be happy to ditch Fedora. :) |
66 |
|
67 |
For future reference, does anyone know why either of the above would be required? If I see the same behavior in the latest git kernel should I file a bug? If so, where (since I doubt this is a Gentoo issue)? |
68 |
|
69 |
JN |