lkml.org 
[lkml]   [2015]   [Sep]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: spi-imx: wait_for_completion should timeout even in non-DMA transfer cases
On Mon, Sep 21, 2015 at 11:08:55AM +0200, Jean-Michel Hautbois wrote:
> 2015-09-19 19:56 GMT+02:00 Mark Brown <broonie@kernel.org>:

> > A calculated timeout is probably best.

> Well, it depends...
> If you have a 20MHz clock, then you can transfer a byte in 4µs.
> As most of the time pio_transfer is used for 8 to 32 bytes max, it
> would be irrelevant to use such a small timeout.
> I can obviously do it, but not sure if using a small (say, 100ms)
> timeout would not be better.

You want a minimum threashold, yes, but you also need to be able toc ope
with larger transfers too so need to be able to raise that where
appropriate.
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2015-09-22 19:41    [W:0.225 / U:0.080 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site