[En-Nut-Discussion] IP Checksum calculation broken. Reenabled old algorithm for the meantime.

Ole Reinhardt ole.reinhardt at embedded-it.de
Mon Jun 18 10:34:48 CEST 2012

Moin Harald,

> Ole, which CPU did you use?

I'm using LPC1778 with trunk HEAD.

> Regarding alignment: In r4028 I added a 2 byte offset to the network
> buffer, which aligns them to (32 + 16)-bit addresses. Due to the 14
> byte Ethernet header, this aligns the IP part to a 32-bit address.

Ok, so in general the alignment should always be the same, right? There
is no chance that we have a 4+2 byte alignment in one situation and a 4
byte alignment in another?

What's about the ICMP checksum thing where we calculate the checksum
just over a part of the ICMP packet data?

> > @Harald: Do you have any ideas what I could do for better testing and
> > evaluating the problem?
> Testing it with network traffic is cumbersome. For testing I add the
> legacy and the new code to the application and call them directly with
> a prepared buffer.

I'll do so with some test code later.




Thermotemp GmbH, Embedded-IT

Embedded Hard-/ Software and Open Source Development, 
Integration and Consulting


Geschäftsstelle Siegen - Steinstraße 67 - D-57072 Siegen - 
tel +49 (0)271 5513597, +49 (0)271-73681 - fax +49 (0)271 736 97

Hauptsitz - Hademarscher Weg 7 - 13503 Berlin
Tel +49 (0)30 4315205 - Fax +49 (0)30 43665002
Geschäftsführer: Jörg Friedrichs, Ole Reinhardt
Handelsregister Berlin Charlottenburg HRB 45978 UstID DE 156329280 

More information about the En-Nut-Discussion mailing list