CVS commit: src/sys/rump/librump/rumpnet

2022-09-03 Thread Michael van Elst
Module Name:src
Committed By:   mlelstv
Date:   Sat Sep  3 09:41:24 UTC 2022

Modified Files:
src/sys/rump/librump/rumpnet: Makefile.rumpnet

Log Message:
netisr.c is gone.


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/rump/librump/rumpnet/Makefile.rumpnet

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/librump/rumpnet/Makefile.rumpnet
diff -u src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.24 src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.25
--- src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.24	Mon Oct 11 05:13:11 2021
+++ src/sys/rump/librump/rumpnet/Makefile.rumpnet	Sat Sep  3 09:41:24 2022
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.rumpnet,v 1.24 2021/10/11 05:13:11 knakahara Exp $
+#	$NetBSD: Makefile.rumpnet,v 1.25 2022/09/03 09:41:24 mlelstv Exp $
 #
 
 LIB=		rumpnet
@@ -13,7 +13,7 @@ COMMENT=	Rump kernel networking faction
 	${RUMPTOP}/../netipsec	\
 	${RUMPTOP}/../compat/common
 
-SRCS=	net_stub.c netisr.c rump_net.c
+SRCS=	net_stub.c rump_net.c
 
 SRCS+=	rumpnet_if_wrappers.c
 



CVS commit: src/sys/rump/librump/rumpnet

2022-09-03 Thread Michael van Elst
Module Name:src
Committed By:   mlelstv
Date:   Sat Sep  3 09:41:24 UTC 2022

Modified Files:
src/sys/rump/librump/rumpnet: Makefile.rumpnet

Log Message:
netisr.c is gone.


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/rump/librump/rumpnet/Makefile.rumpnet

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2020-09-26 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Sun Sep 27 00:34:44 UTC 2020

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
rump: Add weak alias for bridge_calc_link_state


To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2020-09-26 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Sun Sep 27 00:34:44 UTC 2020

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
rump: Add weak alias for bridge_calc_link_state


To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.39 src/sys/rump/librump/rumpnet/net_stub.c:1.40
--- src/sys/rump/librump/rumpnet/net_stub.c:1.39	Sun Sep 27 00:17:56 2020
+++ src/sys/rump/librump/rumpnet/net_stub.c	Sun Sep 27 00:34:44 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.39 2020/09/27 00:17:56 roy Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.40 2020/09/27 00:34:44 roy Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.39 2020/09/27 00:17:56 roy Exp $");
+__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.40 2020/09/27 00:34:44 roy Exp $");
 
 #include 
 #include 
@@ -64,6 +64,7 @@ rumpnet_stub(void)
 __weak_alias(bridge_ifdetach,rumpnet_stub);
 __weak_alias(bridge_output,rumpnet_stub);
 __weak_alias(bridge_calc_csum_flags,rumpnet_stub);
+__weak_alias(bridge_calc_link_state,rumpnet_stub);
 
 /* agr */
 __weak_alias(agr_input,rumpnet_stub);



CVS commit: src/sys/rump/librump/rumpnet

2020-09-26 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Sun Sep 27 00:17:56 UTC 2020

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
rump: Try to fix build


To generate a diff of this commit:
cvs rdiff -u -r1.38 -r1.39 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.38 src/sys/rump/librump/rumpnet/net_stub.c:1.39
--- src/sys/rump/librump/rumpnet/net_stub.c:1.38	Fri Aug 28 06:20:44 2020
+++ src/sys/rump/librump/rumpnet/net_stub.c	Sun Sep 27 00:17:56 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.38 2020/08/28 06:20:44 ozaki-r Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.39 2020/09/27 00:17:56 roy Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.38 2020/08/28 06:20:44 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.39 2020/09/27 00:17:56 roy Exp $");
 
 #include 
 #include 
