Commit e0c4ae06 authored by Mike Frysinger's avatar Mike Frysinger Committed by Ingo Molnar

x86: fix asm-x86/byteorder.h for userspace export

Since asm-x86/byteorder.h is exported to userspace, use __asm__ rather than
asm in its code.
Signed-Off-By: default avatarMike Frysinger <vapier@gentoo.org>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent e697789d
...@@ -30,13 +30,13 @@ static __inline__ __attribute_const__ __u64 ___arch__swab64(__u64 val) ...@@ -30,13 +30,13 @@ static __inline__ __attribute_const__ __u64 ___arch__swab64(__u64 val)
} v; } v;
v.u = val; v.u = val;
#ifdef CONFIG_X86_BSWAP #ifdef CONFIG_X86_BSWAP
asm("bswapl %0 ; bswapl %1 ; xchgl %0,%1" __asm__("bswapl %0 ; bswapl %1 ; xchgl %0,%1"
: "=r" (v.s.a), "=r" (v.s.b) : "=r" (v.s.a), "=r" (v.s.b)
: "0" (v.s.a), "1" (v.s.b)); : "0" (v.s.a), "1" (v.s.b));
#else #else
v.s.a = ___arch__swab32(v.s.a); v.s.a = ___arch__swab32(v.s.a);
v.s.b = ___arch__swab32(v.s.b); v.s.b = ___arch__swab32(v.s.b);
asm("xchgl %0,%1" : "=r" (v.s.a), "=r" (v.s.b) : "0" (v.s.a), "1" (v.s.b)); __asm__("xchgl %0,%1" : "=r" (v.s.a), "=r" (v.s.b) : "0" (v.s.a), "1" (v.s.b));
#endif #endif
return v.u; return v.u;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment