Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
[deliverable/linux.git] / arch / arm / include / asm / bitrev.h
CommitLineData
0b7857db
YW
1#ifndef __ASM_BITREV_H
2#define __ASM_BITREV_H
3
4static __always_inline __attribute_const__ u32 __arch_bitrev32(u32 x)
5{
6 __asm__ ("rbit %0, %1" : "=r" (x) : "r" (x));
7 return x;
8}
9
10static __always_inline __attribute_const__ u16 __arch_bitrev16(u16 x)
11{
12 return __arch_bitrev32((u32)x) >> 16;
13}
14
15static __always_inline __attribute_const__ u8 __arch_bitrev8(u8 x)
16{
17 return __arch_bitrev32((u32)x) >> 24;
18}
19
20#endif
This page took 0.068341 seconds and 5 git commands to generate.