io/channel: complete pread/pwrite_all API and fix multifd_file_recv_data
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest4 patches 13 repliesIn review
- v23 patches 5 repliesSuperseded
- v11 patch 2 repliesSuperseded
Changes in v3 from the cover letter
- Added qio_channel_pread_all_eof() to complete the API set (Daniel)
- Added pwrite_all / pwritev_all variants (Daniel)
- Reworked doc comments to match existing API style (Daniel)
- Added Fixes tag, expanded _eof test coverage, added CONFIG_PREADV guard
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | io/channel: introduce qio_channel_pread{v, }_all{, _eof}()include/ io/ | +183 | 2 replies | |
| 2/4 | io/channel: introduce qio_channel_pwrite{v,}_all()include/ io/ | +89 | 2 replies | |
| 3/4 | migration/file: fix type mismatch and NULL deref in multifd_file_recv_datamigration/ | +7 | 1 reply | |
| 4/4 | tests/unit: add pread/pwrite _all tests for io channel filetests/ | +207 | 2 replies |
Reviews trailers per patch
All 4 patches have a Reviewed-by or Acked-by.
| Patch | Daniel P. Berrangé | Fabiano Rosas |
|---|---|---|
| 1/4 | R-b A-b | R-b |
| 2/4 | R-b A-b | R-b |
| 3/4 | R-b | R-b |
| 4/4 | R-b A-b | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v3 0/4] io/channel: complete pread/pwrite_all API and fix multifd_file_recv_data
This series fixes two bugs in multifd_file_recv_data() and completes the positioned read/write "all" API set for QIO channels.
Bug summary:
- size_t variable storing ssize_t return: -1 wraps to SIZE_MAX
- error_prepend() called without ERRP_GUARD(): NULL deref on short read
Changes since v2:
- Added qio_channel_pread_all_eof() to complete the API set (Daniel)
- Added pwrite_all / pwritev_all variants (Daniel)
- Reworked doc comments to match existing API style (Daniel)
- Added Fixes tag, expanded _eof test coverage, added CONFIG_PREADV guard
Changes since v1:
- Used approach (b): add pread_all API instead of local retry loop (Daniel, Peter)
v2: https://lore.kernel.org/qemu-devel/[email protected]/
v1: https://lore.kernel.org/qemu-devel/[email protected]/
Junjie Cao (4):
io/channel: introduce qio_channel_pread{v,}_all{,_eof}() io/channel: introduce qio_channel_pwrite{v,}_all() migration/file: fix type mismatch and NULL deref in
multifd_file_recv_data
tests/unit: add pread/pwrite _all tests for io channel file
include/io/channel.h | 133 +++++++++++++++++++ io/channel.c | 139 ++++++++++++++++++++ migration/file.c | 13 +- tests/unit/test-io-channel-file.c | 207 ++++++++++++++++++++++++++++++ 4 files changed, 486 insertions(+), 6 deletions(-)
Signature · 1 line
2.43.0