summaryrefslogtreecommitdiff
path: root/sys/arch/mips64/include
diff options
context:
space:
mode:
authorVisa Hankala <visa@cvs.openbsd.org>2016-09-06 13:41:30 +0000
committerVisa Hankala <visa@cvs.openbsd.org>2016-09-06 13:41:30 +0000
commit5c60a158c934576307e74c19b5f5b487082a4b01 (patch)
tree834f2625625ac56efac881ca13643a376089f7d0 /sys/arch/mips64/include
parent94de6658a6776c64247f0eee419acff7a2720756 (diff)
Define PTE_* macros in one place. Use the lwu instruction for 32-bit PTE
loads on all systems as the TLB code does not need sign extension.
Diffstat (limited to 'sys/arch/mips64/include')
-rw-r--r--sys/arch/mips64/include/pte.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/arch/mips64/include/pte.h b/sys/arch/mips64/include/pte.h
index 64a173c6889..eb385fa7d40 100644
--- a/sys/arch/mips64/include/pte.h
+++ b/sys/arch/mips64/include/pte.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: pte.h,v 1.19 2016/08/14 08:23:52 visa Exp $ */
+/* $OpenBSD: pte.h,v 1.20 2016/09/06 13:41:29 visa Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@@ -66,8 +66,14 @@ typedef u_int32_t pt_entry_t;
#ifdef MIPS_PTE64
#define PTE_BITS 64
+#define PTE_LOAD ld
+#define PTE_LOG 3
+#define PTE_OFFS 8
#else
#define PTE_BITS 32
+#define PTE_LOAD lwu
+#define PTE_LOG 2
+#define PTE_OFFS 4
#endif
#ifdef CPU_MIPS64R2