be2net: fix to set proper flow control on resume
If be2 goes into suspend after a user changes the flow control settings, we are not programming them back after resume. This patch takes care of it. We now get the flow control settings before going to suspend mode and then apply them during resume. Signed-off-by: Ajit Khaparde <ajitk@serverengines.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
bb7b228401
commit
9e90c96113
@@ -323,10 +323,12 @@ be_set_pauseparam(struct net_device *netdev, struct ethtool_pauseparam *ecmd)
|
||||
|
||||
if (ecmd->autoneg != 0)
|
||||
return -EINVAL;
|
||||
adapter->tx_fc = ecmd->tx_pause;
|
||||
adapter->rx_fc = ecmd->rx_pause;
|
||||
|
||||
status = be_cmd_set_flow_control(adapter, ecmd->tx_pause,
|
||||
ecmd->rx_pause);
|
||||
if (!status)
|
||||
status = be_cmd_set_flow_control(adapter,
|
||||
adapter->tx_fc, adapter->rx_fc);
|
||||
if (status)
|
||||
dev_warn(&adapter->pdev->dev, "Pause param set failed.\n");
|
||||
|
||||
return status;
|
||||
|
Reference in New Issue
Block a user