Skip to content

md: cleanup on direct access to bvec table

Ming Lei linux-block linux-raid 4 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest14 patches 20 repliesIn review
  2. v2 posting 2/213 patches 25 repliesSuperseded
  3. v2 posting 1/20 of 14 patches 0 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v114 patches4 repliesSuperseded

Changes in v3 from the cover letter

- improve pages allocation & bio clone for write behind(10/14)
- retrieve pages from preallocated page array, and avoid to user bio helpers(14/14)
- change on helpers about managing resync io pages(03/14)

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/14md: raid1/raid10: don't handle failure of bio_add_page()drivers/md/raid1.c drivers/md/raid10.c+16 -461 reply
2/14md: move two macros into md.hdrivers/md/md.h drivers/md/raid1.c drivers/md/raid10.c+5 -55 replies
3/14md: prepare for managing resync I/O pages in clean waydrivers/md/md.h+50 -01 reply
4/14md: raid1: simplify r1buf_pool_free()drivers/md/raid1.c+7 -80 replies
5/14md: raid1: don't use bio's vec table to manage resync pagesdrivers/md/raid1.c+64 -3011 replies
6/14md: raid1: retrieve page from pre-allocated resync page arraydrivers/md/raid1.c+8 -80 replies
7/14md: raid1: use bio helper in process_checks()drivers/md/raid1.c+8 -40 replies
8/14block: introduce bio_copy_data_partialblock/bio.c include/linux/bio.h+49 -132 replies
9/14md: raid1: move 'offset' out of loopdrivers/md/raid1.c+3 -20 replies
10/14md: raid1: improve write behinddrivers/md/raid1.c drivers/md/raid1.h+61 -670 replies
11/14md: raid10: refactor code of read reshape's .bi_end_iodrivers/md/raid10.c+18 -100 replies
12/14md: raid10: don't use bio's vec table to manage resync pagesdrivers/md/raid10.c+82 -520 replies
13/14md: raid10: retrieve page from preallocated resync page arraydrivers/md/raid10.c+9 -40 replies
14/14md: raid10: avoid direct access to bvec table in handle_reshape_read_errordrivers/md/raid10.c+5 -20 replies

Reviews trailers per patch

2 of 14 patches have a Reviewed-by or Acked-by.

PatchJens AxboeChristoph Hellwig
1/14R-b
2/14
3/14
4/14
5/14
6/14
7/14
8/14R-b
9/14
10/14
11/14
12/14
13/14
14/14

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

Read the v3 thread

Cover letter [PATCH v3 00/14] md: cleanup on direct access to bvec table

In MD's resync I/O path, there are lots of direct access to bio's bvec table. This patchset kills almost all, and the conversion is quite straightforward. One root cause of direct access to bvec table is that resync I/O uses the bio's bvec to manage pages. In V1, as suggested by Shaohua, a new approach is used to manage these pages for resync I/O, turns out code becomes more clean and readable.

Once direct access to bvec table in MD is cleaned up, we may make multipage bvec moving on.

V3:
- improve pages allocation & bio clone for write behind(10/14)
- retrieve pages from preallocated page array, and avoid to user bio helpers(14/14)
- change on helpers about managing resync io pages(03/14)

V2:
- remove the patch for introducing/applying bio_remove_last_page()

V1:
- allocate page array to manage resync pages

Thanks,
Ming

Ming Lei (14):
md: raid1/raid10: don't handle failure of bio_add_page()
md: move two macros into md.h
md: prepare for managing resync I/O pages in clean way
md: raid1: simplify r1buf_pool_free()
md: raid1: don't use bio's vec table to manage resync pages
md: raid1: retrieve page from pre-allocated resync page array
md: raid1: use bio helper in process_checks()
block: introduce bio_copy_data_partial
md: raid1: move 'offset' out of loop
md: raid1: improve write behind
md: raid10: refactor code of read reshape's .bi_end_io
md: raid10: don't use bio's vec table to manage resync pages
md: raid10: retrieve page from preallocated resync page array
md: raid10: avoid direct access to bvec table in
handle_reshape_read_error

 block/bio.c         |  60 +++++++++---
 drivers/md/md.h     |  55 +++++++++++
 drivers/md/raid1.c  | 267 ++++++++++++++++++++++++++++------------------------
 drivers/md/raid1.h  |  10 +-
 drivers/md/raid10.c | 224 +++++++++++++++++++++++--------------------
 include/linux/bio.h |   2 +
 6 files changed, 376 insertions(+), 242 deletions(-)
Signature · 1 line
2.9.3