diff options
author | Till Straumann <strauman@slac.stanford.edu> | 2010-07-06 20:13:02 +0000 |
---|---|---|
committer | Till Straumann <strauman@slac.stanford.edu> | 2010-07-06 20:13:02 +0000 |
commit | 39507635f1feb32a94f515cf19286012c580b582 (patch) | |
tree | 3c8f2f60262c0ccfe383f6b70201a66e0ff3a273 /c/src/lib/libcpu/i386/byteorder.h | |
parent | 2010-07-06 Joel Sherrill <joel.sherrilL@OARcorp.com> (diff) | |
download | rtems-39507635f1feb32a94f515cf19286012c580b582.tar.bz2 |
2009-10-28 Till Straumann <strauman@slac.stanford.edu>
* byteorder.h: added ld_le16, st_le16.
Diffstat (limited to 'c/src/lib/libcpu/i386/byteorder.h')
-rw-r--r-- | c/src/lib/libcpu/i386/byteorder.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/c/src/lib/libcpu/i386/byteorder.h b/c/src/lib/libcpu/i386/byteorder.h index 06a3e22bb9..c63e25cf0a 100644 --- a/c/src/lib/libcpu/i386/byteorder.h +++ b/c/src/lib/libcpu/i386/byteorder.h @@ -19,4 +19,15 @@ static inline uint32_t ld_le32(volatile uint32_t *addr) return(*addr); } +static inline void st_le16(volatile uint16_t *addr, uint16_t value) +{ + *(addr)=value ; +} + +static inline uint16_t ld_le16(volatile uint16_t *addr) +{ + return(*addr); +} + + #endif |