Lines Matching +full:global +full:- +full:regs

1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
55 #include <xen/xen-os.h>
63 #include <contrib/xen/arch-x86/cpuid.h>
67 /*--------------------------- Forward Declarations ---------------------------*/
70 /*-------------------------------- Global Data -------------------------------*/
81 * If non-zero, the hypervisor has been configured to use a direct
92 /*------------------------------- Per-CPU Data -------------------------------*/
95 /*------------------------------ Sysctl tunables -----------------------------*/
101 /*---------------------- XEN Hypervisor Probe and Setup ----------------------*/
113 msix_disable_migration == -1) { in hypervisor_quirks()
116 * handle updates to enabled MSI-X table entries, in hypervisor_quirks()
117 * so disable MSI-X interrupt migration in that in hypervisor_quirks()
122 "Disabling MSI-X interrupt migration due to Xen hypervisor bug.\n" in hypervisor_quirks()
132 uint32_t regs[4]; in hypervisor_version() local
135 do_cpuid(hv_base + 1, regs); in hypervisor_version()
137 major = regs[0] >> 16; in hypervisor_version()
138 minor = regs[0] & 0xffff; in hypervisor_version()
146 * created page-tables.
161 return ((uintptr_t)addr - KERNBASE in early_init_vtop()
163 + kernphys - KERNLOAD in early_init_vtop()
173 * non-RAM) address. But finding one at this point in boot is in map_shared_info()
174 * complicated, hence re-use a RAM address for the time being. This in map_shared_info()
175 * sadly causes super-page shattering in the second stage translation in map_shared_info()
232 switch (console->video_type) { in fixup_console()
244 sizeof(fb->efi.fb_mask_reserved), in fixup_console()
246 fb->vbe.fb_bpp = console->u.vesa_lfb.bits_per_pixel; in fixup_console()
258 fb->efi.fb_addr = console->u.vesa_lfb.lfb_base; in fixup_console()
261 fb->efi.fb_addr |= in fixup_console()
262 (uint64_t)console->u.vesa_lfb.ext_lfb_base << 32; in fixup_console()
263 fb->efi.fb_size = console->u.vesa_lfb.lfb_size << 16; in fixup_console()
264 fb->efi.fb_height = console->u.vesa_lfb.height; in fixup_console()
265 fb->efi.fb_width = console->u.vesa_lfb.width; in fixup_console()
266 fb->efi.fb_stride = (console->u.vesa_lfb.bytes_per_line << 3) / in fixup_console()
267 console->u.vesa_lfb.bits_per_pixel; in fixup_console()
269 ((~0u << console->u.vesa_lfb.c ## _pos) & \ in fixup_console()
270 (~0u >> (32 - console->u.vesa_lfb.c ## _pos - \ in fixup_console()
271 console->u.vesa_lfb.c ## _size))) in fixup_console()
272 fb->efi.fb_mask_red = FBMASK(red); in fixup_console()
273 fb->efi.fb_mask_green = FBMASK(green); in fixup_console()
274 fb->efi.fb_mask_blue = FBMASK(blue); in fixup_console()
275 fb->efi.fb_mask_reserved = FBMASK(rsvd); in fixup_console()
289 uint32_t regs[4]; in xen_early_init() local
299 do_cpuid(hv_base + 2, regs); in xen_early_init()
300 if (regs[0] != 1) { in xen_early_init()
302 regs[0]); in xen_early_init()
307 wrmsr(regs[1], early_init_vtop(&hypercall_page)); in xen_early_init()
384 pin = pci_get_intpin(dev) - 1; in xen_hvm_set_callback()
497 uint32_t regs[4]; in xen_hvm_cpu_init() local
506 * from a failed migration and our pre-suspend in xen_hvm_cpu_init()
517 cpuid_count(hv_base + 4, 0, regs); in xen_hvm_cpu_init()
518 KASSERT((regs[0] & XEN_HVM_CPUID_VCPU_ID_PRESENT) || in xen_hvm_cpu_init()
521 PCPU_SET(vcpu_id, (regs[0] & XEN_HVM_CPUID_VCPU_ID_PRESENT) ? in xen_hvm_cpu_init()
522 regs[1] : PCPU_GET(acpi_id)); in xen_hvm_cpu_init()
526 * Setup the per-vpcu event channel upcall vector. This is only in xen_hvm_cpu_init()
545 uint32_t regs[4]; in xen_has_iommu_maps() local
548 cpuid_count(hv_base + 4, 0, regs); in xen_has_iommu_maps()
550 return (regs[0] & XEN_HVM_CPUID_IOMMU_MAPPINGS); in xen_has_iommu_maps()
581 end = MIN(trunc_page(smap[i].base + smap[i].length) - 1, in xen_arch_init_physmem()