Skip to content

Commit ba4939f

Browse files
vadimp-nvidiajwrdegoede
authored andcommitted
platform/x86: mlx-platform: Fix item counter assignment for MSN2700, MSN24xx systems
Fix array names to match assignments for data items and data items counter in 'mlxplat_mlxcpld_default_items' structure for: .data = mlxplat_mlxcpld_default_pwr_items_data, .count = ARRAY_SIZE(mlxplat_mlxcpld_pwr), and .data = mlxplat_mlxcpld_default_fan_items_data, .count = ARRAY_SIZE(mlxplat_mlxcpld_fan), Replace: - 'mlxplat_mlxcpld_pwr' by 'mlxplat_mlxcpld_default_pwr_items_data' for ARRAY_SIZE() calculation. - 'mlxplat_mlxcpld_fan' by 'mlxplat_mlxcpld_default_fan_items_data' for ARRAY_SIZE() calculation. Fixes: c6acad6 ("platform/mellanox: mlxreg-hotplug: Modify to use a regmap interface") Signed-off-by: Vadim Pasternak <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Hans de Goede <[email protected]>
1 parent 5e27cb9 commit ba4939f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/platform/x86/mlx-platform.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ static struct mlxreg_core_item mlxplat_mlxcpld_default_items[] = {
456456
.aggr_mask = MLXPLAT_CPLD_AGGR_PWR_MASK_DEF,
457457
.reg = MLXPLAT_CPLD_LPC_REG_PWR_OFFSET,
458458
.mask = MLXPLAT_CPLD_PWR_MASK,
459-
.count = ARRAY_SIZE(mlxplat_mlxcpld_pwr),
459+
.count = ARRAY_SIZE(mlxplat_mlxcpld_default_pwr_items_data),
460460
.inversed = 0,
461461
.health = false,
462462
},
@@ -465,7 +465,7 @@ static struct mlxreg_core_item mlxplat_mlxcpld_default_items[] = {
465465
.aggr_mask = MLXPLAT_CPLD_AGGR_FAN_MASK_DEF,
466466
.reg = MLXPLAT_CPLD_LPC_REG_FAN_OFFSET,
467467
.mask = MLXPLAT_CPLD_FAN_MASK,
468-
.count = ARRAY_SIZE(mlxplat_mlxcpld_fan),
468+
.count = ARRAY_SIZE(mlxplat_mlxcpld_default_fan_items_data),
469469
.inversed = 1,
470470
.health = false,
471471
},

0 commit comments

Comments
 (0)