Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys Make vmapbuf() return success/error and make physio deal...
details: https://anonhg.NetBSD.org/src/rev/48f272092700
branches: trunk
changeset: 761910:48f272092700
user: pooka <pooka%NetBSD.org@localhost>
date: Thu Feb 10 14:46:44 2011 +0000
description:
Make vmapbuf() return success/error and make physio deal with a
failure.
diffstat:
sys/arch/acorn26/acorn26/vm_machdep.c | 8 +++++---
sys/arch/alpha/alpha/vm_machdep.c | 8 +++++---
sys/arch/arm/arm32/vm_machdep.c | 8 +++++---
sys/arch/hppa/hppa/vm_machdep.c | 8 +++++---
sys/arch/ia64/ia64/vm_machdep.c | 6 +++---
sys/arch/m68k/m68k/vm_machdep.c | 8 +++++---
sys/arch/mips/mips/vm_machdep.c | 8 +++++---
sys/arch/powerpc/powerpc/vm_machdep.c | 8 +++++---
sys/arch/sh3/sh3/vm_machdep.c | 8 +++++---
sys/arch/sparc/sparc/vm_machdep.c | 8 +++++---
sys/arch/sparc64/sparc64/vm_machdep.c | 8 +++++---
sys/arch/vax/vax/vm_machdep.c | 10 ++++++----
sys/arch/x86/x86/vm_machdep.c | 8 +++++---
sys/kern/kern_physio.c | 19 +++++++++++++------
sys/rump/librump/rumpkern/vm.c | 17 ++++++++++++-----
sys/uvm/uvm_extern.h | 4 ++--
16 files changed, 91 insertions(+), 53 deletions(-)
diffs (truncated from 577 to 300 lines):
diff -r d3545449241b -r 48f272092700 sys/arch/acorn26/acorn26/vm_machdep.c
--- a/sys/arch/acorn26/acorn26/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/acorn26/acorn26/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.26 2009/11/29 04:15:42 rmind Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.27 2011/02/10 14:46:45 pooka Exp $ */
/*-
* Copyright (c) 2000, 2001 Ben Harris
@@ -64,7 +64,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.26 2009/11/29 04:15:42 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.27 2011/02/10 14:46:45 pooka Exp $");
#include <sys/param.h>
#include <sys/buf.h>
@@ -173,7 +173,7 @@
* do not need to pass an access_type to pmap_enter().
*/
/* This code was originally stolen from the alpha port. */
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
{
vaddr_t faddr, taddr, off;
@@ -203,6 +203,8 @@
taddr += PAGE_SIZE;
}
pmap_update(vm_map_pmap(phys_map));
+
+ return 0;
}
/*
diff -r d3545449241b -r 48f272092700 sys/arch/alpha/alpha/vm_machdep.c
--- a/sys/arch/alpha/alpha/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/alpha/alpha/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.104 2009/11/29 04:15:42 rmind Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.105 2011/02/10 14:46:46 pooka Exp $ */
/*
* Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
@@ -29,7 +29,7 @@
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.104 2009/11/29 04:15:42 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.105 2011/02/10 14:46:46 pooka Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -192,7 +192,7 @@
* Note: the pages are already locked by uvm_vslock(), so we
* do not need to pass an access_type to pmap_enter().
*/
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
{
vaddr_t faddr, taddr, off;
@@ -219,6 +219,8 @@
taddr += PAGE_SIZE;
}
pmap_update(vm_map_pmap(phys_map));
+
+ return 0;
}
/*
diff -r d3545449241b -r 48f272092700 sys/arch/arm/arm32/vm_machdep.c
--- a/sys/arch/arm/arm32/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/arm/arm32/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.54 2011/01/14 02:06:23 rmind Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.55 2011/02/10 14:46:46 pooka Exp $ */
/*
* Copyright (c) 1994-1998 Mark Brinicombe.
@@ -44,7 +44,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.54 2011/01/14 02:06:23 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.55 2011/02/10 14:46:46 pooka Exp $");
#include "opt_armfpe.h"
#include "opt_pmap_debug.h"
@@ -256,7 +256,7 @@
* Note: the pages are already locked by uvm_vslock(), so we
* do not need to pass an access_type to pmap_enter().
*/
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
{
vaddr_t faddr, taddr, off;
@@ -293,6 +293,8 @@
len -= PAGE_SIZE;
}
pmap_update(pmap_kernel());
+
+ return 0;
}
/*
diff -r d3545449241b -r 48f272092700 sys/arch/hppa/hppa/vm_machdep.c
--- a/sys/arch/hppa/hppa/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/hppa/hppa/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.47 2011/02/07 12:19:35 skrll Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.48 2011/02/10 14:46:46 pooka Exp $ */
/* $OpenBSD: vm_machdep.c,v 1.64 2008/09/30 18:54:26 miod Exp $ */
@@ -29,7 +29,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.47 2011/02/07 12:19:35 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.48 2011/02/10 14:46:46 pooka Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -243,7 +243,7 @@
/*
* Map an IO request into kernel virtual address space.
*/
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
{
vaddr_t uva, kva;
@@ -274,6 +274,8 @@
kva += PAGE_SIZE;
}
pmap_update(kpmap);
+
+ return 0;
}
/*
diff -r d3545449241b -r 48f272092700 sys/arch/ia64/ia64/vm_machdep.c
--- a/sys/arch/ia64/ia64/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/ia64/ia64/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.10 2009/11/29 04:15:42 rmind Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.11 2011/02/10 14:46:46 pooka Exp $ */
/*
* Copyright (c) 2006 The NetBSD Foundation, Inc.
@@ -142,11 +142,11 @@
* Note: the pages are already locked by uvm_vslock(), so we
* do not need to pass an access_type to pmap_enter().
*/
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
{
printf("%s: not yet\n", __func__);
- return;
+ return 0;
}
/*
diff -r d3545449241b -r 48f272092700 sys/arch/m68k/m68k/vm_machdep.c
--- a/sys/arch/m68k/m68k/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/m68k/m68k/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.36 2011/02/08 20:20:17 rmind Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.37 2011/02/10 14:46:46 pooka Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@@ -39,7 +39,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.36 2011/02/08 20:20:17 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.37 2011/02/10 14:46:46 pooka Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -159,7 +159,7 @@
* Note: the pages are already locked by uvm_vslock(), so we
* do not need to pass an access_type to pmap_enter().
*/
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
{
struct pmap *upmap, *kpmap;
@@ -193,6 +193,8 @@
len -= PAGE_SIZE;
} while (len);
pmap_update(kpmap);
+
+ return 0;
}
/*
diff -r d3545449241b -r 48f272092700 sys/arch/mips/mips/vm_machdep.c
--- a/sys/arch/mips/mips/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/mips/mips/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.134 2011/02/08 20:20:19 rmind Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.135 2011/02/10 14:46:47 pooka Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@@ -39,7 +39,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.134 2011/02/08 20:20:19 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.135 2011/02/10 14:46:47 pooka Exp $");
#include "opt_ddb.h"
@@ -191,7 +191,7 @@
/*
* Map a user I/O request into kernel virtual address space.
*/
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
{
struct pmap *upmap;
@@ -219,6 +219,8 @@
len -= PAGE_SIZE;
} while (len);
pmap_update(vm_map_pmap(phys_map));
+
+ return 0;
}
/*
diff -r d3545449241b -r 48f272092700 sys/arch/powerpc/powerpc/vm_machdep.c
--- a/sys/arch/powerpc/powerpc/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/powerpc/powerpc/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.82 2011/02/02 09:02:39 matt Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.83 2011/02/10 14:46:47 pooka Exp $ */
/*
* Copyright (C) 1995, 1996 Wolfgang Solfrank.
@@ -32,7 +32,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.82 2011/02/02 09:02:39 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.83 2011/02/10 14:46:47 pooka Exp $");
#include "opt_altivec.h"
#include "opt_multiprocessor.h"
@@ -232,7 +232,7 @@
* Map a user I/O request into kernel virtual address space.
* Note: these pages have already been locked by uvm_vslock.
*/
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
{
vaddr_t faddr, taddr;
@@ -265,6 +265,8 @@
taddr += PAGE_SIZE;
}
pmap_update(pmap_kernel());
+
+ return 0;
}
/*
diff -r d3545449241b -r 48f272092700 sys/arch/sh3/sh3/vm_machdep.c
--- a/sys/arch/sh3/sh3/vm_machdep.c Thu Feb 10 14:04:29 2011 +0000
+++ b/sys/arch/sh3/sh3/vm_machdep.c Thu Feb 10 14:46:44 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.70 2011/02/01 01:54:14 uwe Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.71 2011/02/10 14:46:47 pooka Exp $ */
/*-
* Copyright (c) 2002 The NetBSD Foundation, Inc. All rights reserved.
@@ -81,7 +81,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.70 2011/02/01 01:54:14 uwe Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.71 2011/02/10 14:46:47 pooka Exp $");
#include "opt_kstack_debug.h"
@@ -327,7 +327,7 @@
* (a name with only slightly more meaning than "kernel_map")
*/
-void
+int
vmapbuf(struct buf *bp, vsize_t len)
Home |
Main Index |
Thread Index |
Old Index