Problem with TCP socket on RTEMS 4.8.1 (ARM BSP)

Ralf Corsepius ralf.corsepius at rtems.org
Tue Sep 2 13:43:53 UTC 2008


On Tue, 2008-09-02 at 08:32 -0500, Joel Sherrill wrote:
> Gene Smith wrote:
> > Alex Zolotov wrote, On 09/01/2008 01:41 AM:
> >   
> >> Thank you.
> >> It seems, that problem same as described by Gene Smith
> >> (http://www.rtems.com/ml/rtems-users/2008/august/msg00073.html) in his
> >> post "Little Endian ARM fails on 1st TCP datagram". The reason is that
> >> BYTE_ORDER BIG_ENDIAN defined during compiling TCP functions.
> >>
> >>     
> >
> > Yes, this BYTE_ORDER macro seems to be a current problem at least for
> > ARM. Also mentioned in the previous thread.  -gene
> >
> >   
> Just to beat this one into submission.
There is a bug in vanilla newlib, which has been supposed "fixed" in all
current toolchain version - Otherwise we would not have been able to
build rtems :)

My most recent rtems-4.10-newlib patches contain another patch, which is
trying to catch a corner case, we have been discarding so far.

>   Are we are running the
> ARM in big or little endian mode?
Little endian.

> If little endian, then the compiler has the correct predefine.
Right.

> /opt/rtems-4.10/bin/arm-rtems4.10-gcc
> #define __ARMEL__ 1
> /opt/rtems-4.6/bin/arm-rtems-gcc
> #define __ARMEL__ 1
> /opt/rtems-4.7/bin/arm-rtems4.7-gcc
> #define __ARMEL__ 1
> /opt/rtems-4.8/bin/arm-rtems4.8-gcc
> #define __ARMEL__ 1
> /opt/rtems-4.9/bin/arm-rtems4.9-gcc
> #define __ARMEL__ 1
> 
> Where is the breakdown?
Wish I knew that ;)

Ralf





More information about the users mailing list