aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorOleg Nesterov <[email protected]>2013-07-03 15:08:22 -0700
committerLinus Torvalds <[email protected]>2013-07-03 16:08:02 -0700
commit3ceadcf6d489650ade673b7197c11c521aecb038 (patch)
treee9c0e9a77cc28d9a8040b41f5699b9da4556fb0c /tools/perf/scripts/python
parent923bed030ff6e20b5176e10da151fade83097891 (diff)
coredump: kill call_count, add core_name_size
Imho, "atomic_t call_count" is ugly and should die. It buys nothing and in fact it can grow more than necessary, expand doesn't check if it was already incremented by another task. Kill it, and introduce "static int core_name_size" updated by expand_corename(). This is obviously racy too but harmless, and core_name_size never grows for no reason. We do not bother to to calculate the "right" new size, we simply do kmalloc(size_we_need) and use ksize() to rely on kmalloc_index's decision. Finally change format_corename() to use expand_corename(), krealloc(NULL) is fine. Signed-off-by: Oleg Nesterov <[email protected]> Cc: Andi Kleen <[email protected]> Cc: Colin Walters <[email protected]> Cc: Denys Vlasenko <[email protected]> Cc: Jiri Slaby <[email protected]> Cc: Lennart Poettering <[email protected]> Cc: Lucas De Marchi <[email protected]> Acked-by: Neil Horman <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions