aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorKonstantin Belousov <kib@FreeBSD.org>2021-07-22 16:27:21 +0000
committerKonstantin Belousov <kib@FreeBSD.org>2021-07-24 15:52:45 +0000
commit48216088b1157a22b95540efea58f70057cd5c06 (patch)
tree6e8200d6b1152daef9e881f6408d73d0c405fd05 /sys
parent6a3821369f43bb1e8a672cbbfd7732406d9f9a4c (diff)
Diffstat (limited to 'sys')
-rw-r--r--sys/amd64/amd64/mp_machdep.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/sys/amd64/amd64/mp_machdep.c b/sys/amd64/amd64/mp_machdep.c
index 1513393a4387..886ea3734a3f 100644
--- a/sys/amd64/amd64/mp_machdep.c
+++ b/sys/amd64/amd64/mp_machdep.c
@@ -450,13 +450,16 @@ start_all_aps(void)
}
/* save the current value of the warm-start vector */
- mpbioswarmvec = *((u_int32_t *) WARMBOOT_OFF);
+ if (!efi_boot)
+ mpbioswarmvec = *((u_int32_t *) WARMBOOT_OFF);
outb(CMOS_REG, BIOS_RESET);
mpbiosreason = inb(CMOS_DATA);
/* setup a vector to our boot code */
- *((volatile u_short *) WARMBOOT_OFF) = WARMBOOT_TARGET;
- *((volatile u_short *) WARMBOOT_SEG) = (boot_address >> 4);
+ if (!efi_boot) {
+ *((volatile u_short *)WARMBOOT_OFF) = WARMBOOT_TARGET;
+ *((volatile u_short *)WARMBOOT_SEG) = (boot_address >> 4);
+ }
outb(CMOS_REG, BIOS_RESET);
outb(CMOS_DATA, BIOS_WARM); /* 'warm-start' */