[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] IP is longer than pbuf
From: |
Kieran Mansley |
Subject: |
Re: [lwip-users] IP is longer than pbuf |
Date: |
Sat, 21 Jul 2012 15:11:16 +0100 |
On 21 Jul 2012, at 12:14, Nico Sachs wrote:
> netif: input length = 60
> pbuf_alloc(length=62)
> pbuf_alloc: allocated pbuf 79C4
> pbuf_alloc(length=62) == 79C4
> pbuf_header: old 79D4 new 79D6 (-2)
> pbuf_header: old 79D6 new 79D4 (2)
> tcpip_thread: PACKET 7714
> pbuf_header: old 79D4 new 79E4 (-16)
> IP (len 52) is longer than pbuf (len 46), IP packet dropped.
At the netif input stage you have 60 bytes, which will I think include the
ethernet header (14 bytes). That leaves 46 bytes of IP packet, which is the
value that the pbuf ends up as, so that calculation is correct. However the IP
header says there should be 52 bytes (or more in your subsequent post). So my
guess is that your netif driver is not passing up all the data. Perhaps you
have pbufs of length 60 and the driver is supposed to chain many of them
together with all the data, but it isn't doing this correctly?
Kieran