> Hi,
> 
> I have written a driver for a special PCI Card on
> Solaris 10, Dual Core 2,4 GHz.
> The application uses the driver via ioctl to get one
> byte from the PCI Card.
> I use ddi_getxx to read the registers of the PCI
> Card, locked with mutex_enter
> and mutex_exit.
> Between ioctl_entry and ioctl_return (within my
> ioctl-function) the driver must run without
> interruptions (the PCI Card itself don't use
> interrupts) by other threads, process, interrupts,
> timers or other kernel code.
> How can I do this? (runtime of the ioctl function is
> about 3-4 microseconds)
> 
> Any ideas are welcome...

Use the old Commodore Amiga trick with CIA chips:

read the first byte, then read the second byte in, then reread the first byte 
again. If the first byte is still the same, you should be golden. This 
technique works particularly well for latch registers.
 
 
This message posted from opensolaris.org
_______________________________________________
opensolaris-discuss mailing list
[email protected]

Reply via email to