# Wireless auth works w/ kernel 3.3.0 but not 3.3.1 [solved]

## verticalrock

I just ran across an oddity that has me scratching my head a bit.  I've had a system running wpa_supplicant on my ath9k wireless card with no issues until I just tried to upgrade to gentoo-sources-3.3.1.

I did the usual "make oldconfig" and nothing came back to change, so I made the kernel and rebooted.  The system seemed to come up as normal but I couldn't connect to it.  Looking through the logs everything seemed fine until:

```
Apr  4 14:24:28 philco kernel: [   12.709757] wlan0: authenticate with 00:24:7b:31:26:4c (try 1)

Apr  4 14:24:28 philco kernel: [   12.909048] wlan0: authenticate with 00:24:7b:31:26:4c (try 2)

Apr  4 14:24:28 philco kernel: [   13.109045] wlan0: authenticate with 00:24:7b:31:26:4c (try 3)

Apr  4 14:24:28 philco kernel: [   13.309050] wlan0: authentication with 00:24:7b:31:26:4c timed out

Apr  4 14:24:39 philco kernel: [   23.845796] wlan0: authenticate with 00:24:7b:31:26:4c (try 1)

Apr  4 14:24:39 philco kernel: [   24.045060] wlan0: authenticate with 00:24:7b:31:26:4c (try 2)

Apr  4 14:24:39 philco kernel: [   24.245045] wlan0: authenticate with 00:24:7b:31:26:4c (try 3)

Apr  4 14:24:40 philco kernel: [   24.445036] wlan0: authentication with 00:24:7b:31:26:4c timed out

Apr  4 14:24:50 philco kernel: [   34.981602] wlan0: direct probe to 00:24:7b:31:26:4c (try 1/3)

Apr  4 14:24:50 philco kernel: [   35.181061] wlan0: direct probe to 00:24:7b:31:26:4c (try 2/3)

Apr  4 14:24:51 philco kernel: [   35.381055] wlan0: direct probe to 00:24:7b:31:26:4c (try 3/3)

Apr  4 14:24:51 philco kernel: [   35.581061] wlan0: direct probe to 00:24:7b:31:26:4c timed out

Apr  4 14:25:01 philco kernel: [   46.120803] wlan0: authenticate with 00:24:7b:31:26:4c (try 1)

Apr  4 14:25:02 philco kernel: [   46.320058] wlan0: authenticate with 00:24:7b:31:26:4c (try 2)

Apr  4 14:25:02 philco kernel: [   46.520056] wlan0: authenticate with 00:24:7b:31:26:4c (try 3)

Apr  4 14:25:02 philco kernel: [   46.720057] wlan0: authentication with 00:24:7b:31:26:4c timed out

Apr  4 14:25:12 philco kernel: [   57.260790] wlan0: direct probe to 00:24:7b:31:26:4c (try 1/3)

Apr  4 14:25:13 philco kernel: [   57.460060] wlan0: direct probe to 00:24:7b:31:26:4c (try 2/3)

Apr  4 14:25:13 philco kernel: [   57.660053] wlan0: direct probe to 00:24:7b:31:26:4c (try 3/3)

Apr  4 14:25:13 philco kernel: [   57.860063] wlan0: direct probe to 00:24:7b:31:26:4c timed out

Apr  4 14:25:30 philco kernel: [   74.528779] wlan0: authenticate with 00:24:7b:31:26:4c (try 1)

Apr  4 14:25:30 philco kernel: [   74.728046] wlan0: authenticate with 00:24:7b:31:26:4c (try 2)

Apr  4 14:25:30 philco kernel: [   74.928055] wlan0: authenticate with 00:24:7b:31:26:4c (try 3)

Apr  4 14:25:30 philco kernel: [   75.128036] wlan0: authentication with 00:24:7b:31:26:4c timed out
```

When I reboot into my old kernel (gentoo-sources-3.3.0):

```
Apr  4 14:39:06 philco kernel: [   11.944054] wlan0: authenticate with 00:24:7b:31:26:4c (try 1)

Apr  4 14:39:06 philco kernel: [   11.946029] wlan0: authenticated

Apr  4 14:39:06 philco kernel: [   11.946106] wlan0: associate with 00:24:7b:31:26:4c (try 1)

Apr  4 14:39:06 philco kernel: [   11.949804] wlan0: RX AssocResp from 00:24:7b:31:26:4c (capab=0x411 status=0 aid=1)

Apr  4 14:39:06 philco kernel: [   11.949812] wlan0: associated

Apr  4 14:39:06 philco kernel: [   11.949820] wlan0: moving STA 00:24:7b:31:26:4c to state 1

Apr  4 14:39:06 philco kernel: [   11.949825] wlan0: moving STA 00:24:7b:31:26:4c to state 2

Apr  4 14:39:06 philco kernel: [   11.949831] wlan0: moving STA 00:24:7b:31:26:4c to state 3

Apr  4 14:39:06 philco kernel: [   11.952526] ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
```

