Signed-off-by: Joe Stringer <j...@ovn.org>
---
 acinclude.m4                                 | 2 ++
 datapath/linux/compat/include/net/inetpeer.h | 3 ++-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/acinclude.m4 b/acinclude.m4
index 5c758a641e1e..245267a26679 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -360,6 +360,8 @@ AC_DEFUN([OVS_CHECK_LINUX_COMPAT], [
                         [frags_work])
   OVS_FIND_FIELD_IFELSE([$KSRC/include/net/inet_frag.h], [inet_frags],
                         [rwlock])
+  OVS_GREP_IFELSE([$KSRC/include/net/inetpeer.h], [vif],
+                  [OVS_DEFINE([HAVE_INETPEER_VIF_SUPPORT])])
 
   OVS_GREP_IFELSE([$KSRC/include/net/dst_metadata.h], [metadata_dst])
 
diff --git a/datapath/linux/compat/include/net/inetpeer.h 
b/datapath/linux/compat/include/net/inetpeer.h
index 02e9d440a60c..c086f3b11a78 100644
--- a/datapath/linux/compat/include/net/inetpeer.h
+++ b/datapath/linux/compat/include/net/inetpeer.h
@@ -3,7 +3,8 @@
 
 #include_next <net/inetpeer.h>
 
-#ifdef OVS_FRAGMENT_BACKPORT
+#if defined(OVS_FRAGMENT_BACKPORT) && \
+    !defined(HAVE_INETPEER_VIF_SUPPORT)
 static inline struct inet_peer *rpl_inet_getpeer_v4(struct inet_peer_base 
*base,
                                                    __be32 v4daddr, int vif,
                                                    int create)
-- 
2.1.4

_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to