]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
tg3: Return flowctrl config through ethtool
authorMatt Carlson <mcarlson@broadcom.com>
Thu, 8 Dec 2011 14:40:17 +0000 (14:40 +0000)
committerJoe Jin <joe.jin@oracle.com>
Wed, 16 May 2012 02:38:20 +0000 (10:38 +0800)
This patch changes the driver to return the flow control configuration
rather than the flow control status through the ETHTOOL_GPAUSEPARAM
ioctl.

(cherry picked from commit 4a2db503c57f7223d851dc7ab8cefca614e0d98a)
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Joe Jin <joe.jin@oracle.com>
drivers/net/tg3.c

index d7892488665e30b64c9d13ad429fe9dcd7ff9ceb..73780912867ec9ce3f4d99a232766c932d4ba1a5 100644 (file)
@@ -10610,12 +10610,12 @@ static void tg3_get_pauseparam(struct net_device *dev, struct ethtool_pauseparam
 
        epause->autoneg = !!tg3_flag(tp, PAUSE_AUTONEG);
 
-       if (tp->link_config.active_flowctrl & FLOW_CTRL_RX)
+       if (tp->link_config.flowctrl & FLOW_CTRL_RX)
                epause->rx_pause = 1;
        else
                epause->rx_pause = 0;
 
-       if (tp->link_config.active_flowctrl & FLOW_CTRL_TX)
+       if (tp->link_config.flowctrl & FLOW_CTRL_TX)
                epause->tx_pause = 1;
        else
                epause->tx_pause = 0;