235 lines · plain
1# SPDX-License-Identifier: GPL-2.02#3# Block layer core configuration4#5menuconfig BLOCK6 bool "Enable the block layer" if EXPERT7 default y8 select FS_IOMAP9 select SBITMAP10 help11 Provide block layer support for the kernel.12 13 Disable this option to remove the block layer support from the14 kernel. This may be useful for embedded devices.15 16 If this option is disabled:17 18 - block device files will become unusable19 - some filesystems (such as ext3) will become unavailable.20 21 Also, SCSI character devices and USB storage will be disabled since22 they make use of various block layer definitions and facilities.23 24 Say Y here unless you know you really don't want to mount disks and25 suchlike.26 27if BLOCK28 29config BLOCK_LEGACY_AUTOLOAD30 bool "Legacy autoloading support"31 default y32 help33 Enable loading modules and creating block device instances based on34 accesses through their device special file. This is a historic Linux35 feature and makes no sense in a udev world where device files are36 created on demand, but scripts that manually create device nodes and37 then call losetup might rely on this behavior.38 39config BLK_RQ_ALLOC_TIME40 bool41 42config BLK_CGROUP_RWSTAT43 bool44 45config BLK_CGROUP_PUNT_BIO46 bool47 48config BLK_DEV_BSG_COMMON49 tristate50 51config BLK_ICQ52 bool53 54config BLK_DEV_BSGLIB55 bool "Block layer SG support v4 helper lib"56 select BLK_DEV_BSG_COMMON57 help58 Subsystems will normally enable this if needed. Users will not59 normally need to manually enable this.60 61 If unsure, say N.62 63config BLK_DEV_INTEGRITY64 bool "Block layer data integrity support"65 select CRC_T10DIF66 select CRC64_ROCKSOFT67 help68 Some storage devices allow extra information to be69 stored/retrieved to help protect the data. The block layer70 data integrity option provides hooks which can be used by71 filesystems to ensure better data integrity.72 73 Say yes here if you have a storage device that provides the74 T10/SCSI Data Integrity Field or the T13/ATA External Path75 Protection. If in doubt, say N.76 77config BLK_DEV_WRITE_MOUNTED78 bool "Allow writing to mounted block devices"79 default y80 help81 When a block device is mounted, writing to its buffer cache is very82 likely going to cause filesystem corruption. It is also rather easy to83 crash the kernel in this way since the filesystem has no practical way84 of detecting these writes to buffer cache and verifying its metadata85 integrity. However there are some setups that need this capability86 like running fsck on read-only mounted root device, modifying some87 features on mounted ext4 filesystem, and similar. If you say N, the88 kernel will prevent processes from writing to block devices that are89 mounted by filesystems which provides some more protection from runaway90 privileged processes and generally makes it much harder to crash91 filesystem drivers. Note however that this does not prevent92 underlying device(s) from being modified by other means, e.g. by93 directly submitting SCSI commands or through access to lower layers of94 storage stack. If in doubt, say Y. The configuration can be overridden95 with the bdev_allow_write_mounted boot option.96 97config BLK_DEV_ZONED98 bool "Zoned block device support"99 help100 Block layer zoned block device support. This option enables101 support for ZAC/ZBC/ZNS host-managed and host-aware zoned block102 devices.103 104 Say yes here if you have a ZAC, ZBC, or ZNS storage device.105 106config BLK_DEV_THROTTLING107 bool "Block layer bio throttling support"108 depends on BLK_CGROUP109 select BLK_CGROUP_RWSTAT110 help111 Block layer bio throttling support. It can be used to limit112 the IO rate to a device. IO rate policies are per cgroup and113 one needs to mount and use blkio cgroup controller for creating114 cgroups and specifying per device IO rate policies.115 116 See Documentation/admin-guide/cgroup-v1/blkio-controller.rst for more information.117 118config BLK_WBT119 bool "Enable support for block device writeback throttling"120 help121 Enabling this option enables the block layer to throttle buffered122 background writeback from the VM, making it more smooth and having123 less impact on foreground operations. The throttling is done124 dynamically on an algorithm loosely based on CoDel, factoring in125 the realtime performance of the disk.126 127config BLK_WBT_MQ128 bool "Enable writeback throttling by default"129 default y130 depends on BLK_WBT131 help132 Enable writeback throttling by default for request-based block devices.133 134config BLK_CGROUP_IOLATENCY135 bool "Enable support for latency based cgroup IO protection"136 depends on BLK_CGROUP137 help138 Enabling this option enables the .latency interface for IO throttling.139 The IO controller will attempt to maintain average IO latencies below140 the configured latency target, throttling anybody with a higher latency141 target than the victimized group.142 143 Note, this is an experimental interface and could be changed someday.144 145config BLK_CGROUP_FC_APPID146 bool "Enable support to track FC I/O Traffic across cgroup applications"147 depends on BLK_CGROUP && NVME_FC148 help149 Enabling this option enables the support to track FC I/O traffic across150 cgroup applications. It enables the Fabric and the storage targets to151 identify, monitor, and handle FC traffic based on VM tags by inserting152 application specific identification into the FC frame.153 154config BLK_CGROUP_IOCOST155 bool "Enable support for cost model based cgroup IO controller"156 depends on BLK_CGROUP157 select BLK_RQ_ALLOC_TIME158 help159 Enabling this option enables the .weight interface for cost160 model based proportional IO control. The IO controller161 distributes IO capacity between different groups based on162 their share of the overall weight distribution.163 164config BLK_CGROUP_IOPRIO165 bool "Cgroup I/O controller for assigning an I/O priority class"166 depends on BLK_CGROUP167 help168 Enable the .prio interface for assigning an I/O priority class to169 requests. The I/O priority class affects the order in which an I/O170 scheduler and block devices process requests. Only some I/O schedulers171 and some block devices support I/O priorities.172 173config BLK_DEBUG_FS174 bool "Block layer debugging information in debugfs"175 default y176 depends on DEBUG_FS177 help178 Include block layer debugging information in debugfs. This information179 is mostly useful for kernel developers, but it doesn't incur any cost180 at runtime.181 182 Unless you are building a kernel for a tiny system, you should183 say Y here.184 185config BLK_SED_OPAL186 bool "Logic for interfacing with Opal enabled SEDs"187 depends on KEYS188 select PSERIES_PLPKS if PPC_PSERIES189 select PSERIES_PLPKS_SED if PPC_PSERIES190 help191 Builds Logic for interfacing with Opal enabled controllers.192 Enabling this option enables users to setup/unlock/lock193 Locking ranges for SED devices using the Opal protocol.194 195config BLK_INLINE_ENCRYPTION196 bool "Enable inline encryption support in block layer"197 help198 Build the blk-crypto subsystem. Enabling this lets the199 block layer handle encryption, so users can take200 advantage of inline encryption hardware if present.201 202config BLK_INLINE_ENCRYPTION_FALLBACK203 bool "Enable crypto API fallback for blk-crypto"204 depends on BLK_INLINE_ENCRYPTION205 select CRYPTO206 select CRYPTO_SKCIPHER207 help208 Enabling this lets the block layer handle inline encryption209 by falling back to the kernel crypto API when inline210 encryption hardware is not present.211 212source "block/partitions/Kconfig"213 214config BLK_MQ_PCI215 def_bool PCI216 217config BLK_MQ_VIRTIO218 bool219 depends on VIRTIO220 default y221 222config BLK_PM223 def_bool PM224 225# do not use in new code226config BLOCK_HOLDER_DEPRECATED227 bool228 229config BLK_MQ_STACKING230 bool231 232source "block/Kconfig.iosched"233 234endif # BLOCK235