From: Juha Yrjola Date: Wed, 12 Apr 2006 03:42:25 +0000 (-0400) Subject: Input: ads7846 - use msleep() instead of udelay() in suspend X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=c4febb94dae915da4423b81c487eabed9cef5cba;p=linux-beck.git Input: ads7846 - use msleep() instead of udelay() in suspend Sometimes a polling loop had a hard time changing state without pre-emption enabled. Use msleep instead, it's better anyway. Signed-off-by: Juha Yrjola Signed-off-by: David Brownell Signed-off-by: Dmitry Torokhov --- diff --git a/drivers/input/touchscreen/ads7846.c b/drivers/input/touchscreen/ads7846.c index 8670cd13bd5d..bdec112e89c4 100644 --- a/drivers/input/touchscreen/ads7846.c +++ b/drivers/input/touchscreen/ads7846.c @@ -449,7 +449,7 @@ ads7846_suspend(struct spi_device *spi, pm_message_t message) while (ts->pendown || ts->pending) { spin_unlock_irqrestore(&ts->lock, flags); - udelay(10); + msleep(1); spin_lock_irqsave(&ts->lock, flags); } }