mirror of
https://github.com/apache/nuttx.git
synced 2026-05-21 21:34:07 +08:00
drivers/net/encx24j600.c: Correct setting of ifstate
The ifstate is already set in enc_ifup -> enc_reset -> enc_linkstatus The ifstate after this call is either ENCSTATE_RUNNING or ENCSTATE_UP If ifstate is ENCSTATE_RUNNING, it would be wrong to set it to ENCSTATE_UP; this would lead to enc_txavail never invoking the driver callback, causing very long latencies in sending. Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
This commit is contained in:
committed by
Xiang Xiao
parent
5bcdeb0851
commit
b8dc64ffed
@@ -2272,11 +2272,8 @@ static int enc_ifup(struct net_driver_s *dev)
|
||||
wd_start(&priv->txpoll, ENC_WDDELAY,
|
||||
enc_polltimer, (wdparm_t)priv);
|
||||
|
||||
/* Mark the interface up and enable the Ethernet interrupt at the
|
||||
* controller
|
||||
*/
|
||||
/* Enable the Ethernet interrupt at the controller */
|
||||
|
||||
priv->ifstate = ENCSTATE_UP;
|
||||
priv->lower->enable(priv->lower);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user