From 95273a610ff4ed4f4cf78d20a99f6a32acec8841 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Mon, 3 Jan 2000 14:06:42 +0000 Subject: Combination of coverhd.h cleanup and MVME23xx/MCP750 patch from Eric Valette and Jay Kulpinski . --- c/src/lib/libcpu/powerpc/mpc6xx/mmu/mmuAsm.S | 29 ++++++++++++++++++++++++---- 1 file changed, 25 insertions(+), 4 deletions(-) (limited to 'c/src/lib/libcpu/powerpc/mpc6xx/mmu/mmuAsm.S') diff --git a/c/src/lib/libcpu/powerpc/mpc6xx/mmu/mmuAsm.S b/c/src/lib/libcpu/powerpc/mpc6xx/mmu/mmuAsm.S index a0f298e5c3..b5a76704c2 100644 --- a/c/src/lib/libcpu/powerpc/mpc6xx/mmu/mmuAsm.S +++ b/c/src/lib/libcpu/powerpc/mpc6xx/mmu/mmuAsm.S @@ -19,27 +19,48 @@ #include #include "asm.h" +/* + * Each setdbat routine start by invalidating the DBAT as some + * proc (604e) request the valid bit set to 0 before accepting + * to write in BAT + */ + .globl asm_setdbat1 .type asm_setdbat1,@function -asm_setdbat1: - mtspr DBAT1U, r3 +asm_setdbat1: + li r20,0 + SYNC + mtspr DBAT1U,r20 + mtspr DBAT1L,r20 + SYNC mtspr DBAT1L, r4 + mtspr DBAT1U, r3 SYNC blr .globl asm_setdbat2 .type asm_setdbat2,@function asm_setdbat2: - mtspr DBAT2U, r3 + li r20,0 + SYNC + mtspr DBAT2U,r20 + mtspr DBAT2L,r20 + SYNC mtspr DBAT2L, r4 + mtspr DBAT2U, r3 SYNC blr .globl asm_setdbat3 .type asm_setdbat3,@function asm_setdbat3: - mtspr DBAT3U, r3 + li r20,0 + SYNC + mtspr DBAT3U,r20 + mtspr DBAT3L,r20 + SYNC mtspr DBAT3L, r4 + mtspr DBAT3U, r3 SYNC blr -- cgit v1.2.3