Re: high max-latency times?

From: David S. Miller (davem@redhat.com)
Date: Tue May 16 2000 - 15:27:04 EST


   Date: Tue, 16 May 2000 15:57:20 -0400
   From: Jeff Garzik <jgarzik@mandrakesoft.com>

   Under 2.3.x, the pci_set_master/pci_enable_device functions often
   sets the latency higher than the "max latency" value. This sounds
   wrong... is it?

In fact, it's dead wrong. The max latency value specifies the latency
which the PCI device can tolerate, ie. the maximum PCI clocks it can
handle not having the bus, without dropping data (such as dropping a
receive packet on a network card) or similar.

This means if you're going to use these values, you'd need to scan the
"min grant" and "max latency" values of all PCI devices on the same
bus segment, and using that you can calculate a suitable latency timer
value for a particular device.

Also, the max latency value is not specified in PCI clocks in the PCI
config space register, it uses some other ratio of some sort, I'd have
to check the PCI standard.

Finally, for the "min grant" value, I've seen loads of cards not set
this value correctly.

Essentially this is major PCI voodoo programming territory.

Later,
David S. Miller
davem@redhat.com

-
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 : Tue May 23 2000 - 21:00:11 EST