aboutsummaryrefslogtreecommitdiff
path: root/mm/debug-pagealloc.c
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2014-08-15 16:06:06 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-10-05 14:54:13 -0700
commit5df644fd609cd0610a77dd13eed9729bd2eefbd5 (patch)
tree98c47c483fc713beac0aea32ddddc9137ba04ea8 /mm/debug-pagealloc.c
parentf9c27a7c7880c29c7579dea9134dfef355f6c3eb (diff)
percpu: fix pcpu_alloc_pages() failure path
commit f0d279654dea22b7a6ad34b9334aee80cda62cde upstream. When pcpu_alloc_pages() fails midway, pcpu_free_pages() is invoked to free what has already been allocated. The invocation is across the whole requested range and pcpu_free_pages() will try to free all non-NULL pages; unfortunately, this is incorrect as pcpu_get_pages_and_bitmap(), unlike what its comment suggests, doesn't clear the pages array and thus the array may have entries from the previous invocations making the partial failure path free incorrect pages. Fix it by open-coding the partial freeing of the already allocated pages. Signed-off-by: Tejun Heo <tj@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'mm/debug-pagealloc.c')
0 files changed, 0 insertions, 0 deletions