2 * QEMU Hypervisor.framework (HVF) support
4 * Copyright 2017 Google Inc
6 * Adapted from target-i386/hax-i386.h:
7 * Copyright (c) 2011 Intel Corporation
9 * Jiang Yunhong<yunhong.jiang@intel.com>
11 * This work is licensed under the terms of the GNU GPL, version 2 or later.
12 * See the COPYING file in the top-level directory.
19 #include "qemu/accel.h"
20 #include "sysemu/hvf.h"
25 #define HVF_SLOT_LOG (1 << 0)
27 typedef struct hvf_slot
{
36 typedef struct hvf_vcpu_caps
{
37 uint64_t vmx_cap_pinbased
;
38 uint64_t vmx_cap_procbased
;
39 uint64_t vmx_cap_procbased2
;
40 uint64_t vmx_cap_entry
;
41 uint64_t vmx_cap_exit
;
42 uint64_t vmx_cap_preemption_timer
;
50 hvf_vcpu_caps
*hvf_caps
;
52 extern HVFState
*hvf_state
;
54 void hvf_set_phys_mem(MemoryRegionSection
*, bool);
55 void hvf_handle_io(CPUArchState
*, uint16_t, void *, int, int, int);
56 hvf_slot
*hvf_find_overlap_slot(uint64_t, uint64_t);
59 /* Functions exported to host specific mode */
61 /* Host specific functions */
62 int hvf_inject_interrupt(CPUArchState
*env
, int vector
);