Skip to content

Commit

Permalink
gre: Add kernel GRE support.
Browse files Browse the repository at this point in the history
This implements the kernel portion of GRE on Linux.  It consists
of a backported module that provides the GRE capabilities of 2.6.32
plus bug fixes to kernels 2.6.18+.
  • Loading branch information
jessegross committed Dec 7, 2009
1 parent db12f2f commit c3e3d2a
Show file tree
Hide file tree
Showing 9 changed files with 2,010 additions and 0 deletions.
11 changes: 11 additions & 0 deletions acinclude.m4
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,16 @@ AC_DEFUN([OVS_CHECK_VETH], [
fi
])

AC_DEFUN([OVS_CHECK_GRE], [
AC_MSG_CHECKING([whether to build gre module])
if test "$sublevel" -ge 18; then
AC_MSG_RESULT([yes])
AC_SUBST([BUILD_GRE], 1)
else
AC_MSG_RESULT([no])
fi
])

AC_DEFUN([OVS_CHECK_LOG2_H], [
AC_MSG_CHECKING([for $KSRC26/include/linux/log2.h])
if test -e $KSRC26/include/linux/log2.h; then
Expand Down Expand Up @@ -153,6 +163,7 @@ AC_DEFUN([OVS_CHECK_LINUX26_COMPAT], [
[OVS_DEFINE([HAVE_PROTO_DATA_VALID])])
OVS_CHECK_LOG2_H
OVS_CHECK_VETH
OVS_CHECK_GRE
if cmp -s datapath/linux-2.6/kcompat.h.new \
datapath/linux-2.6/kcompat.h >/dev/null 2>&1; then
rm datapath/linux-2.6/kcompat.h.new
Expand Down
1 change: 1 addition & 0 deletions datapath/linux-2.6/Makefile.main.in
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export top_srcdir = @abs_top_srcdir@
export KSRC = @KBUILD26@
export VERSION = @VERSION@
export BUILD_VETH = @BUILD_VETH@
export BUILD_GRE = @BUILD_GRE@

include $(srcdir)/../Modules.mk
include $(srcdir)/Modules.mk
Expand Down
23 changes: 23 additions & 0 deletions datapath/linux-2.6/Modules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -47,3 +47,26 @@ dist_modules += veth
build_modules += $(if $(BUILD_VETH),veth)
veth_sources = linux-2.6/compat-2.6/veth.c
veth_headers =

dist_modules += ip_gre
build_modules += $(if $(BUILD_GRE),ip_gre)
ip_gre_sources = \
linux-2.6/compat-2.6/ip_gre.c \
linux-2.6/compat-2.6/net_namespace-ip_gre.c
ip_gre_headers = \
linux-2.6/compat-2.6/compat26.h \
linux-2.6/compat-2.6/include/linux/if.h \
linux-2.6/compat-2.6/include/linux/in.h \
linux-2.6/compat-2.6/include/linux/inetdevice.h \
linux-2.6/compat-2.6/include/linux/if_ether.h \
linux-2.6/compat-2.6/include/linux/ip.h \
linux-2.6/compat-2.6/include/linux/ipv6.h \
linux-2.6/compat-2.6/include/linux/netdevice.h \
linux-2.6/compat-2.6/include/linux/skbuff.h \
linux-2.6/compat-2.6/include/linux/tcp.h \
linux-2.6/compat-2.6/include/linux/types.h \
linux-2.6/compat-2.6/include/net/dst.h \
linux-2.6/compat-2.6/include/net/ipip.h \
linux-2.6/compat-2.6/include/net/netns/generic.h \
linux-2.6/compat-2.6/include/net/net_namespace.h \
linux-2.6/compat-2.6/include/net/route.h
Loading

0 comments on commit c3e3d2a

Please sign in to comment.