| 1 | # SPDX-License-Identifier: GPL-2.0 |
| 2 | # |
| 3 | # Block device driver configuration |
| 4 | # |
| 5 | |
| 6 | menuconfig BLK_DEV |
| 7 | bool "Block devices" |
| 8 | depends on BLOCK |
| 9 | default y |
| 10 | help |
| 11 | Say Y here to get to see options for various different block device |
| 12 | drivers. This option alone does not add any kernel code. |
| 13 | |
| 14 | If you say N, all options in this submenu will be skipped and disabled; |
| 15 | only do this if you know what you are doing. |
| 16 | |
| 17 | if BLK_DEV |
| 18 | |
| 19 | source "drivers/block/null_blk/Kconfig" |
| 20 | source "drivers/block/rnull/Kconfig" |
| 21 | |
| 22 | config BLK_DEV_FD |
| 23 | tristate "Normal floppy disk support" |
| 24 | depends on ARCH_MAY_HAVE_PC_FDC |
| 25 | help |
| 26 | If you want to use the floppy disk drive(s) of your PC under Linux, |
| 27 | say Y. Information about this driver, especially important for IBM |
| 28 | Thinkpad users, is contained in |
| 29 | <file:Documentation/admin-guide/blockdev/floppy.rst>. |
| 30 | That file also contains the location of the Floppy driver FAQ as |
| 31 | well as location of the fdutils package used to configure additional |
| 32 | parameters of the driver at run time. |
| 33 | |
| 34 | To compile this driver as a module, choose M here: the |
| 35 | module will be called floppy. |
| 36 | |
| 37 | config BLK_DEV_FD_RAWCMD |
| 38 | bool "Support for raw floppy disk commands (DEPRECATED)" |
| 39 | depends on BLK_DEV_FD |
| 40 | help |
| 41 | If you want to use actual physical floppies and expect to do |
| 42 | special low-level hardware accesses to them (access and use |
| 43 | non-standard formats, for example), then enable this. |
| 44 | |
| 45 | Note that the code enabled by this option is rarely used and |
| 46 | might be unstable or insecure, and distros should not enable it. |
| 47 | |
| 48 | Note: FDRAWCMD is deprecated and will be removed from the kernel |
| 49 | in the near future. |
| 50 | |
| 51 | If unsure, say N. |
| 52 | |
| 53 | config AMIGA_FLOPPY |
| 54 | tristate "Amiga floppy support" |
| 55 | depends on AMIGA |
| 56 | |
| 57 | config ATARI_FLOPPY |
| 58 | tristate "Atari floppy support" |
| 59 | depends on ATARI |
| 60 | |
| 61 | config MAC_FLOPPY |
| 62 | tristate "Support for PowerMac floppy" |
| 63 | depends on PPC_PMAC && !PPC_PMAC64 |
| 64 | help |
| 65 | If you have a SWIM-3 (Super Woz Integrated Machine 3; from Apple) |
| 66 | floppy controller, say Y here. Most commonly found in PowerMacs. |
| 67 | |
| 68 | config BLK_DEV_SWIM |
| 69 | tristate "Support for SWIM Macintosh floppy" |
| 70 | depends on M68K && MAC && !HIGHMEM |
| 71 | help |
| 72 | You should select this option if you want floppy support |
| 73 | and you don't have a II, IIfx, Q900, Q950 or AV series. |
| 74 | |
| 75 | config AMIGA_Z2RAM |
| 76 | tristate "Amiga Zorro II ramdisk support" |
| 77 | depends on ZORRO |
| 78 | help |
| 79 | This enables support for using Chip RAM and Zorro II RAM as a |
| 80 | ramdisk or as a swap partition. Say Y if you want to include this |
| 81 | driver in the kernel. |
| 82 | |
| 83 | To compile this driver as a module, choose M here: the |
| 84 | module will be called z2ram. |
| 85 | |
| 86 | config N64CART |
| 87 | bool "N64 cart support" |
| 88 | depends on MACH_NINTENDO64 |
| 89 | help |
| 90 | Support for the N64 cart. |
| 91 | |
| 92 | config CDROM |
| 93 | tristate |
| 94 | |
| 95 | config GDROM |
| 96 | tristate "SEGA Dreamcast GD-ROM drive" |
| 97 | depends on SH_DREAMCAST |
| 98 | select CDROM |
| 99 | help |
| 100 | A standard SEGA Dreamcast comes with a modified CD ROM drive called a |
| 101 | "GD-ROM" by SEGA to signify it is capable of reading special disks |
| 102 | with up to 1 GB of data. This drive will also read standard CD ROM |
| 103 | disks. Select this option to access any disks in your GD ROM drive. |
| 104 | Most users will want to say "Y" here. |
| 105 | You can also build this as a module which will be called gdrom. |
| 106 | |
| 107 | source "drivers/block/mtip32xx/Kconfig" |
| 108 | |
| 109 | source "drivers/block/zram/Kconfig" |
| 110 | |
| 111 | config BLK_DEV_UBD |
| 112 | bool "Virtual block device" |
| 113 | depends on UML |
| 114 | help |
| 115 | The User-Mode Linux port includes a driver called UBD which will let |
| 116 | you access arbitrary files on the host computer as block devices. |
| 117 | Unless you know that you do not need such virtual block devices say |
| 118 | Y here. |
| 119 | |
| 120 | config BLK_DEV_UBD_SYNC |
| 121 | bool "Always do synchronous disk IO for UBD" |
| 122 | depends on BLK_DEV_UBD |
| 123 | help |
| 124 | Writes to the virtual block device are not immediately written to the |
| 125 | host's disk; this may cause problems if, for example, the User-Mode |
| 126 | Linux 'Virtual Machine' uses a journalling filesystem and the host |
| 127 | computer crashes. |
| 128 | |
| 129 | Synchronous operation (i.e. always writing data to the host's disk |
| 130 | immediately) is configurable on a per-UBD basis by using a special |
| 131 | kernel command line option. Alternatively, you can say Y here to |
| 132 | turn on synchronous operation by default for all block devices. |
| 133 | |
| 134 | If you're running a journalling file system (like xfs, for |
| 135 | example) in your virtual machine, you will want to say Y here. If |
| 136 | you care for the safety of the data in your virtual machine, Y is a |
| 137 | wise choice too. In all other cases (for example, if you're just |
| 138 | playing around with User-Mode Linux) you can choose N. |
| 139 | |
| 140 | config BLK_DEV_COW_COMMON |
| 141 | bool |
| 142 | default BLK_DEV_UBD |
| 143 | |
| 144 | config BLK_DEV_LOOP |
| 145 | tristate "Loopback device support" |
| 146 | help |
| 147 | Saying Y here will allow you to use a regular file as a block |
| 148 | device; you can then create a file system on that block device and |
| 149 | mount it just as you would mount other block devices such as hard |
| 150 | drive partitions, CD-ROM drives or floppy drives. The loop devices |
| 151 | are block special device files with major number 7 and typically |
| 152 | called /dev/loop0, /dev/loop1 etc. |
| 153 | |
| 154 | This is useful if you want to check an ISO 9660 file system before |
| 155 | burning the CD, or if you want to use floppy images without first |
| 156 | writing them to floppy. Furthermore, some Linux distributions avoid |
| 157 | the need for a dedicated Linux partition by keeping their complete |
| 158 | root file system inside a DOS FAT file using this loop device |
| 159 | driver. |
| 160 | |
| 161 | To use the loop device, you need the losetup utility, found in the |
| 162 | util-linux package, see |
| 163 | <https://www.kernel.org/pub/linux/utils/util-linux/>. |
| 164 | |
| 165 | The loop device driver can also be used to "hide" a file system in |
| 166 | a disk partition, floppy, or regular file, either using encryption |
| 167 | (scrambling the data) or steganography (hiding the data in the low |
| 168 | bits of, say, a sound file). This is also safe if the file resides |
| 169 | on a remote file server. |
| 170 | |
| 171 | Note that this loop device has nothing to do with the loopback |
| 172 | device used for network connections from the machine to itself. |
| 173 | |
| 174 | To compile this driver as a module, choose M here: the |
| 175 | module will be called loop. |
| 176 | |
| 177 | Most users will answer N here. |
| 178 | |
| 179 | config BLK_DEV_LOOP_MIN_COUNT |
| 180 | int "Number of loop devices to pre-create at init time" |
| 181 | depends on BLK_DEV_LOOP |
| 182 | default 8 |
| 183 | help |
| 184 | Static number of loop devices to be unconditionally pre-created |
| 185 | at init time. |
| 186 | |
| 187 | This default value can be overwritten on the kernel command |
| 188 | line or with module-parameter loop.max_loop. |
| 189 | |
| 190 | The historic default is 8. If a late 2011 version of losetup(8) |
| 191 | is used, it can be set to 0, since needed loop devices can be |
| 192 | dynamically allocated with the /dev/loop-control interface. |
| 193 | |
| 194 | source "drivers/block/drbd/Kconfig" |
| 195 | |
| 196 | config BLK_DEV_NBD |
| 197 | tristate "Network block device support" |
| 198 | depends on NET |
| 199 | help |
| 200 | Saying Y here will allow your computer to be a client for network |
| 201 | block devices, i.e. it will be able to use block devices exported by |
| 202 | servers (mount file systems on them etc.). Communication between |
| 203 | client and server works over TCP/IP networking, but to the client |
| 204 | program this is hidden: it looks like a regular local file access to |
| 205 | a block device special file such as /dev/nd0. |
| 206 | |
| 207 | Network block devices also allows you to run a block-device in |
| 208 | userland (making server and client physically the same computer, |
| 209 | communicating using the loopback network device). |
| 210 | |
| 211 | Read <file:Documentation/admin-guide/blockdev/nbd.rst> for more information, |
| 212 | especially about where to find the server code, which runs in user |
| 213 | space and does not need special kernel support. |
| 214 | |
| 215 | Note that this has nothing to do with the network file systems NFS |
| 216 | or Coda; you can say N here even if you intend to use NFS or Coda. |
| 217 | |
| 218 | To compile this driver as a module, choose M here: the |
| 219 | module will be called nbd. |
| 220 | |
| 221 | If unsure, say N. |
| 222 | |
| 223 | config BLK_DEV_RAM |
| 224 | tristate "RAM block device support" |
| 225 | help |
| 226 | Saying Y here will allow you to use a portion of your RAM memory as |
| 227 | a block device, so that you can make file systems on it, read and |
| 228 | write to it and do all the other things that you can do with normal |
| 229 | block devices (such as hard drives). It is usually used to load and |
| 230 | store a copy of a minimal root file system off of a floppy into RAM |
| 231 | during the initial install of Linux. |
| 232 | |
| 233 | Note that the kernel command line option "ramdisk=XX" is now obsolete. |
| 234 | For details, read <file:Documentation/admin-guide/blockdev/ramdisk.rst>. |
| 235 | |
| 236 | To compile this driver as a module, choose M here: the |
| 237 | module will be called brd. An alias "rd" has been defined |
| 238 | for historical reasons. |
| 239 | |
| 240 | Most normal users won't need the RAM disk functionality, and can |
| 241 | thus say N here. |
| 242 | |
| 243 | config BLK_DEV_RAM_COUNT |
| 244 | int "Default number of RAM disks" |
| 245 | default "16" |
| 246 | depends on BLK_DEV_RAM |
| 247 | help |
| 248 | The default value is 16 RAM disks. Change this if you know what you |
| 249 | are doing. If you boot from a filesystem that needs to be extracted |
| 250 | in memory, you will need at least one RAM disk (e.g. root on cramfs). |
| 251 | |
| 252 | config BLK_DEV_RAM_SIZE |
| 253 | int "Default RAM disk size (kbytes)" |
| 254 | depends on BLK_DEV_RAM |
| 255 | default "4096" |
| 256 | help |
| 257 | The default value is 4096 kilobytes. Only change this if you know |
| 258 | what you are doing. |
| 259 | |
| 260 | config ATA_OVER_ETH |
| 261 | tristate "ATA over Ethernet support" |
| 262 | depends on NET |
| 263 | help |
| 264 | This driver provides Support for ATA over Ethernet block |
| 265 | devices like the Coraid EtherDrive (R) Storage Blade. |
| 266 | |
| 267 | config SUNVDC |
| 268 | tristate "Sun Virtual Disk Client support" |
| 269 | depends on SUN_LDOMS |
| 270 | help |
| 271 | Support for virtual disk devices as a client under Sun |
| 272 | Logical Domains. |
| 273 | |
| 274 | source "drivers/s390/block/Kconfig" |
| 275 | |
| 276 | config XEN_BLKDEV_FRONTEND |
| 277 | tristate "Xen virtual block device support" |
| 278 | depends on XEN |
| 279 | default y |
| 280 | select XEN_XENBUS_FRONTEND |
| 281 | help |
| 282 | This driver implements the front-end of the Xen virtual |
| 283 | block device driver. It communicates with a back-end driver |
| 284 | in another domain which drives the actual block device. |
| 285 | |
| 286 | config XEN_BLKDEV_BACKEND |
| 287 | tristate "Xen block-device backend driver" |
| 288 | depends on XEN_BACKEND |
| 289 | help |
| 290 | The block-device backend driver allows the kernel to export its |
| 291 | block devices to other guests via a high-performance shared-memory |
| 292 | interface. |
| 293 | |
| 294 | The corresponding Linux frontend driver is enabled by the |
| 295 | CONFIG_XEN_BLKDEV_FRONTEND configuration option. |
| 296 | |
| 297 | The backend driver attaches itself to a any block device specified |
| 298 | in the XenBus configuration. There are no limits to what the block |
| 299 | device as long as it has a major and minor. |
| 300 | |
| 301 | If you are compiling a kernel to run in a Xen block backend driver |
| 302 | domain (often this is domain 0) you should say Y here. To |
| 303 | compile this driver as a module, chose M here: the module |
| 304 | will be called xen-blkback. |
| 305 | |
| 306 | |
| 307 | config VIRTIO_BLK |
| 308 | tristate "Virtio block driver" |
| 309 | depends on VIRTIO |
| 310 | select SG_POOL |
| 311 | help |
| 312 | This is the virtual block driver for virtio. It can be used with |
| 313 | QEMU based VMMs (like KVM or Xen). Say Y or M. |
| 314 | |
| 315 | config BLK_DEV_RBD |
| 316 | tristate "Rados block device (RBD)" |
| 317 | depends on INET && BLOCK |
| 318 | select CEPH_LIB |
| 319 | help |
| 320 | Say Y here if you want include the Rados block device, which stripes |
| 321 | a block device over objects stored in the Ceph distributed object |
| 322 | store. |
| 323 | |
| 324 | More information at http://ceph.newdream.net/. |
| 325 | |
| 326 | If unsure, say N. |
| 327 | |
| 328 | config BLK_DEV_UBLK |
| 329 | tristate "Userspace block driver (Experimental)" |
| 330 | select IO_URING |
| 331 | help |
| 332 | io_uring based userspace block driver. Together with ublk server, ublk |
| 333 | has been working well, but interface with userspace or command data |
| 334 | definition isn't finalized yet, and might change according to future |
| 335 | requirement, so mark is as experimental now. |
| 336 | |
| 337 | config BLKDEV_UBLK_LEGACY_OPCODES |
| 338 | bool "Support legacy command opcode" |
| 339 | depends on BLK_DEV_UBLK |
| 340 | default y |
| 341 | help |
| 342 | ublk driver started to take plain command encoding, which turns out |
| 343 | one bad way. The traditional ioctl command opcode encodes more |
| 344 | info and basically defines each code uniquely, so opcode conflict |
| 345 | is avoided, and driver can handle wrong command easily, meantime it |
| 346 | may help security subsystem to audit io_uring command. |
| 347 | |
| 348 | Say Y if your application still uses legacy command opcode. |
| 349 | |
| 350 | Say N if you don't want to support legacy command opcode. It is |
| 351 | suggested to enable N if your application(ublk server) switches to |
| 352 | ioctl command encoding. |
| 353 | |
| 354 | source "drivers/block/rnbd/Kconfig" |
| 355 | |
| 356 | config BLK_DEV_ZONED_LOOP |
| 357 | tristate "Zoned loopback device support" |
| 358 | depends on BLK_DEV_ZONED |
| 359 | help |
| 360 | Saying Y here will allow you to use create a zoned block device using |
| 361 | regular files for zones (one file per zones). This is useful to test |
| 362 | file systems, device mapper and applications that support zoned block |
| 363 | devices. To create a zoned loop device, no user utility is needed, a |
| 364 | zoned loop device can be created (or re-started) using a command |
| 365 | like: |
| 366 | |
| 367 | echo "add id=0,zone_size_mb=256,capacity_mb=16384,conv_zones=11" > \ |
| 368 | /dev/zloop-control |
| 369 | |
| 370 | See Documentation/admin-guide/blockdev/zoned_loop.rst for usage |
| 371 | details. |
| 372 | |
| 373 | If unsure, say N. |
| 374 | |
| 375 | endif # BLK_DEV |