]> git.hungrycats.org Git - linux/commit
net/mlx5e: CT: Fix ct debugfs folder name
authorChris Mi <cmi@nvidia.com>
Mon, 28 Nov 2022 05:54:29 +0000 (13:54 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 12 Jan 2023 11:00:35 +0000 (12:00 +0100)
commit4b30987ddcd67d7d1129c3fdadf978df185d2c3d
tree3b2d7b0b8a93f290779a181b5efbf5d583946bc7
parentd0fe3d9e5f70b95f663704e51d4590926d0c9f49
net/mlx5e: CT: Fix ct debugfs folder name

[ Upstream commit 849190e3e4ccf452fbe2240eace30a9ca83fb8d2 ]

Need to use sprintf to build a string instead of sscanf. Otherwise
dirname is null and both "ct_nic" and "ct_fdb" won't be created.
But its redundant anyway as driver could be in switchdev mode but
still add nic rules. So use "ct" as folder name.

Fixes: 77422a8f6f61 ("net/mlx5e: CT: Add ct driver counters")
Signed-off-by: Chris Mi <cmi@nvidia.com>
Reviewed-by: Roi Dayan <roid@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/en/tc_ct.c