You are not logged in.

#1 2012-04-09 05:26:56

Xlator
Member
Registered: 2009-11-14
Posts: 30

3.3.1 ath9k wireless regression (Patch available)

After upgrading the kernel on my ASUS eeePC netbook, I was unable to connect to wireless networks anymore. After much fighting with wpa_supplicant and wicd, I googled it. Seems there's a regression in 3.3.1 that affects ath9k chipsets. Thought that might be good to know for anyone experiencing similar problems. I reverted to 3.2.14 for now. Confirmation

EDIT: Seems it's already been reported

EDIT 2: A patch is available. Download it here.

Patch instructions:

gborzii wrote:

@szebenyib
Here is what I did, although it isn't the fastest and best way to do it:
a) Get the linux source files from abs "cp -r /var/abs/core/linux ." (Note: remember to update your abs dirs).
b) cd into the source files directory and edit the PKGBUILD to add the above patch to the compilation process. Here are the relevant snippets from the edited PKGBUILD

....
        'change-default-console-loglevel.patch'
        'i915-fix-ghost-tv-output.patch'
        'ext4-options.patch'
        'ath9kcommit.diff')
....
        '9d3c56a4b999c8bfbd4018089a62f662'
        '263725f20c0b9eb9c353040792d644e5'
        'bb7fd1aa23016c8057046b84fd4eb528'
        '2b8195e3c7563a84061ccd2374c0c345')
....

  # fix ext4 module to mount ext3/2 correct
  # https://bugs.archlinux.org/task/28653
  patch -Np1 -i "${srcdir}/ext4-options.patch"

  # revert commit to fix ath9k
  patch -Np1 -R -i "${srcdir}/ath9kcommit.diff"
....

c) copy the above patch as ath9kcommit.diff in the source files directory.
d) make the package "makepkg -s".
e) as root remove the ath9k from memory and modules tree "modprobe -r ath9k; rm /lib/modules/3.3.1-1-ARCH/kernel/drivers/net/wireless/ath/ath9k/ath9k.ko.gz".
f) as root copy the module from the locally compiled kernel to the modules tree "cp <source files dir>/pkg/lib/modules/3.3.1-1-ARCH/kernel/drivers/net/wireless/ath/ath9k/ath9k.ko.gz /lib/modules/3.3.1-1-ARCH/kernel/drivers/net/wireless/ath/ath9k/ath9k.ko.gz".
g) as root run depmod and load the module "depmod -a; modprobe ath9k".

Hope this helps.

Last edited by Xlator (2012-04-10 09:52:46)

Offline

#2 2012-04-09 05:31:36

skunktrader
Member
From: Brisbane, Australia
Registered: 2010-02-14
Posts: 1,316

Re: 3.3.1 ath9k wireless regression (Patch available)

https://bugs.archlinux.org/index.php?do … k_id=29340
edit: fixed url

Last edited by skunktrader (2012-04-09 07:05:24)

Offline

#3 2012-04-09 09:48:08

Ambrevar
Trusted User (TU)
Registered: 2011-08-14
Posts: 145
Website

Re: 3.3.1 ath9k wireless regression (Patch available)

I have experienced the same regression with linux 3.3.1 and my Ahteros AR9285. I am unable to run wpa_supplicant properly (time out).
Using an older kernel (LTS or 3.2) works for me.

Offline

#4 2012-04-09 13:38:16

robin67
Member
From: the Netherlands
Registered: 2012-02-18
Posts: 35

Re: 3.3.1 ath9k wireless regression (Patch available)

Maybe it is an old bug revisting

Can someone perhaps try this:

create (or edit) /etc/modprobe.d/ath9k.conf
and add this line
    options ath9k nohwcrypt=1

Reboot and most likely it will be fixed

Offline

#5 2012-04-09 13:56:27

gborzi
Member
From: Sicilia
Registered: 2009-03-18
Posts: 102

Re: 3.3.1 ath9k wireless regression (Patch available)

I had the same problem and solved it by reverting the commit on the ath9k source and recompiling. This is the patch I had to reverse-apply:

--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
@@ -118,13 +118,15 @@ void ath9k_ps_restore(struct ath_softc *sc)
        if (--sc->ps_usecount != 0)
                goto unlock;
 
-       if (sc->ps_idle && (sc->ps_flags & PS_WAIT_FOR_TX_ACK))
+       if (sc->ps_flags & PS_WAIT_FOR_TX_ACK)
+               goto unlock;
+
+       if (sc->ps_idle)
                mode = ATH9K_PM_FULL_SLEEP;
        else if (sc->ps_enabled &&
                 !(sc->ps_flags & (PS_WAIT_FOR_BEACON |
                              PS_WAIT_FOR_CAB |
-                             PS_WAIT_FOR_PSPOLL_DATA |
-                             PS_WAIT_FOR_TX_ACK)))
+                             PS_WAIT_FOR_PSPOLL_DATA)))
                mode = ATH9K_PM_NETWORK_SLEEP;
        else
                goto unlock;

