Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

erofs: Do not select tristate symbols from bool symbols

The EROFS filesystem has many configurable options, controlled through
boolean Kconfig symbols. When enabled, these options may need to enable
additional library functionality elsewhere. Currently this is done by
selecting the symbol for the additional functionality. However, if
EROFS_FS itself is modular, and the target symbol is a tristate symbol,
the additional functionality is always forced built-in.

Selecting tristate symbols from a tristate symbol does keep modular
transitivity. Hence fix this by moving selects of tristate symbols to
the main EROFS_FS symbol.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>
Link: https://lore.kernel.org/r/da1b899e511145dd43fd2d398f64b2e03c6a39e7.1753879351.git.geert+renesas@glider.be
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>

authored by

Geert Uytterhoeven and committed by
Gao Xiang
74da24f0 c6993c4c

+10 -10
+10 -10
fs/erofs/Kconfig
··· 3 3 config EROFS_FS 4 4 tristate "EROFS filesystem support" 5 5 depends on BLOCK 6 + select CACHEFILES if EROFS_FS_ONDEMAND 6 7 select CRC32 8 + select CRYPTO if EROFS_FS_ZIP_ACCEL 9 + select CRYPTO_DEFLATE if EROFS_FS_ZIP_ACCEL 7 10 select FS_IOMAP 11 + select LZ4_DECOMPRESS if EROFS_FS_ZIP 12 + select NETFS_SUPPORT if EROFS_FS_ONDEMAND 13 + select XXHASH if EROFS_FS_XATTR 14 + select XZ_DEC if EROFS_FS_ZIP_LZMA 15 + select XZ_DEC_MICROLZMA if EROFS_FS_ZIP_LZMA 16 + select ZLIB_INFLATE if EROFS_FS_ZIP_DEFLATE 17 + select ZSTD_DECOMPRESS if EROFS_FS_ZIP_ZSTD 8 18 help 9 19 EROFS (Enhanced Read-Only File System) is a lightweight read-only 10 20 file system with modern designs (e.g. no buffer heads, inline ··· 48 38 config EROFS_FS_XATTR 49 39 bool "EROFS extended attributes" 50 40 depends on EROFS_FS 51 - select XXHASH 52 41 default y 53 42 help 54 43 Extended attributes are name:value pairs associated with inodes by ··· 103 94 config EROFS_FS_ZIP 104 95 bool "EROFS Data Compression Support" 105 96 depends on EROFS_FS 106 - select LZ4_DECOMPRESS 107 97 default y 108 98 help 109 99 Enable transparent compression support for EROFS file systems. ··· 112 104 config EROFS_FS_ZIP_LZMA 113 105 bool "EROFS LZMA compressed data support" 114 106 depends on EROFS_FS_ZIP 115 - select XZ_DEC 116 - select XZ_DEC_MICROLZMA 117 107 help 118 108 Saying Y here includes support for reading EROFS file systems 119 109 containing LZMA compressed data, specifically called microLZMA. It ··· 123 117 config EROFS_FS_ZIP_DEFLATE 124 118 bool "EROFS DEFLATE compressed data support" 125 119 depends on EROFS_FS_ZIP 126 - select ZLIB_INFLATE 127 120 help 128 121 Saying Y here includes support for reading EROFS file systems 129 122 containing DEFLATE compressed data. It gives better compression ··· 137 132 config EROFS_FS_ZIP_ZSTD 138 133 bool "EROFS Zstandard compressed data support" 139 134 depends on EROFS_FS_ZIP 140 - select ZSTD_DECOMPRESS 141 135 help 142 136 Saying Y here includes support for reading EROFS file systems 143 137 containing Zstandard compressed data. It gives better compression ··· 151 147 config EROFS_FS_ZIP_ACCEL 152 148 bool "EROFS hardware decompression support" 153 149 depends on EROFS_FS_ZIP 154 - select CRYPTO 155 - select CRYPTO_DEFLATE 156 150 help 157 151 Saying Y here includes hardware accelerator support for reading 158 152 EROFS file systems containing compressed data. It gives better ··· 165 163 config EROFS_FS_ONDEMAND 166 164 bool "EROFS fscache-based on-demand read support (deprecated)" 167 165 depends on EROFS_FS 168 - select NETFS_SUPPORT 169 166 select FSCACHE 170 - select CACHEFILES 171 167 select CACHEFILES_ONDEMAND 172 168 help 173 169 This permits EROFS to use fscache-backed data blobs with on-demand