mirror of
https://github.com/apache/nuttx.git
synced 2026-05-24 16:11:56 +08:00
netdev:When running, proto stack can exchange packets with device
netdev:when network device is running status,the network protocol stack is allowed to send packet to the network device and to receive from the network device Signed-off-by: wangchen <wangchen41@xiaomi.com>
This commit is contained in:
@@ -66,9 +66,9 @@ FAR struct net_driver_s *netdev_default(void)
|
||||
netdev_list_lock();
|
||||
for (dev = g_netdevices; dev; dev = dev->flink)
|
||||
{
|
||||
/* Is the interface in the "up" state? */
|
||||
/* Is the interface in the "running" state? */
|
||||
|
||||
if ((dev->d_flags & IFF_UP) != 0)
|
||||
if (IFF_IS_RUNNING(dev->d_flags) != 0)
|
||||
{
|
||||
/* Return a reference to the first device that we find in the UP
|
||||
* state (but not the loopback device unless it is the only
|
||||
|
||||
Reference in New Issue
Block a user