After changing the stock module with the recompiled one it started to work fine.


Giuseppe Borzi' - Registered Linux user #34028

Offline

#6 2012-04-09 14:50:27

szebenyib
Member
From: LHBP
Registered: 2011-10-18
Posts: 62

Re: 3.3.1 ath9k wireless regression (Patch available)

Hi
can you advise me with a step by step guide on that Sir?
I would be grateful smile

Offline

#7 2012-04-09 14:53:42

kamirao
Member
Registered: 2012-03-20
Posts: 16
Website

Re: 3.3.1 ath9k wireless regression (Patch available)

I had the same issue after kernel upgrade. switching to linux-lts is working fine for me.

Offline

#8 2012-04-09 15:01:43

kamirao
Member
Registered: 2012-03-20
Posts: 16
Website

Re: 3.3.1 ath9k wireless regression (Patch available)

robin67 wrote:

Maybe it is an old bug revisting

Can someone perhaps try this:

create (or edit) /etc/modprobe.d/ath9k.conf
and add this line
    options ath9k nohwcrypt=1

Reboot and most likely it will be fixed

this solution didn't work for me.

Offline

#9 2012-04-09 15:13:50

lifestyle
Member
Registered: 2011-10-12
Posts: 2

Re: 3.3.1 ath9k wireless regression (Patch available)

same problem

Offline

#10 2012-04-09 15:59:10

gborzi
Member
From: Sicilia
Registered: 2009-03-18
Posts: 102

Re: 3.3.1 ath9k wireless regression (Patch available)

@szebenyib
Here is what I did, although it isn't the fastest and best way to do it:
a) Get the linux source files from abs "cp -r /var/abs/core/linux ." (Note: remember to update your abs dirs).
b) cd into the source files directory and edit the PKGBUILD to add the above patch to the compilation process. Here are the relevant snippets from the edited PKGBUILD

....
        'change-default-console-loglevel.patch'
        'i915-fix-ghost-tv-output.patch'
        'ext4-options.patch'
        'ath9kcommit.diff')
....
        '9d3c56a4b999c8bfbd4018089a62f662'
        '263725f20c0b9eb9c353040792d644e5'
        'bb7fd1aa23016c8057046b84fd4eb528'
        '2b8195e3c7563a84061ccd2374c0c345')
....

  # fix ext4 module to mount ext3/2 correct
  # https://bugs.archlinux.org/task/28653
  patch -Np1 -i "${srcdir}/ext4-options.patch"

  # revert commit to fix ath9k
  patch -Np1 -R -i "${srcdir}/ath9kcommit.diff"
....

c) copy the above patch as ath9kcommit.diff in the source files directory.
d) make the package "makepkg -s".
e) as root remove the ath9k from memory and modules tree "modprobe -r ath9k; rm /lib/modules/3.3.1-1-ARCH/kernel/drivers/net/wireless/ath/ath9k/ath9k.ko.gz".
f) as root copy the module from the locally compiled kernel to the modules tree "cp <source files dir>/pkg/lib/modules/3.3.1-1-ARCH/kernel/drivers/net/wireless/ath/ath9k/ath9k.ko.gz /lib/modules/3.3.1-1-ARCH/kernel/drivers/net/wireless/ath/ath9k/ath9k.ko.gz".
g) as root run depmod and load the module "depmod -a; modprobe ath9k".

Hope this helps.


Giuseppe Borzi' - Registered Linux user #34028

Offline

#11 2012-04-09 22:44:03

Fastuous
Member
Registered: 2012-04-09
Posts: 7

Re: 3.3.1 ath9k wireless regression (Patch available)

@gborzi

Preface this by saying I'm almost COMPLETELY new to Arch linux and this level of system-tweakage and apologize for anything I say that comes across as glaringly, obviously ignorant.

Anyway, I followed your steps, as I'm in the same predicament with the Asus EeePC, however I must have done something wrong with your patch "ath9kcommit.diff", at first I got a slightly different checksum, but after assuring myself 3-4 times that I had indeed copy/pasted the patch correctly, named correctly and all, I still got the same checksum (2dbce08924ad35830f4976e143e9f86c). I decided to risk it and modify the PKGBUILD with the different checksum, but obviously I had indeed copied something incorrectly as the patch was rejected when I tried to compile and it was aborted.

Please tell me I'm not a complete dumbass for not knowing what's going on when I verbatim copy/paste the patch into gedit/nano and save it as ath9kcommit.diff and it still fails to compile.

Again sorry for any blatant idiocy on my account.

Thanks!

Offline

