lib: tpm: Add command to list resources
It is sometimes convenient to know how many and/or which resources are
currently loaded into a TPG, e.g. to test is a flush operation succeeded.
Hence, we add a command that lists the resources of a given type currently
loaded into the TPM.
Signed-off-by: Mario Six <mario.six@gdsys.cc>
Reviewed-by: Simon Glass <sjg@chromium.org>
diff --git a/drivers/tpm/Kconfig b/drivers/tpm/Kconfig
index a54b6a9..2a64bc4 100644
--- a/drivers/tpm/Kconfig
+++ b/drivers/tpm/Kconfig
@@ -96,4 +96,11 @@
Enable support to load keys into the TPM by identifying
their parent via the public key's SHA1 hash.
The functionality is available via the 'tpm' command as well.
+
+config TPM_LIST_RESOURCES
+ bool "Enable TPM resource listing support"
+ depends on TPM
+ help
+ Enable support to list specific resources (e.g. keys) within the TPM.
+ The functionality is available via the 'tpm' command as well.
endmenu