diff options
author | Kamal Heib <kheib@redhat.com> | 2024-06-17 13:23:27 -0400 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-06-18 18:19:18 -0700 |
commit | e52e010395dc5232f7dd5c271367f4bdd18ab74c (patch) | |
tree | 08a38c2b71ffc2f989faaceec7859d4ce10b8b32 | |
parent | 8c379e3ce404347acf35fbb4cf8694dd8d35f2a0 (diff) |
net/mlx4_en: Use ethtool_puts to fill priv flags strings
Use the ethtool_puts helper to print the priv flags strings into the
ethtool strings interface.
Signed-off-by: Kamal Heib <kheib@redhat.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://lore.kernel.org/r/20240617172329.239819-2-kheib@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx4/en_ethtool.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx4/en_ethtool.c b/drivers/net/ethernet/mellanox/mlx4/en_ethtool.c index 619e1c3ef7f9..50a4a017a3f4 100644 --- a/drivers/net/ethernet/mellanox/mlx4/en_ethtool.c +++ b/drivers/net/ethernet/mellanox/mlx4/en_ethtool.c @@ -536,8 +536,7 @@ static void mlx4_en_get_strings(struct net_device *dev, break; case ETH_SS_PRIV_FLAGS: for (i = 0; i < ARRAY_SIZE(mlx4_en_priv_flags); i++) - strcpy(data + i * ETH_GSTRING_LEN, - mlx4_en_priv_flags[i]); + ethtool_puts(&data, mlx4_en_priv_flags[i]); break; } |