Commit cc25df3e authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'for-6.19/block-20251201' of git://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux

Pull block updates from Jens Axboe:

 - Fix head insertion for mq-deadline, a regression from when priority
   support was added

 - Series simplifying and improving the ublk user copy code

 - Various ublk related cleanups

 - Fixup REQ_NOWAIT handling in loop/zloop, clearing NOWAIT when the
   request is punted to a thread for handling

 - Merge and then later revert loop dio nowait support, as it ended up
   causing excessive stack usage for when the inline issue code needs to
   dip back into the full file system code

 - Improve auto integrity code, making it less deadlock prone

 - Speedup polled IO handling, but manually managing the hctx lookups

 - Fixes for blk-throttle for SSD devices

 - Small series with fixes for the S390 dasd driver

 - Add support for caching zones, avoiding unnecessary report zone
   queries

 - MD pull requests via Yu:
      - fix null-ptr-dereference regression for dm-raid0
      - fix IO hang for raid5 when array is broken with IO inflight
      - remove legacy 1s delay to speed up system shutdown
      - change maintainer's email address
      - data can be lost if array is created with different lbs devices,
        fix this problem and record lbs of the array in metadata
      - fix rcu protection for md_thread
      - fix mddev kobject lifetime regression
      - enable atomic writes for md-linear
      - some cleanups

 - bcache updates via Coly
      - remove useless discard and cache device code
      - improve usage of per-cpu workqueues

 - Reorganize the IO scheduler switching code, fixing some lockdep
   reports as well

 - Improve the block layer P2P DMA support

 - Add support to the block tracing code for zoned devices

 - Segment calculation improves, and memory alignment flexibility
   improvements

 - Set of prep and cleanups patches for ublk batching support. The
   actual batching hasn't been added yet, but helps shrink down the
   workload of getting that patchset ready for 6.20

 - Fix for how the ps3 block driver handles segments offsets

 - Improve how block plugging handles batch tag allocations

 - nbd fixes for use-after-free of the configuration on device clear/put

 - Set of improvements and fixes for zloop

 - Add Damien as maintainer of the block zoned device code handling

 - Various other fixes and cleanups

* tag 'for-6.19/block-20251201' of git://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux: (162 commits)
  block/rnbd: correct all kernel-doc complaints
  blk-mq: use queue_hctx in blk_mq_map_queue_type
  md: remove legacy 1s delay in md_notify_reboot
  md/raid5: fix IO hang when array is broken with IO inflight
  md: warn about updating super block failure
  md/raid0: fix NULL pointer dereference in create_strip_zones() for dm-raid
  sbitmap: fix all kernel-doc warnings
  ublk: add helper of __ublk_fetch()
  ublk: pass const pointer to ublk_queue_is_zoned()
  ublk: refactor auto buffer register in ublk_dispatch_req()
  ublk: add `union ublk_io_buf` with improved naming
  ublk: add parameter `struct io_uring_cmd *` to ublk_prep_auto_buf_reg()
  kfifo: add kfifo_alloc_node() helper for NUMA awareness
  blk-mq: fix potential uaf for 'queue_hw_ctx'
  blk-mq: use array manage hctx map instead of xarray
  ublk: prevent invalid access with DEBUG
  s390/dasd: Use scnprintf() instead of sprintf()
  s390/dasd: Move device name formatting into separate function
  s390/dasd: Remove unnecessary debugfs_create() return checks
  s390/dasd: Fix gendisk parent after copy pair swap
  ...
parents 0abcfd89 d211a280
Loading
Loading
Loading
Loading
+0 −7
Original line number Diff line number Diff line
@@ -106,13 +106,6 @@ Description:
		will be discarded from the cache. Should not be turned off with
		writeback caching enabled.

What:		/sys/block/<disk>/bcache/discard
Date:		November 2010
Contact:	Kent Overstreet <kent.overstreet@gmail.com>
Description:
		For a cache, a boolean allowing discard/TRIM to be turned off
		or back on if the device supports it.

What:		/sys/block/<disk>/bcache/bucket_size
Date:		November 2010
Contact:	Kent Overstreet <kent.overstreet@gmail.com>
+2 −11
Original line number Diff line number Diff line
@@ -17,8 +17,7 @@ The latest bcache kernel code can be found from mainline Linux kernel:
It's designed around the performance characteristics of SSDs - it only allocates
in erase block sized buckets, and it uses a hybrid btree/log to track cached
extents (which can be anywhere from a single sector to the bucket size). It's
designed to avoid random writes at all costs; it fills up an erase block
sequentially, then issues a discard before reusing it.
designed to avoid random writes at all costs.

Both writethrough and writeback caching are supported. Writeback defaults to
off, but can be switched on and off arbitrarily at runtime. Bcache goes to
@@ -618,19 +617,11 @@ bucket_size
cache_replacement_policy
  One of either lru, fifo or random.

discard
  Boolean; if on a discard/TRIM will be issued to each bucket before it is
  reused. Defaults to off, since SATA TRIM is an unqueued command (and thus
  slow).

