2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-29 13:27:59 +00:00

117 Commits

Author SHA1 Message Date
maryam.tahhan
b35839f385 netdev-dpdk: Move to DPDK 1.7.1
This patch updates the documentation to reflect that DPDK 1.7.1
is supported. Travis scripts have also been updated to reflect
this. DPDK phy and ring ports were validated against DPDK 1.7.1.

Reviewed-by: Mark D. Gray <mark.d.gray@intel.com>
Signed-off-by: Maryam Tahhan <maryam.tahhan@intel.com>
Acked-by: Daniele Di Proietto <ddiproietto@vmware.com>
Acked-by: Thomas Graf <tgraf@noironetworks.com>
Acked-by: Pravin B Shelar <pshelar@nicira.com>
2014-10-20 11:19:42 -07:00
Pravin B Shelar
06021dcba9 datapath: compat: Fix compilation 3.11
Kernel 3.11 is only kernel where GRE APIs are available but
not vxlan. Add check for vxlan xmit to detect this case.

Reported-by: Dave Benson <dbenson@verdantnetworks.com>
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Andy Zhou <azhou@nicira.com>
2014-10-13 11:03:11 -07:00
Pravin B Shelar
705e9260d5 datapath: Add support for RHEL-7 / CentOS-7 kernel.
This patch mostly is related to tunnel API where RHEL 7
kernel API are not in-sync with newer linux kernel API. So
extra checks are required to check for parameters of API.

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jiri Benc <jbenc@redhat.com>
2014-10-03 15:38:53 -07:00
Samuel Gauthier
114fce23a7 datapath: restore OVS_FLOW_CMD_NEW notifications
Since commit fb5d1e9e127a ("openvswitch: Build flow cmd netlink reply only if needed."),
the new flows are not notified to the listeners of OVS_FLOW_MCGROUP.

This commit fixes the problem by using the genl function, ie
genl_has_listerners() instead of netlink_has_listeners().

Signed-off-by: Samuel Gauthier <samuel.gauthier@6wind.com>
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Acked-by: Pravin B Shelar <pshelar@nicira.com>
2014-09-20 19:45:51 -07:00
Thomas Graf
f6a0c895fc datapath: Provide compatibility for kernels up to 3.17
Port datapath to work with kernrels up to 3.17 and use 3.16.2 as
the new kernel for CI testing.

Tested with 3.14, 3.16.2, and net-next (3.17).

Signed-off-by: Thomas Graf <tgraf@noironetworks.com>
Co-authored-by: Madhu Challa <challa@noironetworks.com>
Acked-by: Pravin B Shelar <pshelar@nicira.com>
2014-09-20 19:36:33 -07:00
Andy Zhou
00e01dd48c datapath: Improve robustness of this_cpu_ptr definition in compat layer
Current autoconfig detection logic for HAVE_PER_CPU_PTR is not robust.
Depends on linux kernel version, the definition can be in either
linux/percpu.h or asm/percpu.h

Turns out it is simpler and safer to handle missing percpu.h
definitions in linux/percpu.h rather than asm/percpu.h. With this
change, there is no need for the autoconfig detection logic above.

Signed-off-by: Andy Zhou <azhou@nicira.com>
Acked-by: Pravin B Shelar <pshelar@nicira.com>
2014-09-15 00:21:21 -07:00
Pravin B Shelar
4303ec3469 datapath: Add IS_ERR_OR_NULL for backward compatibility.
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
2014-09-12 16:05:47 -07:00
Thomas Graf
95626395a3 build: Respect CFLAGS and LDFLAGS passed to make
configure cannot expect that the user will not pass additional CFLAGS
and LDFLAGS at make time [0]. Use OVS_CFLAGS and OVS_LDFLAGS instead to
collect compiler and linker flags and substitute in Makefile.am.

This allows for:
./configure --with-dpdk=[...]
make CFLAGS=-Wno-error=foo

[0] http://www.gnu.org/software/automake/manual/html_node/Flag-Variables-Ordering.html

Signed-off-by: Thomas Graf <tgraf@noironetworks.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2014-09-11 12:37:38 -07:00
Pravin B Shelar
2ea8241431 datapath: Backport __ip_select_ident() function
definition of __ip_select_ident() changed in newer kernel and
it is backported to stable kernel, Therefore adding configure
check to detect the new function.

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Andy Zhou <azhou@nicira.com>
2014-09-10 13:28:02 -07:00
Daniele Di Proietto
9475dfeb28 acinclude.m4: Do not set vswitchd_ovs_vswitchd_LDFLAGS
Commit d731058395cb used vswitchd_ovs_vswitchd_LDFLAGS to link with DPDK. This
made automake ignore AM_LDFLAGS while linking the daemon.

