Skip to contentSkip to conversation

dom0 kernel fails to recognize DVD drive on piix controller

DISCUSSION Olaf Hering 3 participants 8 messages Apr 21, 2016

lore
Share & tools
lore
#0 lore raw

On my Fujitsu Esprimo Mobile M9400 laptop the upstream dom0 kernel does not find the DVD drive. The DVD drive is found with native kernels and also with xenlinux based kernels, like 4.1 based openSUSE Leap.

[    6.242286] ata_piix 0000:00:1f.1: version 2.13
[    6.242625] xen: registering gsi 19 triggering 0 polarity 1
[    6.242635] Already setup the GSI :19
[    6.250792] ata_piix: probe of 0000:00:1f.1 failed with error -22

After some investigation it turned out that irq_to_desc() returns nothing for the piix PCI device, as a result EINVAL is returned. The callchain is like:
piix_init_one
ata_pci_sff_activate_host (legacy_mode case)
devm_request_threaded_irq
irq_to_desc

This happens with 4.4, 4.5 and 4.6 based dom0 kernels.

Any idea whats happening here, where to look further?

I'm attaching a collection of logfiles, like dmesg, lspci and the used debug patch, along with the used .config for the dom0 kernel.

Thanks,

Olaf

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#1 lore raw
Quoted 18 lines
Quoted 1 line
Quoted 1 line · On 21.04.16 at 11:37, <[email protected]> wrote:

On my Fujitsu Esprimo Mobile M9400 laptop the upstream dom0 kernel does not find the DVD drive. The DVD drive is found with native kernels and also with xenlinux based kernels, like 4.1 based openSUSE Leap.

[    6.242286] ata_piix 0000:00:1f.1: version 2.13
[    6.242625] xen: registering gsi 19 triggering 0 polarity 1
[    6.242635] Already setup the GSI :19
[    6.250792] ata_piix: probe of 0000:00:1f.1 failed with error -22

After some investigation it turned out that irq_to_desc() returns nothing for the piix PCI device, as a result EINVAL is returned. The callchain is like:
piix_init_one
ata_pci_sff_activate_host (legacy_mode case)
devm_request_threaded_irq
irq_to_desc

Quoted 3 lines

This happens with 4.4, 4.5 and 4.6 based dom0 kernels.

Any idea whats happening here, where to look further?

Does the device actually use IRQ19, or does it instead use IRQ14 and IRQ15 (which then may require some special casing somewhere)?

Jan

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#2 lore raw
Quoted 2 lines · Jan Beulich

Does the device actually use IRQ19, or does it instead use IRQ14 and IRQ15 (which then may require some special casing somewhere)?

How do I find out?

Olaf

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#6 lore raw
In reply to Olaf Hering
Quoted 17 lines · Olaf Hering

On my Fujitsu Esprimo Mobile M9400 laptop the upstream dom0 kernel does not find the DVD drive. The DVD drive is found with native kernels and also with xenlinux based kernels, like 4.1 based openSUSE Leap.

[    6.242286] ata_piix 0000:00:1f.1: version 2.13
[    6.242625] xen: registering gsi 19 triggering 0 polarity 1
[    6.242635] Already setup the GSI :19
[    6.250792] ata_piix: probe of 0000:00:1f.1 failed with error -22

After some investigation it turned out that irq_to_desc() returns nothing for the piix PCI device, as a result EINVAL is returned. The callchain is like:
piix_init_one
ata_pci_sff_activate_host (legacy_mode case)
devm_request_threaded_irq
irq_to_desc

Quoted 3 lines

This happens with 4.4, 4.5 and 4.6 based dom0 kernels.

Any idea whats happening here, where to look further?

You might want to test Stefano's patch trying to fix a similar issue:

http://lists.xen.org/archives/html/xen-devel/2016-04/msg02512.html

Juergen

Quoted 6 lines

I'm attaching a collection of logfiles, like dmesg, lspci and the used debug patch, along with the used .config for the dom0 kernel.

Thanks,

Quoted 9 lines

Olaf

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#4 lore raw
Quoted 9 lines · Jan Beulich
Quoted 7 lines
Quoted 1 line
Quoted 1 line · On 21.04.16 at 11:52, <[email protected]> wrote:
Quoted 2 lines · Jan Beulich

Does the device actually use IRQ19, or does it instead use IRQ14 and IRQ15 (which then may require some special casing somewhere)?

How do I find out?

Check what the native kernel uses.

Yeah, silly question. Sorry.

Its indeed 14/15:

 14:        139        115   IO-APIC  14-edge      ata_piix
 15:          0          0   IO-APIC  15-edge      ata_piix

So does that special handling have to be done in Xen or in dom0?

Olaf

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#5 lore raw
Quoted 13 lines
Quoted 1 line
Quoted 1 line · On 21.04.16 at 12:35, <[email protected]> wrote:
Quoted 9 lines · Jan Beulich
Quoted 7 lines
Quoted 1 line
Quoted 1 line · On 21.04.16 at 11:52, <[email protected]> wrote:
Quoted 2 lines · Jan Beulich

Does the device actually use IRQ19, or does it instead use IRQ14 and IRQ15 (which then may require some special casing somewhere)?

How do I find out?

Check what the native kernel uses.

Quoted 7 lines

Yeah, silly question. Sorry.

Its indeed 14/15:

 14:        139        115   IO-APIC  14-edge      ata_piix
 15:          0          0   IO-APIC  15-edge      ata_piix

So does that special handling have to be done in Xen or in dom0?

In Dom0 I would guess - Xen can't do anything about Dom0's understanding of interrupts, and from the looks of it Dom0 only sets up IRQ19 here, ignoring the two legacy interrupts.

Jan

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel