diff options
Diffstat (limited to 'arch/arm/mach-tegra/apbio.c')
-rw-r--r-- | arch/arm/mach-tegra/apbio.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/arch/arm/mach-tegra/apbio.c b/arch/arm/mach-tegra/apbio.c index d6e08c966e72..2d83ae3a51c2 100644 --- a/arch/arm/mach-tegra/apbio.c +++ b/arch/arm/mach-tegra/apbio.c @@ -66,10 +66,12 @@ static inline u32 apb_readl(unsigned long offset) tegra_dma_enqueue_req(tegra_apb_dma, &req); ret = wait_for_completion_timeout(&tegra_apb_wait, - msecs_to_jiffies(50)); + msecs_to_jiffies(400)); - if (WARN(ret == 0, "apb read dma timed out")) + if (WARN(ret == 0, "apb read dma timed out")) { + tegra_dma_dequeue_req(tegra_apb_dma, &req); *(u32 *)tegra_apb_bb = 0; + } mutex_unlock(&tegra_apb_dma_lock); return *((u32 *)tegra_apb_bb); @@ -103,7 +105,10 @@ static inline void apb_writel(u32 value, unsigned long offset) tegra_dma_enqueue_req(tegra_apb_dma, &req); ret = wait_for_completion_timeout(&tegra_apb_wait, - msecs_to_jiffies(50)); + msecs_to_jiffies(400)); + + if (WARN(ret == 0, "apb write dma timed out")) + tegra_dma_dequeue_req(tegra_apb_dma, &req); mutex_unlock(&tegra_apb_dma_lock); } |