Source-Changes-HG archive

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

[src/trunk]: src/sys/rump g/c dummyif, not useful these days



details:   https://anonhg.NetBSD.org/src/rev/4b1459076c8d
branches:  trunk
changeset: 787786:4b1459076c8d
user:      pooka <pooka%NetBSD.org@localhost>
date:      Wed Jul 03 15:08:01 2013 +0000

description:
g/c dummyif, not useful these days

diffstat:

 sys/rump/librump/rumpnet/rump_net_private.h |   4 +-
 sys/rump/net/lib/libvirtif/if_virt.c        |  50 +---------------------------
 2 files changed, 3 insertions(+), 51 deletions(-)

diffs (86 lines):

diff -r d8463fc5229a -r 4b1459076c8d sys/rump/librump/rumpnet/rump_net_private.h
--- a/sys/rump/librump/rumpnet/rump_net_private.h       Wed Jul 03 15:06:25 2013 +0000
+++ b/sys/rump/librump/rumpnet/rump_net_private.h       Wed Jul 03 15:08:01 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rump_net_private.h,v 1.6 2013/01/14 16:45:47 pooka Exp $       */
+/*     $NetBSD: rump_net_private.h,v 1.7 2013/07/03 15:08:01 pooka Exp $       */
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -39,8 +39,6 @@
 
 void           rump_net_components(void);
 
-void           rump_dummyif_create(void);
-
 #include "rumpnet_if_priv.h"
 
 #endif /* _SYS_RUMP_NET_PRIVATE_H_ */
diff -r d8463fc5229a -r 4b1459076c8d sys/rump/net/lib/libvirtif/if_virt.c
--- a/sys/rump/net/lib/libvirtif/if_virt.c      Wed Jul 03 15:06:25 2013 +0000
+++ b/sys/rump/net/lib/libvirtif/if_virt.c      Wed Jul 03 15:08:01 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_virt.c,v 1.32 2013/07/03 15:06:25 pooka Exp $       */
+/*     $NetBSD: if_virt.c,v 1.33 2013/07/03 15:08:01 pooka Exp $       */
 
 /*
  * Copyright (c) 2008, 2013 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_virt.c,v 1.32 2013/07/03 15:06:25 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_virt.c,v 1.33 2013/07/03 15:08:01 pooka Exp $");
 
 #include <sys/param.h>
 #include <sys/condvar.h>
@@ -342,49 +342,3 @@
 
        kthread_exit(0);
 }
-
-/*
- * dummyif is a nada-interface.
- * As it requires nothing external, it can be used for testing
- * interface configuration.
- */
-static int     dummyif_init(struct ifnet *);
-static void    dummyif_start(struct ifnet *);
-
-void
-rump_dummyif_create()
-{
-       struct ifnet *ifp;
-       struct ethercom *ec;
-       uint8_t enaddr[ETHER_ADDR_LEN] = { 0xb2, 0x0a, 0x00, 0x0b, 0x0e, 0x01 };
-
-       enaddr[2] = cprng_fast32() & 0xff;
-       enaddr[5] = cprng_fast32() & 0xff;
-
-       ec = kmem_zalloc(sizeof(*ec), KM_SLEEP);
-
-       ifp = &ec->ec_if;
-       strlcpy(ifp->if_xname, "dummy0", sizeof(ifp->if_xname));
-       ifp->if_softc = ifp;
-       ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
-       ifp->if_init = dummyif_init;
-       ifp->if_ioctl = virtif_ioctl;
-       ifp->if_start = dummyif_start;
-
-       if_attach(ifp);
-       ether_ifattach(ifp, enaddr);
-}
-
-static int
-dummyif_init(struct ifnet *ifp)
-{
-
-       ifp->if_flags |= IFF_RUNNING;
-       return 0;
-}
-
-static void
-dummyif_start(struct ifnet *ifp)
-{
-
-}



Home | Main Index | Thread Index | Old Index