Re: [lwip-users] implementing device driver: netif events handling

2012-08-09 Thread jblackarty
> See my last mail (2.5 hours ago) about these (short summary: #1 can > currently not be fixed, #3 is already fixed in git). My message was sent earlier but delayed by some reasons. Thank you for answers. I prefer to use stable releases and will wait for official release resolves issue #3. I hope

Re: [lwip-users] implementing device driver: netif events handling

2012-08-09 Thread Simon Goldschmidt
jblackarty wrote: > Issues #1 and #3 are still open. See my last mail (2.5 hours ago) about these (short summary: #1 can currently not be fixed, #3 is already fixed in git). Simon ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongn

Re: [lwip-users] implementing device driver: netif events handling

2012-08-09 Thread jblackarty
> While multiple ports use separate thread for packets input, it is not > the only way LwIP can work. If yor driver operates in tcp_ip thread > there is no need for it to be thread safe. I know. I implicitly meant only case when NO_SYS=0 (that is multithreading) > If u use separate threa > thera a

Re: [lwip-users] implementing device driver: netif events handling

2012-08-08 Thread Simon Goldschmidt
jblackarty wrote: > 1. How to make driver to be notified when application sets it's interface > up/down ? It's needed to remove unnecessary system load by disabling > transmit path in hardware. There are LWIP_NETIF_STATUS_CALLBACK and > LWIP_NETIF_LINK_CALLBACK capabilities exist but seems that t

Re: [lwip-users] implementing device driver: netif events handling

2012-08-08 Thread Simon Goldschmidt
"Krzysztof Wesołowski" wrote: > If u use separate threa > thera are netifapi_* variants of functions which uses messages with > call back to pass execution to tcpip thread. Or use 'tcpip_callback()' to call a self-created function in the context of tcpip_thread which in turn calls netif_set_lin

Re: [lwip-users] implementing device driver: netif events handling

2012-08-08 Thread Krzysztof Wesołowski
> 2. Link change events initiated by driver are not thread-safe. > Wiki page > http://lwip.wikia.com/wiki/Writing_a_device_driver#Link_change_events > claims that driver should use netif_set_link_up/netif_set_link_down > functions. But they manipulate netif flags directly. Moreover, they > directly

[lwip-users] implementing device driver: netif events handling

2012-08-08 Thread jblackarty
Hi all, 1. How to make driver to be notified when application sets it's interface up/down ? It's needed to remove unnecessary system load by disabling transmit path in hardware. There are LWIP_NETIF_STATUS_CALLBACK and LWIP_NETIF_LINK_CALLBACK capabilities exist but seems that they intended to be