Source-Changes-HG archive

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

[src/trunk]: src Add a rump server which comes with all the drivers currently



details:   https://anonhg.NetBSD.org/src/rev/e2d9fcb915db
branches:  trunk
changeset: 759317:e2d9fcb915db
user:      pooka <pooka%NetBSD.org@localhost>
date:      Sun Dec 05 17:37:32 2010 +0000

description:
Add a rump server which comes with all the drivers currently
available.  In terms of modules it maps to:

golem> rump.modstat
NAME             CLASS      SOURCE     REFS  SIZE     REQUIRES
bpf              driver     builtin    0     -        -
cd9660           vfs        builtin    0     -        -
cgd              driver     builtin    0     -        -
dm               driver     builtin    0     -        -
efs              vfs        builtin    0     -        -
ext2fs           vfs        builtin    0     -        ffs
fdesc            vfs        builtin    0     -        -
ffs              vfs        builtin    3     -        -
fss              driver     builtin    0     -        -
hfs              vfs        builtin    0     -        -
kernfs           vfs        builtin    0     -        -
ksem             misc       builtin    0     -        -
layerfs          misc       builtin    2     -        -
lfs              vfs        builtin    0     -        ffs
mfs              vfs        builtin    0     -        ffs
msdos            vfs        builtin    0     -        -
nfs              vfs        builtin    1     -        -
nfsserver        misc       builtin    0     -        nfs
nilfs            vfs        builtin    0     -        -
ntfs             vfs        builtin    0     -        -
null             vfs        builtin    0     -        layerfs
pad              driver     builtin    0     -        -
ptyfs            vfs        builtin    0     -        -
puffs            vfs        builtin    0     -        putter
putter           driver     builtin    1     -        -
scsiverbose      misc       builtin    0     -        -
smbfs            vfs        builtin    0     -        -
suser            secmodel   builtin    0     -        -
swsensor         driver     builtin    0     -        -
sysvbfs          vfs        builtin    0     -        -
tmpfs            vfs        builtin    0     -        -
udf              vfs        builtin    0     -        -
umap             vfs        builtin    0     -        layerfs
union            vfs        builtin    0     -        -
usbverbose       misc       builtin    0     -        -
wapbl            vfs        builtin    0     -        -


In terms of interfaces:
golem> rump.ifconfig -C
shmif virt lo carp


and dmesg:
NetBSD 5.99.41 (RUMP-ROAST) #0: Tue Nov 30 15:35:05 CET 2010
        pooka@pain-rustique.localhost:/usr/allsrc/src/sys/rump/librump/rumpkern
total memory = unlimited (host limit)
timecounter: Timecounters tick every 10.000 msec
timecounter: Timecounter "rumpclk" frequency 100 Hz quality 0
cpu0 at thinair0: rump virtual cpu
cpu1 at thinair0: rump virtual cpu
root file system type: rumpfs
mainbus0 (root)
ugenhc0 at mainbus0
usb0 at ugenhc0: USB revision 2.0
uhub0 at usb0: vendor 0x7275 product 0x6d70, class 9/0, rev 0.00/0.00, addr 1
uhub0: 1 port with 1 removable, self powered
ugenhc1 at mainbus0
usb1 at ugenhc1: USB revision 2.0
uhub1 at usb1: vendor 0x7275 product 0x6d70, class 9/0, rev 0.00/0.00, addr 1
uhub1: 1 port with 1 removable, self powered
ugenhc2 at mainbus0
usb2 at ugenhc2: USB revision 2.0
uhub2 at usb2: vendor 0x7275 product 0x6d70, class 9/0, rev 0.00/0.00, addr 1
uhub2: 1 port with 1 removable, self powered
ugenhc3 at mainbus0
usb3 at ugenhc3: USB revision 2.0
uhub3 at usb3: vendor 0x7275 product 0x6d70, class 9/0, rev 0.00/0.00, addr 1
uhub3: 1 port with 1 removable, self powered
scsitest0 at mainbus0
scsibus0 at scsitest0: 2 targets, 1 lun per target
cd0 at scsibus0 target 1 lun 0: <RUMPHOBO, It's a LIE, 0.00> cdrom removable
Chicony Electronics Chicony Electronics, class 0/0, rev 2.00/1.00, addr 2, uhub0 port 1 not configured
AuthenTec AuthenTec, class 255/255, rev 1.10/6.21, addr 2, uhub1 port 1 not configured
swwdog0: software watchdog initialized
Kernelized RAIDframe activated
pad0: outputs: 44100Hz, 16-bit, stereo
audio0 at pad0: half duplex, playback, capture


There a bunch of other stuff which doesn't show up as any of the
above, plus of course the usb drivers which are probed only if I
have the appropriate hardware plugged into my workstation.

diffstat:

 distrib/sets/lists/base/mi              |   3 +-
 distrib/sets/lists/comp/mi              |   3 +-
 usr.bin/Makefile                        |   7 +-
 usr.bin/rump_allserver/Makefile         |  17 ++++++++
 usr.bin/rump_allserver/rump_allserver.c |  69 +++++++++++++++++++++++++++++++++
 5 files changed, 94 insertions(+), 5 deletions(-)

diffs (149 lines):

diff -r da55f7168f69 -r e2d9fcb915db distrib/sets/lists/base/mi
--- a/distrib/sets/lists/base/mi        Sun Dec 05 16:53:46 2010 +0000
+++ b/distrib/sets/lists/base/mi        Sun Dec 05 17:37:32 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.893 2010/12/05 09:02:28 mrg Exp $
+# $NetBSD: mi,v 1.894 2010/12/05 17:37:33 pooka Exp $
 #
 # Note:        Don't delete entries from here - mark them as "obsolete" instead,
 #      unless otherwise stated below.
