Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 311932
b: refs/heads/master
c: 44b9946
h: refs/heads/master
v: v3
  • Loading branch information
Vaibhav Nagarnaik authored and Steven Rostedt committed Jun 29, 2012
1 parent 1a35c8d commit 11e5e1f
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 18 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7ed97ad41ffa94040dfd593948962a7e9e7b0db9
refs/heads/master: 44b99462d9d776522e174d6c531ce5ccef309e26
1 change: 1 addition & 0 deletions trunk/kernel/trace/ring_buffer.c
Original file line number Diff line number Diff line change
Expand Up @@ -1075,6 +1075,7 @@ rb_allocate_cpu_buffer(struct ring_buffer *buffer, int nr_pages, int cpu)
rb_init_page(bpage->page);

INIT_LIST_HEAD(&cpu_buffer->reader_page->list);
INIT_LIST_HEAD(&cpu_buffer->new_pages);

ret = rb_allocate_pages(cpu_buffer, nr_pages);
if (ret < 0)
Expand Down
29 changes: 14 additions & 15 deletions trunk/tools/perf/util/map.c
Original file line number Diff line number Diff line change
Expand Up @@ -669,26 +669,25 @@ struct machine *machines__find(struct rb_root *self, pid_t pid)
struct machine *machines__findnew(struct rb_root *self, pid_t pid)
{
char path[PATH_MAX];
const char *root_dir = "";
const char *root_dir;
struct machine *machine = machines__find(self, pid);

if (machine && (machine->pid == pid))
goto out;

if ((pid != HOST_KERNEL_ID) &&
(pid != DEFAULT_GUEST_KERNEL_ID) &&
(symbol_conf.guestmount)) {
sprintf(path, "%s/%d", symbol_conf.guestmount, pid);
if (access(path, R_OK)) {
pr_err("Can't access file %s\n", path);
machine = NULL;
goto out;
if (!machine || machine->pid != pid) {
if (pid == HOST_KERNEL_ID || pid == DEFAULT_GUEST_KERNEL_ID)
root_dir = "";
else {
if (!symbol_conf.guestmount)
goto out;
sprintf(path, "%s/%d", symbol_conf.guestmount, pid);
if (access(path, R_OK)) {
pr_err("Can't access file %s\n", path);
goto out;
}
root_dir = path;
}
root_dir = path;
machine = machines__add(self, pid, root_dir);
}

machine = machines__add(self, pid, root_dir);

out:
return machine;
}
Expand Down
2 changes: 1 addition & 1 deletion trunk/tools/perf/util/session.c
Original file line number Diff line number Diff line change
Expand Up @@ -926,7 +926,7 @@ static struct machine *
else
pid = event->ip.pid;

return perf_session__findnew_machine(session, pid);
return perf_session__find_machine(session, pid);
}

return perf_session__find_host_machine(session);
Expand Down
3 changes: 2 additions & 1 deletion trunk/tools/perf/util/trace-event-parse.c
Original file line number Diff line number Diff line change
Expand Up @@ -198,8 +198,9 @@ void print_trace_event(int cpu, void *data, int size)
record.data = data;

trace_seq_init(&s);
pevent_event_info(&s, event, &record);
pevent_print_event(pevent, &s, &record);
trace_seq_do_printf(&s);
printf("\n");
}

void print_event(int cpu, void *data, int size, unsigned long long nsecs,
Expand Down

0 comments on commit 11e5e1f

Please sign in to comment.