Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/cddl/osnet/dev/dtrace/aarch64 Change the address ra...
details: https://anonhg.NetBSD.org/src/rev/bee022498d2e
branches: trunk
changeset: 744749:bee022498d2e
user: riastradh <riastradh%NetBSD.org@localhost>
date: Wed Feb 12 06:05:23 2020 +0000
description:
Change the address ranges that aarch64 considers toxic for dtrace.
`Toxic' means dtrace forbids D scripts from even attempting to read
or write at them.
Previously we considered [0, VM_MIN_KERNEL_ADDRESS) toxic, but
VM_MIN_KERNEL_ADDRESS is only the minimum address of the kernel map;
the direct-mapped region lies below it, and with PMAP_MAP_POOLPAGE we
allocate virtual pages for pool backing directly from physical pages
through the direct-mapped region. Also, this did not consider I/O
mappings to be toxic, which they probably should be.
Instead, treat:
[0, AARCH64_KSEG_START)
and
[VM_KERNEL_IO_ADDRESS, 0xfff...ff)
as toxic. (The upper bound for 0xfff...ff ought to be inclusive, not
exclusive, but I think we'll need another mechanism for expressing
that to dtrace!)
diffstat:
external/cddl/osnet/dev/dtrace/aarch64/dtrace_subr.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diffs (22 lines):
diff -r 11acf9fe8838 -r bee022498d2e external/cddl/osnet/dev/dtrace/aarch64/dtrace_subr.c
--- a/external/cddl/osnet/dev/dtrace/aarch64/dtrace_subr.c Wed Feb 12 05:44:26 2020 +0000
+++ b/external/cddl/osnet/dev/dtrace/aarch64/dtrace_subr.c Wed Feb 12 06:05:23 2020 +0000
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: dtrace_subr.c,v 1.2 2020/02/12 01:09:38 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dtrace_subr.c,v 1.3 2020/02/12 06:05:23 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -128,7 +128,8 @@
dtrace_toxic_ranges(void (*func)(uintptr_t base, uintptr_t limit))
{
- (*func)(0, (uintptr_t)VM_MIN_KERNEL_ADDRESS);
+ (*func)(0, (uintptr_t)AARCH64_KSEG_START);
+ (*func)((uintptr_t)VM_KERNEL_IO_ADDRESS, ~(uintptr_t)0);
}
static void
Home |
Main Index |
Thread Index |
Old Index