This commit explicitly adds AM_LDFLAGS to vswitchd_ovs_vswitchd_LDFLAGS and
moves it to vswitchd/automake.mk

Reported-by: Gurucharan Shetty <gshetty@nicira.com>
Suggested-by: Ben Pfaff <blp@nicira.com>
Signed-off-by: Daniele Di Proietto <ddiproietto@vmware.com>
Signed-off-by: Gurucharan Shetty <gshetty@nicira.com>
2014-08-18 12:36:10 -07:00
Daniele Di Proietto
d731058395 netdev-dpdk: Move to DPDK 1.7.0
With this commit we move our DPDK support to 1.7.0.
DPDK binaries (starting with dpdk 1.7.0) should be linked with --whole-archive
to include pmd drivers

Signed-off-by: Daniele Di Proietto <ddiproietto@vmware.com>
Acked-by: Pravin B Shelar <pshelar@nicira.com>
2014-08-12 17:38:48 -07:00
Jesse Gross
09f27436b1 datapath: Change u64_stats_* to use _irq instead of _bh().
The upstream u64_stats API has been changed to remove the _bh()
versions and switch all consumers to use IRQ safe variants instead.
This was done to be safe for netpoll generated packets, which can
occur in hard IRQ context. From a safety perspective, this doesn't
directly affect OVS since it doesn't support netpoll. However, this
change has been backported to older kernels so OVS needs to use the
new API to compile.

Signed-off-by: Jesse Gross <jesse@nicira.com>
Acked-by: Pritesh Kothari <pritesh.kothari@cisco.com>
Acked-by: Pravin B Shelar <pshelar@nicira.com>
2014-07-01 12:11:21 -07:00
Jesse Gross
5640cbd8bd datapath: Rehash 16-bit skbuff hashes into 32 bits.
Currently, if the network stack provides skb->rxhash then we use it,
otherwise we compute our own. However, on at least some versions of
RHEL/CentOS, the stack provides a hash that is 16 bits rather than
32 bits. In cases where we use the uppermost bits of the hash this
is particularly bad because we detect that a hash is present and we
use it rather than computing our own but the result is always zero.

This is particularly noticible with tunnel ports that use the hash
to generate a source port, such as VXLAN. On these kernels the tunnel
source port is always the minimum value. To solve this problem while
still taking advantage of the precomputed hash, this rehashes the
hash so that the entropy is spread throughout 32 bits.

Signed-off-by: Jesse Gross <jesse@nicira.com>
Acked-by: Thomas Graf <tgraf@noironetworks.com>
2014-06-25 08:08:11 -07:00
Daniele Di Proietto
c1223b11d4 acinclude.m4: dpdk: link with -ldl if necessary
On some systems libintel_dpdk.a fails to link with libopenvswitch
unless -ldl is used. This should address the issue

Signed-off-by: Daniele Di Proietto <ddiproietto@vmware.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2014-06-09 11:28:59 -07:00
Jarno Rajahalme
7c96151e33 CodingStyle: Allow C99 mixing of declarations and code.
As even the MSVC 2013 now supports the C99 mixing of declarations and
code, we can now allow them in OVS code.
    
Signed-off-by: Jarno Rajahalme <jrajahalme@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
2014-05-28 16:56:29 -07:00
Ben Pfaff
380f86e4a7 acinclude.m4: Fix "sparse", via detection of GNU make "if" directive.
Make treats tabs very differently from spaces at the beginning of a line,
so this test must use a tab instead of a space.  This partially reverts
commit a0903134d2d60 (acinclude.m4: Expand tabs).

