From feacaa5f8029d17e426b52e7f259b77138c7bbd5 Mon Sep 17 00:00:00 2001 From: Yousong Zhou Date: Mon, 16 Sep 2019 00:18:52 +0000 Subject: [PATCH] openvswitch: bump to version 2.12.0 Signed-off-by: Yousong Zhou --- net/openvswitch/Makefile | 17 ++++--- ...-interface-flag-survive-internal-por.patch | 8 ++-- ...host-target-python-for-cross-compile.patch | 8 ++-- .../0003-ovs-lib-fix-install_dir.patch | 6 +-- .../0004-build-disable-building-tests.patch | 4 +- ...ck-fix-include-for-IP6_DEFRAG_CONNTR.patch | 46 ------------------- 6 files changed, 24 insertions(+), 65 deletions(-) delete mode 100644 net/openvswitch/patches/0005-datapath-conntrack-fix-include-for-IP6_DEFRAG_CONNTR.patch diff --git a/net/openvswitch/Makefile b/net/openvswitch/Makefile index 709e8190a..501e30b1a 100644 --- a/net/openvswitch/Makefile +++ b/net/openvswitch/Makefile @@ -15,11 +15,11 @@ include $(INCLUDE_DIR)/kernel.mk # - Check and update kmod dependencies when necessary (runtime module load check in the least) # PKG_NAME:=openvswitch -PKG_VERSION:=2.11.1 -PKG_RELEASE:=2 +PKG_VERSION:=2.12.0 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://www.openvswitch.org/releases/ -PKG_HASH:=c1296ae44a7b176150915e33bc497cc0a7a02caeba84ea43ce9b6a2509d9b5dc +PKG_HASH:=13fd42703180b4b1146c7e97926d09225485868cc2fbbd58dc0c421b4b8fe8f8 PKG_LICENSE:=Apache-2.0 PKG_LICENSE_FILES:=LICENSE @@ -40,7 +40,7 @@ include ../../lang/python/python3-package.mk ovs_kmod_packages:= ovs_kmod_intree_kernel_patchver_min:=3.10 -ovs_kmod_intree_kernel_patchver_max:=4.18 +ovs_kmod_intree_kernel_patchver_max:=5.0 ovs_kmod_intree_not_supported:=$(strip $(call kernel_patchver_lt,$(ovs_kmod_intree_kernel_patchver_min))$(call kernel_patchver_gt,$(ovs_kmod_intree_kernel_patchver_max))) ovs_kmod_intree_dir:=$(PKG_BUILD_DIR)/datapath/linux ovs_kmod_upstream_dir:=$(LINUX_DIR)/net/openvswitch @@ -111,14 +111,19 @@ $(eval $(call OvsKmodPackageTemplate,openvswitch-geneve)) # will be pulled in by kmod-gre6. NOTE that tunnel6.ko itself cannot be # enabled and selected on its own # +# - kmod-ipt-conntrack-extra: required for nf_conncount.ko +# ovs_kmod_openvswitch-intree_title:=Open vSwitch kernel datapath (in tree) ovs_kmod_openvswitch-intree_depends:=\ +kmod-lib-crc32c \ +kmod-nf-nat \ +IPV6:kmod-nf-nat6 \ +kmod-nf-conntrack \ - +IPV6:kmod-nf-conntrack6 \ - +kmod-gre +IPV6:kmod-gre6 \ + +(IPV6&&(LINUX_4_9||LINUX_4.14)):kmod-nf-conntrack6 \ + +(LINUX_4_9||LINUX_4.14):kmod-gre \ + +(IPV6&&(LINUX_4_9||LINUX_4.14)):kmod-gre6 \ + +(!LINUX_4_9&&!LINUX_4.14):kmod-udptunnel4 \ + +(!LINUX_4_9&&!LINUX_4.14):kmod-ipt-conntrack-extra \ ovs_kmod_openvswitch-intree_files:= $(ovs_kmod_intree_dir)/openvswitch.ko $(eval $(call OvsKmodPackageTemplate,openvswitch-intree)) diff --git a/net/openvswitch/patches/0001-netdev-linux-Let-interface-flag-survive-internal-por.patch b/net/openvswitch/patches/0001-netdev-linux-Let-interface-flag-survive-internal-por.patch index 33af68059..3a293f21a 100644 --- a/net/openvswitch/patches/0001-netdev-linux-Let-interface-flag-survive-internal-por.patch +++ b/net/openvswitch/patches/0001-netdev-linux-Let-interface-flag-survive-internal-por.patch @@ -1,7 +1,7 @@ -From bfcee43923a4bb07954f6648bde1abdcbfa5d95f Mon Sep 17 00:00:00 2001 +From d215c18a17e82194d4ab9ecd14776712f12d6b07 Mon Sep 17 00:00:00 2001 From: Helmut Schaa Date: Wed, 8 Jan 2014 13:48:49 +0100 -Subject: [PATCH 1/5] netdev-linux: Let interface flag survive internal port +Subject: [PATCH 1/4] netdev-linux: Let interface flag survive internal port setup Due to a race condition when bringing up an internal port on Linux @@ -18,10 +18,10 @@ Signed-off-by: Helmut Schaa 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c -index 25d037cb6..ba1427986 100644 +index 2432cd176..11efbdbc9 100644 --- a/lib/netdev-linux.c +++ b/lib/netdev-linux.c -@@ -3117,7 +3117,13 @@ update_flags(struct netdev_linux *netdev, enum netdev_flags off, +@@ -3161,7 +3161,13 @@ update_flags(struct netdev_linux *netdev, enum netdev_flags off, unsigned int old_flags, new_flags; int error = 0; diff --git a/net/openvswitch/patches/0002-python-separate-host-target-python-for-cross-compile.patch b/net/openvswitch/patches/0002-python-separate-host-target-python-for-cross-compile.patch index 5cfbecb25..73f40ff31 100644 --- a/net/openvswitch/patches/0002-python-separate-host-target-python-for-cross-compile.patch +++ b/net/openvswitch/patches/0002-python-separate-host-target-python-for-cross-compile.patch @@ -1,7 +1,7 @@ -From e881c50ff537d4b34c10227360589f83d90ce373 Mon Sep 17 00:00:00 2001 +From e2d9b5d6fc33d7b9cbb7dc16832c5c86e6470966 Mon Sep 17 00:00:00 2001 From: Yousong Zhou Date: Tue, 21 Aug 2018 12:21:05 +0000 -Subject: [PATCH 2/5] python: separate host/target python for cross-compile +Subject: [PATCH 2/4] python: separate host/target python for cross-compile At the moment, python-six is a requirement for openvswitch python library on target machine. @@ -26,10 +26,10 @@ index ff1f94b48..417f53230 100644 ALL_LOCAL = BUILT_SOURCES = diff --git a/m4/openvswitch.m4 b/m4/openvswitch.m4 -index 41042c98e..4a5f0a84a 100644 +index cd6b51d86..6dc9d630b 100644 --- a/m4/openvswitch.m4 +++ b/m4/openvswitch.m4 -@@ -449,7 +449,9 @@ AC_DEFUN([OVS_CHECK_PYTHON], +@@ -456,7 +456,9 @@ AC_DEFUN([OVS_CHECK_PYTHON], fi]) AC_SUBST([PYTHON]) PYTHON=$ovs_cv_python diff --git a/net/openvswitch/patches/0003-ovs-lib-fix-install_dir.patch b/net/openvswitch/patches/0003-ovs-lib-fix-install_dir.patch index 667f38e0f..4d9b04de3 100644 --- a/net/openvswitch/patches/0003-ovs-lib-fix-install_dir.patch +++ b/net/openvswitch/patches/0003-ovs-lib-fix-install_dir.patch @@ -1,7 +1,7 @@ -From b65652ff441c4236b51f037a76147331c1ffd5fd Mon Sep 17 00:00:00 2001 +From 10fa6a820c155b6b7a97875de0b805aacf1046b8 Mon Sep 17 00:00:00 2001 From: Yousong Zhou Date: Wed, 14 Mar 2018 16:44:13 +0800 -Subject: [PATCH 3/5] ovs-lib: fix install_dir() +Subject: [PATCH 3/4] ovs-lib: fix install_dir() The command "install" is not available in OpenWrt by default @@ -11,7 +11,7 @@ Signed-off-by: Yousong Zhou 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/utilities/ovs-lib.in b/utilities/ovs-lib.in -index 9a0af2e82..68ab3f250 100644 +index d646b444a..dee63dece 100644 --- a/utilities/ovs-lib.in +++ b/utilities/ovs-lib.in @@ -159,7 +159,10 @@ install_dir () { diff --git a/net/openvswitch/patches/0004-build-disable-building-tests.patch b/net/openvswitch/patches/0004-build-disable-building-tests.patch index 6d552ac08..e1c0f8211 100644 --- a/net/openvswitch/patches/0004-build-disable-building-tests.patch +++ b/net/openvswitch/patches/0004-build-disable-building-tests.patch @@ -1,7 +1,7 @@ -From 2f9075aca5f54b8d0c14517c408f162985fb1b18 Mon Sep 17 00:00:00 2001 +From 77dfef9dd14987b091c2d4fc9475690759e1f4d7 Mon Sep 17 00:00:00 2001 From: Yousong Zhou Date: Tue, 21 Aug 2018 13:02:21 +0000 -Subject: [PATCH 4/5] build: disable building tests +Subject: [PATCH 4/4] build: disable building tests Signed-off-by: Yousong Zhou --- diff --git a/net/openvswitch/patches/0005-datapath-conntrack-fix-include-for-IP6_DEFRAG_CONNTR.patch b/net/openvswitch/patches/0005-datapath-conntrack-fix-include-for-IP6_DEFRAG_CONNTR.patch deleted file mode 100644 index 1f77ab54b..000000000 --- a/net/openvswitch/patches/0005-datapath-conntrack-fix-include-for-IP6_DEFRAG_CONNTR.patch +++ /dev/null @@ -1,46 +0,0 @@ -From b89f391203c4420eb454cb321e799a64de809f52 Mon Sep 17 00:00:00 2001 -From: Yousong Zhou -Date: Fri, 3 May 2019 15:03:24 +0000 -Subject: [PATCH 5/5] datapath: conntrack: fix include for - IP6_DEFRAG_CONNTRACK_IN - -The enum definition is now inside include/net/ipv6_frag.h since upstream commit -70b095c ("ipv6: remove dependency of nf_defrag_ipv6 on ipv6 module") which was -backported to stable trees (4.9, 4.14, 4.19) only these days. - -The error message - - CC [M] /opt/buildbot/slaves/lede-slave-tah/mipsel_24kc/build/sdk/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/openvswitch-2.11.0/datapath/linux/conntrack.o - /opt/buildbot/slaves/lede-slave-tah/mipsel_24kc/build/sdk/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/openvswitch-2.11.0/datapath/linux/conntrack.c: In function 'handle_fragments': - /opt/buildbot/slaves/lede-slave-tah/mipsel_24kc/build/sdk/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/openvswitch-2.11.0/datapath/linux/conntrack.c:554:8: error: variable 'user' has initializer but incomplete type - enum ip6_defrag_users user = IP6_DEFRAG_CONNTRACK_IN + zone; - ^~~~~~~~~~~~~~~~ - /opt/buildbot/slaves/lede-slave-tah/mipsel_24kc/build/sdk/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/openvswitch-2.11.0/datapath/linux/conntrack.c:554:32: error: 'IP6_DEFRAG_CONNTRACK_IN' undeclared (first use in this function); did you mean 'IP_DEFRAG_CONNTRACK_IN'? - enum ip6_defrag_users user = IP6_DEFRAG_CONNTRACK_IN + zone; - ^~~~~~~~~~~~~~~~~~~~~~~ - IP_DEFRAG_CONNTRACK_IN - /opt/buildbot/slaves/lede-slave-tah/mipsel_24kc/build/sdk/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/openvswitch-2.11.0/datapath/linux/conntrack.c:554:32: note: each undeclared identifier is reported only once for each function it appears in - /opt/buildbot/slaves/lede-slave-tah/mipsel_24kc/build/sdk/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/openvswitch-2.11.0/datapath/linux/conntrack.c:554:25: error: storage size of 'user' isn't known - enum ip6_defrag_users user = IP6_DEFRAG_CONNTRACK_IN + zone; - ^~~~ - /opt/buildbot/slaves/lede-slave-tah/mipsel_24kc/build/sdk/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/openvswitch-2.11.0/datapath/linux/conntrack.c:554:25: warning: unused variable 'user' [-Wunused-variable] - scripts/Makefile.build:326: recipe for target '/opt/buildbot/slaves/lede-slave-tah/mipsel_24kc/build/sdk/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/openvswitch-2.11.0/datapath/linux/conntrack.o' failed - -Reference: https://github.com/openwrt/packages/issues/8548#issuecomment-488871090 -Signed-off-by: Yousong Zhou ---- - datapath/conntrack.c | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/datapath/conntrack.c b/datapath/conntrack.c -index a7dc9e0c3..69bda5a9c 100644 ---- a/datapath/conntrack.c -+++ b/datapath/conntrack.c -@@ -31,6 +31,7 @@ - #include - #include - #include -+#include - - #ifdef CONFIG_NF_NAT_NEEDED - #include