Skip to content

Commit ac8082a

Browse files
ayalevinSaeed Mahameed
authored andcommitted
net/mlx5: Fix fw reporter diagnose output
Restore fw reporter diagnose to print the syndrome even if it is zero. Following the cited commit, in this case (syndrome == 0) command returns no output at all. This fix restores command output in case syndrome is cleared: $ devlink health diagnose pci/0000:82:00.0 reporter fw Syndrome: 0 Fixes: d17f98b ("net/mlx5: devlink health: use retained error fmsg API") Signed-off-by: Aya Levin <[email protected]> Reviewed-by: Moshe Shemesh <[email protected]> Signed-off-by: Saeed Mahameed <[email protected]>
1 parent 85ea2c5 commit ac8082a

File tree

1 file changed

+1
-1
lines changed
  • drivers/net/ethernet/mellanox/mlx5/core

1 file changed

+1
-1
lines changed

drivers/net/ethernet/mellanox/mlx5/core/health.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -452,10 +452,10 @@ mlx5_fw_reporter_diagnose(struct devlink_health_reporter *reporter,
452452
struct health_buffer __iomem *h = health->health;
453453
u8 synd = ioread8(&h->synd);
454454

455+
devlink_fmsg_u8_pair_put(fmsg, "Syndrome", synd);
455456
if (!synd)
456457
return 0;
457458

458-
devlink_fmsg_u8_pair_put(fmsg, "Syndrome", synd);
459459
devlink_fmsg_string_pair_put(fmsg, "Description", hsynd_str(synd));
460460

461461
return 0;

0 commit comments

Comments
 (0)