diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-10-30 06:25:44 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-10-30 06:25:44 -0400 |
commit | d4608a83f78b489822d0f378acf752c8b71a750c (patch) | |
tree | f8e8751691042de8e7bad413034cbb2bb03ed2e5 /lib/genalloc.c | |
parent | e334cd69fa65fc9e916d6adc8d860a9b6b9e7281 (diff) | |
parent | a909d3e636995ba7c349e2ca5dbb528154d4ac30 (diff) |
Merge 4.9-rc3 into char-misc-next
We need the binder patches in here to build on for other submitted
patches to apply properly.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'lib/genalloc.c')
-rw-r--r-- | lib/genalloc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/genalloc.c b/lib/genalloc.c index 0a1139644d328..144fe6b1a03ea 100644 --- a/lib/genalloc.c +++ b/lib/genalloc.c @@ -292,7 +292,7 @@ unsigned long gen_pool_alloc_algo(struct gen_pool *pool, size_t size, struct gen_pool_chunk *chunk; unsigned long addr = 0; int order = pool->min_alloc_order; - int nbits, start_bit = 0, end_bit, remain; + int nbits, start_bit, end_bit, remain; #ifndef CONFIG_ARCH_HAVE_NMI_SAFE_CMPXCHG BUG_ON(in_nmi()); @@ -307,6 +307,7 @@ unsigned long gen_pool_alloc_algo(struct gen_pool *pool, size_t size, if (size > atomic_read(&chunk->avail)) continue; + start_bit = 0; end_bit = chunk_size(chunk) >> order; retry: start_bit = algo(chunk->bits, end_bit, start_bit, |