Module Name: src
Committed By: uebayasi
Date: Wed Aug 11 14:02:45 UTC 2010
Modified Files:
src/sys/arch/evbppc/obs405 [uebayasi-xip]: obs266_machdep.c
Log Message:
Map the NOR FlashROM region into kernel using a reserved TLB. This is
touched to synchronize I-cache an executable page by pmap_enter().
To generate a diff of this commit:
cvs rdiff -u -r1.10.2.1 -r1.10.2.2 \
src/sys/arch/evbppc/obs405/obs266_machdep.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/evbppc/obs405/obs266_machdep.c
diff -u src/sys/arch/evbppc/obs405/obs266_machdep.c:1.10.2.1 src/sys/arch/evbppc/obs405/obs266_machdep.c:1.10.2.2
--- src/sys/arch/evbppc/obs405/obs266_machdep.c:1.10.2.1 Fri Apr 30 14:39:18 2010
+++ src/sys/arch/evbppc/obs405/obs266_machdep.c Wed Aug 11 14:02:45 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: obs266_machdep.c,v 1.10.2.1 2010/04/30 14:39:18 uebayasi Exp $ */
+/* $NetBSD: obs266_machdep.c,v 1.10.2.2 2010/08/11 14:02:45 uebayasi Exp $ */
/* Original: md_machdep.c,v 1.3 2005/01/24 18:47:37 shige Exp $ */
/*
@@ -68,12 +68,13 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: obs266_machdep.c,v 1.10.2.1 2010/04/30 14:39:18 uebayasi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: obs266_machdep.c,v 1.10.2.2 2010/08/11 14:02:45 uebayasi Exp $");
#include "opt_compat_netbsd.h"
#include "opt_ddb.h"
#include "opt_ipkdb.h"
#include "opt_modular.h"
+#include "opt_xip.h"
#include <sys/param.h>
#include <sys/kernel.h>
@@ -149,6 +150,11 @@
for (va = 0; va < endkernel; va += TLB_PG_SIZE)
ppc4xx_tlb_reserve(va, va, TLB_PG_SIZE, TLB_EX);
+#ifdef XIP
+ /* Map NOR FlashROM as managed. */
+ ppc4xx_tlb_reserve(0xff000000, 0xff000000, TLB_PG_SIZE, TLB_I);
+#endif
+
/* Map console after RAM (see pmap_tlbmiss()) */
ppc4xx_tlb_reserve(CONADDR, roundup(memsize, TLB_PG_SIZE), TLB_PG_SIZE,
TLB_I | TLB_G);