summaryrefslogtreecommitdiffstats
path: root/.gitignore
diff options
context:
space:
mode:
authorKAMEZAWA Hiroyuki2012-10-19 10:00:55 +0200
committerLinus Torvalds2012-10-19 23:32:10 +0200
commit9e7814404b77c3e8920bee4277162bf3a7460505 (patch)
treef7542b049f29150680507dd211925401beadac9a /.gitignore
parentMerge branch 'x86/urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/ti... (diff)
downloadkernel-qcow2-linux-9e7814404b77c3e8920bee4277162bf3a7460505.tar.gz
kernel-qcow2-linux-9e7814404b77c3e8920bee4277162bf3a7460505.tar.xz
kernel-qcow2-linux-9e7814404b77c3e8920bee4277162bf3a7460505.zip
hold task->mempolicy while numa_maps scans.
/proc/<pid>/numa_maps scans vma and show mempolicy under mmap_sem. It sometimes accesses task->mempolicy which can be freed without mmap_sem and numa_maps can show some garbage while scanning. This patch tries to take reference count of task->mempolicy at reading numa_maps before calling get_vma_policy(). By this, task->mempolicy will not be freed until numa_maps reaches its end. V2->v3 - updated comments to be more verbose. - removed task_lock() in numa_maps code. V1->V2 - access task->mempolicy only once and remember it. Becase kernel/exit.c can overwrite it. Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Acked-by: David Rientjes <rientjes@google.com> Acked-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to '.gitignore')
0 files changed, 0 insertions, 0 deletions