Age | Commit message (Collapse) | Author |
|
reuse most of the i.mx 8mq supports.
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
- Add RNG Handles instantation using basic Job Ring
- Increment TRNG entropy configuration in case of failure
Signed-off-by: Cedric Neveux <cedric.neveux@nxp.com>
|
|
The normal world and secure world have both R/W access to OCOTP now.
Signed-off-by: Clement Faure <clement.faure@nxp.com>
|
|
The OCRAM space allocated to optee is Trustzone protected. Only the
begin address of the protection is specifiable.
This function fetches the address of the node to protect in the dtb.
Nodes to protect are specified by its compatible string in
tz_ocram_match[] tab.
This function defines the beginning the start address of the TZ ocram
space.
Signed-off-by: Clement Faure <clement.faure@nxp.com>
|
|
dt_overwrite() overwrites specified properties in the device tree.
Properties to overwrite and new properties are also specified
in the device tree.
The format is the following :
overw_str = <&node_1 prop_1 ... prop_n>,
<&node_2 prop_1 ... prop_n>,
...
<&node_n prop_1 ... prop_n>;
prop_n variables are 32bit integers.
Signed-off-by: Clement Faure <clement.faure@nxp.com>
|
|
- Add a OCRAM initialization as a service init
- Function is called automatically at boot and no need
to call it at suspend time
Signed-off-by: Cedric Neveux <cedric.neveux@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
|
|
Signed-off-by: Franck LENORMAND <franck.lenormand@nxp.com>
|
|
The SMP bit needs to be make ldrex/strex instruction work properly.
Fixes: 21aeeaa2301f6bc ("MLK-17962-2 core: arm: imx: a9: tune ACTLR")
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
bootup.100%
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
The PL310_AUX_CTRL_INIT should have
- 16kb way size (bit19:17=3b001)
- 16-way associciativity (bit16=1)
Fixes: e934a0507ee496 ("MLK-17962-3 core: arm: imx: tune PL310 configuration")
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
Under very rare timing circumstances, a data corruption might occur on
a dirty cache line that is evicted from the L1 Data Cache due to another
cache line being entirely written.
Configurations affected:
This erratum affects configurations with either:
- One processor if the ACP is present
- Two or more processors
This erratum can be worked round by setting bit[22] of the undocumented
Diagnostic Control Register to 1. This register is encoded as CP15 c15 0 c0 1.
The bit can be written in Secure state only, with the following
Read/Modify/Write code sequence:
MRC p15,0,rt,c15,c0,1
ORR rt,rt,#0x00400000
MCR p15,0,rt,c15,c0,1
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
The current tag/data ram, prefetch value is not the best value.
With this, the performance is not good. So retune the value
to match i.MX design to have good performance.
Also there is PL310 errata that we need to disable Double linefill
for version below r3p2 pl310.
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
Tune ACTLR. To SLL, the value is 0xE at runtime.
To others, the value should be 0x4F at runtime.
Bit3 will be enabled when enable L2.
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
The default value of L1PCTL field in ACTLR is 0x3, which is
"3 outstanding pre-fetches permitted", the value should not
be override with 0 to decrease the performance.
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
i.MX 6SL EVK board has 1GB DDR
adjust the configuration to match this.
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
read
When RDC is used to protect SDP instead of TZASC, the CPU do not have
read access to the memory region. Then when the MMU tries to fill the
cache with predictive read, cache line get zeros instead of correct
value.
Signed-off-by: Olivier Masse <olivier.masse@nxp.com>
|
|
- The memory is divided in 4 TZASC regions:
Region 0 : Maps all the available memory. Secure and Non-Secure, RW
Region 1 : Maps all the DDR. Non-secure, RW
Region 2 : Maps the TZ RAM. Secure, RW
Region 3 : Maps the Shared Memory. Secure and Non-Secure, RW
- The priority of a region increases with the region number.
- A region is enabled as soon as the region is configured.
- Region Start and Size:
Region 0 : 0x00000000 (4G)
Region 1 : 0x80000000 (2G)
Region 2 : 0xbe000000 (32M)
Region 3 : 0xbfe00000 (2M)
Signed-off-by: Clement Faure <clement.faure@nxp.com>
|
|
Signed-off-by: Clement Faure <clement.faure@nxp.com>
|
|
Signed-off-by: Clement Faure <clement.faure@nxp.com>
|
|
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
Add support for i.MX 8mscale (AARCH64)
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
Add support for i.MX 7ulp SoC
TODO some cleanup on the header files
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
update watchdog support
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
add new lpuart driver
This driver is used by the i.MX 7ulp SoC
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
Add i.MX6SLL EVK board support.
Signed-off-by: Bai Ping <ping.bai@nxp.com>
|
|
Add i.MX6SL EVK board support.
Signed-off-by: Bai Ping <ping.bai@nxp.com>
|
|
- Add CAAM controller to initialize the JR Owner
Allow Non-secure world access to Job Rings
- Add RNG entropy configuration
CAAM control Block 0 registers are not accessible by the CPU
running in Non-Secure world and so can not configure the RNG
entropy.
However, the default register settings is not suitable on
every SoC.
This is the case for i.MX 6SX and because the RNG entropy is not
configured correctly, the NS SW can not do the RNG instantiation
Signed-off-by: Cedric Neveux <cedric.neveux@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
|
|
Add clock module registers definition for i.MX6 and i.MX7
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
Add tzasc configuration for imx platforms.
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
- Add default configuration to all the imx platform
to avoid passing them to the command line
- Add some more board definition that are edrived from already
available SoC support
Please note the Change in configuration for the 6Q/D/DL from
CFG_BOOT_SYNC_CPU = y to n
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
Add a SCU module
Signed-off-by: Cedric Neveux <cedric.neveux@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
|
|
Centralize CSU settings in one file
Signed-off-by: Cedric Neveux <cedric.neveux@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
|
|
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
|
|
- Move registers to subdirectory
- Rename registers to be almost common
Signed-off-by: Cedric Neveux <cedric.neveux@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
|
|
Create standalone config file for different SoCs
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
|
use WDT_WCR defined in watchdog specific imx_wdog.h
instead of WCR_OFF defined in the platform imx-regs.h
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
|
|
Makes stack trace robust by checking addresses before copying data.
Kernel stack traces are a bit more relaxed as we have crashed already.
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (HiKey960 AArch32, Aarch64)
Tested-by: Jens Wiklander <jens.wiklander@linaro.org> (Juno, QEMU)
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
|
|
Prior to this patch assign_mobj_to_param_mem() stored the offset
supplied with a non-contiguous buffer in mem->offs. Since that offset
already is stored inside the resulting MOBJ that offset is added twice.
This patch fixes this by initializing mem->offs to 0 instead.
Reviewed-by: Volodymyr Babchuk <vlad.babchuk@gmail.com>
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
|
|
Once non-secure DDR is discovered either via FDT or via register_ddr()
maximum output address is updated.
Note that is only has an effect in AArch64.
Fixes: https://github.com/OP-TEE/optee_os/issues/2402
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
Suggested-by: Jean-Paul Etienne <jean-paul.etienne@arm.com>
Reported-by: Rouven Czerwinski <rouven@czerwinskis.de>
Tested-by: Jens Wiklander <jens.wiklander@linaro.org> (Juno, FVP)
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
|
|
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
|
|
Use MIN_UNSAFE/MAX_UNSAFE macros as MAX/MIN macros fail to build
from in current platform_config.h imaplement with the error trace
below:
In file included from core/arch/arm/include/arm.h:8:0,
from core/arch/arm/include/kernel/thread.h:11,
from core/arch/arm/kernel/asm-defines.c:7:
lib/libutils/ext/include/util.h:24:16: error: missing binary operator before token "("
(__extension__({ __typeof__(a) _a = (a); \
^
core/arch/arm/plat-stm/./platform_config.h:190:25: note: in expansion of macro ‘MAX’
#define STM_SECDDR_END MAX(TZSRAM_BASE + TZSRAM_SIZE, \
^~~
core/arch/arm/plat-stm/./platform_config.h:204:6: note: in expansion of macro ‘STM_SECDDR_END’
#if (STM_SECDDR_END < 0x80000000ULL)
^~~~~~~~~~~~~~
make: *** [out/core/include/generated/.asm-defines.s] Error 1
Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
|
|
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
|
|
In case if timestamp buffer is allocated in userspace and new register
user memory API is used for its registering in OP-TEE (introduced in
optee_client commit 27888d73d156 ("tee_client_api: register user memory")),
there is no possibility to keep this mapping permanent among different
TEEC_InvokeCommand invocations, as all SHM are automatically unmapped from
OP-TEE VA space after TEEC_InvokeCommand is handled by OP-TEE.
Timestamp buffer is now allocated with thread_rpc_alloc_global_payload().
Fixes: https://github.com/OP-TEE/optee_os/issues/1979
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
Acked-by: Etienne Carriere <etienne.carriere@linaro.org>
Reviewed-by: Joakim Bech <joakim.bech@linaro.org>
Signed-off-by: Igor Opaniuk <igor.opaniuk@linaro.org>
|
|
Add support of allocating SHM shared with non-secure kernel
and exported to a non-secure userspace application.
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
Signed-off-by: Igor Opaniuk <igor.opaniuk@linaro.org>
|
|
objectSize/keySize was not getting updated when an ECDSA/ECDH
object was imported.
Updating the ObjectSize/keySize based on the EC Curve.
Fixes: https://github.com/OP-TEE/optee_os/issues/2386
Signed-off-by: Sahil Malhotra <sahil.malhotra@nxp.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
|
|
OP-TEE core images are reformatted into a STM32 compliant format
expected by the platform flashing tools.
Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
|
|
Used by platform stm32mp1.
Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
|