diff options
author | Akinobu Mita <akinobu.mita@gmail.com> | 2011-05-26 19:26:06 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-05-26 20:12:38 -0400 |
commit | a2812e178321132811a53f7be40fe7e9bbffd9e0 (patch) | |
tree | 5e1ae6d683d964cce8b4f107d8032522ac69b372 /arch/arm/include/asm | |
parent | e0819410dba141338ebf6ab1057c1863be6247ab (diff) |
arch: add #define for each of optimized find bitops
The style that we normally use in asm-generic is to test the macro itself
for existence, so in asm-generic, do:
#ifndef find_next_zero_bit_le
extern unsigned long find_next_zero_bit_le(const void *addr,
unsigned long size, unsigned long offset);
#endif
and in the architectures, write
static inline unsigned long find_next_zero_bit_le(const void *addr,
unsigned long size, unsigned long offset)
#define find_next_zero_bit_le find_next_zero_bit_le
This adds the #define for each of the optimized find bitops in the
architectures.
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Acked-by: Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>
Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Greg Ungerer <gerg@uclinux.org>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/arm/include/asm')
-rw-r--r-- | arch/arm/include/asm/bitops.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/arm/include/asm/bitops.h b/arch/arm/include/asm/bitops.h index 6b7403fd8f54..18a024b7b676 100644 --- a/arch/arm/include/asm/bitops.h +++ b/arch/arm/include/asm/bitops.h | |||
@@ -326,16 +326,19 @@ static inline int find_first_zero_bit_le(const void *p, unsigned size) | |||
326 | { | 326 | { |
327 | return _find_first_zero_bit_le(p, size); | 327 | return _find_first_zero_bit_le(p, size); |
328 | } | 328 | } |
329 | #define find_first_zero_bit_le find_first_zero_bit_le | ||
329 | 330 | ||
330 | static inline int find_next_zero_bit_le(const void *p, int size, int offset) | 331 | static inline int find_next_zero_bit_le(const void *p, int size, int offset) |
331 | { | 332 | { |
332 | return _find_next_zero_bit_le(p, size, offset); | 333 | return _find_next_zero_bit_le(p, size, offset); |
333 | } | 334 | } |
335 | #define find_next_zero_bit_le find_next_zero_bit_le | ||
334 | 336 | ||
335 | static inline int find_next_bit_le(const void *p, int size, int offset) | 337 | static inline int find_next_bit_le(const void *p, int size, int offset) |
336 | { | 338 | { |
337 | return _find_next_bit_le(p, size, offset); | 339 | return _find_next_bit_le(p, size, offset); |
338 | } | 340 | } |
341 | #define find_next_bit_le find_next_bit_le | ||
339 | 342 | ||
340 | /* | 343 | /* |
341 | * Ext2 is defined to use little-endian byte ordering. | 344 | * Ext2 is defined to use little-endian byte ordering. |