diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2002-10-04 14:47:11 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2002-10-04 14:47:11 +0000 |
commit | 3fb76805139ef1cc04a8ed234febf335c50f5a02 (patch) | |
tree | b3d82e925ff5c475ec1d53f42478a591399ce559 /cpukit/libnetworking/sys/queue.h | |
parent | 2002-10-02 Chris Johns <cjohns@cybertec.com.au> (diff) | |
download | rtems-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 '')
-rw-r--r-- | cpukit/libnetworking/sys/queue.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/cpukit/libnetworking/sys/queue.h b/cpukit/libnetworking/sys/queue.h index e8aa08cf5d..6ebc7dce3d 100644 --- a/cpukit/libnetworking/sys/queue.h +++ b/cpukit/libnetworking/sys/queue.h @@ -413,6 +413,35 @@ struct quehead { #ifdef __GNUC__ +#if (defined(__GNUC__) && defined(__arm__)) +static __inline void +insque(void *a, void *b) +{ + struct quehead *element; + struct quehead *head; + element = (struct quehead *) (((unsigned int) a + 0x3) & ~0x3); + head = (struct quehead *) (((unsigned int) b + 0x3) & ~0x3); + + element->qh_link = head->qh_link; + element->qh_rlink = head; + head->qh_link = element; + element->qh_link->qh_rlink = element; +} + +static __inline void +remque(void *a) +{ + struct quehead *element; + + element = (struct quehead *) (((unsigned int) a + 0x3) & ~0x3); + + element->qh_link->qh_rlink = element->qh_rlink; + element->qh_rlink->qh_link = element->qh_link; + element->qh_rlink = 0; +} + +#else /*if (defined(__GNUC__) && defined(__arm__))*/ + static __inline void insque(void *a, void *b) { @@ -433,6 +462,7 @@ remque(void *a) element->qh_rlink->qh_link = element->qh_link; element->qh_rlink = 0; } +#endif /*if-else (defined(__GNUC__) && defined(__arm__))*/ #else /* !__GNUC__ */ |