aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHermann Lauer <Hermann.Lauer@iwr.uni-heidelberg.de>2008-12-09 18:39:14 -0500
committerDavid S. Miller <davem@davemloft.net>2008-12-09 18:39:14 -0500
commitfbf0229e946deb9e6c711f9eaa5c8d670c3a28fd (patch)
tree37f75559c8dab1e16d3659d3023235043338c7d5
parent8d3a564da34e5844aca4f991b73f8ca512246b23 (diff)
sungem: improve ethtool output with internal pcs and serdes
From: Hermann Lauer <Hermann.Lauer@iwr.uni-heidelberg.de> Attached is a patch which improves the output of ethtool (see below) to some sensefull values with a sungem fibre card which uses the sungem interal pcs connected to a serdes chip. The seriallink case in the driver is untouched. Most values are hardcoded, because gigabit fibre autoneg is anyways limited and the driver don't really support much at the moment with that hardware. Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/sungem.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/net/sungem.c b/drivers/net/sungem.c
index bb7a47829f7f..fed7eba65ead 100644
--- a/drivers/net/sungem.c
+++ b/drivers/net/sungem.c
@@ -2697,6 +2697,21 @@ static int gem_get_settings(struct net_device *dev, struct ethtool_cmd *cmd)
2697 cmd->speed = 0; 2697 cmd->speed = 0;
2698 cmd->duplex = cmd->port = cmd->phy_address = 2698 cmd->duplex = cmd->port = cmd->phy_address =
2699 cmd->transceiver = cmd->autoneg = 0; 2699 cmd->transceiver = cmd->autoneg = 0;
2700
2701 /* serdes means usually a Fibre connector, with most fixed */
2702 if (gp->phy_type == phy_serdes) {
2703 cmd->port = PORT_FIBRE;
2704 cmd->supported = (SUPPORTED_1000baseT_Half |
2705 SUPPORTED_1000baseT_Full |
2706 SUPPORTED_FIBRE | SUPPORTED_Autoneg |
2707 SUPPORTED_Pause | SUPPORTED_Asym_Pause);
2708 cmd->advertising = cmd->supported;
2709 cmd->transceiver = XCVR_INTERNAL;
2710 if (gp->lstate == link_up)
2711 cmd->speed = SPEED_1000;
2712 cmd->duplex = DUPLEX_FULL;
2713 cmd->autoneg = 1;
2714 }
2700 } 2715 }
2701 cmd->maxtxpkt = cmd->maxrxpkt = 0; 2716 cmd->maxtxpkt = cmd->maxrxpkt = 0;
2702 2717