summaryrefslogtreecommitdiff
path: root/common/port80.c
diff options
context:
space:
mode:
authorAndrew McRae <amcrae@google.com>2022-08-24 13:08:22 +1000
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-08-25 02:02:08 +0000
commit5514b2515e4c5d05b406595e54ef48a11ccccb5f (patch)
tree1f2e67faffb7c1ed4b414df3fbca60b66f4e2cac /common/port80.c
parente657e7385afa565816135e4bb4a32a2a154f679d (diff)
downloadchrome-ec-5514b2515e4c5d05b406595e54ef48a11ccccb5f.tar.gz
port80: Add a config to avoid logging port80 codes
Add a config item to disable logging all of the port80 history buffer as each code is received. Individual codes can still be logged as they are received when enabled via the console command 'port80 intprint' or using the CONFIG_PORT80_PRINT_IN_INT config item. This reduces the overhead at AP startup on the logging. It has been observed on the ITE81302 that logging the port80 codes causes significant overhead that may lead to watchdog timeouts. The port80 code history is still available via the 'port80' EC console command. BUG=b:243607643 TEST=zmake build nereid; flash & run BRANCH=none Signed-off-by: Andrew McRae <amcrae@google.com> Change-Id: I543b0391bcf474c9d040baa98ff75f6e2b9fd5a9 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3853308 Code-Coverage: Zoss <zoss-cl-coverage@prod.google.com> Reviewed-by: Peter Marheine <pmarheine@chromium.org>
Diffstat (limited to 'common/port80.c')
-rw-r--r--common/port80.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/common/port80.c b/common/port80.c
index 66ad48be5e..72195c5793 100644
--- a/common/port80.c
+++ b/common/port80.c
@@ -62,7 +62,9 @@ void port_80_write(int data)
data);
}
- hook_call_deferred(&port80_dump_buffer_data, 4 * SECOND);
+ if (!IS_ENABLED(CONFIG_PORT80_QUIET)) {
+ hook_call_deferred(&port80_dump_buffer_data, 4 * SECOND);
+ }
/* Save current port80 code if system is resetting */
if (data == PORT_80_EVENT_RESET && writes) {