Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/rump/librump/rumpkern Provide stupid uvm_map() and uvm_u...



details:   https://anonhg.NetBSD.org/src/rev/49e05378e6ce
branches:  trunk
changeset: 823759:49e05378e6ce
user:      martin <martin%NetBSD.org@localhost>
date:      Sun May 07 14:20:50 2017 +0000

description:
Provide stupid uvm_map() and uvm_unmap1() immplementations - might be enough
to get audio tests in rump going again.
XXX needs a RUMP chef to review/replace by something sane!

diffstat:

 sys/rump/librump/rumpkern/vm.c |  14 +++++++++++---
 1 files changed, 11 insertions(+), 3 deletions(-)

diffs (35 lines):

diff -r f601ac25ac82 -r 49e05378e6ce sys/rump/librump/rumpkern/vm.c
--- a/sys/rump/librump/rumpkern/vm.c    Sun May 07 12:22:22 2017 +0000
+++ b/sys/rump/librump/rumpkern/vm.c    Sun May 07 14:20:50 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: vm.c,v 1.171 2017/05/07 11:48:39 martin Exp $  */
+/*     $NetBSD: vm.c,v 1.172 2017/05/07 14:20:50 martin Exp $  */
 
 /*
  * Copyright (c) 2007-2011 Antti Kantee.  All Rights Reserved.
@@ -41,7 +41,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm.c,v 1.171 2017/05/07 11:48:39 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm.c,v 1.172 2017/05/07 14:20:50 martin Exp $");
 
 #include <sys/param.h>
 #include <sys/atomic.h>
@@ -720,7 +720,15 @@
     uvm_flag_t flags)
 {
 
-       return EOPNOTSUPP;
+       *startp = (vaddr_t)rump_hypermalloc(size, align, true, "uvm_map");
+       return *startp != 0 ? 0 : ENOMEM;
+}
+
+void
+uvm_unmap1(struct vm_map *map, vaddr_t start, vaddr_t end, int flags)
+{
+
+       rump_hyperfree((void*)start, end-start);
 }
 
 



Home | Main Index | Thread Index | Old Index