aboutsummaryrefslogtreecommitdiff
path: root/i386/intel/read_fault.c
diff options
context:
space:
mode:
authorMasanori Ogino <masanori.ogino@gmail.com>2020-11-08 02:27:12 +0100
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2020-11-08 03:12:05 +0100
commit9dbc292eed8c9971f4b9e26b30d0e3d65ef9c629 (patch)
tree07ef1fcb2da234287cfb5c933928a4f4cc066f9b /i386/intel/read_fault.c
parentd0aee051a980557ded97d00e74446bddecf161cc (diff)
downloadgnumach-9dbc292eed8c9971f4b9e26b30d0e3d65ef9c629.tar.gz
gnumach-9dbc292eed8c9971f4b9e26b30d0e3d65ef9c629.tar.bz2
gnumach-9dbc292eed8c9971f4b9e26b30d0e3d65ef9c629.zip
i386 pmap: Omit pmap workaround on i486 or later.
As described in XXX comments, the workaround for memory mapping is implemented for 80386 and it is unnecessary on i486 or later. Thus, it is safe to omit that if the kernel is built for the recent (1989~) processors. Fuhito Inagawa pointed out the problem to me. * i386/i386/trap.c (kernel_trap): Disable the workaround when the kernel is built for i[456]86. * i386/intel/pmap.c (pmap_protect, pmap_enter): Ditto. * i386/intel/read_fault.c: Define intel_read_fault if and only if it is necessary.
Diffstat (limited to 'i386/intel/read_fault.c')
-rw-r--r--i386/intel/read_fault.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/i386/intel/read_fault.c b/i386/intel/read_fault.c
index 4b1edce3..0b79e3d8 100644
--- a/i386/intel/read_fault.c
+++ b/i386/intel/read_fault.c
@@ -33,6 +33,7 @@
#include <kern/macros.h>
+#if !(__i486__ || __i586__ || __i686__)
/*
* Expansion of vm_fault for read fault in kernel mode.
* Must enter the mapping as writable, since the i386
@@ -174,3 +175,4 @@ intel_read_fault(
return (KERN_SUCCESS);
}
+#endif