As I have changed nothing between these two kernel, I am curious to see if anyone else has seen this weirdness.Last edited by verticalrock on Sat Apr 07, 2012 4:51 pm; edited 1 time in total

----------

## romildo

I am having a similar issue too, after upgrading to sys-kernel/gentoo-sources-3.3.1 on my ~amd64 notebook yesterday. The card is an  Atheros AR9285.

----------

## TRC

same exact problems as described in previous posts, also using an Atheros AR9285 wireless card

----------

## romildo

I have found it is a bug in kernel 3.3.1 and will be fixed in next versions. For now stick with kernel 3.3.0.

https://lkml.org/lkml/2012/4/3/303

----------

## zhushazang

Hey hey hey, same here. Finally someone with the same problem. Going back to 3.3.0.

Another question, someone have problem with vmplayer and pf-sources? It's impossible use XP inside vmplayer when use pf-source. A lot of hangs.

Thanks for any advice

----------

## ulenrich

Just revert the only ath9k patch of series 3.3.1 and keep going linux-3.3.1:

```

--- a/drivers/net/wireless/ath/ath9k/main.c

+++ b/drivers/net/wireless/ath/ath9k/main.c

@@ -118,15 +118,13 @@ void ath9k_ps_restore(struct ath_softc *

        if (--sc->ps_usecount != 0)

                goto unlock;

-       if (sc->ps_flags & PS_WAIT_FOR_TX_ACK)

-               goto unlock;

-

-       if (sc->ps_idle)

+       if (sc->ps_idle && (sc->ps_flags & PS_WAIT_FOR_TX_ACK))

                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_PSPOLL_DATA |

+                             PS_WAIT_FOR_TX_ACK)))

                mode = ATH9K_PM_NETWORK_SLEEP;

        else

                goto unlock;

```

[edit] above ist not the original patch but the antipatch of the patchLast edited by ulenrich on Sat Apr 07, 2012 4:32 pm; edited 1 time in total

----------

## claudecat

 *ulenrich wrote:*   

> Just revert the only ath9k patch of series 3.3.1 and keep going linux-3.3.1:
> 
> ```
> 
> --- a/drivers/net/wireless/ath/ath9k/main.c
> ...

 

Umm... ok, I'm new to gentoo and am having this issue with the new kernel (and have reverted back to 3.3.0 for now). How exactly would I do what is proposed above?

----------

## BillWho

claudecat,

 *Quote:*   

> How exactly would I do what is proposed above?

 

There are several ways of doing this - this is how I usually do it on the rare occasion that I need to.

Set your linux symlink to linux-3.3.1-gentoo/ and cd to it.

```
diff -u  ../linux-3.3.0-gentoo/drivers/net/wireless/ath/ath9k/main.c  ../linux-3.3.1-gentoo/drivers/net/wireless/ath/ath9k/main.c > ath9k.patch
```

```
patch -b drivers/net/wireless/ath/ath9k/main.c /usr/src/linux/ath9k.patch
```

The -b will create a backup file of main.c.orig

Good luck   :Wink: 

----------

## claudecat

Thanks for the reply - now I know how to create a patch  :Smile:  ! Unfortunately, I  had already unmerged the 3.3.0 kernel. Anyway, I ended up simply copying the main.c file from /usr/portage/distfiles/linux-3.3.tar.bz2 (confirmed it was dated older than the one I had and looked it over briefly - backed up the "original" just in case) into the correct place in the 3.3.1 kernel tree and recompiled. Works fine now. Thanks again BillWho!

----------

## verticalrock

Thanks to all for the help and camaraderie.  Always good to see the fine Gentoo-vians come together to help identify a problem.  As 3.3.1 didn't bring any particular improvements I need, I'll just stick with 3.3.0 and wait to see if this bug gets fixed in 3.3.2.

Cheers!

----------

## manwe_

@ulenrich: Thanks for the tip and diff, had the same issue with my AR9285. Now 3.3.1 works flawless  :Smile: 

----------

## Spidey

Thank you all. I'm having this same problem and couldn't downgrade to 3.1 or 3.2 because of udev problems (probably would need to rebuild it with the older kernel set).

----------