freelist_percent
  Size of the freelist as a percentage of nbuckets. Can be written to to
  increase the number of buckets kept on the freelist, which lets you
  artificially reduce the size of the cache at runtime. Mostly for testing
  purposes (i.e. testing how different size caches affect your hit rate), but
  since buckets are discarded when they move on to the freelist will also make
  the SSD's garbage collection easier by effectively giving it more reserved
  space.
  purposes (i.e. testing how different size caches affect your hit rate).

io_errors
  Number of errors that have occurred, decayed by io_error_halflife.
+37 −24
Original line number Diff line number Diff line
@@ -68,30 +68,43 @@ The options available for the add command can be listed by reading the
In more details, the options that can be used with the "add" command are as
follows.

================   ===========================================================
===================   =========================================================
id                    Device number (the X in /dev/zloopX).
                      Default: automatically assigned.
capacity_mb        Device total capacity in MiB. This is always rounded up to
                   the nearest higher multiple of the zone size.
capacity_mb           Device total capacity in MiB. This is always rounded up
                      to the nearest higher multiple of the zone size.
                      Default: 16384 MiB (16 GiB).
zone_size_mb          Device zone size in MiB. Default: 256 MiB.
zone_capacity_mb   Device zone capacity (must always be equal to or lower than
                   the zone size. Default: zone size.
conv_zones         Total number of conventioanl zones starting from sector 0.
                   Default: 8.
zone_capacity_mb      Device zone capacity (must always be equal to or lower
                      than the zone size. Default: zone size.
conv_zones            Total number of conventioanl zones starting from
                      sector 0
                      Default: 8
base_dir              Path to the base directory where to create the directory
                      containing the zone files of the device.
                      Default=/var/local/zloop.
                      The device directory containing the zone files is always
                      named with the device ID. E.g. the default zone file
                      directory for /dev/zloop0 is /var/local/zloop/0.
nr_queues          Number of I/O queues of the zoned block device. This value is
                   always capped by the number of online CPUs
nr_queues             Number of I/O queues of the zoned block device. This
                      value is always capped by the number of online CPUs
                      Default: 1
queue_depth           Maximum I/O queue depth per I/O queue.
                      Default: 64
buffered_io           Do buffered IOs instead of direct IOs (default: false)
================   ===========================================================
zone_append           Enable or disable a zloop device native zone append
                      support.
                      Default: 1 (enabled).
                      If native zone append support is disabled, the block layer
                      will emulate this operation using regular write
                      operations.
ordered_zone_append   Enable zloop mitigation of zone append reordering.
                      Default: disabled.
                      This is useful for testing file systems file data mapping
                      (extents), as when enabled, this can significantly reduce
                      the number of data extents needed to for a file data
                      mapping.
===================   =========================================================

3) Deleting a Zoned Device
--------------------------
+10 −0
Original line number Diff line number Diff line
@@ -238,6 +238,16 @@ All md devices contain:
     the number of devices in a raid4/5/6, or to support external
     metadata formats which mandate such clipping.

  logical_block_size
     Configure the array's logical block size in bytes. This attribute
     is only supported for 1.x meta. Write the value before starting
     array. The final array LBS uses the maximum between this
     configuration and LBS of all combined devices. Note that
     LBS cannot exceed PAGE_SIZE before RAID supports folio.
     WARNING: Arrays created on new kernel cannot be assembled at old
     kernel due to padding check, Set module parameter 'check_new_feature'
     to false to bypass, but data loss may occur.

  reshape_position
     This is either ``none`` or a sector number within the devices of
     the array where ``reshape`` is up to.  If this is set, the three
+11 −2
Original line number Diff line number Diff line
@@ -4307,7 +4307,7 @@ F: Documentation/filesystems/befs.rst
F:	fs/befs/
BFQ I/O SCHEDULER
M:	Yu Kuai <yukuai3@huawei.com>
M:	Yu Kuai <yukuai@fnnas.com>
L:	linux-block@vger.kernel.org
S:	Odd Fixes
F:	Documentation/block/bfq-iosched.rst
@@ -4407,6 +4407,8 @@ F: block/
F:	drivers/block/
F:	include/linux/bio.h
F:	include/linux/blk*
F:	include/uapi/linux/blk*
F:	include/uapi/linux/ioprio.h
F:	kernel/trace/blktrace.c
F:	lib/sbitmap.c
@@ -23908,7 +23910,7 @@ F: include/linux/property.h
SOFTWARE RAID (Multiple Disks) SUPPORT
M:	Song Liu <song@kernel.org>
M:	Yu Kuai <yukuai3@huawei.com>
M:	Yu Kuai <yukuai@fnnas.com>
L:	linux-raid@vger.kernel.org
S:	Supported
Q:	https://patchwork.kernel.org/project/linux-raid/list/
@@ -28371,6 +28373,13 @@ L: linux-kernel@vger.kernel.org
S:	Maintained
F:	arch/x86/kernel/cpu/zhaoxin.c
ZONED BLOCK DEVICE (BLOCK LAYER)
M:	Damien Le Moal <dlemoal@kernel.org>
L:	linux-block@vger.kernel.org
S:	Maintained
F:	block/blk-zoned.c
F:	include/uapi/linux/blkzoned.h
ZONED LOOP DEVICE
M:	Damien Le Moal <dlemoal@kernel.org>
R:	Christoph Hellwig <hch@lst.de>
Loading