PERFORCE change 145870 for review
Marko Zec
zec at FreeBSD.org
Fri Jul 25 06:30:49 UTC 2008
http://perforce.freebsd.org/chv.cgi?CH=145870
Change 145870 by zec at zec_tpx32 on 2008/07/25 06:30:07
Unbreak VIMAGE build.
Affected files ...
.. //depot/projects/vimage-devel/src/sys/netinet/tcp_offload.c#3 edit
Differences ...
==== //depot/projects/vimage-devel/src/sys/netinet/tcp_offload.c#3 (text+ko) ====
@@ -28,6 +28,8 @@
#include <sys/cdefs.h>
__FBSDID("$FreeBSD: src/sys/netinet/tcp_offload.c,v 1.4 2008/07/21 21:22:56 kmacy Exp $");
+#include "opt_vimage.h"
+
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/types.h>
@@ -37,11 +39,13 @@
#include <sys/mbuf.h>
#include <sys/socket.h>
#include <sys/socketvar.h>
+#include <sys/vimage.h>
#include <net/if.h>
#include <net/if_types.h>
#include <net/if_var.h>
+#include <netinet/vinet.h>
#include <netinet/in.h>
#include <netinet/in_systm.h>
#include <netinet/in_pcb.h>
@@ -101,21 +105,23 @@
void
tcp_offload_twstart(struct tcpcb *tp)
{
+ INIT_VNET_INET(curvnet);
- INP_INFO_WLOCK(&tcbinfo);
+ INP_INFO_WLOCK(&V_tcbinfo);
INP_WLOCK(tp->t_inpcb);
tcp_twstart(tp);
- INP_INFO_WUNLOCK(&tcbinfo);
+ INP_INFO_WUNLOCK(&V_tcbinfo);
}
struct tcpcb *
tcp_offload_close(struct tcpcb *tp)
{
+ INIT_VNET_INET(curvnet);
- INP_INFO_WLOCK(&tcbinfo);
+ INP_INFO_WLOCK(&V_tcbinfo);
INP_WLOCK(tp->t_inpcb);
tp = tcp_close(tp);
- INP_INFO_WUNLOCK(&tcbinfo);
+ INP_INFO_WUNLOCK(&V_tcbinfo);
if (tp)
INP_WUNLOCK(tp->t_inpcb);
@@ -125,11 +131,12 @@
struct tcpcb *
tcp_offload_drop(struct tcpcb *tp, int error)
{
+ INIT_VNET_INET(curvnet);
- INP_INFO_WLOCK(&tcbinfo);
+ INP_INFO_WLOCK(&V_tcbinfo);
INP_WLOCK(tp->t_inpcb);
tp = tcp_drop(tp, error);
- INP_INFO_WUNLOCK(&tcbinfo);
+ INP_INFO_WUNLOCK(&V_tcbinfo);
if (tp)
INP_WUNLOCK(tp->t_inpcb);
More information about the p4-projects
mailing list