[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230623100822.274706-5-sui.jingfeng@linux.dev>
Date: Fri, 23 Jun 2023 18:08:18 +0800
From: Sui Jingfeng <sui.jingfeng@...ux.dev>
To: Lucas Stach <l.stach@...gutronix.de>,
Russell King <linux+etnaviv@...linux.org.uk>,
Christian Gmeiner <christian.gmeiner@...il.com>,
David Airlie <airlied@...il.com>,
Daniel Vetter <daniel@...ll.ch>
Cc: etnaviv@...ts.freedesktop.org, dri-devel@...ts.freedesktop.org,
linux-kernel@...r.kernel.org, loongson-kernel@...ts.loongnix.cn,
Sui Jingfeng <suijingfeng@...ngson.cn>
Subject: [PATCH v1 4/8] drm/etnaviv: Remove surplus else after return
From: Sui Jingfeng <suijingfeng@...ngson.cn>
Because the 'else' is not generally useful after the 'return'.
Signed-off-by: Sui Jingfeng <suijingfeng@...ngson.cn>
---
drivers/gpu/drm/etnaviv/etnaviv_gem.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gem.c b/drivers/gpu/drm/etnaviv/etnaviv_gem.c
index be2f459c66b5..271470723d5e 100644
--- a/drivers/gpu/drm/etnaviv/etnaviv_gem.c
+++ b/drivers/gpu/drm/etnaviv/etnaviv_gem.c
@@ -358,10 +358,11 @@ static inline enum dma_data_direction etnaviv_op_to_dma_dir(u32 op)
{
if (op & ETNA_PREP_READ)
return DMA_FROM_DEVICE;
- else if (op & ETNA_PREP_WRITE)
+
+ if (op & ETNA_PREP_WRITE)
return DMA_TO_DEVICE;
- else
- return DMA_BIDIRECTIONAL;
+
+ return DMA_BIDIRECTIONAL;
}
int etnaviv_gem_cpu_prep(struct drm_gem_object *obj, u32 op,
--
2.25.1
Powered by blists - more mailing lists