[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <2abd0da35608c14689a919d47dd45898a8ab4297.1635263478.git.geert@linux-m68k.org>
Date: Tue, 26 Oct 2021 17:56:07 +0200
From: Geert Uytterhoeven <geert@...ux-m68k.org>
To: Eugeniy Paltsev <Eugeniy.Paltsev@...opsys.com>,
Vinod Koul <vkoul@...nel.org>
Cc: dmaengine@...r.kernel.org, linux-kernel@...r.kernel.org,
Geert Uytterhoeven <geert@...ux-m68k.org>
Subject: [PATCH] dmaengine: dw-axi-dmac: Simplify assignment in dma_chan_pause()
Simplify assigning zero and performing a logical OR to a single
assignment.
Signed-off-by: Geert Uytterhoeven <geert@...ux-m68k.org>
---
drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c b/drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c
index e8c98b16ae991a59..b907f3acf5c1f31e 100644
--- a/drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c
+++ b/drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c
@@ -1191,9 +1191,8 @@ static int dma_chan_pause(struct dma_chan *dchan)
BIT(chan->id) << DMAC_CHAN_SUSP_WE_SHIFT;
axi_dma_iowrite32(chan->chip, DMAC_CHEN, val);
} else {
- val = 0;
- val |= BIT(chan->id) << DMAC_CHAN_SUSP2_SHIFT |
- BIT(chan->id) << DMAC_CHAN_SUSP2_WE_SHIFT;
+ val = BIT(chan->id) << DMAC_CHAN_SUSP2_SHIFT |
+ BIT(chan->id) << DMAC_CHAN_SUSP2_WE_SHIFT;
axi_dma_iowrite32(chan->chip, DMAC_CHSUSPREG, val);
}
--
2.25.1
Powered by blists - more mailing lists