Skip to contentSkip to conversation

net/mlx5: Fill out devlink dev info only for PFs

PATCH RESEND Applied Tariq Toukan 3 participants 3 messages Mar 6, 2025 – Mar 8, 2025

Subsystems (4)
lore
Share & tools
lore

Tariq Toukan

author maintainer
#0 lore raw

PATCH RESEND 1/1 net/mlx5: Fill out devlink dev info only for PFs

From: Jiri Pirko <[email protected]>

Firmware version query is supported on the PFs. Due to this following kernel warning log is observed:

[  188.590344] mlx5_core 0000:08:00.2: mlx5_fw_version_query:816:(pid 1453): fw query isn't supported by the FW

Fix it by restricting the query and devlink info to the PF.

Fixes 8338d9378895 ("net/mlx5: Added devlink info callback")
---
 drivers/net/ethernet/mellanox/mlx5/core/devlink.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/net/ethernet/mellanox/mlx5/core/devlink.c +3 -0
index 98d4306929f3..a2cf3e79693d 100644
@@ -46,6 +46,9 @@ mlx5_devlink_info_get(struct devlink *devlink, struct devlink_info_req *req,
 	u32 running_fw, stored_fw;
 	int err;
 
+	if (!mlx5_core_is_pf(dev))
+		return 0;
+
 	err = devlink_info_version_fixed_put(req, "fw.psid", dev->board_id);
 	if (err)
 		return err;
Signature · 1 line
2.45.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 11 lines

From: Tariq Toukan <[email protected]>
Sent: Friday, March 7, 2025 2:55 AM

From: Jiri Pirko <[email protected]>

Firmware version query is supported on the PFs. Due to this following kernel warning log is observed:

[  188.590344] mlx5_core 0000:08:00.2: mlx5_fw_version_query:816:(pid
Quoted 8 lines

1453): fw query isn't supported by the FW

Fix it by restricting the query and devlink info to the PF.

Fixes 8338d9378895 ("net/mlx5: Added devlink info callback")
Quoted 23 lines
---
 drivers/net/ethernet/mellanox/mlx5/core/devlink.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/net/ethernet/mellanox/mlx5/core/devlink.c +3 -0
index 98d4306929f3..a2cf3e79693d 100644
@@ -46,6 +46,9 @@ mlx5_devlink_info_get(struct devlink *devlink, struct
 devlink_info_req *req,
 	u32 running_fw, stored_fw;
 	int err;
 
+	if (!mlx5_core_is_pf(dev))
+		return 0;
+
 	err = devlink_info_version_fixed_put(req, "fw.psid", dev->board_id);
 	if (err)

return err;
--
2.45.0

#2 lore raw
In reply to Tariq Toukan
This patch was applied to netdev/net.git (main) by Jakub Kicinski <[email protected]>:

Hello:

This patch was applied to netdev/net.git (main)
by Jakub Kicinski <[email protected]>:

Quoted 8 lines · On Thu, 6 Mar 2025 23:25:29 +0200 you wrote:

From: Jiri Pirko <[email protected]>

Firmware version query is supported on the PFs. Due to this following kernel warning log is observed:

[  188.590344] mlx5_core 0000:08:00.2: mlx5_fw_version_query:816:(pid 1453): fw query isn't supported by the FW

[...]

Here is the summary with links:
- [net,RESEND] net/mlx5: Fill out devlink dev info only for PFs

    https://git.kernel.org/netdev/net/c/d749d901b216

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html