Skip to content

Commit

Permalink
[PATCH] genalloc warning fixes
Browse files Browse the repository at this point in the history
lib/genalloc.c: In function 'gen_pool_alloc':
lib/genalloc.c:151: warning: passing argument 2 of '__set_bit' from incompatible pointer type
lib/genalloc.c: In function 'gen_pool_free':
lib/genalloc.c:190: warning: passing argument 2 of '__clear_bit' from incompatible pointer type

Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
akpm00 authored and Linus Torvalds committed Feb 21, 2007
1 parent 2be3c79 commit 96c62d5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/genalloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ unsigned long gen_pool_alloc(struct gen_pool *pool, size_t size)
addr = chunk->start_addr +
((unsigned long)start_bit << order);
while (nbits--)
__set_bit(start_bit++, &chunk->bits);
__set_bit(start_bit++, chunk->bits);
spin_unlock_irqrestore(&chunk->lock, flags);
read_unlock(&pool->lock);
return addr;
Expand Down Expand Up @@ -187,7 +187,7 @@ void gen_pool_free(struct gen_pool *pool, unsigned long addr, size_t size)
spin_lock_irqsave(&chunk->lock, flags);
bit = (addr - chunk->start_addr) >> order;
while (nbits--)
__clear_bit(bit++, &chunk->bits);
__clear_bit(bit++, chunk->bits);
spin_unlock_irqrestore(&chunk->lock, flags);
break;
}
Expand Down

0 comments on commit 96c62d5

Please sign in to comment.