[PATCH V2] spi: bcm2835: enabling polling mode for transfers shorter than 30us

Martin Sperl kernel at martin.sperl.org
Sat Apr 18 05:13:56 PDT 2015


> On 18.04.2015, at 13:53, Mark Brown <broonie at kernel.org> wrote:
> 
> As I've said several times now 1s seems far too long for a busy wait,
> the driver should fall back to something that sleeps after an initial
> busy wait (once it's clear we're over time).
Then I have misread what you wrote - I understood you wanted to avoid
having no timeout at all.

So you want something like:
* wait for 4 jiffies (which is 40ms typically)
* if we exceed that, then enable interrupts for the rest of the transfer
and let the 30s timeout handle everything else

Martin



More information about the linux-rpi-kernel mailing list