[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <7c9c093a-cfb8-c997-87f8-db769eaa2c62@pengutronix.de>
Date: Fri, 15 Apr 2022 22:07:01 +0200
From: Ahmad Fatoum <a.fatoum@...gutronix.de>
To: Pankaj Gupta <pankaj.gupta@....com>,
Horia Geanta <horia.geanta@....com>,
Herbert Xu <herbert@...dor.apana.org.au>,
"David S. Miller" <davem@...emloft.net>
Cc: Sumit Garg <sumit.garg@...aro.org>,
David Gstir <david@...ma-star.at>,
Matthias Schiffer <matthias.schiffer@...tq-group.com>,
"kernel@...gutronix.de" <kernel@...gutronix.de>,
Franck Lenormand <franck.lenormand@....com>,
Richard Weinberger <richard@....at>,
Jan Luebbe <j.luebbe@...gutronix.de>,
James Morris <jmorris@...ei.org>,
Mimi Zohar <zohar@...ux.ibm.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Eric Biggers <ebiggers@...nel.org>,
"linux-security-module@...r.kernel.org"
<linux-security-module@...r.kernel.org>,
"keyrings@...r.kernel.org" <keyrings@...r.kernel.org>,
"linux-crypto@...r.kernel.org" <linux-crypto@...r.kernel.org>,
David Howells <dhowells@...hat.com>,
Jarkko Sakkinen <jarkko@...nel.org>,
"linux-integrity@...r.kernel.org" <linux-integrity@...r.kernel.org>,
James Bottomley <jejb@...ux.ibm.com>,
"tharvey@...eworks.com" <tharvey@...eworks.com>,
"Serge E. Hallyn" <serge@...lyn.com>
Subject: Re: [EXT] [PATCH v6 3/4] crypto: caam - add in-kernel interface for
blob generator
On 28.03.22 11:29, Pankaj Gupta wrote:
>>> 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.
I went with your other suggestion instead: void *input and void *output.
This keeps the code simple and avoids having to do:
if (encap) {
in = info->key;
in_len = info->key_len;
out = info->blob_len;
out_len = info->key_len + CAAM_BLOB_OVERHEAD;
} else {
in = info->blob;
in_len = info->blob_len;
out = info->key_len;
out_len = info->blob_len - CAAM_BLOB_OVERHEAD;
}
> 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 |
>
>
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
Powered by blists - more mailing lists