drivers/net/ethernet/microchip/lan865x/lan865x.c | 1 + 1 file changed, 1 insertion(+)
Introduce support for standard MII ioctl operations in the LAN865x
Ethernet driver by implementing the .ndo_eth_ioctl callback. This allows
PHY-related ioctl commands to be handled via phy_do_ioctl_running() and
enables support for ethtool and other user-space tools that rely on ioctl
interface to perform PHY register access using commands like SIOCGMIIREG
and SIOCSMIIREG.
This feature enables improved diagnostics and PHY configuration
capabilities from userspace.
Signed-off-by: Parthiban Veerasooran <parthiban.veerasooran@microchip.com>
---
v2:
- Replaced custom lan865x_eth_ioctl() with direct use of
phy_do_ioctl_running() to avoid code duplication.
- Updated commit message to reflect the new change.
---
drivers/net/ethernet/microchip/lan865x/lan865x.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/ethernet/microchip/lan865x/lan865x.c b/drivers/net/ethernet/microchip/lan865x/lan865x.c
index 84c41f193561..f7cb685b1562 100644
--- a/drivers/net/ethernet/microchip/lan865x/lan865x.c
+++ b/drivers/net/ethernet/microchip/lan865x/lan865x.c
@@ -326,6 +326,7 @@ static const struct net_device_ops lan865x_netdev_ops = {
.ndo_start_xmit = lan865x_send_packet,
.ndo_set_rx_mode = lan865x_set_multicast_list,
.ndo_set_mac_address = lan865x_set_mac_address,
+ .ndo_eth_ioctl = phy_do_ioctl_running,
};
static int lan865x_probe(struct spi_device *spi)
base-commit: d4854be4ec21dad23907c0fbc3389c3a394ebf67
--
2.34.1
On Thu, Aug 28, 2025 at 05:15:49PM +0530, Parthiban Veerasooran wrote:
> Introduce support for standard MII ioctl operations in the LAN865x
> Ethernet driver by implementing the .ndo_eth_ioctl callback. This allows
> PHY-related ioctl commands to be handled via phy_do_ioctl_running() and
> enables support for ethtool and other user-space tools that rely on ioctl
> interface to perform PHY register access using commands like SIOCGMIIREG
> and SIOCSMIIREG.
>
> This feature enables improved diagnostics and PHY configuration
> capabilities from userspace.
>
> Signed-off-by: Parthiban Veerasooran <parthiban.veerasooran@microchip.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Andrew
© 2016 - 2026 Red Hat, Inc.