summaryrefslogtreecommitdiff
path: root/sys/arch/mips64
diff options
context:
space:
mode:
authorVisa Hankala <visa@cvs.openbsd.org>2016-11-21 13:50:23 +0000
committerVisa Hankala <visa@cvs.openbsd.org>2016-11-21 13:50:23 +0000
commit89400d94f74c350c085d683b98e3a5acaf241486 (patch)
tree63b5703a65b4455d87bd60906633716de82a9664 /sys/arch/mips64
parent606ce24daec9c3355e7816394dd1efaf43c2a215 (diff)
Enabling Loongson 3A bits turned on a code path that uses a MIPS64r2
register on Loongson 2. This causes a boot failure on LS2 because the CPU does not implement the register. Disable the code on LS2 similarly to mips64 pte.h. Yeelong boot hang reported and fix tested by matthieu@
Diffstat (limited to 'sys/arch/mips64')
-rw-r--r--sys/arch/mips64/mips64/pmap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/arch/mips64/mips64/pmap.c b/sys/arch/mips64/mips64/pmap.c
index f0b5531c4e9..ef4f1f53b40 100644
--- a/sys/arch/mips64/mips64/pmap.c
+++ b/sys/arch/mips64/mips64/pmap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap.c,v 1.94 2016/10/19 08:28:20 guenther Exp $ */
+/* $OpenBSD: pmap.c,v 1.95 2016/11/21 13:50:22 visa Exp $ */
/*
* Copyright (c) 2001-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
@@ -386,7 +386,7 @@ pmap_bootstrap(void)
pmap_asid_info[i].pma_asid = MIN_USER_ASID + 1;
}
-#ifdef CPU_MIPS64R2
+#if defined(CPU_MIPS64R2) && !defined(CPU_LOONGSON2)
if (cp0_get_pagegrain() & PGRAIN_XIE)
pg_xi = PG_XI;
#endif