From a7f264fd2fc396e153f240461e6e22fbf51e2626 Mon Sep 17 00:00:00 2001 From: thorpej Date: Sat, 18 Dec 1999 01:37:00 +0000 Subject: [PATCH] Update for BATU()/BATL() changes. --- sys/arch/bebox/bebox/machdep.c | 22 ++++++++++++---------- sys/arch/macppc/macppc/machdep.c | 24 +++++++++++++----------- sys/arch/macppc/macppc/rbus_machdep.c | 6 +++--- sys/arch/ofppc/ofppc/machdep.c | 6 +++--- 4 files changed, 31 insertions(+), 27 deletions(-) diff --git a/sys/arch/bebox/bebox/machdep.c b/sys/arch/bebox/bebox/machdep.c index 990fe42df06a..70d5d47791b0 100644 --- a/sys/arch/bebox/bebox/machdep.c +++ b/sys/arch/bebox/bebox/machdep.c @@ -1,4 +1,4 @@ -/* $NetBSD: machdep.c,v 1.45 1999/12/04 21:20:17 ragge Exp $ */ +/* $NetBSD: machdep.c,v 1.46 1999/12/18 01:37:00 thorpej Exp $ */ /* * Copyright (C) 1995, 1996 Wolfgang Solfrank. @@ -242,15 +242,17 @@ initppc(startkernel, endkernel, args, btinfo) /* * Set up initial BAT table */ - /* map the lowest 256 MB area */ - battable[0].batl = BATL(0x00000000, BAT_M); - battable[0].batu = BATU(0x00000000); - /* map the PCI/ISA I/O 256 MB area */ - battable[1].batl = BATL(BEBOX_BUS_SPACE_IO, BAT_I); - battable[1].batu = BATU(BEBOX_BUS_SPACE_IO); - /* map the PCI/ISA MEMORY 256 MB area */ - battable[2].batl = BATL(BEBOX_BUS_SPACE_MEM, BAT_I); - battable[2].batu = BATU(BEBOX_BUS_SPACE_MEM); + /* map the lowest 256M area */ + battable[0].batl = BATL(0x00000000, BAT_M, BAT_PP_RW); + battable[0].batu = BATU(0x00000000, BAT_BL_256M, BAT_Vs); + + /* map the PCI/ISA I/O 256M area */ + battable[1].batl = BATL(BEBOX_BUS_SPACE_IO, BAT_I, BAT_PP_RW); + battable[1].batu = BATU(BEBOX_BUS_SPACE_IO, BAT_BL_256M, BAT_Vs); + + /* map the PCI/ISA MEMORY 256M area */ + battable[2].batl = BATL(BEBOX_BUS_SPACE_MEM, BAT_I, BAT_PP_RW); + battable[2].batu = BATU(BEBOX_BUS_SPACE_MEM, BAT_BL_256M, BAT_Vs); /* * Now setup fixed bat registers diff --git a/sys/arch/macppc/macppc/machdep.c b/sys/arch/macppc/macppc/machdep.c index d782dd904a4d..2191430fba51 100644 --- a/sys/arch/macppc/macppc/machdep.c +++ b/sys/arch/macppc/macppc/machdep.c @@ -1,4 +1,4 @@ -/* $NetBSD: machdep.c,v 1.62 1999/12/04 21:20:47 ragge Exp $ */ +/* $NetBSD: machdep.c,v 1.63 1999/12/18 01:37:00 thorpej Exp $ */ /* * Copyright (C) 1995, 1996 Wolfgang Solfrank. @@ -167,23 +167,23 @@ initppc(startkernel, endkernel, args) /* * Set up BAT0 to only map the lowest 256 MB area */ - battable[0].batl = BATL(0x00000000, BAT_M); - battable[0].batu = BATU(0x00000000); + battable[0].batl = BATL(0x00000000, BAT_M, BAT_PP_RW); + battable[0].batu = BATU(0x00000000, BAT_BL_256M, BAT_Vs); /* * Map PCI memory space. */ - battable[8].batl = BATL(0x80000000, BAT_I); - battable[8].batu = BATU(0x80000000); + battable[8].batl = BATL(0x80000000, BAT_I, BAT_PP_RW); + battable[8].batu = BATU(0x80000000, BAT_BL_256M, BAT_Vs); - battable[9].batl = BATL(0x90000000, BAT_I); - battable[9].batu = BATU(0x90000000); + battable[9].batl = BATL(0x90000000, BAT_I, BAT_PP_RW); + battable[9].batu = BATU(0x90000000, BAT_BL_256M, BAT_Vs); /* * Map obio devices. */ - battable[0xf].batl = BATL(0xf0000000, BAT_I); - battable[0xf].batu = BATU(0xf0000000); + battable[0xf].batl = BATL(0xf0000000, BAT_I, BAT_PP_RW); + battable[0xf].batu = BATU(0xf0000000, BAT_BL_256M, BAT_Vs); /* * Now setup fixed bat registers @@ -331,8 +331,10 @@ initppc(startkernel, endkernel, args) pmap_bootstrap(startkernel, endkernel); restore_ofw_mapping(); - battable[msgbuf_paddr >> 28].batl = BATL(msgbuf_paddr, BAT_M); - battable[msgbuf_paddr >> 28].batu = BATU(msgbuf_paddr); + battable[msgbuf_paddr >> 28].batl = BATL(msgbuf_paddr, BAT_M, + BAT_PP_RW); + battable[msgbuf_paddr >> 28].batu = BATU(msgbuf_paddr, BAT_BL_256M, + BAT_Vs); } static int N_mapping; diff --git a/sys/arch/macppc/macppc/rbus_machdep.c b/sys/arch/macppc/macppc/rbus_machdep.c index 5343a420e571..c3d32bdec279 100644 --- a/sys/arch/macppc/macppc/rbus_machdep.c +++ b/sys/arch/macppc/macppc/rbus_machdep.c @@ -1,4 +1,4 @@ -/* $NetBSD: rbus_machdep.c,v 1.2 1999/10/15 07:20:43 tsubai Exp $ */ +/* $NetBSD: rbus_machdep.c,v 1.3 1999/12/18 01:37:00 thorpej Exp $ */ /* * Copyright (c) 1999 @@ -102,8 +102,8 @@ rbus_pccbb_parent_mem(pa) size = 0x10000000; } - battable[start >> 28].batl = BATL(start, BAT_I); - battable[start >> 28].batu = BATU(start); + battable[start >> 28].batl = BATL(start, BAT_I, BAT_PP_RW); + battable[start >> 28].batu = BATU(start, BAT_BL_256M, BAT_Vs); return rbus_new_root_delegate(pa->pa_memt, start, size, 0); } diff --git a/sys/arch/ofppc/ofppc/machdep.c b/sys/arch/ofppc/ofppc/machdep.c index 07f4cf310d3f..28047f94dc76 100644 --- a/sys/arch/ofppc/ofppc/machdep.c +++ b/sys/arch/ofppc/ofppc/machdep.c @@ -1,4 +1,4 @@ -/* $NetBSD: machdep.c,v 1.48 1999/12/04 21:21:09 ragge Exp $ */ +/* $NetBSD: machdep.c,v 1.49 1999/12/18 01:37:00 thorpej Exp $ */ /* * Copyright (C) 1995, 1996 Wolfgang Solfrank. @@ -173,8 +173,8 @@ initppc(startkernel, endkernel, args) /* * Set up initial BAT table to only map the lowest 256 MB area */ - battable[0].batl = BATL(0x00000000, BAT_M); - battable[0].batu = BATU(0x00000000); + battable[0].batl = BATL(0x00000000, BAT_M, BAT_PP_RW); + battable[0].batu = BATU(0x00000000, BAT_BL_256M, BAT_Vs); /* * Now setup fixed bat registers