diff options
author | bz <bz@FreeBSD.org> | 2008-08-17 23:27:27 +0000 |
---|---|---|
committer | bz <bz@FreeBSD.org> | 2008-08-17 23:27:27 +0000 |
commit | 1021d43b569bfc8d2c5544bde2f540fa432b011f (patch) | |
tree | 1496da534aec03cf2f9d2d0735d80e4c1e3b5715 /sys/netinet6/in6_gif.c | |
parent | 7fc341305a3e341fca7f202fc1219358f8d9dbbd (diff) | |
download | FreeBSD-src-1021d43b569bfc8d2c5544bde2f540fa432b011f.zip FreeBSD-src-1021d43b569bfc8d2c5544bde2f540fa432b011f.tar.gz |
Commit step 1 of the vimage project, (network stack)
virtualization work done by Marko Zec (zec@).
This is the first in a series of commits over the course
of the next few weeks.
Mark all uses of global variables to be virtualized
with a V_ prefix.
Use macros to map them back to their global names for
now, so this is a NOP change only.
We hope to have caught at least 85-90% of what is needed
so we do not invalidate a lot of outstanding patches again.
Obtained from: //depot/projects/vimage-commit2/...
Reviewed by: brooks, des, ed, mav, julian,
jamie, kris, rwatson, zec, ...
(various people I forgot, different versions)
md5 (with a bit of help)
Sponsored by: NLnet Foundation, The FreeBSD Foundation
X-MFC after: never
V_Commit_Message_Reviewed_By: more people than the patch
Diffstat (limited to 'sys/netinet6/in6_gif.c')
-rw-r--r-- | sys/netinet6/in6_gif.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/netinet6/in6_gif.c b/sys/netinet6/in6_gif.c index d05f8a3..1220244 100644 --- a/sys/netinet6/in6_gif.c +++ b/sys/netinet6/in6_gif.c @@ -46,6 +46,7 @@ __FBSDID("$FreeBSD$"); #include <sys/protosw.h> #include <sys/malloc.h> +#include <sys/vimage.h> #include <net/if.h> #include <net/route.h> @@ -175,7 +176,7 @@ in6_gif_output(struct ifnet *ifp, ip6->ip6_vfc |= IPV6_VERSION; ip6->ip6_plen = htons((u_short)m->m_pkthdr.len); ip6->ip6_nxt = proto; - ip6->ip6_hlim = ip6_gif_hlim; + ip6->ip6_hlim = V_ip6_gif_hlim; ip6->ip6_src = sin6_src->sin6_addr; /* bidirectional configured tunnel mode */ if (!IN6_IS_ADDR_UNSPECIFIED(&sin6_dst->sin6_addr)) @@ -258,14 +259,14 @@ in6_gif_input(struct mbuf **mp, int *offp, int proto) sc = (struct gif_softc *)encap_getarg(m); if (sc == NULL) { m_freem(m); - ip6stat.ip6s_nogif++; + V_ip6stat.ip6s_nogif++; return IPPROTO_DONE; } gifp = GIF2IFP(sc); if (gifp == NULL || (gifp->if_flags & IFF_UP) == 0) { m_freem(m); - ip6stat.ip6s_nogif++; + V_ip6stat.ip6s_nogif++; return IPPROTO_DONE; } @@ -320,7 +321,7 @@ in6_gif_input(struct mbuf **mp, int *offp, int proto) break; default: - ip6stat.ip6s_nogif++; + V_ip6stat.ip6s_nogif++; m_freem(m); return IPPROTO_DONE; } |