summaryrefslogtreecommitdiffstats
path: root/drivers/net/mdio.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2009-10-12 09:26:37 +0000
committerDavid S. Miller <davem@davemloft.net>2009-10-12 23:59:08 -0700
commit27fbc7db52315d6ec37fe3292c1b2ee62180c643 (patch)
treeff928d967066b26d183d25e07e172296b5638cc0 /drivers/net/mdio.c
parent767f4a7ca8041442e033dd919b591d00f6901e03 (diff)
downloadlinux-27fbc7db52315d6ec37fe3292c1b2ee62180c643.tar.gz
linux-27fbc7db52315d6ec37fe3292c1b2ee62180c643.tar.bz2
linux-27fbc7db52315d6ec37fe3292c1b2ee62180c643.zip
mdio: Expose pause frame advertising flags to ethtool
In mdio45_ethtool_gset_npage() and mdio45_ethtool_gset(), check MDIO pause frame advertising flags and set the corresponding ethtool flags. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/mdio.c')
-rw-r--r--drivers/net/mdio.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/mdio.c b/drivers/net/mdio.c
index c0db9d753006..e85bf04cf813 100644
--- a/drivers/net/mdio.c
+++ b/drivers/net/mdio.c
@@ -162,6 +162,10 @@ static u32 mdio45_get_an(const struct mdio_if_info *mdio, u16 addr)
result |= ADVERTISED_100baseT_Half;
if (reg & ADVERTISE_100FULL)
result |= ADVERTISED_100baseT_Full;
+ if (reg & ADVERTISE_PAUSE_CAP)
+ result |= ADVERTISED_Pause;
+ if (reg & ADVERTISE_PAUSE_ASYM)
+ result |= ADVERTISED_Asym_Pause;
return result;
}