Without this commit, the build system never enables checking with sparse
because it never detects that GNU make "if" works.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp>
2014-05-19 07:52:21 -07:00
YAMAMOTO Takashi
e2e5451794 acinclude.m4: Fix a typo in a help message
Acked-by: Ben Pfaff <blp@nicira.com>
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp>
2014-05-10 14:09:20 +09:00
YAMAMOTO Takashi
a0903134d2 acinclude.m4: Expand tabs
Acked-by: Ben Pfaff <blp@nicira.com>
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp>
2014-05-10 14:09:20 +09:00
Pritesh Kothari
9bbf88b238 datapath: clear l4_rxhash in skb_clear_hash.
Signed-off-by: Pritesh Kothari <pritesh.kothari@cisco.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
2014-05-01 23:14:45 -07:00
Pritesh Kothari
e2f3178f05 datapath: Add support for kernel 3.14.
Signed-off-by: Pritesh Kothari <pritesh.kothari@cisco.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
2014-05-01 23:11:00 -07:00
Joe Stringer
1edc458d61 datapath: Check for backported skb_orphan_frags().
This was causing build failures on debian wheezy. Check for the feature
rather than the version.

Signed-off-by: Joe Stringer <joestringer@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2014-04-29 10:19:29 +12:00
Ben Pfaff
a7ae938074 FAQ: Explain what to do when building against a too-new kernel.
Also add references to this FAQ from INSTALL and configure.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Gurucharan Shetty <gshetty@nicira.com>
2014-04-24 15:37:24 -07:00
Pravin Shelar
cb25142c50 datapath: Add support for kernels 3.13
Add support for building the in-tree kernel datapath for
Linux kernels up to 3.13. There were some changes in the
netlink area which required adding new compatibility code
for this layer. Also, some new per-cpu stats initialization
code was added.

Based on patch from Kyle Mestery.

Signed-off-by: Kyle Mestery <mestery@noironetworks.com>
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Kyle Mestery <mestery@noironetworks.com>
2014-03-31 07:38:38 -07:00
Pravin
8a9562d21a dpif-netdev: Add DPDK netdev.
Following patch adds DPDK netdev-class to userspace datapath. Now
OVS can use DPDK port for IO by just configuring DPDK port and then
adding dpdk type port to userspace datapath.

Refer to INSTALL.DPDK doc for further info.

This is based a patch from Gerald Rogers.

Signed-off-by: Gerald Rogers <gerald.rogers@intel.com>
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Thomas Graf <tgraf@redhat.com>
2014-03-21 11:48:28 -07:00
Pravin Shelar
29c71cfa0c datapath: Add support for Linux 3.12
Bump kernel support for datapath module to include 3.12.
Make use of native ip-tunnel API for Kernel >= 3.12.

Based on patch from James Page.

