[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [lwip-users] DHCP issues....problem found; how do I solve it?
From: |
Tom C. Barker |
Subject: |
RE: [lwip-users] DHCP issues....problem found; how do I solve it? |
Date: |
Mon, 1 Dec 2003 08:21:14 -0800 |
This has been set all the time. If I take out the
memcpy, DHCP never gets a properly formed REQUEST out.
#define MEM_ALIGNMENT 4
Thanks,
Tom
-----Original Message-----
From: Leon Woestenberg [mailto:address@hidden
Sent: Sunday, November 30, 2003 11:44 AM
To: Mailing list for lwIP users; Discussion of development issues
regarding lwIP.
Subject: Re: [lwip-users] DHCP issues....problem found; how do I solve
it?
Hello Tom
----- Original Message -----
From: "Tom C. Barker" <address@hidden>
To: "'Mailing list for lwIP users'" <address@hidden>
Sent: Wednesday, November 26, 2003 1:09 AM
Subject: [lwip-users] DHCP issues....problem found; how do I solve it?
> The issue of malformed packets is that on the Coldfire5282,
> the transmit buffer must be 4-byte aligned.
>
> I confirmed the proper working of DHCP by creating a 4-byte
> aligned buffer and then doing a memcpy every time (ugh!) in
> low_level_output: this idea fails in many areas but proves that
> DHCP is working just fine.
>
> How do I align _any_ packet so that after the TCP/UDP and IP
> headers are tacked on, I end up with a 4-byte aligned buffer?
>
> Anybody got an idea (shy of a total rewrite)? Hopefully I have
> overlooked something....
>
Have you tried setting this define to 4?
/* ---------- Memory options ---------- */
/* MEM_ALIGNMENT: should be set to the alignment of the CPU for which
lwIP is compiled. 4 byte alignment -> define MEM_ALIGNMENT to 4, 2
byte alignment -> define MEM_ALIGNMENT to 2. */
#define MEM_ALIGNMENT 4
Let us know if this works, thanks,
Leon.
_______________________________________________
lwip-users mailing list
address@hidden
http://mail.gnu.org/mailman/listinfo/lwip-users
- RE: [lwip-users] DHCP issues....problem found; how do I solve it?,
Tom C. Barker <=