net: ethtool: Allow passing a phy index for some commands
authorMaxime Chevallier <maxime.chevallier@bootlin.com>
Thu, 21 Dec 2023 18:00:38 +0000 (19:00 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 1 Jan 2024 18:38:57 +0000 (18:38 +0000)
commit2ab0edb505faa9ac90dee1732571390f074e8113
treecde674843ce3ef43d2cd94b478f30b300221938d
parentdedd702a35793ab462fce4c737eeba0badf9718e
net: ethtool: Allow passing a phy index for some commands

Some netlink commands are target towards ethernet PHYs, to control some
of their features. As there's several such commands, add the ability to
pass a PHY index in the ethnl request, which will populate the generic
ethnl_req_info with the relevant phydev when the command targets a PHY.

Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Documentation/networking/ethtool-netlink.rst
include/uapi/linux/ethtool_netlink.h
net/ethtool/netlink.c
net/ethtool/netlink.h