summaryrefslogtreecommitdiff
path: root/board/host
diff options
context:
space:
mode:
authorAllen Webb <allenwebb@google.com>2018-02-28 15:42:47 -0800
committerchrome-bot <chrome-bot@chromium.org>2018-04-27 12:22:26 -0700
commit1820ecce31e6a23e5ab79f708f66a8655da6a161 (patch)
tree9c4f09621ec2282208cfed21de76f8172fc9c888 /board/host
parent826a3876b4f3ecd5f73d2320ee1e853a789e6e30 (diff)
downloadchrome-ec-1820ecce31e6a23e5ab79f708f66a8655da6a161.tar.gz
Cr50: Add logging functionality to PinWeaver.
In order to be able to recover from the AP and Cr50 getting out of sync, this logging functionality gives Cr50 a way to track the state changes of the merkle tree so that the AP can be updated to the current state as long as it has a recent enough copy. This involves packing the important information so it can be stored efficiently on flash, and adding the necessary messages for the replay. CQ-DEPEND=CL:895395,CL:929430 BRANCH=none BUG=chromium:809729, chromium:809745 TEST=cd ~/src/platform/ec && V=1 make run-weaver_ng -j Change-Id: I40f98de2c8e9706cccb5b922215699f2132fa121 Signed-off-by: Allen Webb <allenwebb@google.com> Reviewed-on: https://chromium-review.googlesource.com/963773 Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Diffstat (limited to 'board/host')
-rw-r--r--board/host/dcrypto.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/board/host/dcrypto.h b/board/host/dcrypto.h
index f949ef4352..48bde62592 100644
--- a/board/host/dcrypto.h
+++ b/board/host/dcrypto.h
@@ -4,7 +4,9 @@
*/
/* Provides the minimal declarations needed by pinweaver to build on
- * CHIP_HOST.
+ * CHIP_HOST. While it might be preferable to simply use the original dcrypto.h,
+ * That would require incorporating additional headers / dependencies such as
+ * cryptoc.
*/
#ifndef __CROS_EC_DCRYPTO_HOST_H
@@ -30,6 +32,9 @@ enum dcrypto_appid {
/* This enum value should not exceed 7. */
};
+/* Used as a replacement for declarations in cryptoc that are used by Cr50, but
+ * add unnecessary complexity to the test code.
+ */
struct dcrypto_mock_ctx_t {
struct HASH_CTX hash;
};