From: Vakul Garg <vakul@freescale.com>
To: <linux-crypto@vger.kernel.org>
Subject: [PATCH 1/2] crypto: caam - Fix DMA size in descriptor in ahash_digest()
Date: Fri, 11 Jan 2013 15:33:56 +0530 [thread overview]
Message-ID: <1357898637-18971-2-git-send-email-vakul@freescale.com> (raw)
In-Reply-To: <1357898637-18971-1-git-send-email-vakul@freescale.com>
From: Steve Cornelius <steve.cornelius@freescale.com>
Save of DMA size in extended descriptor was missing.
Thus crashes could occur during post-request unmapping.
Signed-off-by: Steve Cornelius <steve.cornelius@freescale.com>
---
drivers/crypto/caam/caamhash.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/drivers/crypto/caam/caamhash.c b/drivers/crypto/caam/caamhash.c
index 32aba7a..6a26b6b 100644
--- a/drivers/crypto/caam/caamhash.c
+++ b/drivers/crypto/caam/caamhash.c
@@ -1065,6 +1065,7 @@ static int ahash_digest(struct ahash_request *req)
DESC_JOB_IO_LEN;
edesc->sec4_sg_dma = dma_map_single(jrdev, edesc->sec4_sg,
sec4_sg_bytes, DMA_TO_DEVICE);
+ edesc->sec4_sg_bytes = sec4_sg_bytes;
edesc->src_nents = src_nents;
edesc->chained = chained;
--
1.7.7.6
next prev parent reply other threads:[~2013-01-11 10:06 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-11 10:03 [PATCH 0/2] crypto: caam - Fix bugs in hashing module Vakul Garg
2013-01-11 10:03 ` Vakul Garg [this message]
2013-02-27 16:07 ` [PATCH 1/2] crypto: caam - Fix DMA size in descriptor in ahash_digest() Horia Geantă
2013-01-11 10:03 ` [PATCH 2/2] crypto: caam - improve init for context state saves Vakul Garg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1357898637-18971-2-git-send-email-vakul@freescale.com \
--to=vakul@freescale.com \
--cc=linux-crypto@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).