dvb_usb firmware does not load after hibernate / resume or within initramfs for different hardware (e.g. af9015/AVerMedia A309 or dib0700/hauppauge nova T)

Bug #388383 reported by Anand Kumria
32
This bug affects 6 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Hi,

I have a HP HDX 16 which correctly hibernates and resumes using:

Linux saltatrix 2.6.30-9-generic #10-Ubuntu SMP Fri Jun 12 13:08:18 UTC 2009 x86_64 GNU/Linux

It has a dvb-usb device (AverMedia A30), during system boot it is detected and the firmware is located, however after a hibernate / resume cycle it fails to find the firmware.

anand@saltatrix:/lib/firmware$ dmesg | grep -i firmware
[ 0.642502] Firmware did not grant requested _OSC control
[ 0.642562] Firmware did not grant requested _OSC control
[ 0.642607] Firmware did not grant requested _OSC control
[ 0.642653] Firmware did not grant requested _OSC control
[ 0.642698] Firmware did not grant requested _OSC control
[ 0.642743] Firmware did not grant requested _OSC control
[ 0.642848] Firmware did not grant requested _OSC control
[ 0.642894] Firmware did not grant requested _OSC control
[ 0.642939] Firmware did not grant requested _OSC control
[ 0.642984] Firmware did not grant requested _OSC control
[ 0.643029] Firmware did not grant requested _OSC control
[ 0.643075] Firmware did not grant requested _OSC control
[ 10.793797] dvb-usb: found a 'AVerMedia A309' in cold state, will try to load a firmware
[ 10.793803] usb 2-8: firmware: requesting dvb-usb-af9015.fw
[ 11.061131] dvb-usb: downloading firmware from file 'dvb-usb-af9015.fw'
[ 11.615424] af9013: firmware version:4.65.0
[ 26.268298] iwlagn 0000:02:00.0: firmware: requesting iwlwifi-5000-2.ucode
[ 26.301150] iwlagn 0000:02:00.0: loaded firmware version 8.24.2.12
[77776.946263] dvb-usb: found a 'AVerMedia A309' in cold state, will try to load a firmware
[77776.946268] usb 2-8: firmware: requesting dvb-usb-af9015.fw
[77836.936145] dvb-usb: did not find the firmware file. (dvb-usb-af9015.fw) Please see linux/Documentation/dvb/ for more details on firmware-problems. (-2)

The firmware file exists in /lib/firmware/:

anand@saltatrix:/lib/firmware$ date +%s
1245235248
anand@saltatrix:/lib/firmware$ ls -l dvb-usb-af9015.fw
-rw-r--r-- 1 root root 12700 2009-06-10 13:02 dvb-usb-af9015.fw

Not sure what else I can do to help.

Regards,
Anand

ProblemType: Bug
Architecture: amd64
Date: Wed Jun 17 11:37:02 2009
DistroRelease: Ubuntu 9.10
HibernationDevice: RESUME=UUID=59276a34-e540-4fd4-87fb-095b6aa6d6b5
MachineType: Hewlett-Packard HP HDX 16 Notebook PC
NonfreeKernelModules: nvidia
Package: linux-image-2.6.30-9-generic 2.6.30-9.10
ProcCmdLine: root=UUID=08a8ccd7-5a7b-4c2a-a9e8-c3c752d4764e ro quiet splash
ProcEnviron:
 PATH=(custom, user)
 LANG=en_GB.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.30-9.10-generic
RelatedPackageVersions: linux-backports-modules-2.6.30-9-generic N/A
SourcePackage: linux
Uname: Linux 2.6.30-9-generic x86_64
dmi.bios.date: 10/01/2008
dmi.bios.vendor: Hewlett-Packard
dmi.bios.version: F.04
dmi.board.asset.tag: Base Board Asset Tag
dmi.board.name: 361B
dmi.board.vendor: Quanta
dmi.board.version: 15.15
dmi.chassis.type: 10
dmi.chassis.vendor: Quanta
dmi.chassis.version: N/A
dmi.modalias: dmi:bvnHewlett-Packard:bvrF.04:bd10/01/2008:svnHewlett-Packard:pnHPHDX16NotebookPC:pvrF.04:rvnQuanta:rn361B:rvr15.15:cvnQuanta:ct10:cvrN/A:
dmi.product.name: HP HDX 16 Notebook PC
dmi.product.version: F.04
dmi.sys.vendor: Hewlett-Packard

Revision history for this message
Anand Kumria (wildfire) wrote :
Revision history for this message
Lord_neo (lord-neo) wrote :

i confirm this bug, that exist on my jaunty 9.04 with official kernel 2.6.28 on amd64 architecture.

summary: - AVerMedia A30 firmware not loaded after hibernate / resume cycle
+ AVerMedia A309 firmware not loaded after hibernate / resume cycle
Revision history for this message
Lord_neo (lord-neo) wrote :

sorry for double post.. I have an hp dv5 1140 el.

Revision history for this message
Ralf (ralf-kaestner) wrote : Re: AVerMedia A309 firmware not loaded after hibernate / resume cycle

the same problem does exist for other dvb cards like the nova T, reported by two ppl under bug #303667 as example.
The dvb_usb_dib0700 also errors out with (-2) after resume. You can easily fix that by a small quirk under /etc/pm/sleep.d

attached you can find one example I implemented for my dib0700 based card.

Apart from the quirk I did a bunch of debugging but was unable to locate why the firmware load fails after resume.
I suspect I has to do with udev still beeing suspended at that time or similar which prevents the firmware loader to load the firmware. I found that the same issue exists if you try to put the module and its firmware into the initramfs. Even if the FW is in there, it won't load it on boot but timeout instead - but finally when the system is up it does correctly load the fw on rmmod/modprobe.

Additionally there is a second issue with dvb_usb in general and that is that it makes use of request_firmware instead of request_firmware_nowait. This does cause the 60 second hang when the fw load fails after resume.

I'll attach my analysis for the dib0700 as well, I am sure the root cause must be in dvb_usb or even below, so it does not matter that the origin of this ticket was for another card.

Revision history for this message
Ralf (ralf-kaestner) wrote :
summary: - AVerMedia A309 firmware not loaded after hibernate / resume cycle
+ dvb_usb firmware does not load after hibernate / resume or within
+ initramfs for different hardware (e.g. af9015/AVerMedia A309 or
+ dib0700/hauppauge nova T)
Revision history for this message
Robert Hensing (rjhensing) wrote :

Still same problem here (kernel: Linux robert-laptop 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:05:01 UTC 2009 x86_64 GNU/Linux)

I can not unplug my AVerMedia A309 because it is built in to my acer aspire 6920G. I suppose many more users have dvb-usb devices built-in, making this bug more severe.

Revision history for this message
Robert Hensing (rjhensing) wrote :

There is a cyclic dependency.

The kernel tries to initialize all devices before resuming user space, but it can not do so for these DVB-USB cards (and possibily other devices?) because firmware has to be loaded through udev (userspace).

A fix would be to store the firmware in kernel memory before suspend. Then it is available when resuming, without depending on user space resume.
This is sufficient when the device was plugged in at suspend time. Otherwise, the firmware should be loaded after user space resume

I am not familiar with the linux kernel code itself, so I don't know how to implement the fix.

Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
MiC (mikjnb) wrote :

Same problem on Ubuntu 10.04 (2.6.32-23-generic #37-Ubuntu SMP Fri Jun 11 08:03:28 UTC 2010 x86_64 GNU/Linux).
I have an HP DV5-1120el.

Is there not any solution yet?

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.