From 42a4fbe4a4fda8b61a1cec0762957872511f6527 Mon Sep 17 00:00:00 2001 From: Josef Schlehofer Date: Thu, 23 Feb 2023 07:52:01 +0100 Subject: [PATCH 1/2] antfs: drop this kernel package Reasons to remove this package: 1. It is not available for Linux kernel 5.15 and onwards. 2. It seems that it is not maintained as the original repository was done in 2018 and then the forked repository was done to have this merged only to OpenWrt. 3. Anyone can use ntfs-3g (fuse) or ntfs3 from Paragon, which has been available since Linux kernel 5.15 4. Nobody said why this package was necessary or required to be added here or what was the difference between driver(s) in the Linux kernel and this package. 5. No project home page, no documentation, only source code provided by AVM Signed-off-by: Josef Schlehofer --- kernel/antfs/Makefile | 44 ------------------- .../0001-file.c-Patch-for-Linux-v5.8.patch | 40 ----------------- 2 files changed, 84 deletions(-) delete mode 100644 kernel/antfs/Makefile delete mode 100644 kernel/antfs/patches/0001-file.c-Patch-for-Linux-v5.8.patch diff --git a/kernel/antfs/Makefile b/kernel/antfs/Makefile deleted file mode 100644 index 1137b5bd8..000000000 --- a/kernel/antfs/Makefile +++ /dev/null @@ -1,44 +0,0 @@ -include $(TOPDIR)/rules.mk -include $(INCLUDE_DIR)/kernel.mk - -PKG_NAME:=antfs -PKG_RELEASE:=2 - -PKG_SOURCE_URL:=https://github.com/klukonin/antfs.git -PKG_SOURCE_PROTO:=git -PKG_SOURCE_DATE:=2020-02-10 -PKG_SOURCE_VERSION:=b41ba529f6b64b429527e09a06ce0326d5456c05 -PKG_MIRROR_HASH:=dae039c0fe5bf1a2c8c1cca4211d607a4d6f56fc41b38444e2234b40d710d9db - -PKG_LICENSE:=GPL-2.0-or-later -PKG_LICENSE_FILES:=LICENSE - -include $(INCLUDE_DIR)/package.mk - -define KernelPackage/fs-antfs - SUBMENU:=Filesystems - TITLE:=AVM NTFS Read/Write Driver - FILES:=$(PKG_BUILD_DIR)/antfs.ko - AUTOLOAD:=$(call AutoLoad,30,antfs,1) - DEPENDS:=+kmod-nls-base @LINUX_5_10 -endef - -define KernelPackage/fs-antfs/description - Kernel module for NTFS Filesytem -endef - -MAKE_OPTS:= \ - ARCH="$(LINUX_KARCH)" \ - CROSS_COMPILE="$(TARGET_CROSS)" \ - M="$(PKG_BUILD_DIR)" - -define Build/Compile - $(MAKE) -C "$(LINUX_DIR)" \ - $(MAKE_OPTS) \ - CONFIG_ANTFS_FS=m \ - CONFIG_ANTFS_SYMLINKS=y \ - ANTFS_VERSION=07.19-$(call version_abbrev,$(PKG_SOURCE_VERSION)) \ - modules -endef - -$(eval $(call KernelPackage,fs-antfs)) diff --git a/kernel/antfs/patches/0001-file.c-Patch-for-Linux-v5.8.patch b/kernel/antfs/patches/0001-file.c-Patch-for-Linux-v5.8.patch deleted file mode 100644 index ed17550d3..000000000 --- a/kernel/antfs/patches/0001-file.c-Patch-for-Linux-v5.8.patch +++ /dev/null @@ -1,40 +0,0 @@ ---- a/file.c -+++ b/file.c -@@ -625,6 +625,9 @@ static int antfs_readpages(struct file * - unsigned page_idx = nr_pages; - pgoff_t page_idx_to_init; - bool do_init_page = false; -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 8, 0) -+ DEFINE_READAHEAD(rac, file, mapping, 0); -+#endif - - if (page_offs & (buffer_len - 1)) { - /* If initialized size is not on buffer boundary, walk -@@ -660,8 +663,13 @@ static int antfs_readpages(struct file * - } - } - -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 8, 0) -+ mpage_readahead(&rac, antfs_get_block); -+ err = 0; -+#else - err = mpage_readpages(mapping, pages, nr_pages, - antfs_get_block); -+#endif - if (!err && do_init_page) { - /* Initialize stuff past initialized_size with zero. */ - page = grab_cache_page(mapping, page_idx_to_init); ---- a/libntfs-3g/misc.c -+++ b/libntfs-3g/misc.c -@@ -38,7 +38,11 @@ void *ntfs_malloc(size_t size) - return kmalloc(size, GFP_KERNEL); - } - -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 8, 0) -+ return __vmalloc(size, GFP_KERNEL); -+#else - return __vmalloc(size, GFP_KERNEL, PAGE_KERNEL); -+#endif - } - - /** From 8027ea5c0ff02535c3665fa430774f721f58634f Mon Sep 17 00:00:00 2001 From: Josef Schlehofer Date: Thu, 23 Feb 2023 07:56:04 +0100 Subject: [PATCH 2/2] antfs-mount: drop Since kernel module was dropped, check the reasons why it was removed in the commit 42a4fbe4a4fda8b61a1cec0762957872511f6527 (" antfs: drop this kernel package"), then this package should be removed, too as the dependency was removed and without it, it is not useful Signed-off-by: Josef Schlehofer --- utils/antfs-mount/Makefile | 28 ---------------------------- utils/antfs-mount/files/mount.ntfs | 2 -- 2 files changed, 30 deletions(-) delete mode 100644 utils/antfs-mount/Makefile delete mode 100644 utils/antfs-mount/files/mount.ntfs diff --git a/utils/antfs-mount/Makefile b/utils/antfs-mount/Makefile deleted file mode 100644 index 48ffc6f1c..000000000 --- a/utils/antfs-mount/Makefile +++ /dev/null @@ -1,28 +0,0 @@ -include $(TOPDIR)/rules.mk - -PKG_NAME:=antfs-mount -PKG_RELEASE:=1 - -include $(INCLUDE_DIR)/package.mk - -define Package/antfs-mount - SECTION:=utils - CATEGORY:=Utilities - SUBMENU:=Filesystem - TITLE:=NTFS mount script for AVM NTFS driver - PKGARCH:=all - DEPENDS:=+kmod-fs-antfs -endef - -define Build/Configure -endef - -define Build/Compile -endef - -define Package/antfs-mount/install - $(INSTALL_DIR) $(1)/sbin - $(INSTALL_BIN) ./files/mount.ntfs $(1)/sbin -endef - -$(eval $(call BuildPackage,antfs-mount)) diff --git a/utils/antfs-mount/files/mount.ntfs b/utils/antfs-mount/files/mount.ntfs deleted file mode 100644 index e97709aec..000000000 --- a/utils/antfs-mount/files/mount.ntfs +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -mount -t antfs "$@"