summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/arch/sparc/sparc/cpu.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/sys/arch/sparc/sparc/cpu.c b/sys/arch/sparc/sparc/cpu.c
index 8826a84ae33..b2c26dd0cf9 100644
--- a/sys/arch/sparc/sparc/cpu.c
+++ b/sys/arch/sparc/sparc/cpu.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cpu.c,v 1.7 1997/08/08 08:27:10 downsj Exp $ */
+/* $OpenBSD: cpu.c,v 1.8 1997/09/11 20:31:33 deraadt Exp $ */
/* $NetBSD: cpu.c,v 1.52 1997/07/29 09:41:58 fair Exp $ */
/*
@@ -333,6 +333,7 @@ void getcacheinfo_obp __P((struct cpu_softc *, int node));
void sun4_hotfix __P((struct cpu_softc *));
void viking_hotfix __P((struct cpu_softc *));
void turbosparc_hotfix __P((struct cpu_softc *));
+void swift_hotfix __P((struct cpu_softc *));
void ms1_mmu_enable __P((void));
void viking_mmu_enable __P((void));
@@ -731,7 +732,7 @@ struct module_info module_swift = { /* UNTESTED */
VAC_WRITETHROUGH,
0,
getcacheinfo_obp,
- 0,
+ swift_hotfix,
0,
swift_cache_enable,
256,
@@ -745,6 +746,17 @@ struct module_info module_swift = { /* UNTESTED */
};
void
+swift_hotfix(sc)
+ struct cpu_softc *sc;
+{
+ int pcr = lda(SRMMU_PCR, ASI_SRMMU);
+
+ /* Turn off branch prediction */
+ pcr &= ~SWIFT_PCR_BF;
+ sta(SRMMU_PCR, ASI_SRMMU, pcr);
+}
+
+void
swift_mmu_enable()
{
}