lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] Multi threaded TCP model


From: Pîrvu Mihai
Subject: Re: [lwip-users] Multi threaded TCP model
Date: Fri, 18 Mar 2016 21:13:11 +0200

The port I'm using is using 1.3.2 version, so I doubt there's this option from the unreleased branch. I'll try to follow how select is implemented and see if there's a non-blocking way to check if a packet has arived on a socket/session so I don't block the thread indefinitely.

On Fri, Mar 18, 2016 at 8:56 PM, address@hidden <address@hidden> wrote:
Pîrvu Mihai wrote:
I've read that different threads cannot call the same socket/netconn session at the same time, so I guess this is where my problem lays.

You can use the fairly new option LWIP_NETCONN_FULLDUPLEX set to 1, which in combination with thread-local semaphores (LWIP_NETCONN_SEM_PER_THREAD==1) to write from one thread while writing from a 2nd thread. Thread-local semaphores might not be easy to implement, though, depending on your port.

Simon

_______________________________________________
lwip-users mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/lwip-users


reply via email to

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