ath9k drivers freeze the system when changing state

Bug #787210 reported by Sam Van den Eynde
30
This bug affects 7 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Medium
Seth Forshee

Bug Description

Binary package hint: linux-image-generic

The ath9k driver freezes the laptop when the adapter changes state. Reproduceable by enabling/disabling wireless adapter using the network manager applet, or by suspending the system. The issue exists at least in 10.10 as well, but never had issues running 10.04. Since applicable in several kernel versions, reported this against linux-image-generic. It's 32 bit stock kernel, latest updates, Natty 11.04 i386.

On 10.10 the system got freezes randomly just while browsing, which was even worse. Used compat-wireless which made it much better but not perfect (only freezes on state changes as mentioned above).

I am 100% sure it is triggered by the wireless driver: issuing "rmmod ath9k ath9k_common ath9k_hw ath" prior to suspending the laptop, followed by "modprobe ath9k" after resume, makes the freeze disappear. I actually added a script in /etc/pm.d/sleep.d issuing these commands and now laptop works normal.

ProblemType: Bug
DistroRelease: Ubuntu 11.04
Package: linux-image-generic 2.6.38.8.22
ProcVersionSignature: Ubuntu 2.6.38-8.42-generic 2.6.38.2
Uname: Linux 2.6.38-8-generic i686
NonfreeKernelModules: nvidia
AlsaVersion: Advanced Linux Sound Architecture Driver Version 1.0.23.
Architecture: i386
ArecordDevices:
 **** List of CAPTURE Hardware Devices ****
 card 0: NVidia [HDA NVidia], device 0: STAC92xx Analog [STAC92xx Analog]
   Subdevices: 1/1
   Subdevice #0: subdevice #0
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: sam 1773 F.... xfce4-volumed
                      sam 1794 F.... pulseaudio
CRDA: Error: [Errno 2] No such file or directory
Card0.Amixer.info:
 Card hw:0 'NVidia'/'HDA NVidia at 0x93100000 irq 23'
   Mixer name : 'Nvidia MCP79/7A HDMI'
   Components : 'HDA:111d7605,103c3651,00100402 HDA:10de0007,10de0101,00100100'
   Controls : 18
   Simple ctrls : 10
Date: Mon May 23 22:55:40 2011
InstallationMedia: Xubuntu 11.04 "Natty Narwhal" - Release i386 (20110426.1)
MachineType: Hewlett-Packard Compaq Mini 311-1100
ProcEnviron:
 LANGUAGE=en_US:en
 LANG=en_US.UTF-8
 SHELL=/bin/bash
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-2.6.38-8-generic root=UUID=76ad9066-c058-4318-95ea-d214f8737341 ro quiet splash vt.handoff=7
RelatedPackageVersions:
 linux-restricted-modules-2.6.38-8-generic N/A
 linux-backports-modules-2.6.38-8-generic N/A
 linux-firmware 1.52
SourcePackage: linux
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 11/07/2009
dmi.bios.vendor: Hewlett-Packard
dmi.bios.version: F.12
dmi.board.asset.tag: Base Board Asset Tag
dmi.board.name: 3651
dmi.board.vendor: Hewlett-Packard
dmi.board.version: 49.18
dmi.chassis.type: 10
dmi.chassis.vendor: Hewlett-Packard
dmi.chassis.version: N/A
dmi.modalias: dmi:bvnHewlett-Packard:bvrF.12:bd11/07/2009:svnHewlett-Packard:pnCompaqMini311-1100:pvr048F110000201C00000320000:rvnHewlett-Packard:rn3651:rvr49.18:cvnHewlett-Packard:ct10:cvrN/A:
dmi.product.name: Compaq Mini 311-1100
dmi.product.version: 048F110000201C00000320000
dmi.sys.vendor: Hewlett-Packard

Revision history for this message
Sam Van den Eynde (samvde) wrote :
affects: linux-meta (Ubuntu) → linux (Ubuntu)
Brad Figg (brad-figg)
Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Seth Forshee (sforshee) wrote :

@Sam, please try the following. Switch to virtual terminal 1 (press Ctrl-Alt-F1) and log in. Run ifconfig and identify the interface that represents your wireless device (e.g. eth1), and then run 'sudo ifconfig eth1 down' (using the interface for your wireless). Please let me know if the system locks up when you do this, and if so whether or not anything is printed on the screen. Thanks!

