diff options
author | Anatol Pomazau <anatol@google.com> | 2018-01-18 13:46:50 -0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2018-01-31 13:47:15 -0800 |
commit | 5a910a86be7e8174d81d194a2a6042e3452ccaf8 (patch) | |
tree | df0fa7b529ba4ac95203e9f5598ebac07466b6ec /include | |
parent | 760caca89bfe3d91fe7d66b8d435a105664fd0d3 (diff) | |
download | chrome-ec-5a910a86be7e8174d81d194a2a6042e3452ccaf8.tar.gz |
Add support for HW alerts
- Add a vendor command that provides alert counter. Userspace can use
it e.g. for user metric analysis.
- Add 'alerts' debug console command. It provides information about
chip alerts: supported alerts, fuse status, interrupt status, alert
counter.
- Add 'alerts fire [INT]' command to fire a software defined alert
(globalsec/fwN where N is 0,1,2,3).
Signed-off-by: Anatol Pomazau <anatol@google.com>
BUG=b:63523947
TEST=ran the FW at Pyro and checked alerts data sent to host
Change-Id: I7cec0c451ed71076b44dad14a151b147ff1337e8
Reviewed-on: https://chromium-review.googlesource.com/817639
Commit-Ready: Anatol Pomazau <anatol@google.com>
Tested-by: Anatol Pomazau <anatol@google.com>
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/config.h | 10 | ||||
-rw-r--r-- | include/tpm_vendor_cmds.h | 1 |
2 files changed, 11 insertions, 0 deletions
diff --git a/include/config.h b/include/config.h index c6a57bcf13..b47b1e9892 100644 --- a/include/config.h +++ b/include/config.h @@ -968,6 +968,16 @@ */ #undef CONFIG_IGNORE_G_UPDATE_CHECKS +/* + * When enabled hardware alerts statistics provided via VendorCommand extension. + */ +#undef CONFIG_ENABLE_H1_ALERTS + +/* + * Enable console shell command 'alerts' that prints chip alerts statistics. + */ +#undef CONFIG_ENABLE_H1_ALERTS_CONSOLE + /*****************************************************************************/ /* * Debugging config diff --git a/include/tpm_vendor_cmds.h b/include/tpm_vendor_cmds.h index b61ca2623c..09d578493f 100644 --- a/include/tpm_vendor_cmds.h +++ b/include/tpm_vendor_cmds.h @@ -50,6 +50,7 @@ enum vendor_cmd_cc { VENDOR_CC_DISABLE_RMA = 32, VENDOR_CC_MANAGE_CCD_PWD = 33, VENDOR_CC_CCD = 34, + VENDOR_CC_GET_ALERTS_DATA = 35, LAST_VENDOR_COMMAND = 65535, }; |