Implement GetCapabilities and reading flags for tpm2
authorAndrey Pronin <apronin@google.com>
Sat, 23 Jul 2016 01:45:07 +0000 (18:45 -0700)
committerchrome-bot <chrome-bot@chromium.org>
Wed, 27 Jul 2016 00:31:56 +0000 (17:31 -0700)
commit0960682caa1fd27539b0c2100e4f8766ebe66640
treeb1cf5c1004163ffe3bd6277ba3e9d88f3d1d236b
parentca7251286655fe8865d0089bfc23b42ffececbf3
Implement GetCapabilities and reading flags for tpm2

For TPM2.0:
1) Implement TPM2_GetCapabilities command that allows reading
TPM properties, including PERMANENT and STARTUP_CLEAR flags.
2) Implement 'getpf' and 'getvf' commands in tpmc.

BRANCH=none
BUG=chrome-os-partner:55210
BUG=chrome-os-partner:55250
TEST=boot on kevin, verify 'tpmc getpf' and 'tpmc getvf'

Change-Id: I8490b2c92ebf7c266e27b7cb5898126a1b99b1a8
Reviewed-on: https://chromium-review.googlesource.com/362770
Commit-Ready: Andrey Pronin <apronin@chromium.org>
Tested-by: Andrey Pronin <apronin@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
firmware/include/tpm2_tss_constants.h
firmware/lib/tpm2_lite/marshaling.c
firmware/lib/tpm2_lite/tlcl.c
utility/tpmc.c