aboutsummaryrefslogtreecommitdiff
path: root/lib/hang.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2018-10-01 12:22:20 -0600
committerSimon Glass <sjg@chromium.org>2018-10-09 04:40:27 -0600
commitaa0ffe8eb919c85997884d4d3d44a81f92a8ab66 (patch)
treed193f25cae0670f87c5d524afa96c186bb8444df /lib/hang.c
parent6307896c177e3afb54a42439062dce0776d31891 (diff)
downloadu-boot-aa0ffe8eb919c85997884d4d3d44a81f92a8ab66.zip
u-boot-aa0ffe8eb919c85997884d4d3d44a81f92a8ab66.tar.gz
u-boot-aa0ffe8eb919c85997884d4d3d44a81f92a8ab66.tar.bz2
serial: Allow serial to be absent in TPL
At present this option applies to SPL, but it should be available in TPL also, and separately. Change to using CONFIG_IS_ENABLED(), add a new Kconfig option and fix up hang(). Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'lib/hang.c')
-rw-r--r--lib/hang.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/hang.c b/lib/hang.c
index bf56f4c..c5a7869 100644
--- a/lib/hang.c
+++ b/lib/hang.c
@@ -20,8 +20,9 @@
*/
void hang(void)
{
-#if !defined(CONFIG_SPL_BUILD) || (defined(CONFIG_SPL_LIBCOMMON_SUPPORT) && \
- defined(CONFIG_SPL_SERIAL_SUPPORT))
+#if !defined(CONFIG_SPL_BUILD) || \
+ (CONFIG_IS_ENABLED(LIBCOMMON_SUPPORT) && \
+ CONFIG_IS_ENABLED(SERIAL_SUPPORT))
puts("### ERROR ### Please RESET the board ###\n");
#endif
bootstage_error(BOOTSTAGE_ID_NEED_RESET);