From: Zenghui Yu <yuzenghui@huawei.com>
To: Chenghai Huang <huangchenghai2@huawei.com>
Cc: <herbert@gondor.apana.org.au>, <davem@davemloft.net>,
<linux-kernel@vger.kernel.org>, <linux-crypto@vger.kernel.org>,
<fanghao11@huawei.com>, <liulongfang@huawei.com>,
<qianweili@huawei.com>
Subject: Re: [PATCH] crypto: hisilicon/sgl - fix inconsistent map/unmap direction issue
Date: Tue, 23 Dec 2025 20:37:01 +0800 [thread overview]
Message-ID: <7569c3cd-92ea-81c1-b57e-cebcacee66e7@huawei.com> (raw)
In-Reply-To: <20251219033619.1871450-1-huangchenghai2@huawei.com>
On 2025/12/19 11:36, Chenghai Huang wrote:
> Ensure that the direction for dma_map_sg and dma_unmap_sg is
> consistent.
>
> Fixes: 2566de3e06a3 ("crypto: hisilicon - Use fine grained DMA mapping direction")
> Signed-off-by: Chenghai Huang <huangchenghai2@huawei.com>
> ---
> drivers/crypto/hisilicon/sgl.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/crypto/hisilicon/sgl.c b/drivers/crypto/hisilicon/sgl.c
> index 24c7b6ab285b..d41b34405c21 100644
> --- a/drivers/crypto/hisilicon/sgl.c
> +++ b/drivers/crypto/hisilicon/sgl.c
> @@ -260,7 +260,7 @@ hisi_acc_sg_buf_map_to_hw_sgl(struct device *dev, struct scatterlist *sgl,
> return curr_hw_sgl;
>
> err_unmap:
> - dma_unmap_sg(dev, sgl, sg_n, DMA_BIDIRECTIONAL);
> + dma_unmap_sg(dev, sgl, sg_n, dir);
>
> return ERR_PTR(ret);
> }
Reviewed-by: Zenghui Yu <yuzenghui@huawei.com>
Thanks for fixing it!
Zenghui
next prev parent reply other threads:[~2025-12-23 12:37 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-19 3:36 [PATCH] crypto: hisilicon/sgl - fix inconsistent map/unmap direction issue Chenghai Huang
2025-12-23 12:37 ` Zenghui Yu [this message]
2026-01-16 6:06 ` Herbert Xu
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=7569c3cd-92ea-81c1-b57e-cebcacee66e7@huawei.com \
--to=yuzenghui@huawei.com \
--cc=davem@davemloft.net \
--cc=fanghao11@huawei.com \
--cc=herbert@gondor.apana.org.au \
--cc=huangchenghai2@huawei.com \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=liulongfang@huawei.com \
--cc=qianweili@huawei.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