Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1357872 > unrolled thread
| Started by | Baolin Wang <baolin.wang@linaro.org> |
|---|---|
| First post | 2016-03-15 08:50 +0100 |
| Last post | 2016-03-15 09:00 +0100 |
| Articles | 2 — 1 participant |
Back to article view | Back to linux.kernel
[PATCH v2 0/4] Introduce bulk mode for crypto engine framework Baolin Wang <baolin.wang@linaro.org> - 2016-03-15 08:50 +0100
[PATCH v2 4/4] md: dm-crypt: Initialize the sector number for one request Baolin Wang <baolin.wang@linaro.org> - 2016-03-15 09:00 +0100
| From | Baolin Wang <baolin.wang@linaro.org> |
|---|---|
| Date | 2016-03-15 08:50 +0100 |
| Subject | [PATCH v2 0/4] Introduce bulk mode for crypto engine framework |
| Message-ID | <rcRTQ-7sZ-9@gated-at.bofh.it> |
Now some cipher hardware engines prefer to handle bulk block by merging requests to increase the block size and thus increase the hardware engine processing speed. This patchset introduces request bulk mode to help the crypto hardware drivers improve in efficiency. Changes since v1: - Modify the sg_is_contiguous() function. Baolin Wang (4): scatterlist: Introduce some helper functions crypto: Introduce some helper functions to help to merge requests crypto: Introduce the bulk mode for crypto engine framework md: dm-crypt: Initialize the sector number for one request crypto/Kconfig | 1 + crypto/ablk_helper.c | 135 ++++++++++++++++++++++++++++++++++++++++++ crypto/crypto_engine.c | 122 +++++++++++++++++++++++++++++++++++++- drivers/crypto/omap-aes.c | 2 +- drivers/md/dm-crypt.c | 1 + include/crypto/ablk_helper.h | 3 + include/crypto/algapi.h | 23 ++++++- include/linux/crypto.h | 5 ++ include/linux/scatterlist.h | 33 +++++++++++ lib/scatterlist.c | 69 +++++++++++++++++++++ 10 files changed, 389 insertions(+), 5 deletions(-) -- 1.7.9.5
[toc] | [next] | [standalone]
| From | Baolin Wang <baolin.wang@linaro.org> |
|---|---|
| Date | 2016-03-15 09:00 +0100 |
| Subject | [PATCH v2 4/4] md: dm-crypt: Initialize the sector number for one request |
| Message-ID | <rcS3v-7wi-3@gated-at.bofh.it> |
| In reply to | #1357872 |
If the crypto engine can support the bulk mode, that means the contiguous requests from one block can be merged into one request to be handled by crypto engine. If so, the crypto engine need the sector number of one request to do merging action. Signed-off-by: Baolin Wang <baolin.wang@linaro.org> --- drivers/md/dm-crypt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-crypt.c b/drivers/md/dm-crypt.c index 3147c8d..9e2dbfd 100644 --- a/drivers/md/dm-crypt.c +++ b/drivers/md/dm-crypt.c @@ -866,6 +866,7 @@ static int crypt_convert_block(struct crypt_config *cc, return r; } + req->sector = ctx->cc_sector; ablkcipher_request_set_crypt(req, &dmreq->sg_in, &dmreq->sg_out, 1 << SECTOR_SHIFT, iv); -- 1.7.9.5
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web