diff options
author | Michal Kubecek <mkubecek@suse.cz> | 2020-03-28 02:01:43 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-03-30 08:32:36 +0300 |
commit | fd77be7bd43c578614165b1ae5fdb91b8f2f1689 (patch) | |
tree | ff5e458ea9d78e7a6cb1b0f03dbe8de923aea724 /net/ethtool/netlink.c | |
parent | b7eeefe72eb09a5dd9b259ab970d77d3e0fccdbd (diff) | |
download | linux-fd77be7bd43c578614165b1ae5fdb91b8f2f1689.tar.xz |
ethtool: set EEE settings with EEE_SET request
Implement EEE_SET netlink request to set EEE settings of a network device.
These are traditionally set with ETHTOOL_SEEE ioctl request.
The netlink interface allows setting the EEE status for all link modes
supported by kernel but only first 32 link modes can be set at the moment
as only those are supported by the ethtool_ops callback.
Signed-off-by: Michal Kubecek <mkubecek@suse.cz>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ethtool/netlink.c')
-rw-r--r-- | net/ethtool/netlink.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/net/ethtool/netlink.c b/net/ethtool/netlink.c index f9396d2a96f6..4630206837e0 100644 --- a/net/ethtool/netlink.c +++ b/net/ethtool/netlink.c @@ -824,6 +824,11 @@ static const struct genl_ops ethtool_genl_ops[] = { .dumpit = ethnl_default_dumpit, .done = ethnl_default_done, }, + { + .cmd = ETHTOOL_MSG_EEE_SET, + .flags = GENL_UNS_ADMIN_PERM, + .doit = ethnl_set_eee, + }, }; static const struct genl_multicast_group ethtool_nl_mcgrps[] = { |