linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/2] Introduce the bulk IV mode for improving the crypto engine efficiency
@ 2015-12-17  7:32 Baolin Wang
  2015-12-17  7:32 ` [PATCH v3 1/2] block: Introduce blk_bio_map_sg() to map one bio Baolin Wang
  2015-12-17  7:32 ` [PATCH v3 2/2] md: dm-crypt: Introduce the bulk IV mode for bulk crypto Baolin Wang
  0 siblings, 2 replies; 3+ messages in thread
From: Baolin Wang @ 2015-12-17  7:32 UTC (permalink / raw)
  To: axboe, agk, snitzer, dm-devel
  Cc: neilb, dan.j.williams, martin.petersen, sagig, kent.overstreet,
	keith.busch, tj, broonie, arnd, linux-block, linux-raid,
	linux-kernel, baolin.wang

From the dm-crypt performance report, we found it shows low efficiency
with crypto engine for some mode (like ecb or xts mode). Because in dm
crypt, it will map the IO data buffer with scatterlist, and send the
scatterlist of one bio to the encryption engine, if send more scatterlists
with bigger size at one time, that helps the engine palys best performance,
which means a high encryption speed.

But now the dm-crypt only map one segment (always one sector) of one bio
with one scatterlist to the crypto engine at one time. which is more
time-consuming and ineffective for the crypto engine. Especially for some
modes which don't need different IV for each sector, we can map the whole
bio with multiple scatterlists to improve the engine performance.

But this optimization is not support some ciphers and IV modes which should
do sector by sector and need different IV for each sector.

Change since v2:
 - Introduce blk_bio_map_sg() function to map one bio.
 - Do some modifications for checking sg entry. 

Baolin Wang (2):
  block: Introduce blk_bio_map_sg() to map one bio
  md: dm-crypt: Introduce the bulk IV mode for bulk crypto

 block/blk-merge.c      |   45 +++++++
 drivers/md/dm-crypt.c  |  333 +++++++++++++++++++++++++++++++++++++++++++++++-
 include/linux/blkdev.h |    3 +
 3 files changed, 375 insertions(+), 6 deletions(-)

-- 
1.7.9.5


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

end of thread, other threads:[~2015-12-17  7:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-12-17  7:32 [PATCH v3 0/2] Introduce the bulk IV mode for improving the crypto engine efficiency Baolin Wang
2015-12-17  7:32 ` [PATCH v3 1/2] block: Introduce blk_bio_map_sg() to map one bio Baolin Wang
2015-12-17  7:32 ` [PATCH v3 2/2] md: dm-crypt: Introduce the bulk IV mode for bulk crypto Baolin Wang

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).