d069778b2dac204e43dea10d5ea574165764784d
[openwrt/staging/pepe2k.git] /
1 From 4176c964cd42c43d90fc1b60ff8266613462ebe8 Mon Sep 17 00:00:00 2001
2 From: Maxime Ripard <maxime@cerno.tech>
3 Date: Thu, 13 Apr 2023 16:44:21 +0200
4 Subject: [PATCH] dmaengine: bcm2835: Use to_bcm2711_cbaddr where
5 relevant
6
7 bcm2711_dma40_memcpy has some code strictly equivalent to the
8 to_bcm2711_cbaddr() function. Let's use it instead.
9
10 Signed-off-by: Maxime Ripard <maxime@cerno.tech>
11 ---
12 drivers/dma/bcm2835-dma.c | 2 +-
13 1 file changed, 1 insertion(+), 1 deletion(-)
14
15 --- a/drivers/dma/bcm2835-dma.c
16 +++ b/drivers/dma/bcm2835-dma.c
17 @@ -1149,7 +1149,7 @@ void bcm2711_dma40_memcpy(dma_addr_t dst
18 scb->len = size;
19 scb->next_cb = 0;
20
21 - writel((u32)(memcpy_scb_dma >> 5), memcpy_chan + BCM2711_DMA40_CB);
22 + writel(to_bcm2711_cbaddr(memcpy_scb_dma), memcpy_chan + BCM2711_DMA40_CB);
23 writel(BCM2711_DMA40_MEMCPY_FLAGS + BCM2711_DMA40_ACTIVE,
24 memcpy_chan + BCM2711_DMA40_CS);
25