summaryrefslogtreecommitdiff
path: root/src/mainboard/google/snow/wakeup.c
diff options
context:
space:
mode:
authorHung-Te Lin <hungte@chromium.org>2013-04-25 19:30:19 +0800
committerRonald G. Minnich <rminnich@gmail.com>2013-04-26 20:00:45 +0200
commit31039e315c78b1b8a2cbef108ec4c07cb95c5e60 (patch)
tree335fe5ea8ccdb07f2e05dcbf4eebef57bdda48a4 /src/mainboard/google/snow/wakeup.c
parent526a46ed7e4feb9e2cb02dffccbf40182c8cc014 (diff)
downloadcoreboot-31039e315c78b1b8a2cbef108ec4c07cb95c5e60.tar.xz
google/snow: Revise romstage initialization code.
Move board setup procedure to snow_setup_* functions, and Snow board-specific (wakeup) code to snow_* for better function names and comments. Verified by successfully building and booting on Google/Snow. Change-Id: I2942d75064135093eeb1c1da188a005fd255111d Signed-off-by: Hung-Te Lin <hungte@chromium.org> Reviewed-on: http://review.coreboot.org/3130 Reviewed-by: Ronald G. Minnich <rminnich@gmail.com> Tested-by: build bot (Jenkins)
Diffstat (limited to 'src/mainboard/google/snow/wakeup.c')
-rw-r--r--src/mainboard/google/snow/wakeup.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/mainboard/google/snow/wakeup.c b/src/mainboard/google/snow/wakeup.c
index 33ea9d8fd1..8bb1724a2d 100644
--- a/src/mainboard/google/snow/wakeup.c
+++ b/src/mainboard/google/snow/wakeup.c
@@ -26,16 +26,16 @@
#include "mainboard.h"
-static int wakeup_need_reset(void)
+static int snow_wakeup_need_reset(void)
{
/* The "wake up" event is not reliable (known as "bad wakeup") and needs
* reset if GPIO value is high. */
return gpio_get_value(GPIO_Y10);
}
-void board_wakeup(void)
+void snow_wakeup(void)
{
- if (wakeup_need_reset())
+ if (snow_wakeup_need_reset())
power_reset();
power_init(); /* Ensure ps_hold_setup() for early wakeup. */
@@ -44,7 +44,7 @@ void board_wakeup(void)
die("Failed to wake up.\n");
}
-int board_get_wakeup_state()
+int snow_get_wakeup_state()
{
uint32_t status = power_read_reset_status();
@@ -53,10 +53,10 @@ int board_get_wakeup_state()
*/
if (status == S5P_CHECK_DIDLE || status == S5P_CHECK_LPA)
- return BOARD_WAKEUP_DIRECT;
+ return SNOW_WAKEUP_DIRECT;
if (status == S5P_CHECK_SLEEP)
- return BOARD_WAKEUP_NEED_CLOCK_RESET;
+ return SNOW_WAKEUP_NEED_CLOCK_RESET;
- return BOARD_IS_NOT_WAKEUP;
+ return SNOW_IS_NOT_WAKEUP;
}