提交 24fcad6b 编写于 作者: M Michael Chan 提交者: David S. Miller

[TG3]: Assign tp->link_config.orig_* values.

tp->link_config.orig_* values must be assigned during
tg3_set_settings() because these values will be used to setup the
link speed during tg3_open().  Without these assignments, the link
speed settings will be all messed by if tg3_set_settings() is called
when the device is down.
Signed-off-by: NMichael Chan <mchan@broadcom.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 9b54d5c6
...@@ -7974,6 +7974,10 @@ static int tg3_set_settings(struct net_device *dev, struct ethtool_cmd *cmd) ...@@ -7974,6 +7974,10 @@ static int tg3_set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
tp->link_config.duplex = cmd->duplex; tp->link_config.duplex = cmd->duplex;
} }
tp->link_config.orig_speed = tp->link_config.speed;
tp->link_config.orig_duplex = tp->link_config.duplex;
tp->link_config.orig_autoneg = tp->link_config.autoneg;
if (netif_running(dev)) if (netif_running(dev))
tg3_setup_phy(tp, 1); tg3_setup_phy(tp, 1);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册