lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] lwip-users Digest, Vol 162, Issue 1


From: Sandra Gilge (ADATIS)
Subject: Re: [lwip-users] lwip-users Digest, Vol 162, Issue 1
Date: Wed, 1 Feb 2017 21:44:31 +0100
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0

>Simon wrote
>I'm not sure I get it. You checked that sockets are used from only one thread? 
>The thing to check >would be to ensure that *every* core function (not 
>sockets) is only called from tcpip_thread and not >from an interrupt. That 
>would indeed be useful for debugging. I could imagine adding a macro for this 
>>which whould need to be implemented by an lwIP port.

I did both. In the core functions I compare the calling thread with the tcpip 
thread ID.
In the sockets I store for each socket created with socket or accept the thread 
that created the socket and compare it in the other socket functions with the 
calling thread ID. So I can be shure that a single socket is not "used" by 
different threads (i.e. select in one and send in the other). At least in the 
past things like that caused problems.




reply via email to

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