[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <VI1PR0402MB348551336691838632965ADA98860@VI1PR0402MB3485.eurprd04.prod.outlook.com>
Date: Thu, 26 Sep 2019 07:17:28 +0000
From: Horia Geanta <horia.geanta@....com>
To: Iuliana Prodan <iuliana.prodan@....com>,
Herbert Xu <herbert@...dor.apana.org.au>,
Aymen Sghaier <aymen.sghaier@....com>
CC: "David S. Miller" <davem@...emloft.net>,
"linux-crypto@...r.kernel.org" <linux-crypto@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
dl-linux-imx <linux-imx@....com>
Subject: Re: [PATCH] crypto: caam - use mapped_{src,dst}_nents for descriptor
On 9/25/2019 4:04 PM, Iuliana Prodan wrote:
> @@ -428,17 +433,18 @@ static int set_rsa_priv_f1_pdb(struct akcipher_request *req,
> return -ENOMEM;
> }
>
> - if (edesc->src_nents > 1) {
> + if (edesc->mapped_src_nents > 1) {
> pdb->sgf |= RSA_PRIV_PDB_SGF_G;
> pdb->g_dma = edesc->sec4_sg_dma;
> - sec4_sg_index += edesc->src_nents;
> + sec4_sg_index += edesc->mapped_src_nents;
> +
> } else {
> struct caam_rsa_req_ctx *req_ctx = akcipher_request_ctx(req);
>
> pdb->g_dma = sg_dma_address(req_ctx->fixup_src);
> }
>
> - if (edesc->dst_nents > 1) {
> + if (edesc->mapped_dst_nents > 1) {
> pdb->sgf |= RSA_PRIV_PDB_SGF_F;
> pdb->f_dma = edesc->sec4_sg_dma +
> sec4_sg_index * sizeof(struct sec4_sg_entry);
AFAICS there are a few other places besides set_rsa_priv_f1_pdb
that should be updated:
set_rsa_pub_pdb
set_rsa_priv_f2_pdb
set_rsa_priv_f3_pdb
Horia
Powered by blists - more mailing lists