Re: PCI device initialization.

From: Jeff Garzik (jgarzik@mandrakesoft.com)
Date: Thu Mar 30 2000 - 16:37:36 EST


Martin Mares wrote:
>
> Hello!
>
> > The sound card has a register to enable the joystick port so I need to know
> > where the sound card IO ports begin (and maybe to make use of a spinlock that
> > serializes hardware registers access).
>
> If you don't need to serialize the accesses, it should be sufficient to
> lookup the sound card device from the joystick driver and don't touch the sound
> card driver at all.

All pci_{read,write}_config_xxx calls are serialized through a global
PCI spinlock... if enabling the joystick port is simply a matter of PCI
config register updates, just update away with minimal consideration for
what the sound driver is doing...

-- 
Jeff Garzik              | Tact is the ability to tell a man 
Building 1024            | he has an open mind when he has a
MandrakeSoft, Inc.       | hole in his head.  (-random fortune)

- 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/



This archive was generated by hypermail 2b29 : Fri Mar 31 2000 - 21:00:27 EST