When you use the tun/tap interface in Linux, you have a tun/tap
interface in Linux. Nothing from lwIPland, just Linuxland.
As per my (sort of) expertise, you get what looks like another Ethernet
card attached to a network. There is your plain trusty old linux machine
on one side, there is your brand new process on the other side. Unless
you set it in bridging mode, thing I don't know how to do (but you can
ask your good friend Google), if your port process wants to connect with
"the rest of the machine", you have to route; that means properly
configuring routing on both ends. (I'm talking networking, not IPC)
Your lwip port will have to be setup with a default gateway equal to the
tun/tap address (which belongs to Linux), and be assigned a different
address on the very same subnet.
If you want to serve DHCP on that tun/tap, you have to configure the
DHCP server to listen to that interface (and probably start it after the
tun/tap goes up when you start the lwIP port).
If you have a web server on lwIP and want to access it from Firefox on a
Windows PC on your local network, you have to have a route to your
tun/tap (or a default to your Linux) in your Windows.
Your Linux machine is a router with several interfaces and one of them
happens to be connected to a device that is the lwIP port process.
So I guess the answer to your question is that the Linux stack will send
ARP requests on that network and your lwIP port will listen to them.
Just the opposite will happen when your lwIP port wants to know the MAC
address of the Linux side of the connection.
lwip-users mailing list