@@ -77,6 +77,7 @@ __weak_alias(pppoedisc_input,rumpnet_stu
 /* vlan */
 __weak_alias(vlan_input,rumpnet_stub);
 __weak_alias(vlan_ifdetach,rumpnet_stub);
+__weak_alias(vlan_link_state_changed,rumpnet_stub);
 
 /* ipsec */
 /* FIXME: should modularize netipsec and reduce reverse symbol references */



CVS commit: src/sys/rump/librump/rumpnet

2020-09-26 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Sun Sep 27 00:17:56 UTC 2020

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
rump: Try to fix build


To generate a diff of this commit:
cvs rdiff -u -r1.38 -r1.39 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2018-05-05 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat May  5 23:42:00 UTC 2018

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
add an empty stub


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.33 src/sys/rump/librump/rumpnet/net_stub.c:1.34
--- src/sys/rump/librump/rumpnet/net_stub.c:1.33	Sat Apr 28 10:21:03 2018
+++ src/sys/rump/librump/rumpnet/net_stub.c	Sat May  5 19:42:00 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.33 2018/04/28 14:21:03 maxv Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.34 2018/05/05 23:42:00 christos Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.33 2018/04/28 14:21:03 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.34 2018/05/05 23:42:00 christos Exp $");
 
 #include 
 #include 
@@ -34,6 +34,8 @@ __KERNEL_RCSID(0, "$NetBSD: net_stub.c,v
 #include 
 #include 
 #include 
+#include 
+#include 
 
 #include 
 #include 
@@ -83,6 +85,12 @@ int ipsec_used;
 percpu_t *ipsecstat_percpu;
 u_int ipsec_spdgen;
 
+/* sysctl */
+void
+unp_sysctl_create(struct sysctllog **clog)
+{
+}
+
 __weak_alias(ah4_ctlinput,rumpnet_stub);
 __weak_alias(ah6_ctlinput,rumpnet_stub);
 __weak_alias(esp4_ctlinput,rumpnet_stub);



CVS commit: src/sys/rump/librump/rumpnet

2018-05-05 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat May  5 23:42:00 UTC 2018

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
add an empty stub


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2018-04-12 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Thu Apr 12 21:39:00 UTC 2018

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
remove now unused crap.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2018-04-12 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Thu Apr 12 21:39:00 UTC 2018

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
remove now unused crap.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.31 src/sys/rump/librump/rumpnet/net_stub.c:1.32
--- src/sys/rump/librump/rumpnet/net_stub.c:1.31	Tue Feb 27 10:01:30 2018
+++ src/sys/rump/librump/rumpnet/net_stub.c	Thu Apr 12 17:38:59 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.31 2018/02/27 15:01:30 maxv Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.32 2018/04/12 21:38:59 christos Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.31 2018/02/27 15:01:30 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.32 2018/04/12 21:38:59 christos Exp $");
 
 #include 
 #include 
@@ -109,10 +109,3 @@ __weak_alias(key_sp_unref,rumpnet_stub);
 struct ifnet_head ifnet_list;
 struct pslist_head ifnet_pslist;
 kmutex_t ifnet_mtx;
-
-int
-compat_ifconf(u_long cmd, void *data)
-{
-
-	return EOPNOTSUPP;
-}



Re: CVS commit: src/sys/rump/librump/rumpnet

2018-02-28 Thread maya
On Tue, Feb 27, 2018 at 02:45:43PM +, Maxime Villard wrote:
> Oops, forgot this file; I just merged two IPsec functions, so adapt
> the rump stubs accordingly.
..
>  __weak_alias(esp6_ctlinput,rumpnet_stub);
>  __weak_alias(ipsec4_output,rumpnet_stub);
>  __weak_alias(ipsec4_common_input,rumpnet_stub);
> -__weak_alias(ipsec4_delete_pcbpolicy,rumpnet_stub);
>  __weak_alias(ipsec4_forward,rumpnet_stub);
>  __weak_alias(ipsec4_input,rumpnet_stub);
>  __weak_alias(ipsec4_set_policy,rumpnet_stub);
>  __weak_alias(ipsec6_common_input,rumpnet_stub);
>  __weak_alias(ipsec6_input,rumpnet_stub);
>  __weak_alias(ipsec6_check_policy,rumpnet_stub);
> -__weak_alias(ipsec6_delete_pcbpolicy,rumpnet_stub);
> -__weak_alias(ipsec6_get_policy,rumpnet_stub);
>  __weak_alias(ipsec6_process_packet,rumpnet_stub);
>  __weak_alias(ipsec6_set_policy,rumpnet_stub);
> +__weak_alias(ipsec_get_policy,rumpnet_stub);
> +__weak_alias(ipsec_delete_pcbpolicy,rumpnet_stub);
>  __weak_alias(ipsec_hdrsiz,rumpnet_stub);
>  __weak_alias(ipsec_in_reject,rumpnet_stub);
>  __weak_alias(ipsec_init_policy,rumpnet_stub);
> 

For a normal library I assume this would require a major bump. do we do
this for rump?


CVS commit: src/sys/rump/librump/rumpnet

2018-02-27 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Feb 27 14:45:43 UTC 2018

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Oops, forgot this file; I just merged two IPsec functions, so adapt
the rump stubs accordingly.


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.29 src/sys/rump/librump/rumpnet/net_stub.c:1.30
--- src/sys/rump/librump/rumpnet/net_stub.c:1.29	Mon Feb 26 09:04:29 2018
+++ src/sys/rump/librump/rumpnet/net_stub.c	Tue Feb 27 14:45:43 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.29 2018/02/26 09:04:29 maxv Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.30 2018/02/27 14:45:43 maxv Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.29 2018/02/26 09:04:29 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: net_stub.c,v 1.30 2018/02/27 14:45:43 maxv Exp $");
 
 #include 
 #include 
@@ -89,17 +89,16 @@ __weak_alias(esp4_ctlinput,rumpnet_stub)
 __weak_alias(esp6_ctlinput,rumpnet_stub);
 __weak_alias(ipsec4_output,rumpnet_stub);
 __weak_alias(ipsec4_common_input,rumpnet_stub);
-__weak_alias(ipsec4_delete_pcbpolicy,rumpnet_stub);
 __weak_alias(ipsec4_forward,rumpnet_stub);
 __weak_alias(ipsec4_input,rumpnet_stub);
 __weak_alias(ipsec4_set_policy,rumpnet_stub);
 __weak_alias(ipsec6_common_input,rumpnet_stub);
 __weak_alias(ipsec6_input,rumpnet_stub);
 __weak_alias(ipsec6_check_policy,rumpnet_stub);
-__weak_alias(ipsec6_delete_pcbpolicy,rumpnet_stub);
-__weak_alias(ipsec6_get_policy,rumpnet_stub);
 __weak_alias(ipsec6_process_packet,rumpnet_stub);
 __weak_alias(ipsec6_set_policy,rumpnet_stub);
+__weak_alias(ipsec_get_policy,rumpnet_stub);
+__weak_alias(ipsec_delete_pcbpolicy,rumpnet_stub);
 __weak_alias(ipsec_hdrsiz,rumpnet_stub);
 __weak_alias(ipsec_in_reject,rumpnet_stub);
 __weak_alias(ipsec_init_policy,rumpnet_stub);



CVS commit: src/sys/rump/librump/rumpnet

2018-02-27 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Feb 27 14:45:43 UTC 2018

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Oops, forgot this file; I just merged two IPsec functions, so adapt
the rump stubs accordingly.


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2017-01-16 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Jan 17 02:03:09 UTC 2017

Modified Files:
src/sys/rump/librump/rumpnet: rump_net.c

Log Message:
call pfil_init() here.


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/sys/rump/librump/rumpnet/rump_net.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/librump/rumpnet/rump_net.c
diff -u src/sys/rump/librump/rumpnet/rump_net.c:1.19 src/sys/rump/librump/rumpnet/rump_net.c:1.20
--- src/sys/rump/librump/rumpnet/rump_net.c:1.19	Mon Apr 11 04:56:16 2016
+++ src/sys/rump/librump/rumpnet/rump_net.c	Mon Jan 16 21:03:09 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: rump_net.c,v 1.19 2016/04/11 08:56:16 ozaki-r Exp $	*/
+/*	$NetBSD: rump_net.c,v 1.20 2017/01/17 02:03:09 christos Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: rump_net.c,v 1.19 2016/04/11 08:56:16 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rump_net.c,v 1.20 2017/01/17 02:03:09 christos Exp $");
 
 #include 
 
@@ -35,6 +35,7 @@ __KERNEL_RCSID(0, "$NetBSD: rump_net.c,v
 #include 
 
 #include 
+#include 
 #include 
 
 #include 
@@ -47,6 +48,7 @@ RUMP_COMPONENT(RUMP__FACTION_NET)
 
 	mbinit();
 	soinit();
+	pfil_init();
 
 	domaininit(false);
 



CVS commit: src/sys/rump/librump/rumpnet

2017-01-16 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Jan 17 02:03:09 UTC 2017

Modified Files:
src/sys/rump/librump/rumpnet: rump_net.c

Log Message:
call pfil_init() here.


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/sys/rump/librump/rumpnet/rump_net.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet/opt

2015-01-18 Thread Justin Cormack
Module Name:src
Committed By:   justin
Date:   Sun Jan 18 17:33:08 UTC 2015

Modified Files:
src/sys/rump/librump/rumpnet/opt: opt_inet.h

Log Message:
Revert removal of opt_inet.h as many cases may still require it


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/rump/librump/rumpnet/opt/opt_inet.h

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/librump/rumpnet/opt/opt_inet.h
diff -u src/sys/rump/librump/rumpnet/opt/opt_inet.h:1.3 src/sys/rump/librump/rumpnet/opt/opt_inet.h:1.4
--- src/sys/rump/librump/rumpnet/opt/opt_inet.h:1.3	Sun Jan 18 17:06:24 2015
+++ src/sys/rump/librump/rumpnet/opt/opt_inet.h	Sun Jan 18 17:33:08 2015
@@ -1 +1,4 @@
-/*	$NetBSD: opt_inet.h,v 1.3 2015/01/18 17:06:24 justin Exp $	*/
+/*	$NetBSD: opt_inet.h,v 1.4 2015/01/18 17:33:08 justin Exp $	*/
+
+#define INET  1
+#define INET6 1



CVS commit: src/sys/rump/librump/rumpnet/opt

2015-01-18 Thread Justin Cormack
Module Name:src
Committed By:   justin
Date:   Sun Jan 18 17:33:08 UTC 2015

Modified Files:
src/sys/rump/librump/rumpnet/opt: opt_inet.h

Log Message:
Revert removal of opt_inet.h as many cases may still require it


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/rump/librump/rumpnet/opt/opt_inet.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2014-12-02 Thread Ryota Ozaki
Module Name:src
Committed By:   ozaki-r
Date:   Tue Dec  2 14:34:19 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Get rid of weak_alias for bridge_input

bridge_input is now not directly called from ether_input,
so we can remove weak_alias for it.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.20 src/sys/rump/librump/rumpnet/net_stub.c:1.21
--- src/sys/rump/librump/rumpnet/net_stub.c:1.20	Tue Dec  2 04:43:35 2014
+++ src/sys/rump/librump/rumpnet/net_stub.c	Tue Dec  2 14:34:19 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.20 2014/12/02 04:43:35 ozaki-r Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.21 2014/12/02 14:34:19 ozaki-r Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.20 2014/12/02 04:43:35 ozaki-r Exp $);
+__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.21 2014/12/02 14:34:19 ozaki-r Exp $);
 
 #include sys/param.h
 #include sys/protosw.h
