From ec9d4a6c42311b3f1ef4edfda9d00765b285c420 Mon Sep 17 00:00:00 2001 From: Sven Eckelmann Date: Sat, 27 Jul 2019 21:52:58 +0200 Subject: [PATCH] batmand: Drop batgat kernel module This kernel module is broken since 2013 and doesn't build. It can therefore be removed. Signed-off-by: Sven Eckelmann --- batmand/Makefile | 48 ++------------------------------ batmand/patches/100-2.6.36.patch | 47 ------------------------------- 2 files changed, 2 insertions(+), 93 deletions(-) delete mode 100644 batmand/patches/100-2.6.36.patch diff --git a/batmand/Makefile b/batmand/Makefile index 77497ab..b8520b9 100644 --- a/batmand/Makefile +++ b/batmand/Makefile @@ -6,7 +6,6 @@ # include $(TOPDIR)/rules.mk -include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=batmand @@ -25,17 +24,11 @@ PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_SOURCE_SUBDIR) PKG_EXTRA_CFLAGS=-DDEBUG_MALLOC -DMEMORY_USAGE -DPROFILE_DATA -DREVISION_VERSION=\"\ rv$(PKG_REV)\" -D_GNU_SOURCE -PKG_KMOD_BUILD_DIR:=$(PKG_BUILD_DIR)/linux/modules - include $(INCLUDE_DIR)/package.mk -define Package/batmand/Default +define Package/batmand URL:=https://www.open-mesh.org/ MAINTAINER:=Corinna "Elektra" Aichele -endef - -define Package/batmand -$(call Package/batmand/Default) SECTION:=net CATEGORY:=Network SUBMENU:=Routing and Redirection @@ -47,20 +40,6 @@ define Package/batmand/description B.A.T.M.A.N. layer 3 routing daemon endef -define KernelPackage/batgat -$(call Package/batmand/Default) - SUBMENU:=Network Support - DEPENDS:=+batmand @BROKEN - TITLE:=B.A.T.M.A.N. gateway module - FILES:=$(PKG_KMOD_BUILD_DIR)/batgat.$(LINUX_KMOD_SUFFIX) - AUTOLOAD:=$(call AutoLoad,50,batgat) -endef - - -define KernelPackage/batgat/description -Kernel gateway module for B.A.T.M.A.N. for better tunnel performance -endef - MAKE_BATMAND_ARGS += \ EXTRA_CFLAGS='$(TARGET_CFLAGS) $(PKG_EXTRA_CFLAGS)' \ CCFLAGS="$(TARGET_CFLAGS)" \ @@ -73,30 +52,8 @@ MAKE_BATMAND_ARGS += \ STRIP="/bin/true" \ batmand install -MAKE_BATGAT_ARGS += \ - CROSS_COMPILE="$(TARGET_CROSS)" \ - ARCH="$(LINUX_KARCH)" \ - PATH="$(TARGET_PATH)" \ - SUBDIRS="$(PKG_KMOD_BUILD_DIR)" \ - LINUX_VERSION="$(LINUX_VERSION)" \ - REVISION="$(PKG_REV)" modules - - -define Build/Configure -endef - -ifneq ($(DEVELOPER)$(CONFIG_PACKAGE_batmand),) - BUILD_BATMAND := $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_BATMAND_ARGS) -endif - -ifneq ($(DEVELOPER)$(CONFIG_PACKAGE_kmod-batgat),) - BUILD_BATGAT := $(MAKE) -C "$(LINUX_DIR)" $(MAKE_BATGAT_ARGS) -endif - define Build/Compile - $(BUILD_BATMAND) - cp $(PKG_KMOD_BUILD_DIR)/Makefile.kbuild $(PKG_KMOD_BUILD_DIR)/Makefile - $(BUILD_BATGAT) + $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_BATMAND_ARGS) endef define Package/batmand/install @@ -111,4 +68,3 @@ define Package/batmand/conffiles endef $(eval $(call BuildPackage,batmand)) -$(eval $(call KernelPackage,batgat)) diff --git a/batmand/patches/100-2.6.36.patch b/batmand/patches/100-2.6.36.patch deleted file mode 100644 index 13318e0..0000000 --- a/batmand/patches/100-2.6.36.patch +++ /dev/null @@ -1,47 +0,0 @@ ---- - batman/linux/modules/gateway.c | 19 +++++++++++++++++++ - 1 file changed, 19 insertions(+) - ---- batmand-r1439.orig/linux/modules/gateway.c -+++ batmand-r1439/linux/modules/gateway.c -@@ -29,6 +29,7 @@ static struct class *batman_class; - static int batgat_open(struct inode *inode, struct file *filp); - static int batgat_release(struct inode *inode, struct file *file); - static int batgat_ioctl( struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg ); -+static long batgat_ioctl_unlocked(struct file *file, unsigned int cmd, unsigned long arg ); - - - static void udp_data_ready(struct sock *sk, int len); -@@ -53,7 +54,11 @@ static int proc_clients_read(char *buf, - static struct file_operations fops = { - .open = batgat_open, - .release = batgat_release, -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36) -+ .unlocked_ioctl = batgat_ioctl_unlocked, -+#else - .ioctl = batgat_ioctl, -+#endif - }; - - -@@ -166,6 +171,20 @@ static int batgat_release(struct inode * - } - - -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36) -+#include -+static long batgat_ioctl_unlocked(struct file *file, unsigned int cmd, unsigned long arg ) -+{ -+ int ret; -+ -+ lock_kernel(); -+ ret = batgat_ioctl(file->f_path.dentry->d_inode, file, cmd, arg); -+ unlock_kernel(); -+ -+ return ret; -+} -+#endif -+ - static int batgat_ioctl( struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg ) - { - uint8_t tmp_ip[4]; -- 2.30.2