summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNamyoon Woo <namyoon@chromium.org>2020-06-02 13:37:23 -0700
committerCommit Bot <commit-bot@chromium.org>2021-06-10 04:19:02 +0000
commita1a7979aaf4187acafbb7a6cfae3166274ec0645 (patch)
treebf596a526e1f385af1998e4e5982162b5fd5a88a
parent0fae876b6e6e72899066f4475c2d4ae1108cf031 (diff)
downloadchrome-ec-a1a7979aaf4187acafbb7a6cfae3166274ec0645.tar.gz
enable CONFIG_CMD_CHARGEN
This patch enables the uart command, chargen by default. It generates a series of alphanumeric chractecters, and is useful in testing UART related modules with a stress workload. This patch occupies 400 bytes or so in flash memory of RW image. BUG=b:158477297 BRANCH=all TEST=ran it on Atlas, Puff, and Volteer. Signed-off-by: Namyoon Woo <namyoon@chromium.org> Cq-Depend: chromium:1679710,chromium:1554198,chromium:2080933,chromium:2217112 Change-Id: I3c0407e7a4a6d3bb8d998e3e5618be5769192a8c Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2951863 Reviewed-by: Craig Hesling <hesling@chromium.org> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
-rw-r--r--include/config.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/include/config.h b/include/config.h
index 2c135ec161..1d24ea4410 100644
--- a/include/config.h
+++ b/include/config.h
@@ -1389,7 +1389,16 @@
#define CONFIG_CMD_RETIMER
#undef CONFIG_CMD_BUTTON
#define CONFIG_CMD_CBI
-#undef CONFIG_CMD_CHARGEN
+/*
+ * HAS_TASK_CHIPSET implies the GSC presence.
+ * HAS_TASK_CONSOLE means UART console enabled.
+ * chargen command is needed for UART stress test.
+ */
+#if defined(HAS_TASK_CHIPSET) && defined(HAS_TASK_CONSOLE)
+#define CONFIG_CMD_CHARGEN
+#else
+#undef CONFIG_CMD_CHARGEN
+#endif
#define CONFIG_CMD_CHARGER
#undef CONFIG_CMD_CHARGER_ADC_AMON_BMON
#undef CONFIG_CMD_CHARGER_DUMP