]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - releases/6.6.26/spi-s3c64xx-remove-else-after-return.patch
Linux 6.6.26
[thirdparty/kernel/stable-queue.git] / releases / 6.6.26 / spi-s3c64xx-remove-else-after-return.patch
CommitLineData
ea78042b
SL
1From de161fe93de0b2e03c0bcca72523047e61185000 Mon Sep 17 00:00:00 2001
2From: Sasha Levin <sashal@kernel.org>
3Date: Wed, 7 Feb 2024 12:04:22 +0000
4Subject: spi: s3c64xx: remove else after return
5
6From: Tudor Ambarus <tudor.ambarus@linaro.org>
7
8[ Upstream commit 9d47e411f4d636519a8d26587928d34cf52c0c1f ]
9
10Else case is not needed after a return, remove it.
11
12Reviewed-by: Andi Shyti <andi.shyti@kernel.org>
13Reviewed-by: Sam Protsenko <semen.protsenko@linaro.org>
14Signed-off-by: Tudor Ambarus <tudor.ambarus@linaro.org>
15Link: https://lore.kernel.org/r/20240207120431.2766269-9-tudor.ambarus@linaro.org
16Signed-off-by: Mark Brown <broonie@kernel.org>
17Stable-dep-of: a3d3eab627bb ("spi: s3c64xx: Use DMA mode from fifo size")
18Signed-off-by: Sasha Levin <sashal@kernel.org>
19---
20 drivers/spi/spi-s3c64xx.c | 6 ++----
21 1 file changed, 2 insertions(+), 4 deletions(-)
22
23diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c
24index 1e519b1537e71..29e99410c9716 100644
25--- a/drivers/spi/spi-s3c64xx.c
26+++ b/drivers/spi/spi-s3c64xx.c
27@@ -406,12 +406,10 @@ static bool s3c64xx_spi_can_dma(struct spi_controller *host,
28 {
29 struct s3c64xx_spi_driver_data *sdd = spi_controller_get_devdata(host);
30
31- if (sdd->rx_dma.ch && sdd->tx_dma.ch) {
32+ if (sdd->rx_dma.ch && sdd->tx_dma.ch)
33 return xfer->len > FIFO_DEPTH(sdd);
34- } else {
35- return false;
36- }
37
38+ return false;
39 }
40
41 static int s3c64xx_enable_datapath(struct s3c64xx_spi_driver_data *sdd,
42--
432.43.0
44