| 355 | } |
| 356 | |
| 357 | static int |
| 358 | vmm_init(void) |
| 359 | { |
| 360 | int error; |
| 361 | |
| 362 | if (!vmm_is_hw_supported()) |
| 363 | return (ENXIO); |
| 364 | |
| 365 | vmm_host_state_init(); |
| 366 | |
| 367 | vmm_ipinum = lapic_ipi_alloc(pti ? &IDTVEC(justreturn1_pti) : |
| 368 | &IDTVEC(justreturn)); |
| 369 | if (vmm_ipinum < 0) |
| 370 | vmm_ipinum = IPI_AST; |
| 371 | |
| 372 | error = vmm_mem_init(); |
| 373 | if (error) |
| 374 | return (error); |
| 375 | |
| 376 | vmm_resume_p = vmmops_modresume; |
| 377 | |
| 378 | return (vmmops_modinit(vmm_ipinum)); |
| 379 | } |
| 380 | |
| 381 | static int |
| 382 | vmm_handler(module_t mod, int what, void *arg) |
no test coverage detected