Subject: Revert "batman-adv: Add new include for min/max helpers"
From: Sven Eckelmann <[email-masked]>
Date: Thu, 28 Jan 2021 21:06:51 +0100

The OpenWrt kernel sources and backports sources are currently missing this
header.

This reverts commit 1810de05310d5c5e9140f870ac21052f38bc06b8.

Signed-off-by: Sven Eckelmann <[email-masked]>

diff --git a/compat-include/linux/minmax.h b/compat-include/linux/minmax.h
deleted file mode 100644
index 4b19479bc5ea12c5005485f623decfad90a85cff..0000000000000000000000000000000000000000
--- a/compat-include/linux/minmax.h
+++ /dev/null
@@ -1,20 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-/* Copyright (C) 2007-2020  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_MINMAX_H_
-#define _NET_BATMAN_ADV_COMPAT_LINUX_MINMAX_H_
-
-#include <linux/version.h>
-#if LINUX_VERSION_IS_GEQ(5, 10, 0)
-#include_next <linux/minmax.h>
-#else
-#include <linux/kernel.h>
-#endif
-
-#endif /* _NET_BATMAN_ADV_COMPAT_LINUX_MINMAX_H_ */
diff --git a/net/batman-adv/bat_v.c b/net/batman-adv/bat_v.c
index e4455babe4c28f8c1527a17e825675183c37ea1d..22183e954647089ca72a941e744375d72e1f94b0 100644
--- a/net/batman-adv/bat_v.c
+++ b/net/batman-adv/bat_v.c
@@ -15,7 +15,6 @@
 #include <linux/jiffies.h>
 #include <linux/kref.h>
 #include <linux/list.h>
-#include <linux/minmax.h>
 #include <linux/netdevice.h>
 #include <linux/netlink.h>
 #include <linux/rculist.h>
diff --git a/net/batman-adv/bat_v_elp.c b/net/batman-adv/bat_v_elp.c
index 0512ea6cd818c22768e601f446ff806cf863163b..79a7dfc32e76c511c5b5d8716cbebf64f6228d9d 100644
--- a/net/batman-adv/bat_v_elp.c
+++ b/net/batman-adv/bat_v_elp.c
@@ -18,7 +18,6 @@
 #include <linux/jiffies.h>
 #include <linux/kernel.h>
 #include <linux/kref.h>
-#include <linux/minmax.h>
 #include <linux/netdevice.h>
 #include <linux/nl80211.h>
 #include <linux/prandom.h>
diff --git a/net/batman-adv/bat_v_ogm.c b/net/batman-adv/bat_v_ogm.c
index 798d659855d0bcc9d7638901fedeb77d830f1980..8c1148fc73d776c076bdb35896f5536d7378578d 100644
--- a/net/batman-adv/bat_v_ogm.c
+++ b/net/batman-adv/bat_v_ogm.c
@@ -18,7 +18,6 @@
 #include <linux/kref.h>
 #include <linux/list.h>
 #include <linux/lockdep.h>
-#include <linux/minmax.h>
 #include <linux/mutex.h>
 #include <linux/netdevice.h>
 #include <linux/prandom.h>
diff --git a/net/batman-adv/fragmentation.c b/net/batman-adv/fragmentation.c
index e522f1fcfd9af04ee2d92b1b11ace6960d6f9c9f..ea40e54867573320d44e68524589454db553fb81 100644
--- a/net/batman-adv/fragmentation.c
+++ b/net/batman-adv/fragmentation.c
@@ -14,8 +14,8 @@
 #include <linux/gfp.h>
 #include <linux/if_ether.h>
 #include <linux/jiffies.h>
+#include <linux/kernel.h>
 #include <linux/lockdep.h>
-#include <linux/minmax.h>
 #include <linux/netdevice.h>
 #include <linux/skbuff.h>
 #include <linux/slab.h>
diff --git a/net/batman-adv/hard-interface.c b/net/batman-adv/hard-interface.c
index 0f186ddc15e30a9c9f5e4de44b96b2c7b27d8b86..b57e95c959cf064a74a01d25a24bdc495caa6324 100644
--- a/net/batman-adv/hard-interface.c
+++ b/net/batman-adv/hard-interface.c
@@ -18,7 +18,6 @@
 #include <linux/kref.h>
 #include <linux/limits.h>
 #include <linux/list.h>
-#include <linux/minmax.h>
 #include <linux/mutex.h>
 #include <linux/netdevice.h>
 #include <linux/printk.h>
diff --git a/net/batman-adv/main.c b/net/batman-adv/main.c
index ed9d87ce3407614e5e37922fe3039324adb027cc..edc0d53e9ba0a79ad0c37986e15ec362fb009f4f 100644
--- a/net/batman-adv/main.c
+++ b/net/batman-adv/main.c
@@ -23,7 +23,6 @@
 #include <linux/kobject.h>
 #include <linux/kref.h>
 #include <linux/list.h>
-#include <linux/minmax.h>
 #include <linux/module.h>
 #include <linux/netdevice.h>
 #include <linux/printk.h>
diff --git a/net/batman-adv/netlink.c b/net/batman-adv/netlink.c
index a8f15c04826af1144db655887b754758fc5ab47a..dc193618a761c0b451e860ca83921007d286e09b 100644
--- a/net/batman-adv/netlink.c
+++ b/net/batman-adv/netlink.c
@@ -23,7 +23,6 @@
 #include <linux/kernel.h>
 #include <linux/limits.h>
 #include <linux/list.h>
-#include <linux/minmax.h>
 #include <linux/netdevice.h>
 #include <linux/netlink.h>
 #include <linux/printk.h>
diff --git a/net/batman-adv/tp_meter.c b/net/batman-adv/tp_meter.c
index d4e10005df6cd2936a3132e1ad7bd8bf3c1d99b6..db7e3774825b5f5871b23c0e4fa5ce7afb2accd6 100644
--- a/net/batman-adv/tp_meter.c
+++ b/net/batman-adv/tp_meter.c
@@ -23,7 +23,6 @@
 #include <linux/kthread.h>
 #include <linux/limits.h>
 #include <linux/list.h>
-#include <linux/minmax.h>
 #include <linux/netdevice.h>
 #include <linux/param.h>
 #include <linux/printk.h>