|
|
|
|
|
|
|
|
|
|
xen-devel
Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems
On Sat, 2009-01-24 at 16:59 -0800, Jeremy Fitzhardinge wrote:
> Pasi Kärkkäinen wrote:
> > rc = devm_request_irq(dev, ATA_PRIMARY_IRQ(pdev), irq_handler, IRQF_SHARED,
> > drv_name, host);
> > if (rc)
> > goto out;
> >
> > and ports names never get assigned because that "goto out;" is executed.
> >
> > So.. Any ideas why devm_request_irq() fails?
>
>
> Good question. Will need to pick through
>
> Hm, wonder if its something to do with the handling of the legacy irqs:
>
> ata_pci_sff_activate_host: pci_read_config_byte()
> ata_pci_sff_activate_host: if (!devres_open_group(dev, NULL, GFP_KERNEL))
> ata_pci_sff_activate_host: if (!legacy_mode && pdev->irq)
> ata_pci_sff_activate_host: legacy_mode
> ata_pci_sff_activate_host: port 0 not dummy: devm_request_irq()
> ata_pci_sff_activate_host: non-legacy-mode irq: 30
> ata_pci_sff_activate_host: requesting ATA_PRIMARY_IRQ(pdev) irq: 14
> ata_pci_sff_activate_host: devm_request_irq() returned != 0, goto out
I see a similar failure to allocate IRQ 14 although in my case some
other driver comes along and makes it work so I hadn't noticed until
just now.
In my case request_irq() was being called direct rather than via
devm_request_irq and the return was -ENOSYS (it'd be interesting to know
what != 0 value was seen here). I followed this down to __setup_irq()
which has:
if (desc->chip == &no_irq_chip)
return -ENOSYS;
So it looks like something expects there to already be a chip present
for the legacy IRQ. For non-legacy IRQs I think we setup the chip
through xen_pci_pirq_enable() -> xen_register_gsi() ->
xen_allocate_pirq() -> set_irq_chip_and_handler_name(). Perhaps legacy
IRQs do not (always) get explicitly enabled?
This little hack made things work for me. Possibly the correct fix might
be to use xen_register_gsi() here instead of xen_allocate_pirq() and get
rid of the special case for IRQ 14 and 15 in xen_pci_pirq_enable().
Maybe only 14 and 15 need this special treatment.
--- a/arch/x86/xen/pci.c Fri Jan 30 17:39:54 2009 +0000
+++ b/arch/x86/xen/pci.c Fri Jan 30 18:08:36 2009 +0000
@@ -133,4 +133,7 @@
/* Blerk. */
acpi_gbl_FADT.sci_interrupt = irq;
#endif
+
+ for (irq = 0 ; irq < 16 ; irq ++)
+ xen_allocate_pirq(irq);
}
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread>
|
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, (continued)
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Jeremy Fitzhardinge
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Jeremy Fitzhardinge
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Jeremy Fitzhardinge
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems,
Ian Campbell <=
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Ian Campbell
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Jeremy Fitzhardinge
- [Xen-devel] Attempt to compile 2.6.29-rc3 with pv_ops suppot for Dom0, Boris Derzhavets
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Gerd Hoffmann
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Christophe Saout
- Re: [Xen-devel] pv_ops dom0 kernel failure with ata_piix / irq problems, Pasi Kärkkäinen
|
|
|
|
|