Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-10-12 Thread Sylvain Rochet
Hello Charles, On Fri, Apr 11, 2014 at 06:21:09PM +, l...@moog.com wrote: Sylvain, Great, the latest patch works. Thank you very much. Maybe you missed that, but the patch was actually broken by design, please see bug #43173 [1]. Please also note that ppp-new branch has been merged

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-15 Thread LMao
for lwIP users Subject: Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP) Hello Charles, On Mon, Apr 14, 2014 at 01:05:07PM +, l...@moog.com wrote: Hi Sylvain, I applied the patch and it seems everything is working. However, I don't know much about VJ

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-15 Thread Sylvain Rochet
Hello Charles, On Tue, Apr 15, 2014 at 06:03:40PM +, l...@moog.com wrote: Sylvain, I observed similar messages. I think VJ is in effect in my test. Great ! :) Sylvain signature.asc Description: Digital signature ___ lwip-users mailing list

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-14 Thread LMao
To: Mailing list for lwIP users Subject: Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP) Hello Charles, On Sat, Apr 12, 2014 at 01:29:33AM +0200, Sylvain Rochet wrote: Finally, here we are… Hey!, since you have the setup to check IP forwarding could you check IP

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-14 Thread Sylvain Rochet
Hello Charles, On Mon, Apr 14, 2014 at 01:05:07PM +, l...@moog.com wrote: Hi Sylvain, I applied the patch and it seems everything is working. However, I don't know much about VJ support, so I don't know if the PPP server and my gateway device have actually negotiated to use VJ at

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-12 Thread Sylvain Rochet
Hello Charles, On Sat, Apr 12, 2014 at 01:29:33AM +0200, Sylvain Rochet wrote: Finally, here we are… Hey!, since you have the setup to check IP forwarding could you check IP forwarding with VJ support enabled ? :) Humm, I should have added that you must update your Git repository before

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-11 Thread LMao
] On Behalf Of Sylvain Rochet Sent: Thursday, April 10, 2014 6:15 PM To: Mailing list for lwIP users Subject: Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP) Hello Charles, On Thu, Apr 10, 2014 at 08:03:13PM +, l...@moog.com wrote: Hi Sylvain, Good news, I got

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-11 Thread Sylvain Rochet
Hello Charles, On Fri, Apr 11, 2014 at 12:13:02PM +, l...@moog.com wrote: Sylvain, I applied the new patch, but the following statement always cause Data Abort exception run-time error. No matter I set ETH_PAD_SIZE to 0 or 2. The good thing is my compiler doesn't generate any error

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-11 Thread Simon Goldschmidt
Hi Sylvain, Sylvain Rochet wrote: I put the PPP header into the allocated space for PBUF_LINK if there is enough space to do so, for a 14 byte PBUF_LINK_HEADER this is 12 bytes of RAM wasted for NO_SYS=1, and 8 bytes for NO_SYS=0 with 32 bits pointers, for me this is an acceptable

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-11 Thread LMao
users Subject: Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP) Hello Charles, On Fri, Apr 11, 2014 at 12:13:02PM +, l...@moog.com wrote: Sylvain, I applied the new patch, but the following statement always cause Data Abort exception run-time error

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-11 Thread Sylvain Rochet
Hello Charles, On Fri, Apr 11, 2014 at 06:21:09PM +, l...@moog.com wrote: Sylvain, Great, the latest patch works. Thank you very much. Finally, here we are… Hey!, since you have the setup to check IP forwarding could you check IP forwarding with VJ support enabled ? :) Sylvain

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-11 Thread Sylvain Rochet
Hi Simon, On Fri, Apr 11, 2014 at 07:45:25PM +0200, Simon Goldschmidt wrote: Sylvain Rochet wrote: I put the PPP header into the allocated space for PBUF_LINK if there is enough space to do so, for a 14 byte PBUF_LINK_HEADER this is 12 bytes of RAM wasted for NO_SYS=1, and 8 bytes for

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread Sylvain Rochet
Hello Charles, On Wed, Apr 09, 2014 at 06:47:43PM +, l...@moog.com wrote: My test setup is like this: Ethernet PPP PC - My gateway device Linux PPP server 192.168.0.211

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread LMao
Hi Sylvain, Thank you for your reply. I really appreciate your help. The below are a few comments and more observations. Well, ip_forward() should call netif-output(), which in our case is ppp_netif_output_ip4(), could you first check that ? Sorry, I may confuse you about which direction the

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread LMao
Sylvain, It seems the patch makes things worse - PPP connection couldn’t build-up anymore. Below is the complete log message after applying the patch. It seems the code stalled at very early stage. *** FreeRTOS Demo Started! *** netif_set_ipaddr: netif addrnetif: IP address of interface set

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread Simon Goldschmidt
Sylvain Rochet wrote: Oh dear, now I see what is happening. PPP header is smaller than Ethernet header [..] This is actually a lwIP design issue, the only way we can fix that is by adding a configuration option so pbuf from PPP are allocated with enough extra space so a Ethernet header

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread Sylvain Rochet
Hello Simon, On Thu, Apr 10, 2014 at 08:12:00PM +0200, Simon Goldschmidt wrote: Sylvain Rochet wrote: Oh dear, now I see what is happening. PPP header is smaller than Ethernet header [..] This is actually a lwIP design issue, the only way we can fix that is by adding a configuration

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread LMao
@nongnu.org [mailto:lwip-users-bounces+cmao=moog@nongnu.org] On Behalf Of l...@moog.com Sent: Thursday, April 10, 2014 2:30 PM To: lwip-users@nongnu.org Subject: Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP) Sylvain, It seems the patch makes things

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread Sylvain Rochet
Hello Charles, On Thu, Apr 10, 2014 at 05:30:12PM +, l...@moog.com wrote: Sylvain, It seems the patch makes things worse - PPP connection couldn’t build-up anymore. Below is the complete log message after applying the patch. It seems the code stalled at very early stage. Hummm, this

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread S G
Sylvain Rochet wrote: PPPoE use PBUF_LINK, PPPoL2TP use PBUF_TRANSPORT, PPPoS use PBUF_RAW, it all makes sense at first sight and IP forwarding should work for PPPoE and PPPoL2TP. Maybe we should allocate a PBUF_LINK for PPPoS as well. That would be a good idea for the forwarding case, I

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread Sylvain Rochet
Hello Charles, On Thu, Apr 10, 2014 at 06:37:02PM +, l...@moog.com wrote: Below is more debug information and hope it's helpful for fixing the problem. Regarding the code stalled at early stage, that's hardware related. I am using ARM7 (AT91SAM7 to be specific), so the data alignment is

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread LMao
=moog@nongnu.org] On Behalf Of Sylvain Rochet Sent: Thursday, April 10, 2014 3:49 PM To: Mailing list for lwIP users Subject: Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP) Hello Charles, On Thu, Apr 10, 2014 at 06:37:02PM +, l...@moog.com wrote: Below

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread Sylvain Rochet
Hello Charles, On Thu, Apr 10, 2014 at 08:03:13PM +, l...@moog.com wrote: Hi Sylvain, Good news, I got it work with your patch Yeah, happy to hear that. Here is another patch, which should fix the issue in a way that can be pushed to the repository, would you test it ? plus the

Re: [lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-10 Thread Sylvain Rochet
Hello, On Thu, Apr 10, 2014 at 08:44:43PM +0200, S G wrote: Sylvain Rochet wrote: PPPoE use PBUF_LINK, PPPoL2TP use PBUF_TRANSPORT, PPPoS use PBUF_RAW, it all makes sense at first sight and IP forwarding should work for PPPoE and PPPoL2TP. Maybe we should allocate a PBUF_LINK for PPPoS

[lwip-users] ppp-new IP forwarding only works one direction (Ethernet to PPP)

2014-04-09 Thread LMao
Hi Sylvain, I try to get IP forwarding work between two interfaces - Ethernet and PPP. So far, I can see it works in one direction, i.e., Packets from Ethernet can be forward to PPP, but it seems lwIP stack silently drop the packets in the opposite direction, i.e., from PPP to Ethernet. Can