[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [lwip-users] lwip + sam7x = udef exception
From: |
Kieran Mansley |
Subject: |
RE: [lwip-users] lwip + sam7x = udef exception |
Date: |
Wed, 14 Feb 2007 12:52:24 +0000 |
On Wed, 2007-02-14 at 12:23 +0000, B B wrote:
>
> Hi again,
>
> correction to the below, the address calculated
> is resulting in a 2 byte aligned value and not 4 byte as required.
>
> (struct tcp_hdr *)((u8_t *)p->payload + IPH_HL(iphdr) * 4) =
> 0x0020b1fa
This suggests that p->payload is also not 4-byte aligned (as "+ IPH_HL
(iphdr) * 4" should not change the bottom 2 bits), which in turn
suggests that when the data was put into the pbuf, it wasn't done in a
way that guarantees the headers and payloads will fall on the required
alignment. For example, with ethernet which has 14 byte headers, a
driver will normally arrange to put the ethernet header on at a 2 byte
offset, so that the IP header, TCP header and packet data all align on 4
byte boundaries.
How are you creating and filling your packet buffers?
Kieran
- [lwip-users] lwip + sam7x = udef exception, B B, 2007/02/13
- RE: [lwip-users] lwip + sam7x = udef exception, B B, 2007/02/14
- RE: [lwip-users] lwip + sam7x = udef exception, B B, 2007/02/14
- RE: [lwip-users] lwip + sam7x = udef exception, B B, 2007/02/14
- RE: [lwip-users] lwip + sam7x = udef exception,
Kieran Mansley <=
- RE: [lwip-users] lwip + sam7x = udef exception, Goldschmidt Simon, 2007/02/15
- RE: [lwip-users] lwip + sam7x = udef exception, Kieran Mansley, 2007/02/15
- RE: [lwip-users] lwip + sam7x = udef exception, Goldschmidt Simon, 2007/02/15
- RE: [lwip-users] lwip + sam7x = udef exception, Kieran Mansley, 2007/02/15
- RE: [lwip-users] lwip + sam7x = udef exception, Goldschmidt Simon, 2007/02/15
Re: [lwip-users] lwip + sam7x = udef exception, Çağlar AKYÜZ, 2007/02/14
RE: [lwip-users] lwip + sam7x = udef exception, B B, 2007/02/15
RE: [lwip-users] lwip + sam7x = udef exception, B B, 2007/02/16