diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-10-29 08:46:28 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-10-29 08:46:28 -0700 |
commit | 94b086b243e112030b815b76e61de6523e6fc700 (patch) | |
tree | 3c7f2308e7e5afdb276a858c4960754168a92d8c /lib/genalloc.c | |
parent | 967857dfd990081f6702daebc6c9bc6f4ba7a39e (diff) | |
parent | 8f0d8163b50e01f398b14bcd4dc039ac5ab18d64 (diff) |
Merge 3.7-rc3 into driver-core-next
This pulls in the various driver core changes that were in 3.7-rc3 into the
driver-core-next branch.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'lib/genalloc.c')
-rw-r--r-- | lib/genalloc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/genalloc.c b/lib/genalloc.c index ca208a92628..54920433705 100644 --- a/lib/genalloc.c +++ b/lib/genalloc.c @@ -178,7 +178,7 @@ int gen_pool_add_virt(struct gen_pool *pool, unsigned long virt, phys_addr_t phy struct gen_pool_chunk *chunk; int nbits = size >> pool->min_alloc_order; int nbytes = sizeof(struct gen_pool_chunk) + - (nbits + BITS_PER_BYTE - 1) / BITS_PER_BYTE; + BITS_TO_LONGS(nbits) * sizeof(long); chunk = kmalloc_node(nbytes, GFP_KERNEL | __GFP_ZERO, nid); if (unlikely(chunk == NULL)) |