lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] Calling netif_set_link_up/down in my driver


From: Mason
Subject: Re: [lwip-users] Calling netif_set_link_up/down in my driver
Date: Thu, 24 May 2012 17:38:40 +0200
User-agent: Mozilla/5.0 (Windows NT 5.1; rv:12.0) Gecko/20120429 Firefox/12.0 SeaMonkey/2.9.1

Simon Goldschmidt wrote:

> Mason wrote:
> 
>> If LWIP_TCPIP_CORE_LOCKING is 0, tcpip_netifapi looks
>> fairly similar to tcpip_callback_with_block.
>>
>> Does netifapi make sense when LWIP_TCPIP_CORE_LOCKING is 1,
>> in which case there is no message passing, the operation is
>> done within the calling context holding LOCK_TCPIP_CORE?
> 
> Using netifapi makes sense in both configurations as you can just
> use the predefined functions instead of writing your own code.

Can I call netif_set_link_up( ) directly in my driver?
Or would I need some hypothetical netifapi_netif_set_link_up?

$ grep -rn netifapi_netif_set_link

NB: netifapi_netif_set_link is not defined in the list of
wrappers in netifapi.h (in the 1.4.x branch)

Should netifapi_netif_set_link_up be defined in netifapi.h?

> I didn't quite get why you can't use the netifapi functions,
> though.

I haven't needed netifapi until now, thus it is not compiled in.
Adding this module to my project (thus adding object code) when
the same operation can be done through tcpip_callback does not
seem warranted to me. But perhaps I have some misconceptions?

-- 
Regards.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]