Subject: Grrr: Small delays
To: None <>
From: David S. Miller <>
List: port-sun3
Date: 08/14/1995 13:19:41
   From: David Jones <>
   Date: 	Mon, 14 Aug 1995 12:23:11 -0400

   Is there a standard way of delaying for less than 1 us in the kernel?


    while (req not true)

   This works, but gives you lousy transfer rates.  I'd like to do something

   while (req not true)


   The ncr5380 code is going to be universally portable, so for now I'm sticking
   to delay().

   Any ideas?  Of course this is not so much a problem once I get DMA going...

Is not the 'hz' variable available to your routines?  At boot time you
could use it to calculate delay constants for the driver, perhaps
implement a delay200ns() macro which will use this driver constant in
a decrementing loop to get the accuracy you are looking for.

David S. Miller