Lines Matching refs:xch

80 xc_core_strtab_init(xc_interface *xch)  in xc_core_strtab_init()  argument
113 xc_core_strtab_get(xc_interface *xch, struct xc_core_strtab *strtab, const char *name) in xc_core_strtab_get() argument
164 xc_core_shdr_init(xc_interface *xch) in xc_core_shdr_init() argument
190 xc_core_shdr_get(xc_interface *xch, in xc_core_shdr_get() argument
218 xc_core_shdr_set(xc_interface *xch, in xc_core_shdr_set() argument
225 uint64_t name_idx = xc_core_strtab_get(xch, strtab, name); in xc_core_shdr_set()
268 elfnote_fill_xen_version(xc_interface *xch, in elfnote_fill_xen_version() argument
275 rc = xc_version(xch, XENVER_version, NULL); in elfnote_fill_xen_version()
281 rc = xc_version(xch, XENVER_extraversion, in elfnote_fill_xen_version()
286 rc = xc_version(xch, XENVER_compile_info, in elfnote_fill_xen_version()
291 rc = xc_version(xch, in elfnote_fill_xen_version()
296 rc = xc_version(xch, XENVER_changeset, &xen_version->changeset); in elfnote_fill_xen_version()
300 rc = xc_version(xch, XENVER_platform_parameters, in elfnote_fill_xen_version()
305 rc = xc_version(xch, XENVER_pagesize, NULL); in elfnote_fill_xen_version()
330 elfnote_dump_none(xc_interface *xch, void *args, dumpcore_rtn_t dump_rtn) in elfnote_dump_none() argument
342 sts = dump_rtn(xch, args, (char*)&elfnote, sizeof(elfnote)); in elfnote_dump_none()
345 return dump_rtn(xch, args, (char*)&none, sizeof(none)); in elfnote_dump_none()
350 xc_interface *xch, in elfnote_dump_core_header() argument
367 sts = dump_rtn(xch, args, (char*)&elfnote, sizeof(elfnote)); in elfnote_dump_core_header()
370 return dump_rtn(xch, args, (char*)&header, sizeof(header)); in elfnote_dump_core_header()
374 elfnote_dump_xen_version(xc_interface *xch, void *args, in elfnote_dump_xen_version() argument
386 elfnote_fill_xen_version(xch, &xen_version); in elfnote_dump_xen_version()
393 sts = dump_rtn(xch, args, (char*)&elfnote, sizeof(elfnote)); in elfnote_dump_xen_version()
396 return dump_rtn(xch, args, (char*)&xen_version, sizeof(xen_version)); in elfnote_dump_xen_version()
400 elfnote_dump_format_version(xc_interface *xch, in elfnote_dump_format_version() argument
413 sts = dump_rtn(xch, args, (char*)&elfnote, sizeof(elfnote)); in elfnote_dump_format_version()
416 return dump_rtn(xch, args, (char*)&format_version, sizeof(format_version)); in elfnote_dump_format_version()
420 xc_domain_dumpcore_via_callback(xc_interface *xch, in xc_domain_dumpcore_via_callback() argument
469 if ( xc_domain_getinfo(xch, domid, 1, &info) != 1 ) in xc_domain_dumpcore_via_callback()
475 live_shinfo = xc_map_foreign_range(xch, domid, PAGE_SIZE, in xc_domain_dumpcore_via_callback()
487 if ( xc_domain_get_guest_width(xch, domid, &dinfo->guest_width) != 0 ) in xc_domain_dumpcore_via_callback()
533 if ( xc_vcpu_getcontext(xch, domid, i, &ctxt[nr_vcpus]) == 0 ) in xc_domain_dumpcore_via_callback()
536 xch, domid) ) in xc_domain_dumpcore_via_callback()
548 sts = xc_core_arch_memory_map_get(xch, &arch_ctxt, &info, in xc_domain_dumpcore_via_callback()
575 sts = xc_core_arch_map_p2m(xch, dinfo->guest_width, &info, live_shinfo, in xc_domain_dumpcore_via_callback()
594 strtab = xc_core_strtab_init(xch); in xc_domain_dumpcore_via_callback()
600 sheaders = xc_core_shdr_init(xch); in xc_domain_dumpcore_via_callback()
607 shdr = xc_core_shdr_get(xch,sheaders); in xc_domain_dumpcore_via_callback()
615 shdr = xc_core_shdr_get(xch,sheaders); in xc_domain_dumpcore_via_callback()
625 sts = xc_core_shdr_set(xch, shdr, strtab, ELF_SHSTRTAB, SHT_STRTAB, 0, 0, 0, 0); in xc_domain_dumpcore_via_callback()
637 shdr = xc_core_shdr_get(xch,sheaders); in xc_domain_dumpcore_via_callback()
643 sts = xc_core_shdr_set(xch, shdr, strtab, XEN_DUMPCORE_SEC_NOTE, SHT_NOTE, in xc_domain_dumpcore_via_callback()
650 shdr = xc_core_shdr_get(xch,sheaders); in xc_domain_dumpcore_via_callback()
657 sts = xc_core_shdr_set(xch, shdr, strtab, XEN_DUMPCORE_SEC_PRSTATUS, in xc_domain_dumpcore_via_callback()
665 sts = xc_core_arch_context_get_shdr(xch, &arch_ctxt, sheaders, strtab, in xc_domain_dumpcore_via_callback()
674 shdr = xc_core_shdr_get(xch,sheaders); in xc_domain_dumpcore_via_callback()
681 sts = xc_core_shdr_set(xch, shdr, strtab, XEN_DUMPCORE_SEC_SHARED_INFO, in xc_domain_dumpcore_via_callback()
703 shdr = xc_core_shdr_get(xch,sheaders); in xc_domain_dumpcore_via_callback()
710 sts = xc_core_shdr_set(xch, shdr, strtab, XEN_DUMPCORE_SEC_PAGES, SHT_PROGBITS, in xc_domain_dumpcore_via_callback()
717 shdr = xc_core_shdr_get(xch,sheaders); in xc_domain_dumpcore_via_callback()
726 sts = xc_core_shdr_set(xch, shdr, strtab, XEN_DUMPCORE_SEC_P2M, in xc_domain_dumpcore_via_callback()
734 sts = xc_core_shdr_set(xch, shdr, strtab, XEN_DUMPCORE_SEC_PFN, in xc_domain_dumpcore_via_callback()
752 sts = dump_rtn(xch, args, (char*)&ehdr, sizeof(ehdr)); in xc_domain_dumpcore_via_callback()
757 sts = dump_rtn(xch, args, (char*)sheaders->shdrs, in xc_domain_dumpcore_via_callback()
763 sts = elfnote_dump_none(xch, args, dump_rtn); in xc_domain_dumpcore_via_callback()
768 sts = elfnote_dump_core_header(xch, args, dump_rtn, &info, nr_vcpus, nr_pages); in xc_domain_dumpcore_via_callback()
773 sts = elfnote_dump_xen_version(xch, args, dump_rtn, dinfo->guest_width); in xc_domain_dumpcore_via_callback()
778 sts = elfnote_dump_format_version(xch, args, dump_rtn); in xc_domain_dumpcore_via_callback()
783 sts = dump_rtn(xch, args, (char *)ctxt, sizeof(*ctxt) * nr_vcpus); in xc_domain_dumpcore_via_callback()
790 sts = dump_rtn(xch, args, (char*)live_shinfo, PAGE_SIZE); in xc_domain_dumpcore_via_callback()
796 sts = xc_core_arch_context_dump(xch, &arch_ctxt, args, dump_rtn); in xc_domain_dumpcore_via_callback()
802 sts = dump_rtn(xch, args, dummy, dummy_len); in xc_domain_dumpcore_via_callback()
862 xch, domid, PAGE_SIZE, PROT_READ, gmfn); in xc_domain_dumpcore_via_callback()
871 xch, args, dump_mem_start, dump_mem - dump_mem_start); in xc_domain_dumpcore_via_callback()
882 sts = dump_rtn(xch, args, dump_mem_start, dump_mem - dump_mem_start); in xc_domain_dumpcore_via_callback()
893 sts = dump_rtn(xch, args, dump_mem_start, PAGE_SIZE); in xc_domain_dumpcore_via_callback()
909 xch, args, (char *)p2m_array, sizeof(p2m_array[0]) * nr_pages); in xc_domain_dumpcore_via_callback()
912 xch, args, (char *)pfn_array, sizeof(pfn_array[0]) * nr_pages); in xc_domain_dumpcore_via_callback()
917 sts = dump_rtn(xch, args, strtab->strings, strtab->length); in xc_domain_dumpcore_via_callback()
953 static int local_file_dump(xc_interface *xch, in local_file_dump() argument
968 discard_file_cache(xch, da->fd, 0 /* no flush */); in local_file_dump()
975 xc_domain_dumpcore(xc_interface *xch, in xc_domain_dumpcore() argument
989 xch, domid, &da, &local_file_dump); in xc_domain_dumpcore()
992 discard_file_cache(xch, da.fd, 1/* flush first*/); in xc_domain_dumpcore()