History log of /optee_os/core/kernel/ (Results 26 – 50 of 493)
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
00a2b8c728-Apr-2025 Jerome Forissier <jerome.forissier@linaro.org>

core: kernel: dt_driver: variable may be unused

Fix the following warning with Clang 18.6.1:

core/kernel/dt_driver.c:456:15: error: variable 'count' set but not used [-Werror,-Wunused-but-set-vari

core: kernel: dt_driver: variable may be unused

Fix the following warning with Clang 18.6.1:

core/kernel/dt_driver.c:456:15: error: variable 'count' set but not used [-Werror,-Wunused-but-set-variable]
456 | unsigned int count = 0;
| ^

Indeed, when CFG_TEE_CORE_LOG_LEVEL <= 2, the value of count is never
read.

Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Gatien Chevallier <gatien.chevallier@foss.st.com>

show more ...

414123ae03-Apr-2025 Jens Wiklander <jens.wiklander@linaro.org>

core: ffa: reserve physical memory for manifest

With CFG_CORE_SEL2_SPMC=y (Hafnium as SPMC at S-EL2), the FF-A manifest
passed to OP-TEE resides in the memory reserved for OP-TEE just before
the loa

core: ffa: reserve physical memory for manifest

With CFG_CORE_SEL2_SPMC=y (Hafnium as SPMC at S-EL2), the FF-A manifest
passed to OP-TEE resides in the memory reserved for OP-TEE just before
the load address. The physical memory pool is initialized with the entire
range of secure memory, with holes carved out for already used memory.

Temporarily allocate the physical memory used by the manifest until it's
not needed any longer and released by release_manifest_dt().

Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>

show more ...

45c754ce16-Apr-2025 Jens Wiklander <jens.wiklander@linaro.org>

core: fix crash during syscall ftrace

Syscall ftrace collects data during a syscall. get_fbuf() checks if
thread_get_id_may_fail() != -1 to see if a function is called under
normal thread execution.

core: fix crash during syscall ftrace

Syscall ftrace collects data during a syscall. get_fbuf() checks if
thread_get_id_may_fail() != -1 to see if a function is called under
normal thread execution. This can lead to an inconsistent state if a
native interrupt occur while ftrace_enter() or ftrace_return() is
recording data in the ftrace buffer. So fix this by using
thread_is_in_normal_mode() to exclude ftrace during interrupt
processing.

Reported-by: Jerome Forissier <jerome.forissier@linaro.org>
Closes: https://github.com/OP-TEE/optee_os/issues/7216
Fixes: 099918f6744c ("ftrace: Add support for syscall function tracer")
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (vexpress-qemu_armv8a)

show more ...

c60785c428-Mar-2025 Yu-Chien Peter Lin <peter.lin@sifive.com>

core: move plat_get_random_stack_canaries() to common part

Other architectures (e.g. RISC-V) may want to call
plat_get_random_stack_canaries() for random stack
canaries. Move it from ARM architectur

core: move plat_get_random_stack_canaries() to common part

Other architectures (e.g. RISC-V) may want to call
plat_get_random_stack_canaries() for random stack
canaries. Move it from ARM architecture directory
to common part.

Signed-off-by: Yu-Chien Peter Lin <peter.lin@sifive.com>
Co-developed-by: Alvin Chang <alvinga@andestech.com>
Signed-off-by: Alvin Chang <alvinga@andestech.com>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...


/optee_os/.github/workflows/ci.yml
/optee_os/core/arch/arm/kernel/boot.c
/optee_os/core/arch/arm/kernel/link.mk
/optee_os/core/arch/arm/kernel/thread_spmc.c
/optee_os/core/arch/arm/plat-imx/conf.mk
/optee_os/core/arch/arm/plat-rockchip/platform_config.h
/optee_os/core/arch/arm/plat-rockchip/platform_rk3588.c
/optee_os/core/arch/riscv/include/kernel/misc_arch.h
/optee_os/core/arch/riscv/include/kernel/thread_arch.h
/optee_os/core/arch/riscv/include/riscv.h
/optee_os/core/arch/riscv/include/sbi.h
/optee_os/core/arch/riscv/kernel/asm-defines.c
/optee_os/core/arch/riscv/kernel/boot.c
/optee_os/core/arch/riscv/kernel/entry.S
/optee_os/core/arch/riscv/kernel/link.mk
/optee_os/core/arch/riscv/kernel/sbi.c
/optee_os/core/arch/riscv/kernel/thread_arch.c
/optee_os/core/arch/riscv/kernel/thread_rv.S
/optee_os/core/arch/riscv/plat-sifive/conf.mk
/optee_os/core/arch/riscv/plat-sifive/main.c
/optee_os/core/arch/riscv/plat-sifive/platform_config.h
/optee_os/core/arch/riscv/plat-sifive/sub.mk
/optee_os/core/arch/riscv/plat-spike/conf.mk
/optee_os/core/arch/riscv/plat-virt/platform_config.h
/optee_os/core/core.mk
/optee_os/core/drivers/firewall/stm32_rifsc.c
/optee_os/core/drivers/imx_csu.c
/optee_os/core/drivers/sifive_uart.c
/optee_os/core/drivers/sub.mk
/optee_os/core/include/drivers/sifive_uart.h
/optee_os/core/include/kernel/boot.h
boot.c
/optee_os/core/mm/core_mmu.c
/optee_os/core/pta/tests/misc.c
/optee_os/ldelf/link.mk
/optee_os/lib/libmbedtls/mbedtls/ChangeLog
/optee_os/lib/libmbedtls/mbedtls/SECURITY.md
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/build_info.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/check_config.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/config_adjust_legacy_crypto.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/config_adjust_legacy_from_psa.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/config_adjust_psa_superset_legacy.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/debug.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/entropy.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/error.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/gcm.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/net_sockets.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/psa_util.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/ssl.h
/optee_os/lib/libmbedtls/mbedtls/include/mbedtls/threading.h
/optee_os/lib/libmbedtls/mbedtls/include/psa/crypto_config.h
/optee_os/lib/libmbedtls/mbedtls/include/psa/crypto_extra.h
/optee_os/lib/libmbedtls/mbedtls/include/psa/crypto_sizes.h
/optee_os/lib/libmbedtls/mbedtls/library/aesni.c
/optee_os/lib/libmbedtls/mbedtls/library/bignum_core.c
/optee_os/lib/libmbedtls/mbedtls/library/bignum_core.h
/optee_os/lib/libmbedtls/mbedtls/library/bignum_core_invasive.h
/optee_os/lib/libmbedtls/mbedtls/library/ccm.c
/optee_os/lib/libmbedtls/mbedtls/library/common.h
/optee_os/lib/libmbedtls/mbedtls/library/constant_time_impl.h
/optee_os/lib/libmbedtls/mbedtls/library/ecp.c
/optee_os/lib/libmbedtls/mbedtls/library/error.c
/optee_os/lib/libmbedtls/mbedtls/library/net_sockets.c
/optee_os/lib/libmbedtls/mbedtls/library/pk.c
/optee_os/lib/libmbedtls/mbedtls/library/psa_crypto.c
/optee_os/lib/libmbedtls/mbedtls/library/psa_crypto_cipher.c
/optee_os/lib/libmbedtls/mbedtls/library/psa_crypto_core.h
/optee_os/lib/libmbedtls/mbedtls/library/psa_crypto_driver_wrappers.h
/optee_os/lib/libmbedtls/mbedtls/library/psa_crypto_ecp.c
/optee_os/lib/libmbedtls/mbedtls/library/psa_crypto_slot_management.c
/optee_os/lib/libmbedtls/mbedtls/library/psa_crypto_storage.h
/optee_os/lib/libmbedtls/mbedtls/library/psa_util.c
/optee_os/lib/libmbedtls/mbedtls/library/ssl_client.c
/optee_os/lib/libmbedtls/mbedtls/library/ssl_debug_helpers_generated.c
/optee_os/lib/libmbedtls/mbedtls/library/ssl_misc.h
/optee_os/lib/libmbedtls/mbedtls/library/ssl_msg.c
/optee_os/lib/libmbedtls/mbedtls/library/ssl_tls.c
/optee_os/lib/libmbedtls/mbedtls/library/ssl_tls12_client.c
/optee_os/lib/libmbedtls/mbedtls/library/ssl_tls12_server.c
/optee_os/lib/libmbedtls/mbedtls/library/ssl_tls13_client.c
/optee_os/lib/libmbedtls/mbedtls/library/ssl_tls13_server.c
/optee_os/lib/libmbedtls/mbedtls/library/threading.c
/optee_os/lib/libmbedtls/mbedtls/library/version_features.c
/optee_os/lib/libutee/include/pta_stats.h
/optee_os/lib/libutee/tcb.c
/optee_os/lib/libutee/tee_api.c
/optee_os/lib/libutils/ext/sub.mk
/optee_os/lib/libutils/ext/ubsan.c
/optee_os/lib/libutils/isoc/bget.c
/optee_os/lib/libutils/isoc/bget_malloc.c
/optee_os/lib/libutils/isoc/include/malloc.h
/optee_os/mk/compile.mk
/optee_os/mk/config.mk
/optee_os/scripts/checkpatch.sh
/optee_os/scripts/checkpatch_inc.sh
/optee_os/ta/link.mk
/optee_os/ta/mk/build-user-ta.mk
/optee_os/ta/mk/ta_dev_kit.mk
/optee_os/ta/pkcs11/scripts/dump_ec_curve_params.sh
/optee_os/ta/pkcs11/scripts/verify-helpers.sh
/optee_os/ta/ta.mk
ff3ed64415-Jan-2025 Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>

ldelf: enable ubsan support

Ubsan support was previously limited to core code. This commit moves the
ubsan runtime implementation to libutils, making it available for ldelf
and trusted applications.

ldelf: enable ubsan support

Ubsan support was previously limited to core code. This commit moves the
ubsan runtime implementation to libutils, making it available for ldelf
and trusted applications.

As a result, ldelf will now be built with ubsan support when
CFG_CORE_SANITIZE_UNDEFINED is enabled.

Additionally, to avoid potential infinite recursion, ubsan
instrumentation is explicitly disabled for ubsan.c.

Signed-off-by: Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>
Reviewed-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 ...

758c368713-Mar-2025 Jens Wiklander <jens.wiklander@linaro.org>

core: fix CFG_BOOT_INIT_THREAD_CORE_LOCAL0

CFG_BOOT_INIT_THREAD_CORE_LOCAL0 is misleading since it's concerning the
core id of the boot CPU. So rename the configuration flag to
CFG_BOOT_INIT_CURRENT

core: fix CFG_BOOT_INIT_THREAD_CORE_LOCAL0

CFG_BOOT_INIT_THREAD_CORE_LOCAL0 is misleading since it's concerning the
core id of the boot CPU. So rename the configuration flag to
CFG_BOOT_INIT_CURRENT_THREAD_CORE_LOCAL and update the code as needed.
Only thread_init_thread_core_local() has a change of behaviour where the
boot CPU now can have any core id.

Fixes: b5ec8152f3e5 ("core: arm: refactor boot")
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 ...


/optee_os/.github/workflows/ci.yml
/optee_os/MAINTAINERS
/optee_os/core/arch/arm/arm.mk
/optee_os/core/arch/arm/dts/stm32mp135f-dk.dts
/optee_os/core/arch/arm/dts/stm32mp15xx-dhcor-avenger96.dtsi
/optee_os/core/arch/arm/kernel/boot.c
/optee_os/core/arch/arm/kernel/entry_a32.S
/optee_os/core/arch/arm/kernel/entry_a64.S
/optee_os/core/arch/arm/kernel/link.mk
/optee_os/core/arch/arm/kernel/virtualization.c
/optee_os/core/arch/arm/mm/core_mmu_lpae.c
/optee_os/core/arch/arm/plat-imx/conf.mk
/optee_os/core/arch/arm/plat-imx/registers/imx93.h
/optee_os/core/arch/arm/plat-rockchip/conf.mk
/optee_os/core/arch/arm/plat-sam/scmi_server.c
/optee_os/core/arch/arm/plat-stm32mp1/conf.mk
/optee_os/core/arch/riscv/include/riscv.h
/optee_os/core/arch/riscv/kernel/boot.c
/optee_os/core/arch/riscv/kernel/entry.S
/optee_os/core/arch/riscv/mm/core_mmu_arch.c
/optee_os/core/arch/riscv/plat-virt/conf.mk
/optee_os/core/arch/riscv/plat-virt/main.c
/optee_os/core/arch/riscv/plat-virt/platform_config.h
/optee_os/core/arch/riscv/riscv.mk
/optee_os/core/drivers/aplic_direct.c
/optee_os/core/drivers/aplic_msi.c
/optee_os/core/drivers/aplic_priv.c
/optee_os/core/drivers/clk/sam/at91_clk.h
/optee_os/core/drivers/clk/sam/clk-sam9x60-pll.c
/optee_os/core/drivers/clk/sam/sama7g5_clk.c
/optee_os/core/drivers/crypto/ele/crypto.mk
/optee_os/core/drivers/crypto/ele/ele.c
/optee_os/core/drivers/crypto/ele/include/ele.h
/optee_os/core/drivers/crypto/ele/include/memutils.h
/optee_os/core/drivers/crypto/ele/memutils.c
/optee_os/core/drivers/crypto/ele/sub.mk
/optee_os/core/drivers/crypto/stm32/common.h
/optee_os/core/drivers/crypto/stm32/crypto.mk
/optee_os/core/drivers/crypto/stm32/hash.c
/optee_os/core/drivers/crypto/stm32/hmac.c
/optee_os/core/drivers/crypto/stm32/stm32_hash.c
/optee_os/core/drivers/crypto/stm32/stm32_hash.h
/optee_os/core/drivers/crypto/stm32/sub.mk
/optee_os/core/drivers/crypto/sub.mk
/optee_os/core/drivers/imsic.c
/optee_os/core/drivers/imx/mu/imx_mu.c
/optee_os/core/drivers/remoteproc/stm32_remoteproc.c
/optee_os/core/drivers/stm32_gpio.c
/optee_os/core/drivers/sub.mk
/optee_os/core/include/drivers/aplic.h
/optee_os/core/include/drivers/aplic_priv.h
/optee_os/core/include/drivers/imsic.h
/optee_os/core/include/dt-bindings/clock/at91.h
/optee_os/core/include/kernel/boot.h
/optee_os/core/include/mm/core_mmu.h
/optee_os/core/include/mm/page_alloc.h
/optee_os/core/include/mm/phys_mem.h
/optee_os/core/include/mm/tee_mm.h
thread.c
/optee_os/core/mm/core_mmu.c
/optee_os/core/mm/page_alloc.c
/optee_os/core/mm/phys_mem.c
/optee_os/core/mm/sub.mk
/optee_os/core/mm/tee_mm.c
/optee_os/ldelf/link.mk
/optee_os/lib/libmbedtls/include/mbedtls_config_kernel.h
/optee_os/lib/libmbedtls/include/mbedtls_config_uta.h
/optee_os/lib/libmbedtls/mbedtls/library/common.h
/optee_os/lib/libutils/ext/include/asm.S
/optee_os/lib/libutils/isoc/include/malloc_flags.h
/optee_os/mk/compile.mk
/optee_os/mk/config.mk
/optee_os/scripts/sign_encrypt.py
/optee_os/scripts/sign_rproc_fw.py
/optee_os/ta/link.mk
/optee_os/ta/link_shlib.mk
/optee_os/ta/ta.mk
5e01ede926-Feb-2025 Alvin Chang <alvinga@andestech.com>

core: kernel: Remove unused call_initcalls()

Remove call_initcalls() since there is no architecture calls it.

Signed-off-by: Alvin Chang <alvinga@andestech.com>
Reviewed-by: Jens Wiklander <jens.wi

core: kernel: Remove unused call_initcalls()

Remove call_initcalls() since there is no architecture calls it.

Signed-off-by: Alvin Chang <alvinga@andestech.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Marouene Boubakri <marouene.boubakri@nxp.com>

show more ...

2f4d5a0d07-Feb-2025 Etienne Carriere <etienne.carriere@foss.st.com>

core: interrupt: clarify inline comment in interrupt_create_handler()

Clarify inline comment in interrupt_create_handler() to explicit that
this function request add_configure_handler() to not confi

core: interrupt: clarify inline comment in interrupt_create_handler()

Clarify inline comment in interrupt_create_handler() to explicit that
this function request add_configure_handler() to not configure the
interrupt (since it's already configured from interrupt_dt_get_by_*()
API functions).

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

df7874b514-Feb-2025 Etienne Carriere <etienne.carriere@foss.st.com>

core: interrupt: itr_chip may not require configure handler

The configure handler in struct itr_ops is not required for interrupt
providers which consumers only use the DT to get and configure their

core: interrupt: itr_chip may not require configure handler

The configure handler in struct itr_ops is not required for interrupt
providers which consumers only use the DT to get and configure their
interrupts (with interrupt_dt_get_by_*() and interrupt_create_handler()).
Therefore change itr_chip_is_valid() to not enforce its support
but add back that constraint for the interrupt main controller.

Add an itr_chip_dt_only_init() helper function for interrupt
controllers which consumers only use the DT to configure their
interrupt, that is such controllers do not need a configure handler.

itr_chip_is_valid() is not called outside interrupt.c where it is
used in itr_chip_init() and itr_chip_dt_only_init() so make it a local
function.

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

2a50ce7d07-Feb-2025 Etienne Carriere <etienne.carriere@foss.st.com>

core: interrupt: rename .add handler to .configure

Rename field add of struct itr_ops to configure for consistency
since that handler is used the configure the interrupt. Update
existing interrupt d

core: interrupt: rename .add handler to .configure

Rename field add of struct itr_ops to configure for consistency
since that handler is used the configure the interrupt. Update
existing interrupt drivers accordingly.

By the way fix inline comment spelling typo (s/contrainsts/constraints/).

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

ad94da2a22-Jan-2025 Jens Wiklander <jens.wiklander@linaro.org>

core: thread: initialize stack canaries from recorded end-va

Continue where "core: thread: get stacks from recorded end-va" left and
initialize the stack canaries based on the recorded end-va. This

core: thread: initialize stack canaries from recorded end-va

Continue where "core: thread: get stacks from recorded end-va" left and
initialize the stack canaries based on the recorded end-va. This is
needed in later patches where the stacks aren't statically allocated.

Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...

05994c7622-Jan-2025 Jens Wiklander <jens.wiklander@linaro.org>

core: thread: get stacks from recorded end-va

Each stack has its end-va or top recorded in either thread_core_local[]
or threads[] as tmp_stack_va_end, abt_stack_va_end, or stack_va_end.
This addres

core: thread: get stacks from recorded end-va

Each stack has its end-va or top recorded in either thread_core_local[]
or threads[] as tmp_stack_va_end, abt_stack_va_end, or stack_va_end.
This address together with the known size of the stack is enough to
calculate all the other needed stack related addresses:
- start and end canaries,
- top and bottom of the stacks.

Add and use new internal functions to calculate these addresses and
remove the now unused macros. This is needed in later patches where the
stacks aren't statically allocated.

INIT_CANARY(), GET_START_CANARY(), and GET_END_CANARY() are kept for now
to see that the addresses for the canaries are calculated correctly in
the new functions.

Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...

b5ec815222-Jan-2025 Jens Wiklander <jens.wiklander@linaro.org>

core: arm: refactor boot

Introduce CFG_BOOT_INIT_THREAD_CORE_LOCAL0 to indicate that
thread_core_local[0] is initialized before the boot_init_* functions are
called.

thread_init_core_local_stacks()

core: arm: refactor boot

Introduce CFG_BOOT_INIT_THREAD_CORE_LOCAL0 to indicate that
thread_core_local[0] is initialized before the boot_init_* functions are
called.

thread_init_core_local_stacks() and thread_init_thread_core_local() are
replaced by a new version of thread_init_thread_core_local() for
CFG_BOOT_INIT_THREAD_CORE_LOCAL0=y.

Move initialization of thread_core_local[] from very early to
boot_init_primary_late() where various DTBs containing run-time
configuration are available. This will be needed in later patches when
the number of configured cores can be read from DT or some other
run-time configuration.

Move the "OP-TEE version" print and following code from
boot_init_primary_late() to boot_init_primary_final()

Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...

fe33e97424-Jan-2025 Sascha Hauer <s.hauer@pengutronix.de>

core: fail build when CFG_INSECURE=n used with zero HUK

CFG_INSECURE=n indicates the build may be used for production. In this
environment using the zero HUK in inappropriate, so fail the build
in t

core: fail build when CFG_INSECURE=n used with zero HUK

CFG_INSECURE=n indicates the build may be used for production. In this
environment using the zero HUK in inappropriate, so fail the build
in this case.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...

941de17823-Jan-2025 Etienne Carriere <etienne.carriere@foss.st.com>

core: interrupt: enhance registered controller chips validity

Enhance assertion of interrupt chip validity using itr_chip_is_valid()
helper function instead of only testing the chip handle is not nu

core: interrupt: enhance registered controller chips validity

Enhance assertion of interrupt chip validity using itr_chip_is_valid()
helper function instead of only testing the chip handle is not null.

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

6387340123-Jan-2025 Etienne Carriere <etienne.carriere@foss.st.com>

core: interrupt: fix property count in dt_get_irq_type_prio()

Fix the number of properties passed by dt_get_irq_type_prio()
to dt_get_irq handler of the interrupt main chip. The fixed issue
was not

core: interrupt: fix property count in dt_get_irq_type_prio()

Fix the number of properties passed by dt_get_irq_type_prio()
to dt_get_irq handler of the interrupt main chip. The fixed issue
was not seen since existing registered dt_get_irq handlers (atmel_wdt.c,
gic.c and plic.c) do not really care when this count value is too high.

Fixes: 702fe5a74327 ("core: kernel: interrupt: add type and prio for interrupts")
Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...

96e33b7f24-Jan-2025 Etienne Carriere <etienne.carriere@foss.st.com>

core: dt: cached data for fdt_get_reg_props_by_index()

Factorize fdt_get_reg_props_by_index() and fdt_reg_info() to
add DT cache info support to the former.

Signed-off-by: Etienne Carriere <etienne

core: dt: cached data for fdt_get_reg_props_by_index()

Factorize fdt_get_reg_props_by_index() and fdt_reg_info() to
add DT cache info support to the former.

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

bf27365d21-Jan-2025 Raymond Mao <raymond.mao@linaro.org>

core: fix potential crash when setting transfer entry size

Fix a potential crash when the rounded up end-of-entry exceeds the
boundary of the old end-of-transfer-list when setting the size of
a tran

core: fix potential crash when setting transfer entry size

Fix a potential crash when the rounded up end-of-entry exceeds the
boundary of the old end-of-transfer-list when setting the size of
a transfer entry.

The crash happens when the specified entry is the last one in the
transfer list and its rounded up end 'old_ev' exceeds the
'tl_old_ev' which is not rounded up, leading to a negative value
with (tl_old_ev - old_ev).

Logically, 'tl_old_ev > old_ev' is the only case that indicates
there are subsequent entries to be moved.

Signed-off-by: Raymond Mao <raymond.mao@linaro.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...


/optee_os/.github/workflows/ci.yml
/optee_os/CHANGELOG.md
/optee_os/core/arch/arm/dts/stm32mp15xx-dhcom-som.dtsi
/optee_os/core/arch/arm/dts/stm32mp15xx-dhcor-som.dtsi
/optee_os/core/arch/arm/dts/stm32mp251.dtsi
/optee_os/core/arch/arm/include/ffa.h
/optee_os/core/arch/arm/include/kernel/secure_partition.h
/optee_os/core/arch/arm/include/kernel/spmc_sp_handler.h
/optee_os/core/arch/arm/include/kernel/thread_arch.h
/optee_os/core/arch/arm/include/kernel/thread_spmc.h
/optee_os/core/arch/arm/include/mm/core_mmu_arch.h
/optee_os/core/arch/arm/kernel/asm-defines.c
/optee_os/core/arch/arm/kernel/boot.c
/optee_os/core/arch/arm/kernel/secure_partition.c
/optee_os/core/arch/arm/kernel/spmc_sp_handler.c
/optee_os/core/arch/arm/kernel/stmm_sp.c
/optee_os/core/arch/arm/kernel/thread_spmc.c
/optee_os/core/arch/arm/kernel/thread_spmc_a64.S
/optee_os/core/arch/arm/mm/core_mmu_lpae.c
/optee_os/core/arch/arm/mm/core_mmu_v7.c
/optee_os/core/arch/arm/plat-rockchip/platform_config.h
/optee_os/core/arch/arm/plat-rockchip/platform_rk3588.c
/optee_os/core/arch/arm/plat-sam/conf.mk
/optee_os/core/arch/arm/plat-sam/scmi_server.c
/optee_os/core/arch/arm/plat-stm32mp1/conf.mk
/optee_os/core/arch/arm/plat-stm32mp1/drivers/stm32mp1_pmic.c
/optee_os/core/arch/arm/plat-stm32mp2/conf.mk
/optee_os/core/drivers/atmel_rstc.c
/optee_os/core/drivers/atmel_rtc.c
/optee_os/core/drivers/clk/clk-stm32-core.c
/optee_os/core/drivers/clk/clk-stm32mp25.c
/optee_os/core/drivers/clk/clk.c
/optee_os/core/drivers/clk/sam/sama7g5_clk.c
/optee_os/core/drivers/counter/stm32_stgen.c
/optee_os/core/drivers/counter/sub.mk
/optee_os/core/drivers/gic.c
/optee_os/core/drivers/microchip_pit.c
/optee_os/core/drivers/rtc/rtc.c
/optee_os/core/drivers/stm32_i2c.c
/optee_os/core/drivers/stm32_rtc.c
/optee_os/core/drivers/sub.mk
/optee_os/core/include/drivers/atmel_rstc.h
/optee_os/core/include/drivers/gic.h
/optee_os/core/include/drivers/rtc.h
/optee_os/core/include/drivers/stm32_i2c.h
/optee_os/core/include/drivers/stm32_stgen.h
/optee_os/core/include/dt-bindings/clock/stm32mp13-clksrc.h
/optee_os/core/include/kernel/boot.h
/optee_os/core/include/tee/tee_fs.h
transfer_list.c
/optee_os/core/mm/boot_mem.c
/optee_os/core/mm/core_mmu.c
/optee_os/core/mm/tee_mm.c
/optee_os/core/pta/device.c
/optee_os/core/pta/stats.c
/optee_os/core/tee/tee_rpmb_fs.c
/optee_os/lib/libutee/include/pta_stats.h
/optee_os/lib/libutee/tee_api_arith_mpi.c
/optee_os/lib/libutils/isoc/bget_malloc.c
/optee_os/lib/libutils/isoc/include/malloc.h
/optee_os/lib/libutils/isoc/include/malloc_flags.h
/optee_os/mk/config.mk
/optee_os/scripts/sign_encrypt.py
/optee_os/ta/ta.mk
09d7477718-Dec-2024 Yuvraj Sakshith <ysakshith@gmail.com>

core: notif_default: support ns-virtualization

Add support for CFG_NS_VIRTUALIZATION=y in the default notification
implementation used with the SMC ABI.

virt_add_guest_spec_data() is used to add st

core: notif_default: support ns-virtualization

Add support for CFG_NS_VIRTUALIZATION=y in the default notification
implementation used with the SMC ABI.

virt_add_guest_spec_data() is used to add struct notif_vm_bitmap for
bookkeeping per guest, similarly to the implementation for the FF-A ABI.

This takes care of and removes the assert for "!guest" in
notif_send_async().

Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Signed-off-by: Yuvraj Sakshith <ysakshith@gmail.com>
Tested-by: Yuvraj Sakshith <ysakshith@gmail.com>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...

9f9c846a27-Dec-2024 Aleksandr Iashchenko <alexhoppus111@gmail.com>

core: refactor ubsan panic code

Move panic invocation to common function. That makes entire code a
little bit more compact and removes duplications. Also remove
volatile modifier from ubsan_panic va

core: refactor ubsan panic code

Move panic invocation to common function. That makes entire code a
little bit more compact and removes duplications. Also remove
volatile modifier from ubsan_panic variable to make checkpatch
happy.

Signed-off-by: Aleksandr Iashchenko <alexhoppus111@gmail.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

45ef9dd027-Dec-2024 Aleksandr Iashchenko <alexhoppus111@gmail.com>

core: fix error in ubsan_builtin_unreachable naming

There is only __ubsan_handle_builtin_unreachable interface in gcc.
It was there starting from version 4.9.0.

Signed-off-by: Aleksandr Iashchenko

core: fix error in ubsan_builtin_unreachable naming

There is only __ubsan_handle_builtin_unreachable interface in gcc.
It was there starting from version 4.9.0.

Signed-off-by: Aleksandr Iashchenko <alexhoppus111@gmail.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

6966dabd27-Dec-2024 Aleksandr Iashchenko <alexhoppus111@gmail.com>

core: fix gcc warnings in ubsan

Latest gcc versions utilize void * as argument type for most of the
ubsan related handlers prototypes. Reproduced with gcc 11.2 .

Signed-off-by: Aleksandr Iashchenko

core: fix gcc warnings in ubsan

Latest gcc versions utilize void * as argument type for most of the
ubsan related handlers prototypes. Reproduced with gcc 11.2 .

Signed-off-by: Aleksandr Iashchenko <alexhoppus111@gmail.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

eb969f1826-Dec-2024 Aleksandr Iashchenko <alexhoppus111@gmail.com>

core: fix undefined reference to ubsan function

Add UBSan handler __ubsan_handle_invalid_builtin, which support
__builtin* functions validation. In some cases when __builtin functions
are used, und

core: fix undefined reference to ubsan function

Add UBSan handler __ubsan_handle_invalid_builtin, which support
__builtin* functions validation. In some cases when __builtin functions
are used, undefined behaviour might be triggered by invalid arguments.
E.g. passing 0 as the argument to __builtin_ctz or __builtin_clz
invokes undefined behavior and is diagnosed by UBSan.

Signed-off-by: Aleksandr Iashchenko <alexhoppus111@gmail.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

04e4697516-Dec-2024 Etienne Carriere <etienne.carriere@foss.st.com>

tree-wide: use ROUNDUP_DIV() where applicable

Use ROUNDUP_DIV() instead of ROUNDUP(..., size) / size where applicable.

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Reviewed-by: Je

tree-wide: use ROUNDUP_DIV() where applicable

Use ROUNDUP_DIV() instead of ROUNDUP(..., size) / size where applicable.

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...


/optee_os/.github/workflows/ci.yml
/optee_os/MAINTAINERS
/optee_os/core/arch/arm/kernel/stmm_sp.c
/optee_os/core/arch/arm/mm/core_mmu_v7.c
/optee_os/core/arch/arm/mm/mobj_ffa.c
/optee_os/core/arch/arm/mm/sp_mem.c
/optee_os/core/arch/arm/plat-d06/conf.mk
/optee_os/core/arch/arm/plat-sam/conf.mk
/optee_os/core/arch/arm/plat-telechips/conf.mk
/optee_os/core/arch/arm/plat-telechips/drivers/include/drivers/tcc_otp.h
/optee_os/core/arch/arm/plat-telechips/drivers/sub.mk
/optee_os/core/arch/arm/plat-telechips/drivers/tcc_otp.c
/optee_os/core/arch/arm/plat-telechips/link.mk
/optee_os/core/arch/arm/plat-telechips/main.c
/optee_os/core/arch/arm/plat-telechips/plat_tzc.c
/optee_os/core/arch/arm/plat-telechips/scripts/tcmktool.py
/optee_os/core/arch/arm/plat-telechips/sub.mk
/optee_os/core/arch/arm/plat-telechips/tcc805x/otprom.h
/optee_os/core/arch/arm/plat-telechips/tcc805x/platform_config.h
/optee_os/core/arch/arm/plat-versal2/conf.mk
/optee_os/core/arch/arm/plat-versal2/platform_config.h
/optee_os/core/arch/arm/plat-vexpress/conf.mk
/optee_os/core/drivers/clk/sam/clk-sam9x60-pll.c
/optee_os/core/drivers/crypto/caam/ae/caam_ae.c
/optee_os/core/drivers/crypto/caam/ae/caam_ae_ccm.c
/optee_os/core/drivers/crypto/caam/ae/caam_ae_gcm.c
/optee_os/core/drivers/crypto/caam/ae/local.h
/optee_os/core/drivers/crypto/caam/ae/sub.mk
/optee_os/core/drivers/crypto/caam/caam_ctrl.c
/optee_os/core/drivers/crypto/caam/caam_desc.c
/optee_os/core/drivers/crypto/caam/cipher/caam_cipher.c
/optee_os/core/drivers/crypto/caam/crypto.mk
/optee_os/core/drivers/crypto/caam/include/caam_ae.h
/optee_os/core/drivers/crypto/caam/include/caam_desc_ccb_defines.h
/optee_os/core/drivers/crypto/caam/include/caam_desc_defines.h
/optee_os/core/drivers/crypto/caam/include/caam_desc_helper.h
/optee_os/core/drivers/crypto/caam/include/caam_trace.h
/optee_os/core/drivers/crypto/caam/include/caam_utils_mem.h
/optee_os/core/drivers/crypto/caam/sub.mk
/optee_os/core/drivers/crypto/caam/utils/utils_mem.c
/optee_os/core/drivers/crypto/crypto_api/acipher/rsassa.c
/optee_os/core/drivers/crypto/hisilicon/crypto.mk
/optee_os/core/drivers/crypto/hisilicon/sec_pbkdf2.c
/optee_os/core/drivers/crypto/hisilicon/sec_pbkdf2.h
/optee_os/core/drivers/crypto/hisilicon/sub.mk
/optee_os/core/drivers/imx/dcp/dcp.c
/optee_os/core/drivers/microchip_pit.c
/optee_os/core/drivers/openedges_omc.c
/optee_os/core/drivers/sub.mk
/optee_os/core/include/drivers/openedges_omc.h
ldelf_loader.c
/optee_os/core/lib/libtomcrypt/mpi_desc.c
/optee_os/core/mm/fobj.c
/optee_os/core/tee/tee_ree_fs.c
/optee_os/core/tee/tee_rpmb_fs.c
/optee_os/lib/libutils/ext/include/util.h
/optee_os/ta/pkcs11/include/pkcs11_ta.h
/optee_os/ta/pkcs11/src/pkcs11_attributes.c
/optee_os/ta/pkcs11/src/processing_aes.c
/optee_os/ta/pkcs11/src/processing_rsa.c
/optee_os/ta/pkcs11/src/token_capabilities.c
76d6685e17-Dec-2024 Etienne Carriere <etienne.carriere@foss.st.com>

tree-wide: use power-of-2 rounding macros where applicable

Use ROUNDUP2(), ROUNDUP2_OVERFLOW(), ROUNDUP2_DIV() and ROUNDDOWN2() at
places where the rounding argument is a variable value and we want

tree-wide: use power-of-2 rounding macros where applicable

Use ROUNDUP2(), ROUNDUP2_OVERFLOW(), ROUNDUP2_DIV() and ROUNDDOWN2() at
places where the rounding argument is a variable value and we want to
leverage the implementation of these routines optimized for a
power-of-2 rounding argument.

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...


/optee_os/.github/workflows/ci.yml
/optee_os/core/arch/arm/dts/stm32mp157c-ed1.dts
/optee_os/core/arch/arm/dts/stm32mp15xx-dhcor-avenger96.dtsi
/optee_os/core/arch/arm/kernel/boot.c
/optee_os/core/arch/arm/kernel/entry_a32.S
/optee_os/core/arch/arm/kernel/entry_a64.S
/optee_os/core/arch/arm/kernel/kern.ld.S
/optee_os/core/arch/arm/kernel/virtualization.c
/optee_os/core/arch/arm/mm/core_mmu_v7.c
/optee_os/core/arch/arm/plat-stm32mp1/conf.mk
/optee_os/core/arch/arm/plat-stm32mp1/drivers/stm32mp1_pmic.c
/optee_os/core/arch/arm/plat-stm32mp1/main.c
/optee_os/core/arch/arm/plat-stm32mp1/scmi_server.c
/optee_os/core/arch/arm/plat-stm32mp1/stm32_util.h
/optee_os/core/arch/arm/plat-stm32mp1/sub.mk
/optee_os/core/arch/arm/plat-stm32mp2/main.c
/optee_os/core/arch/arm/plat-stm32mp2/stm32_util.h
/optee_os/core/arch/arm/plat-vexpress/conf.mk
/optee_os/core/drivers/clk/clk-stm32-core.c
/optee_os/core/drivers/crypto/caam/utils/utils_dmaobj.c
/optee_os/core/drivers/crypto/caam/utils/utils_mem.c
/optee_os/core/drivers/crypto/hisilicon/crypto.mk
/optee_os/core/drivers/crypto/hisilicon/hpre_rsa.c
/optee_os/core/drivers/crypto/hisilicon/hpre_rsa.h
/optee_os/core/drivers/crypto/hisilicon/sub.mk
/optee_os/core/drivers/crypto/stm32/stm32_cryp.c
/optee_os/core/drivers/firewall/stm32_etzpc.c
/optee_os/core/drivers/regulator/stm32mp13_regulator_iod.c
/optee_os/core/drivers/stm32_iwdg.c
/optee_os/core/drivers/stm32_rng.c
/optee_os/core/drivers/stm32_uart.c
/optee_os/core/include/drivers/stm32_uart.h
/optee_os/core/include/kernel/boot.h
/optee_os/core/include/kernel/virtualization.h
/optee_os/core/include/mm/core_mmu.h
tee_misc.c
transfer_list.c
/optee_os/core/mm/boot_mem.c
/optee_os/core/mm/core_mmu.c
/optee_os/core/mm/phys_mem.c
/optee_os/core/mm/sub.mk
/optee_os/core/mm/tee_mm.c
/optee_os/core/mm/vm.c
/optee_os/core/pta/secstor_ta_mgmt.c
/optee_os/ldelf/ta_elf.c
/optee_os/lib/libmbedtls/mbedtls/library/bignum.c
/optee_os/lib/libutee/tee_api.c
/optee_os/lib/libutee/tee_api_operations.c
/optee_os/lib/libutils/ext/include/util.h
/optee_os/mk/config.mk
/optee_os/ta/pkcs11/sub.mk

12345678910>>...20