]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit - mm/percpu-vm.c
percpu: remove @may_alloc from pcpu_get_pages()
authorTejun Heo <tj@kernel.org>
Tue, 2 Sep 2014 18:46:01 +0000 (14:46 -0400)
committerTejun Heo <tj@kernel.org>
Tue, 2 Sep 2014 18:46:01 +0000 (14:46 -0400)
commitcdb4cba5a3c9fa27240d04f4f8dad316b10d995b
tree6238aeb94660eda94e9bb37f227a6531bb4a8e22
parentfbbb7f4e149f6dd19a8dbebc9fa5c5b72173c6de
percpu: remove @may_alloc from pcpu_get_pages()

pcpu_get_pages() creates the temp pages array if not already allocated
and returns the pointer to it.  As the function is called from both
[de]population paths and depopulation can only happen after at least
one successful population, the param doesn't make any difference - the
allocation will always happen on the population path anyway.

Remove @may_alloc from pcpu_get_pages().  Also, add an lockdep
assertion pcpu_alloc_mutex instead of vaguely stating that the
exclusion is the caller's responsibility.

Signed-off-by: Tejun Heo <tj@kernel.org>
mm/percpu-vm.c