diff options
Diffstat (limited to 'arch/arm/plat-mxc/sdma/sdma.c')
-rw-r--r-- | arch/arm/plat-mxc/sdma/sdma.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/arch/arm/plat-mxc/sdma/sdma.c b/arch/arm/plat-mxc/sdma/sdma.c index 8a9e8e7faf48..7b3d7ae92eb8 100644 --- a/arch/arm/plat-mxc/sdma/sdma.c +++ b/arch/arm/plat-mxc/sdma/sdma.c @@ -134,9 +134,13 @@ static void sdma_init_sleep(int channel) static void sdma_sleep_channel(int channel) { while ((iapi_SDMAIntr & (1 << channel)) == 0) { - wait_event_interruptible(sdma_sleep_queue[channel], - ((iapi_SDMAIntr & (1 << channel)) != - 0)); + int timeout = 10; /* timeout 10ms */ + timeout = wait_event_interruptible_timeout( + sdma_sleep_queue[channel], + ((iapi_SDMAIntr & (1 << channel)) != + 0), timeout); + if (!timeout) + printk(KERN_WARNING "sdma channel timeout\n"); } } |