@@ -54,7 +54,6 @@ rumpnet_stub(void)
 /* bridge */
 __weak_alias(bridge_ifdetach,rumpnet_stub);
 __weak_alias(bridge_output,rumpnet_stub);
-__weak_alias(bridge_input,rumpnet_stub);
 
 /* agr */
 __weak_alias(agr_input,rumpnet_stub);



CVS commit: src/sys/rump/librump/rumpnet

2014-12-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Dec  3 00:19:04 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: Makefile.rumpnet

Log Message:
add printers.


To generate a diff of this commit:
cvs rdiff -u -r1.16 -r1.17 src/sys/rump/librump/rumpnet/Makefile.rumpnet

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/librump/rumpnet/Makefile.rumpnet
diff -u src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.16 src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.17
--- src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.16	Mon Dec  1 20:59:16 2014
+++ src/sys/rump/librump/rumpnet/Makefile.rumpnet	Tue Dec  2 19:19:04 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.rumpnet,v 1.16 2014/12/02 01:59:16 pooka Exp $
+#	$NetBSD: Makefile.rumpnet,v 1.17 2014/12/03 00:19:04 christos Exp $
 #
 
 LIB=		rumpnet
@@ -6,6 +6,9 @@ LIB=		rumpnet
 .PATH:	${RUMPTOP}/librump/rumpnet\
 	${RUMPTOP}/../kern	\
 	${RUMPTOP}/../net	\
+	${RUMPTOP}/../netatalk	\
+	${RUMPTOP}/../netinet	\
+	${RUMPTOP}/../netinet6	\
 	${RUMPTOP}/../compat/common
 
 SRCS=	net_stub.c netisr.c rump_net.c
@@ -21,6 +24,9 @@ SRCS+=	sys_socket.c uipc_accf.c uipc_dom
 # sys/net
 SRCS+=	pktqueue.c
 
+# formatters
+SRCS+= at_print.c dl_print.c in_print.c in6_print.c
+
 # radix trie support
 SRCS+=	radix.c
 SRCS+=	rtbl.c



CVS commit: src/sys/rump/librump/rumpnet

2014-12-02 Thread Ryota Ozaki
Module Name:src
Committed By:   ozaki-r
Date:   Tue Dec  2 14:34:19 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Get rid of weak_alias for bridge_input

bridge_input is now not directly called from ether_input,
so we can remove weak_alias for it.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2014-12-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Dec  3 00:19:04 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: Makefile.rumpnet

Log Message:
add printers.


To generate a diff of this commit:
cvs rdiff -u -r1.16 -r1.17 src/sys/rump/librump/rumpnet/Makefile.rumpnet

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



re: CVS commit: src/sys/rump/librump/rumpnet

2014-05-18 Thread matthew green

Mindaugas Rasiukevicius writes:
 Module Name:  src
 Committed By: rmind
 Date: Sun May 18 14:03:26 UTC 2014
 
 Modified Files:
   src/sys/rump/librump/rumpnet: net_stub.c
 
 Log Message:
 Fix RUMP build.

please describe the change itself, not the objective.


.mrg.


CVS commit: src/sys/rump/librump/rumpnet

