drivers/net/{e1000|igc}: do not touch RX/TX rings when link status change
Do not reset RX/TX rings when link status change. This can break internal card state which is impossible to recovery. Signed-off-by: p-szafonimateusz <p-szafonimateusz@xiaomi.com>
This commit is contained in:
parent
bccee707d6
commit
7a8ac49836
2 changed files with 3 additions and 10 deletions
|
|
@ -757,15 +757,11 @@ static void e1000_link_work(FAR void *arg)
|
|||
ninfo("Link up, status = 0x%x\n", tmp);
|
||||
|
||||
netdev_lower_carrier_on(&priv->dev);
|
||||
|
||||
/* Clear Tx and RX rings */
|
||||
|
||||
e1000_txclean(priv);
|
||||
e1000_rxclean(priv);
|
||||
}
|
||||
else
|
||||
{
|
||||
ninfo("Link down\n");
|
||||
|
||||
netdev_lower_carrier_off(&priv->dev);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -711,16 +711,13 @@ static void igc_link_work(FAR void *arg)
|
|||
if (tmp & IGC_STATUS_LU)
|
||||
{
|
||||
ninfo("Link up, status = 0x%x\n", tmp);
|
||||
|
||||
netdev_lower_carrier_on(&priv->dev);
|
||||
|
||||
/* Clear Tx and RX rings */
|
||||
|
||||
igc_txclean(priv);
|
||||
igc_rxclean(priv);
|
||||
}
|
||||
else
|
||||
{
|
||||
ninfo("Link down\n");
|
||||
|
||||
netdev_lower_carrier_off(&priv->dev);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue