Directory Files
.. 2
aoe 9
drbd 28
mtip32xx 5
null_blk 8
rnbd 15
xen-blkback 5
zram 7
File Size
Kconfig 14 kB
Makefile 1.2 kB
amiflop.c 52 kB
ataflop.c 58 kB
brd.c 11 kB
brd.mod.c 0 B
floppy.c 137 kB
floppy.mod.c 0 B
loop.c 59 kB
loop.mod.c 0 B
n64cart.c 3.9 kB
nbd.c 66 kB
nbd.mod.c 0 B
pktcdvd.c 73 kB
pktcdvd.mod.c 0 B
ps3disk.c 13 kB
ps3vram.c 22 kB
rbd.c 191 kB
rbd.mod.c 0 B
rbd_types.h 2.6 kB
sunvdc.c 29 kB
swim.c 20 kB
swim3.c 32 kB
swim_asm.S 4.5 kB
ublk_drv.c 73 kB
ublk_drv.mod.c 0 B
virtio_blk.c 45 kB
virtio_blk.mod.c 0 B
xen-blkfront.c 73 kB
xen-blkfront.mod.c 0 B
z2ram.c 9.4 kB

Linux v6.6.1 - block

# SPDX-License-Identifier: GPL-2.0
# Block device driver configuration

menuconfig BLK_DEV
	bool "Block devices"
	depends on BLOCK
	default y
	  Say Y here to get to see options for various different block device
	  drivers. This option alone does not add any kernel code.

	  If you say N, all options in this submenu will be skipped and disabled;
	  only do this if you know what you are doing.


source "drivers/block/null_blk/Kconfig"

config BLK_DEV_FD
	tristate "Normal floppy disk support"
	depends on ARCH_MAY_HAVE_PC_FDC
	  If you want to use the floppy disk drive(s) of your PC under Linux,
	  say Y. Information about this driver, especially important for IBM
	  Thinkpad users, is contained in
	  That file also contains the location of the Floppy driver FAQ as
	  well as location of the fdutils package used to configure additional
	  parameters of the driver at run time.

	  To compile this driver as a module, choose M here: the
	  module will be called floppy.

	bool "Support for raw floppy disk commands (DEPRECATED)"
	depends on BLK_DEV_FD
	  If you want to use actual physical floppies and expect to do
	  special low-level hardware accesses to them (access and use
	  non-standard formats, for example), then enable this.

	  Note that the code enabled by this option is rarely used and
	  might be unstable or insecure, and distros should not enable it.

	  Note: FDRAWCMD is deprecated and will be removed from the kernel
	  in the near future.

	  If unsure, say N.

	tristate "Amiga floppy support"
	depends on AMIGA

	tristate "Atari floppy support"
	depends on ATARI

	tristate "Support for PowerMac floppy"
	depends on PPC_PMAC && !PPC_PMAC64
	  If you have a SWIM-3 (Super Woz Integrated Machine 3; from Apple)
	  floppy controller, say Y here. Most commonly found in PowerMacs.

	tristate "Support for SWIM Macintosh floppy"
	depends on M68K && MAC && !HIGHMEM
	  You should select this option if you want floppy support
	  and you don't have a II, IIfx, Q900, Q950 or AV series.

config AMIGA_Z2RAM
	tristate "Amiga Zorro II ramdisk support"
	depends on ZORRO
	  This enables support for using Chip RAM and Zorro II RAM as a
	  ramdisk or as a swap partition. Say Y if you want to include this
	  driver in the kernel.

	  To compile this driver as a module, choose M here: the
	  module will be called z2ram.

config N64CART
	bool "N64 cart support"
	depends on MACH_NINTENDO64
	  Support for the N64 cart.

config CDROM

config GDROM
	tristate "SEGA Dreamcast GD-ROM drive"
	depends on SH_DREAMCAST
	select CDROM
	  A standard SEGA Dreamcast comes with a modified CD ROM drive called a
	  "GD-ROM" by SEGA to signify it is capable of reading special disks
	  with up to 1 GB of data. This drive will also read standard CD ROM
	  disks. Select this option to access any disks in your GD ROM drive.
	  Most users will want to say "Y" here.
	  You can also build this as a module which will be called gdrom.

source "drivers/block/mtip32xx/Kconfig"

source "drivers/block/zram/Kconfig"

config BLK_DEV_UBD
	bool "Virtual block device"
	depends on UML
          The User-Mode Linux port includes a driver called UBD which will let
          you access arbitrary files on the host computer as block devices.
          Unless you know that you do not need such virtual block devices say
          Y here.

	bool "Always do synchronous disk IO for UBD"
	depends on BLK_DEV_UBD
	  Writes to the virtual block device are not immediately written to the
	  host's disk; this may cause problems if, for example, the User-Mode
	  Linux 'Virtual Machine' uses a journalling filesystem and the host
	  computer crashes.

          Synchronous operation (i.e. always writing data to the host's disk
          immediately) is configurable on a per-UBD basis by using a special
          kernel command line option.  Alternatively, you can say Y here to
          turn on synchronous operation by default for all block devices.

          If you're running a journalling file system (like reiserfs, for
          example) in your virtual machine, you will want to say Y here.  If
          you care for the safety of the data in your virtual machine, Y is a
          wise choice too.  In all other cases (for example, if you're just
          playing around with User-Mode Linux) you can choose N.

	default BLK_DEV_UBD

	tristate "Loopback device support"
	  Saying Y here will allow you to use a regular file as a block
	  device; you can then create a file system on that block device and
	  mount it just as you would mount other block devices such as hard
	  drive partitions, CD-ROM drives or floppy drives. The loop devices
	  are block special device files with major number 7 and typically
	  called /dev/loop0, /dev/loop1 etc.

	  This is useful if you want to check an ISO 9660 file system before
	  burning the CD, or if you want to use floppy images without first
	  writing them to floppy. Furthermore, some Linux distributions avoid
	  the need for a dedicated Linux partition by keeping their complete
	  root file system inside a DOS FAT file using this loop device

	  To use the loop device, you need the losetup utility, found in the
	  util-linux package, see

	  The loop device driver can also be used to "hide" a file system in
	  a disk partition, floppy, or regular file, either using encryption
	  (scrambling the data) or steganography (hiding the data in the low
	  bits of, say, a sound file). This is also safe if the file resides
	  on a remote file server.

	  Note that this loop device has nothing to do with the loopback
	  device used for network connections from the machine to itself.

	  To compile this driver as a module, choose M here: the
	  module will be called loop.

	  Most users will answer N here.

	int "Number of loop devices to pre-create at init time"
	depends on BLK_DEV_LOOP
	default 8
	  Static number of loop devices to be unconditionally pre-created
	  at init time.

	  This default value can be overwritten on the kernel command
	  line or with module-parameter loop.max_loop.

	  The historic default is 8. If a late 2011 version of losetup(8)
	  is used, it can be set to 0, since needed loop devices can be
	  dynamically allocated with the /dev/loop-control interface.

source "drivers/block/drbd/Kconfig"

config BLK_DEV_NBD
	tristate "Network block device support"
	depends on NET
	  Saying Y here will allow your computer to be a client for network
	  block devices, i.e. it will be able to use block devices exported by
	  servers (mount file systems on them etc.). Communication between
	  client and server works over TCP/IP networking, but to the client
	  program this is hidden: it looks like a regular local file access to
	  a block device special file such as /dev/nd0.

	  Network block devices also allows you to run a block-device in
	  userland (making server and client physically the same computer,
	  communicating using the loopback network device).

	  Read <file:Documentation/admin-guide/blockdev/nbd.rst> for more information,
	  especially about where to find the server code, which runs in user
	  space and does not need special kernel support.

	  Note that this has nothing to do with the network file systems NFS
	  or Coda; you can say N here even if you intend to use NFS or Coda.

	  To compile this driver as a module, choose M here: the
	  module will be called nbd.

	  If unsure, say N.

config BLK_DEV_RAM
	tristate "RAM block device support"
	  Saying Y here will allow you to use a portion of your RAM memory as
	  a block device, so that you can make file systems on it, read and
	  write to it and do all the other things that you can do with normal
	  block devices (such as hard drives). It is usually used to load and
	  store a copy of a minimal root file system off of a floppy into RAM
	  during the initial install of Linux.

	  Note that the kernel command line option "ramdisk=XX" is now obsolete.
	  For details, read <file:Documentation/admin-guide/blockdev/ramdisk.rst>.

	  To compile this driver as a module, choose M here: the
	  module will be called brd. An alias "rd" has been defined
	  for historical reasons.

	  Most normal users won't need the RAM disk functionality, and can
	  thus say N here.

	int "Default number of RAM disks"
	default "16"
	depends on BLK_DEV_RAM
	  The default value is 16 RAM disks. Change this if you know what you
	  are doing. If you boot from a filesystem that needs to be extracted
	  in memory, you will need at least one RAM disk (e.g. root on cramfs).

	int "Default RAM disk size (kbytes)"
	depends on BLK_DEV_RAM
	default "4096"
	  The default value is 4096 kilobytes. Only change this if you know
	  what you are doing.

	tristate "Packet writing on CD/DVD media (DEPRECATED)"
	depends on !UML
	depends on SCSI
	select CDROM
	  Note: This driver is deprecated and will be removed from the
	  kernel in the near future!

	  If you have a CDROM/DVD drive that supports packet writing, say
	  Y to include support. It should work with any MMC/Mt Fuji
	  compliant ATAPI or SCSI drive, which is just about any newer
	  DVD/CD writer.

	  Currently only writing to CD-RW, DVD-RW, DVD+RW and DVDRAM discs
	  is possible.
	  DVD-RW disks must be in restricted overwrite mode.

	  See the file <file:Documentation/cdrom/packet-writing.rst>
	  for further information on the use of this driver.

	  To compile this driver as a module, choose M here: the
	  module will be called pktcdvd.

	int "Free buffers for data gathering"
	depends on CDROM_PKTCDVD
	default "8"
	  This controls the maximum number of active concurrent packets. More
	  concurrent packets can increase write performance, but also require
	  more memory. Each concurrent packet will require approximately 64Kb
	  of non-swappable kernel memory, memory which will be allocated when
	  a disc is opened for writing.

	bool "Enable write caching"
	depends on CDROM_PKTCDVD
	  If enabled, write caching will be set for the CD-R/W device. For now
	  this option is dangerous unless the CD-RW media is known good, as we
	  don't do deferred write error handling yet.

	tristate "ATA over Ethernet support"
	depends on NET
	This driver provides Support for ATA over Ethernet block
	devices like the Coraid EtherDrive (R) Storage Blade.

config SUNVDC
	tristate "Sun Virtual Disk Client support"
	depends on SUN_LDOMS
	  Support for virtual disk devices as a client under Sun
	  Logical Domains.

source "drivers/s390/block/Kconfig"

	tristate "Xen virtual block device support"
	depends on XEN
	default y
	  This driver implements the front-end of the Xen virtual
	  block device driver.  It communicates with a back-end driver
	  in another domain which drives the actual block device.

	tristate "Xen block-device backend driver"
	depends on XEN_BACKEND
	  The block-device backend driver allows the kernel to export its
	  block devices to other guests via a high-performance shared-memory

	  The corresponding Linux frontend driver is enabled by the
	  CONFIG_XEN_BLKDEV_FRONTEND configuration option.

	  The backend driver attaches itself to a any block device specified
	  in the XenBus configuration. There are no limits to what the block
	  device as long as it has a major and minor.

	  If you are compiling a kernel to run in a Xen block backend driver
	  domain (often this is domain 0) you should say Y here. To
	  compile this driver as a module, chose M here: the module
	  will be called xen-blkback.

	tristate "Virtio block driver"
	depends on VIRTIO
	select SG_POOL
	  This is the virtual block driver for virtio.  It can be used with
          QEMU based VMMs (like KVM or Xen).  Say Y or M.

config BLK_DEV_RBD
	tristate "Rados block device (RBD)"
	depends on INET && BLOCK
	select CEPH_LIB
	select LIBCRC32C
	select CRYPTO_AES
	select CRYPTO
	  Say Y here if you want include the Rados block device, which stripes
	  a block device over objects stored in the Ceph distributed object

	  More information at

	  If unsure, say N.

	tristate "Userspace block driver (Experimental)"
	select IO_URING
	  io_uring based userspace block driver. Together with ublk server, ublk
	  has been working well, but interface with userspace or command data
	  definition isn't finalized yet, and might change according to future
	  requirement, so mark is as experimental now.

	  Say Y if you want to get better performance because task_work_add()
	  can be used in IO path for replacing io_uring cmd, which will become
	  shared between IO tasks and ubq daemon, meantime task_work_add() can
	  can handle batch more effectively, but task_work_add() isn't exported
	  for module, so ublk has to be built to kernel.

	bool "Support legacy command opcode"
	depends on BLK_DEV_UBLK
	default y
	  ublk driver started to take plain command encoding, which turns out
	  one bad way. The traditional ioctl command opcode encodes more
	  info and basically defines each code uniquely, so opcode conflict
	  is avoided, and driver can handle wrong command easily, meantime it
	  may help security subsystem to audit io_uring command.

	  Say Y if your application still uses legacy command opcode.

	  Say N if you don't want to support legacy command opcode. It is
	  suggested to enable N if your application(ublk server) switches to
	  ioctl command encoding.

source "drivers/block/rnbd/Kconfig"

endif # BLK_DEV