diff --git a/SOURCES/openvswitch-2.13.0.patch b/SOURCES/openvswitch-2.13.0.patch index 37c4222..5dd58d2 100644 --- a/SOURCES/openvswitch-2.13.0.patch +++ b/SOURCES/openvswitch-2.13.0.patch @@ -84153,6 +84153,28 @@ index a44114e8dc..d75d66b863 100644 const char *jsonrpc_session_get_id(const struct jsonrpc_session *); #endif /* jsonrpc.h */ +diff --git a/lib/libopenvswitch.pc.in b/lib/libopenvswitch.pc.in +index 2a3f2ca7bc..44fbb1f9fd 100644 +--- a/lib/libopenvswitch.pc.in ++++ b/lib/libopenvswitch.pc.in +@@ -7,5 +7,5 @@ Name: libopenvswitch + Description: Open vSwitch library + Version: @VERSION@ + Libs: -L${libdir} -lopenvswitch +-Libs.private: @LIBS@ +-Cflags: -I${includedir}/openvswitch ++Libs.private: @LIBS@ @SSL_LIBS@ @CAPNG_LDADD@ @LIBBPF_LDADD@ ++Cflags: -I${includedir} +diff --git a/lib/libsflow.pc.in b/lib/libsflow.pc.in +index e70a2b7048..34bb7e3d69 100644 +--- a/lib/libsflow.pc.in ++++ b/lib/libsflow.pc.in +@@ -8,4 +8,4 @@ Description: sFlow library of Open vSwitch + Version: @VERSION@ + Libs: -L${libdir} -lsflow + Libs.private: @LIBS@ +-Cflags: -I${includedir}/openvswitch ++Cflags: -I${includedir} diff --git a/lib/lldp/lldp.c b/lib/lldp/lldp.c index 74f747fcdc..dfeb2a8002 100644 --- a/lib/lldp/lldp.c @@ -84660,7 +84682,7 @@ index 6187129c00..4da7f0352a 100644 err = rte_vhost_driver_start(dev->vhost_id); diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c -index c6f3d27409..ef996eab00 100644 +index c6f3d27409..61ca8075bd 100644 --- a/lib/netdev-linux.c +++ b/lib/netdev-linux.c @@ -231,6 +231,14 @@ struct rtnl_link_stats64 { @@ -84705,7 +84727,7 @@ index c6f3d27409..ef996eab00 100644 if (change->slave && netdev_linux_kind_is_lag(change->slave)) { lag = shash_find_data(&lag_shash, change->ifname); -@@ -672,7 +676,9 @@ netdev_linux_update_lag(struct rtnetlink_change *change) +@@ -672,13 +676,18 @@ netdev_linux_update_lag(struct rtnetlink_change *change) uint32_t block_id; int error = 0; @@ -84716,7 +84738,17 @@ index c6f3d27409..ef996eab00 100644 master_netdev = netdev_from_name(master_name); if (!master_netdev) { return; -@@ -760,8 +766,11 @@ netdev_linux_run(const struct netdev_class *netdev_class OVS_UNUSED) + } + +- if (is_netdev_linux_class(master_netdev->netdev_class)) { ++ /* If LAG master is not attached to ovs, ingress block on LAG ++ * members shoud not be updated. */ ++ if (!master_netdev->auto_classified && ++ is_netdev_linux_class(master_netdev->netdev_class)) { + block_id = netdev_get_block_id(master_netdev); + if (!block_id) { + netdev_close(master_netdev); +@@ -760,8 +769,11 @@ netdev_linux_run(const struct netdev_class *netdev_class OVS_UNUSED) netdev_linux_update(netdev, nsid, &change); ovs_mutex_unlock(&netdev->mutex); } @@ -84730,7 +84762,7 @@ index c6f3d27409..ef996eab00 100644 ovs_mutex_lock(&lag_mutex); netdev_linux_update_lag(&change); ovs_mutex_unlock(&lag_mutex); -@@ -923,6 +932,8 @@ netdev_linux_common_construct(struct netdev *netdev_) +@@ -923,6 +935,8 @@ netdev_linux_common_construct(struct netdev *netdev_) if (userspace_tso_enabled()) { netdev_->ol_flags |= NETDEV_TX_OFFLOAD_TCP_TSO; netdev_->ol_flags |= NETDEV_TX_OFFLOAD_TCP_CKSUM; @@ -84739,7 +84771,7 @@ index c6f3d27409..ef996eab00 100644 netdev_->ol_flags |= NETDEV_TX_OFFLOAD_IPV4_CKSUM; } -@@ -1233,21 +1244,21 @@ netdev_linux_batch_rxq_recv_sock(struct netdev_rxq_linux *rx, int mtu, +@@ -1233,21 +1247,21 @@ netdev_linux_batch_rxq_recv_sock(struct netdev_rxq_linux *rx, int mtu, * aux_buf is allocated so that it can be prepended to TSO buffer. */ std_len = virtio_net_hdr_size + VLAN_ETH_HEADER_LEN + mtu; for (i = 0; i < NETDEV_MAX_BURST; i++) { @@ -84775,7 +84807,7 @@ index c6f3d27409..ef996eab00 100644 } do { -@@ -1266,14 +1277,28 @@ netdev_linux_batch_rxq_recv_sock(struct netdev_rxq_linux *rx, int mtu, +@@ -1266,14 +1280,28 @@ netdev_linux_batch_rxq_recv_sock(struct netdev_rxq_linux *rx, int mtu, for (i = 0; i < retval; i++) { struct dp_packet *pkt; @@ -84807,7 +84839,7 @@ index c6f3d27409..ef996eab00 100644 continue; } -@@ -2562,7 +2587,7 @@ exit: +@@ -2562,7 +2590,7 @@ exit: static struct tc_police tc_matchall_fill_police(uint32_t kbits_rate, uint32_t kbits_burst) { @@ -84816,7 +84848,7 @@ index c6f3d27409..ef996eab00 100644 unsigned int bps = ((uint64_t) kbits_rate * 1000) / 8; struct tc_police police; struct tc_ratespec rate; -@@ -6202,7 +6227,14 @@ get_stats_via_netlink(const struct netdev *netdev_, struct netdev_stats *stats) +@@ -6202,7 +6230,14 @@ get_stats_via_netlink(const struct netdev *netdev_, struct netdev_stats *stats) if (ofpbuf_try_pull(reply, NLMSG_HDRLEN + sizeof(struct ifinfomsg))) { const struct nlattr *a = nl_attr_find(reply, 0, IFLA_STATS64); if (a && nl_attr_get_size(a) >= sizeof(struct rtnl_link_stats64)) { @@ -85490,10 +85522,59 @@ index b57d21ff8d..be5ed099fd 100644 ds_put_format(&errors, "%s: unknown %s argument '%s'\n", name, type, node->key); diff --git a/lib/netdev.c b/lib/netdev.c -index f95b19af4d..8c44eee8e9 100644 +index f95b19af4d..186b435b1f 100644 --- a/lib/netdev.c +++ b/lib/netdev.c -@@ -791,6 +791,8 @@ static bool +@@ -386,25 +386,30 @@ netdev_open(const char *name, const char *type, struct netdev **netdevp) + ovs_mutex_lock(&netdev_mutex); + netdev = shash_find_data(&netdev_shash, name); + +- if (netdev && +- type && type[0] && strcmp(type, netdev->netdev_class->type)) { +- +- if (netdev->auto_classified) { +- /* If this device was first created without a classification type, +- * for example due to routing or tunneling code, and they keep a +- * reference, a "classified" call to open will fail. In this case +- * we remove the classless device, and re-add it below. We remove +- * the netdev from the shash, and change the sequence, so owners of +- * the old classless device can release/cleanup. */ +- if (netdev->node) { +- shash_delete(&netdev_shash, netdev->node); +- netdev->node = NULL; +- netdev_change_seq_changed(netdev); +- } ++ if (netdev && type && type[0]) { ++ if (strcmp(type, netdev->netdev_class->type)) { ++ ++ if (netdev->auto_classified) { ++ /* If this device was first created without a classification ++ * type, for example due to routing or tunneling code, and they ++ * keep a reference, a "classified" call to open will fail. ++ * In this case we remove the classless device, and re-add it ++ * below. We remove the netdev from the shash, and change the ++ * sequence, so owners of the old classless device can ++ * release/cleanup. */ ++ if (netdev->node) { ++ shash_delete(&netdev_shash, netdev->node); ++ netdev->node = NULL; ++ netdev_change_seq_changed(netdev); ++ } + +- netdev = NULL; +- } else { +- error = EEXIST; ++ netdev = NULL; ++ } else { ++ error = EEXIST; ++ } ++ } else if (netdev->auto_classified) { ++ /* If netdev reopened with type "system", clear auto_classified. */ ++ netdev->auto_classified = false; + } + } + +@@ -791,6 +796,8 @@ static bool netdev_send_prepare_packet(const uint64_t netdev_flags, struct dp_packet *packet, char **errormsg) { @@ -85502,7 +85583,7 @@ index f95b19af4d..8c44eee8e9 100644 if (dp_packet_hwol_is_tso(packet) && !(netdev_flags & NETDEV_TX_OFFLOAD_TCP_TSO)) { /* Fall back to GSO in software. */ -@@ -798,11 +800,31 @@ netdev_send_prepare_packet(const uint64_t netdev_flags, +@@ -798,11 +805,31 @@ netdev_send_prepare_packet(const uint64_t netdev_flags, return false; } @@ -88881,6 +88962,16 @@ index 0be719967d..dcecdab212 100755 import getopt import re import sys +diff --git a/ofproto/libofproto.pc.in b/ofproto/libofproto.pc.in +index 2740712505..49894fb695 100644 +--- a/ofproto/libofproto.pc.in ++++ b/ofproto/libofproto.pc.in +@@ -8,4 +8,4 @@ Description: OpenFlow library of Open vSwitch + Version: @VERSION@ + Libs: -L${libdir} -lofproto + Libs.private: @LIBS@ +-Cflags: -I${includedir}/openvswitch ++Cflags: -I${includedir} diff --git a/ofproto/ofproto-dpif-ipfix.c b/ofproto/ofproto-dpif-ipfix.c index b413768ef0..bdd19de2d4 100644 --- a/ofproto/ofproto-dpif-ipfix.c @@ -90382,6 +90473,16 @@ index 0af077fcec..b86763c422 100644 ovsdb_storage_unread(storage); break; } +diff --git a/ovsdb/libovsdb.pc.in b/ovsdb/libovsdb.pc.in +index fe367ea7b1..54c9039cfd 100644 +--- a/ovsdb/libovsdb.pc.in ++++ b/ovsdb/libovsdb.pc.in +@@ -8,4 +8,4 @@ Description: OVSDB library of Open vSwitch + Version: @VERSION@ + Libs: -L${libdir} -lovsdb + Libs.private: @LIBS@ +-Cflags: -I${includedir}/openvswitch ++Cflags: -I${includedir} diff --git a/ovsdb/log.c b/ovsdb/log.c index c82a79c9ff..f35faadfe0 100644 --- a/ovsdb/log.c @@ -92217,10 +92318,31 @@ index b7252800c1..cfe01763f3 100644 'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.5', diff --git a/rhel/openvswitch-fedora.spec.in b/rhel/openvswitch-fedora.spec.in -index 7bc8c34b80..f6ec347c15 100644 +index 7bc8c34b80..39800400b6 100644 --- a/rhel/openvswitch-fedora.spec.in +++ b/rhel/openvswitch-fedora.spec.in -@@ -318,18 +318,19 @@ exit 0 +@@ -189,20 +189,6 @@ make install DESTDIR=$RPM_BUILD_ROOT + install -d -m 0755 $RPM_BUILD_ROOT%{_rundir}/openvswitch + install -d -m 0750 $RPM_BUILD_ROOT%{_localstatedir}/log/openvswitch + install -d -m 0755 $RPM_BUILD_ROOT%{_sysconfdir}/openvswitch +-copy_headers() { +- src=$1 +- dst=$RPM_BUILD_ROOT/$2 +- install -d -m 0755 $dst +- install -m 0644 $src/*.h $dst +-} +-copy_headers include %{_includedir}/openvswitch +-copy_headers include/openflow %{_includedir}/openvswitch/openflow +-copy_headers include/openvswitch %{_includedir}/openvswitch/openvswitch +-copy_headers include/sparse %{_includedir}/openvswitch/sparse +-copy_headers include/sparse/arpa %{_includedir}/openvswitch/sparse/arpa +-copy_headers include/sparse/netinet %{_includedir}/openvswitch/sparse/netinet +-copy_headers include/sparse/sys %{_includedir}/openvswitch/sparse/sys +-copy_headers lib %{_includedir}/openvswitch/lib + + %if %{with dpdk} + install -p -D -m 0644 rhel/usr_lib_udev_rules.d_91-vfio.rules \ +@@ -318,18 +304,19 @@ exit 0 %post %if %{with libcapng} if [ $1 -eq 1 ]; then @@ -92273,7 +92395,7 @@ index c94f2f5358..15eec6d4c0 100644 if [ -x "%{_datadir}/openvswitch/scripts/ovs-kmod-manage.sh" ]; then %{_datadir}/openvswitch/scripts/ovs-kmod-manage.sh diff --git a/rhel/openvswitch.spec.in b/rhel/openvswitch.spec.in -index b0383ed75e..ee8b3c9eac 100644 +index b0383ed75e..e5e092d11e 100644 --- a/rhel/openvswitch.spec.in +++ b/rhel/openvswitch.spec.in @@ -39,7 +39,7 @@ BuildRequires: checkpolicy, selinux-policy-devel @@ -92285,6 +92407,31 @@ index b0383ed75e..ee8b3c9eac 100644 %bcond_without check %bcond_with check_datapath_kernel +@@ -108,24 +108,6 @@ install -d -m 0755 $RPM_BUILD_ROOT%{_rundir}/openvswitch + install -d -m 0755 $RPM_BUILD_ROOT%{_localstatedir}/log/openvswitch + install -d -m 0755 $RPM_BUILD_ROOT/var/lib/openvswitch + +-copy_headers() { +- src=$1 +- dst=$RPM_BUILD_ROOT/$2 +- install -d -m 0755 $dst +- install -m 0644 $src/*.h $dst +-} +-copy_headers include %{_includedir}/openvswitch +-copy_headers include/openflow %{_includedir}/openvswitch/openflow +-copy_headers include/openvswitch %{_includedir}/openvswitch/openvswitch +-copy_headers include/sparse %{_includedir}/openvswitch/sparse +-copy_headers include/sparse/arpa %{_includedir}/openvswitch/sparse/arpa +-copy_headers include/sparse/netinet %{_includedir}/openvswitch/sparse/netinet +-copy_headers include/sparse/sys %{_includedir}/openvswitch/sparse/sys +-copy_headers lib %{_includedir}/openvswitch/lib +- +-install -D -m 0644 lib/.libs/libopenvswitch.a \ +- $RPM_BUILD_ROOT/%{_libdir}/libopenvswitch.a +- + %check + %if %{with check} + if make check TESTSUITEFLAGS='%{_smp_mflags}' RECHECK=yes; then :; diff --git a/rhel/usr_lib_systemd_system_ovsdb-server.service b/rhel/usr_lib_systemd_system_ovsdb-server.service index 4c170c09b4..98338b9dfb 100644 --- a/rhel/usr_lib_systemd_system_ovsdb-server.service diff --git a/SPECS/openvswitch2.13.spec b/SPECS/openvswitch2.13.spec index 32b2491..f311e63 100644 --- a/SPECS/openvswitch2.13.spec +++ b/SPECS/openvswitch2.13.spec @@ -59,7 +59,7 @@ Summary: Open vSwitch Group: System Environment/Daemons daemon/database/utilities URL: http://www.openvswitch.org/ Version: 2.13.0 -Release: 191%{?commit0:.%{date}git%{shortcommit0}}%{?commit1:dpdk%{shortcommit1}}%{?dist} +Release: 193%{?commit0:.%{date}git%{shortcommit0}}%{?commit1:dpdk%{shortcommit1}}%{?dist} # Nearly all of openvswitch is ASL 2.0. The bugtool is LGPLv2+, and the # lib/sflow*.[ch] files are SISSL @@ -715,6 +715,20 @@ exit 0 %endif %changelog +* Fri Jul 29 2022 Open vSwitch CI - 2.13.0-193 +- Merging upstream branch-2.13 [RH git: 91ba12ea05] + Commit list: + da9b611c3a libopenvswitch.pc: Add missing libs for a static build. + b85d9bc79f rhel: Stop installing internal headers. + + +* Tue Jul 26 2022 Open vSwitch CI - 2.13.0-192 +- Merging upstream branch-2.13 [RH git: 7547aa56c7] + Commit list: + 74070e3559 netdev-linux: Do not touch LAG members if master is not attached to OVS. + 384e7f9501 netdev: Clear auto_classified if netdev reopened with the type specified. + + * Mon Jul 25 2022 Open vSwitch CI - 2.13.0-191 - Merging upstream branch-2.13 [RH git: 7f22841d90] Commit list: