diff options
author | Catalin Marinas <[email protected]> | 2016-10-27 17:46:47 -0700 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2016-10-27 18:43:43 -0700 |
commit | 37df49f433bc3a11f5716fe65aaec5189c6402cb (patch) | |
tree | 60265296d843c73e11f962bdf7560f0bb2bad43c /tools/perf/scripts/python/call-graph-from-postgresql.py | |
parent | 02754e0a484a50a92d44c38879f2cb2792ebc572 (diff) |
mm: kmemleak: ensure that the task stack is not freed during scanning
Commit 68f24b08ee89 ("sched/core: Free the stack early if
CONFIG_THREAD_INFO_IN_TASK") may cause the task->stack to be freed
during kmemleak_scan() execution, leading to either a NULL pointer fault
(if task->stack is NULL) or kmemleak accessing already freed memory.
This patch uses the new try_get_task_stack() API to ensure that the task
stack is not freed during kmemleak stack scanning.
Addresses https://bugzilla.kernel.org/show_bug.cgi?id=173901.
Fixes: 68f24b08ee89 ("sched/core: Free the stack early if CONFIG_THREAD_INFO_IN_TASK")
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Catalin Marinas <[email protected]>
Reported-by: CAI Qian <[email protected]>
Tested-by: CAI Qian <[email protected]>
Acked-by: Michal Hocko <[email protected]>
Cc: Andy Lutomirski <[email protected]>
Cc: CAI Qian <[email protected]>
Cc: Hillf Danton <[email protected]>
Cc: Oleg Nesterov <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions