1 From 497acc03cd3918baabe25d46e30c5c62b998e24d Mon Sep 17 00:00:00 2001
2 From: Aleksander Jan Bajkowski <olek2@wp.pl>
3 Date: Sat, 19 Jun 2021 13:38:12 +0200
4 Subject: [PATCH 1/5] MIPS: lantiq: dma: add small delay after reset
6 Reading the DMA registers immediately after the reset causes
7 Data Bus Error. Adding a small delay fixes this problem.
9 Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
11 arch/mips/lantiq/xway/dma.c | 3 +++
12 1 file changed, 3 insertions(+)
14 --- a/arch/mips/lantiq/xway/dma.c
15 +++ b/arch/mips/lantiq/xway/dma.c
17 #include <linux/export.h>
18 #include <linux/spinlock.h>
19 #include <linux/clk.h>
20 +#include <linux/delay.h>
21 #include <linux/err.h>
23 #include <lantiq_soc.h>
24 @@ -221,6 +222,8 @@ ltq_dma_init(struct platform_device *pde
26 ltq_dma_w32_mask(0, DMA_RESET, LTQ_DMA_CTRL);
28 + usleep_range(1, 10);
30 /* disable all interrupts */
31 ltq_dma_w32(0, LTQ_DMA_IRNEN);