summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--drivers/ras/amd/atl/denormalize.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ras/amd/atl/denormalize.c b/drivers/ras/amd/atl/denormalize.c
index d5d0e1fda159..49a900e066f1 100644
--- a/drivers/ras/amd/atl/denormalize.c
+++ b/drivers/ras/amd/atl/denormalize.c
@@ -405,7 +405,7 @@ static const u16 phy_to_log_coh_st_map_mi300[] = {
static u16 get_logical_coh_st_fabric_id_mi300(struct addr_ctx *ctx)
{
- if (ctx->inst_id >= sizeof(phy_to_log_coh_st_map_mi300)) {
+ if (ctx->inst_id >= ARRAY_SIZE(phy_to_log_coh_st_map_mi300)) {
atl_debug(ctx, "Instance ID out of range");
return ~0;
}