2014-05-18 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Sun May 18 14:03:26 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Fix RUMP build.


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.17 src/sys/rump/librump/rumpnet/net_stub.c:1.18
--- src/sys/rump/librump/rumpnet/net_stub.c:1.17	Sat Apr 26 11:23:56 2014
+++ src/sys/rump/librump/rumpnet/net_stub.c	Sun May 18 14:03:26 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.17 2014/04/26 11:23:56 pooka Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.18 2014/05/18 14:03:26 rmind Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.17 2014/04/26 11:23:56 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.18 2014/05/18 14:03:26 rmind Exp $);
 
 #include sys/param.h
 #include sys/protosw.h
@@ -61,7 +61,7 @@ __weak_alias(agr_input,rumpnet_stub);
 __weak_alias(ieee8023ad_lacp_input,rumpnet_stub);
 __weak_alias(ieee8023ad_marker_input,rumpnet_stub);
 
-struct ifnet_head ifnet;
+struct ifnet_head ifnet_list;
 
 int
 compat_ifconf(u_long cmd, void *data)



CVS commit: src/sys/rump/librump/rumpnet

2014-05-18 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Sun May 18 14:03:26 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Fix RUMP build.


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2014-04-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Sat Apr 26 11:23:56 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
don't invade the __toolchain namespace


To generate a diff of this commit:
cvs rdiff -u -r1.16 -r1.17 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.16 src/sys/rump/librump/rumpnet/net_stub.c:1.17
--- src/sys/rump/librump/rumpnet/net_stub.c:1.16	Sat Apr 26 11:23:03 2014
+++ src/sys/rump/librump/rumpnet/net_stub.c	Sat Apr 26 11:23:56 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.16 2014/04/26 11:23:03 pooka Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.17 2014/04/26 11:23:56 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.16 2014/04/26 11:23:03 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.17 2014/04/26 11:23:56 pooka Exp $);
 
 #include sys/param.h
 #include sys/protosw.h
@@ -38,9 +38,9 @@ __KERNEL_RCSID(0, $NetBSD: net_stub.c,v
 #include compat/sys/socket.h
 #include compat/sys/sockio.h
 
-int __rumpnet_stub(void);
+int rumpnet_stub(void);
 int
-__rumpnet_stub(void)
+rumpnet_stub(void)
 {
 
 	panic(component not available);
@@ -52,14 +52,14 @@ __rumpnet_stub(void)
  */
 
 /* bridge */
-__weak_alias(bridge_ifdetach,__rumpnet_stub);
-__weak_alias(bridge_output,__rumpnet_stub);
-__weak_alias(bridge_input,__rumpnet_stub);
+__weak_alias(bridge_ifdetach,rumpnet_stub);
+__weak_alias(bridge_output,rumpnet_stub);
+__weak_alias(bridge_input,rumpnet_stub);
 
 /* agr */
-__weak_alias(agr_input,__rumpnet_stub);
-__weak_alias(ieee8023ad_lacp_input,__rumpnet_stub);
-__weak_alias(ieee8023ad_marker_input,__rumpnet_stub);
+__weak_alias(agr_input,rumpnet_stub);
+__weak_alias(ieee8023ad_lacp_input,rumpnet_stub);
+__weak_alias(ieee8023ad_marker_input,rumpnet_stub);
 
 struct ifnet_head ifnet;
 



CVS commit: src/sys/rump/librump/rumpnet

2014-02-25 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Tue Feb 25 22:40:53 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: netisr.c

Log Message:
Schedule only those netisr's that have registered handlers.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/rump/librump/rumpnet/netisr.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/librump/rumpnet/netisr.c
diff -u src/sys/rump/librump/rumpnet/netisr.c:1.7 src/sys/rump/librump/rumpnet/netisr.c:1.8
--- src/sys/rump/librump/rumpnet/netisr.c:1.7	Fri Feb 14 01:43:13 2014
+++ src/sys/rump/librump/rumpnet/netisr.c	Tue Feb 25 22:40:53 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: netisr.c,v 1.7 2014/02/14 01:43:13 pooka Exp $	*/
+/*	$NetBSD: netisr.c,v 1.8 2014/02/25 22:40:53 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: netisr.c,v 1.7 2014/02/14 01:43:13 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: netisr.c,v 1.8 2014/02/25 22:40:53 pooka Exp $);
 
 #include sys/param.h
 #include sys/intr.h
@@ -42,7 +42,14 @@ void
 schednetisr(int isr)
 {
 
-	softint_schedule(netisrs[isr]);
+	/*
+	 * Do not schedule a softint that is not registered.
+	 * This might cause the inq to fill, but the one calling us
+	 * should start dropping packets once the inq is full,
+	 * so no big harm done.
+	 */
+	if (__predict_true(netisrs[isr]))
+		softint_schedule(netisrs[isr]);
 }
 
 void



CVS commit: src/sys/rump/librump/rumpnet

2014-02-25 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Tue Feb 25 22:40:53 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: netisr.c

Log Message:
Schedule only those netisr's that have registered handlers.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/rump/librump/rumpnet/netisr.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2014-02-13 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Feb 14 01:27:48 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: rump_net_private.h

Log Message:
g/c prototype of imaginary routine


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/rump/librump/rumpnet/rump_net_private.h

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/librump/rumpnet/rump_net_private.h
diff -u src/sys/rump/librump/rumpnet/rump_net_private.h:1.7 src/sys/rump/librump/rumpnet/rump_net_private.h:1.8
--- src/sys/rump/librump/rumpnet/rump_net_private.h:1.7	Wed Jul  3 15:08:01 2013
+++ src/sys/rump/librump/rumpnet/rump_net_private.h	Fri Feb 14 01:27:48 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: rump_net_private.h,v 1.7 2013/07/03 15:08:01 pooka Exp $	*/
+/*	$NetBSD: rump_net_private.h,v 1.8 2014/02/14 01:27:48 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -37,8 +37,6 @@ do {	\
 }\
 } while (/*CONSTCOND*/0)
 
-void		rump_net_components(void);
-
 #include rumpnet_if_priv.h
 
 #endif /* _SYS_RUMP_NET_PRIVATE_H_ */



CVS commit: src/sys/rump/librump/rumpnet

2014-02-13 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Feb 14 01:27:48 UTC 2014

Modified Files:
src/sys/rump/librump/rumpnet: rump_net_private.h

Log Message:
g/c prototype of imaginary routine


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/rump/librump/rumpnet/rump_net_private.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2013-06-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Jun 26 17:10:23 UTC 2013

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Remove the route_info weak alias.  It's unnecessary since 2011
and confused Linux ld.so, thus preventing dlopen() of librumpnet.
Reported in private email by Justin Cormack.

