OSDN Git Service

KEYS: trusted: explicitly use tpm_chip structure from tpm_default_chip()
authorRoberto Sassu <roberto.sassu@huawei.com>
Wed, 6 Feb 2019 16:24:51 +0000 (17:24 +0100)
committerJarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Wed, 13 Feb 2019 07:48:51 +0000 (09:48 +0200)
commit240730437deb213a58915830884e1a99045624dc
tree8a87d96a19783cd8fc8fd3962665e0eb2d3cfd01
parent901615cb916dc955fb7bda4e34402bf263532e4a
KEYS: trusted: explicitly use tpm_chip structure from tpm_default_chip()

When crypto agility support will be added to the TPM driver, users of the
driver have to retrieve the allocated banks from chip->allocated_banks and
use this information to prepare the array of tpm_digest structures to be
passed to tpm_pcr_extend().

This patch retrieves a tpm_chip pointer from tpm_default_chip() so that the
pointer can be used to prepare the array of tpm_digest structures.

Signed-off-by: Roberto Sassu <roberto.sassu@huawei.com>
Reviewed-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Tested-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
security/keys/trusted.c