diff options
author | Florian Fainelli <f.fainelli@gmail.com> | 2020-07-08 09:46:24 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-07-08 12:39:05 -0700 |
commit | bd36ed1c935144a0e3b788bba659258f666e7b5b (patch) | |
tree | cf6d2f62da5f0707255e3b1caab68c9d401049f8 /include/linux/ethtool.h | |
parent | 5d75c04306f7f906c1200bef42406ccb71d4b75f (diff) |
net: phy: Define PHY statistics ethtool_phy_ops
Extend ethtool_phy_ops to include the 3 function pointers necessary for
implementing PHY statistics. In a subsequent change we will uninline
those functions.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/ethtool.h')
-rw-r--r-- | include/linux/ethtool.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/ethtool.h b/include/linux/ethtool.h index 0c139a93b67a..969a80211df6 100644 --- a/include/linux/ethtool.h +++ b/include/linux/ethtool.h @@ -508,6 +508,9 @@ struct phy_tdr_config; /** * struct ethtool_phy_ops - Optional PHY device options + * @get_sset_count: Get number of strings that @get_strings will write. + * @get_strings: Return a set of strings that describe the requested objects + * @get_stats: Return extended statistics about the PHY device. * @start_cable_test - Start a cable test * @start_cable_test_tdr - Start a Time Domain Reflectometry cable test * @@ -515,6 +518,10 @@ struct phy_tdr_config; * and callers must take this into account. Callers must hold the RTNL lock. */ struct ethtool_phy_ops { + int (*get_sset_count)(struct phy_device *dev); + int (*get_strings)(struct phy_device *dev, u8 *data); + int (*get_stats)(struct phy_device *dev, + struct ethtool_stats *stats, u64 *data); int (*start_cable_test)(struct phy_device *phydev, struct netlink_ext_ack *extack); int (*start_cable_test_tdr)(struct phy_device *phydev, |