Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/atari/atari Get 060 CacheCopyBack support in line w...
details: https://anonhg.NetBSD.org/src/rev/00720ac13117
branches: trunk
changeset: 494014:00720ac13117
user: leo <leo%NetBSD.org@localhost>
date: Thu Jun 29 07:36:16 2000 +0000
description:
Get 060 CacheCopyBack support in line with the amiga (and working ;-)
diffstat:
sys/arch/atari/atari/atari_init.c | 15 +++++++++++----
sys/arch/atari/atari/pmap.c | 7 ++++---
2 files changed, 15 insertions(+), 7 deletions(-)
diffs (70 lines):
diff -r 80c8f54e3db9 -r 00720ac13117 sys/arch/atari/atari/atari_init.c
--- a/sys/arch/atari/atari/atari_init.c Thu Jun 29 07:18:57 2000 +0000
+++ b/sys/arch/atari/atari/atari_init.c Thu Jun 29 07:36:16 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: atari_init.c,v 1.49 2000/06/27 04:18:53 mrg Exp $ */
+/* $NetBSD: atari_init.c,v 1.50 2000/06/29 07:36:16 leo Exp $ */
/*
* Copyright (c) 1995 Leo Weppelman
@@ -173,6 +173,7 @@
*
* Very crude 68040 support by Michael L. Hitch.
*/
+int kernel_copyback = 1;
void
start_c(id, ttphystart, ttphysize, stphysize, esym_addr)
@@ -366,13 +367,19 @@
* recommended by Motorola; for the 68060 mandatory)
*/
if (mmutype == MMU_68040) {
+
+ if (kernel_copyback)
+ pg_proto |= PG_CCB;
+
for (; i < (u_int)Sysseg; i += NBPG, pg_proto += NBPG)
*pg++ = pg_proto;
+
pg_proto = (pg_proto & ~PG_CCB) | PG_CI;
- for (; i < (u_int)&Sysseg[kstsize * NPTEPG]; i += NBPG,
- pg_proto += NBPG)
+ for (; i < pstart; i += NBPG, pg_proto += NBPG)
*pg++ = pg_proto;
- pg_proto = (pg_proto & ~PG_CI) | PG_CCB;
+ pg_proto = (pg_proto & ~PG_CI);
+ if (kernel_copyback)
+ pg_proto |= PG_CCB;
}
#endif /* defined(M68040) || defined(M68060) */
diff -r 80c8f54e3db9 -r 00720ac13117 sys/arch/atari/atari/pmap.c
--- a/sys/arch/atari/atari/pmap.c Thu Jun 29 07:18:57 2000 +0000
+++ b/sys/arch/atari/atari/pmap.c Thu Jun 29 07:36:16 2000 +0000
@@ -1,4 +1,3 @@
-/* $NetBSD: pmap.c,v 1.56 2000/06/26 14:20:39 mrg Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -1081,6 +1080,8 @@
* or lose information. That is, this routine must actually
* insert this page into the given map NOW.
*/
+extern int kernel_copyback;
+
int
pmap_enter(pmap, va, pa, prot, flags)
register pmap_t pmap;
@@ -1306,10 +1307,10 @@
if (wired)
npte |= PG_W;
if (!checkpv && !cacheable)
- npte |= PG_CI;
+ npte |= (cputype == CPU_68060 ? PG_CIN : PG_CI);
#if defined(M68040) || defined(M68060)
else if (mmutype == MMU_68040 && (npte & PG_PROT) == PG_RW &&
- pmap != pmap_kernel())
+ (kernel_copyback || pmap != pmap_kernel()))
npte |= PG_CCB; /* cache copyback */
#endif
/*
Home |
Main Index |
Thread Index |
Old Index