[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
PowerPC in_cksum() needs -O (was: Re: Loopback test failing, not returning from rtems_bsdnet_event_receive())
- Date: Mon, 21 Sep 2009 17:00:38 -0400
- From: dufault at hda.com (Peter Dufault)
- Subject: PowerPC in_cksum() needs -O (was: Re: Loopback test failing, not returning from rtems_bsdnet_event_receive())
On Sep 21, 2009, at 2:12 , Peter Dufault wrote:
> I've tracked it down to everything getting dropped with a bad
> checksum in tcp_input() at line 321.
I had built with optimization off for debugging. Without optimization
in_cksum() is returning 1. With -O2 in effect it is returning 0.
I put a breakpoint right after the call to in_cksum() with the only
change recompiling tcp_input.c with and without optimization.
Checksum with tcp_input.c compiled with -O2:
(gdb) print ti->ti_t.th_sum
$1 = 0x0
(gdb)
Checksum with tcp_input.c compiled without any optimization:
(gdb) print ti->ti_t.th_sum
$1 = 0x1
(gdb)
I'll open a bug.
Peter