#12 2012-04-09 23:34:18

gborzi
Member
From: Sicilia
Registered: 2009-03-18
Posts: 102

Re: 3.3.1 ath9k wireless regression (Patch available)

Hi Fastuous,
don't worry, everyone starts as a newbie and learns with time. The problem with the patch is that the original patch I've in my PC contains tabs, that were converted into spaces when I pasted it in the message. Hence the different md5sum and the abortive makepkg, that should have been caused by a failure to apply the patch. My bad, I didn't notice the tabs. You can get the patch from here. I removed the lines above "--- a" and the last two lines. Try again with the patch from the link and let me know if it works.

Regards.


Giuseppe Borzi' - Registered Linux user #34028

Offline

#13 2012-04-10 01:08:58

Fastuous
Member
Registered: 2012-04-09
Posts: 7

Re: 3.3.1 ath9k wireless regression (Patch available)

Thanks! I knew it had to be something simple I was overlooking haha. Got the right checksum and am running makepkg now. Hopefully I don't run into any hiccups when I implement it.

Thanks again. Will confirm if this fix works for my EeePC once I get it going.

Edit: Confirmed, was able to connect to WPA networks after following gborzi's steps to patch the kernel. Thanks a bunch!

Last edited by Fastuous (2012-04-10 06:33:34)

Offline

#14 2012-04-10 07:58:03

Aperculum
Member
From: Finland
Registered: 2007-01-24
Posts: 16

Re: 3.3.1 ath9k wireless regression (Patch available)

I had the same problem with the pathcing. I'm now running makepkg to see if it fixes my problem. My problem was also related to ath9k so I'm hopeful. I'll report back after I'm finished compiling.

edit Fixed it, thanks a lot! smile

Last edited by Aperculum (2012-04-10 15:41:32)

Offline

#15 2012-04-10 09:48:31

Xlator
Member
Registered: 2009-11-14
Posts: 30

Re: 3.3.1 ath9k wireless regression (Patch available)

Cool, worked here too. Many thanks!

Offline

#16 2012-04-10 22:57:54

TTSDA
Member
From: Portugal
Registered: 2012-04-10
Posts: 4

Re: 3.3.1 ath9k wireless regression (Patch available)

Thank you very much. Worked perfectly!

Offline

#17 2012-04-10 23:16:10

SolarBoyMatt
Member
From: Columbus, Ohio
Registered: 2012-01-07
Posts: 258
Website

Re: 3.3.1 ath9k wireless regression (Patch available)

Interestingly, this issue isn't happening to me. I have an AR9285 chip and I just upgraded to the stock 3.3-1 Kernel, but I'm not having and I didn't have any issues connecting to my WPA2 network.  If it makes any difference, I don't use wpa_supplicant to connect to it. I have the networkmanager daemon start up, and I've always used nm-applet to set and configure my network connections. I also didn't have these issues during the ath9k problems when they happened on the 3.2 kernel... weird.

Guess I compiled the 3.3-1 Kernel with that ath9k patch for nothing then, huh? Can never be too safe I guess...

EDIT: Actually, turns out it's the same thing as someone else posted in the bug report. When I first boot up it connects fine, but when I turn the wireless off and back on again, I can't reconnect again until I reboot.

Last edited by SolarBoyMatt (2012-04-11 00:03:51)

Offline

#18 2012-04-11 06:22:59

bergersau
Member
Registered: 2012-01-19
Posts: 47

Re: 3.3.1 ath9k wireless regression (Patch available)

Glad I finally found this thread.
This bug was driving me crazy night before last.  I thought I'd screwed up my config somehow.

I have the same symptom as SolarBoyMatt when using NetworkManager (connection OK on boot but fail to reconnect after that) and no connection at all using WICD.

I'll try rolling back the kernel to 3.2.14 for now - takes too long to compile a kernel on my 1.6 Atom netbook. :-)

Offline

#19 2012-04-11 10:57:55

jukkan
Member
Registered: 2010-09-08
Posts: 39

Re: 3.3.1 ath9k wireless regression (Patch available)

Had the same issue on a laptop that has ath9k. Tried wicd, networkmanager and manually, but nothing worked. wpa_supplicant kept timing out at validating authentication.

Temporarily fixed by downgrading to kernel 3.2.14, so I'm going to use that until this is fixed.

Last edited by jukkan (2012-04-11 11:01:02)

Offline

#20 2012-04-11 11:17:30

lgeek
Member
From: Europe, Portugal
Registered: 2012-03-09
Posts: 70

Re: 3.3.1 ath9k wireless regression (Patch available)

I've had the same problem: https://bbs.archlinux.org/viewtopic.php?id=139365
This solved my problem.

Offline

#21 2012-04-11 15:52:29

gborzi
Member
From: Sicilia
Registered: 2009-03-18
Posts: 102

