linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH V6 0/3] md/raid10: Improve handling raid10 discard request
@ 2020-09-02 12:00 Xiao Ni
  2020-09-02 12:00 ` [PATCH V6 1/3] md: calculate discard start address and size in specific raid type Xiao Ni
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Xiao Ni @ 2020-09-02 12:00 UTC (permalink / raw)
  To: linux-raid, song; +Cc: heinzm, ncroxon, guoqing.jiang, colyli

Hi all

Now mkfs on raid10 which is combined with ssd/nvme disks takes a long time.
This patch set tries to resolve this problem.

v1:
Coly helps to review these patches and give some suggestions:
One bug is found. If discard bio is across one stripe but bio size is
bigger than one stripe size. After spliting, the bio will be NULL.
In this version, it checks whether discard bio size is bigger than
(2*stripe_size). 
In raid10_end_discard_request, it's better to check R10BIO_Uptodate
is set or not. It can avoid write memory to improve performance. 
Add more comments for calculating addresses.

v2:
Fix error by checkpatch.pl
Fix one bug for offset layout. v1 calculates wrongly split size
Add more comments to explain how the discard range of each component disk
is decided.

v3:
add support for far layout
Change the patch name

v4:
Pull codes that wait for blocked device into a seprate function
It can't use (stripe_size-1) as a mask to calculate. (stripe_size-1) may
not be power of 2.
It doesn't need to use a full copy of geo.
Fix warning by checkpatch.pl

v5:
In 32bit platform, it doesn't support 64bit devide by 32bit value.
Reported-by: kernel test robot <lkp@intel.com>

v6:
Move the codes that calculate discard start/size into specific raid type.
Remove discard support for reshape

Xiao Ni (3):
  md: calculate discard start address and size in specific raid type
  md/raid10: improve raid10 discard request
  md/raid10: improve discard request for far layout

 drivers/md/md.c     |   9 +-
 drivers/md/md.h     |   3 +-
 drivers/md/raid0.c  |   5 +-
 drivers/md/raid10.c | 296 +++++++++++++++++++++++++++++++++++++++++++++++++++-
 drivers/md/raid10.h |   1 +
 5 files changed, 303 insertions(+), 11 deletions(-)

-- 
2.7.5


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-09-15  6:29 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-02 12:00 [PATCH V6 0/3] md/raid10: Improve handling raid10 discard request Xiao Ni
2020-09-02 12:00 ` [PATCH V6 1/3] md: calculate discard start address and size in specific raid type Xiao Ni
2020-09-02 12:00 ` [PATCH V6 2/3] md/raid10: improve raid10 discard request Xiao Ni
2020-09-02 12:00 ` [PATCH V6 3/3] md/raid10: improve discard request for far layout Xiao Ni
2020-09-02 12:04 ` [PATCH V6 0/3] md/raid10: Improve handling raid10 discard request Xiao Ni
2020-09-15  6:29 ` Song Liu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).