diff options
Diffstat (limited to 'include/asm-mips/byteorder.h')
-rw-r--r-- | include/asm-mips/byteorder.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/asm-mips/byteorder.h b/include/asm-mips/byteorder.h index 584f8128fff..4ce5bc37f40 100644 --- a/include/asm-mips/byteorder.h +++ b/include/asm-mips/byteorder.h @@ -19,7 +19,9 @@ static __inline__ __attribute_const__ __u16 ___arch__swab16(__u16 x) { __asm__( + " .set mips32r2 \n" " wsbh %0, %1 \n" + " .set mips0 \n" : "=r" (x) : "r" (x)); @@ -30,8 +32,10 @@ static __inline__ __attribute_const__ __u16 ___arch__swab16(__u16 x) static __inline__ __attribute_const__ __u32 ___arch__swab32(__u32 x) { __asm__( + " .set mips32r2 \n" " wsbh %0, %1 \n" " rotr %0, %0, 16 \n" + " .set mips0 \n" : "=r" (x) : "r" (x)); |