From: Gaurav Jain <gaurav.jain@nxp.com>
To: Herbert Xu <herbert@gondor.apana.org.au>,
Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Cc: Horia Geanta <horia.geanta@nxp.com>,
Pankaj Gupta <pankaj.gupta@nxp.com>,
"davem@davemloft.net" <davem@davemloft.net>,
"linux-crypto@vger.kernel.org" <linux-crypto@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"kernel-janitors@vger.kernel.org"
<kernel-janitors@vger.kernel.org>
Subject: RE: [EXT] Re: [PATCH] crypto: caam: Clear some memory in instantiate_rng()
Date: Tue, 21 Mar 2023 05:03:24 +0000 [thread overview]
Message-ID: <AM0PR04MB6004F6DC17B8CB859D13EF1EE7819@AM0PR04MB6004.eurprd04.prod.outlook.com> (raw)
In-Reply-To: <ZBkj9tUFl8OJeoic@gondor.apana.org.au>
Hi Herbert
> -----Original Message-----
> From: Herbert Xu <herbert@gondor.apana.org.au>
> Sent: Tuesday, March 21, 2023 8:57 AM
> To: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> Cc: Horia Geanta <horia.geanta@nxp.com>; Pankaj Gupta
> <pankaj.gupta@nxp.com>; Gaurav Jain <gaurav.jain@nxp.com>;
> davem@davemloft.net; linux-crypto@vger.kernel.org; linux-
> kernel@vger.kernel.org; kernel-janitors@vger.kernel.org
> Subject: [EXT] Re: [PATCH] crypto: caam: Clear some memory in
> instantiate_rng()
>
> Caution: EXT Email
>
> On Tue, Mar 21, 2023 at 12:45:43AM +0100, Christophe JAILLET wrote:
> > According to the comment at the end of the 'for' loop just a few lines
> > below, it looks needed to clear 'desc'.
> >
> > So it should also be cleared for the first iteration.
> >
> > Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> > ---
> > This patch is speculative, but can't hurt.
> >
> > Maybe the memset() at the end of the 'for' loop could be removed instead.
>
> I think the memset can be removed. Horia?
memset() is needed to clear the desc for each state handle before recreating descriptor.
So it is required.
Regards
Gaurav Jain
> --
> Email: Herbert Xu <herbert@gondor.apana.org.au> Home Page:
> https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgondor
> .apana.org.au%2F~herbert%2F&data=05%7C01%7Cgaurav.jain%40nxp.com%
> 7C93eb192d0c734fc5105e08db29bc1da2%7C686ea1d3bc2b4c6fa92cd99c5c3
> 01635%7C0%7C0%7C638149660155476281%7CUnknown%7CTWFpbGZsb3d8
> eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3
> D%7C3000%7C%7C%7C&sdata=S%2Bh6BA5ka9HoWb%2BHq8Vwb3TwnEu8b
> RZ5scpGvOxg8iw%3D&reserved=0
> PGP Key:
> https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgondor
> .apana.org.au%2F~herbert%2Fpubkey.txt&data=05%7C01%7Cgaurav.jain%4
> 0nxp.com%7C93eb192d0c734fc5105e08db29bc1da2%7C686ea1d3bc2b4c6fa
> 92cd99c5c301635%7C0%7C0%7C638149660155476281%7CUnknown%7CTWF
> pbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXV
> CI6Mn0%3D%7C3000%7C%7C%7C&sdata=7YT4gr8kviqJYFABOcg6UgZL3BceG
> 3oY4HUSUuUwAdg%3D&reserved=0
next prev parent reply other threads:[~2023-03-21 5:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-20 23:45 Christophe JAILLET
2023-03-21 3:26 ` Herbert Xu
2023-03-21 5:03 ` Gaurav Jain [this message]
2023-03-21 5:06 ` [EXT] " Herbert Xu
2023-03-21 6:55 ` Gaurav Jain
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=AM0PR04MB6004F6DC17B8CB859D13EF1EE7819@AM0PR04MB6004.eurprd04.prod.outlook.com \
--to=gaurav.jain@nxp.com \
--cc=christophe.jaillet@wanadoo.fr \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=horia.geanta@nxp.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pankaj.gupta@nxp.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®