Changeset View
Changeset View
Standalone View
Standalone View
sys/amd64/vmm/intel/vmx.c
Show First 20 Lines • Show All 1,014 Lines • ▼ Show 20 Lines | vmx_setup_cr_shadow(int which, struct vmcs *vmcs, uint32_t initial) | ||||
return (0); | return (0); | ||||
} | } | ||||
#define vmx_setup_cr0_shadow(vmcs,init) vmx_setup_cr_shadow(0, (vmcs), (init)) | #define vmx_setup_cr0_shadow(vmcs,init) vmx_setup_cr_shadow(0, (vmcs), (init)) | ||||
#define vmx_setup_cr4_shadow(vmcs,init) vmx_setup_cr_shadow(4, (vmcs), (init)) | #define vmx_setup_cr4_shadow(vmcs,init) vmx_setup_cr_shadow(4, (vmcs), (init)) | ||||
static void * | static void * | ||||
vmx_init(struct vm *vm, pmap_t pmap) | vmx_init(struct vm *vm, pmap_t pmap) | ||||
{ | { | ||||
int error; | int error __diagused; | ||||
bz: Isn't
```
int error __diagused;
```
all that is needed? | |||||
struct vmx *vmx; | struct vmx *vmx; | ||||
vmx = malloc(sizeof(struct vmx), M_VMX, M_WAITOK | M_ZERO); | vmx = malloc(sizeof(struct vmx), M_VMX, M_WAITOK | M_ZERO); | ||||
vmx->vm = vm; | vmx->vm = vm; | ||||
vmx->eptp = eptp(vtophys((vm_offset_t)pmap->pm_pmltop)); | vmx->eptp = eptp(vtophys((vm_offset_t)pmap->pm_pmltop)); | ||||
/* | /* | ||||
▲ Show 20 Lines • Show All 3,226 Lines • Show Last 20 Lines |
Isn't
all that is needed?