iproute2: update to 6.11.0
authorHauke Mehrtens <hauke@hauke-m.de>
Thu, 3 Oct 2024 19:51:54 +0000 (21:51 +0200)
committerHauke Mehrtens <hauke@hauke-m.de>
Sat, 5 Oct 2024 10:39:13 +0000 (12:39 +0200)
Release Notes:
https://lore.kernel.org/netdev/20240717090601.20b2871f@hermes.local/T/
https://lwn.net/Articles/990423/

Remove patch `401-bridge-vlan.c-bridge-vlan.c-fix-build-with-gcc-14-on.patch`
because it is upstream now.

Backport two patches to fix build problems in bridge/mst.c

Small size increase:
 38538 bin/packages/mips_24kc-old/base/devlink_6.9.0-r1_mips_24kc.ipk
  7713 bin/packages/mips_24kc-old/base/genl_6.9.0-r1_mips_24kc.ipk
 31875 bin/packages/mips_24kc-old/base/ip-bridge_6.9.0-r1_mips_24kc.ipk
187733 bin/packages/mips_24kc-old/base/ip-full_6.9.0-r1_mips_24kc.ipk
126538 bin/packages/mips_24kc-old/base/ip-tiny_6.9.0-r1_mips_24kc.ipk
  7619 bin/packages/mips_24kc-old/base/nstat_6.9.0-r1_mips_24kc.ipk
 20704 bin/packages/mips_24kc-old/base/rdma_6.9.0-r1_mips_24kc.ipk
 37607 bin/packages/mips_24kc-old/base/ss_6.9.0-r1_mips_24kc.ipk
158909 bin/packages/mips_24kc-old/base/tc-bpf_6.9.0-r1_mips_24kc.ipk
160459 bin/packages/mips_24kc-old/base/tc-full_6.9.0-r1_mips_24kc.ipk
135846 bin/packages/mips_24kc-old/base/tc-tiny_6.9.0-r1_mips_24kc.ipk
 38669 bin/packages/mips_24kc-new/base/devlink_6.11.0-r1_mips_24kc.ipk
  7719 bin/packages/mips_24kc-new/base/genl_6.11.0-r1_mips_24kc.ipk
 32676 bin/packages/mips_24kc-new/base/ip-bridge_6.11.0-r1_mips_24kc.ipk
188920 bin/packages/mips_24kc-new/base/ip-full_6.11.0-r1_mips_24kc.ipk
127313 bin/packages/mips_24kc-new/base/ip-tiny_6.11.0-r1_mips_24kc.ipk
  7612 bin/packages/mips_24kc-new/base/nstat_6.11.0-r1_mips_24kc.ipk
 21065 bin/packages/mips_24kc-new/base/rdma_6.11.0-r1_mips_24kc.ipk
 37726 bin/packages/mips_24kc-new/base/ss_6.11.0-r1_mips_24kc.ipk
158921 bin/packages/mips_24kc-new/base/tc-bpf_6.11.0-r1_mips_24kc.ipk
160510 bin/packages/mips_24kc-new/base/tc-full_6.11.0-r1_mips_24kc.ipk
136352 bin/packages/mips_24kc-new/base/tc-tiny_6.11.0-r1_mips_24kc.ipk

Link: https://github.com/openwrt/openwrt/pull/16589
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
package/network/utils/iproute2/Makefile
package/network/utils/iproute2/patches/010-bridge-mst-fix-a-musl-build-issue.patch [new file with mode: 0644]
package/network/utils/iproute2/patches/011-bridge-mst-fix-a-further-musl-build-issue.patch [new file with mode: 0644]
package/network/utils/iproute2/patches/140-keep_libmnl_optional.patch
package/network/utils/iproute2/patches/150-keep_libcap_optional.patch
package/network/utils/iproute2/patches/155-keep_tirpc_optional.patch
package/network/utils/iproute2/patches/200-drop_libbsd_dependency.patch
package/network/utils/iproute2/patches/300-selinux-configurable.patch
package/network/utils/iproute2/patches/401-bridge-vlan.c-bridge-vlan.c-fix-build-with-gcc-14-on.patch [deleted file]

