I'm starting to use the Loopback connection
at the moment and am running into what appears to be race conditions.
(Still using 1.3.0 and in the process
of looking at 1.3.1)
Now in 1.3.0 in loopif.c it is said
that loopif_output() copies the pbuf and calls netif->input() with it.
And netif->input() is supposed to put the pbuf in a mbox to get out
of reentering functions.
How would that input() function look
like? I looked for examples and didn't find any.
Until now my netif_add() for loopback
looked like this:
Now in 1.3.1 you just seem to schedule
a call to netif_poll(), the same function that the user of raw API is supposed
to call periodically himself (which was also similar in 1.3.0).
Does this mean for 1.3.1, my netif_add()
can just use NULL as input function? Will that get me around the race condition?
Please provide some example on using
loopback in the wiki.