diff options
author | Michal Marek <mmarek@suse.cz> | 2010-10-12 09:09:06 -0400 |
---|---|---|
committer | Michal Marek <mmarek@suse.cz> | 2010-10-12 09:09:06 -0400 |
commit | 239060b93bb30a4ad55f1ecaa512464a035cc5ba (patch) | |
tree | 77f79810e57d4fc24356eca0cd6db463e8994128 /tools/perf/builtin-timechart.c | |
parent | 1408b15b98635a13bad2e2a50b3c2ae2ccdf625b (diff) | |
parent | e9203c988234aa512bd45ca32b52e21c7bbfc414 (diff) |
Merge branch 'kbuild/rc-fixes' into kbuild/kconfig
We need to revert the temporary hack in 71ebc01, hence the merge.
Diffstat (limited to 'tools/perf/builtin-timechart.c')
-rw-r--r-- | tools/perf/builtin-timechart.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/tools/perf/builtin-timechart.c b/tools/perf/builtin-timechart.c index 5a52ed9fc10b..9bcc38f0b706 100644 --- a/tools/perf/builtin-timechart.c +++ b/tools/perf/builtin-timechart.c | |||
@@ -300,8 +300,9 @@ struct trace_entry { | |||
300 | 300 | ||
301 | struct power_entry { | 301 | struct power_entry { |
302 | struct trace_entry te; | 302 | struct trace_entry te; |
303 | s64 type; | 303 | u64 type; |
304 | s64 value; | 304 | u64 value; |
305 | u64 cpu_id; | ||
305 | }; | 306 | }; |
306 | 307 | ||
307 | #define TASK_COMM_LEN 16 | 308 | #define TASK_COMM_LEN 16 |
@@ -454,8 +455,8 @@ static void sched_switch(int cpu, u64 timestamp, struct trace_entry *te) | |||
454 | if (p->current->state != TYPE_NONE) | 455 | if (p->current->state != TYPE_NONE) |
455 | pid_put_sample(sw->next_pid, p->current->state, cpu, p->current->state_since, timestamp); | 456 | pid_put_sample(sw->next_pid, p->current->state, cpu, p->current->state_since, timestamp); |
456 | 457 | ||
457 | p->current->state_since = timestamp; | 458 | p->current->state_since = timestamp; |
458 | p->current->state = TYPE_RUNNING; | 459 | p->current->state = TYPE_RUNNING; |
459 | } | 460 | } |
460 | 461 | ||
461 | if (prev_p->current) { | 462 | if (prev_p->current) { |
@@ -498,13 +499,13 @@ static int process_sample_event(event_t *event, struct perf_session *session) | |||
498 | return 0; | 499 | return 0; |
499 | 500 | ||
500 | if (strcmp(event_str, "power:power_start") == 0) | 501 | if (strcmp(event_str, "power:power_start") == 0) |
501 | c_state_start(data.cpu, data.time, pe->value); | 502 | c_state_start(pe->cpu_id, data.time, pe->value); |
502 | 503 | ||
503 | if (strcmp(event_str, "power:power_end") == 0) | 504 | if (strcmp(event_str, "power:power_end") == 0) |
504 | c_state_end(data.cpu, data.time); | 505 | c_state_end(pe->cpu_id, data.time); |
505 | 506 | ||
506 | if (strcmp(event_str, "power:power_frequency") == 0) | 507 | if (strcmp(event_str, "power:power_frequency") == 0) |
507 | p_state_change(data.cpu, data.time, pe->value); | 508 | p_state_change(pe->cpu_id, data.time, pe->value); |
508 | 509 | ||
509 | if (strcmp(event_str, "sched:sched_wakeup") == 0) | 510 | if (strcmp(event_str, "sched:sched_wakeup") == 0) |
510 | sched_wakeup(data.cpu, data.time, data.pid, te); | 511 | sched_wakeup(data.cpu, data.time, data.pid, te); |