]> git.ipfire.org Git - thirdparty/linux.git/commit
ublk: add DMA alignment limit
authorMing Lei <ming.lei@redhat.com>
Thu, 27 Feb 2025 10:37:07 +0000 (18:37 +0800)
committerJens Axboe <axboe@kernel.dk>
Mon, 3 Mar 2025 18:17:52 +0000 (11:17 -0700)
commite84025d2a9cb0d30baf3f59e341d426ef57a2cd7
tree9017a53fdd479f48348ffa1994bad2b609bd2e79
parent105ca2a2c2ff2c8df0e334d6913d62eec1973dd3
ublk: add DMA alignment limit

The in-tree ublk driver doesn't need DMA alignment limit because there
is one data copy between request pages and the userspace buffer.

However, ublk is going to support zero copy, then DMA alignment limit
is required, because same IO buffer is forwarded to backend which may
have specific buffer DMA alignment limit, so the limit has to be exposed
from the frontend driver to client application.

Cc: Keith Busch <kbusch@kernel.org>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20250227103707.2640014-1-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/ublk_drv.c
include/uapi/linux/ublk_cmd.h