[openwrt/openwrt] config: kernel: Add support for configuring BTRFS to be built-in

LEDE Commits lede-commits at lists.infradead.org
Wed Aug 14 15:36:32 PDT 2024


hauke pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/b51abacb5fd465e5ce4329ec27ac516b5a2b83b9

commit b51abacb5fd465e5ce4329ec27ac516b5a2b83b9
Author: Marek Behún <kabel at kernel.org>
AuthorDate: Mon Jul 22 16:57:50 2024 +0200

    config: kernel: Add support for configuring BTRFS to be built-in
    
    Add the KERNEL_BTRFS_FS config option so that targets can select
    whether BTRFS support must be built-in.
    
    Select this option (alongside KERNEL_BTRFS_FS_POSIX_ACL) from the
    layerscape/armv8_64b subtarget instead of enabling it in
    target/linux/layerscape/armv8_64b/config-* files.
    
    Move disabling of CONFIG_BTRFS_FS_CHECK_INTEGRITY into generic configs.
    
    This makes it possible for OpenWRT to be built with built-in BTRFS
    support on specific boards, instead of whole targets.
    
    Signed-off-by: Marek Behún <kabel at kernel.org>
    Link: https://github.com/openwrt/openwrt/pull/15990
    Signed-off-by: Hauke Mehrtens <hauke at hauke-m.de>
---
 config/Config-kernel.in                      | 6 ++++++
 target/linux/generic/config-5.15             | 1 +
 target/linux/generic/config-6.1              | 1 +
 target/linux/generic/config-6.6              | 1 +
 target/linux/layerscape/armv8_64b/config-6.1 | 3 ---
 target/linux/layerscape/armv8_64b/config-6.6 | 3 ---
 target/linux/layerscape/armv8_64b/target.mk  | 1 +
 7 files changed, 10 insertions(+), 6 deletions(-)

diff --git a/config/Config-kernel.in b/config/Config-kernel.in
index 9cedd1df12..73b26b631a 100644
--- a/config/Config-kernel.in
+++ b/config/Config-kernel.in
@@ -1238,6 +1238,12 @@ if KERNEL_IP_PNP
 
 endif
 
+config KERNEL_BTRFS_FS
+	bool "Compile the kernel with built-in BTRFS support"
+	help
+	  Say Y here if you want to make the kernel to be able to boot off a
+	  BTRFS partition.
+
 menu "Filesystem ACL and attr support options"
 	config USE_FS_ACL_ATTR
 		bool "Use filesystem ACL and attr support by default"
diff --git a/target/linux/generic/config-5.15 b/target/linux/generic/config-5.15
index 8e2223aebb..90650ac7dd 100644
--- a/target/linux/generic/config-5.15
+++ b/target/linux/generic/config-5.15
@@ -774,6 +774,7 @@ CONFIG_BROKEN_ON_SMP=y
 # CONFIG_BTRFS_ASSERT is not set
 # CONFIG_BTRFS_DEBUG is not set
 # CONFIG_BTRFS_FS is not set
+# CONFIG_BTRFS_FS_CHECK_INTEGRITY is not set
 # CONFIG_BTRFS_FS_POSIX_ACL is not set
 # CONFIG_BTRFS_FS_REF_VERIFY is not set
 # CONFIG_BTRFS_FS_RUN_SANITY_TESTS is not set
diff --git a/target/linux/generic/config-6.1 b/target/linux/generic/config-6.1
index 1b657ea214..80dcb54683 100644
--- a/target/linux/generic/config-6.1
+++ b/target/linux/generic/config-6.1
@@ -820,6 +820,7 @@ CONFIG_BROKEN_ON_SMP=y
 # CONFIG_BTRFS_ASSERT is not set
 # CONFIG_BTRFS_DEBUG is not set
 # CONFIG_BTRFS_FS is not set
+# CONFIG_BTRFS_FS_CHECK_INTEGRITY is not set
 # CONFIG_BTRFS_FS_POSIX_ACL is not set
 # CONFIG_BTRFS_FS_REF_VERIFY is not set
 # CONFIG_BTRFS_FS_RUN_SANITY_TESTS is not set
diff --git a/target/linux/generic/config-6.6 b/target/linux/generic/config-6.6
index e5c5360608..26651e077c 100644
--- a/target/linux/generic/config-6.6
+++ b/target/linux/generic/config-6.6
@@ -725,6 +725,7 @@ CONFIG_BROKEN_ON_SMP=y
 # CONFIG_BTRFS_ASSERT is not set
 # CONFIG_BTRFS_DEBUG is not set
 # CONFIG_BTRFS_FS is not set
+# CONFIG_BTRFS_FS_CHECK_INTEGRITY is not set
 # CONFIG_BTRFS_FS_POSIX_ACL is not set
 # CONFIG_BTRFS_FS_REF_VERIFY is not set
 # CONFIG_BTRFS_FS_RUN_SANITY_TESTS is not set
diff --git a/target/linux/layerscape/armv8_64b/config-6.1 b/target/linux/layerscape/armv8_64b/config-6.1
index a2a4a633af..2ebe59c7cc 100644
--- a/target/linux/layerscape/armv8_64b/config-6.1
+++ b/target/linux/layerscape/armv8_64b/config-6.1
@@ -104,9 +104,6 @@ CONFIG_BLK_MQ_VIRTIO=y
 CONFIG_BLK_PM=y
 CONFIG_BSD_PROCESS_ACCT=y
 CONFIG_BSD_PROCESS_ACCT_V3=y
-CONFIG_BTRFS_FS=y
-# CONFIG_BTRFS_FS_CHECK_INTEGRITY is not set
-CONFIG_BTRFS_FS_POSIX_ACL=y
 CONFIG_CAVIUM_ERRATUM_22375=y
 CONFIG_CAVIUM_ERRATUM_23144=y
 CONFIG_CAVIUM_ERRATUM_23154=y
diff --git a/target/linux/layerscape/armv8_64b/config-6.6 b/target/linux/layerscape/armv8_64b/config-6.6
index f95b4603be..6d9d2ba2d5 100644
--- a/target/linux/layerscape/armv8_64b/config-6.6
+++ b/target/linux/layerscape/armv8_64b/config-6.6
@@ -105,9 +105,6 @@ CONFIG_BLK_MQ_VIRTIO=y
 CONFIG_BLK_PM=y
 CONFIG_BSD_PROCESS_ACCT=y
 CONFIG_BSD_PROCESS_ACCT_V3=y
-CONFIG_BTRFS_FS=y
-# CONFIG_BTRFS_FS_CHECK_INTEGRITY is not set
-CONFIG_BTRFS_FS_POSIX_ACL=y
 CONFIG_BUFFER_HEAD=y
 CONFIG_BUILTIN_RETURN_ADDRESS_STRIPS_PAC=y
 CONFIG_CAVIUM_ERRATUM_22375=y
diff --git a/target/linux/layerscape/armv8_64b/target.mk b/target/linux/layerscape/armv8_64b/target.mk
index c9a61701a9..d880afa7a3 100644
--- a/target/linux/layerscape/armv8_64b/target.mk
+++ b/target/linux/layerscape/armv8_64b/target.mk
@@ -5,6 +5,7 @@
 ARCH:=aarch64
 BOARDNAME:=ARMv8 64-bit based boards
 KERNELNAME:=Image dtbs
+DEPENDS:=+ at KERNEL_BTRFS_FS + at KERNEL_BTRFS_FS_POSIX_ACL
 
 define Target/Description
 	Build firmware images for NXP Layerscape ARMv8 64-bit based boards.




More information about the lede-commits mailing list