Also, g/c a few other stubs which are no longer necessary.


To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.13 src/sys/rump/librump/rumpnet/net_stub.c:1.14
--- src/sys/rump/librump/rumpnet/net_stub.c:1.13	Sun Aug  5 15:36:19 2012
+++ src/sys/rump/librump/rumpnet/net_stub.c	Wed Jun 26 17:10:23 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.13 2012/08/05 15:36:19 pooka Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.14 2013/06/26 17:10:23 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.13 2012/08/05 15:36:19 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.14 2013/06/26 17:10:23 pooka Exp $);
 
 #include sys/param.h
 #include sys/protosw.h
@@ -46,14 +46,10 @@ __rumpnet_stub(void)
 	panic(component not available);
 }
 __weak_alias(rtioctl,__rumpnet_stub);
-__weak_alias(rt_walktree,__rumpnet_stub);
 __weak_alias(rtrequest,__rumpnet_stub);
 __weak_alias(ifioctl,__rumpnet_stub);
 __weak_alias(ifunit,__rumpnet_stub);
 __weak_alias(ifreq_setaddr,__rumpnet_stub);
-__weak_alias(rt_msg1,__rumpnet_stub);
-__weak_alias(route_enqueue,__rumpnet_stub);
-__weak_alias(route_info,__rumpnet_stub);
 
 /*
  * Weak symbols so that we can optionally leave components out.



CVS commit: src/sys/rump/librump/rumpnet

2013-06-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Jun 26 17:10:23 UTC 2013

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Remove the route_info weak alias.  It's unnecessary since 2011
and confused Linux ld.so, thus preventing dlopen() of librumpnet.
Reported in private email by Justin Cormack.

Also, g/c a few other stubs which are no longer necessary.


To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2013-01-14 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Mon Jan 14 16:48:08 UTC 2013

Modified Files:
src/sys/rump/librump/rumpnet: rump_net.c

Log Message:
Set networking soft interrupt vectors earlier, just in case interface
component initialization causes network traffic to be received.


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 src/sys/rump/librump/rumpnet/rump_net.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/librump/rumpnet/rump_net.c
diff -u src/sys/rump/librump/rumpnet/rump_net.c:1.14 src/sys/rump/librump/rumpnet/rump_net.c:1.15
--- src/sys/rump/librump/rumpnet/rump_net.c:1.14	Mon Jan 14 16:45:47 2013
+++ src/sys/rump/librump/rumpnet/rump_net.c	Mon Jan 14 16:48:08 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: rump_net.c,v 1.14 2013/01/14 16:45:47 pooka Exp $	*/
+/*	$NetBSD: rump_net.c,v 1.15 2013/01/14 16:48:08 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rump_net.c,v 1.14 2013/01/14 16:45:47 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: rump_net.c,v 1.15 2013/01/14 16:48:08 pooka Exp $);
 
 #include sys/param.h
 
@@ -54,12 +54,11 @@ RUMP_COMPONENT(RUMP__FACTION_NET)
 	soinit();
 
 	domaininit(false);
+	rump_netisr_init();
 
 	rump_component_init(RUMP_COMPONENT_NET);
 	rump_component_init(RUMP_COMPONENT_NET_ROUTE);
 	rump_component_init(RUMP_COMPONENT_NET_IF);
 	rump_component_init(RUMP_COMPONENT_NET_IFCFG);
 	rump_net_components();
-
-	rump_netisr_init();
 }



CVS commit: src/sys/rump/librump/rumpnet

2013-01-14 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Mon Jan 14 16:48:08 UTC 2013

Modified Files:
src/sys/rump/librump/rumpnet: rump_net.c

Log Message:
Set networking soft interrupt vectors earlier, just in case interface
component initialization causes network traffic to be received.


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 src/sys/rump/librump/rumpnet/rump_net.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2012-08-05 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Sun Aug  5 15:36:19 UTC 2012

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Remove stubs which have been provided elsewhere for almost 2 years now.


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.12 src/sys/rump/librump/rumpnet/net_stub.c:1.13
--- src/sys/rump/librump/rumpnet/net_stub.c:1.12	Tue Feb  1 01:39:21 2011
+++ src/sys/rump/librump/rumpnet/net_stub.c	Sun Aug  5 15:36:19 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.12 2011/02/01 01:39:21 matt Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.13 2012/08/05 15:36:19 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.12 2011/02/01 01:39:21 matt Exp $);
+__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.13 2012/08/05 15:36:19 pooka Exp $);
 
 #include sys/param.h
 #include sys/protosw.h
@@ -72,30 +72,9 @@ __weak_alias(ieee8023ad_marker_input,__r
 
 struct ifnet_head ifnet;
 
-u_long
-compat_cvtcmd(u_long cmd)
-{
-
-	return cmd;
-}
-
 int
 compat_ifconf(u_long cmd, void *data)
 {
 
 	return EOPNOTSUPP;
 }
-
-int
-compat_ifioctl(struct socket *so, u_long ocmd, u_long cmd, void *data,
-	struct lwp *l)
-{
-	struct ifreq *ifr = data;
-	struct ifnet *ifp = ifunit(ifr-ifr_name);
-
-	if (!ifp)
-		return ENXIO;
-
-	return (*so-so_proto-pr_usrreq)(so, PRU_CONTROL,
-	(struct mbuf *)cmd, (struct mbuf *)data, (struct mbuf *)ifp, l);
-}



CVS commit: src/sys/rump/librump/rumpnet

2012-08-05 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Sun Aug  5 15:36:19 UTC 2012

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Remove stubs which have been provided elsewhere for almost 2 years now.


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 16:19:39 UTC 2010

Modified Files:
src/sys/rump/librump/rumpnet: netisr.c

Log Message:
Refetch netisr function pointers with dlsym().  This gives the
desired values in case the components containing the netisr handlers
were not linked in but dlopen()'d before calling rump_init().

(could simplify a little in case static linking is declared dead)


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/rump/librump/rumpnet/netisr.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/librump/rumpnet/netisr.c
diff -u src/sys/rump/librump/rumpnet/netisr.c:1.4 src/sys/rump/librump/rumpnet/netisr.c:1.5
--- src/sys/rump/librump/rumpnet/netisr.c:1.4	Tue May 26 23:43:39 2009
+++ src/sys/rump/librump/rumpnet/netisr.c	Thu Dec 30 16:19:39 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: netisr.c,v 1.4 2009/05/26 23:43:39 pooka Exp $	*/
+/*	$NetBSD: netisr.c,v 1.5 2010/12/30 16:19:39 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: netisr.c,v 1.4 2009/05/26 23:43:39 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: netisr.c,v 1.5 2010/12/30 16:19:39 pooka Exp $);
 
 #include sys/param.h
 #include sys/intr.h
@@ -38,6 +38,8 @@
 #include netinet6/ip6_var.h
 #include net/netisr.h
 
+#include rump/rumpuser.h
+
 #include rump_net_private.h
 
 static void *netisrs[NETISR_MAX];
@@ -49,44 +51,40 @@
 }
 
 /*
- * Provide weak aliases purely for linkage in case the real
- * networking stack isn't used
+ * Aliases are needed only for static linking (dlsym() is not supported).
  */
