Commit 49f74946 authored by Joe Perches's avatar Joe Perches Committed by Ingo Molnar

include/asm-x86/bitops_64.h: checkpatch cleanups - formatting only

Signed-off-by: default avatarJoe Perches <joe@perches.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent fd591acd
...@@ -17,35 +17,35 @@ static inline long __scanbit(unsigned long val, unsigned long max) ...@@ -17,35 +17,35 @@ static inline long __scanbit(unsigned long val, unsigned long max)
return val; return val;
} }
#define find_first_bit(addr,size) \
((__builtin_constant_p(size) && (size) <= BITS_PER_LONG ? \
(__scanbit(*(unsigned long *)addr,(size))) : \
find_first_bit(addr,size)))
#define find_next_bit(addr,size,off) \ #define find_next_bit(addr,size,off) \
((__builtin_constant_p(size) && (size) <= BITS_PER_LONG ? \ ((__builtin_constant_p(size) && (size) <= BITS_PER_LONG ? \
((off) + (__scanbit((*(unsigned long *)addr) >> (off),(size)-(off)))) : \ ((off) + (__scanbit((*(unsigned long *)addr) >> (off),(size)-(off)))) : \
find_next_bit(addr,size,off))) find_next_bit(addr,size,off)))
#define find_first_zero_bit(addr,size) \
((__builtin_constant_p(size) && (size) <= BITS_PER_LONG ? \
(__scanbit(~*(unsigned long *)addr,(size))) : \
find_first_zero_bit(addr,size)))
#define find_next_zero_bit(addr,size,off) \ #define find_next_zero_bit(addr,size,off) \
((__builtin_constant_p(size) && (size) <= BITS_PER_LONG ? \ ((__builtin_constant_p(size) && (size) <= BITS_PER_LONG ? \
((off)+(__scanbit(~(((*(unsigned long *)addr)) >> (off)),(size)-(off)))) : \ ((off)+(__scanbit(~(((*(unsigned long *)addr)) >> (off)),(size)-(off)))) : \
find_next_zero_bit(addr,size,off))) find_next_zero_bit(addr,size,off)))
static inline void set_bit_string(unsigned long *bitmap, unsigned long i, #define find_first_bit(addr, size) \
int len) ((__builtin_constant_p((size)) && (size) <= BITS_PER_LONG \
{ ? (__scanbit(*(unsigned long *)(addr), (size))) \
unsigned long end = i + len; : find_first_bit((addr), (size))))
#define find_first_zero_bit(addr, size) \
((__builtin_constant_p((size)) && (size) <= BITS_PER_LONG \
? (__scanbit(~*(unsigned long *)(addr), (size))) \
: find_first_zero_bit((addr), (size))))
static inline void set_bit_string(unsigned long *bitmap, unsigned long i,
int len)
{
unsigned long end = i + len;
while (i < end) { while (i < end) {
__set_bit(i, bitmap); __set_bit(i, bitmap);
i++; i++;
} }
} }
/** /**
* ffz - find first zero in word. * ffz - find first zero in word.
...@@ -150,10 +150,10 @@ static inline int fls(int x) ...@@ -150,10 +150,10 @@ static inline int fls(int x)
#include <asm-generic/bitops/ext2-non-atomic.h> #include <asm-generic/bitops/ext2-non-atomic.h>
#define ext2_set_bit_atomic(lock,nr,addr) \ #define ext2_set_bit_atomic(lock, nr, addr) \
test_and_set_bit((nr),(unsigned long*)addr) test_and_set_bit((nr), (unsigned long *)(addr))
#define ext2_clear_bit_atomic(lock,nr,addr) \ #define ext2_clear_bit_atomic(lock, nr, addr) \
test_and_clear_bit((nr),(unsigned long*)addr) test_and_clear_bit((nr), (unsigned long *)(addr))
#include <asm-generic/bitops/minix.h> #include <asm-generic/bitops/minix.h>
......
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