diff options
author | Steven Rostedt <srostedt@redhat.com> | 2010-06-18 16:18:02 -0400 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2010-06-18 16:18:02 -0400 |
commit | a54bf34429363367d7567bfd1f0ebc5fc807f598 (patch) | |
tree | dd7288854ea91e46f1a248a81003207abff10d89 | |
parent | c63d1ad98b9e61ca48d58eba442eaa645859249c (diff) |
trace-plot: Fix filtering of event boxes in graph
The graph was using the "orig_pid" to determine if it should display
the box (process running) or not. But this only worked when we had
sched events available. When schedule events were enabled, this would
fail the tests.
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
-rw-r--r-- | trace-plot-cpu.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/trace-plot-cpu.c b/trace-plot-cpu.c index 1c86df8..09b1690 100644 --- a/trace-plot-cpu.c +++ b/trace-plot-cpu.c | |||
@@ -237,10 +237,12 @@ static int cpu_plot_event(struct graph_info *ginfo, | |||
237 | cpu_info->last_pid = orig_pid; | 237 | cpu_info->last_pid = orig_pid; |
238 | else | 238 | else |
239 | cpu_info->last_pid = pid; | 239 | cpu_info->last_pid = pid; |
240 | } | ||
241 | 240 | ||
242 | /* Box should always use the original pid (prev in sched_switch) */ | 241 | /* Box should always use the original pid (prev in sched_switch) */ |
243 | box_filter = trace_graph_filter_on_task(ginfo, orig_pid); | 242 | box_filter = trace_graph_filter_on_task(ginfo, orig_pid); |
243 | } else | ||
244 | box_filter = trace_graph_filter_on_task(ginfo, cpu_info->last_pid); | ||
245 | |||
244 | 246 | ||
245 | if (!box_filter && cpu_info->last_pid) { | 247 | if (!box_filter && cpu_info->last_pid) { |
246 | info->bcolor = hash_pid(cpu_info->last_pid); | 248 | info->bcolor = hash_pid(cpu_info->last_pid); |