summaryrefslogtreecommitdiff
path: root/common/serial.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/serial.c')
-rw-r--r--common/serial.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/common/serial.c b/common/serial.c
index fc38e6c..acb74af 100644
--- a/common/serial.c
+++ b/common/serial.c
@@ -222,8 +222,14 @@ static struct serial_device *get_current(void)
dev = default_serial_console();
/* We must have a console device */
- if (!dev)
- panic("Cannot find console");
+ if (!dev) {
+#ifdef CONFIG_SPL_BUILD
+ puts("Cannot find console\n");
+ hang();
+#else
+ panic("Cannot find console\n");
+#endif
+ }
} else
dev = serial_current;
return dev;