Re: PCI IRQ initialisation in pci.c

Martin Mares (mj@ucw.cz)
Wed, 4 Aug 1999 20:11:31 +0200


Hi,

> How about this:
>
> Providing the PCI registers are only modified by the kernel or
> drivers, why not get pci_write_*() to update pci_dev if it modifies
> anything it has "cached"? (perhaps only irq and base registers).

Actually, the base address and interrupt line values stored in struct
pci_dev are not a mere cache and exist just because on many architectures
they differ from what is written in the registers (the bus addresses
and physical addresses as seen by the processor may be different; the
IRQ number can be too large to fit in a 8-bit register and so on).

> You already responded to it. It was the problem with enabling USB
> on a Toshiba 7020CT causing a permanent spurious interrupt to occur.
> By redirecting a particular pci pin to an unused irq, the problem
> disappears. Unfortunately that pin is used by the IR driver and doesn't
> work after the setpci since the driver picks up the irq as it was
> initially instead of what it is when toshoboe is loaded.

Now I remember :-)

I'll write the patch for manual setting of kernel base address
and IRQ fields.

Have a nice fortnight

-- 
Martin `MJ' Mares   <mj@ucw.cz>   http://atrey.karlin.mff.cuni.cz/~mj/
Faculty of Math and Physics, Charles University, Prague, Czech Rep., Earth
"Lisp Users: Due to the holiday, there will be no garbage collection on Monday."

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/