Commit Message

This function copies the array of tpm_pcr_bank_info structures to the
memory address specified by the caller. It assumes that the caller
allocated an array with the same number of elements of the active_banks
array (member of the tpm_chip structure). This number is defined in
include/linux/tpm.h (TPM_ACTIVE_BANKS_MAX definition).
A tpm_pcr_bank_info structure is also returned if the TPM version is 1.2.
The advantage of this choice is that the code for extending a PCR with
multiple digests will work regardless of the TPM version.
Signed-off-by: Roberto Sassu <roberto.sassu@huawei.com>
---
drivers/char/tpm/tpm-interface.c | 33 +++++++++++++++++++++++++++++++++
drivers/char/tpm/tpm.h | 2 +-
include/linux/tpm.h | 8 ++++++++
3 files changed, 42 insertions(+), 1 deletion(-)