Hello Charles, On Wed, Apr 09, 2014 at 06:47:43PM +0000, [email protected] wrote: > > My test setup is like this: > > Ethernet > PPP > PC ------------- My gateway device -------- Linux PPP server > 192.168.0.211 192.168.0.50 192.168.1.105 192.168.1.106 > > I ping from my PC to the PPP server. Here's some logging messages > showing the modified ip_forward function works as expected. > > ip_input: iphdr->dest 0x6a01a8c0 netif->ip_addr 0x3200a8c0 (0x1a8c0, 0xa8c0, > 0x6a000000) > ip_input: iphdr->dest 0x6a01a8c0 netif->ip_addr 0x6901a8c0 (0x6a01a8c0, > 0x6901a8c0, 0x0) > ip_input: packet not for us. > ip_forward: forward packets to interface.pp > ip_forward: forwarding packet to 192.168.1.106 > ip_input: iphdr->dest 0xd300a8c0 netif->ip_addr 0x6901a8c0 (0xd300a8c0, > 0x6901a8c0, 0x0) > ip_input: iphdr->dest 0xd300a8c0 netif->ip_addr 0x3200a8c0 (0xa8c0, 0xa8c0, > 0xd3000000) > ip_input: packet not for us. > ip_forward: forward packets to interface.em > ip_forward: forwarding packet to 192.168.0.211 > > I captured PPP traffic on the serial port and also captured Ethernet > traffic using Wireshark. I can clearly see PPP traffic on both > directions(into and out from the PPP server) and they are correct > frames as expected. However, the traffic from PPP server to my PC > NEVER showed up in Wireshark. It seems lwIP silently drop those > packets. What should I do to find out the cause of the problem?
First, thank you, I trimed most but everything was really helpful, I enjoy getting such well-written investigation pattern :) Well, ip_forward() should call netif->output(), which in our case is ppp_netif_output_ip4(), could you first check that ? You can also enable PPP_DEBUG in your lwipopts.h, this will display discarded frames in ppp_netif_output_ip4() if any. Sylvain
signature.asc
Description: Digital signature
_______________________________________________ lwip-users mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/lwip-users
