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 set L_SA_PAGEFAULT for prefetch aborts, t...



details:   https://anonhg.NetBSD.org/src/rev/d60f51e8a64f
branches:  trunk
changeset: 572432:d60f51e8a64f
user:      joff <joff%NetBSD.org@localhost>
date:      Sun Jan 02 21:12:48 2005 +0000

description:
set L_SA_PAGEFAULT for prefetch aborts, too.  Fixes kern/28828

diffstat:

 sys/arch/arm/arm32/fault.c |  11 +++++++++--
 1 files changed, 9 insertions(+), 2 deletions(-)

diffs (34 lines):

diff -r 2ec9bb10c805 -r d60f51e8a64f sys/arch/arm/arm32/fault.c
--- a/sys/arch/arm/arm32/fault.c        Sun Jan 02 20:43:23 2005 +0000
+++ b/sys/arch/arm/arm32/fault.c        Sun Jan 02 21:12:48 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: fault.c,v 1.52 2004/10/24 06:58:14 skrll Exp $ */
+/*     $NetBSD: fault.c,v 1.53 2005/01/02 21:12:48 joff Exp $  */
 
 /*
  * Copyright 2003 Wasabi Systems, Inc.
@@ -81,7 +81,7 @@
 #include "opt_kgdb.h"
 
 #include <sys/types.h>
-__KERNEL_RCSID(0, "$NetBSD: fault.c,v 1.52 2004/10/24 06:58:14 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: fault.c,v 1.53 2005/01/02 21:12:48 joff Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -843,8 +843,15 @@
                dab_fatal(tf, 0, tf->tf_pc, NULL, NULL);
        }
 #endif
+       if (map != kernel_map && l->l_flag & L_SA) {
+               l->l_savp->savp_faultaddr = fault_pc;
+               l->l_flag |= L_SA_PAGEFAULT;
+       }
 
        error = uvm_fault(map, va, 0, VM_PROT_READ);
+
+       if (map != kernel_map) l->l_flag &= ~L_SA_PAGEFAULT;
+
        if (__predict_true(error == 0)) {
                UVMHIST_LOG (maphist, " <- uvm", 0, 0, 0, 0);
                goto out;



Home | Main Index | Thread Index | Old Index