summaryrefslogtreecommitdiffstats
path: root/cpukit/libnetworking/netinet/tcp_var.h
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2002-10-04 14:47:11 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2002-10-04 14:47:11 +0000
commit3fb76805139ef1cc04a8ed234febf335c50f5a02 (patch)
treeb3d82e925ff5c475ec1d53f42478a591399ce559 /cpukit/libnetworking/netinet/tcp_var.h
parent2002-10-02 Chris Johns <cjohns@cybertec.com.au> (diff)
downloadrtems-3fb76805139ef1cc04a8ed234febf335c50f5a02.tar.bz2
2002-10-04 Jay Monkman <jtm@smoothsmoothie.com>
* netinet/in_cksum.c, netinet/ip_icmp.h, netinet/ip_input.c, netinet/tcp_input.c, netinet/tcp_subr.c, netinet/tcp_var.h, sys/queue.h: Address alignment requirements for the ARM.
Diffstat (limited to 'cpukit/libnetworking/netinet/tcp_var.h')
-rw-r--r--cpukit/libnetworking/netinet/tcp_var.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/cpukit/libnetworking/netinet/tcp_var.h b/cpukit/libnetworking/netinet/tcp_var.h
index 8e63a2cafe..3c4c5f8c89 100644
--- a/cpukit/libnetworking/netinet/tcp_var.h
+++ b/cpukit/libnetworking/netinet/tcp_var.h
@@ -225,7 +225,16 @@ struct rmxp_tao {
* port numbers (which are no longer needed once we've located the
* tcpcb) are overlayed with an mbuf pointer.
*/
-#define REASS_MBUF(ti) (*(struct mbuf **)&((ti)->ti_t))
+#if (defined(__GNUC__) && defined(__arm__))
+#define STR32_UNALGN(ti,m) \
+ (ti)->ti_sport = (unsigned short)(((unsigned int) m & 0xffff0000) >> 16); \
+ (ti)->ti_dport = (unsigned short) ((unsigned int) m & 0x0000ffff);
+#define LD32_UNALGN(ti,m) \
+ m = (struct mbuf *)((((unsigned int) (ti)->ti_sport) << 16) | ( (unsigned int)(ti)->ti_dport));
+
+#else
+#define REASS_MBUF(ti) (*(mbuf_packed **)&((ti)->ti_t))
+#endif
/*
* TCP statistics.