-void __ipintr_stub(void);
-void
-__ipintr_stub(void)
-{
-
-	panic(ipintr called but networking stack missing);
-}
-__weak_alias(ipintr,__ipintr_stub);
-
-void __arpintr_stub(void);
-void
-__arpintr_stub(void)
-{
-
-	panic(arpintr called but networking stack missing);
-}
-__weak_alias(arpintr,__arpintr_stub);
-
-void __ip6intr_stub(void);
+void __netisr_stub(void);
 void
-__ip6intr_stub(void)
+__netisr_stub(void)
 {
 
-	panic(ip6intr called but networking stack missing);
+	panic(netisr called but networking stack missing);
 }
-__weak_alias(ip6intr,__ip6intr_stub);
+__weak_alias(ipintr,__netisr_stub);
+__weak_alias(arpintr,__netisr_stub);
+__weak_alias(ip6intr,__netisr_stub);
 
 void
 rump_netisr_init(void)
 {
+	void *iphand, *arphand, *ip6hand, *sym;
 
+	iphand = ipintr;
+	if ((sym = rumpuser_dl_globalsym(rumpns_ipintr)) != NULL)
+		iphand = sym;
+
+	arphand = arpintr;
+	if ((sym = rumpuser_dl_globalsym(rumpns_arpintr)) != NULL)
+		arphand = sym;
+
+	ip6hand = ip6intr;
+	if ((sym = rumpuser_dl_globalsym(rumpns_ip6intr)) != NULL)
+		ip6hand = sym;
+		
 	netisrs[NETISR_IP] = softint_establish(SOFTINT_NET | SOFTINT_MPSAFE,
-	(void (*)(void *))ipintr, NULL);
+	(void (*)(void *))iphand, NULL);
 	netisrs[NETISR_ARP] = softint_establish(SOFTINT_NET | SOFTINT_MPSAFE,
-	(void (*)(void *))arpintr, NULL);
+	(void (*)(void *))arphand, NULL);
 	netisrs[NETISR_IPV6] = softint_establish(SOFTINT_NET | SOFTINT_MPSAFE,
-	(void (*)(void *))ip6intr, NULL);
+	(void (*)(void *))ip6hand, NULL);
 }



CVS commit: src/sys/rump/librump/rumpnet

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 16:19:39 UTC 2010

Modified Files:
src/sys/rump/librump/rumpnet: netisr.c

Log Message:
Refetch netisr function pointers with dlsym().  This gives the
desired values in case the components containing the netisr handlers
were not linked in but dlopen()'d before calling rump_init().

(could simplify a little in case static linking is declared dead)


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/rump/librump/rumpnet/netisr.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2010-12-08 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Dec  8 18:06:59 UTC 2010

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
add weak stubs for bridge (not the game)


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.9 src/sys/rump/librump/rumpnet/net_stub.c:1.10
--- src/sys/rump/librump/rumpnet/net_stub.c:1.9	Wed Dec  8 01:22:55 2010
+++ src/sys/rump/librump/rumpnet/net_stub.c	Wed Dec  8 18:06:58 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.9 2010/12/08 01:22:55 joerg Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.10 2010/12/08 18:06:58 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.9 2010/12/08 01:22:55 joerg Exp $);
+__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.10 2010/12/08 18:06:58 pooka Exp $);
 
 #include sys/param.h
 #include sys/protosw.h
@@ -43,7 +43,7 @@
 __rumpnet_stub(void)
 {
 
-	panic(rumpnet stubs only, linking against librumpnet_net required);
+	panic(component not available);
 }
 __weak_alias(rtioctl,__rumpnet_stub);
 __weak_alias(rt_walktree,__rumpnet_stub);
@@ -55,6 +55,16 @@
 __weak_alias(route_enqueue,__rumpnet_stub);
 __weak_alias(route_cb,__rumpnet_stub);
 
+/*
+ * Weak symbols so that we can optionally leave components out.
+ * (would be better to fix sys/net* to be more modular, though)
+ */
+
+/* bridge */
+__weak_alias(bridge_ifdetach,__rumpnet_stub);
+__weak_alias(bridge_output,__rumpnet_stub);
+__weak_alias(bridge_input,__rumpnet_stub);
+
 struct ifnet_head ifnet;
 
 u_long



CVS commit: src/sys/rump/librump/rumpnet

2010-12-08 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Dec  8 20:20:52 UTC 2010

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
weak stubs for agr(4)


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.10 src/sys/rump/librump/rumpnet/net_stub.c:1.11
--- src/sys/rump/librump/rumpnet/net_stub.c:1.10	Wed Dec  8 18:06:58 2010
+++ src/sys/rump/librump/rumpnet/net_stub.c	Wed Dec  8 20:20:52 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.10 2010/12/08 18:06:58 pooka Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.11 2010/12/08 20:20:52 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.10 2010/12/08 18:06:58 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.11 2010/12/08 20:20:52 pooka Exp $);
 
 #include sys/param.h
 #include sys/protosw.h
@@ -65,6 +65,11 @@
 __weak_alias(bridge_output,__rumpnet_stub);
 __weak_alias(bridge_input,__rumpnet_stub);
 
