Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/sparc/sparc mmu_pagein: refuse kernel space address...
details: https://anonhg.NetBSD.org/src/rev/b2f7464e535b
branches: trunk
changeset: 474117:b2f7464e535b
user: pk <pk%NetBSD.org@localhost>
date: Mon Jun 28 14:41:43 1999 +0000
description:
mmu_pagein: refuse kernel space addresses here.
diffstat:
sys/arch/sparc/sparc/pmap.c | 9 +++++++--
1 files changed, 7 insertions(+), 2 deletions(-)
diffs (36 lines):
diff -r dae36dbdac2c -r b2f7464e535b sys/arch/sparc/sparc/pmap.c
--- a/sys/arch/sparc/sparc/pmap.c Mon Jun 28 13:32:43 1999 +0000
+++ b/sys/arch/sparc/sparc/pmap.c Mon Jun 28 14:41:43 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.147 1999/06/17 19:23:27 thorpej Exp $ */
+/* $NetBSD: pmap.c,v 1.148 1999/06/28 14:41:43 pk Exp $ */
/*
* Copyright (c) 1996
@@ -1697,13 +1697,17 @@
int
mmu_pagein(pm, va, prot)
struct pmap *pm;
- int va, prot;
+ vaddr_t va;
+ int prot;
{
int *pte;
int vr, vs, pmeg, i, s, bits;
struct regmap *rp;
struct segmap *sp;
+ if (va >= (unsigned long)KERNBASE)
+ return (0);
+
if (prot != VM_PROT_NONE)
bits = PG_V | ((prot & VM_PROT_WRITE) ? PG_W : 0);
else
@@ -1711,6 +1715,7 @@
vr = VA_VREG(va);
vs = VA_VSEG(va);
+
rp = &pm->pm_regmap[vr];
#ifdef DEBUG
if (pm == pmap_kernel())
Home |
Main Index |
Thread Index |
Old Index