From mboxrd@z Thu Jan 1 00:00:00 1970 From: linus.walleij@linaro.org (Linus Walleij) Date: Thu, 19 May 2011 20:06:32 +0200 Subject: [PATCH 1/2] spi/pl022: timeout on polled transfer v2 In-Reply-To: References: <1305821134-26147-1-git-send-email-linus.walleij@stericsson.com> Message-ID: To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org 2011/5/19 Vitaly Wool : > On Thu, May 19, 2011 at 7:36 PM, Linus Walleij wrote: >>> >>> just out of curiosity: is it a busy wait? Looks like it is... >> >> Yep that's the polling mode part. IRQ and DMA mode should >> be the norm I guess. >> >> Magnus: do you have a specific use case for this thing? > > Well, adding cpu_relax() somewhere in the loop might be not a bad idea... OK sent a patch for it, and Grant applied it within something like 30 seconds :-) I think on ARM that just boils down to a barrier() so it basically injects air in the pipeline when busywaiting, I never understood what that is good for, but it's a good marker anyway. Linus Walleij