[PATCH 27/36] RAS/AMD/ATL: remove conditional return with no effect

From: Sang-Heon Jeon

Date: Thu Jul 23 2026 - 15:07:28 EST


Both branches of the check return the same value, so the check has
no effect. Remove it and return the value directly.

This is the result of running the Coccinelle script from
scripts/coccinelle/misc/cond_return_no_effect.cocci.

Signed-off-by: Sang-Heon Jeon <ekffu200098@xxxxxxxxx>
---
drivers/ras/amd/atl/map.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/drivers/ras/amd/atl/map.c b/drivers/ras/amd/atl/map.c
index 24a05af747d5..4ec9333ef745 100644
--- a/drivers/ras/amd/atl/map.c
+++ b/drivers/ras/amd/atl/map.c
@@ -771,9 +771,5 @@ int get_address_map(struct addr_ctx *ctx)

dump_address_map(&ctx->map);

- ret = validate_address_map(ctx);
- if (ret)
- return ret;
-
- return ret;
+ return validate_address_map(ctx);
}
--
2.43.0