mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-01 06:33:07 +00:00
net: arc_emac: reset txbd_curr and txbd_dirty pointers to zero
EMAC reset internal tx ring pointer to zero at statup. txbd_curr and txbd_dirty can be different from zero. That cause ethernet transfer hang (no packets transmitted). In order to reproduce, run on device: ifconfig eth0 down ifconfig eth0 up Signed-off-by: Alexander Kochetkov <al.kochet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
c278c253f3
commit
99f93a156a
1 changed files with 3 additions and 0 deletions
|
@ -447,6 +447,9 @@ static int arc_emac_open(struct net_device *ndev)
|
|||
*last_rx_bd = (*last_rx_bd + 1) % RX_BD_NUM;
|
||||
}
|
||||
|
||||
priv->txbd_curr = 0;
|
||||
priv->txbd_dirty = 0;
|
||||
|
||||
/* Clean Tx BD's */
|
||||
memset(priv->txbd, 0, TX_RING_SZ);
|
||||
|
||||
|
|
Loading…
Reference in a new issue