+/* agr */
+__weak_alias(agr_input,__rumpnet_stub);
+__weak_alias(ieee8023ad_lacp_input,__rumpnet_stub);
+__weak_alias(ieee8023ad_marker_input,__rumpnet_stub);
+
 struct ifnet_head ifnet;
 
 u_long



CVS commit: src/sys/rump/librump/rumpnet

2010-12-07 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Wed Dec  8 01:22:55 UTC 2010

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Don't alias the same symbol twice.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/rump/librump/rumpnet/net_stub.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/librump/rumpnet/net_stub.c
diff -u src/sys/rump/librump/rumpnet/net_stub.c:1.8 src/sys/rump/librump/rumpnet/net_stub.c:1.9
--- src/sys/rump/librump/rumpnet/net_stub.c:1.8	Fri Jan 23 21:57:35 2009
+++ src/sys/rump/librump/rumpnet/net_stub.c	Wed Dec  8 01:22:55 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: net_stub.c,v 1.8 2009/01/23 21:57:35 pooka Exp $	*/
+/*	$NetBSD: net_stub.c,v 1.9 2010/12/08 01:22:55 joerg Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.8 2009/01/23 21:57:35 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: net_stub.c,v 1.9 2010/12/08 01:22:55 joerg Exp $);
 
 #include sys/param.h
 #include sys/protosw.h
@@ -48,7 +48,6 @@
 __weak_alias(rtioctl,__rumpnet_stub);
 __weak_alias(rt_walktree,__rumpnet_stub);
 __weak_alias(rtrequest,__rumpnet_stub);
-__weak_alias(rtrequest,__rumpnet_stub);
 __weak_alias(ifioctl,__rumpnet_stub);
 __weak_alias(ifunit,__rumpnet_stub);
 __weak_alias(ifreq_setaddr,__rumpnet_stub);



CVS commit: src/sys/rump/librump/rumpnet

2010-12-07 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Wed Dec  8 01:22:55 UTC 2010

Modified Files:
src/sys/rump/librump/rumpnet: net_stub.c

Log Message:
Don't alias the same symbol twice.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/rump/librump/rumpnet/net_stub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/rump/librump/rumpnet

2009-10-20 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Tue Oct 20 23:28:50 UTC 2009

Modified Files:
src/sys/rump/librump/rumpnet: rumpnet.ifspec

Log Message:
add shmif_create


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/rump/librump/rumpnet/rumpnet.ifspec

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/librump/rumpnet/rumpnet.ifspec
diff -u src/sys/rump/librump/rumpnet/rumpnet.ifspec:1.1 src/sys/rump/librump/rumpnet/rumpnet.ifspec:1.2
--- src/sys/rump/librump/rumpnet/rumpnet.ifspec:1.1	Wed Oct 14 17:17:00 2009
+++ src/sys/rump/librump/rumpnet/rumpnet.ifspec	Tue Oct 20 23:28:50 2009
@@ -1,11 +1,12 @@
-;   $NetBSD: rumpnet.ifspec,v 1.1 2009/10/14 17:17:00 pooka Exp $
+;   $NetBSD: rumpnet.ifspec,v 1.2 2009/10/20 23:28:50 pooka Exp $
 
 NAME|net
 PUBHDR|include/rump/rumpnet_if_pub.h
 PRIVHDR|librump/rumpnet/rumpnet_if_priv.h
 WRAPPERS|librump/rumpnet/rumpnet_if_wrappers.c
 
-; type  | name  | args		| attrs
+; type  | name  | args			| attrs
 ;
 
-int		|virtif_create	|int		|WEAK
+int		|virtif_create	|int			|WEAK
+int		|shmif_create	|const char *, int *	|WEAK



CVS commit: src/sys/rump/librump/rumpnet

2009-10-15 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Oct 16 00:16:32 UTC 2009

Modified Files:
src/sys/rump/librump/rumpnet: Makefile.rumpnet
Removed Files:
src/sys/rump/librump/rumpnet: net_emul.c

Log Message:
We have real pollsuck() now, so remove this, ahem, less-than-perfect one.
(XXX: only thing in the kernel using pollsuck is netsmb)


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/rump/librump/rumpnet/Makefile.rumpnet
cvs rdiff -u -r1.1 -r0 src/sys/rump/librump/rumpnet/net_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/librump/rumpnet/Makefile.rumpnet
diff -u src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.8 src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.9
--- src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.8	Wed Oct 14 17:29:20 2009
+++ src/sys/rump/librump/rumpnet/Makefile.rumpnet	Fri Oct 16 00:16:32 2009
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.rumpnet,v 1.8 2009/10/14 17:29:20 pooka Exp $
+#	$NetBSD: Makefile.rumpnet,v 1.9 2009/10/16 00:16:32 pooka Exp $
 #
 
 .include ${RUMPTOP}/Makefile.rump
@@ -10,7 +10,7 @@
 	${RUMPTOP}/../net	\
 	${RUMPTOP}/../compat/common
 
-SRCS=	net_stub.c netisr.c rump_net.c net_emul.c
+SRCS=	net_stub.c netisr.c rump_net.c
 
 SRCS+=	rumpnet_if_wrappers.c
 



CVS commit: src/sys/rump/librump/rumpnet

2009-10-04 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Sun Oct  4 13:24:58 UTC 2009

Modified Files:
src/sys/rump/librump/rumpnet: rump_net.c

Log Message:
Initialize suckets before domains since some domains install timers
which take softnet_lock and might run before the lock is actually
initialized.  Also, soinit() itself already calls soinit2(), so no
need to call it twice.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/sys/rump/librump/rumpnet/rump_net.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/librump/rumpnet/rump_net.c
diff -u src/sys/rump/librump/rumpnet/rump_net.c:1.9 src/sys/rump/librump/rumpnet/rump_net.c:1.10
--- src/sys/rump/librump/rumpnet/rump_net.c:1.9	Wed Sep 16 13:30:41 2009
+++ src/sys/rump/librump/rumpnet/rump_net.c	Sun Oct  4 13:24:58 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: rump_net.c,v 1.9 2009/09/16 13:30:41 pooka Exp $	*/
+/*	$NetBSD: rump_net.c,v 1.10 2009/10/04 13:24:58 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rump_net.c,v 1.9 2009/09/16 13:30:41 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: rump_net.c,v 1.10 2009/10/04 13:24:58 pooka Exp $);
 
 #include sys/param.h
 
@@ -52,6 +52,7 @@
 {
 
 	mbinit();
+	soinit();
 
 	domaininit(false);
 	/*
@@ -66,8 +67,5 @@
 
 	rump_net_virtif_init();
 
-	soinit();
-	soinit2();
-
 	rump_netisr_init();
 }



CVS commit: src/sys/rump/librump/rumpnet

2009-09-16 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Sep 16 13:30:41 UTC 2009

Modified Files:
src/sys/rump/librump/rumpnet: rump_net.c

Log Message:
create interfaces only after ifnef is initialized


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/rump/librump/rumpnet/rump_net.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/librump/rumpnet/rump_net.c
diff -u src/sys/rump/librump/rumpnet/rump_net.c:1.8 src/sys/rump/librump/rumpnet/rump_net.c:1.9
--- src/sys/rump/librump/rumpnet/rump_net.c:1.8	Thu May 28 00:02:16 2009
+++ src/sys/rump/librump/rumpnet/rump_net.c	Wed Sep 16 13:30:41 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: rump_net.c,v 1.8 2009/05/28 00:02:16 pooka Exp $	*/
+/*	$NetBSD: rump_net.c,v 1.9 2009/09/16 13:30:41 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rump_net.c,v 1.8 2009/05/28 00:02:16 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: rump_net.c,v 1.9 2009/09/16 13:30:41 pooka Exp $);
 
 #include sys/param.h
 
@@ -61,10 +61,11 @@
 	rump_net_inet_init();
 	rump_net_local_init();
 	rump_net_sockin_init();
-	rump_net_virtif_init();
-	/* Note: should be last due to calling of rn_init() */
+	/* Note: should be last _domain_ due to calling of rn_init() */
 	rump_net_net_init();
 
