]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
stm32mp1: declare backup registers for coprocessor
authorFabien Dessenne <fabien.dessenne@st.com>
Wed, 30 Oct 2019 13:38:29 +0000 (14:38 +0100)
committerTom Rini <trini@konsulko.com>
Tue, 7 Jan 2020 16:13:25 +0000 (11:13 -0500)
Use the backup register #17 as coprocessor resource table address and
backup register #18 as coprocessor state.

Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com>
Acked-by: Patrick Delaunay <patrick.delaunay@st.com>
arch/arm/mach-stm32mp/include/mach/stm32.h

index b3e9ccc5d327bc370bbbbba9488eb0ecc2d2bb77..88126b8cdbad662deee0a6ead3045c718ff17afb 100644 (file)
@@ -86,9 +86,18 @@ enum boot_device {
 #define TAMP_BACKUP_REGISTER(x)                (STM32_TAMP_BASE + 0x100 + 4 * x)
 #define TAMP_BACKUP_MAGIC_NUMBER       TAMP_BACKUP_REGISTER(4)
 #define TAMP_BACKUP_BRANCH_ADDRESS     TAMP_BACKUP_REGISTER(5)
+#define TAMP_COPRO_RSC_TBL_ADDRESS     TAMP_BACKUP_REGISTER(17)
+#define TAMP_COPRO_STATE               TAMP_BACKUP_REGISTER(18)
 #define TAMP_BOOT_CONTEXT              TAMP_BACKUP_REGISTER(20)
 #define TAMP_BOOTCOUNT                 TAMP_BACKUP_REGISTER(21)
 
+#define TAMP_COPRO_STATE_OFF           0
+#define TAMP_COPRO_STATE_INIT          1
+#define TAMP_COPRO_STATE_CRUN          2
+#define TAMP_COPRO_STATE_CSTOP         3
+#define TAMP_COPRO_STATE_STANDBY       4
+#define TAMP_COPRO_STATE_CRASH         5
+
 #define TAMP_BOOT_MODE_MASK            GENMASK(15, 8)
 #define TAMP_BOOT_MODE_SHIFT           8
 #define TAMP_BOOT_DEVICE_MASK          GENMASK(7, 4)