aboutsummaryrefslogtreecommitdiff
path: root/sys/amd64/amd64/machdep.c
diff options
context:
space:
mode:
authorKonstantin Belousov <kib@FreeBSD.org>2021-07-29 00:22:35 +0000
committerKonstantin Belousov <kib@FreeBSD.org>2021-07-29 22:20:45 +0000
commitb27fe1c3ba2a1302c2866751e0c618b5a697bf30 (patch)
tree93eb44842e5f23adce58cb1b6ddbd3efc242f7b5 /sys/amd64/amd64/machdep.c
parent59b83c47e21520954178204d15ea3ba5df28a894 (diff)
downloadsrc-b27fe1c3ba2a1302c2866751e0c618b5a697bf30.tar.gz
src-b27fe1c3ba2a1302c2866751e0c618b5a697bf30.zip
amd64: stop doing special allocation for the AP startup trampoline
There is no reason now why do we need to allocate trampoline page very early in the boot process. The only requirement for the page is that it is below 1M to be usable by the real mode during init. This can be handled by vm_alloc_contig() when we do the startup. Also assert that startup trampoline fits into single page. In principle we can do multi-page allocation if needed, but it is not. Move the alloc_ap_trampoline() function and the boot_address variable to i386/mp_machdep.c. Keep existing mechanism of early alloc on i386. Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D31343
Diffstat (limited to 'sys/amd64/amd64/machdep.c')
-rw-r--r--sys/amd64/amd64/machdep.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c
index 49e245e1fdfe..0cb72314e68d 100644
--- a/sys/amd64/amd64/machdep.c
+++ b/sys/amd64/amd64/machdep.c
@@ -1272,16 +1272,6 @@ getmemsize(caddr_t kmdp, u_int64_t first)
(boothowto & RB_VERBOSE))
printf("Physical memory use set to %ldK\n", Maxmem * 4);
- /*
- * Make hole for "AP -> long mode" bootstrap code. The
- * mp_bootaddress vector is only available when the kernel
- * is configured to support APs and APs for the system start
- * in real mode mode (e.g. SMP bare metal).
- */
-#ifdef SMP
- alloc_ap_trampoline(physmap, &physmap_idx);
-#endif
-
/* call pmap initialization to make new kernel address space */
pmap_bootstrap(&first);