From e8d322e2167f7dc337e41ab53b02ab4e09925c35 Mon Sep 17 00:00:00 2001 From: Sven Eckelmann Date: Sat, 20 Dec 2025 18:34:33 +0100 Subject: [PATCH] batman-adv: drop support for kernels < 6.12 OpenWrt only supports Linux 6.12 at the moment. It is no longer necessary to support older versions of the kernel. Signed-off-by: Sven Eckelmann --- batman-adv/Makefile | 2 +- ...man-adv-Switch-to-linux-array_size.h.patch | 72 ------------------- ...v-move-asm-unaligned.h-to-linux-unal.patch | 49 ------------- batman-adv/src/compat-hacks.h | 6 -- 4 files changed, 1 insertion(+), 128 deletions(-) delete mode 100644 batman-adv/patches/0002-Revert-batman-adv-Switch-to-linux-array_size.h.patch delete mode 100644 batman-adv/patches/0003-Revert-batman-adv-move-asm-unaligned.h-to-linux-unal.patch diff --git a/batman-adv/Makefile b/batman-adv/Makefile index c61ed09..7a8d1d7 100644 --- a/batman-adv/Makefile +++ b/batman-adv/Makefile @@ -4,7 +4,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=batman-adv PKG_VERSION:=2025.5 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://downloads.open-mesh.org/batman/releases/batman-adv-$(PKG_VERSION) diff --git a/batman-adv/patches/0002-Revert-batman-adv-Switch-to-linux-array_size.h.patch b/batman-adv/patches/0002-Revert-batman-adv-Switch-to-linux-array_size.h.patch deleted file mode 100644 index acf6827..0000000 --- a/batman-adv/patches/0002-Revert-batman-adv-Switch-to-linux-array_size.h.patch +++ /dev/null @@ -1,72 +0,0 @@ -From: Sven Eckelmann -Date: Fri, 2 Feb 2024 22:49:48 +0100 -Subject: Revert "batman-adv: Switch to linux/array_size.h" - -The original patch requires Linux 6.7.0 or a mac80211 compat header with this -name. But the mac80211 package is currently not providing this header and -OpenWrt main is still using older Linux kernel versions for some targets. - -This reverts commit f33d7f724675544a36b24c77f8d4b95d41252ae2. - ---- a/compat-include/linux/array_size.h -+++ /dev/null -@@ -1,23 +0,0 @@ --/* SPDX-License-Identifier: GPL-2.0 */ --/* Copyright (C) B.A.T.M.A.N. contributors: -- * -- * Marek Lindner, Simon Wunderlich -- * -- * This file contains macros for maintaining compatibility with older versions -- * of the Linux kernel. -- */ -- --#ifndef _NET_BATMAN_ADV_COMPAT_LINUX_ARRAY_SIZE_H_ --#define _NET_BATMAN_ADV_COMPAT_LINUX_ARRAY_SIZE_H_ -- --#include --#if (LINUX_VERSION_IS_GEQ(5, 15, 197) && LINUX_VERSION_IS_LESS(5, 16, 0)) || \ -- (LINUX_VERSION_IS_GEQ(6, 1, 159) && LINUX_VERSION_IS_LESS(6, 2, 0)) || \ -- (LINUX_VERSION_IS_GEQ(6, 6, 118) && LINUX_VERSION_IS_LESS(6, 7, 0)) || \ -- LINUX_VERSION_IS_GEQ(6, 7, 0) --#include_next --#else --#include --#endif -- --#endif /* _NET_BATMAN_ADV_COMPAT_LINUX_ARRAY_SIZE_H_ */ ---- a/net/batman-adv/main.c -+++ b/net/batman-adv/main.c -@@ -6,7 +6,6 @@ - - #include "main.h" - --#include - #include - #include - #include -@@ -19,6 +18,7 @@ - #include - #include - #include -+#include - #include - #include - #include ---- a/net/batman-adv/netlink.c -+++ b/net/batman-adv/netlink.c -@@ -7,7 +7,6 @@ - #include "netlink.h" - #include "main.h" - --#include - #include - #include - #include -@@ -19,6 +18,7 @@ - #include - #include - #include -+#include - #include - #include - #include diff --git a/batman-adv/patches/0003-Revert-batman-adv-move-asm-unaligned.h-to-linux-unal.patch b/batman-adv/patches/0003-Revert-batman-adv-move-asm-unaligned.h-to-linux-unal.patch deleted file mode 100644 index 1c500c7..0000000 --- a/batman-adv/patches/0003-Revert-batman-adv-move-asm-unaligned.h-to-linux-unal.patch +++ /dev/null @@ -1,49 +0,0 @@ -From: Sven Eckelmann -Date: Tue, 10 Dec 2024 22:31:33 +0100 -Subject: Revert "batman-adv: move asm/unaligned.h to linux/unaligned.h" - -This header is only available with Linux 6.12 - -This reverts commit ee60832ebec47a023d634b06f9434103ec090aed. - ---- a/compat-include/linux/unaligned.h -+++ /dev/null -@@ -1,20 +0,0 @@ --/* SPDX-License-Identifier: GPL-2.0 */ --/* Copyright (C) B.A.T.M.A.N. contributors: -- * -- * Marek Lindner, Simon Wunderlich -- * -- * This file contains macros for maintaining compatibility with older versions -- * of the Linux kernel. -- */ -- --#ifndef _NET_BATMAN_ADV_COMPAT_LINUX_UNALIGNED_H_ --#define _NET_BATMAN_ADV_COMPAT_LINUX_UNALIGNED_H_ -- --#include --#if LINUX_VERSION_IS_GEQ(6, 12, 0) --#include_next --#else --#include --#endif -- --#endif /* _NET_BATMAN_ADV_COMPAT_LINUX_UNALIGNED_H_ */ ---- a/net/batman-adv/distributed-arp-table.c -+++ b/net/batman-adv/distributed-arp-table.c -@@ -7,6 +7,7 @@ - #include "distributed-arp-table.h" - #include "main.h" - -+#include - #include - #include - #include -@@ -32,7 +33,6 @@ - #include - #include - #include --#include - #include - #include - #include diff --git a/batman-adv/src/compat-hacks.h b/batman-adv/src/compat-hacks.h index 3df7042..7b6b116 100644 --- a/batman-adv/src/compat-hacks.h +++ b/batman-adv/src/compat-hacks.h @@ -5,12 +5,6 @@ #include /* LINUX_VERSION_CODE */ #include -#if LINUX_VERSION_IS_LESS(6, 10, 0) - -#define __counted_by_be(member) - -#endif /* LINUX_VERSION_IS_LESS(6, 10, 0) */ - #if LINUX_VERSION_IS_LESS(6, 15, 0) #include #endif /* LINUX_VERSION_IS_LESS(6, 15, 0) */ -- 2.30.2