batman-adv: Drop support for Linux < 4.9
RFC PATCH 1/1 batman-adv: Drop support for Linux < 4.9
The Linux Kernel 4.4 reached its end of life [1] after 6 years. Instead it is recommended to use at least kernel 4.9. It is also over 5 years old but still maintained by the stable kernel team. All older kernels (4.4 - v4.8) will be dropped to reduce the support overhead.
[1] TODO
Signed-off-by Sven Eckelmann <[email protected]>
--- README.external.rst | 2 +- compat-include/linux/cache.h | 22 ------ compat-include/linux/ethtool.h | 51 ------------- compat-include/linux/netdevice.h | 17 +---- compat-include/linux/netlink.h | 102 -------------------------- compat-include/linux/prandom.h | 1 - compat-include/linux/skbuff.h | 15 ---- compat-include/net/cfg80211.h | 18 ----- compat-include/uapi/linux/genetlink.h | 22 ------ 9 files changed, 2 insertions(+), 248 deletions(-) delete mode 100644 compat-include/linux/cache.h delete mode 100644 compat-include/linux/ethtool.h delete mode 100644 compat-include/linux/netlink.h delete mode 100644 compat-include/uapi/linux/genetlink.h
README.external.rst +1 -1
@@ -12,7 +12,7 @@ and as an external module. The external module allows to get new features without upgrading to a newer kernel version and to get batman-adv specific bug fixes for kernels that are not supported anymore. It compiles against and should work -with Linux 4.4 - 5.16. Supporting older versions is not +with Linux 4.9 - 5.16. Supporting older versions is not planned, but it's probably easy to backport it. If you work on a backport, feel free to contact us. :-)
compat-include/linux/cache.h deleted +0 -22
@@ -1,22 +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_CACHE_H -#define _NET_BATMAN_ADV_COMPAT_LINUX_CACHE_H - -#include <linux/version.h> -#include_next <linux/cache.h> - -#if LINUX_VERSION_IS_LESS (4 ,6 ,0 ) - -#define __ro_after_init - -#endif /* LINUX_VERSION_IS_LESS(4, 6, 0) */ - -#endif /* _NET_BATMAN_ADV_COMPAT_LINUX_CACHE_H */
compat-include/linux/ethtool.h deleted +0 -51
51 lines not on this page · raw message
compat-include/linux/netdevice.h +1 -16
@@ -13,28 +13,13 @@#include <linux/version.h> #include_next <linux/netdevice.h> -#if LINUX_VERSION_IS_LESS (4 ,5 ,0 ) - -#define netdev_master_upper_dev_link (dev, upper_dev, upper_priv, upper_info, extack) \ - netdev_master_upper_dev_link(dev, upper_dev) - -#elif LINUX_VERSION_IS_LESS (4 ,15 ,0 ) +#if LINUX_VERSION_IS_LESS (4 ,15 ,0 )#define netdev_master_upper_dev_link (dev, upper_dev, upper_priv, upper_info, extack) \ netdev_master_upper_dev_link(dev, upper_dev, upper_priv, upper_info)#endif /* LINUX_VERSION_IS_LESS(4, 15, 0) */ -#if LINUX_VERSION_IS_LESS (4 ,7 ,0 ) - -#define netif_trans_update batadv_netif_trans_update -static inline void batadv_netif_trans_update (struct net_device *dev) -{ - dev->trans_start = jiffies; -} - -#endif /* LINUX_VERSION_IS_LESS(4, 7, 0) */ -#if LINUX_VERSION_IS_LESS (4 ,11 ,9 )/* work around missing attribute needs_free_netdev and priv_destructor in
compat-include/linux/netlink.h deleted +0 -102
102 lines not on this page · raw message
compat-include/linux/prandom.h +0 -1
@@ -12,7 +12,6 @@#include <linux/version.h> #if LINUX_VERSION_IS_GEQ(5, 8, 1) || \ - (LINUX_VERSION_IS_GEQ(4, 4, 233) && LINUX_VERSION_IS_LESS(4, 5, 0)) || \ (LINUX_VERSION_IS_GEQ(4, 9, 233) && LINUX_VERSION_IS_LESS(4, 10, 0)) || \ (LINUX_VERSION_IS_GEQ(4, 14, 193) && LINUX_VERSION_IS_LESS(4, 15, 0)) || \ (LINUX_VERSION_IS_GEQ(4, 19, 138) && LINUX_VERSION_IS_LESS(4, 20, 0)) || \
compat-include/linux/skbuff.h +0 -15
@@ -13,21 +13,6 @@#include <linux/version.h> #include_next <linux/skbuff.h> -#if LINUX_VERSION_IS_LESS (4 ,5 ,0 ) - -static inline void batadv_skb_postpush_rcsum (struct sk_buff *skb, -const void *start, -unsigned int len) -{ -if (skb->ip_summed ==CHECKSUM_COMPLETE ) - skb->csum =csum_block_add (skb->csum, -csum_partial (start, len,0 ),0 ); -} - -#define skb_postpush_rcsum batadv_skb_postpush_rcsum - -#endif /* LINUX_VERSION_IS_LESS(4, 5, 0) */ -#if LINUX_VERSION_IS_LESS (4 ,13 ,0 )static inline void *batadv_skb_put (struct sk_buff *skb,unsigned int len)
compat-include/net/cfg80211.h +0 -18
@@ -13,24 +13,6 @@#include <linux/version.h> #include_next <net/cfg80211.h> -#if LINUX_VERSION_IS_LESS (4 ,8 ,0 ) - -#if !IS_ENABLED (CONFIG_CFG80211 ) && \ -LINUX_VERSION_IS_GEQ (3 ,16 ,0 ) - -#define cfg80211_get_station (dev, mac_addr, sinfo) \ - batadv_cfg80211_get_station(dev, mac_addr, sinfo) - -static inline int batadv_cfg80211_get_station (struct net_device *dev, -const u8 *mac_addr, -struct station_info *sinfo) -{ -return -ENOENT ; -} -#endif - -#endif /* LINUX_VERSION_IS_LESS(4, 8, 0) */ -#if LINUX_VERSION_IS_LESS (4 ,18 ,0 ) &&IS_ENABLED (CONFIG_CFG80211 )
compat-include/uapi/linux/genetlink.h deleted +0 -22
@@ -1,22 +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_UAPI_LINUX_GENETLINK_H_ -#define _NET_BATMAN_ADV_COMPAT_UAPI_LINUX_GENETLINK_H_ - -#include <linux/version.h> -#include_next <uapi/linux/genetlink.h> - -#if LINUX_VERSION_IS_LESS (4 ,6 ,0 ) - -#define GENL_UNS_ADMIN_PERM GENL_ADMIN_PERM - -#endif /* LINUX_VERSION_IS_LESS(4, 6, 0) */ - -#endif /* _NET_BATMAN_ADV_COMPAT_UAPI_LINUX_GENETLINK_H_ */
Signature · 1 line
2.30.2