Re: 3.3.1 ath9k wireless regression (Patch available)

Here is an updated guide that avoids recompiling the entire kernel but needs linux-headers installed.
a) Get the linux source files from abs "cp -r /var/abs/core/linux ." (Note: remember to update your abs dirs).
b) cd into the source files directory and edit the PKGBUILD to add the patch to the compilation process and stop the compilation before it really starts. Here are the relevant snippets from the edited PKGBUILD

....
        'change-default-console-loglevel.patch'
        'i915-fix-ghost-tv-output.patch'
        'ext4-options.patch'
        'ath9kcommit.diff')
....
        '9d3c56a4b999c8bfbd4018089a62f662'
        '263725f20c0b9eb9c353040792d644e5'
        'bb7fd1aa23016c8057046b84fd4eb528'
        '2b8195e3c7563a84061ccd2374c0c345')
....

  # fix ext4 module to mount ext3/2 correct
  # https://bugs.archlinux.org/task/28653
  patch -Np1 -i "${srcdir}/ext4-options.patch"

  # revert commit to fix ath9k
  patch -Np1 -R -i "${srcdir}/ath9kcommit.diff"
....
  ####################

  yes "" | make config
  return 1
....

c) copy the above patch as ath9kcommit.diff in the source files directory.
d) make the package "makepkg -s". It will end soon with an error message, don't worry, this is the expected behaviour.
e) enter the linux source tree dir "cd src/linux-3.3"
f) make the module "make -C /lib/modules/3.3.1-1-ARCH/build M=`pwd`/drivers/net/wireless/ath/ath9k".
g) as root remove the ath9k module from memory and modules tree "modprobe -r ath9k; rm /lib/modules/3.3.1-1-ARCH/kernel/drivers/net/wireless/ath/ath9k/ath9k.ko.gz".
h) as root copy the module from the kernel tree to the modules tree "cp <source files dir>/drivers/net/wireless/ath/ath9k/ath9k.ko /lib/modules/3.3.1-1-ARCH/kernel/drivers/net/wireless/ath/ath9k/ath9k.ko".
i) as root run depmod and load the module "depmod -a; modprobe ath9k".


Giuseppe Borzi' - Registered Linux user #34028

Offline

#22 2012-04-11 21:17:33

DarkSniper
Member
Registered: 2011-04-05
Posts: 74

Re: 3.3.1 ath9k wireless regression (Patch available)

Thanks for the instructions! Putting the line to reverse the diff in my linux-ck PKGBUILD worked like a charm.

Though for my -ARCH backup kernel, a complete recompile would take magnitudes longer (I like to keep it in the vanilla repo state, so no localmodconfig).
To make this process simpler, I took gborzi's instructions and integrated them into a PKGBUILD that only builds the module and does so in a cleaner, single makepkg command.

The makepkg source archive is up here if anyone wants it: http://dl.dropbox.com/u/6464618/ath9k-w … src.tar.gz

Make sure you don't try to install the resulting package (you should get dependency errors if you try as I set invalid depends as a safety measure).
The module you want will be in pkg. You will still have to install the module manually as detailed above. This PKGBUILD merely streamlines the build process.
I copied the instructions into a text file and included them in the source archive (as README) just in case you don't have access to the forums when you install it.

Last edited by DarkSniper (2012-04-11 21:25:08)


Failure is not an option... It comes bundled with Windows.

Offline

#23 2012-04-13 15:14:26

flocke
Member
From: Magdeburg
Registered: 2010-06-14
Posts: 5
Website

Re: 3.3.1 ath9k wireless regression (Patch available)

If you don't want to recompile the kernel you can just install the compat-wireless-patched package from the AUR. This solved the problem for me without recompiling the whole kernel.

Offline

#24 2012-04-13 17:11:21

LadFromWales
Member
Registered: 2011-01-29
Posts: 9

Re: 3.3.1 ath9k wireless regression (Patch available)

DarkSniper wrote:

The makepkg source archive is up here if anyone wants it: http://dl.dropbox.com/u/6464618/ath9k-w … src.tar.gz

Cheers for the pkg! All connected on laptop now smile
Thanks!

Offline

#25 2012-04-14 14:03:57

listdata
Member
Registered: 2008-12-23
Posts: 102
Website

Re: 3.3.1 ath9k wireless regression (Patch available)

The Linux 3.3.2 stable release has reverted the troublesome commit (commit c1afdaff90538ef085b756454f12b29575411214) with commit 2ed63a49ab039d590f7f9fef63706d83805079c6; see http://www.kernel.org/pub/linux/kernel/ … eLog-3.3.2.

So, if you are lazy you can just downgrade to the older kernel and upgrade when 3.3.2 is available from Core.

Offline

Board footer

Powered by FluxBB