@@ -586,6 +586,7 @@
 ./usr/bin/rpcinfo                              base-rpcutil-bin
 ./usr/bin/rs                                   base-util-bin
 ./usr/bin/rsh                                  base-netutil-bin
+./usr/bin/rump_allserver                       base-util-bin
 ./usr/bin/rup                                  base-netutil-bin
 ./usr/bin/ruptime                              base-netutil-bin
 ./usr/bin/rusers                               base-netutil-bin
diff -r da55f7168f69 -r e2d9fcb915db distrib/sets/lists/comp/mi
--- a/distrib/sets/lists/comp/mi        Sun Dec 05 16:53:46 2010 +0000
+++ b/distrib/sets/lists/comp/mi        Sun Dec 05 17:37:32 2010 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: mi,v 1.1528 2010/12/05 06:02:28 christos Exp $
+#      $NetBSD: mi,v 1.1529 2010/12/05 17:37:33 pooka Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -3308,6 +3308,7 @@
 ./usr/libdata/debug/usr/bin/rpcinfo.debug      comp-rpcutil-debug      debug
 ./usr/libdata/debug/usr/bin/rs.debug           comp-util-debug         debug
 ./usr/libdata/debug/usr/bin/rsh.debug          comp-netutil-debug      debug
+./usr/libdata/debug/usr/bin/rump_allserver.debug               comp-util-debug         debug
 ./usr/libdata/debug/usr/bin/rup.debug          comp-netutil-debug      debug
 ./usr/libdata/debug/usr/bin/ruptime.debug      comp-netutil-debug      debug
 ./usr/libdata/debug/usr/bin/rusers.debug       comp-netutil-debug      debug
diff -r da55f7168f69 -r e2d9fcb915db usr.bin/Makefile
--- a/usr.bin/Makefile  Sun Dec 05 16:53:46 2010 +0000
+++ b/usr.bin/Makefile  Sun Dec 05 17:37:32 2010 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.192 2010/08/27 16:50:10 christos Exp $
+#      $NetBSD: Makefile,v 1.193 2010/12/05 17:37:32 pooka Exp $
 #      from: @(#)Makefile      8.3 (Berkeley) 1/7/94
 
 .include <bsd.own.mk>
@@ -21,8 +21,9 @@
        nbperf netgroup netstat newgrp newsyslog nfsstat nice nl nohup nvi \
        pagesize passwd paste patch pathchk pkill pmap pmc pr \
        printenv printf progress pwhash qsubst quota radioctl rdist \
-       renice rev revoke rfcomm_sppd rlogin rpcgen rpcinfo rs rsh rup \
-       ruptime rusers rwall rwho script sdiff sdpquery sed seq shar shlock \
+       renice rev revoke rfcomm_sppd rlogin rpcgen rpcinfo rs rsh \
+       rump_superserver rup ruptime rusers rwall rwho \
+       script sdiff sdpquery sed seq shar shlock \
        showmount shuffle sockstat soelim sort spell split stat su systat \
        tabs tail talk tcopy tee telnet tftp tic time tip touch tput \
        tr true tset tsort tty ul uname unexpand unifdef \
diff -r da55f7168f69 -r e2d9fcb915db usr.bin/rump_allserver/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/usr.bin/rump_allserver/Makefile   Sun Dec 05 17:37:32 2010 +0000
@@ -0,0 +1,17 @@
+#      $NetBSD: Makefile,v 1.1 2010/12/05 17:37:33 pooka Exp $
+#
+
+PROG=  rump_allserver
+NOMAN= for now
+
+RUMPTOP=${.CURDIR}/../../sys/rump
+
+.include "${RUMPTOP}/dev/Makefile.rumpdevcomp"
+.include "${RUMPTOP}/fs/Makefile.rumpfscomp"
+.include "${RUMPTOP}/kern/Makefile.rumpkerncomp"
+.include "${RUMPTOP}/net/Makefile.rumpnetcomp"
+
+LDADD+=        ${RUMPDEVLDADD} ${RUMPFSLDADD} ${RUMPKERNLDADD} ${RUMPNETLDADD}
+LDADD+= -lrumpcrypto -lrumpdev -lrumpvfs -lrumpnet -lrump -lrumpuser -lpthread
+
+.include <bsd.prog.mk>
diff -r da55f7168f69 -r e2d9fcb915db usr.bin/rump_allserver/rump_allserver.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/usr.bin/rump_allserver/rump_allserver.c   Sun Dec 05 17:37:32 2010 +0000
@@ -0,0 +1,69 @@
+/*     $NetBSD: rump_allserver.c,v 1.1 2010/12/05 17:37:33 pooka Exp $ */
+
+/*-
+ * Copyright (c) 2010 Antti Kantee.  All Rights Reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include <sys/cdefs.h>
+#ifndef lint
+__RCSID("$NetBSD: rump_allserver.c,v 1.1 2010/12/05 17:37:33 pooka Exp $");
+#endif /* !lint */
+
+#include <sys/types.h>
+
+#include <rump/rump.h>
+
+#include <err.h>
+#include <errno.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+
+static void
+usage(void)
+{
+
+       fprintf(stderr, "usage: %s [args] bindurl\n", getprogname());
+       exit(1);
+}
+
+int
+main(int argc, char *argv[])
+{
+       int error;
+
+       setprogname(argv[0]);
+
+       if (argc != 2)
+               usage();
+
+       error = rump_init();
+       if (error)
+               errx(1, "rump init failed: %s", strerror(error));
+       error = rump_init_server(argv[1]);
+       if (error)
+               errx(1, "rump server init failed: %s", strerror(error));
+       pause();
+}



Home | Main Index | Thread Index | Old Index