diff options
author | Julian Wiedmann <jwi@linux.ibm.com> | 2021-06-11 09:33:36 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-06-11 12:49:15 -0700 |
commit | c0a0186630fb0e9880aa4c3d6ea136146c48db56 (patch) | |
tree | 8a4bccce502a706ec979c8ffc048a0e69338a4a5 /drivers/s390 | |
parent | 3518ae76f2bbc465f7a0d7075fe71815e37b21c6 (diff) |
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>
Diffstat (limited to 'drivers/s390')
-rw-r--r-- | drivers/s390/net/qeth_ethtool.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/s390/net/qeth_ethtool.c b/drivers/s390/net/qeth_ethtool.c index 190dac2065df..2c4cb300a8fc 100644 --- a/drivers/s390/net/qeth_ethtool.c +++ b/drivers/s390/net/qeth_ethtool.c @@ -80,10 +80,8 @@ static void qeth_add_stat_strings(u8 **data, const char *prefix, { unsigned int i; - for (i = 0; i < size; i++) { - snprintf(*data, ETH_GSTRING_LEN, "%s%s", prefix, stats[i].name); - *data += ETH_GSTRING_LEN; - } + for (i = 0; i < size; i++) + ethtool_sprintf(data, "%s%s", prefix, stats[i].name); } static int qeth_get_sset_count(struct net_device *dev, int stringset) |