Changeset View
Changeset View
Standalone View
Standalone View
usr.sbin/bhyve/bhyverun.c
Show First 20 Lines • Show All 95 Lines • ▼ Show 20 Lines | |||||
#include "mem.h" | #include "mem.h" | ||||
#include "mevent.h" | #include "mevent.h" | ||||
#include "mptbl.h" | #include "mptbl.h" | ||||
#include "pci_emul.h" | #include "pci_emul.h" | ||||
#include "pci_irq.h" | #include "pci_irq.h" | ||||
#include "pci_lpc.h" | #include "pci_lpc.h" | ||||
#include "smbiostbl.h" | #include "smbiostbl.h" | ||||
#ifdef BHYVE_SNAPSHOT | #ifdef BHYVE_SNAPSHOT | ||||
#include "ipc.h" | |||||
#include "snapshot.h" | #include "snapshot.h" | ||||
#endif | #endif | ||||
#include "xmsr.h" | #include "xmsr.h" | ||||
#include "spinup_ap.h" | #include "spinup_ap.h" | ||||
#include "rtc.h" | #include "rtc.h" | ||||
#include "vmgenc.h" | #include "vmgenc.h" | ||||
#define GUEST_NIO_PORT 0x488 /* guest upcalls via i/o port */ | #define GUEST_NIO_PORT 0x488 /* guest upcalls via i/o port */ | ||||
▲ Show 20 Lines • Show All 1,285 Lines • ▼ Show 20 Lines | #ifndef WITHOUT_CAPSICUM | ||||
if (caph_enter() == -1) | if (caph_enter() == -1) | ||||
errx(EX_OSERR, "cap_enter() failed"); | errx(EX_OSERR, "cap_enter() failed"); | ||||
#endif | #endif | ||||
#ifdef BHYVE_SNAPSHOT | #ifdef BHYVE_SNAPSHOT | ||||
if (restore_file != NULL) | if (restore_file != NULL) | ||||
destroy_restore_state(&rstate); | destroy_restore_state(&rstate); | ||||
/* | /* initialize mutex/cond variables */ | ||||
* checkpointing thread for communication with bhyvectl | init_snapshot(); | ||||
*/ | |||||
if (init_checkpoint_thread(ctx) < 0) | /* open up IPC to bhyve */ | ||||
printf("Failed to start checkpoint thread!\r\n"); | if (init_ipc(ctx) != 0) | ||||
fprintf(stderr, "Unable to open IPC to %s\n", vmname); | |||||
if (restore_file != NULL) | if (restore_file != NULL) | ||||
vm_restore_time(ctx); | vm_restore_time(ctx); | ||||
#endif | #endif | ||||
/* | /* | ||||
* Add CPU 0 | * Add CPU 0 | ||||
*/ | */ | ||||
Show All 25 Lines |