]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
tg3 ethtool fiber reports tp
authorChris Wright <chrisw@sous-sol.org>
Tue, 16 May 2006 23:38:55 +0000 (16:38 -0700)
committerChris Wright <chrisw@sous-sol.org>
Tue, 16 May 2006 23:38:55 +0000 (16:38 -0700)
queue-2.6.16/series
queue-2.6.16/tg3-ethtool-always-report-port-is-tp.patch [new file with mode: 0644]

index 7777a1c14dc9e066c802219870e59d7cf9c9fbaf..71aac5cdd17974d51d07c91ea7317d55915bacb0 100644 (file)
@@ -7,3 +7,4 @@ fs-compat.c-fix-if-typo.patch
 smbus-unhiding-kills-thermal-management.patch
 scx200_acb-fix-resource-name-use-after-free.patch
 netfilter-do_add_counters-race-possible-info-leak.patch
+tg3-ethtool-always-report-port-is-tp.patch
diff --git a/queue-2.6.16/tg3-ethtool-always-report-port-is-tp.patch b/queue-2.6.16/tg3-ethtool-always-report-port-is-tp.patch
new file mode 100644 (file)
index 0000000..8f7ef6d
--- /dev/null
@@ -0,0 +1,46 @@
+From nobody Mon Sep 17 00:00:00 2001
+From: Karsten Keil <kkeil@suse.de>
+Date: Fri May 12 12:49:08 2006 -0700
+Subject: [PATCH] TG3: ethtool always report port is TP.
+
+Even with fiber cards ethtool reports that the connected port is TP,
+the patch fix this.
+
+Signed-off-by: Karsten Keil <kkeil@suse.de>
+Acked-by: Michael Chan <mchan@broadcom.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Chris Wright <chrisw@sous-sol.org>
+---
+
+ drivers/net/tg3.c |    8 +++++---
+ 1 file changed, 5 insertions(+), 3 deletions(-)
+
+--- linux-2.6.16.16.orig/drivers/net/tg3.c
++++ linux-2.6.16.16/drivers/net/tg3.c
+@@ -7368,21 +7368,23 @@ static int tg3_get_settings(struct net_d
+               cmd->supported |= (SUPPORTED_1000baseT_Half |
+                                  SUPPORTED_1000baseT_Full);
+-      if (!(tp->tg3_flags2 & TG3_FLG2_ANY_SERDES))
++      if (!(tp->tg3_flags2 & TG3_FLG2_ANY_SERDES)) {
+               cmd->supported |= (SUPPORTED_100baseT_Half |
+                                 SUPPORTED_100baseT_Full |
+                                 SUPPORTED_10baseT_Half |
+                                 SUPPORTED_10baseT_Full |
+                                 SUPPORTED_MII);
+-      else
++              cmd->port = PORT_TP;
++      } else {
+               cmd->supported |= SUPPORTED_FIBRE;
++              cmd->port = PORT_FIBRE;
++      }
+   
+       cmd->advertising = tp->link_config.advertising;
+       if (netif_running(dev)) {
+               cmd->speed = tp->link_config.active_speed;
+               cmd->duplex = tp->link_config.active_duplex;
+       }
+-      cmd->port = 0;
+       cmd->phy_address = PHY_ADDR;
+       cmd->transceiver = 0;
+       cmd->autoneg = tp->link_config.autoneg;