1 #ifndef _ASM_GENERIC_BITOPS_LE_H_
2 #define _ASM_GENERIC_BITOPS_LE_H_
5 #include <asm/byteorder.h>
7 #if defined(__LITTLE_ENDIAN)
9 #define BITOP_LE_SWIZZLE 0
29 #elif defined(__BIG_ENDIAN)
31 #define BITOP_LE_SWIZZLE ((BITS_PER_LONG-1) & ~0x7)
33 #ifndef find_next_zero_bit_le
38 #ifndef find_next_bit_le
43 #ifndef find_first_zero_bit_le
44 #define find_first_zero_bit_le(addr, size) \
45 find_next_zero_bit_le((addr), (size), 0)
49 #error "Please fix <asm/byteorder.h>"
52 static inline int test_bit_le(
int nr,
const void *
addr)
54 return test_bit(nr ^ BITOP_LE_SWIZZLE, addr);
57 static inline void set_bit_le(
int nr,
void *
addr)
59 set_bit(nr ^ BITOP_LE_SWIZZLE, addr);
62 static inline void clear_bit_le(
int nr,
void *
addr)
67 static inline void __set_bit_le(
int nr,
void *
addr)
72 static inline void __clear_bit_le(
int nr,
void *
addr)
77 static inline int test_and_set_bit_le(
int nr,
void *
addr)
82 static inline int test_and_clear_bit_le(
int nr,
void *
addr)
87 static inline int __test_and_set_bit_le(
int nr,
void *
addr)
92 static inline int __test_and_clear_bit_le(
int nr,
void *
addr)