If you remember, I had set up my desktop computer as a Wi-Fi access point
. It is working really well since then.
However, I hadn't updated that kernel in a long while... I didn't want to update because I read about rt61pci problems with hostapd after upgrade to 2.6.31
, and I didn't have enough time to investigate and solve problems back then. So, I was running linux-2.6.30-gentoo-r5 kernel for over a year.
This month, however, I decided it was time to update. And so I did. And it stopped working.
After updating to linux-2.6.36-gentoo-r5, this happened:
- hostapd starts, no error messages.
- My notebook can associate with the AP, no errors.
- hostapd shows "WPA: pairwise key handshake completed (RSN)". My notebook wlan0 interface is up.
- However... The DHCP client times out and the notebook doesn't receive an IP.
- Even if I manually set an IP to the notebook interface, one machine can't ping the other one.
After watching packets in wireshark
, I found out the notebook was able to receive packets from the desktop (specifically, it was receiving CUPS broadcast packets). I tried pinging my notebok from my desktop, and the notebook was receiving the ping requests, but the ping responses never reached the desktop.
Then I tried disabling WPA and reconnecting. This time, it everything works and both machines can communicate. Obviously, I've disabled it a minute later. I don't want my Wi-Fi unencrypted.
Okay, I was out of luck. The new kernel only worked without encryption, and the old kernel worked flawlessly. I didn't know what else to do, so I asked for help in rt2x00-users mailing list
. And I got very helpful responses! Thanks, Luis Correia and Helmut Schaa!They suggested me to try a little patch
, but it half-worked: Linux client worked fine, while Windows client got very unstable connection
. Then, it was concluded the best solution was to disable hardware encryption
It is a known fact that some older chipsets, like rt61pci have some
problems with encryption and they were never fixed.
So, it is best to disable it alltogether since the difference to use
software encryption isn't noticable on more recent computers.
So... How to disable hardware encryption? Very easy! Just pass nohwcrypt=1
option to the rt61pci
linux module. I did that by adding a file /etc/modules.d/rt61pci_nohwcrypt
with this line:
options rt61pci nohwcrypt=1
And then ran update-modules
command. I bet it would also work if I added it to the /etc/modprobe.d
directory. Obviously, after that you should either reboot or unload and reload the module.
But why did it work on previous versions? Because a while ago (maybe up to kernel 2.6.30), the default setting had hardware encryption disabled. Recently (maybe after kernel 2.6.31), it became enabled by default, and thus things stopped working on some chipsets.
So now I'm happy again, with my machines updated and my Wi-Fi back working.