| 1b5c7ca4 | 22-Jun-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
core: interrupt: helper function interrupt_alloc_add_conf_handler()
Adds interrupt API function interrupt_alloc_add_conf_handler() to allocate, configure and register an interrupt handler, providing
core: interrupt: helper function interrupt_alloc_add_conf_handler()
Adds interrupt API function interrupt_alloc_add_conf_handler() to allocate, configure and register an interrupt handler, providing interrupt type and priority.
Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 99e2612c | 16-May-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
drivers: move to interrupt_call_handlers()
Removes itr_handle() in favor to interrupt_call_handlers(). This changes updates all implemented main interrupt controller drivers that are the GIC driver,
drivers: move to interrupt_call_handlers()
Removes itr_handle() in favor to interrupt_call_handlers(). This changes updates all implemented main interrupt controller drivers that are the GIC driver, the HFIC driver and Atmel SAIC driver.
Reviewed-by: Alvin Chang <alvinga@andestech.com> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 66d7ea0e | 06-Sep-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
drivers: regulator: DT property regulator-pull-down
Handle pull down mode for regulators which DT node sets property regulator-pull-down.
Acked-by: Jens Wiklander <jens.wiklander@linaro.org> Signed
drivers: regulator: DT property regulator-pull-down
Handle pull down mode for regulators which DT node sets property regulator-pull-down.
Acked-by: Jens Wiklander <jens.wiklander@linaro.org> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 43c155ba | 06-Sep-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
drivers: regulator: list supported levels
Adds regulator API function regulator_supported_voltages() to get the list of the voltage levels supported by the regulator.
Voltage level array is either
drivers: regulator: list supported levels
Adds regulator API function regulator_supported_voltages() to get the list of the voltage levels supported by the regulator.
Voltage level array is either an array of increasing ordered levels, in microvolt, or is a triplet [min, max, step] for linear step incremental levels.
Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 199cc636 | 06-Oct-2023 |
Alvin Chang <alvinga@andestech.com> |
drivers: ns16550: Implement helper function to get driver info
Implement chip_to_base_and_data() for ns16550 UART driver to get effective address and private structure.
Signed-off-by: Alvin Chang <
drivers: ns16550: Implement helper function to get driver info
Implement chip_to_base_and_data() for ns16550 UART driver to get effective address and private structure.
Signed-off-by: Alvin Chang <alvinga@andestech.com> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| f33bc3ef | 26-Sep-2023 |
Alvin Chang <alvinga@andestech.com> |
drivers: plic: Maintain controller data in driver source file
To align the design from other architecture, we move the interrupt controller data instance from platform source file to driver source f
drivers: plic: Maintain controller data in driver source file
To align the design from other architecture, we move the interrupt controller data instance from platform source file to driver source file. With this change, the PLIC initialization functions no more get the controller data as input argument. Platforms do not need to care about the interrupt controller data instance.
Signed-off-by: Alvin Chang <alvinga@andestech.com> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com> Reviewed-by: Marouene Boubakri <marouene.boubakri@nxp.com>
show more ...
|
| 97ea199a | 15-Sep-2023 |
Xiaoxu Zeng <zengxiaoxu@huawei.com> |
core: io: IO_READ32_POLL_TIMEOUT()
Implement Polling Read Register Interface inspired by linux kernel.
Signed-off-by: Xiaoxu Zeng <zengxiaoxu@huawei.com> Reviewed-by: Etienne Carriere <etienne.carr
core: io: IO_READ32_POLL_TIMEOUT()
Implement Polling Read Register Interface inspired by linux kernel.
Signed-off-by: Xiaoxu Zeng <zengxiaoxu@huawei.com> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 6558b565 | 14-Sep-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
drivers: regulator: register to dt_driver
Adds regulator_dt_register() for regulator drivers to register regulator instances based on the DT description of the platform.
Regulator instances may not
drivers: regulator: register to dt_driver
Adds regulator_dt_register() for regulator drivers to register regulator instances based on the DT description of the platform.
Regulator instances may not be created and initialized when regulator_dt_register() returns. When a regulator depends on a supply this latter may not yet be registered and initialized. The framework will resolve the regulator dependencies later.
At OP-TEE core last initcall stage, a debug message informs in case of remaining unresolved regulator dependency. Used resources are released and no error status is returns to the system.
regulator_dt_register() uses a dedicated struct regu_dt_desc ABI to get the description of the regulator to be registered.
Acked-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Co-developed-by: Pascal Paillet <p.paillet@foss.st.com> Signed-off-by: Pascal Paillet <p.paillet@foss.st.com> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| c9c53de1 | 14-Sep-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
core: dt_driver: add dt_driver_provider_priv_data()
Implements dt_driver_provider_priv_data() to get the private data registered with a provider. Regulator framework will use this function to return
core: dt_driver: add dt_driver_provider_priv_data()
Implements dt_driver_provider_priv_data() to get the private data registered with a provider. Regulator framework will use this function to return the regulator handle associated to a regulator provider driver.
Acked-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 193944aa | 14-Sep-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
core: dt_driver: define DT_DRIVER_REGULATOR
Adds DT_DRIVER_REGULATOR for a regulator consumer to retrieve its regulator device(s) from device tree information.
Acked-by: Gatien Chevallier <gatien.c
core: dt_driver: define DT_DRIVER_REGULATOR
Adds DT_DRIVER_REGULATOR for a regulator consumer to retrieve its regulator device(s) from device tree information.
Acked-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| e3830fc7 | 02-Oct-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
drivers: regulator: always on property
Implements always-on regulator property for regulators that once enabled shall never be disabled. This is archived using a regulator_enable() call to increment
drivers: regulator: always on property
Implements always-on regulator property for regulators that once enabled shall never be disabled. This is archived using a regulator_enable() call to increment its refcount.
Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Acked-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 1a3d3273 | 12-Sep-2023 |
Etienne Carriere <etienne.carriere@foss.st.com> |
drivers: regulator framework
Introduces a voltage regulator driver framework for management of regulators and supply dependencies. The framework permits 1 regulator supply per regulator.
API functi
drivers: regulator framework
Introduces a voltage regulator driver framework for management of regulators and supply dependencies. The framework permits 1 regulator supply per regulator.
API function regulator_register() allows a regulator driver to register a regulator in the regulator framework.
Supported operation here are to enable, disable, get and set voltage level. They are all optional.
Registered regulators are referenced in a list for initialization resource release and debug purpose.
Acked-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Co-developed-by: Pascal Paillet <p.paillet@foss.st.com> Signed-off-by: Pascal Paillet <p.paillet@foss.st.com> Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 11c218db | 30-Aug-2023 |
Clement Faure <clement.faure@nxp.com> |
core: imx: move PSCI SNVS operation to the driver
Create imx_snvs_shutdown() to use during psci_system_off() call.
Signed-off-by: Clement Faure <clement.faure@nxp.com> Acked-by: Jens Wiklander <jen
core: imx: move PSCI SNVS operation to the driver
Create imx_snvs_shutdown() to use during psci_system_off() call.
Signed-off-by: Clement Faure <clement.faure@nxp.com> Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 623b9bd4 | 23-Aug-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: use monotonic counter for secure storage without RPMB
If OP-TEE is configured without RPMB (CFG_REE_FS_INTEGRITY_RPMB=n), use the non-volatile monotonic counter interface instead to protect ag
core: use monotonic counter for secure storage without RPMB
If OP-TEE is configured without RPMB (CFG_REE_FS_INTEGRITY_RPMB=n), use the non-volatile monotonic counter interface instead to protect against rollback of the REE FS base secure storage.
If configured without CFG_WARN_INSECURE=y, accept TEE_ERROR_NOT_IMPLEMENTED error from nv_counter_get_ree_fs() and nv_counter_incr_ree_fs_to() and warn once to make clear that the configuration isn't secure.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com> Tested-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 200cc96d | 23-Aug-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add non-volatile monotonic counter interface
Adds a stubbed non-volatile monotonic counter interface with a REE FS counter. Platforms or drivers overrides the weak functions nv_counter_get_ree
core: add non-volatile monotonic counter interface
Adds a stubbed non-volatile monotonic counter interface with a REE FS counter. Platforms or drivers overrides the weak functions nv_counter_get_ree_fs() and nv_counter_incr_ree_fs_to() to provide a non-stubbed implementation of the counter.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 0bbbe306 | 13-Sep-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: make core_mmu_set_secure_memory() available
Makes core_mmu_set_secure_memory() unconditionally available, but add a runtime_assert() to protect against calls without CFG_CORE_PHYS_RELOCATABLE=
core: make core_mmu_set_secure_memory() available
Makes core_mmu_set_secure_memory() unconditionally available, but add a runtime_assert() to protect against calls without CFG_CORE_PHYS_RELOCATABLE=y.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Leisen <leisen1@huawei.com> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 330e04ef | 13-Sep-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: rename tos_fw_config_dt to manifest_dt
Renames tos_fw_config_dt to manifest_dt as a preparation for coming patches to let it represent all device tree manifests provided in an FF-A configurati
core: rename tos_fw_config_dt to manifest_dt
Renames tos_fw_config_dt to manifest_dt as a preparation for coming patches to let it represent all device tree manifests provided in an FF-A configuration.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Leisen <leisen1@huawei.com> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| d4bd157e | 08-Sep-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add MEM_AREA_MANIFEST_DT
Adds MEM_AREA_MANIFEST_DT for mapping an FF-A manifest FDT.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Leisen <leisen1@huawei.com> Acked-by:
core: add MEM_AREA_MANIFEST_DT
Adds MEM_AREA_MANIFEST_DT for mapping an FF-A manifest FDT.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Leisen <leisen1@huawei.com> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 280dd882 | 02-Jun-2023 |
Clement Faure <clement.faure@nxp.com> |
drivers: caam: add DEK blob support
The CAAM can generate a specific key blob called DEK blob - Data Encryption Key blob. It encapsulates and encrypts the plain text key used to encrypt the boot ima
drivers: caam: add DEK blob support
The CAAM can generate a specific key blob called DEK blob - Data Encryption Key blob. It encapsulates and encrypts the plain text key used to encrypt the boot image. This blob is decapsulated by the HAB - High Assurance boot at boot to decrypt the boot image.
The DEK blob is a specific CAAM blob as it requires a header and the key must be encapsulated from the CAAM secure memory.
Enable the CAAM DEK blob support on imx8m platforms.
Signed-off-by: Clement Faure <clement.faure@nxp.com> Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| b39fcd95 | 06-Sep-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add bb_free_wipe()
Adds bb_free_wipe() the bounce buffer counter-part of free_wipe().
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere
core: add bb_free_wipe()
Adds bb_free_wipe() the bounce buffer counter-part of free_wipe().
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| c10e3fa9 | 31-Aug-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: fix race in handling TA panic
A TA context (struct tee_ta_ctx), can only be accessed and manipulated if either locked or set to busy by the current thread, or if it has no no other references.
core: fix race in handling TA panic
A TA context (struct tee_ta_ctx), can only be accessed and manipulated if either locked or set to busy by the current thread, or if it has no no other references.
Prior to this patch this wasn't followed by tee_ta_open_session(), tee_ta_invoke_command(), and dump_ta_memstats(). Accesses were made to the "panicked" field of struct tee_ta_ctx. destroy_ta_ctx_from_session() was also manipulating sessions possibly being used by other threads.
So fix this by only accessing the internals of the TA context while holding the needed lock. destroy_ta_ctx_from_session() is removed, the new ts_ops callback release_state() is used instead to free what can be freed from a panicked TA context. The last session referencing the TA context will free it.
Fixes: fd10f62b8210 ("core: keep alive TA context can be created after TA has panicked") Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com> Tested-by: Wentao Sun <wentao.sun@amlogic.com>
show more ...
|
| 5a5d1173 | 01-Sep-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add release_state to struct ts_ops
Adds the optional function pointer release_state() to struct ts_ops. This callback will be called when a TA has panicked and as many resources as possible ne
core: add release_state to struct ts_ops
Adds the optional function pointer release_state() to struct ts_ops. This callback will be called when a TA has panicked and as many resources as possible need to be released early. release_state() is a subset of the destroy() callback. When the destroy() is called eventually it will free the entire state of the TA regardless if release_state() has been called before or not. This allows freeing resources while there are still open sessions to the TA.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| ef44161f | 25-Aug-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: update ts_store API with user space buffer
Updates the read() function pointer in struct ts_store_ops to take an user space buffer in addition to the previous core buffer. Core buffers are nor
core: update ts_store API with user space buffer
Updates the read() function pointer in struct ts_store_ops to take an user space buffer in addition to the previous core buffer. Core buffers are normal secure memory while user space buffers should only be accessed using the user_access.h functions.
The different TA storage implementations are updated accordingly.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
show more ...
|
| 107f49d1 | 25-Aug-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add BB_MEMDUP_USER() and BB_MEMDUP_USER_PRIVATE()
Adds BB_MEMDUP_USER() and BB_MEMDUP_USER_PRIVATE() wrapper macros to allow non-void pointer destination.
Signed-off-by: Jens Wiklander <jens.
core: add BB_MEMDUP_USER() and BB_MEMDUP_USER_PRIVATE()
Adds BB_MEMDUP_USER() and BB_MEMDUP_USER_PRIVATE() wrapper macros to allow non-void pointer destination.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 0b00e98d | 23-Aug-2023 |
Jerome Forissier <jerome.forissier@linaro.org> |
core: linker.h: replace __arm__ with ARM32
We use ARM32 and ARM64 throughout the core code, not __arm__ and __aarch64__, so replace the occurrence of __arm__ that is in linker.h.
Signed-off-by: Jer
core: linker.h: replace __arm__ with ARM32
We use ARM32 and ARM64 throughout the core code, not __arm__ and __aarch64__, so replace the occurrence of __arm__ that is in linker.h.
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|