Signed-off-by: James Page <james.page@ubuntu.com>
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Reviewed-by: Kyle Mestery <mestery@noironetworks.com>
2014-03-07 04:00:24 -08:00
Ben Pfaff
5020f5f099 Makefile: Compile Linux-specific files based on __linux__ macro.
We want to conditionally compile several files based on whether we're
building for a Linux host, so we need some Automake conditional for that.
Previously this was based on whether Netlink is available and we're not
on ESX (since ESX has Netlink but isn't Linux), but it's more
straightforward to just test for Linux directly.

CC: Luigi Rizzo <rizzo@iet.unipi.it>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2014-03-05 07:51:56 -08:00
Jesse Gross
c4e976db13 datapath: Check for backported sctp_compute_cksum().
This is backported by RHEL7.

Reported-by: Ashok Byahatti <ashok.byahatti@embrane.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
Acked-by: Joe Stringer <joestringer@nicira.com>
2014-01-03 16:08:37 -08:00
Pravin B Shelar
cc1d0dea7f datapath: compat: Configure check GRE DEMUX.
RHEL6-openstack kernel has backported gre DEMUX module,
Therefore add configure check to detect it.

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
Bug #21936
2013-12-20 15:34:43 -08:00
Pravin B Shelar
8fa5225080 datapath: compat: Add configure check for lockdep_rtnl_is_held()
RHEL6-openstack kernel has backported lockdep_rtnl_is_held().

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-12-20 15:34:40 -08:00
Pravin B Shelar
da4bbeb70a datapath: compat: Fix skb_has_frag_list definition.
RHEL6-openstack kernel has already replaced skb_has_frags
with skb_has_frag_list().

Fix compilation error on RHEL6-openstack.

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-12-20 15:34:38 -08:00
Jesse Gross
d1890de500 datapath: Check for backported netdev_features_t.
This is apparently used by CentOS 6.5.

Reported-by: Phil Daws <uxbod@splatnix.net>
Reported-by: Edouard Bourguignon <madko@linuxed.net>
Signed-off-by: Jesse Gross <jesse@nicira.com>
2013-12-20 11:47:44 -08:00
Pravin B Shelar
0aa6fda799 datapath: Fix build failure on RHEL 6.4
Patch fixes following build failure:-

make[4]: Entering directory
`/usr/src/kernels/2.6.32-358.18.1.el6.x86_64'
  CC [M]  openvswitch/datapath/linux/actions.o
In file included from
openvswitch/datapath/linux/actions.c:21:
openvswitch/datapath/linux/compat/include/linux/skbuff.h:273:
error: redefinition of ‘__skb_fill_page_desc’
include/linux/skbuff.h:1123: note: previous definition of
‘__skb_fill_page_desc’ was here
-----

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-12-16 14:56:43 -08:00
Helmut Schaa
38b7a52b61 openvswitch: Use libtool and allow building shared libs
Currently openvswitch builds all libraries static only. However,
libopenvswitch is linked into nearly all openvswitch executables
making it hardly possible to run openvswitch on embedded devices
(for example running OpenWrt).

Convert openvswitch to use libtool for building its internal libs.
This allows "--enable-shared" and "--enable-static" as configure
arguments. Default is "--disable-shared" thus keeping the current
behavior with the only change that static libs are installed by
"make install".

Since the openvswitch library interfaces are internal and thus not
stable (yet) encode the openvswitch version into the library name:
libopenvswitch-2.0.90.so

Binary size is reduced to around 1/3 when using shared libs.

Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2013-12-17 16:30:32 -08:00
Pravin B Shelar
60c4904fec datapath: Add compile time check for rxhash
Some distribution kernel has backported skb->rxhash (e.g. RHEL)
Following patch allows use precalculated rxhash.

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Reviewed-by: Thomas Graf <tgraf@redhat.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-12-03 08:36:51 -08:00
Pravin B Shelar
54af97ad7b datapath: Add support for Linux 3.11
Kernel 3.11 has support for extended GRE API required for
OVS datapath,  But vxlan still needs out of tree tunneling
compatibility.  Therefore to simplify, all tunneling modules
are forced to use compat tunneling.

CC: James Page <james.page@ubuntu.com>
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-10-16 12:12:50 -07:00
Viresh Kumar
63a04c1b5f datapath: remove HAVE_MAC_RAW
This was causing it to fail against latest RT kernels, with following errors:

	In file included from /home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux/compat/include/linux/if_vlan.h:6:0,
	                 from /home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux/actions.c:29:
	/home/arm/work/kernel/linaro/lng/lng.git/include/linux/if_vlan.h: In function vlan_insert_tag:
	/home/arm/work/kernel/linaro/lng/lng.git/include/linux/if_vlan.h:197:5: error: struct sk_buff has no member named mac
	In file included from /home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux/../flow.h:34:0,
	                 from /home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux/../datapath.h:31,
	                 from /home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux/actions.c:36:
	/home/arm/work/kernel/linaro/lng/lng.git/include/net/inet_ecn.h: In function INET_ECN_set_ce:
	/home/arm/work/kernel/linaro/lng/lng.git/include/net/inet_ecn.h:137:10: error: struct sk_buff has no member named nh
	/home/arm/work/kernel/linaro/lng/lng.git/include/net/inet_ecn.h:142:10: error: struct sk_buff has no member named nh
	/home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux/actions.c: In function __pop_vlan_tci:
	/home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux/actions.c:72:5: error: struct sk_buff has no member named mac
	make[7]: *** [/home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux/actions.o] Error 1
	make[6]: *** [_module_/home/arm/work/kernel/linaro/lng/openvswitch/datapath/linux] Error 2

Not sure why it was added earlier but my guess is, for earlier RT kernels struct
sk_buff had following variables mac.raw, nh.raw, h.raw instead of mac_header,
network_header, transport_header. And so the hack to rename them in OVS code.
But that's not the case now. RT kernel have mac_header, network_header and
transport_header as parameter and so we don't need this macro at all.

Lets get rid of it.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Jesse Gross <jesse@nicira.com>
2013-09-13 09:03:18 -07:00
Pravin B Shelar
5804fb7b84 datapath: Remove compat files.
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-09-06 09:51:59 -07:00
Pravin B Shelar
d3fe1c2bb3 datapath: Remove compat support for NLA_NUL_STRING
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-09-06 09:51:50 -07:00
Pravin B Shelar
d76aabead8 datapath: Move kernel version check to configure.
Rather than having compile time check in datapath.c, its better
to check kernel version at configuration step.

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-09-06 09:51:12 -07:00
Pravin B Shelar
14002a5984 datapath: Use parallel_ops genl.
OVS locking was recently changed to have private OVS lock which
simplified overall locking.  Therefore there is no need to have
another global genl lock to protect OVS data structures.  Following
patch uses of parallel_ops genl family for OVS.  This also allows
more granual OVS locking using ovs_mutex for protecting OVS data
structures, which gives more concurrencey.  E.g multiple genl
operations OVS_PACKET_CMD_EXECUTE can run in parallel, etc.

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-08-10 16:07:52 -07:00
Ben Pfaff
8a8cd0acd0 configure: Distinguish glibc and NetBSD pthread_setname_np() variants.
Reported-by: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
Tested-by: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2013-08-01 09:47:20 -07:00
Kyle Mestery
dc0d542d52 datapath: Conditionally define skb_unclone in datapath compat code
Recent versions of Fedora have skb_unclone included in their
kernels. This patch adds a conditional check into the compat directory so as
not to error out by defining it twice. This allows the latest OVS kernel
module to build on Fedora 19.

Signed-off-by: Kyle Mestery <kmestery@cisco.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
2013-07-22 10:24:18 -07:00
Pravin B Shelar
a2b7fd3fa6 datapath: Revert "datapath: rhel: Account for RHEL specific backports"
This reverts commit 752378e1cd1f133a8366fbacec3b281a45ff8268
(datapath: rhel: Account for RHEL specific backports).
Change related to netif_needs_gso() is cuasing panic on RHEL
and Xen platforms.  This way we revert back to use of ovs
skb_gso_segment() and netif_skb_features() which has required
compat code for gso for kernel older than 2.6.38.

<1>[  924.855722] BUG: unable to handle kernel NULL pointer dereference
at 000000a0
<1>[  924.855789] IP: [<f0337fb7>] netdev_send+0x77/0x340 [openvswitch]
<4>[  924.855849] *pdpt = 000000011bc66027 *pde = 0000000000000000
<0>[  924.855895] Oops: 0000 [#1] SMP
<0>[  924.855927] last sysfs file: /sys/class/net/lo/carrier
<4>[  924.856551] Pid: 17937, comm: vif Not tainted
(2.6.32.43-0.4.1.xs1.6.10.734.170748xen #1) VMware Virtual Platform
<4>[  924.856618] EIP: 0061:[<f0337fb7>] EFLAGS: 00010246 CPU: 0
<4>[  924.856659] EIP is at netdev_send+0x77/0x340 [openvswitch]
<4>[  924.856697] EAX: 00000000 EBX: dd4fb800 ECX: 00000000 EDX:
00000289
<4>[  924.856749] ESI: edd55a40 EDI: 000005dc EBP: df287aa8 ESP:
df287a7c
<4>[  924.856790]  DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0069
<0>[  924.856825] Process vif (pid: 17937, ti=df286000 task=ee88d570
task.ti=df286000)
<0>[  924.856880] Stack:
<4>[  924.856902]  00000000 be8b9067 00000000 e9b02000 dd523ac0 dd523b50
f033aef1 b2e77c64
<4>[  924.856966] <0> dd523ac0 ee902840 dd4fc58c df287ab8 f0336162
edd55a40 ee902840 df287ac8
<4>[  924.857043] <0> f032d684 0000001e ee10a300 df287b34 f032d6ef
0000001c 00000000 00000000
<0>[  924.858942] Call Trace:
<4>[  924.859553]  [<f033aef1>] ? flex_array_get+0x51/0x70 [openvswitch]
<4>[  924.860189]  [<f0336162>] ? ovs_vport_send+0x12/0x50 [openvswitch]
<4>[  924.860806]  [<f032d684>] ? do_output+0x34/0x50 [openvswitch]
<4>[  924.861444]  [<f032d6ef>] ? do_execute_actions+0x4f/0x830
[openvswitch]
<4>[  924.862047]  [<f032dfa0>] ? ovs_execute_actions+0x70/0xd0
[openvswitch]
<4>[  924.862636]  [<f032fd3f>] ?
ovs_dp_process_received_packet+0x8f/0xf0 [openvswitch]
<4>[  924.863774]  [<f033690e>] ? ovs_vport_receive+0x5e/0x70
[openvswitch]
<4>[  924.864354]  [<f0337d9f>] ? netdev_frame_hook+0x4f/0x90
[openvswitch]
<4>[  924.864918]  [<c034f7ab>] ? netif_receive_skb+0x1bb/0x6a0
<4>[  924.865469]  [<c03c193f>] ? vlan_gro_common+0x10f/0x230
<4>[  924.866007]  [<c034fd58>] ? napi_skb_finish+0x38/0x40
<4>[  924.866533]  [<c03c1e86>] ? vlan_gro_receive+0x76/0x80
<4>[  924.867055]  [<f05adba4>] ? e1000_receive_skb+0x74/0x80 [e1000]
<4>[  924.867571]  [<f05b2b67>] ? e1000_clean_rx_irq+0x1f7/0x3e0 [e1000]
<4>[  924.868084]  [<f05b2970>] ? e1000_clean_rx_irq+0x0/0x3e0 [e1000]
<4>[  924.869025]  [<f05b06ac>] ? e1000_poll+0x4c/0x1f0 [e1000]

--snip--

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-07-15 11:21:28 -07:00
Thomas Graf
752378e1cd datapath: rhel: Account for RHEL specific backports
The following symbols have been backported to RHEL and the kernel
version is no longer an accurate indicator for their presence:

 - skb_gso_segment
 - netif_skb_features
 - netif_needs_gso

Signed-off-by: Thomas Graf <tgraf@redhat.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
2013-07-09 11:06:53 -07:00
Ben Pfaff
501948203f acinclude: Improve detection of not-understood compiler options with clang.
By default, clang warns about but does not fail on unknown -W options.
This made configure add the option to WARNING_FLAGS, which caused the
warning about not-understood warnings to be emitted for every file
compiled.

In combination with -Werror, clang does fail on unknown -W options.  This
commit adds -Werror during configure's warning tests, which should cause
the not-understood warnings to be detected that way.

Reported-by: Ed Maste <emaste@freebsd.org>
Tested-by: Ed Maste <emaste@freebsd.org>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2013-06-24 12:25:48 -07:00
YAMAMOTO Takashi
d23fa2ed56 acinclude.m4: update a comment for NetBSD support
Signed-off-by: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2013-05-21 08:01:47 -07:00
Pravin B Shelar
8dbe1f9fbf datapath: Fix compilation with Linux kernel 3.7.
Definition of __sum16 and __wsum is moved to uapi header.
Following patch adds check in config script for second possible
header.

Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2013-05-13 15:53:06 -07:00
Thomas Graf
42d5dd9595 datapath: Account for RHEL6.4 backports in compat layer
Explicitly check the availability of several kernel API functions
instead of relying on the kernel version to account for Red Hat
Enterprise Linux backports.

Signed-off-by: Thomas Graf <tgraf@redhat.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
2013-04-25 13:24:49 -07:00
Thomas Graf
f285d3e715 datapath: Use openvswitch_handle_frame hook in >=RHEL6.4 to live side by side with bridging
Due to the missing register rx_handler API in the kernel RHEL6 is
based on, the datapath currently falls back to using the bridging
hook with the consequence that bridging and OVS cannot be used in
parallel on any RHEL6 release.

For this purpose, >=RHEL6.4 releases provide a special rx frame hook
to be used by OVS. It captures frames at the same location in the
stack as the rx_handler would do in more recent kernel releases. In
order to store the vport pointer, the net_device's ax25_ptr field is
utilized under the assumption that an AX25 device will never be
attached to an OVS bridge.

Signed-off-by: Thomas Graf <tgraf@redhat.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
2013-04-25 13:23:46 -07:00
Andy Zhou
32e96ab703 sparse: Support recent distributions
sparse support seems to be broken on some recent Linux distributions.
For example, ubuntu 12.04 with Linux 3.5 kernel, and Debian latest test
distribution, running Linux 3.2 kernel.

On both systems that sparse was broken, It was not able find the header files
in the  default system include directories.  GCC finds them by default.

This patch adds the required GCC default search path when running sparse.

Tested on:

Ubuntu 12.04 - w/ linux 3.5 kernel
Debian-6 March test distribution - w/ linux 3.2 kernel

Signed-off-by: Andy Zhou <azhou@nicira.com>
[blp@nicira.com also tested on Debian squeeze and wheezy (testing)]
Signed-off-by: Ben Pfaff <blp@nicira.com>
2013-04-18 10:08:03 -07:00