]> git.ipfire.org Git - people/ms/u-boot.git/blame - arch/powerpc/include/asm/fsl_secure_boot.h
powerpc: T2080RDB: Remove macro CONFIG_T2080RDB
[people/ms/u-boot.git] / arch / powerpc / include / asm / fsl_secure_boot.h
CommitLineData
7065b7d4
RG
1/*
2 * Copyright 2010-2011 Freescale Semiconductor, Inc.
3 *
1a459660 4 * SPDX-License-Identifier: GPL-2.0+
7065b7d4
RG
5 */
6
7#ifndef __FSL_SECURE_BOOT_H
8#define __FSL_SECURE_BOOT_H
e04916a7 9#include <asm/config_mpc85xx.h>
10
11#ifdef CONFIG_SECURE_BOOT
bdc22074
AB
12
13#ifndef CONFIG_FIT_SIGNATURE
14#define CONFIG_CHAIN_OF_TRUST
e04916a7 15#endif
7065b7d4 16
7065b7d4
RG
17#if defined(CONFIG_FSL_CORENET)
18#define CONFIG_SYS_PBI_FLASH_BASE 0xc0000000
a202b9f8 19#elif defined(CONFIG_TARGET_BSC9132QDS)
f978f7c2 20#define CONFIG_SYS_PBI_FLASH_BASE 0xc8000000
ebccf255 21#elif defined(CONFIG_TARGET_C29XPCIE)
b3f0f632 22#define CONFIG_SYS_PBI_FLASH_BASE 0xcc000000
7065b7d4
RG
23#else
24#define CONFIG_SYS_PBI_FLASH_BASE 0xce000000
25#endif
26#define CONFIG_SYS_PBI_FLASH_WINDOW 0xcff80000
27
d46a4a13
YS
28#if defined(CONFIG_TARGET_B4860QDS) || \
29 defined(CONFIG_TARGET_B4420QDS) || \
9c21d06c 30 defined(CONFIG_TARGET_T4160QDS) || \
673c01c7 31 defined(CONFIG_TARGET_T4240QDS) || \
80d26188 32 defined(CONFIG_TARGET_T2080QDS) || \
86e0a313 33 defined(CONFIG_TARGET_T2080RDB) || \
f4f66940 34 defined(CONFIG_TARGET_T1040QDS) || \
e622d9ed 35 defined(CONFIG_T104xD4QDS) || \
78e56995
YS
36 defined(CONFIG_TARGET_T1040RDB) || \
37 defined(CONFIG_TARGET_T1040D4RDB) || \
38 defined(CONFIG_TARGET_T1042RDB) || \
39 defined(CONFIG_TARGET_T1042D4RDB) || \
40 defined(CONFIG_TARGET_T1042RDB_PI) || \
5ff3f41d 41 defined(CONFIG_ARCH_T1023) || \
e5d5f5a8 42 defined(CONFIG_ARCH_T1024)
aa36c84e 43#ifndef CONFIG_SYS_RAMBOOT
fb4a2409 44#define CONFIG_SYS_CPC_REINIT_F
aa36c84e 45#endif
e04916a7 46#define CONFIG_KEY_REVOCATION
fb4a2409
AB
47#undef CONFIG_SYS_INIT_L3_ADDR
48#define CONFIG_SYS_INIT_L3_ADDR 0xbff00000
49#endif
50
467a40df
AB
51#if defined(CONFIG_RAMBOOT_PBL)
52#undef CONFIG_SYS_INIT_L3_ADDR
aa36c84e
SG
53#ifdef CONFIG_SYS_INIT_L3_VADDR
54#define CONFIG_SYS_INIT_L3_ADDR \
55 (CONFIG_SYS_INIT_L3_VADDR & ~0xFFF00000) | \
56 0xbff00000
57#else
58#define CONFIG_SYS_INIT_L3_ADDR 0xbff00000
59#endif
467a40df
AB
60#endif
61
ebccf255 62#if defined(CONFIG_TARGET_C29XPCIE)
e04916a7 63#define CONFIG_KEY_REVOCATION
64#endif
65
5e5fdd2d 66#if defined(CONFIG_ARCH_P3041) || \
e71372cb 67 defined(CONFIG_ARCH_P4080) || \
cefe11cd 68 defined(CONFIG_ARCH_P5020) || \
95390360 69 defined(CONFIG_ARCH_P5040) || \
ce040c83 70 defined(CONFIG_ARCH_P2041)
e04916a7 71 #define CONFIG_FSL_TRUST_ARCH_v1
72#endif
73
2ed948f4 74#if defined(CONFIG_FSL_CORENET) && !defined(CONFIG_SYS_RAMBOOT)
e04916a7 75/* The key used for verification of next level images
76 * is picked up from an Extension Table which has
77 * been verified by the ISBC (Internal Secure boot Code)
2ed948f4
AB
78 * in boot ROM of the SoC.
79 * The feature is only applicable in case of NOR boot and is
80 * not applicable in case of RAMBOOT (NAND, SD, SPI).
e04916a7 81 */
82#define CONFIG_FSL_ISBC_KEY_EXT
83#endif
bdc22074
AB
84#endif /* #ifdef CONFIG_SECURE_BOOT */
85
86#ifdef CONFIG_CHAIN_OF_TRUST
b63f8a43 87#ifdef CONFIG_SPL_BUILD
8f01397b
SG
88/*
89 * PPAACT and SPAACT table for PAMU must be placed on DDR after DDR init
90 * due to space crunch on CPC and thus malloc will not work.
91 */
92#define CONFIG_SPL_PPAACT_ADDR 0x2e000000
93#define CONFIG_SPL_SPAACT_ADDR 0x2f000000
94#define CONFIG_SPL_JR0_LIODN_S 454
95#define CONFIG_SPL_JR0_LIODN_NS 458
96/*
97 * Define the key hash for U-Boot here if public/private key pair used to
98 * sign U-boot are different from the SRK hash put in the fuse
99 * Example of defining KEY_HASH is
100 * #define CONFIG_SPL_UBOOT_KEY_HASH \
101 * "41066b564c6ffcef40ccbc1e0a5d0d519604000c785d97bbefd25e4d288d1c8b"
102 * else leave it defined as NULL
103 */
104
105#define CONFIG_SPL_UBOOT_KEY_HASH NULL
106#endif /* ifdef CONFIG_SPL_BUILD */
107
bdc22074
AB
108#define CONFIG_CMD_ESBC_VALIDATE
109#define CONFIG_CMD_BLOB
110#define CONFIG_FSL_SEC_MON
111#define CONFIG_SHA_PROG_HW_ACCEL
bdc22074
AB
112#define CONFIG_RSA_FREESCALE_EXP
113
bdc22074
AB
114#ifndef CONFIG_FSL_CAAM
115#define CONFIG_FSL_CAAM
116#endif
e04916a7 117
8f01397b
SG
118#ifndef CONFIG_SPL_BUILD
119/*
120 * fsl_setenv_chain_of_trust() must be called from
d0a6d7ce
AB
121 * board_late_init()
122 */
123#ifndef CONFIG_BOARD_LATE_INIT
124#define CONFIG_BOARD_LATE_INIT
125#endif
126
5050f6f0
AB
127/* If Boot Script is not on NOR and is required to be copied on RAM */
128#ifdef CONFIG_BOOTSCRIPT_COPY_RAM
129#define CONFIG_BS_HDR_ADDR_RAM 0x00010000
69d4b48c 130#define CONFIG_BS_HDR_ADDR_DEVICE 0x00800000
5050f6f0
AB
131#define CONFIG_BS_HDR_SIZE 0x00002000
132#define CONFIG_BS_ADDR_RAM 0x00012000
69d4b48c 133#define CONFIG_BS_ADDR_DEVICE 0x00802000
5050f6f0
AB
134#define CONFIG_BS_SIZE 0x00001000
135
136#define CONFIG_BOOTSCRIPT_HDR_ADDR CONFIG_BS_HDR_ADDR_RAM
137#else
138
98cb0efd 139/* The bootscript header address is different for B4860 because the NOR
140 * mapping is different on B4 due to reduced NOR size.
141 */
d46a4a13 142#if defined(CONFIG_TARGET_B4860QDS) || defined(CONFIG_TARGET_B4420QDS)
98cb0efd 143#define CONFIG_BOOTSCRIPT_HDR_ADDR 0xecc00000
144#elif defined(CONFIG_FSL_CORENET)
145#define CONFIG_BOOTSCRIPT_HDR_ADDR 0xe8e00000
a202b9f8 146#elif defined(CONFIG_TARGET_BSC9132QDS)
98cb0efd 147#define CONFIG_BOOTSCRIPT_HDR_ADDR 0x88020000
ebccf255 148#elif defined(CONFIG_TARGET_C29XPCIE)
98cb0efd 149#define CONFIG_BOOTSCRIPT_HDR_ADDR 0xec020000
150#else
151#define CONFIG_BOOTSCRIPT_HDR_ADDR 0xee020000
152#endif
153
bdc22074 154#endif /* #ifdef CONFIG_BOOTSCRIPT_COPY_RAM */
98cb0efd 155
bdc22074 156#include <config_fsl_chain_trust.h>
8f01397b 157#endif /* #ifndef CONFIG_SPL_BUILD */
bdc22074 158#endif /* #ifdef CONFIG_CHAIN_OF_TRUST */
0d2cff2d 159#endif