summaryrefslogtreecommitdiff
path: root/core/cortex-m
diff options
context:
space:
mode:
authorRandall Spangler <rspangler@chromium.org>2012-10-23 14:12:25 -0700
committerGerrit <chrome-bot@google.com>2012-10-23 16:49:29 -0700
commite72788ef96e83ef9d6ac0b2593c7edd8139c9376 (patch)
tree8eab899042c277b835310e9c35d9ee8180b14837 /core/cortex-m
parent7cd4d4391d3abbd2272bf9b7459677a4fa99cd0c (diff)
downloadchrome-ec-e72788ef96e83ef9d6ac0b2593c7edd8139c9376.tar.gz
Hook functions no longer return values
Previously, all hook functions returned EC_SUCCESS, which was meaningless because nothing ever looked at the return value. Changing the return value to void saves ~100 bytes of code size and an equal amount of source code size. BUG=none BRANCH=none TEST=code still builds; link still boots Change-Id: I2a636339894e5a804831244967a9c9d134df7d13 Signed-off-by: Randall Spangler <rspangler@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/36372
Diffstat (limited to 'core/cortex-m')
-rw-r--r--core/cortex-m/timer.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/core/cortex-m/timer.c b/core/cortex-m/timer.c
index 10370aeeb6..d3eaae7efb 100644
--- a/core/cortex-m/timer.c
+++ b/core/cortex-m/timer.c
@@ -250,18 +250,14 @@ DECLARE_CONSOLE_COMMAND(timerinfo, command_timer_info,
#define TIMER_SYSJUMP_TAG 0x4d54 /* "TM" */
-
/* Preserve time across a sysjump */
-static int timer_sysjump(void)
+static void timer_sysjump(void)
{
timestamp_t ts = get_time();
system_add_jump_tag(TIMER_SYSJUMP_TAG, 1, sizeof(ts), &ts);
-
- return EC_SUCCESS;
}
DECLARE_HOOK(HOOK_SYSJUMP, timer_sysjump, HOOK_PRIO_DEFAULT);
-
int timer_init(void)
{
const timestamp_t *ts;