block-status cache for data regions
Get series with b4
b4 am [email protected]Versions newest first
- v3 Latest6 patches 5 repliesIn review
Changes in v3 from the cover letter
- Patch 2:
- Add rcu_head object to BdrvBlockStatusCache, so we can use g_free_rcu() to free it instead of synchronize_rcu()+g_free()
- Use qatomic_rcu_read() every time we read bs->block_status_cache (except in bdrv_close(), where no concurrency is possible)
- Use RCU_READ_LOCK_GUARD() instead of WITH_RCU_READ_LOCK_GUARD() in functions where we lock the whole scope anyway
- Same for QEMU_LOCK_GUARD() instead of WITH_QEMU_LOCK_GUARD() in
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | block: Drop BDS comment regarding bdrv_append()include/ | +0 | 0 replies | |
| 2/6 | block: block-status cache for data regionsblock.c block/ include/ | +192 | 3 replies | |
| 3/6 | block: Clarify that @bytes is no limit on *pnuminclude/ | +9 | 1 reply | |
| 4/6 | block/file-posix: Do not force-cap *pnumblock/ | +4 | 0 replies | |
| 5/6 | block/gluster: Do not force-cap *pnumblock/ | +4 | 0 replies | |
| 6/6 | block/iscsi: Do not force-cap *pnumblock/ | +0 | 0 replies |
Reviews trailers per patch
All 6 patches have a Reviewed-by or Acked-by.
| Patch | Eric Blake | Vladimir Sementsov-Ogievskiy | Kevin Wolf |
|---|---|---|---|
| 1/6 | R-b | R-b | R-b |
| 2/6 | R-b | R-b | |
| 3/6 | R-b | R-b | |
| 4/6 | R-b | R-b | R-b |
| 5/6 | R-b | R-b | R-b |
| 6/6 | R-b | R-b | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.
Cover letter [PATCH v3 0/6] block-status cache for data regions
Hi,
See the cover letter from v1 for the general idea:
https://lists.nongnu.org/archive/html/qemu-block/2021-06/msg00843.html
Cover letter from v2, introducing RCU locking:
https://lists.nongnu.org/archive/html/qemu-block/2021-06/msg01060.html
v3:
- Patch 2:
- Add rcu_head object to BdrvBlockStatusCache, so we can use g_free_rcu() to free it instead of synchronize_rcu()+g_free()
- Use qatomic_rcu_read() every time we read bs->block_status_cache (except in bdrv_close(), where no concurrency is possible)
- Use RCU_READ_LOCK_GUARD() instead of WITH_RCU_READ_LOCK_GUARD() in functions where we lock the whole scope anyway
- Same for QEMU_LOCK_GUARD() instead of WITH_QEMU_LOCK_GUARD() in
bdrv_bsc_fill()
- Drop from_cache variable in bdrv_co_block_status() (was an artifact from v1, which had a different control flow and needed this variable)
- Assert that local_map returned from a protocol driver’s bdrv_co_block_status() implementation is equal to the offset we passed to it (see comment there for why we should do this)
- Patch 3:
- Add note why block drivers should return larger *pnum values in addition to just saying that it’s allowed
git-backport-diff against v2:
Key:
[----] : patches are identical
[####] : number of functional differences between upstream/downstream patch [down] : patch is downstream-only
The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively
001/6:[----] [--] 'block: Drop BDS comment regarding bdrv_append()' 002/6:[0063] [FC] 'block: block-status cache for data regions' 003/6:[0004] [FC] 'block: Clarify that @bytes is no limit on *pnum' 004/6:[----] [--] 'block/file-posix: Do not force-cap *pnum' 005/6:[----] [--] 'block/gluster: Do not force-cap *pnum' 006/6:[----] [--] 'block/iscsi: Do not force-cap *pnum'
Hanna Reitz (6):
block: Drop BDS comment regarding bdrv_append()
block: block-status cache for data regions
block: Clarify that @bytes is no limit on *pnum
block/file-posix: Do not force-cap *pnum
block/gluster: Do not force-cap *pnum
block/iscsi: Do not force-cap *pnum
include/block/block_int.h | 61 +++++++++++++++++++++++++++-- block.c | 80 +++++++++++++++++++++++++++++++++++++++ block/file-posix.c | 7 ++-- block/gluster.c | 7 ++-- block/io.c | 65 +++++++++++++++++++++++++++++-- block/iscsi.c | 3 -- 6 files changed, 207 insertions(+), 16 deletions(-)
Signature · 1 line
2.31.1