index 85d9f437f63e6b7a570deb2b5a52c2bd7dcfba06..04a4df24c9904576813741c2946ca783da569209 100644 (file)
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=iproute2
-PKG_VERSION:=6.9.0
+PKG_VERSION:=6.11.0
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=@KERNEL/linux/utils/net/iproute2
-PKG_HASH:=2f643d09ea11a4a2a043c92e2b469b5f73228cbf241ae806760296ed0ec413d0
+PKG_HASH:=1f795398a04aeaacd06a8f6ace2cfd913c33fa5953ca99daae83bb5c534611c3
 PKG_BUILD_PARALLEL:=1
 PKG_BUILD_DEPENDS:=iptables
 PKG_LICENSE:=GPL-2.0
diff --git a/package/network/utils/iproute2/patches/010-bridge-mst-fix-a-musl-build-issue.patch b/package/network/utils/iproute2/patches/010-bridge-mst-fix-a-musl-build-issue.patch
new file mode 100644 (file)
index 0000000..1630415
--- /dev/null
@@ -0,0 +1,68 @@
+From 6a77abab92516e65f07f8657fc4e384c4541ce0e Mon Sep 17 00:00:00 2001
+From: Dario Binacchi <dario.binacchi@amarulasolutions.com>
+Date: Sun, 22 Sep 2024 16:50:10 +0200
+Subject: bridge: mst: fix a musl build issue
+
+This patch fixes a compilation error raised by the bump to version 6.11.0
+in Buildroot using musl as the C library for the cross-compilation
+toolchain.
+
+After setting the CFLGAS
+
+ifeq ($(BR2_TOOLCHAIN_USES_MUSL),y)
+IPROUTE2_CFLAGS += -D__UAPI_DEF_IN6_ADDR=0 -D__UAPI_DEF_SOCKADDR_IN6=0 \
+                       -D__UAPI_DEF_IPV6_MREQ=0
+endif
+
+to fix the following errors:
+
+In file included from ../../../host/mips64-buildroot-linux-musl/sysroot/usr/include/arpa/inet.h:9,
+                 from ../include/libnetlink.h:14,
+                 from mst.c:10:
+../../../host/mips64-buildroot-linux-musl/sysroot/usr/include/netinet/in.h:23:8: error: redefinition of 'struct in6_addr'
+   23 | struct in6_addr {
+      |        ^~~~~~~~
+In file included from ../include/uapi/linux/if_bridge.h:19,
+                 from mst.c:7:
+../include/uapi/linux/in6.h:33:8: note: originally defined here
+   33 | struct in6_addr {
+      |        ^~~~~~~~
+../../../host/mips64-buildroot-linux-musl/sysroot/usr/include/netinet/in.h:34:8: error: redefinition of 'struct sockaddr_in6'
+   34 | struct sockaddr_in6 {
+      |        ^~~~~~~~~~~~
+../include/uapi/linux/in6.h:50:8: note: originally defined here
+   50 | struct sockaddr_in6 {
+      |        ^~~~~~~~~~~~
+../../../host/mips64-buildroot-linux-musl/sysroot/usr/include/netinet/in.h:42:8: error: redefinition of 'struct ipv6_mreq'
+   42 | struct ipv6_mreq {
+      |        ^~~~~~~~~
+../include/uapi/linux/in6.h:60:8: note: originally defined here
+   60 | struct ipv6_mreq {
+
+I got this further errors
+
+../include/uapi/linux/in6.h:72:25: error: field 'flr_dst' has incomplete type
+   72 |         struct in6_addr flr_dst;
+      |                         ^~~~~~~
+../include/uapi/linux/if_bridge.h:711:41: error: field 'ip6' has incomplete type
+  711 |                         struct in6_addr ip6;
+      |                                         ^~~
+
+fixed by including the netinet/in.h header.
+
+Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
+Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
+---
+ bridge/mst.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/bridge/mst.c
++++ b/bridge/mst.c
+@@ -4,6 +4,7 @@
+  */
+ #include <stdio.h>
++#include <netinet/in.h>
+ #include <linux/if_bridge.h>
+ #include <net/if.h>
diff --git a/package/network/utils/iproute2/patches/011-bridge-mst-fix-a-further-musl-build-issue.patch b/package/network/utils/iproute2/patches/011-bridge-mst-fix-a-further-musl-build-issue.patch
new file mode 100644 (file)
index 0000000..1bdab39
--- /dev/null
@@ -0,0 +1,51 @@
+From 043ef90e2fa94397eb5c85330889ca4146a6d58a Mon Sep 17 00:00:00 2001
+From: Dario Binacchi <dario.binacchi@amarulasolutions.com>
+Date: Sun, 22 Sep 2024 16:50:11 +0200
+Subject: bridge: mst: fix a further musl build issue
+
+This patch fixes the following build errors:
+
+In file included from mst.c:11:
+../include/json_print.h:80:30: warning: 'struct timeval' declared inside parameter list will not be visible outside of this definition or declaration
+   80 | _PRINT_FUNC(tv, const struct timeval *)
+      |                              ^~~~~~~
+../include/json_print.h:50:37: note: in definition of macro '_PRINT_FUNC'
+   50 |                                     type value);                        \
+      |                                     ^~~~
+../include/json_print.h:80:30: warning: 'struct timeval' declared inside parameter list will not be visible outside of this definition or declaration
+   80 | _PRINT_FUNC(tv, const struct timeval *)
+      |                              ^~~~~~~
+../include/json_print.h:55:45: note: in definition of macro '_PRINT_FUNC'
+   55 |                                             type value)                 \
+      |                                             ^~~~
+../include/json_print.h: In function 'print_tv':
+../include/json_print.h:58:48: error: passing argument 5 of 'print_color_tv' from incompatible pointer type [-Wincompatible-pointer-types]
+   58 |                                                value);                  \
+      |                                                ^~~~~
+      |                                                |
+      |                                                const struct timeval *
+../include/json_print.h:80:1: note: in expansion of macro '_PRINT_FUNC'
+   80 | _PRINT_FUNC(tv, const struct timeval *)
+      | ^~~~~~~~~~~
+../include/json_print.h:50:42: note: expected 'const struct timeval *' but argument is of type 'const struct timeval *'
+   50 |                                     type value);                        \
+      |                                          ^
+../include/json_print.h:80:1: note: in expansion of macro '_PRINT_FUNC'
+   80 | _PRINT_FUNC(tv, const struct timeval *)
+
+Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
+Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
+---
+ bridge/mst.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/bridge/mst.c
++++ b/bridge/mst.c
+@@ -4,6 +4,7 @@
+  */
+ #include <stdio.h>
++#include <sys/time.h>
+ #include <netinet/in.h>
+ #include <linux/if_bridge.h>
+ #include <net/if.h>
index ee18f17d54f00e8f18d891ff0aabbc970f6052e5..48a4ae75196fe141802c931973531adf8ada1dd4 100644 (file)
@@ -1,6 +1,6 @@
 --- a/configure
 +++ b/configure
-@@ -362,7 +362,7 @@ check_tirpc()
+@@ -368,7 +368,7 @@ check_tirpc()
  
  check_mnl()
  {
index 767c968e74c289455f4b3b6abb5e33007686a4e6..49873f87b16e883c20b62c5148cec28ebec5fdea 100644 (file)
@@ -1,6 +1,6 @@
 --- a/configure
 +++ b/configure
-@@ -421,7 +421,7 @@ EOF
+@@ -427,7 +427,7 @@ EOF
  
  check_cap()
  {
index 011dd48f8e14f355bb640a2de319d66de86e84e7..9e5e4330cf8707eb358c771e7847263490b28832 100644 (file)
@@ -1,6 +1,6 @@
 --- a/configure
 +++ b/configure
-@@ -349,7 +349,7 @@ check_selinux()
+@@ -355,7 +355,7 @@ check_selinux()
  
  check_tirpc()
  {
index e41be20f108f8eb64732f5951ddb26120474d131..38193be156bd0223d32166b217f92a7748d2ea61 100644 (file)
@@ -1,6 +1,6 @@
 --- a/configure
 +++ b/configure
-@@ -407,14 +407,8 @@ EOF
+@@ -413,14 +413,8 @@ EOF
      if $CC -I$INCLUDE -o $TMPDIR/strtest $TMPDIR/strtest.c >/dev/null 2>&1; then
        echo "no"
      else
index 36ecc735a74d4a7a44ae23fa4d4c8680619dfb71..9f07d31768fdf69cde59b1e11c66437622827b3a 100644 (file)
@@ -1,6 +1,6 @@
 --- a/configure
 +++ b/configure
-@@ -336,7 +336,7 @@ check_libbpf()
+@@ -342,7 +342,7 @@ check_libbpf()
  check_selinux()
  # SELinux is a compile time option in the ss utility
  {
diff --git a/package/network/utils/iproute2/patches/401-bridge-vlan.c-bridge-vlan.c-fix-build-with-gcc-14-on.patch b/package/network/utils/iproute2/patches/401-bridge-vlan.c-bridge-vlan.c-fix-build-with-gcc-14-on.patch
deleted file mode 100644 (file)
index a90c9fc..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-From 53a89bfd86fff1a00cc77cabb8457a03eaa3bc7d Mon Sep 17 00:00:00 2001
-From: Gabi Falk <gabifalk@gmx.com>
-Date: Fri, 10 May 2024 14:36:12 +0000
-Subject: [PATCH] bridge/vlan.c: bridge/vlan.c: fix build with gcc 14 on musl
- systems
-
-On glibc based systems the definition of 'struct timeval' is pulled in
-with inclusion of <stdlib.h> header, but on musl based systems it
-doesn't work this way.  Missing definition triggers an
-incompatible-pointer-types error with gcc 14 (warning on previous
-versions of gcc):
-
-../include/json_print.h:80:30: warning: 'struct timeval' declared inside parameter list will not be visible outside of this definition or declaration
-   80 | _PRINT_FUNC(tv, const struct timeval *)
-      |                              ^~~~~~~
-../include/json_print.h:50:37: note: in definition of macro '_PRINT_FUNC'
-   50 |                                     type value);                        \
-      |                                     ^~~~
-../include/json_print.h:80:30: warning: 'struct timeval' declared inside parameter list will not be visible outside of this definition or declaration
-   80 | _PRINT_FUNC(tv, const struct timeval *)
-      |                              ^~~~~~~
-../include/json_print.h:55:45: note: in definition of macro '_PRINT_FUNC'
-   55 |                                             type value)                 \
-      |                                             ^~~~
-../include/json_print.h: In function 'print_tv':
-../include/json_print.h:58:48: error: passing argument 5 of 'print_color_tv' from incompatible pointer type [-Wincompatible-pointer-types]
-   58 |                                                value);                  \
-      |                                                ^~~~~
-      |                                                |
-      |                                                const struct timeval *
-
-Signed-off-by: Gabi Falk <gabifalk@gmx.com>
-Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
----
- bridge/vlan.c | 1 +
- bridge/vni.c  | 1 +
- vdpa/vdpa.c   | 1 +
- 3 files changed, 3 insertions(+)
-
---- a/bridge/vlan.c
-+++ b/bridge/vlan.c
-@@ -4,6 +4,7 @@
- #include <unistd.h>
- #include <fcntl.h>
- #include <sys/socket.h>
-+#include <sys/time.h>
- #include <net/if.h>
- #include <netinet/in.h>
- #include <linux/if_bridge.h>
---- a/bridge/vni.c
-+++ b/bridge/vni.c
-@@ -10,6 +10,7 @@
- #include <string.h>
- #include <fcntl.h>
- #include <sys/socket.h>
-+#include <sys/time.h>
- #include <net/if.h>
- #include <netinet/in.h>
- #include <linux/if_link.h>
---- a/vdpa/vdpa.c
-+++ b/vdpa/vdpa.c
-@@ -3,6 +3,7 @@
- #include <stdio.h>
- #include <getopt.h>
- #include <errno.h>
-+#include <sys/time.h>
- #include <linux/genetlink.h>
- #include <linux/if_ether.h>
- #include <linux/vdpa.h>