Message ID | 20240618213330.982046-1-anthony.l.nguyen@intel.com (mailing list archive) |
---|---|
State | Accepted |
Commit | a012f9a752a5856b29610057c76079fbdbe02abf |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [net-next] igb: Add MII write support | expand |
Hello: This patch was applied to netdev/net-next.git (main) by Paolo Abeni <pabeni@redhat.com>: On Tue, 18 Jun 2024 14:33:28 -0700 you wrote: > From: Jackie Jone <jackie.jone@alliedtelesis.co.nz> > > To facilitate running PHY parametric tests, add support for the SIOCSMIIREG > ioctl. This allows a userspace application to write to the PHY registers > to enable the test modes. > > Signed-off-by: Jackie Jone <jackie.jone@alliedtelesis.co.nz> > Acked-by: Jacob Keller <jacob.e.keller@intel.com> > Tested-by: Pucha Himasekhar Reddy <himasekharx.reddy.pucha@intel.com> (A Contingent worker at Intel) > Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com> > > [...] Here is the summary with links: - [net-next] igb: Add MII write support https://git.kernel.org/netdev/net-next/c/a012f9a752a5 You are awesome, thank you!
diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c index fce2930ae6af..3af03a211c3c 100644 --- a/drivers/net/ethernet/intel/igb/igb_main.c +++ b/drivers/net/ethernet/intel/igb/igb_main.c @@ -9139,6 +9139,10 @@ static int igb_mii_ioctl(struct net_device *netdev, struct ifreq *ifr, int cmd) return -EIO; break; case SIOCSMIIREG: + if (igb_write_phy_reg(&adapter->hw, data->reg_num & 0x1F, + data->val_in)) + return -EIO; + break; default: return -EOPNOTSUPP; }