summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordavidcunado-arm <david.cunado@arm.com>2018-03-25 04:20:40 +0100
committerGitHub <noreply@github.com>2018-03-25 04:20:40 +0100
commitba7848e283cd11326f60f3a3084c142875f3ec41 (patch)
tree200b56a10752b8ee0140bfc7cda226da3df6ed62
parent0d48df84b3bd2b9167ec9cb92e6ccdb15ac7de95 (diff)
parent4c746fc56c3e849a297d42cbc00115bd590b1216 (diff)
Merge pull request #1330 from michpappas/tf-issues#571_qemu_fix_MULTI_CONSOLE=0
qemu: MULTI_CONSOLE_API=0 causes build error
-rw-r--r--include/drivers/console.h2
-rw-r--r--plat/qemu/platform.mk7
-rw-r--r--plat/qemu/qemu_console.c2
3 files changed, 10 insertions, 1 deletions
diff --git a/include/drivers/console.h b/include/drivers/console.h
index f8ec83d2..c8a43a28 100644
--- a/include/drivers/console.h
+++ b/include/drivers/console.h
@@ -66,6 +66,8 @@ int console_flush(void);
/* REMOVED on AArch64 -- use console_<driver>_register() instead! */
int console_init(uintptr_t base_addr,
unsigned int uart_clk, unsigned int baud_rate);
+int console_core_init(uintptr_t base_addr,
+ unsigned int uart_clk, unsigned int baud_rate);
void console_uninit(void);
#endif
diff --git a/plat/qemu/platform.mk b/plat/qemu/platform.mk
index a9fbcd73..017807b0 100644
--- a/plat/qemu/platform.mk
+++ b/plat/qemu/platform.mk
@@ -169,7 +169,12 @@ $(eval $(call TOOL_ADD_IMG,bl32_extra2,--tos-fw-extra2))
endif
SEPARATE_CODE_AND_RODATA := 1
-MULTI_CONSOLE_API := 1
+
+# Use MULTI_CONSOLE_API by default only on AArch64
+# as it is not yet supported on AArch32
+ifeq ($(ARCH),aarch64)
+MULTI_CONSOLE_API := 1
+endif
# Disable the PSCI platform compatibility layer
ENABLE_PLAT_COMPAT := 0
diff --git a/plat/qemu/qemu_console.c b/plat/qemu/qemu_console.c
index 9c02957e..1cf84aa7 100644
--- a/plat/qemu/qemu_console.c
+++ b/plat/qemu/qemu_console.c
@@ -7,8 +7,10 @@
#include <pl011.h>
#include <platform_def.h>
+#if MULTI_CONSOLE_API
static console_pl011_t console;
static console_pl011_t crash_console;
+#endif /* MULTI_CONSOLE_API */
void qemu_console_init(void)
{