Ethernet Tx Thread */
| 877 | #ifndef LWIP_NO_TX_THREAD |
| 878 | /* Ethernet Tx Thread */ |
| 879 | static void eth_tx_thread_entry(void* parameter) |
| 880 | { |
| 881 | struct eth_tx_msg* msg; |
| 882 | |
| 883 | while (1) |
| 884 | { |
| 885 | if (rt_mb_recv(ð_tx_thread_mb, (rt_ubase_t *)&msg, RT_WAITING_FOREVER) == RT_EOK) |
| 886 | { |
| 887 | struct eth_device* enetif; |
| 888 | |
| 889 | RT_ASSERT(msg->netif != RT_NULL); |
| 890 | RT_ASSERT(msg->buf != RT_NULL); |
| 891 | |
| 892 | enetif = (struct eth_device*)msg->netif->state; |
| 893 | if (enetif != RT_NULL) |
| 894 | { |
| 895 | /* call driver's interface */ |
| 896 | if (enetif->eth_tx(&(enetif->parent), msg->buf) != RT_EOK) |
| 897 | { |
| 898 | /* transmit eth packet failed */ |
| 899 | } |
| 900 | } |
| 901 | |
| 902 | /* send ACK */ |
| 903 | rt_completion_done(&msg->ack); |
| 904 | } |
| 905 | } |
| 906 | } |
| 907 | #endif |
| 908 | |
| 909 | #ifndef LWIP_NO_RX_THREAD |
nothing calls this directly
no test coverage detected