Lines Matching full:machines
274 void machines__init(struct machines *machines) in machines__init() argument
276 machine__init(&machines->host, "", HOST_KERNEL_ID); in machines__init()
277 machines->guests = RB_ROOT_CACHED; in machines__init()
280 void machines__exit(struct machines *machines) in machines__exit() argument
282 machine__exit(&machines->host); in machines__exit()
286 struct machine *machines__add(struct machines *machines, pid_t pid, in machines__add() argument
289 struct rb_node **p = &machines->guests.rb_root.rb_node; in machines__add()
314 rb_insert_color_cached(&machine->rb_node, &machines->guests, leftmost); in machines__add()
316 machine->machines = machines; in machines__add()
321 void machines__set_comm_exec(struct machines *machines, bool comm_exec) in machines__set_comm_exec() argument
325 machines->host.comm_exec = comm_exec; in machines__set_comm_exec()
327 for (nd = rb_first_cached(&machines->guests); nd; nd = rb_next(nd)) { in machines__set_comm_exec()
334 struct machine *machines__find(struct machines *machines, pid_t pid) in machines__find() argument
336 struct rb_node **p = &machines->guests.rb_root.rb_node; in machines__find()
342 return &machines->host; in machines__find()
360 struct machine *machines__findnew(struct machines *machines, pid_t pid) in machines__findnew() argument
364 struct machine *machine = machines__find(machines, pid); in machines__findnew()
389 machine = machines__add(machines, pid, root_dir); in machines__findnew()
394 struct machine *machines__find_guest(struct machines *machines, pid_t pid) in machines__find_guest() argument
396 struct machine *machine = machines__find(machines, pid); in machines__find_guest()
399 machine = machines__findnew(machines, DEFAULT_GUEST_KERNEL_ID); in machines__find_guest()
469 struct thread *machines__findnew_guest_code(struct machines *machines, pid_t pid) in machines__findnew_guest_code() argument
471 struct machine *host_machine = machines__find(machines, HOST_KERNEL_ID); in machines__findnew_guest_code()
472 struct machine *machine = machines__findnew(machines, pid); in machines__findnew_guest_code()
479 struct machines *machines = machine->machines; in machine__findnew_guest_code() local
482 if (!machines) in machine__findnew_guest_code()
485 host_machine = machines__find(machines, HOST_KERNEL_ID); in machine__findnew_guest_code()
490 void machines__process_guests(struct machines *machines, in machines__process_guests() argument
495 for (nd = rb_first_cached(&machines->guests); nd; nd = rb_next(nd)) { in machines__process_guests()
501 void machines__set_id_hdr_size(struct machines *machines, u16 id_hdr_size) in machines__set_id_hdr_size() argument
506 machines->host.id_hdr_size = id_hdr_size; in machines__set_id_hdr_size()
508 for (node = rb_first_cached(&machines->guests); node; in machines__set_id_hdr_size()
1072 size_t machines__fprintf_dsos(struct machines *machines, FILE *fp) in machines__fprintf_dsos() argument
1075 size_t ret = __dsos__fprintf(&machines->host.dsos.head, fp); in machines__fprintf_dsos()
1077 for (nd = rb_first_cached(&machines->guests); nd; nd = rb_next(nd)) { in machines__fprintf_dsos()
1091 size_t machines__fprintf_dsos_buildid(struct machines *machines, FILE *fp, in machines__fprintf_dsos_buildid() argument
1095 size_t ret = machine__fprintf_dsos_buildid(&machines->host, fp, skip, parm); in machines__fprintf_dsos_buildid()
1097 for (nd = rb_first_cached(&machines->guests); nd; nd = rb_next(nd)) { in machines__fprintf_dsos_buildid()
1386 int machines__create_guest_kernel_maps(struct machines *machines) in machines__create_guest_kernel_maps() argument
1398 machines__create_kernel_maps(machines, DEFAULT_GUEST_KERNEL_ID); in machines__create_guest_kernel_maps()
1426 machines__create_kernel_maps(machines, pid); in machines__create_guest_kernel_maps()
1435 void machines__destroy_kernel_maps(struct machines *machines) in machines__destroy_kernel_maps() argument
1437 struct rb_node *next = rb_first_cached(&machines->guests); in machines__destroy_kernel_maps()
1439 machine__destroy_kernel_maps(&machines->host); in machines__destroy_kernel_maps()
1445 rb_erase_cached(&pos->rb_node, &machines->guests); in machines__destroy_kernel_maps()
1450 int machines__create_kernel_maps(struct machines *machines, pid_t pid) in machines__create_kernel_maps() argument
1452 struct machine *machine = machines__findnew(machines, pid); in machines__create_kernel_maps()
3239 int machines__for_each_thread(struct machines *machines, in machines__for_each_thread() argument
3246 rc = machine__for_each_thread(&machines->host, fn, priv); in machines__for_each_thread()
3250 for (nd = rb_first_cached(&machines->guests); nd; nd = rb_next(nd)) { in machines__for_each_thread()