diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2024-10-21 18:27:35 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2024-10-21 18:27:35 +0000 |
commit | aae803f7d9290f0c52ca254b2165359cc4ea951c (patch) | |
tree | dfe4caf43dc932ae02473629f8920ecae1b7a36b /sys/arch/amd64 | |
parent | 2d27eb7a3635dbb66535856633ebd13bec608552 (diff) |
We have not been swapping out kernel stacks since forever. So just
allocate the uarea with zeroed pages using km_alloc(9). Adjust the amd64
code that creates a guard page at the top of the kernel stack to use
pmap_kremove(9) instead of pmap_remove(9) to reflect that the uarea no
longer uses "managed" pages.
ok mpi@
Diffstat (limited to 'sys/arch/amd64')
-rw-r--r-- | sys/arch/amd64/amd64/vm_machdep.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/arch/amd64/amd64/vm_machdep.c b/sys/arch/amd64/amd64/vm_machdep.c index 8be22524d5d..5275969ed39 100644 --- a/sys/arch/amd64/amd64/vm_machdep.c +++ b/sys/arch/amd64/amd64/vm_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vm_machdep.c,v 1.47 2023/04/11 00:45:07 jsg Exp $ */ +/* $OpenBSD: vm_machdep.c,v 1.48 2024/10/21 18:27:34 kettenis Exp $ */ /* $NetBSD: vm_machdep.c,v 1.1 2003/04/26 18:39:33 fvdl Exp $ */ /*- @@ -135,8 +135,7 @@ cpu_exit(struct proc *p) void setguardpage(struct proc *p) { - pmap_remove(pmap_kernel(), (vaddr_t)p->p_addr + PAGE_SIZE, - (vaddr_t)p->p_addr + 2 * PAGE_SIZE); + pmap_kremove((vaddr_t)p->p_addr + PAGE_SIZE, PAGE_SIZE); pmap_update(pmap_kernel()); } |