Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/arm/arm32 Always call pmap_grow_map with a page ali...
details: https://anonhg.NetBSD.org/src/rev/876dc336a8fb
branches: trunk
changeset: 1006999:876dc336a8fb
user: skrll <skrll%NetBSD.org@localhost>
date: Sun Feb 02 08:19:15 2020 +0000
description:
Always call pmap_grow_map with a page aligned new VA. KASSERT that this
happenes.
diffstat:
sys/arch/arm/arm32/pmap.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
diffs (36 lines):
diff -r bc9bfddb31c8 -r 876dc336a8fb sys/arch/arm/arm32/pmap.c
--- a/sys/arch/arm/arm32/pmap.c Sun Feb 02 08:16:40 2020 +0000
+++ b/sys/arch/arm/arm32/pmap.c Sun Feb 02 08:19:15 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.385 2020/02/02 08:16:40 skrll Exp $ */
+/* $NetBSD: pmap.c,v 1.386 2020/02/02 08:19:15 skrll Exp $ */
/*
* Copyright 2003 Wasabi Systems, Inc.
@@ -198,7 +198,7 @@
#endif
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.385 2020/02/02 08:16:40 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.386 2020/02/02 08:19:15 skrll Exp $");
#include <sys/param.h>
#include <sys/types.h>
@@ -5800,6 +5800,8 @@
{
paddr_t pa;
+ KASSERT((va & PGOFSET) == 0);
+
if (uvm.page_init_done == false) {
#ifdef PMAP_STEAL_MEMORY
pv_addr_t pv;
@@ -5886,7 +5888,7 @@
* The new l2_dtable straddles a page boundary.
* Map in another page to cover it.
*/
- if (pmap_grow_map(nva, NULL))
+ if (pmap_grow_map(nva & ~PGOFSET, NULL))
return (NULL);
}
Home |
Main Index |
Thread Index |
Old Index