linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kai Ye <yekai13@huawei.com>
To: <herbert@gondor.apana.org.au>
Cc: <linux-crypto@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	<yekai13@huawei.com>
Subject: [PATCH v3 4/5] crypto: hisilicon/sgl - fix the soft sg map to hardware sg
Date: Fri, 9 Apr 2021 17:04:03 +0800	[thread overview]
Message-ID: <1617959044-11023-5-git-send-email-yekai13@huawei.com> (raw)
In-Reply-To: <1617959044-11023-1-git-send-email-yekai13@huawei.com>

The buffer of the hardware sge needs to be initialized by
soft sgl.

Signed-off-by: Kai Ye <yekai13@huawei.com>
---
 drivers/crypto/hisilicon/sgl.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/crypto/hisilicon/sgl.c b/drivers/crypto/hisilicon/sgl.c
index d04e551..7f11e41 100644
--- a/drivers/crypto/hisilicon/sgl.c
+++ b/drivers/crypto/hisilicon/sgl.c
@@ -176,6 +176,7 @@ static void sg_map_to_hw_sg(struct scatterlist *sgl,
 {
 	hw_sge->buf = sg_dma_address(sgl);
 	hw_sge->len = cpu_to_le32(sg_dma_len(sgl));
+	hw_sge->page_ctrl = sg_virt(sgl);
 }
 
 static void inc_hw_sgl_sge(struct hisi_acc_hw_sgl *hw_sgl)
-- 
2.8.1


  parent reply	other threads:[~2021-04-09  9:07 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-09  9:03 [PATCH v3 0/5] bug fix and clear coding style Kai Ye
2021-04-09  9:04 ` [PATCH v3 1/5] crypto: hisilicon/sgl - add a comment for block size initialization Kai Ye
2021-04-09  9:04 ` [PATCH v3 2/5] crypto: hisilicon/sgl - delete unneeded variable initialization Kai Ye
2021-04-09  9:04 ` [PATCH v3 3/5] crypto: hisilicon/sgl - add some dfx logs Kai Ye
2021-04-09  9:04 ` Kai Ye [this message]
2021-04-09  9:04 ` [PATCH v3 5/5] crypto: hisilicon/sgl - fix the sg buf unmap Kai Ye
2021-04-16 11:32 ` [PATCH v3 0/5] bug fix and clear coding style 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=1617959044-11023-5-git-send-email-yekai13@huawei.com \
    --to=yekai13@huawei.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@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).