[PATCH 0/4] ublk: refactor __ublk_ch_uring_cmd

Uday Shankar posted 4 patches 7 months, 3 weeks ago
drivers/block/ublk_drv.c | 133 +++++++++++++++++++++++------------------------
1 file changed, 65 insertions(+), 68 deletions(-)
[PATCH 0/4] ublk: refactor __ublk_ch_uring_cmd
Posted by Uday Shankar 7 months, 3 weeks ago
Refactor __ublk_ch_uring_cmd to:

- Have one function per operation instead of handling operations
  directly in the switch statement.
- Mark most ublk_queue pointers as const. Given efforts to allow
  concurrent operations on one ublk_queue [1], it is important that
  ublk_queue be read-only (or accesses to it be properly synchronized)
  to avoid data races.

This series is split off from [1]. No functional changes are expected.

[1] https://lore.kernel.org/linux-block/20250416-ublk_task_per_io-v5-0-9261ad7bff20@purestorage.com/

Signed-off-by: Uday Shankar <ushankar@purestorage.com>
---
Uday Shankar (4):
      ublk: factor out ublk_commit_and_fetch
      ublk: mark ublk_queue as const for ublk_register_io_buf
      ublk: factor out ublk_get_data
      ublk: factor out error handling in __ublk_ch_uring_cmd

 drivers/block/ublk_drv.c | 133 +++++++++++++++++++++++------------------------
 1 file changed, 65 insertions(+), 68 deletions(-)
---
base-commit: edbaa72ba1bd21040df81f7c63851093264c7955
change-id: 20250421-ublk_constify-33ee1a6486ac

Best regards,
-- 
Uday Shankar <ushankar@purestorage.com>
Re: [PATCH 0/4] ublk: refactor __ublk_ch_uring_cmd
Posted by Uday Shankar 7 months, 3 weeks ago
Hi Jens,

Can this series get queued up? They all have reviews from Caleb and/or
Ming.
Re: [PATCH 0/4] ublk: refactor __ublk_ch_uring_cmd
Posted by Jens Axboe 7 months, 3 weeks ago
On 4/24/25 3:50 PM, Uday Shankar wrote:
> Hi Jens,
> 
> Can this series get queued up? They all have reviews from Caleb and/or
> Ming.

It can, but I was assuming we'd have conflicts between 6.16 ublk patches
and what is queued up in block-6.15. And looks like I'm right... I'll
merge block-6.15 into for-6.16/block, and then please re-post a version
against that.

-- 
Jens Axboe