提交 e48b30c1 编写于 作者: K Ken Chen 提交者: Andi Kleen

[PATCH] i386: type cast clean up for find_next_zero_bit

clean up unneeded type cast by properly declare data type.
Signed-off-by: NKen Chen <kenchen@google.com>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NAndi Kleen <ak@suse.de>
上级 30a1528d
...@@ -43,7 +43,7 @@ EXPORT_SYMBOL(find_next_bit); ...@@ -43,7 +43,7 @@ EXPORT_SYMBOL(find_next_bit);
*/ */
int find_next_zero_bit(const unsigned long *addr, int size, int offset) int find_next_zero_bit(const unsigned long *addr, int size, int offset)
{ {
unsigned long * p = ((unsigned long *) addr) + (offset >> 5); const unsigned long *p = addr + (offset >> 5);
int set = 0, bit = offset & 31, res; int set = 0, bit = offset & 31, res;
if (bit) { if (bit) {
...@@ -64,7 +64,7 @@ int find_next_zero_bit(const unsigned long *addr, int size, int offset) ...@@ -64,7 +64,7 @@ int find_next_zero_bit(const unsigned long *addr, int size, int offset)
/* /*
* No zero yet, search remaining full bytes for a zero * No zero yet, search remaining full bytes for a zero
*/ */
res = find_first_zero_bit (p, size - 32 * (p - (unsigned long *) addr)); res = find_first_zero_bit(p, size - 32 * (p - addr));
return (offset + set + res); return (offset + set + res);
} }
EXPORT_SYMBOL(find_next_zero_bit); EXPORT_SYMBOL(find_next_zero_bit);
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册