From: Sahil Malhotra <sahil.malhotra@oss.nxp.com>
To: Changwei Zou <changwei.zou@canonical.com>
Cc: herbert@gondor.apana.org.au, davem@davemloft.net,
horia.geanta@nxp.com, pankaj.gupta@nxp.com, gaurav.jain@nxp.com,
iuliana.prodan@nxp.com, jeffbarnes@linux.microsoft.com,
stephane.debusne@cynove.com,
martin.kepplinger-novakovic@ginzinger.com, lukas@wunner.de,
linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v6 2/2] crypto: caam - Use bounce buffer for unaligned RSA destination buffers
Date: Mon, 16 Nov 2026 19:05:23 +0100 [thread overview]
Message-ID: <20261116180523.863575-1-sahil.malhotra@oss.nxp.com> (raw)
In-Reply-To: <20261114060032.872141-3-changwei.zou@canonical.com>
On Sat, Nov 14, 2026 at 05:00:32PM +1100, Changwei Zou wrote:
> The rsa-caam driver directly DMA-maps the destination buffer supplied by
> the caller via req->dst without checking whether it meets the cacheline
> alignment requirements of DMA-incoherent hardware such as i.MX8.
Hi Changwei,
Thanks for v6. Using req_ctx->fixup_dst instead of swapping req->dst
makes this much cleaner, and the commit message now explains why the
DMA API does not catch this case.
I re-checked all completion and error paths: the DMA unmap always
happens before the copy-back/free, the -ENOSPC retry and -EBUSY
backlog paths keep the bounce buffer alive, and the new bounce_fail
label also fixes the src-map-failure path.
Reviewed-by: Sahil Malhotra <sahil.malhotra@nxp.com>
Thanks,
Sahil
next prev parent reply other threads:[~2026-11-16 18:05 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-14 6:00 [PATCH v6 0/2] crypto: caam - Fix RSA error-path unmap and unaligned dst buffers Changwei Zou
2026-11-14 6:00 ` [PATCH v6 1/2] crypto: caam - Fix wrong unmap operations Changwei Zou
2026-11-16 18:05 ` Sahil Malhotra
2026-11-14 6:00 ` [PATCH v6 2/2] crypto: caam - Use bounce buffer for unaligned RSA destination buffers Changwei Zou
2026-11-16 18:05 ` Sahil Malhotra [this message]
2026-11-18 23:13 ` Changwei Zou
2026-11-20 9:29 ` [PATCH v6 0/2] crypto: caam - Fix RSA error-path unmap and unaligned dst buffers Herbert Xu
2026-11-20 11:20 ` Changwei Zou
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=20261116180523.863575-1-sahil.malhotra@oss.nxp.com \
--to=sahil.malhotra@oss.nxp.com \
--cc=changwei.zou@canonical.com \
--cc=davem@davemloft.net \
--cc=gaurav.jain@nxp.com \
--cc=herbert@gondor.apana.org.au \
--cc=horia.geanta@nxp.com \
--cc=iuliana.prodan@nxp.com \
--cc=jeffbarnes@linux.microsoft.com \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lukas@wunner.de \
--cc=martin.kepplinger-novakovic@ginzinger.com \
--cc=pankaj.gupta@nxp.com \
--cc=stephane.debusne@cynove.com \
/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
all inboxes | Powered by JetHome®