Skip to content

Commit ddc1dff

Browse files
committed
Merge branch 'for-7.1/block' into for-next
* for-7.1/block: MAINTAINERS: update ublk driver maintainer email Documentation: ublk: address review comments for SHMEM_ZC docs ublk: allow buffer registration before device is started ublk: replace xarray with IDA for shmem buffer index allocation ublk: simplify PFN range loop in __ublk_ctrl_reg_buf ublk: verify all pages in multi-page bvec fall within registered range ublk: widen ublk_shmem_buf_reg.len to __u64 for 4GB buffer support
2 parents 7eb7e8a + b774765 commit ddc1dff

4 files changed

Lines changed: 102 additions & 111 deletions

File tree

Documentation/block/ublk.rst

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -492,8 +492,8 @@ The ``UBLK_F_SHMEM_ZC`` feature provides an alternative zero-copy path
492492
that works by sharing physical memory pages between the client application
493493
and the ublk server. Unlike the io_uring fixed buffer approach above,
494494
shared memory zero copy does not require io_uring buffer registration
495-
per I/O — instead, it relies on the kernel matching page frame numbers
496-
(PFNs) at I/O time. This allows the ublk server to access the shared
495+
per I/O — instead, it relies on the kernel matching physical pages
496+
at I/O time. This allows the ublk server to access the shared
497497
buffer directly, which is unlikely for the io_uring fixed buffer
498498
approach.
499499

@@ -507,8 +507,7 @@ tells the server where the data already lives.
507507

508508
``UBLK_F_SHMEM_ZC`` can be thought of as a supplement for optimized client
509509
applications — when the client is willing to allocate I/O buffers from
510-
shared memory, the entire data path becomes zero-copy without any per-I/O
511-
overhead.
510+
shared memory, the entire data path becomes zero-copy.
512511

513512
Use Cases
514513
~~~~~~~~~
@@ -584,6 +583,9 @@ Limitations
584583
the page cache, which allocates its own pages. These kernel-allocated
585584
pages will never match the registered shared buffer. Only ``O_DIRECT``
586585
puts the client's buffer pages directly into the block I/O.
586+
- **Contiguous data only**: each I/O request's data must be contiguous
587+
within a single registered buffer. Scatter/gather I/O that spans
588+
multiple non-adjacent registered buffers cannot use the zero-copy path.
587589

588590
Control Commands
589591
~~~~~~~~~~~~~~~~

MAINTAINERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27013,7 +27013,7 @@ F: Documentation/filesystems/ubifs.rst
2701327013
F: fs/ubifs/
2701427014

2701527015
UBLK USERSPACE BLOCK DRIVER
27016-
M: Ming Lei <ming.lei@redhat.com>
27016+
M: Ming Lei <tom.leiming@gmail.com>
2701727017
L: linux-block@vger.kernel.org
2701827018
S: Maintained
2701927019
F: Documentation/block/ublk.rst

0 commit comments

Comments
 (0)