Juno: Add support for Test Secure-EL1 Payload
This patch implements the TSP on Juno. It executes from on-chip Trusted
SRAM.
Also, the other bootloader images (i.e. BL1 R/W, BL2 and BL3-1) have
been moved around. The reason is, although there was enough space
overall to store the TSP in SRAM, there was no contiguous free chunk
of SRAM big enough to hold it.
This patch keeps the overall memory layout (i.e. keeping BL1 R/W at
the bottom, BL2 at the top and BL3-1 in between) but moves the base
addresses of all the bootloader images in such a way that:
- memory fragmentation is reduced enough to fit BL3-2 in;
- new base addresses are suitable for release builds as well as debug
ones;
- each image has a few extra kilobytes for future growth.
BL3-1 and BL3-2 are the images which received the biggest allocations
since they will most probably grow the most.
This patch also adds instruction synchronization barriers around the code which
handles the timer interrupt in the TSP. This ensures that the interrupt is not
acknowledged after or EOIed before it is deactivated at the peripheral.
Change-Id: I1c5b51858700027ee283ac85d18e06863a27c72e
diff --git a/plat/juno/include/platform_def.h b/plat/juno/include/platform_def.h
index 2678efc..6d9d0fb 100644
--- a/plat/juno/include/platform_def.h
+++ b/plat/juno/include/platform_def.h
@@ -32,6 +32,7 @@
#define __PLATFORM_DEF_H__
#include <arch.h>
+#include "../juno_def.h"
/*******************************************************************************
* Platform binary types for linking
@@ -142,9 +143,9 @@
#define MAX_MMAP_REGIONS 16
/*******************************************************************************
- * ID of the secure physical generic timer interrupt.
+ * ID of the secure physical generic timer interrupt used by the TSP
******************************************************************************/
-#define IRQ_SEC_PHY_TIMER 29
+#define TSP_IRQ_SEC_PHY_TIMER IRQ_SEC_PHY_TIMER
/*******************************************************************************
* Declarations and constants to access the mailboxes safely. Each mailbox is