Skip to content

null_blk: zone resource management fixes

Niklas Cassel linux-block 2 versions – Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 3 repliesApplied
  2. v12 patches 4 repliesSuperseded

Changes in v2 from the cover letter

- Picked up Reviewed-by tags from Damien on patches 1 and 2.
- New patch 3, a cleanup suggested by Damien.

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/3null_blk: fix opening closed zones at the active zone limitdrivers/block/null_blk/zoned.c+7 -60 replies
2/3null_blk: don't finish zones to set them read-only or offlinedrivers/block/null_blk/zoned.c+30 -50 replies
3/3null_blk: clean up setting zones read-only or offlinedrivers/block/null_blk/zoned.c+12 -91 reply

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchDamien Le Moal
1/3R-b
2/3R-b
3/3R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/3] null_blk: zone resource management fixes

Patch 1 fixes writing, opening and finishing a closed zone when both the open and the active zone limits are reached: null_blk fails the request instead of closing an implicitly open zone, as ZBC-3 and NVMe ZNS require.

Patch 2 fixes zone_readonly and zone_offline, which can close an unrelated zone, or leak the closed zone count.

Patch 3 cleans up the code that sets zones read-only or offline, with no functional change.

Both issues were reproduced, and the fixes tested, in QEMU, with null_blk devices created through configfs (memory_backed=0 and 1, CONFIG_PROVE_LOCKING=y).

Developed with the help of an AI coding assistant.

Changes since v1:
- Picked up Reviewed-by tags from Damien on patches 1 and 2.
- New patch 3, a cleanup suggested by Damien.

Niklas Cassel (3):
null_blk: fix opening closed zones at the active zone limit
null_blk: don't finish zones to set them read-only or offline
null_blk: clean up setting zones read-only or offline

 drivers/block/null_blk/zoned.c | 63 +++++++++++++++++++++++++---------
 1 file changed, 46 insertions(+), 17 deletions(-)

base-commit: f47d223627f80cb7a1eb14c585fe6cb35de5e984

Signature · 1 line
2.56.0