Lines Matching refs:pid

23 int machine__init(struct machine *machine, const char *root_dir, pid_t pid)  in machine__init()  argument
36 machine->pid = pid; in machine__init()
47 if (pid != HOST_KERNEL_ID) { in machine__init()
49 pid); in machine__init()
55 snprintf(comm, sizeof(comm), "[guest/%d]", pid); in machine__init()
133 struct machine *machines__add(struct machines *machines, pid_t pid, in machines__add() argument
143 if (machine__init(machine, root_dir, pid) != 0) { in machines__add()
153 if (pid < pos->pid) in machines__add()
193 struct machine *machines__find(struct machines *machines, pid_t pid) in machines__find() argument
200 if (pid == HOST_KERNEL_ID) in machines__find()
206 if (pid < machine->pid) in machines__find()
208 else if (pid > machine->pid) in machines__find()
212 if (!machine->pid) in machines__find()
219 struct machine *machines__findnew(struct machines *machines, pid_t pid) in machines__findnew() argument
223 struct machine *machine = machines__find(machines, pid); in machines__findnew()
225 if (machine && (machine->pid == pid)) in machines__findnew()
228 if ((pid != HOST_KERNEL_ID) && in machines__findnew()
229 (pid != DEFAULT_GUEST_KERNEL_ID) && in machines__findnew()
231 sprintf(path, "%s/%d", symbol_conf.guestmount, pid); in machines__findnew()
248 machine = machines__add(machines, pid, root_dir); in machines__findnew()
272 machine->pid); in machine__mmap_name()
294 struct thread *th, pid_t pid) in machine__update_thread_pid() argument
298 if (pid == th->pid_ || pid == -1 || th->pid_ != -1) in machine__update_thread_pid()
301 th->pid_ = pid; in machine__update_thread_pid()
340 pid_t pid, pid_t tid, in __machine__findnew_thread() argument
355 machine__update_thread_pid(machine, th, pid); in __machine__findnew_thread()
368 machine__update_thread_pid(machine, th, pid); in __machine__findnew_thread()
381 th = thread__new(pid, tid); in __machine__findnew_thread()
409 struct thread *machine__findnew_thread(struct machine *machine, pid_t pid, in machine__findnew_thread() argument
412 return __machine__findnew_thread(machine, pid, tid, true); in machine__findnew_thread()
415 struct thread *machine__find_thread(struct machine *machine, pid_t pid, in machine__find_thread() argument
418 return __machine__findnew_thread(machine, pid, tid, false); in machine__find_thread()
434 event->comm.pid, in machine__process_comm_event()
727 pid_t pid; in machines__create_guest_kernel_maps() local
745 pid = (pid_t)strtol(namelist[i]->d_name, &endp, 10); in machines__create_guest_kernel_maps()
761 machines__create_kernel_maps(machines, pid); in machines__create_guest_kernel_maps()
785 int machines__create_kernel_maps(struct machines *machines, pid_t pid) in machines__create_kernel_maps() argument
787 struct machine *machine = machines__findnew(machines, pid); in machines__create_kernel_maps()
1026 "continuing anyway...\n", machine->pid); in machine__create_kernel_maps()
1180 thread = machine__findnew_thread(machine, event->mmap2.pid, in machine__process_mmap2_event()
1192 event->mmap2.pid, event->mmap2.maj, in machine__process_mmap2_event()
1230 thread = machine__findnew_thread(machine, event->mmap.pid, in machine__process_mmap_event()
1242 event->mmap.pid, 0, 0, 0, 0, 0, 0, in machine__process_mmap_event()
1276 event->fork.pid, in machine__process_fork_event()
1286 thread = machine__findnew_thread(machine, event->fork.pid, in machine__process_fork_event()
1304 event->fork.pid, in machine__process_exit_event()
1792 int machine__set_current_tid(struct machine *machine, int cpu, pid_t pid, in machine__set_current_tid() argument
1818 thread = machine__findnew_thread(machine, pid, tid); in machine__set_current_tid()