1b2441318SGreg Kroah-Hartman# SPDX-License-Identifier: GPL-2.0 23a65dfe8SJens Axboe# 33a65dfe8SJens Axboe# Block layer core configuration 43a65dfe8SJens Axboe# 516ed002fSJan Engelhardtmenuconfig BLOCK 66a108a14SDavid Rientjes bool "Enable the block layer" if EXPERT 79361401eSDavid Howells default y 8487c607dSChristoph Hellwig select FS_IOMAP 988459642SOmar Sandoval select SBITMAP 109361401eSDavid Howells help 11ee86418dSNick Andrew Provide block layer support for the kernel. 129361401eSDavid Howells 13ee86418dSNick Andrew Disable this option to remove the block layer support from the 14ee86418dSNick Andrew kernel. This may be useful for embedded devices. 15ee86418dSNick Andrew 16ee86418dSNick Andrew If this option is disabled: 17ee86418dSNick Andrew 18ee86418dSNick Andrew - block device files will become unusable 19ee86418dSNick Andrew - some filesystems (such as ext3) will become unavailable. 20ee86418dSNick Andrew 21ee86418dSNick Andrew Also, SCSI character devices and USB storage will be disabled since 22ee86418dSNick Andrew they make use of various block layer definitions and facilities. 239361401eSDavid Howells 249361401eSDavid Howells Say Y here unless you know you really don't want to mount disks and 259361401eSDavid Howells suchlike. 269361401eSDavid Howells 279361401eSDavid Howellsif BLOCK 289361401eSDavid Howells 29fbdee71bSChristoph Hellwigconfig BLOCK_LEGACY_AUTOLOAD 30fbdee71bSChristoph Hellwig bool "Legacy autoloading support" 31451f0b6fSChristoph Hellwig default y 32fbdee71bSChristoph Hellwig help 33fbdee71bSChristoph Hellwig Enable loading modules and creating block device instances based on 34fbdee71bSChristoph Hellwig accesses through their device special file. This is a historic Linux 35fbdee71bSChristoph Hellwig feature and makes no sense in a udev world where device files are 36451f0b6fSChristoph Hellwig created on demand, but scripts that manually create device nodes and 37451f0b6fSChristoph Hellwig then call losetup might rely on this behavior. 38fbdee71bSChristoph Hellwig 396f816b4bSTejun Heoconfig BLK_RQ_ALLOC_TIME 406f816b4bSTejun Heo bool 416f816b4bSTejun Heo 421d156646STejun Heoconfig BLK_CGROUP_RWSTAT 431d156646STejun Heo bool 441d156646STejun Heo 452c275afeSChristoph Hellwigconfig BLK_CGROUP_PUNT_BIO 462c275afeSChristoph Hellwig bool 472c275afeSChristoph Hellwig 4878011042SChristoph Hellwigconfig BLK_DEV_BSG_COMMON 4978011042SChristoph Hellwig tristate 50ee86418dSNick Andrew 515ef16305SChristoph Hellwigconfig BLK_ICQ 525ef16305SChristoph Hellwig bool 535ef16305SChristoph Hellwig 54aa387cc8SMike Christieconfig BLK_DEV_BSGLIB 55aa387cc8SMike Christie bool "Block layer SG support v4 helper lib" 5678011042SChristoph Hellwig select BLK_DEV_BSG_COMMON 57aa387cc8SMike Christie help 58aa387cc8SMike Christie Subsystems will normally enable this if needed. Users will not 59aa387cc8SMike Christie normally need to manually enable this. 60aa387cc8SMike Christie 61aa387cc8SMike Christie If unsure, say N. 62aa387cc8SMike Christie 637ba1ba12SMartin K. Petersenconfig BLK_DEV_INTEGRITY 647ba1ba12SMartin K. Petersen bool "Block layer data integrity support" 65a7f7f624SMasahiro Yamada help 667ba1ba12SMartin K. Petersen Some storage devices allow extra information to be 677ba1ba12SMartin K. Petersen stored/retrieved to help protect the data. The block layer 687ba1ba12SMartin K. Petersen data integrity option provides hooks which can be used by 697ba1ba12SMartin K. Petersen filesystems to ensure better data integrity. 707ba1ba12SMartin K. Petersen 717ba1ba12SMartin K. Petersen Say yes here if you have a storage device that provides the 727ba1ba12SMartin K. Petersen T10/SCSI Data Integrity Field or the T13/ATA External Path 737ba1ba12SMartin K. Petersen Protection. If in doubt, say N. 747ba1ba12SMartin K. Petersen 75a754bd5fSHerbert Xuconfig BLK_DEV_INTEGRITY_T10 76a754bd5fSHerbert Xu tristate 77a754bd5fSHerbert Xu depends on BLK_DEV_INTEGRITY 78a754bd5fSHerbert Xu select CRC_T10DIF 79a7d4383fSKeith Busch select CRC64_ROCKSOFT 80a754bd5fSHerbert Xu 81*ed5cc702SJan Karaconfig BLK_DEV_WRITE_MOUNTED 82*ed5cc702SJan Kara bool "Allow writing to mounted block devices" 83*ed5cc702SJan Kara default y 84*ed5cc702SJan Kara help 85*ed5cc702SJan Kara When a block device is mounted, writing to its buffer cache is very 86*ed5cc702SJan Kara likely going to cause filesystem corruption. It is also rather easy to 87*ed5cc702SJan Kara crash the kernel in this way since the filesystem has no practical way 88*ed5cc702SJan Kara of detecting these writes to buffer cache and verifying its metadata 89*ed5cc702SJan Kara integrity. However there are some setups that need this capability 90*ed5cc702SJan Kara like running fsck on read-only mounted root device, modifying some 91*ed5cc702SJan Kara features on mounted ext4 filesystem, and similar. If you say N, the 92*ed5cc702SJan Kara kernel will prevent processes from writing to block devices that are 93*ed5cc702SJan Kara mounted by filesystems which provides some more protection from runaway 94*ed5cc702SJan Kara privileged processes and generally makes it much harder to crash 95*ed5cc702SJan Kara filesystem drivers. Note however that this does not prevent 96*ed5cc702SJan Kara underlying device(s) from being modified by other means, e.g. by 97*ed5cc702SJan Kara directly submitting SCSI commands or through access to lower layers of 98*ed5cc702SJan Kara storage stack. If in doubt, say Y. The configuration can be overridden 99*ed5cc702SJan Kara with the bdev_allow_write_mounted boot option. 100*ed5cc702SJan Kara 1016a0cb1bcSHannes Reineckeconfig BLK_DEV_ZONED 1026a0cb1bcSHannes Reinecke bool "Zoned block device support" 103b9aef63aSDamien Le Moal select MQ_IOSCHED_DEADLINE 104a7f7f624SMasahiro Yamada help 1056a0cb1bcSHannes Reinecke Block layer zoned block device support. This option enables 106240e6ee2SKeith Busch support for ZAC/ZBC/ZNS host-managed and host-aware zoned block 107240e6ee2SKeith Busch devices. 1086a0cb1bcSHannes Reinecke 109240e6ee2SKeith Busch Say yes here if you have a ZAC, ZBC, or ZNS storage device. 1106a0cb1bcSHannes Reinecke 111e43473b7SVivek Goyalconfig BLK_DEV_THROTTLING 112e43473b7SVivek Goyal bool "Block layer bio throttling support" 113df252bdeSMasahiro Yamada depends on BLK_CGROUP 1141d156646STejun Heo select BLK_CGROUP_RWSTAT 115a7f7f624SMasahiro Yamada help 116e43473b7SVivek Goyal Block layer bio throttling support. It can be used to limit 117e43473b7SVivek Goyal the IO rate to a device. IO rate policies are per cgroup and 118e43473b7SVivek Goyal one needs to mount and use blkio cgroup controller for creating 119e43473b7SVivek Goyal cgroups and specifying per device IO rate policies. 120e43473b7SVivek Goyal 121da82c92fSMauro Carvalho Chehab See Documentation/admin-guide/cgroup-v1/blkio-controller.rst for more information. 122e43473b7SVivek Goyal 123327ffb9bSShaohua Liconfig BLK_DEV_THROTTLING_LOW 124327ffb9bSShaohua Li bool "Block throttling .low limit interface support (EXPERIMENTAL)" 125327ffb9bSShaohua Li depends on BLK_DEV_THROTTLING 126a7f7f624SMasahiro Yamada help 127327ffb9bSShaohua Li Add .low limit interface for block throttling. The low limit is a best 128327ffb9bSShaohua Li effort limit to prioritize cgroups. Depending on the setting, the limit 129327ffb9bSShaohua Li can be used to protect cgroups in terms of bandwidth/iops and better 130327ffb9bSShaohua Li utilize disk resource. 131327ffb9bSShaohua Li 132327ffb9bSShaohua Li Note, this is an experimental interface and could be changed someday. 133327ffb9bSShaohua Li 13487760e5eSJens Axboeconfig BLK_WBT 13587760e5eSJens Axboe bool "Enable support for block device writeback throttling" 136a7f7f624SMasahiro Yamada help 13787760e5eSJens Axboe Enabling this option enables the block layer to throttle buffered 13887760e5eSJens Axboe background writeback from the VM, making it more smooth and having 13987760e5eSJens Axboe less impact on foreground operations. The throttling is done 14087760e5eSJens Axboe dynamically on an algorithm loosely based on CoDel, factoring in 14187760e5eSJens Axboe the realtime performance of the disk. 14287760e5eSJens Axboe 1435f6776baSBart Van Asscheconfig BLK_WBT_MQ 1445f6776baSBart Van Assche bool "Enable writeback throttling by default" 1455f6776baSBart Van Assche default y 1465f6776baSBart Van Assche depends on BLK_WBT 1475f6776baSBart Van Assche help 1485f6776baSBart Van Assche Enable writeback throttling by default for request-based block devices. 1495f6776baSBart Van Assche 150d7067512SJosef Bacikconfig BLK_CGROUP_IOLATENCY 151d7067512SJosef Bacik bool "Enable support for latency based cgroup IO protection" 152df252bdeSMasahiro Yamada depends on BLK_CGROUP 153a7f7f624SMasahiro Yamada help 154d7067512SJosef Bacik Enabling this option enables the .latency interface for IO throttling. 155d7067512SJosef Bacik The IO controller will attempt to maintain average IO latencies below 156d7067512SJosef Bacik the configured latency target, throttling anybody with a higher latency 157d7067512SJosef Bacik target than the victimized group. 158d7067512SJosef Bacik 159d7067512SJosef Bacik Note, this is an experimental interface and could be changed someday. 160d7067512SJosef Bacik 161d2bcbeabSMuneendra Kumarconfig BLK_CGROUP_FC_APPID 162d2bcbeabSMuneendra Kumar bool "Enable support to track FC I/O Traffic across cgroup applications" 163d2500a0cSMartin K. Petersen depends on BLK_CGROUP && NVME_FC 164d2bcbeabSMuneendra Kumar help 165d2bcbeabSMuneendra Kumar Enabling this option enables the support to track FC I/O traffic across 166d2bcbeabSMuneendra Kumar cgroup applications. It enables the Fabric and the storage targets to 167d2bcbeabSMuneendra Kumar identify, monitor, and handle FC traffic based on VM tags by inserting 168d2bcbeabSMuneendra Kumar application specific identification into the FC frame. 169d2bcbeabSMuneendra Kumar 1707caa4715STejun Heoconfig BLK_CGROUP_IOCOST 1717caa4715STejun Heo bool "Enable support for cost model based cgroup IO controller" 172df252bdeSMasahiro Yamada depends on BLK_CGROUP 1737caa4715STejun Heo select BLK_RQ_ALLOC_TIME 174a7f7f624SMasahiro Yamada help 1757caa4715STejun Heo Enabling this option enables the .weight interface for cost 1767caa4715STejun Heo model based proportional IO control. The IO controller 1777caa4715STejun Heo distributes IO capacity between different groups based on 1787caa4715STejun Heo their share of the overall weight distribution. 1797caa4715STejun Heo 180556910e3SBart Van Asscheconfig BLK_CGROUP_IOPRIO 181556910e3SBart Van Assche bool "Cgroup I/O controller for assigning an I/O priority class" 182556910e3SBart Van Assche depends on BLK_CGROUP 183556910e3SBart Van Assche help 184556910e3SBart Van Assche Enable the .prio interface for assigning an I/O priority class to 185556910e3SBart Van Assche requests. The I/O priority class affects the order in which an I/O 186556910e3SBart Van Assche scheduler and block devices process requests. Only some I/O schedulers 187556910e3SBart Van Assche and some block devices support I/O priorities. 188556910e3SBart Van Assche 189400f73b2SOmar Sandovalconfig BLK_DEBUG_FS 190400f73b2SOmar Sandoval bool "Block layer debugging information in debugfs" 191400f73b2SOmar Sandoval default y 192400f73b2SOmar Sandoval depends on DEBUG_FS 193a7f7f624SMasahiro Yamada help 194400f73b2SOmar Sandoval Include block layer debugging information in debugfs. This information 195400f73b2SOmar Sandoval is mostly useful for kernel developers, but it doesn't incur any cost 196400f73b2SOmar Sandoval at runtime. 197400f73b2SOmar Sandoval 198400f73b2SOmar Sandoval Unless you are building a kernel for a tiny system, you should 199400f73b2SOmar Sandoval say Y here. 200400f73b2SOmar Sandoval 2016a5ac984SBart Van Asscheconfig BLK_DEBUG_FS_ZONED 2026a5ac984SBart Van Assche bool 2036a5ac984SBart Van Assche default BLK_DEBUG_FS && BLK_DEV_ZONED 2046a5ac984SBart Van Assche 205455a7b23SScott Bauerconfig BLK_SED_OPAL 206455a7b23SScott Bauer bool "Logic for interfacing with Opal enabled SEDs" 2073bfeb612SGreg Joyce depends on KEYS 2083bfeb612SGreg Joyce select PSERIES_PLPKS if PPC_PSERIES 209ec8cf230SGreg Joyce select PSERIES_PLPKS_SED if PPC_PSERIES 210a7f7f624SMasahiro Yamada help 211455a7b23SScott Bauer Builds Logic for interfacing with Opal enabled controllers. 212455a7b23SScott Bauer Enabling this option enables users to setup/unlock/lock 213455a7b23SScott Bauer Locking ranges for SED devices using the Opal protocol. 214455a7b23SScott Bauer 2151b262839SSatya Tangiralaconfig BLK_INLINE_ENCRYPTION 2161b262839SSatya Tangirala bool "Enable inline encryption support in block layer" 2171b262839SSatya Tangirala help 2181b262839SSatya Tangirala Build the blk-crypto subsystem. Enabling this lets the 2191b262839SSatya Tangirala block layer handle encryption, so users can take 2201b262839SSatya Tangirala advantage of inline encryption hardware if present. 2211b262839SSatya Tangirala 222488f6682SSatya Tangiralaconfig BLK_INLINE_ENCRYPTION_FALLBACK 223488f6682SSatya Tangirala bool "Enable crypto API fallback for blk-crypto" 224488f6682SSatya Tangirala depends on BLK_INLINE_ENCRYPTION 225488f6682SSatya Tangirala select CRYPTO 226488f6682SSatya Tangirala select CRYPTO_SKCIPHER 227488f6682SSatya Tangirala help 228488f6682SSatya Tangirala Enabling this lets the block layer handle inline encryption 229488f6682SSatya Tangirala by falling back to the kernel crypto API when inline 230488f6682SSatya Tangirala encryption hardware is not present. 231488f6682SSatya Tangirala 2329be96f3fSAl Virosource "block/partitions/Kconfig" 2339be96f3fSAl Viro 2348ec2ef2bSStephen Rothwellconfig BLK_MQ_PCI 235c50fca55SMasahiro Yamada def_bool PCI 2368ec2ef2bSStephen Rothwell 23773473427SChristoph Hellwigconfig BLK_MQ_VIRTIO 23873473427SChristoph Hellwig bool 239c50fca55SMasahiro Yamada depends on VIRTIO 24073473427SChristoph Hellwig default y 24173473427SChristoph Hellwig 242bca6b067SBart Van Asscheconfig BLK_PM 243c50fca55SMasahiro Yamada def_bool PM 244bca6b067SBart Van Assche 245c66fd019SChristoph Hellwig# do not use in new code 246c66fd019SChristoph Hellwigconfig BLOCK_HOLDER_DEPRECATED 247c66fd019SChristoph Hellwig bool 248c66fd019SChristoph Hellwig 249248c7933SChristoph Hellwigconfig BLK_MQ_STACKING 250248c7933SChristoph Hellwig bool 251248c7933SChristoph Hellwig 2528636a1f9SMasahiro Yamadasource "block/Kconfig.iosched" 253c50fca55SMasahiro Yamada 254c50fca55SMasahiro Yamadaendif # BLOCK 255