[PATCH 5/6] drm/simpledrm: Remove redundant else in atomic_check

Aditya Garg posted 6 patches 11 months, 2 weeks ago
[PATCH 5/6] drm/simpledrm: Remove redundant else in atomic_check
Posted by Aditya Garg 11 months, 2 weeks ago
From: Aditya Garg <gargaditya08@live.com>

Remove the redundant else statement from atomic_check since the previous if
statement was returning if true.

Signed-off-by: Aditya Garg <gargaditya08@live.com>
---
 drivers/gpu/drm/tiny/simpledrm.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/tiny/simpledrm.c b/drivers/gpu/drm/tiny/simpledrm.c
index 5d9ab8adf..1c20d4c49 100644
--- a/drivers/gpu/drm/tiny/simpledrm.c
+++ b/drivers/gpu/drm/tiny/simpledrm.c
@@ -602,7 +602,8 @@ static int simpledrm_primary_plane_helper_atomic_check(struct drm_plane *plane,
 						  false, false);
 	if (ret)
 		return ret;
-	else if (!new_plane_state->visible)
+
+	if (!new_plane_state->visible)
 		return 0;
 
 	if (new_fb->format != sdev->format) {
-- 
2.43.0