Module Name: src
Committed By: pooka
Date: Fri Jan 21 13:11:04 UTC 2011
Modified Files:
src/sys/rump/fs/lib/libzfs: Makefile
src/sys/rump/librump/rumpkern: emul.c
Log Message:
Since "physmem" is largely unused except for zfs wanting to know
if it has enough memory available, just pick a number which makes
zfs happy.
We *could* use a MIN() of available host mem and rump_memlimit,
though ...
To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/rump/fs/lib/libzfs/Makefile
cvs rdiff -u -r1.148 -r1.149 src/sys/rump/librump/rumpkern/emul.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/rump/fs/lib/libzfs/Makefile
diff -u src/sys/rump/fs/lib/libzfs/Makefile:1.1 src/sys/rump/fs/lib/libzfs/Makefile:1.2
--- src/sys/rump/fs/lib/libzfs/Makefile:1.1 Tue Jan 18 22:21:23 2011
+++ src/sys/rump/fs/lib/libzfs/Makefile Fri Jan 21 13:11:04 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2011/01/18 22:21:23 haad Exp $
+# $NetBSD: Makefile,v 1.2 2011/01/21 13:11:04 pooka Exp $
#
S!= cd ${.PARSEDIR}/../../../../;pwd
@@ -10,7 +10,6 @@
# RUMP stuff
CPPFLAGS+= -I${RUMPTOP}/librump/rumpkern -I${RUMPTOP}/librump/rumpvfs\
-I${RUMPTOP}/librump/rumpdev
-SRCS+= component.c
.include <bsd.lib.mk>
Index: src/sys/rump/librump/rumpkern/emul.c
diff -u src/sys/rump/librump/rumpkern/emul.c:1.148 src/sys/rump/librump/rumpkern/emul.c:1.149
--- src/sys/rump/librump/rumpkern/emul.c:1.148 Thu Jan 6 11:22:55 2011
+++ src/sys/rump/librump/rumpkern/emul.c Fri Jan 21 13:11:03 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: emul.c,v 1.148 2011/01/06 11:22:55 pooka Exp $ */
+/* $NetBSD: emul.c,v 1.149 2011/01/21 13:11:03 pooka Exp $ */
/*
* Copyright (c) 2007 Antti Kantee. All Rights Reserved.
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: emul.c,v 1.148 2011/01/06 11:22:55 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: emul.c,v 1.149 2011/01/21 13:11:03 pooka Exp $");
#include <sys/param.h>
#include <sys/null.h>
@@ -62,11 +62,21 @@
#include "rump_private.h"
+/*
+ * physmem is largely unused (except for nmbcluster calculations),
+ * so pick a default value which suits ZFS. if an application wants
+ * a very small memory footprint, it can still adjust this before
+ * calling rump_init()
+ */
+#define PHYSMEM 512*256
+int physmem = PHYSMEM;
+int nkmempages = PHYSMEM/2; /* from le chapeau */
+#undef PHYSMEM
+
struct lwp lwp0;
struct vnode *rootvp;
dev_t rootdev = NODEV;
-int physmem = 256*256; /* 256 * 1024*1024 / 4k, PAGE_SIZE not always set */
-int nkmempages = 256*256/2; /* from le chapeau */
+
const int schedppq = 1;
int hardclock_ticks;
bool mp_online = false;