Skip to content

Commit

Permalink
datapath: Check for backported sctp_compute_cksum().
Browse files Browse the repository at this point in the history
This is backported by RHEL7.

Reported-by: Ashok Byahatti <[email protected]>
Signed-off-by: Jesse Gross <[email protected]>
Acked-by: Joe Stringer <[email protected]>
  • Loading branch information
jessegross committed Jan 4, 2014
1 parent 004a624 commit c4e976d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 2 additions & 0 deletions acinclude.m4
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,8 @@ AC_DEFUN([OVS_CHECK_LINUX_COMPAT], [
OVS_GREP_IFELSE([$KSRC/include/net/netlink.h], [nla_put_be64])
OVS_GREP_IFELSE([$KSRC/include/net/netlink.h], [nla_find_nested])
OVS_GREP_IFELSE([$KSRC/include/net/sctp/checksum.h], [sctp_compute_cksum])
OVS_GREP_IFELSE([$KSRC/include/linux/if_vlan.h], [ADD_ALL_VLANS_CMD],
[OVS_DEFINE([HAVE_VLAN_BUG_WORKAROUND])])
Expand Down
3 changes: 1 addition & 2 deletions datapath/linux/compat/include/net/sctp/checksum.h
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
#ifndef __SCTP_CHECKSUM_WRAPPER_H
#define __SCTP_CHECKSUM_WRAPPER_H 1

#include <linux/version.h>
#include_next <net/sctp/checksum.h>

#if LINUX_VERSION_CODE < KERNEL_VERSION(3,12,0)
#ifndef HAVE_SCTP_COMPUTE_CKSUM
static inline __le32 sctp_compute_cksum(const struct sk_buff *skb,
unsigned int offset)
{
Expand Down

0 comments on commit c4e976d

Please sign in to comment.