s390/qeth: use ethtool_sprintf()

Use a recently introduced helper to fill our ethtool stats strings.

Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Julian Wiedmann 2021-06-11 09:33:36 +02:00 committed by David S. Miller
parent 3518ae76f2
commit c0a0186630
1 changed files with 2 additions and 4 deletions

View File

@ -80,10 +80,8 @@ static void qeth_add_stat_strings(u8 **data, const char *prefix,
{ {
unsigned int i; unsigned int i;
for (i = 0; i < size; i++) { for (i = 0; i < size; i++)
snprintf(*data, ETH_GSTRING_LEN, "%s%s", prefix, stats[i].name); ethtool_sprintf(data, "%s%s", prefix, stats[i].name);
*data += ETH_GSTRING_LEN;
}
} }
static int qeth_get_sset_count(struct net_device *dev, int stringset) static int qeth_get_sset_count(struct net_device *dev, int stringset)