+	rump_net_virtif_init();
+
 	soinit();
 	soinit2();
 



CVS commit: src/sys/rump/librump/rumpnet

2009-09-06 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Sun Sep  6 20:02:49 UTC 2009

Modified Files:
src/sys/rump/librump/rumpnet: Makefile.rumpnet
Added Files:
src/sys/rump/librump/rumpnet: net_emul.c

Log Message:
add a very simple version of pollsock()
XXX: it seems to exist purely for the pleasure of netsmb??


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/rump/librump/rumpnet/Makefile.rumpnet
cvs rdiff -u -r0 -r1.1 src/sys/rump/librump/rumpnet/net_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/librump/rumpnet/Makefile.rumpnet
diff -u src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.6 src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.7
--- src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.6	Wed Jun 10 20:54:55 2009
+++ src/sys/rump/librump/rumpnet/Makefile.rumpnet	Sun Sep  6 20:02:49 2009
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.rumpnet,v 1.6 2009/06/10 20:54:55 pooka Exp $
+#	$NetBSD: Makefile.rumpnet,v 1.7 2009/09/06 20:02:49 pooka Exp $
 #
 
 .include ${RUMPTOP}/Makefile.rump
@@ -10,7 +10,7 @@
 	${RUMPTOP}/../net	\
 	${RUMPTOP}/../compat/common
 
-SRCS=	net_stub.c netisr.c rump_net.c
+SRCS=	net_stub.c netisr.c rump_net.c net_emul.c
 
 # sys/kern networking (sockets, mbufs, etc.)
 SRCS+=	sys_socket.c uipc_accf.c uipc_domain.c uipc_mbuf.c uipc_mbuf2.c	\

Added files:

Index: src/sys/rump/librump/rumpnet/net_emul.c
diff -u /dev/null src/sys/rump/librump/rumpnet/net_emul.c:1.1
--- /dev/null	Sun Sep  6 20:02:50 2009
+++ src/sys/rump/librump/rumpnet/net_emul.c	Sun Sep  6 20:02:49 2009
@@ -0,0 +1,66 @@
+/*	$NetBSD: net_emul.c,v 1.1 2009/09/06 20:02:49 pooka Exp $	*/
+
+/*
+ * Copyright (c) 2009 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
+__KERNEL_RCSID(0, $NetBSD: net_emul.c,v 1.1 2009/09/06 20:02:49 pooka Exp $);
+
+#include sys/param.h
+#include sys/kernel.h
+#include sys/proc.h
+#include sys/socket.h
+#include sys/socketvar.h
+#include sys/time.h
+
+/*
+ * A very simplistic (and polling ;) implementation of pollsock().
+ * Hopefully I'll soon be able to run sys_select.c
+ */
+
+int
+pollsock(struct socket *so, const struct timespec *tsp, int events)
+{
+	struct timespec ts, sts;
+
+	if (tsp) {
+		ts = *tsp;
+		if (inittimeleft(ts, sts) == -1)
+			return EINVAL;
+	}
+
+	for (;;) {
+		if (tsp) {
+			if (gettimeleft(ts, sts)  0) {
+break;
+			}
+		}
+		if (sopoll(so, events) != 0)
+			break;
+		kpause(lol, false, hz/10, 0);
+	}
+
+	return 0;
+}



CVS commit: src/sys/rump/librump/rumpnet

2009-06-10 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Jun 10 20:54:55 UTC 2009

Modified Files:
src/sys/rump/librump/rumpnet: Makefile.rumpnet

Log Message:
MAXUSERS comes from Makefile.rump


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/sys/rump/librump/rumpnet/Makefile.rumpnet

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/librump/rumpnet/Makefile.rumpnet
diff -u src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.5 src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.6
--- src/sys/rump/librump/rumpnet/Makefile.rumpnet:1.5	Wed Jun 10 20:50:51 2009
+++ src/sys/rump/librump/rumpnet/Makefile.rumpnet	Wed Jun 10 20:54:55 2009
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.rumpnet,v 1.5 2009/06/10 20:50:51 pooka Exp $
+#	$NetBSD: Makefile.rumpnet,v 1.6 2009/06/10 20:54:55 pooka Exp $
 #
 
 .include ${RUMPTOP}/Makefile.rump
@@ -27,7 +27,6 @@
 SHLIB_MINOR=0
 
 CPPFLAGS+=	-I${RUMPTOP}/librump/rumpkern -I${RUMPTOP}/librump/rumpnet/opt
-CPPFLAGS+=	-DMAXUSERS=32
 
 .include bsd.lib.mk
 .include bsd.klinks.mk