mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-21 15:45:02 +00:00
arm64: Fix thread0.td_kstack_pages init
Commit 86a994d653
initialized
thread0.td_kstack_pages to KSTACK_PAGES. Due to the lack of an
include of opt_kstack_pages.h it used the fallback value of 4 from
machine/param.h. This meant that increasing KSTACK_PAGES in the kernel
config resulted in a panic in _epoch_enter_preempt as the following
assertion was false during network stack setup:
MPASS((vm_offset_t)et >= td->td_kstack &&
(vm_offset_t)et + sizeof(struct epoch_tracker) <=
td->td_kstack + td->td_kstack_pages * PAGE_SIZE);
Switch to initializing with kstack_pages following other architectures.
Reviewed by: imp, markj
Sponsored by: DARPA, AFRL
Differential Revision: https://reviews.freebsd.org/D38048
This commit is contained in:
parent
c968598479
commit
e1b610f76c
@ -365,7 +365,7 @@ init_proc0(vm_offset_t kstack)
|
||||
|
||||
proc_linkup0(&proc0, &thread0);
|
||||
thread0.td_kstack = kstack;
|
||||
thread0.td_kstack_pages = KSTACK_PAGES;
|
||||
thread0.td_kstack_pages = kstack_pages;
|
||||
#if defined(PERTHREAD_SSP)
|
||||
thread0.td_md.md_canary = boot_canary;
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user