Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/aarch64/include Use pmap_growkernel(VM_KERNEL_VM_BA...



details:   https://anonhg.NetBSD.org/src/rev/16f9c18ede31
branches:  trunk
changeset: 938927:16f9c18ede31
user:      skrll <skrll%NetBSD.org@localhost>
date:      Sun Sep 20 15:30:11 2020 +0000

description:
Use pmap_growkernel(VM_KERNEL_VM_BASE) rather than pmap_virtual_space to
work out what to map initially.

XXX could do better mapping the kernel and modules more accurately

diffstat:

 sys/arch/aarch64/include/asan.h |  5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diffs (23 lines):

diff -r f4185718cab6 -r 16f9c18ede31 sys/arch/aarch64/include/asan.h
--- a/sys/arch/aarch64/include/asan.h   Sun Sep 20 14:42:29 2020 +0000
+++ b/sys/arch/aarch64/include/asan.h   Sun Sep 20 15:30:11 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: asan.h,v 1.12 2020/09/19 13:33:08 skrll Exp $  */
+/*     $NetBSD: asan.h,v 1.13 2020/09/20 15:30:11 skrll Exp $  */
 
 /*
  * Copyright (c) 2018-2020 Maxime Villard, m00nbsd.net
@@ -202,12 +202,11 @@
 static void
 kasan_md_init(void)
 {
-       vaddr_t eva, dummy;
 
        CTASSERT((__MD_SHADOW_SIZE / L0_SIZE) == 64);
 
        /* The VAs we've created until now. */
-       pmap_virtual_space(&eva, &dummy);
+       vaddr_t eva = pmap_growkernel(VM_KERNEL_VM_BASE);
        kasan_shadow_map((void *)VM_MIN_KERNEL_ADDRESS,
            eva - VM_MIN_KERNEL_ADDRESS);
 }



Home | Main Index | Thread Index | Old Index