Changed in linux (Ubuntu):
assignee: nobody → Seth Forshee (sforshee)
importance: Undecided → Medium
status: Confirmed → Incomplete
Revision history for this message
Sam Van den Eynde (samvde) wrote : Re: [Bug 787210] Re: ath9k drivers freeze the system when changing state
Download full text (4.8 KiB)

Hi,

Bringing the interface down was no issue, but bringing it back up ("sudo
ifconfig eth1 up" in the analogy) gave an instant freeze. Needed to hard
power down the system and reboot. Everything working fine after reboot.

Nothing shows up in the console at all.

I just noticed with 11.04 I don't have a /var/log/messages file per default
anymore. If you can advice me how to log for this issue I'd be happy to do
further testing.

Krgds
Sam

On Mon, Jun 27, 2011 at 3:22 PM, Seth Forshee <email address hidden>wrote:

> @Sam, please try the following. Switch to virtual terminal 1 (press
> Ctrl-Alt-F1) and log in. Run ifconfig and identify the interface that
> represents your wireless device (e.g. eth1), and then run 'sudo ifconfig
> eth1 down' (using the interface for your wireless). Please let me know
> if the system locks up when you do this, and if so whether or not
> anything is printed on the screen. Thanks!
>
> ** Changed in: linux (Ubuntu)
> Importance: Undecided => Medium
>
> ** Changed in: linux (Ubuntu)
> Status: Confirmed => Incomplete
>
> ** Changed in: linux (Ubuntu)
> Assignee: (unassigned) => Seth Forshee (sforshee)
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/787210
>
> Title:
> ath9k drivers freeze the system when changing state
>
> Status in “linux” package in Ubuntu:
> Incomplete
>
> Bug description:
> Binary package hint: linux-image-generic
>
> The ath9k driver freezes the laptop when the adapter changes state.
> Reproduceable by enabling/disabling wireless adapter using the network
> manager applet, or by suspending the system. The issue exists at least
> in 10.10 as well, but never had issues running 10.04. Since applicable
> in several kernel versions, reported this against linux-image-generic.
> It's 32 bit stock kernel, latest updates, Natty 11.04 i386.
>
> On 10.10 the system got freezes randomly just while browsing, which
> was even worse. Used compat-wireless which made it much better but not
> perfect (only freezes on state changes as mentioned above).
>
> I am 100% sure it is triggered by the wireless driver: issuing "rmmod
> ath9k ath9k_common ath9k_hw ath" prior to suspending the laptop,
> followed by "modprobe ath9k" after resume, makes the freeze disappear.
> I actually added a script in /etc/pm.d/sleep.d issuing these commands
> and now laptop works normal.
>
> ProblemType: Bug
> DistroRelease: Ubuntu 11.04
> Package: linux-image-generic 2.6.38.8.22
> ProcVersionSignature: Ubuntu 2.6.38-8.42-generic 2.6.38.2
> Uname: Linux 2.6.38-8-generic i686
> NonfreeKernelModules: nvidia
> AlsaVersion: Advanced Linux Sound Architecture Driver Version 1.0.23.
> Architecture: i386
> ArecordDevices:
> **** List of CAPTURE Hardware Devices ****
> card 0: NVidia [HDA NVidia], device 0: STAC92xx Analog [STAC92xx Analog]
> Subdevices: 1/1
> Subdevice #0: subdevice #0
> AudioDevicesInUse:
> USER PID ACCESS COMMAND
> /dev/snd/controlC0: sam 1773 F.... xfce4-volumed
> sam 1794 F.... pulseaudio
> CRDA: Error: [Errno 2] No such file or directory
> ...

Read more...

Revision history for this message
Seth Forshee (sforshee) wrote :

@Sam, you can look in /var/log/syslog and /var/log/kern.log. You may find something there, but if it's really locked hard then there probably won't be anything useful logged there. It's worth checking though.

Revision history for this message
Sam Van den Eynde (samvde) wrote :
Download full text (4.6 KiB)

Hi,

No luck... I can see the ifdown in the logs, but followed by the system
boot. I left 10 seconds between ifdown and ifup to get clear time stamps. No
ifup in the logs...

And I've had the issue on ifdown as well. So it's the state change in both
directions that triggers it.

To do further testing I am going to clone my root fs to a new partition
first and boot from there. These are really ugly freezes (completely dead in
a millisec) and I already had soms fs errors on my /home during last
boot...

Not that it would be a disaster since this is backed up nicely but
nevertheless... So further testing is due for tomorrow (Brussels timezone).

Rgds
Sam

On Mon, Jun 27, 2011 at 5:35 PM, Seth Forshee <email address hidden>wrote:

> @Sam, you can look in /var/log/syslog and /var/log/kern.log. You may
> find something there, but if it's really locked hard then there probably
> won't be anything useful logged there. It's worth checking though.
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/787210
>
> Title:
> ath9k drivers freeze the system when changing state
>
> Status in “linux” package in Ubuntu:
> Incomplete
>
> Bug description:
> Binary package hint: linux-image-generic
>
> The ath9k driver freezes the laptop when the adapter changes state.
> Reproduceable by enabling/disabling wireless adapter using the network
> manager applet, or by suspending the system. The issue exists at least
> in 10.10 as well, but never had issues running 10.04. Since applicable
> in several kernel versions, reported this against linux-image-generic.
> It's 32 bit stock kernel, latest updates, Natty 11.04 i386.
>
> On 10.10 the system got freezes randomly just while browsing, which
> was even worse. Used compat-wireless which made it much better but not
> perfect (only freezes on state changes as mentioned above).
>
> I am 100% sure it is triggered by the wireless driver: issuing "rmmod
> ath9k ath9k_common ath9k_hw ath" prior to suspending the laptop,
> followed by "modprobe ath9k" after resume, makes the freeze disappear.
> I actually added a script in /etc/pm.d/sleep.d issuing these commands
> and now laptop works normal.
>
> ProblemType: Bug
> DistroRelease: Ubuntu 11.04
> Package: linux-image-generic 2.6.38.8.22
> ProcVersionSignature: Ubuntu 2.6.38-8.42-generic 2.6.38.2
> Uname: Linux 2.6.38-8-generic i686
> NonfreeKernelModules: nvidia
> AlsaVersion: Advanced Linux Sound Architecture Driver Version 1.0.23.
> Architecture: i386
> ArecordDevices:
> **** List of CAPTURE Hardware Devices ****
> card 0: NVidia [HDA NVidia], device 0: STAC92xx Analog [STAC92xx Analog]
> Subdevices: 1/1
> Subdevice #0: subdevice #0
> AudioDevicesInUse:
> USER PID ACCESS COMMAND
> /dev/snd/controlC0: sam 1773 F.... xfce4-volumed
> sam 1794 F.... pulseaudio
> CRDA: Error: [Errno 2] No such file or directory
> Card0.Amixer.info:
> Card hw:0 'NVidia'/'HDA NVidia at 0x93100000 irq 23'
> Mixer name : 'Nvidia MCP79/7A HDMI'
> Components : 'HDA:111d7605,103c3651,00100402
> HDA:10de0007,10de0101,00100100'
> ...

Read more...

Revision history for this message
Seth Forshee (sforshee) wrote :

@Sam: Here's something else to try. Induce the lockup from virtual terminal 1 and then press Alt-Sysrq-9 then Alt-Sysrq-P. If that produces some output, please take a photograph or something to capture the output. After that you can also try pressing Alt-Sysrq-L and Alt-Sysrq-T, then wait a few seconds and press Alt-Sysrq-S and Alt-Sysrq-B. This should produce lots of output then sync your filesystems and reboot your machine. After the reboot completes you can check /var/log/kern.log to see if the data was logged there.

Revision history for this message
insaner (insaner) wrote :

i can confirm this bug.. 11.04 is unusable because of it. i need to boot with 2.6.35-30 (the kernel from 10.10) as no other kernel i've tried is able to get past the point after i enter my login info,and press enter. shortly after the background changes (as part of the login process) but before any icons or panels show up, the machine freezes completely, and i need to hard reboot.

2.6.35-30 gets me up and online but also sometimes after a while freezes the entire system. plugging in the ethernet cable allows the other kernels to operate fine, but unplugging it makes the system freeze.

the kernels ive tried so far have been
2.6.38-11
2.6.38-10
2.6.39
3.0.0

i tried the compat-wireless trick but it didnt work.

Revision history for this message
insaner (insaner) wrote :

my machine is an acer aspire one 522-bz623

Revision history for this message
insaner (insaner) wrote :
Revision history for this message
Sam Van den Eynde (samvde) wrote :

Well this is worse in 11.10. Even proactively unloading the modules make the laptop freeze. With the 6 month release cycle this issue remains in place for at least 1,5 years now, which is a lot... I guess I need to replace the module by an Intel based model to be in the green.

Revision history for this message
Seth Forshee (sforshee) wrote :

Is anyone able to try the steps in comment #6 to see if more information can be collected to help in debugging the issue? Right now there's very little information to go on, and since many machines use ath9k without this issue it's difficult to know what's special about the configurations affected by this bug.

Something else to try is to use the iw command-line tool (sudo apt-get install iw) from virtual terminal 1 to see if you can trigger the lockup and whether anything is printed to the console when it hangs. An example iw session would look like:

  Get a list of wireless devices
  $ iw list

  Scan for APs on device wlan0
  $ iw dev wlan0 scan

  Connect to open AP "foo" on device wlan0
  $ iw wlan0 connect foo

More information about using iw can be found at

http://linuxwireless.org/en/users/Documentation/iw

Revision history for this message
Dmitry (tdmdimas) wrote :

If the first device in the boot order is not an adapter (ath9k) - system freezes at 100%. laptop Lenovo G575 (Atheros ar9285)

Revision history for this message
Guillaume Gay (gay) wrote :

Hi,

I am also affected by this bug on a Compaq Mini 311C with Xubuntu 11.10 (3.0.0-12-generic kernel).
lspci gives:
03:00.0 Network controller: Atheros Communications Inc. AR9285 Wireless Network Adapter (PCI-Express) (rev 01)

A simple "sudo rmmod ath9k" suffices to freeze the system completely when the wifi is connected. When it's not, every thing goes well.

I'll try the steps of comment #6 at home as I don't have any wifi access point here.

Thank you for addressing this bug!

Guillaume

Revision history for this message
Sam Van den Eynde (samvde) wrote :
Download full text (4.7 KiB)

Hi guys

In the end I replaced the module by a Broadcom one a few weeks ago. The
laptop is running as clean as can be. It never freezes, I suspend/resume it
all the time and I disable/enable network at will. I rebooted maybe 2-3
times over the past weeks, mainly because of installed updates.

I could not get a meaningful error code out of the ath9k driver although I
tried all procedures. I am not a developer, but maybe a debug module
printing out some essential status information could help here.

Kind regards
Sam

On Tue, Nov 15, 2011 at 11:38 AM, Guillaume Gay
<email address hidden>wrote:

> Hi,
>
> I am also affected by this bug on a Compaq Mini 311C with Xubuntu 11.10
> (3.0.0-12-generic kernel).
> lspci gives:
> 03:00.0 Network controller: Atheros Communications Inc. AR9285 Wireless
> Network Adapter (PCI-Express) (rev 01)
>
> A simple "sudo rmmod ath9k" suffices to freeze the system completely
> when the wifi is connected. When it's not, every thing goes well.
>
> I'll try the steps of comment #6 at home as I don't have any wifi access
> point here.
>
> Thank you for addressing this bug!
>
> Guillaume
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/787210
>
> Title:
> ath9k drivers freeze the system when changing state
>
> Status in “linux” package in Ubuntu:
> Incomplete
>
> Bug description:
> Binary package hint: linux-image-generic
>
> The ath9k driver freezes the laptop when the adapter changes state.
> Reproduceable by enabling/disabling wireless adapter using the network
> manager applet, or by suspending the system. The issue exists at least
> in 10.10 as well, but never had issues running 10.04. Since applicable
> in several kernel versions, reported this against linux-image-generic.
> It's 32 bit stock kernel, latest updates, Natty 11.04 i386.
>
> On 10.10 the system got freezes randomly just while browsing, which
> was even worse. Used compat-wireless which made it much better but not
> perfect (only freezes on state changes as mentioned above).
>
> I am 100% sure it is triggered by the wireless driver: issuing "rmmod
> ath9k ath9k_common ath9k_hw ath" prior to suspending the laptop,
> followed by "modprobe ath9k" after resume, makes the freeze disappear.
> I actually added a script in /etc/pm.d/sleep.d issuing these commands
> and now laptop works normal.
>
> ProblemType: Bug
> DistroRelease: Ubuntu 11.04
> Package: linux-image-generic 2.6.38.8.22
> ProcVersionSignature: Ubuntu 2.6.38-8.42-generic 2.6.38.2
> Uname: Linux 2.6.38-8-generic i686
> NonfreeKernelModules: nvidia
> AlsaVersion: Advanced Linux Sound Architecture Driver Version 1.0.23.
> Architecture: i386
> ArecordDevices:
> **** List of CAPTURE Hardware Devices ****
> card 0: NVidia [HDA NVidia], device 0: STAC92xx Analog [STAC92xx Analog]
> Subdevices: 1/1
> Subdevice #0: subdevice #0
> AudioDevicesInUse:
> USER PID ACCESS COMMAND
> /dev/snd/controlC0: sam 1773 F.... xfce4-volumed
> sam 1794 F.... pulseaudio
> CRDA: Error: [Errno 2] No such file or directory
> Card0.Amixer.info:
> Card hw:0 '...

Read more...

Revision history for this message
sherbey (mark-sherborne) wrote :

I'm running 11.04 ubuntu on a HP 311c laptop; suspend and hibernate did not work in that attempting to wake the computer up would always hard lock it, requiring a 5 second press of the power button to kill it.

AR9285 Atheros wifi adaptor seems to be the culprit; occasionally disabling this via the wifi button prior to attempting suspend/hibernate would allow the process to work correctly.

Installing compat-wireless via synaptic (linux-backports-modules-cw-3.0.0-2.6.38-13-generic) seems to have fixed this issue - suspend and hibernate both working fine.

Revision history for this message
Guillaume Gay (gay) wrote :

Hi,

Sorry to have to come back to this...
The solution given above works only in 11.04, I'm running 11.10 and the backport version is linux-backports-modules-cw-3.2-oneiric-generic, which doesn't solve the issue.

Right now I'm runnning my laptop with ath9k blacklisted, and modprobe it when I need wireless conection, but then it freezes whenever I try to stop the computer (or suspend).

Is there another solution?

Best,

Guillaume

Revision history for this message
sherbey (mark-sherborne) wrote :

Updated my HP 311c laptop to 12.04; suspend either hard-locks the machine or 'bounces' back into screensaver password. Trying to shut the machine down results in hard-lockups probably 70% of the time. I've installed compat-wireless from the repositories which improved matters a little (100% lockup on trying to shut the laptop off before), and I have tried compiling the latest compat-wireless from http://linuxwireless.org/en/users/Download which if anything made matters worse.

I never ran 11.10 on this machine (apart from momentarily to update to 12.04).

Revision history for this message
Guillaume Gay (gay) wrote :

Just tried a fresh xubuntu 12.04 install on my compaq 311c to no avail.. I also tried to enable the network adapter boot device in the bios, which some how changed the behaviour. As of now halting and reboot works but not suspend.

Is any body loking at the bug? Is there something we can do?

Guillaume

Revision history for this message
sherbey (mark-sherborne) wrote :

Following the advice in post #2, sudo ifconfig wlan0 down in virtual terminal 1 instantly locks the computer. Nothing results from doing the advice in post #6, and looking at kern.log post-reboot reveals no log entries relating to the attempt to shut the interface down.

HP 311c running 12.04

Getting the feeling that this just isn't going to get even looked at let alone fixed. Very very disappointed in this. 18 months! Good grief!

Revision history for this message
Sam Van den Eynde (samvde) wrote :

I strongly advise you to replace the module. I replaced it with WiFi/Bluetooth (use partnumber 575920-001 for queries), and never had another issue.

Revision history for this message
sherbey (mark-sherborne) wrote :

I tried replacing the wifi/bluetooth mini pci-e card with one from ebay culled from a Dell laptop (BCM94312HMG) - the HP stopped with a BIOS error message on rebooting :(
I've ordered a 575920-001 so I'm looking forward to standby/hibernation heaven from now on. Cheers Sam.

Revision history for this message
Sam Van den Eynde (samvde) wrote :

Yes they check it in bios, you can only use hp approved parts. There is a hack but seen the price, just get one that works is easier...

Revision history for this message
vinçouille (v-jousse) wrote :

I'm another user of a mini 311c on ubuntu 13.04.
I have added pcie_aspm=force to my boot options, and I can suspend, but once only !!
What can I do to help fixing this bug ?

Revision history for this message
Sam Van den Eynde (samvde) wrote :

Closing this old bug. Newer versions should not see this issue anymore.

Changed in linux (Ubuntu):
status: Incomplete → Fix Committed
Brad Figg (brad-figg)
tags: added: cscc
Changed in linux (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.