[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20190325145619.GC29989@linux.intel.com>
Date: Mon, 25 Mar 2019 16:56:19 +0200
From: Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>
To: Roberto Sassu <roberto.sassu@...wei.com>
Cc: dhowells@...hat.com, zohar@...ux.ibm.com, dan.j.williams@...el.com,
linux-integrity@...r.kernel.org, keyrings@...r.kernel.org,
linux-security-module@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-nvdimm@...ts.01.org,
david.safford@...com, jejb@...ux.ibm.com,
silviu.vlasceanu@...wei.com, stable@...r.kernel.org
Subject: Re: [PATCH] KEYS: trusted: defer execution of TPM-specific code
until key instantiate
On Fri, Mar 22, 2019 at 07:01:39PM +0100, Roberto Sassu wrote:
> Commit 240730437deb ("KEYS: trusted: explicitly use tpm_chip structure from
> tpm_default_chip()") changed the tpm_chip argument of every TPM function
> from NULL to a pointer that is retrieved at module initialization time.
>
> Unlike before this patch, the trusted module cannot be loaded if no TPM is
> available. Unfortunately, this causes a dependency problem because the
> encrypted key type requires the 'key_type_trusted' symbol when
> CONFIG_TRUSTED_KEYS is defined.
>
> This patch fixes the issue by deferring the execution of TPM-specific code
> until a new trusted key is instantiated: init_tpm(), to obtain a tpm_chip
> pointer; init_digests(), introduced by commit 0b6cf6b97b7e ("tpm: pass an
> array of tpm_extend_digest structures to tpm_pcr_extend()"), to get random
> bytes from the TPM to lock a PCR.
>
> Cc: stable@...r.kernel.org
> Fixes: 240730437deb ("KEYS: trusted: explicitly use tpm_chip structure from tpm_default_chip()")
> Reported-by: Dan Williams <dan.j.williams@...el.com>
> Signed-off-by: Roberto Sassu <roberto.sassu@...wei.com>
Definitive NAK for the release. Sorting out the dependency problem is
definitely out of scope for v5.1.
/Jarkko
Powered by blists - more mailing lists