diff options
author | Gurleen Grewal <gurleengrewal@chromium.org> | 2019-09-13 17:42:48 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-09-18 02:20:21 +0000 |
commit | ad20ea449951e49ecd991ade3a8f3f5a3fd7a227 (patch) | |
tree | e78c2009dd56e817b4a4cade7b57cf5ecd530a31 /test/tpm_test/upgrade_test.py | |
parent | 73f6dc7cc71d98789f96f38fc8b636d78ba1e9b4 (diff) | |
download | chrome-ec-ad20ea449951e49ecd991ade3a8f3f5a3fd7a227.tar.gz |
tpmtest: Make it work with current cr50
A couple of changes are needed to make tpmtests run with the
latest cr50:
1. The CRYPTO_TESTS flag turns off the TPM in cr50 build, so
no need to initalize TPM.
2. FW_UPGRADE protocol now uses offset into flash instead of
absolute memory addresses to perform upgrade.
BUG=None
TEST=test/tpm_test/tpmtest.py runs and all tests pass
Change-Id: I2402ba956e4588a7452128e75fbc82c44f8cf04f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1804068
Tested-by: Gurleen Grewal <gurleengrewal@google.com>
Commit-Queue: Gurleen Grewal <gurleengrewal@chromium.org>
Reviewed-by: Vadim Sukhomlinov <sukhomlinov@chromium.org>
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Diffstat (limited to 'test/tpm_test/upgrade_test.py')
-rw-r--r-- | test/tpm_test/upgrade_test.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/tpm_test/upgrade_test.py b/test/tpm_test/upgrade_test.py index 2d2c0b7169..69e8630358 100644 --- a/test/tpm_test/upgrade_test.py +++ b/test/tpm_test/upgrade_test.py @@ -37,9 +37,9 @@ def upgrade(tpm): raise subcmd.TpmTestError('Initialization error %d' % ord(base_str[0])) base = struct.unpack_from('>4I', base_str)[3] - if base == 0x84000: + if base == 0x44000: fname = 'build/cr50/RW/ec.RW_B.flat' - elif base == 0x44000: + elif base == 0x4000: fname = 'build/cr50/RW/ec.RW.flat' else: raise subcmd.TpmTestError('Unknown base address 0x%x' % base) |