git: 3f5b4dd6cd35 - stable/14 - arm64, riscv: Use KSTACK_PAGES for the thread0 kstack size designator
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 20 Oct 2023 15:56:11 UTC
The branch stable/14 has been updated by kib:
URL: https://cgit.FreeBSD.org/src/commit/?id=3f5b4dd6cd35e00544c332422918c296ca853162
commit 3f5b4dd6cd35e00544c332422918c296ca853162
Author: Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2023-10-09 23:56:37 +0000
Commit: Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2023-10-20 15:55:45 +0000
arm64, riscv: Use KSTACK_PAGES for the thread0 kstack size designator
(cherry picked from commit ac63f7534d0102352bf993ebe2c748ce2ffd432e)
---
sys/arm64/arm64/machdep.c | 3 ++-
sys/riscv/riscv/machdep.c | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/sys/arm64/arm64/machdep.c b/sys/arm64/arm64/machdep.c
index 4bfbfcaa91bd..8aa45a86fef4 100644
--- a/sys/arm64/arm64/machdep.c
+++ b/sys/arm64/arm64/machdep.c
@@ -26,6 +26,7 @@
*/
#include "opt_acpi.h"
+#include "opt_kstack_pages.h"
#include "opt_platform.h"
#include "opt_ddb.h"
@@ -380,7 +381,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
diff --git a/sys/riscv/riscv/machdep.c b/sys/riscv/riscv/machdep.c
index 6bc0b996948a..261dc8d6d840 100644
--- a/sys/riscv/riscv/machdep.c
+++ b/sys/riscv/riscv/machdep.c
@@ -33,6 +33,7 @@
* SUCH DAMAGE.
*/
+#include "opt_kstack_pages.h"
#include "opt_platform.h"
#include <sys/cdefs.h>
@@ -286,7 +287,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;
thread0.td_pcb = (struct pcb *)(thread0.td_kstack +
thread0.td_kstack_pages * PAGE_SIZE) - 1;
thread0.td_pcb->pcb_fpflags = 0;