tlcl: automatically detect if platform hierarchy is disabled
authorAndrey Pronin <apronin@google.com>
Sat, 23 Jul 2016 02:33:07 +0000 (19:33 -0700)
committerchrome-bot <chrome-bot@chromium.org>
Wed, 27 Jul 2016 06:54:27 +0000 (23:54 -0700)
commitc37f0f82056adca65de7b99419663dff437365c1
tree85b1d7a8539aeea78b463357dea24ee7cdf0b4fc
parent98263a1b17397032b3f7d747d48f8fd914217237
tlcl: automatically detect if platform hierarchy is disabled

Instead of passing a special flag when 'tpmc' starts, auto-detect
if platform hierarchy is disabled in TlclLibInit(). See discussion
in https://chromium-review.googlesource.com/#/c/362520/.

BRANCH=none
BUG=chrome-os-partner:55210
BUG=chrome-os-partner:55250
TEST=boot on kevin, verify that 'tpmc read 0x1008 0xd' works

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