diff --git a/usr.sbin/bhyve/Makefile b/usr.sbin/bhyve/Makefile --- a/usr.sbin/bhyve/Makefile +++ b/usr.sbin/bhyve/Makefile @@ -62,7 +62,6 @@ qemu_fwcfg.c \ qemu_loader.c \ rfb.c \ - rtc.c \ smbiostbl.c \ sockstream.c \ spinup_ap.c \ diff --git a/usr.sbin/bhyve/amd64/Makefile.inc b/usr.sbin/bhyve/amd64/Makefile.inc --- a/usr.sbin/bhyve/amd64/Makefile.inc +++ b/usr.sbin/bhyve/amd64/Makefile.inc @@ -9,6 +9,7 @@ post.c \ ps2kbd.c \ ps2mouse.c \ + rtc.c \ task_switch.c \ xmsr.c diff --git a/usr.sbin/bhyve/rtc.h b/usr.sbin/bhyve/amd64/rtc.h rename from usr.sbin/bhyve/rtc.h rename to usr.sbin/bhyve/amd64/rtc.h diff --git a/usr.sbin/bhyve/rtc.c b/usr.sbin/bhyve/amd64/rtc.c rename from usr.sbin/bhyve/rtc.c rename to usr.sbin/bhyve/amd64/rtc.c diff --git a/usr.sbin/bhyve/bhyverun.c b/usr.sbin/bhyve/bhyverun.c --- a/usr.sbin/bhyve/bhyverun.c +++ b/usr.sbin/bhyve/bhyverun.c @@ -106,7 +106,9 @@ #ifdef BHYVE_SNAPSHOT #include "snapshot.h" #endif -#include "rtc.h" +#ifdef __amd64__ +#include "amd64/rtc.h" +#endif #include "vmgenc.h" #include "vmexit.h" #ifdef __amd64__ @@ -902,9 +904,11 @@ case 'e': set_config_bool("x86.strictio", true); break; +#ifdef __amd64__ case 'u': set_config_bool("rtc.use_localtime", false); break; +#endif case 'U': set_config_value("uuid", optarg); break; @@ -1036,7 +1040,9 @@ pci_irq_init(ctx); ioapic_init(ctx); +#ifdef __amd64__ rtc_init(ctx); +#endif sci_init(ctx); if (qemu_fwcfg_init(ctx) != 0) {