diff options
author | Keith Short <keithshort@chromium.org> | 2021-04-08 08:43:58 -0600 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-04-23 22:08:53 +0000 |
commit | f0be771092e47854664c6028c56d1499ca412f8a (patch) | |
tree | d85a8918fa2aa6043939fa3a14641a9e7f763ed3 /zephyr | |
parent | 4e074a16c5703f0cdd7b7d780a8ae1bea53a445a (diff) | |
download | chrome-ec-f0be771092e47854664c6028c56d1499ca412f8a.tar.gz |
zephyr: Update banner to match Chromium OS
Update the boot banner to match Chromium OS. This also modifies the
version output to include "_zephyr" after the board name to clearly
identify the image type.
Boot banner:
Booting Zephyr OS build zephyr-v2.5.0-31-g6fcd6373e58a
--- UART initialized after reboot ---
[Image: RO, volteer_zephyr_v2.0.8350-190d6f 2021-04-08 11:15:09
keithshort@mtbaldy]
[Reset cause: reset-pin]
uart:~$ version
Chip: Nuvoton NPCX796FC 02
Board: 1
RO: volteer_zephyr_v2.0.8350-190d6f
RW: volteer_zephyr_v2.0.8350-190d6f
Build: volteer_zephyr_v2.0.8350-190d6f
2021-04-08 11:15:09 keithshort@mtbaldy
BUG=none
BRANCH=none
TEST=zmake testall
Signed-off-by: Keith Short <keithshort@chromium.org>
Change-Id: Ia136c4e025aba95217f1d8c51de39255fef54f7b
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2822208
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Diffstat (limited to 'zephyr')
-rw-r--r-- | zephyr/CMakeLists.txt | 3 | ||||
-rw-r--r-- | zephyr/app/ec/ec_app_main.c | 6 | ||||
-rw-r--r-- | zephyr/shim/src/ztest_system.c | 6 |
3 files changed, 10 insertions, 5 deletions
diff --git a/zephyr/CMakeLists.txt b/zephyr/CMakeLists.txt index 95bf2046ea..f16ce4dd1a 100644 --- a/zephyr/CMakeLists.txt +++ b/zephyr/CMakeLists.txt @@ -31,7 +31,8 @@ if(DEFINED CONFIG_PLATFORM_EC) # Create the command used to generate the ec_version.h file. add_custom_command( OUTPUT ${ec_version_file} - COMMAND ${PLATFORM_EC}/util/getversion.sh BOARD=${BOARD} > ${ec_version_file} + # TODO(b/185249526): zephyr: add project name to the version output + COMMAND BOARD=${BOARD}_zephyr ${PLATFORM_EC}/util/getversion.sh > ${ec_version_file} WORKING_DIRECTORY ${PLATFORM_EC} ) # Create a custom target that will depend on the file. diff --git a/zephyr/app/ec/ec_app_main.c b/zephyr/app/ec/ec_app_main.c index ad8498efc6..3853dc58fc 100644 --- a/zephyr/app/ec/ec_app_main.c +++ b/zephyr/app/ec/ec_app_main.c @@ -23,10 +23,6 @@ */ void ec_app_main(void) { - printk("Hello from a Chrome EC!\n"); - printk(" BOARD=%s\n", CONFIG_BOARD); - printk(" ACTIVE_COPY=%s\n", CONFIG_CROS_EC_ACTIVE_COPY); - system_common_pre_init(); /* @@ -38,6 +34,8 @@ void ec_app_main(void) init_reset_log(); } + system_print_banner(); + /* * Keyboard scan init/Button init can set recovery events to * indicate to host entry into recovery mode. Before this is diff --git a/zephyr/shim/src/ztest_system.c b/zephyr/shim/src/ztest_system.c index 625502ed82..5fbc3dc50d 100644 --- a/zephyr/shim/src/ztest_system.c +++ b/zephyr/shim/src/ztest_system.c @@ -4,6 +4,7 @@ */ #include "system.h" +#include "cros_version.h" /* Ongoing actions preventing going into deep-sleep mode. */ uint32_t sleep_mask; @@ -46,3 +47,8 @@ uint32_t system_get_reset_flags(void) { return 0; } + +void system_print_banner(void) +{ + printk("Image: %s\n", build_info); +} |