aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorAntonio Nino Diaz <antonio.ninodiaz@arm.com>2018-06-19 09:29:36 +0100
committerAntonio Nino Diaz <antonio.ninodiaz@arm.com>2018-06-19 09:29:36 +0100
commit88a0523e914cb28fded2ce398a184e0c0e8843c8 (patch)
tree413409425f5f108297c0c287f5508b7d5469b12c /include
parentf13cb561f06f492bdccd1a5c8397e5ff6aba3c85 (diff)
downloadplatform_external_arm-trusted-firmware-88a0523e914cb28fded2ce398a184e0c0e8843c8.tar.gz
platform_external_arm-trusted-firmware-88a0523e914cb28fded2ce398a184e0c0e8843c8.tar.bz2
platform_external_arm-trusted-firmware-88a0523e914cb28fded2ce398a184e0c0e8843c8.zip
plat/arm: Migrate AArch64 port to the multi console driver
The old API is deprecated and will eventually be removed. Arm platforms now use the multi console driver for boot and runtime consoles. However, the crash console uses the direct console API because it doesn't need any memory access to work. This makes it more robust during crashes. The AArch32 port of the Trusted Firmware doesn't support this new API yet, so it is only enabled in AArch64 builds. Because of this, the common code must maintain compatibility with both systems. SP_MIN doesn't have to be updated because it's only used in AArch32 builds. The TSP is only used in AArch64, so it only needs to support the new API without keeping support for the old one. Special care must be taken because of PSCI_SYSTEM_SUSPEND. In Juno, this causes the UARTs to reset (except for the one used by the TSP). This means that they must be unregistered when suspending and re-registered when resuming. This wasn't a problem with the old driver because it just restarted the UART, and there were no problems associated with registering and unregistering consoles. The size reserved for BL2 has been increased. Change-Id: Icefd117dd1eb9c498921181a21318c2d2435c441 Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
Diffstat (limited to 'include')
-rw-r--r--include/drivers/console.h6
-rw-r--r--include/plat/arm/board/common/board_arm_def.h2
-rw-r--r--include/plat/arm/common/plat_arm.h6
3 files changed, 10 insertions, 4 deletions
diff --git a/include/drivers/console.h b/include/drivers/console.h
index a4d89fe91..6e7ebbf9c 100644
--- a/include/drivers/console.h
+++ b/include/drivers/console.h
@@ -16,9 +16,9 @@
#define CONSOLE_T_FLUSH (U(4) * REGSZ)
#define CONSOLE_T_DRVDATA (U(5) * REGSZ)
-#define CONSOLE_FLAG_BOOT BIT(0)
-#define CONSOLE_FLAG_RUNTIME BIT(1)
-#define CONSOLE_FLAG_CRASH BIT(2)
+#define CONSOLE_FLAG_BOOT (U(1) << 0)
+#define CONSOLE_FLAG_RUNTIME (U(1) << 1)
+#define CONSOLE_FLAG_CRASH (U(1) << 2)
/* Bits 3 to 7 reserved for additional scopes in future expansion. */
#define CONSOLE_FLAG_SCOPE_MASK ((U(1) << 8) - 1)
/* Bits 8 to 31 reserved for non-scope use in future expansion. */
diff --git a/include/plat/arm/board/common/board_arm_def.h b/include/plat/arm/board/common/board_arm_def.h
index 2d8e4c139..030e06737 100644
--- a/include/plat/arm/board/common/board_arm_def.h
+++ b/include/plat/arm/board/common/board_arm_def.h
@@ -89,7 +89,7 @@
#if TRUSTED_BOARD_BOOT
# define PLAT_ARM_MAX_BL2_SIZE 0x1E000
#else
-# define PLAT_ARM_MAX_BL2_SIZE 0x10000
+# define PLAT_ARM_MAX_BL2_SIZE 0x11000
#endif
/*
diff --git a/include/plat/arm/common/plat_arm.h b/include/plat/arm/common/plat_arm.h
index fc3f4ec3a..33f2c7dbe 100644
--- a/include/plat/arm/common/plat_arm.h
+++ b/include/plat/arm/common/plat_arm.h
@@ -155,6 +155,12 @@ struct tzc_dmc500_driver_data;
void arm_tzc_dmc500_setup(struct tzc_dmc500_driver_data *plat_driver_data,
const arm_tzc_regions_info_t *tzc_regions);
+/* Console utility functions */
+void arm_console_boot_init(void);
+void arm_console_boot_end(void);
+void arm_console_runtime_init(void);
+void arm_console_runtime_end(void);
+
/* Systimer utility function */
void arm_configure_sys_timer(void);