From: Pankaj Gupta <pankaj.gupta@nxp.com>
To: Ahmad Fatoum <a.fatoum@pengutronix.de>,
Horia Geanta <horia.geanta@nxp.com>,
Herbert Xu <herbert@gondor.apana.org.au>,
"David S. Miller" <davem@davemloft.net>
Cc: "linux-security-module@vger.kernel.org"
<linux-security-module@vger.kernel.org>,
Eric Biggers <ebiggers@kernel.org>,
David Gstir <david@sigma-star.at>,
Matthias Schiffer <matthias.schiffer@ew.tq-group.com>,
Sumit Garg <sumit.garg@linaro.org>,
Jan Luebbe <j.luebbe@pengutronix.de>,
Richard Weinberger <richard@nod.at>,
"tharvey@gateworks.com" <tharvey@gateworks.com>,
Franck Lenormand <franck.lenormand@nxp.com>,
James Morris <jmorris@namei.org>,
Mimi Zohar <zohar@linux.ibm.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
David Howells <dhowells@redhat.com>,
Jarkko Sakkinen <jarkko@kernel.org>,
"keyrings@vger.kernel.org" <keyrings@vger.kernel.org>,
"linux-crypto@vger.kernel.org" <linux-crypto@vger.kernel.org>,
"kernel@pengutronix.de" <kernel@pengutronix.de>,
"linux-integrity@vger.kernel.org"
<linux-integrity@vger.kernel.org>,
James Bottomley <jejb@linux.ibm.com>,
"Serge E. Hallyn" <serge@hallyn.com>
Subject: RE: [EXT] [PATCH v6 3/4] crypto: caam - add in-kernel interface for blob generator
Date: Mon, 28 Mar 2022 09:29:12 +0000 [thread overview]
Message-ID: <DU2PR04MB86306DE99EA993BF596BA729951D9@DU2PR04MB8630.eurprd04.prod.outlook.com> (raw)
In-Reply-To: <ae941471-43c0-1aea-2567-89eed98a61a6@pengutronix.de>
Hi Ahmad,
Please find the comments in-line.
Regards
Pankaj
> -----Original Message-----
> From: Ahmad Fatoum <a.fatoum@pengutronix.de>
> Sent: Thursday, March 24, 2022 3:40 PM
> To: Pankaj Gupta <pankaj.gupta@nxp.com>; Horia Geanta
> <horia.geanta@nxp.com>; Herbert Xu <herbert@gondor.apana.org.au>;
> David S. Miller <davem@davemloft.net>
> Cc: linux-security-module@vger.kernel.org; Eric Biggers
> <ebiggers@kernel.org>; David Gstir <david@sigma-star.at>; Matthias
> Schiffer <matthias.schiffer@ew.tq-group.com>; Sumit Garg
> <sumit.garg@linaro.org>; Jan Luebbe <j.luebbe@pengutronix.de>; Richard
> Weinberger <richard@nod.at>; tharvey@gateworks.com; Franck Lenormand
> <franck.lenormand@nxp.com>; James Morris <jmorris@namei.org>; Mimi
> Zohar <zohar@linux.ibm.com>; linux-kernel@vger.kernel.org; David Howells
> <dhowells@redhat.com>; Jarkko Sakkinen <jarkko@kernel.org>;
> keyrings@vger.kernel.org; linux-crypto@vger.kernel.org;
> kernel@pengutronix.de; linux-integrity@vger.kernel.org; James Bottomley
> <jejb@linux.ibm.com>; Serge E. Hallyn <serge@hallyn.com>
> Subject: Re: [EXT] [PATCH v6 3/4] crypto: caam - add in-kernel interface for
> blob generator
>
> Caution: EXT Email
>
> Hello Pankaj,
>
> On 24.03.22 10:55, Pankaj Gupta wrote:
> > Hi Ahmad,
> >
> > Please find the comments in-line.
>
> Thanks for you review.
>
> > Suggest to continue to use two separate descriptor-creation-function for
> 'encap' and 'decap'.
> > This will help these API(s) to be maintained easily going forward.
>
> We can still split them up in future once there is a real need.
> But currently they are exactly the same, except for input/output length, so I
> think it's correct to not introduce duplication unless needed.
>
> >> - use append_seq_(in|out)_ptr_intlen for both encap/decap as a
> >> result
>
> Case in point. The intlen omission was because the two functions are largely
> identical and I only fixed up one of them. This is prone to repeat when we go
> back to have identical code with minor differences.
>
> > In continuation to the previous comment, there is another suggestion:
> >
> > Either:
> > struct keyblob_info {
> > void *key;
> > size_t key_len;
> >
> > void *blob;
> > size_t blob_len;
> >
> > size_t key_mod_len;
> > const void *key_mod;
> > };
>
> I can do that.
>
Please do. Thanks.
Patch 4/4, needs to be re-worked to.
> Whats your opinion on the desc size computation? Comment the macro or
> add the static inline helper?
>
Comment the macro is fine.
> Cheers,
> Ahmad
>
> --
> Pengutronix e.K. | |
> Steuerwalder Str. 21 |
> https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.
> pengutronix.de%2F&data=04%7C01%7Cpankaj.gupta%40nxp.com%7C4
> d60f0d524a04b7cbd7b08da0d7e7d21%7C686ea1d3bc2b4c6fa92cd99c5c30163
> 5%7C0%7C0%7C637837134158793951%7CUnknown%7CTWFpbGZsb3d8eyJWI
> joiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3
> 000&sdata=PetvZm8teusBwQ4BeZ1VLEOvBlCrZ2k2bNG3SJBEXPw%3D&
> amp;reserved=0 |
> 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
> Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
next prev parent reply other threads:[~2022-03-28 9:29 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-16 16:43 [PATCH v6 0/4] KEYS: trusted: Introduce support for NXP CAAM-based trusted keys Ahmad Fatoum
2022-03-16 16:43 ` [PATCH v6 1/4] KEYS: trusted: allow use of TEE as backend without TCG_TPM support Ahmad Fatoum
2022-03-16 16:43 ` [PATCH v6 2/4] KEYS: trusted: allow use of kernel RNG for key material Ahmad Fatoum
2022-03-16 16:43 ` [PATCH v6 3/4] crypto: caam - add in-kernel interface for blob generator Ahmad Fatoum
2022-03-22 6:25 ` [EXT] " Pankaj Gupta
2022-03-22 7:32 ` Ahmad Fatoum
2022-03-22 9:37 ` Ahmad Fatoum
2022-03-24 9:55 ` Pankaj Gupta
2022-03-24 10:10 ` Ahmad Fatoum
2022-03-28 9:29 ` Pankaj Gupta [this message]
2022-04-15 20:07 ` Ahmad Fatoum
2022-03-16 16:43 ` [PATCH v6 4/4] KEYS: trusted: Introduce support for NXP CAAM-based trusted keys Ahmad Fatoum
2022-03-20 21:02 ` Jarkko Sakkinen
2022-03-22 7:33 ` Ahmad Fatoum
2022-03-22 8:17 ` Jarkko Sakkinen
2022-03-28 10:46 ` [EXT] " Pankaj Gupta
2022-04-15 20:02 ` Ahmad Fatoum
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=DU2PR04MB86306DE99EA993BF596BA729951D9@DU2PR04MB8630.eurprd04.prod.outlook.com \
--to=pankaj.gupta@nxp.com \
--cc=a.fatoum@pengutronix.de \
--cc=davem@davemloft.net \
--cc=david@sigma-star.at \
--cc=dhowells@redhat.com \
--cc=ebiggers@kernel.org \
--cc=franck.lenormand@nxp.com \
--cc=herbert@gondor.apana.org.au \
--cc=horia.geanta@nxp.com \
--cc=j.luebbe@pengutronix.de \
--cc=jarkko@kernel.org \
--cc=jejb@linux.ibm.com \
--cc=jmorris@namei.org \
--cc=kernel@pengutronix.de \
--cc=keyrings@vger.kernel.org \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-integrity@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=matthias.schiffer@ew.tq-group.com \
--cc=richard@nod.at \
--cc=serge@hallyn.com \
--cc=sumit.garg@linaro.org \
--cc=tharvey@gateworks.com \
--cc=zohar@linux.ibm.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;
as well as URLs for NNTP newsgroup(s).