diff options
author | David Howells <dhowells@redhat.com> | 2006-01-06 03:11:59 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-06 11:33:36 -0500 |
commit | d89c145c0344fe2180336af6a309a59a8bc8c1c0 (patch) | |
tree | 3b124a740d14ef298117b4ad0732e075ed970e4b /include | |
parent | 2684927c6b938ec7a679891e0ec1fa0709c521bd (diff) |
[PATCH] x86: handle -Wsign-compare in bitops
Make i386's find_first_bit() use an unsigned integer as a counter to avoid
getting warnings when -Wsign-compare is given.
Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-i386/bitops.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/asm-i386/bitops.h b/include/asm-i386/bitops.h index 4807aa1d2e3d..26eb9811712f 100644 --- a/include/asm-i386/bitops.h +++ b/include/asm-i386/bitops.h | |||
@@ -332,9 +332,9 @@ static inline unsigned long __ffs(unsigned long word) | |||
332 | * Returns the bit-number of the first set bit, not the number of the byte | 332 | * Returns the bit-number of the first set bit, not the number of the byte |
333 | * containing a bit. | 333 | * containing a bit. |
334 | */ | 334 | */ |
335 | static inline int find_first_bit(const unsigned long *addr, unsigned size) | 335 | static inline unsigned find_first_bit(const unsigned long *addr, unsigned size) |
336 | { | 336 | { |
337 | int x = 0; | 337 | unsigned x = 0; |
338 | 338 | ||
339 | while (x < size) { | 339 | while (x < size) { |
340 | unsigned long val = *addr++; | 340 | unsigned long val = *addr++; |