#ifdef USE_DHCP/* Update DHCP state machine */DHCP_state = DHCP_LINK_DOWN;#endif/* USE_DHCP *//* When the netif link is down this function must be called.*/netif_set_down(netif);#ifdefUSE_LCDLCD_UsrLog ("The network cable is not connected \n");#elseBSP_LED_Off(LED1); BSP_L...
示例9: netif_set_down ▲点赞 1▼ /** * Bring an interface down, disabling any traffic processing. * * @note: Enabling DHCP on a down interface will make it come * up once configured. * * @see dhcp_start() */voidnetif_set_down(struct netif *netif){if(netif->flags & NETIF_FLAG...
netif_set_default:把网卡恢复出厂设置,目前lwip有一套默认参数 void netif_set_default(struct netif *netif); 1. netif_set_up&netif_set_down:设置我们网卡工作状态,是上线还是离线 void netif_set_up(struct netif *netif); void netif_set_down(struct netif *netif); 1. 2. callback:需要自己实现l...
/* 释放资源 */ } #endif /* LWIP_DHCP > 0 */ netifapi_netif_set_down(netif); /* 禁用网卡 */ } netifapi_netif_set_up(netif); /* 启动网卡 */ #if LWIP_DHCP > 0 if (bUseDHCP) { netif->flags2 |= NETIF_FLAG2_DHCP; /* 使用 DHCP 启动 */ } else if (bShutDownDHCP) {...
{ netif_set_link_up(&netif); } else { netif_set_link_down(&netif); } } /* Check for received frames, feed them to lwIP */ lock_interrupts(); struct pbuf* p = queue_try_get(&queue); unlock_interrupts(); if(p != NULL) { LINK_STATS_INC(link.recv); /* Update SNMP stats ...
Search or jump to... Search code, repositories, users, issues, pull requests... Provide feedback We read every piece of feedback, and take your input very seriously. Include my email address so I can be contacted Cancel Submit feedback Saved searches Use saved searches to filter your...
* start, stop, set_up or set_down. These functions can be directly used as event handlers * registered to follow the events from communication media. */ /** @addtogroup ESP_NETIF_LIFECYCLE * @{ */ /** * @brief Default building block for network interface action upon IO driver start...
/** This function is called when the netif link is set to up or down */ netif_status_callback_fn link_callback; #endif /* LWIP_NETIF_LINK_CALLBACK */ #if LWIP_NETIF_REMOVE_CALLBACK /** This function is called when the netif has been removed */ ...
interface down then up again). HW seem to be unable to transmit descriptor to the wire after HW tail register bump which in turn causes bit __QUEUE_STATE_STACK_XOFF to be set forever as netdev_tx_completed_queue() sees no cleaned bytes on the input. ...
back into this driver and all the way down into netif_receive_skb()again. And so on and so forth.If there is some bug in the stack (ACK'ing ACKs, stuff like that) wecould get into a loop and overrun the kernel stack in no time at all.So, if anything, this change cou...