Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/uebayasi-xip]: src/sys Re-define the definition of "device page"; device...
details: https://anonhg.NetBSD.org/src/rev/f12a5d8f3ea7
branches: uebayasi-xip
changeset: 751724:f12a5d8f3ea7
user: uebayasi <uebayasi%NetBSD.org@localhost>
date: Mon May 31 13:26:36 2010 +0000
description:
Re-define the definition of "device page"; device pages are pages of
device memory. Pages which don't have vm_page (== can't be used for
generic use), but whose PV are tracked, are called "direct pages" from
now.
diffstat:
sys/arch/alpha/alpha/pmap.c | 6 +-
sys/arch/arm/arm32/mem.c | 6 +-
sys/arch/arm/arm32/pmap.c | 6 +-
sys/arch/arm/imx/imx31_space.c | 16 +-
sys/arch/arm/include/bus.h | 26 ++--
sys/arch/hppa/hppa/pmap.c | 6 +-
sys/arch/ia64/ia64/pmap.c | 6 +-
sys/conf/files | 6 +-
sys/dev/flash.c | 6 +-
sys/miscfs/genfs/genfs_io.c | 8 +-
sys/rump/librump/rumpkern/opt/opt_device_page.h | 1 -
sys/rump/librump/rumpkern/opt/opt_direct_page.h | 1 +
sys/uvm/uvm_bio.c | 16 +-
sys/uvm/uvm_extern.h | 6 +-
sys/uvm/uvm_fault.c | 40 +++---
sys/uvm/uvm_km.c | 6 +-
sys/uvm/uvm_loan.c | 8 +-
sys/uvm/uvm_object.c | 6 +-
sys/uvm/uvm_page.c | 134 +++++++++++------------
sys/uvm/uvm_page.h | 16 +-
20 files changed, 159 insertions(+), 167 deletions(-)
diffs (truncated from 998 to 300 lines):
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/arch/alpha/alpha/pmap.c
--- a/sys/arch/alpha/alpha/pmap.c Mon May 31 06:38:34 2010 +0000
+++ b/sys/arch/alpha/alpha/pmap.c Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.252.2.2 2010/04/28 08:31:05 uebayasi Exp $ */
+/* $NetBSD: pmap.c,v 1.252.2.3 2010/05/31 13:26:36 uebayasi Exp $ */
/*-
* Copyright (c) 1998, 1999, 2000, 2001, 2007, 2008 The NetBSD Foundation, Inc.
@@ -137,12 +137,12 @@
#include "opt_lockdebug.h"
#include "opt_sysv.h"
#include "opt_multiprocessor.h"
-#include "opt_device_page.h"
+#include "opt_direct_page.h"
#include "opt_xip.h"
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.252.2.2 2010/04/28 08:31:05 uebayasi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.252.2.3 2010/05/31 13:26:36 uebayasi Exp $");
#include <sys/param.h>
#include <sys/systm.h>
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/arch/arm/arm32/mem.c
--- a/sys/arch/arm/arm32/mem.c Mon May 31 06:38:34 2010 +0000
+++ b/sys/arch/arm/arm32/mem.c Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mem.c,v 1.26.6.3 2010/02/25 03:30:22 uebayasi Exp $ */
+/* $NetBSD: mem.c,v 1.26.6.4 2010/05/31 13:26:36 uebayasi Exp $ */
/*
* Copyright (c) 1982, 1986, 1990, 1993
@@ -74,11 +74,11 @@
#include "opt_arm32_pmap.h"
#include "opt_compat_netbsd.h"
-#include "opt_device_page.h"
+#include "opt_direct_page.h"
#include "opt_xip.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: mem.c,v 1.26.6.3 2010/02/25 03:30:22 uebayasi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: mem.c,v 1.26.6.4 2010/05/31 13:26:36 uebayasi Exp $");
#include <sys/param.h>
#include <sys/conf.h>
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/arch/arm/arm32/pmap.c
--- a/sys/arch/arm/arm32/pmap.c Mon May 31 06:38:34 2010 +0000
+++ b/sys/arch/arm/arm32/pmap.c Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.211.2.12 2010/04/30 14:39:07 uebayasi Exp $ */
+/* $NetBSD: pmap.c,v 1.211.2.13 2010/05/31 13:26:36 uebayasi Exp $ */
/*
* Copyright 2003 Wasabi Systems, Inc.
@@ -191,7 +191,7 @@
#include "opt_ddb.h"
#include "opt_lockdebug.h"
#include "opt_multiprocessor.h"
-#include "opt_device_page.h"
+#include "opt_direct_page.h"
#include "opt_xip.h"
#include <sys/param.h>
@@ -213,7 +213,7 @@
#include <machine/param.h>
#include <arm/arm32/katelib.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.211.2.12 2010/04/30 14:39:07 uebayasi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.211.2.13 2010/05/31 13:26:36 uebayasi Exp $");
#ifdef PMAP_DEBUG
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/arch/arm/imx/imx31_space.c
--- a/sys/arch/arm/imx/imx31_space.c Mon May 31 06:38:34 2010 +0000
+++ b/sys/arch/arm/imx/imx31_space.c Mon May 31 13:26:36 2010 +0000
@@ -1,7 +1,7 @@
-/* $Id: imx31_space.c,v 1.3.2.2 2010/04/29 03:16:18 uebayasi Exp $ */
+/* $Id: imx31_space.c,v 1.3.2.3 2010/05/31 13:26:36 uebayasi Exp $ */
/* derived from: */
-/* $NetBSD: imx31_space.c,v 1.3.2.2 2010/04/29 03:16:18 uebayasi Exp $ */
+/* $NetBSD: imx31_space.c,v 1.3.2.3 2010/05/31 13:26:36 uebayasi Exp $ */
/*
* Copyright (c) 2001, 2002 Wasabi Systems, Inc.
@@ -166,8 +166,8 @@
/* physload */
imx31_bs_physload,
imx31_bs_physunload,
- imx31_bs_physload_device,
- imx31_bs_physunload_device,
+ imx31_bs_physload_direct,
+ imx31_bs_physunload_direct,
};
int
@@ -302,18 +302,18 @@
}
void *
-imx31_bs_physload_device(void *t, bus_addr_t addr, bus_size_t size, int prot, int flags)
+imx31_bs_physload_direct(void *t, bus_addr_t addr, bus_size_t size, int prot, int flags)
{
/* XXX */
const paddr_t start = imx31_bs_mmap(t, addr, 0, prot, flags);
const paddr_t end = imx31_bs_mmap(t, addr + size, 0, prot, flags);
- return uvm_page_physload_device(start, end, start, end, prot, flags);
+ return uvm_page_physload_direct(start, end, start, end, prot, flags);
}
void
-imx31_bs_physunload_device(void *t, void *phys)
+imx31_bs_physunload_direct(void *t, void *phys)
{
- uvm_page_physunload_device(phys);
+ uvm_page_physunload_direct(phys);
}
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/arch/arm/include/bus.h
--- a/sys/arch/arm/include/bus.h Mon May 31 06:38:34 2010 +0000
+++ b/sys/arch/arm/include/bus.h Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bus.h,v 1.20.2.1 2010/04/28 14:56:14 uebayasi Exp $ */
+/* $NetBSD: bus.h,v 1.20.2.2 2010/05/31 13:26:36 uebayasi Exp $ */
/*-
* Copyright (c) 1996, 1997, 1998, 2001 The NetBSD Foundation, Inc.
@@ -276,9 +276,9 @@
void * (*bs_physload)(void *, bus_addr_t, bus_size_t,
int, int);
void (*bs_physunload)(void *, void *);
- void * (*bs_physload_device)(void *, bus_addr_t, bus_size_t,
+ void * (*bs_physload_direct)(void *, bus_addr_t, bus_size_t,
int, int);
- void (*bs_physunload_device)(void *, void *);
+ void (*bs_physunload_direct)(void *, void *);
#endif
};
@@ -705,11 +705,11 @@
bus_addr_t addr, bus_size_t size, int prot, int flags);
#define bs_physunload_proto(f) \
void __bs_c(f,_bs_physunload)(void *t, void *phys)
-#define bs_physload_device_proto(f) \
-void * __bs_c(f,_bs_physload_device)(void *t, \
+#define bs_physload_direct_proto(f) \
+void * __bs_c(f,_bs_physload_direct)(void *t, \
bus_addr_t addr, bus_size_t size, int prot, int flags);
-#define bs_physunload_device_proto(f) \
-void __bs_c(f,_bs_physunload_device)(void *t, void *phys)
+#define bs_physunload_direct_proto(f) \
+void __bs_c(f,_bs_physunload_direct)(void *t, void *phys)
#endif
#define bs_protos(f) \
@@ -759,8 +759,8 @@
bs_c_8_proto(f); \
bs_physload_proto(f); \
bs_physunload_proto(f); \
-bs_physload_device_proto(f); \
-bs_physunload_device_proto(f);
+bs_physload_direct_proto(f); \
+bs_physunload_direct_proto(f);
#define BUS_SPACE_ALIGNED_POINTER(p, t) ALIGNED_POINTER(p, t)
@@ -771,10 +771,10 @@
(*(t)->bs_physload)((t)->bs_cookie, (a), (s), (p), (f))
#define bus_space_physunload(t, p) \
(*(t)->bs_physunload)((t)->bs_cookie, (p))
-#define bus_space_physload_device(t, a, s, p, f) \
- (*(t)->bs_physload_device)((t)->bs_cookie, (a), (s), (p), (f))
-#define bus_space_physunload_device(t, p) \
- (*(t)->bs_physunload_device)((t)->bs_cookie, (p))
+#define bus_space_physload_direct(t, a, s, p, f) \
+ (*(t)->bs_physload_direct)((t)->bs_cookie, (a), (s), (p), (f))
+#define bus_space_physunload_direct(t, p) \
+ (*(t)->bs_physunload_direct)((t)->bs_cookie, (p))
/* Bus Space DMA macros */
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/arch/hppa/hppa/pmap.c
--- a/sys/arch/hppa/hppa/pmap.c Mon May 31 06:38:34 2010 +0000
+++ b/sys/arch/hppa/hppa/pmap.c Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.63.2.4 2010/05/28 08:32:20 uebayasi Exp $ */
+/* $NetBSD: pmap.c,v 1.63.2.5 2010/05/31 13:26:37 uebayasi Exp $ */
/*-
* Copyright (c) 2001, 2002 The NetBSD Foundation, Inc.
@@ -65,9 +65,9 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.63.2.4 2010/05/28 08:32:20 uebayasi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.63.2.5 2010/05/31 13:26:37 uebayasi Exp $");
-#include "opt_device_page.h"
+#include "opt_direct_page.h"
#include "opt_xip.h"
#include "opt_cputype.h"
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/arch/ia64/ia64/pmap.c
--- a/sys/arch/ia64/ia64/pmap.c Mon May 31 06:38:34 2010 +0000
+++ b/sys/arch/ia64/ia64/pmap.c Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.24.2.2 2010/04/28 08:31:06 uebayasi Exp $ */
+/* $NetBSD: pmap.c,v 1.24.2.3 2010/05/31 13:26:37 uebayasi Exp $ */
/*-
@@ -85,9 +85,9 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.24.2.2 2010/04/28 08:31:06 uebayasi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.24.2.3 2010/05/31 13:26:37 uebayasi Exp $");
-#include "opt_device_page.h"
+#include "opt_direct_page.h"
#include "opt_xip.h"
#include <sys/param.h>
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/conf/files
--- a/sys/conf/files Mon May 31 06:38:34 2010 +0000
+++ b/sys/conf/files Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: files,v 1.974.2.3 2010/04/30 14:43:03 uebayasi Exp $
+# $NetBSD: files,v 1.974.2.4 2010/05/31 13:26:37 uebayasi Exp $
# @(#)files.newconf 7.5 (Berkeley) 5/10/93
version 20090313
@@ -119,10 +119,10 @@
defflag opt_wapbl.h WAPBL WAPBL_DEBUG
defparam opt_wapbl.h WAPBL_DEBUG_PRINT
-defflag opt_device_page.h DEVICE_PAGE
+defflag opt_direct_page.h DIRECT_PAGE
# eXecute In Place
-defflag opt_xip.h XIP: DEVICE_PAGE
+defflag opt_xip.h XIP: DIRECT_PAGE
# compatibility options
#
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/dev/flash.c
--- a/sys/dev/flash.c Mon May 31 06:38:34 2010 +0000
+++ b/sys/dev/flash.c Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-/* $Id: flash.c,v 1.1.2.8 2010/04/29 06:29:29 uebayasi Exp $ */
+/* $Id: flash.c,v 1.1.2.9 2010/05/31 13:26:37 uebayasi Exp $ */
/*-
* Copyright (c) 2010 Tsubai Masanari. All rights reserved.
@@ -238,9 +238,9 @@
#ifdef XIP
#ifndef __BUS_SPACE_HAS_PHYSLOAD
-#error bus_space_physload_device(9) must be supported to use XIP!
+#error bus_space_physload_direct(9) must be supported to use XIP!
#else
- sc->sc_phys = bus_space_physload_device(sc->sc_iot, sc->sc_addr, sc->sc_size,
+ sc->sc_phys = bus_space_physload_direct(sc->sc_iot, sc->sc_addr, sc->sc_size,
PROT_READ | PROT_WRITE, 0);
#endif
#endif
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/miscfs/genfs/genfs_io.c
--- a/sys/miscfs/genfs/genfs_io.c Mon May 31 06:38:34 2010 +0000
+++ b/sys/miscfs/genfs/genfs_io.c Mon May 31 13:26:36 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: genfs_io.c,v 1.36.2.7 2010/04/28 16:33:47 uebayasi Exp $ */
+/* $NetBSD: genfs_io.c,v 1.36.2.8 2010/05/31 13:26:37 uebayasi Exp $ */
/*
* Copyright (c) 1982, 1986, 1989, 1993
@@ -31,9 +31,9 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: genfs_io.c,v 1.36.2.7 2010/04/28 16:33:47 uebayasi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: genfs_io.c,v 1.36.2.8 2010/05/31 13:26:37 uebayasi Exp $");
-#include "opt_device_page.h"
+#include "opt_direct_page.h"
#include "opt_xip.h"
#include <sys/param.h>
@@ -822,7 +822,7 @@
(off - (lbn << fs_bshift));
}
- pps[i] = uvm_phys_to_vm_page_device(phys_addr);
+ pps[i] = uvm_phys_to_vm_page_direct(phys_addr);
UVMHIST_LOG(ubchist, "xip pgs %d => phys_addr=0x%lx (%p)",
i,
diff -r c779f97bcb0a -r f12a5d8f3ea7 sys/rump/librump/rumpkern/opt/opt_device_page.h
Home |
Main Index |
Thread Index |
Old Index