2021-03-17 07:42:09

by Sumit Garg

[permalink] [raw]
Subject: Re: [PATCH v1 3/3] KEYS: trusted: Introduce support for NXP CAAM-based trusted keys

Hi Richard,

On Wed, 17 Mar 2021 at 04:45, Richard Weinberger
<[email protected]> wrote:
>
> Ahmad,
>
> On Tue, Mar 16, 2021 at 6:24 PM Ahmad Fatoum <[email protected]> wrote:
> > +#include <keys/trusted_caam.h>
> > +#include <keys/trusted-type.h>
> > +#include <linux/build_bug.h>
> > +#include <linux/key-type.h>
> > +#include <soc/fsl/caam-blob.h>
> > +
> > +struct caam_blob_priv *blobifier;
>
> Who is using this pointer too?
> Otherwise I'd suggest marking it static.
>
> > module_param_named(source, trusted_key_source, charp, 0);
> > -MODULE_PARM_DESC(source, "Select trusted keys source (tpm or tee)");
> > +MODULE_PARM_DESC(source, "Select trusted keys source (tpm, tee or caam)");
>
> I didn't closely follow the previous discussions, but is a module
> parameter really the right approach?
> Is there also a way to set it via something like device tree?
>

It's there to support a platform which possesses multiple trusted keys
backends. So that a user is able to select during boot which one to
use as a backend.

-Sumit

> --
> Thanks,
> //richard


2021-03-17 08:09:36

by Richard Weinberger

[permalink] [raw]
Subject: Re: [PATCH v1 3/3] KEYS: trusted: Introduce support for NXP CAAM-based trusted keys

Sumit,

----- Ursprüngliche Mail -----
>> > module_param_named(source, trusted_key_source, charp, 0);
>> > -MODULE_PARM_DESC(source, "Select trusted keys source (tpm or tee)");
>> > +MODULE_PARM_DESC(source, "Select trusted keys source (tpm, tee or caam)");
>>
>> I didn't closely follow the previous discussions, but is a module
>> parameter really the right approach?
>> Is there also a way to set it via something like device tree?
>>
>
> It's there to support a platform which possesses multiple trusted keys
> backends. So that a user is able to select during boot which one to
> use as a backend.

I understand the use case, my question was whether it makes actually sense to
have a module parameter for it, or additionally another way to define the
preferred backend.

Thanks,
//richard