diff options
author | Philippe Reynes <tremyfr@gmail.com> | 2016-04-14 18:34:59 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-04-18 14:45:08 -0400 |
commit | 6d62b4d5fac620ee0ca65dc6d99b0306d96bc541 (patch) | |
tree | 3cd05429d28f63fbe2ddfa3860cf39be5485d0cb /include/linux/ethtool.h | |
parent | 2a2bbf170054e2525f11e08bb36d4027d76b7bff (diff) |
net: ethtool: export conversion function between u32 and link mode
The function convert_legacy_u32_to_link_mode and
convert_link_mode_to_legacy_u32 may be used outside
of ethtool.c. We rename them to ethtool_convert_...
and export them, so we could use them in others
drivers and modules.
Signed-off-by: Philippe Reynes <tremyfr@gmail.com>
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 e2b7bf27c03e..9ded8c6d8176 100644 --- a/include/linux/ethtool.h +++ b/include/linux/ethtool.h | |||
@@ -150,6 +150,13 @@ extern int | |||
150 | __ethtool_get_link_ksettings(struct net_device *dev, | 150 | __ethtool_get_link_ksettings(struct net_device *dev, |
151 | struct ethtool_link_ksettings *link_ksettings); | 151 | struct ethtool_link_ksettings *link_ksettings); |
152 | 152 | ||
153 | void ethtool_convert_legacy_u32_to_link_mode(unsigned long *dst, | ||
154 | u32 legacy_u32); | ||
155 | |||
156 | /* return false if src had higher bits set. lower bits always updated. */ | ||
157 | bool ethtool_convert_link_mode_to_legacy_u32(u32 *legacy_u32, | ||
158 | const unsigned long *src); | ||
159 | |||
153 | /** | 160 | /** |
154 | * struct ethtool_ops - optional netdev operations | 161 | * struct ethtool_ops - optional netdev operations |
155 | * @get_settings: DEPRECATED, use %get_link_ksettings/%set_link_ksettings | 162 | * @get_settings: DEPRECATED, use %get_link_ksettings/%set_link_ksettings |