diff options
author | Krister Johansen <kjlx@templeofstupid.com> | 2017-01-05 22:23:31 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-03-12 06:41:47 +0100 |
commit | 11a4d644d6d84a34a393a389d5efd4e036b04a62 (patch) | |
tree | 793dc6c63b83a7b774bed66aeb6858586d4c4cb7 /crypto/testmgr.h | |
parent | 65013a93b6c335bd166c911d73c47ff4bcbdb8be (diff) |
perf callchain: Reference count maps
commit aa33b9b9a2ebb00d33c83a5312d4fbf2d5aeba36 upstream.
If dso__load_kcore frees all of the existing maps, but one has already
been attached to a callchain cursor node, then we can get a SIGSEGV in
any function that happens to try to use this invalid cursor. Use the
existing map refcount mechanism to forestall cleanup of a map until the
cursor iterates past the node.
Signed-off-by: Krister Johansen <kjlx@templeofstupid.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Masami Hiramatsu <mhiramat@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Fixes: 84c2cafa2889 ("perf tools: Reference count struct map")
Link: http://lkml.kernel.org/r/20170106062331.GB2707@templeofstupid.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'crypto/testmgr.h')
0 files changed, 0 insertions, 0 deletions