summaryrefslogtreecommitdiff
path: root/chip/npcx/system.c
diff options
context:
space:
mode:
authorJack Rosenthal <jrosenth@chromium.org>2019-02-26 16:25:28 -0700
committerchrome-bot <chrome-bot@chromium.org>2019-03-01 01:08:44 -0800
commit528ff711f6f22c7899d2c29dae3e1ff2d331bef2 (patch)
tree481f987693cd547b1543f4cc6959587a3e5bf232 /chip/npcx/system.c
parent0f85d578dfff59cf4b8800ba5b346d6ae8676db4 (diff)
downloadchrome-ec-528ff711f6f22c7899d2c29dae3e1ff2d331bef2.tar.gz
ec: cleanup: Add CONFIG_RTC
This allows the chipset task to print RTC information, without requiring CONFIG_CMD_RTC to be enabled. BUG=chromium:649851 BRANCH=none TEST=Built and flashed on grunt (careena), confirmed RTC state printed when the power state was changed, but without RTC command present Change-Id: I6b11c4d2822117c57febdacf299a865710ed1edd Signed-off-by: Jack Rosenthal <jrosenth@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1490672 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org> Reviewed-by: Raul E Rangel <rrangel@chromium.org> Reviewed-by: Jett Rink <jettrink@chromium.org>
Diffstat (limited to 'chip/npcx/system.c')
-rw-r--r--chip/npcx/system.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/chip/npcx/system.c b/chip/npcx/system.c
index edb9e2335e..726aa30350 100644
--- a/chip/npcx/system.c
+++ b/chip/npcx/system.c
@@ -914,7 +914,6 @@ int system_is_reboot_warm(void)
/*****************************************************************************/
/* Console commands */
-#ifdef CONFIG_CMD_RTC
void print_system_rtc(enum console_channel ch)
{
uint32_t sec = system_get_rtc_sec();
@@ -922,6 +921,7 @@ void print_system_rtc(enum console_channel ch)
cprintf(ch, "RTC: 0x%08x (%d.00 s)\n", sec, sec);
}
+#ifdef CONFIG_CMD_RTC
static int command_system_rtc(int argc, char **argv)
{
if (argc == 3 && !strcasecmp(argv[1], "set")) {