History log of /optee_os/lib/ (Results 1 – 25 of 882)
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
e339d8f524-Sep-2025 Gatien Chevallier <gatien.chevallier@foss.st.com>

pta: stm32mp: add debug access PTA

Add the debug access PTA that is responsible of validating whether
a given debug profile is configured or not. This basically means that
the debug configuration sh

pta: stm32mp: add debug access PTA

Add the debug access PTA that is responsible of validating whether
a given debug profile is configured or not. This basically means that
the debug configuration should allow (at least!) access to the debug
peripherals requiring the debug profile being checked.

For now, as it is specific to BSEC, only embed the PTA if the BSEC support
is embedded as well.

Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.com>
Reviewed-by: Etienne Carriere <etienne.carriere@st.com>

show more ...

2949576e06-Aug-2025 Michael Tretter <m.tretter@pengutronix.de>

core: pta: add Rockchip secure boot PTA

The S_OTP area for the Rockchip secure boot RSA hash and status register
is accessible only from the secure world. Thus, secure boot must be
enabled from the

core: pta: add Rockchip secure boot PTA

The S_OTP area for the Rockchip secure boot RSA hash and status register
is accessible only from the secure world. Thus, secure boot must be
enabled from the secure world on these board.

The PTA implements 3 functions:

1. Ask the TA from the non-secure world about the current status and hash
of the hardware. This allows to inspect the current status of secure
boot on a specific device.

2. Write an RSA hash into the OTP fuses. It's the responsibility of the
user to calculate the hash and ensure that it matches the key, which
will be used to sign the images.

3. Actually lockdown the device by enabling secure boot. This is a
separate step to allow the user to verify the setup before
potentially bricking a device.

With these functions, a user may use a client running in the normal
world (for example in a boot loader or operating system) to enable
secure boot on a Rockchip device.

Implementing secure boot setup as an OP-TEE PTA has the advantage that
secure boot can be enabled at any time during the device setup instead
of during early boot. This allows a developer/user or additional scripts
to interact with the secure boot setup process.

The hash of the root key is accepted and reported as calculated by
sha256sum and internally converted to the correct byte order that needs
to be burned into the fuses.

Signed-off-by: Michael Tretter <m.tretter@pengutronix.de>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

1751321701-Sep-2025 Leo Chen <shf.chen@mediatek.com>

ftrace: dump ftrace after every ta_entry

This patch implements the feature to dump ftrace buffer to
tee_supplicant after every entry to the ta.
To implement the feature, this patch does some modific

ftrace: dump ftrace after every ta_entry

This patch implements the feature to dump ftrace buffer to
tee_supplicant after every entry to the ta.
To implement the feature, this patch does some modification to the
ftrace dumping process and add a new config CFG_FTRACE_DUMP_EVERY_ENTRY
to control this behavior.
This can reduce the chance of losing the ftrace data due to not
enough ftrace buffer and make debugging long-lived TA possible.

Signed-off-by: Leo Chen <shf.chen@mediatek.com>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Reviewed-by: Sumit Garg <sumit.garg@oss.qualcomm.com>

show more ...

2ff02bfa17-Dec-2025 Jerome Forissier <jerome.forissier@linaro.org>

libutee: make TEE_SetOperationKey2() panic if operation is NULL or not in initial state

The Internal Core API specification v1.3.1 has the following panic
conditions for TEE_SetOperationKey2(), same

libutee: make TEE_SetOperationKey2() panic if operation is NULL or not in initial state

The Internal Core API specification v1.3.1 has the following panic
conditions for TEE_SetOperationKey2(), same as v1.1:

- If operation is not a valid opened operation handle.
- If operation is not in initial state.

Therefore, it should call __GP11_TEE_SetOperationKey2() not the internal
function set_operation_key2(). Then operation is guaranteed to be
non-NULL and the test may be replaced by an assertion.

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

show more ...

854ea12216-Dec-2025 Jerome Forissier <jerome.forissier@linaro.org>

libutee: make TEE_SetOperationKey() panic if handle state is initialized

According to the TEE Internal Core API specification v1.3.1 section
6.2.6, TEE_SetOperationKey() should panic if the flag
TEE

libutee: make TEE_SetOperationKey() panic if handle state is initialized

According to the TEE Internal Core API specification v1.3.1 section
6.2.6, TEE_SetOperationKey() should panic if the flag
TEE_HANDLE_FLAG_INITIALIZED is set on the operation. Update
TEE_SetOperationKey() accordingly.

A NULL operation should cause a panic, too. Since this condition is
caught in both TEE_SetOperationKey() and __GP11_TEE_SetOperationKey(),
we can drop the NULL check in set_operation_key() and assert instead.

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

show more ...

764994e408-Dec-2025 Leo Chen <shf.chen@mediatek.com>

compiler.h: detect builtin arithmetic overflow support with __has_builtin

Using the __has_builtin macro to check if the compiler has builtin
arithmetic overflow function. This makes OP-TEE use more

compiler.h: detect builtin arithmetic overflow support with __has_builtin

Using the __has_builtin macro to check if the compiler has builtin
arithmetic overflow function. This makes OP-TEE use more efficient
code when compiled with clang.

Tested with clang 21.0.0 on arm64 platform, the generated assembly
is using the CPU flags to check overflow.

Signed-off-by: Leo Chen <shf.chen@mediatek.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>

show more ...

cf74bf0f08-Dec-2025 Leo Chen <shf.chen@mediatek.com>

libutils: add integer overflow multiplication from LLVM compiler-rt

Add integer overflow multiplication function __mulodi4() needed for
__builtin_mul_overflow() to work on a few platforms.

Selected

libutils: add integer overflow multiplication from LLVM compiler-rt

Add integer overflow multiplication function __mulodi4() needed for
__builtin_mul_overflow() to work on a few platforms.

Selected files are imported from the compiler-rt directory in LLVM
version 20.1.3, tag llvmorg-20.1, to lib/libutils/compiler-rt with no
local changes except for the sub.mk file.

Signed-off-by: Leo Chen <shf.chen@mediatek.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>

show more ...


/optee_os/.github/workflows/ci.yml
/optee_os/.github/workflows/notify.yml
/optee_os/CHANGELOG.md
/optee_os/MAINTAINERS
/optee_os/core/arch/arm/dts/stm32mp211.dtsi
/optee_os/core/arch/arm/dts/stm32mp231.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_private_arch.h
/optee_os/core/arch/arm/include/kernel/thread_spmc.h
/optee_os/core/arch/arm/include/optee_ffa.h
/optee_os/core/arch/arm/include/sm/optee_smc.h
/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/thread_spmc.c
/optee_os/core/arch/arm/mm/mobj_ffa.c
/optee_os/core/arch/arm/plat-imx/conf.mk
/optee_os/core/arch/arm/plat-imx/imx-common.c
/optee_os/core/arch/arm/plat-imx/imx-regs.h
/optee_os/core/arch/arm/plat-imx/imx.h
/optee_os/core/arch/arm/plat-imx/registers/imx943.h
/optee_os/core/arch/arm/plat-imx/registers/imx95.h
/optee_os/core/arch/arm/plat-qcom/conf.mk
/optee_os/core/arch/arm/plat-qcom/main.c
/optee_os/core/arch/arm/plat-qcom/platform_config.h
/optee_os/core/arch/arm/plat-qcom/sub.mk
/optee_os/core/arch/arm/plat-rockchip/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/arm/plat-rpi5/conf.mk
/optee_os/core/arch/arm/plat-rpi5/main.c
/optee_os/core/arch/arm/plat-rpi5/platform_config.h
/optee_os/core/arch/arm/plat-rpi5/sub.mk
/optee_os/core/arch/arm/plat-stm32mp1/drivers/stm32mp1_syscfg.c
/optee_os/core/arch/arm/plat-stm32mp1/stm32_util.h
/optee_os/core/arch/arm/plat-stm32mp2/conf.mk
/optee_os/core/arch/arm/plat-telechips/scripts/tcmktool.py
/optee_os/core/arch/arm/plat-ti/main.c
/optee_os/core/arch/arm/tee/entry_fast.c
/optee_os/core/arch/riscv/kernel/spinlock.S
/optee_os/core/drivers/crypto/ele/ele.c
/optee_os/core/drivers/imx/mu/imx_mu_8ulp_9x.c
/optee_os/core/drivers/imx/mu/sub.mk
/optee_os/core/drivers/qcom_geni_uart.c
/optee_os/core/drivers/regulator/regulator.c
/optee_os/core/drivers/regulator/regulator_dt.c
/optee_os/core/drivers/rockchip_otp.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/imx_mu.h
/optee_os/core/include/drivers/qcom_geni_uart.h
/optee_os/core/include/drivers/regulator.h
/optee_os/core/include/drivers/rockchip_otp.h
/optee_os/core/include/drivers/stm32_i2c.h
/optee_os/core/include/kernel/boot.h
/optee_os/core/include/mm/mobj.h
/optee_os/core/include/optee_msg.h
/optee_os/core/lib/libtomcrypt/src/pk/rsa/rsa_verify_hash.c
/optee_os/core/mm/core_mmu.c
/optee_os/core/mm/mobj.c
/optee_os/core/mm/mobj_dyn_shm.c
/optee_os/core/mm/vm.c
/optee_os/core/pta/device.c
/optee_os/core/tee/entry_std.c
/optee_os/core/tee/fs_htree.c
libutils/compiler-rt/lib/builtins/int_mulo_impl.inc
libutils/compiler-rt/lib/builtins/mulodi4.c
libutils/compiler-rt/lib/builtins/sub.mk
/optee_os/mk/config.mk
/optee_os/mk/macros.mk
/optee_os/scripts/ci-host-cleanup.sh
/optee_os/scripts/gen_ldelf_hex.py
/optee_os/scripts/notify_maintainers.py
/optee_os/ta/pkcs11/src/processing_rsa.c
/optee_os/ta/remoteproc/src/remoteproc_core.c
273a583e30-Sep-2025 Thomas Bourgoin <thomas.bourgoin@foss.st.com>

Squashed commit upgrading to mbedtls-3.6.4

Squash merging branch import/mbedtls-3.6.4

commit 43e97a8f0625 ("Import mbedtls-3.6.4")
commit 8ac83749d343 ("mbedtls: remove default include/mbedtls/conf

Squashed commit upgrading to mbedtls-3.6.4

Squash merging branch import/mbedtls-3.6.4

commit 43e97a8f0625 ("Import mbedtls-3.6.4")
commit 8ac83749d343 ("mbedtls: remove default include/mbedtls/config.h")
commit 89c0fc652535 ("mbedtls: configure mbedtls to reach for config")
commit 59c9730a19a8 ("libmbedtls: make mbedtls_mpi_mont*() available")
commit 20d408b354b4 ("libmbedtls: add mbedtls_mpi_init_mempool()")
commit ae519b65d8e1 ("libmedtls: mpi_miller_rabin: increase count limit")
commit eec216feead8 ("libmbedtls: add interfaces in mbedtls for context memory operation")
commit 436c9dec3733 ("libmbedtls: fix no CRT issue")
commit eb7fd40aa0c1 ("libmbedtls: add SM2 curve")
commit 6ca24312de58 ("libmbedtls: add fault mitigation in mbedtls_rsa_rsassa_pss_verify_ext()")
commit a7a355ebd993 ("libmbedtls: add fault mitigation in mbedtls_rsa_rsassa_pkcs1_v15_verify()")
commit 45083a9c2d7f ("libmbedtls: fix cipher_wrap.c for chacha20 and chachapoly")
commit a345e1bb1572 ("libmbedtls: fix cipher_wrap.c for NIST AES Key Wrap mode")
commit 015ba93f356d ("libmbedtls: allow inclusion of arm_neon.h")
commit 3c7a228496a7 ("libmbedtls: add CFG_CORE_UNSAFE_MODEXP and CFG_TA_MBEDTLS_UNSAFE_MODEXP")
commit c88a506a0f55 ("libmbedtls: use mempool_calloc() for temporary memory")
commit b22584209222 ("libmbedtls: fix build warning related to deprecated DTLS connect ID")
commit 4afc1eba8114 ("libmbedtls: sync with DTLS connect ID build fix")
commit 85329760d40b ("libmbedtls: fix compilation warning with GCC14")

Signed-off-by: Thomas Bourgoin <thomas.bourgoin@foss.st.com>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (vexpress-qemu_virt)
Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (vexpress-qemu_armv8a)

show more ...


/optee_os/.github/workflows/ci.yml
/optee_os/.github/workflows/stales.yml
/optee_os/MAINTAINERS
/optee_os/core/arch/arm/crypto/aes-gcm-ce.c
/optee_os/core/arch/arm/dts/stm32mp21-st-scmi-cfg.dtsi
/optee_os/core/arch/arm/dts/stm32mp23-st-scmi-cfg.dtsi
/optee_os/core/arch/arm/dts/stm32mp231.dtsi
/optee_os/core/arch/arm/dts/stm32mp233.dtsi
/optee_os/core/arch/arm/dts/stm32mp235.dtsi
/optee_os/core/arch/arm/dts/stm32mp235f-dk-ca35tdcid-rcc.dtsi
/optee_os/core/arch/arm/dts/stm32mp235f-dk-ca35tdcid-resmem.dtsi
/optee_os/core/arch/arm/dts/stm32mp235f-dk-ca35tdcid-rif.dtsi
/optee_os/core/arch/arm/dts/stm32mp235f-dk.dts
/optee_os/core/arch/arm/dts/stm32mp23xc.dtsi
/optee_os/core/arch/arm/dts/stm32mp23xf.dtsi
/optee_os/core/arch/arm/dts/stm32mp25-st-scmi-cfg.dtsi
/optee_os/core/arch/arm/dts/stm32mp251.dtsi
/optee_os/core/arch/arm/dts/stm32mp257f-dk.dts
/optee_os/core/arch/arm/plat-k3/conf.mk
/optee_os/core/arch/arm/plat-stm32mp2/conf.mk
/optee_os/core/crypto/aes-gcm.c
/optee_os/core/drivers/firewall/stm32_rifsc.c
/optee_os/core/drivers/gpio/gpio.c
/optee_os/core/drivers/regulator/regulator_fixed.c
/optee_os/core/drivers/regulator/regulator_gpio.c
/optee_os/core/drivers/stm32_gpio.c
/optee_os/core/drivers/stm32_tamp.c
/optee_os/core/include/drivers/gpio.h
/optee_os/core/include/drivers/stm32mp_dt_bindings.h
/optee_os/core/kernel/console.c
/optee_os/core/kernel/ree_fs_ta.c
/optee_os/core/pta/tests/dt_driver_test.c
libmbedtls/mbedtls/ChangeLog
libmbedtls/mbedtls/include/mbedtls/bignum.h
libmbedtls/mbedtls/include/mbedtls/build_info.h
libmbedtls/mbedtls/include/mbedtls/dhm.h
libmbedtls/mbedtls/include/mbedtls/ecdh.h
libmbedtls/mbedtls/include/mbedtls/ecdsa.h
libmbedtls/mbedtls/include/mbedtls/ecjpake.h
libmbedtls/mbedtls/include/mbedtls/ecp.h
libmbedtls/mbedtls/include/mbedtls/lms.h
libmbedtls/mbedtls/include/mbedtls/pk.h
libmbedtls/mbedtls/include/mbedtls/platform_util.h
libmbedtls/mbedtls/include/mbedtls/rsa.h
libmbedtls/mbedtls/include/mbedtls/ssl.h
libmbedtls/mbedtls/include/mbedtls/ssl_cookie.h
libmbedtls/mbedtls/include/mbedtls/ssl_ticket.h
libmbedtls/mbedtls/include/mbedtls/x509.h
libmbedtls/mbedtls/include/mbedtls/x509_crt.h
libmbedtls/mbedtls/include/mbedtls/x509_csr.h
libmbedtls/mbedtls/include/psa/crypto.h
libmbedtls/mbedtls/include/psa/crypto_extra.h
libmbedtls/mbedtls/library/aesni.c
libmbedtls/mbedtls/library/asn1write.c
libmbedtls/mbedtls/library/base64.c
libmbedtls/mbedtls/library/cipher.c
libmbedtls/mbedtls/library/cipher_invasive.h
libmbedtls/mbedtls/library/cipher_wrap.c
libmbedtls/mbedtls/library/cipher_wrap.h
libmbedtls/mbedtls/library/common.h
libmbedtls/mbedtls/library/lmots.c
libmbedtls/mbedtls/library/lms.c
libmbedtls/mbedtls/library/pem.c
libmbedtls/mbedtls/library/psa_crypto.c
libmbedtls/mbedtls/library/psa_crypto_mac.c
libmbedtls/mbedtls/library/psa_crypto_slot_management.c
libmbedtls/mbedtls/library/ssl_misc.h
libmbedtls/mbedtls/library/ssl_msg.c
libmbedtls/mbedtls/library/ssl_tls.c
libmbedtls/mbedtls/library/ssl_tls12_client.c
libmbedtls/mbedtls/library/ssl_tls12_server.c
libmbedtls/mbedtls/library/ssl_tls13_keys.c
libmbedtls/mbedtls/library/ssl_tls13_keys.h
libmbedtls/mbedtls/library/version_features.c
libmbedtls/mbedtls/library/x509_create.c
libmbedtls/mbedtls/library/x509write_crt.c
libmbedtls/mbedtls/library/x509write_csr.c
/optee_os/mk/config.mk
3eb0c44524-Jun-2025 Johan Korsnes <johan.korsnes@remarkable.no>

libutee: Fix handling of failed TA_CreateEntryPoint() in keep-alive TAs

Do not mark init as done if init fails. This is necessary to avoid
running a TA uninitialized. Also, add a new marker indicati

libutee: Fix handling of failed TA_CreateEntryPoint() in keep-alive TAs

Do not mark init as done if init fails. This is necessary to avoid
running a TA uninitialized. Also, add a new marker indicating if the
malloc pool and other runtime setup has been performed - this part
of the init must not be repeated.

This issue could cause a NULL pointer dereference in PKCS#11 TA if
the TA's init failed. F.ex., if `tee-supplicant` was unavailable, the
PKCS#11 TA's `TA_CreateEntryPoint()` would fail to init its tokens,
and an error value would be returned. This in itself is fine, but the
problem is that the init would be marked as done. Hence, for the next
session, the TA's `TA_CreateEntryPoint()` would be omitted during init.

Link: https://github.com/OP-TEE/optee_os/pull/7443
Signed-off-by: Johan Korsnes <johan.korsnes@remarkable.no>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

86d6bc2011-Jul-2025 Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>

libutils: disable word-at-a-time for str* functions with ASan

The optimized versions of str* functions perform word-aligned reads
that may go slightly past the actual string boundary. The out-of-bou

libutils: disable word-at-a-time for str* functions with ASan

The optimized versions of str* functions perform word-aligned reads
that may go slightly past the actual string boundary. The out-of-bound
read accesses doesn't look dangerous, because in this case buffer start
address is always word-size aligned.

Disable the optimized versions when CFG_CORE_SANITIZE_KADDRESS is enabled
to avoid ASan errors.

Signed-off-by: Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...


/optee_os/core/arch/arm/dts/stm32mp211.dtsi
/optee_os/core/arch/arm/dts/stm32mp215f-dk.dts
/optee_os/core/arch/arm/dts/stm32mp251.dtsi
/optee_os/core/arch/arm/dts/stm32mp257f-dk-ca35tdcid-rcc.dtsi
/optee_os/core/arch/arm/dts/stm32mp257f-dk-ca35tdcid-resmem.dtsi
/optee_os/core/arch/arm/dts/stm32mp257f-dk-ca35tdcid-rif.dtsi
/optee_os/core/arch/arm/dts/stm32mp257f-dk.dts
/optee_os/core/arch/arm/dts/stm32mp257f-ev1-ca35tdcid-rif.dtsi
/optee_os/core/arch/arm/dts/stm32mp257f-ev1.dts
/optee_os/core/arch/arm/plat-k3/conf.mk
/optee_os/core/arch/arm/plat-k3/drivers/dthev2.c
/optee_os/core/arch/arm/plat-k3/drivers/eip76d_trng.c
/optee_os/core/arch/arm/plat-k3/drivers/eip76d_trng.h
/optee_os/core/arch/arm/plat-k3/drivers/sa2ul.c
/optee_os/core/arch/arm/plat-k3/drivers/sub.mk
/optee_os/core/arch/arm/plat-k3/platform_config.h
/optee_os/core/arch/arm/plat-stm32mp1/conf.mk
/optee_os/core/arch/arm/plat-stm32mp1/main.c
/optee_os/core/arch/arm/plat-stm32mp1/stm32_util.h
/optee_os/core/arch/arm/plat-stm32mp2/conf.mk
/optee_os/core/arch/arm/plat-stm32mp2/main.c
/optee_os/core/arch/arm/plat-stm32mp2/stm32_sysconf.h
/optee_os/core/arch/arm/plat-stm32mp2/stm32_util.h
/optee_os/core/arch/arm/plat-versal2/conf.mk
/optee_os/core/arch/arm/plat-vexpress/conf.mk
/optee_os/core/drivers/clk/clk-stm32mp21.c
/optee_os/core/drivers/clk/clk-stm32mp25.c
/optee_os/core/drivers/ffa_console.c
/optee_os/core/drivers/stm32_gpio.c
/optee_os/core/drivers/stm32_iwdg.c
/optee_os/core/drivers/stm32_rtc.c
/optee_os/core/drivers/stm32_tamp.c
/optee_os/core/kernel/asan.c
/optee_os/core/kernel/panic.c
/optee_os/core/kernel/tee_ta_manager.c
/optee_os/core/pta/tests/misc.c
libutils/isoc/newlib/strchr.c
libutils/isoc/newlib/strcmp.c
libutils/isoc/newlib/strcpy.c
libutils/isoc/newlib/strlen.c
/optee_os/mk/config.mk
8e31dd5802-Sep-2024 Clément Le Goffic <clement.legoffic@foss.st.com>

core: pta: add alarm-related operations to RTC PTA

Add `set_alarm()`, `read_alarm()`, `enable_alarm()`, `wait_alarm()`,
`cancel_wait()` and `set_wake_alarm_status()` operations.
Also update RTC feat

core: pta: add alarm-related operations to RTC PTA

Add `set_alarm()`, `read_alarm()`, `enable_alarm()`, `wait_alarm()`,
`cancel_wait()` and `set_wake_alarm_status()` operations.
Also update RTC features to include alarm and wakeup alarm capabilities.

Signed-off-by: Clément Le Goffic <clement.legoffic@foss.st.com>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
Reviewed-by: Gatien Chevallier <gatien.chevallier@foss.st.com>

show more ...

0f3e22bd17-Jun-2025 Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>

libutils: drop redundant IS_ENABLED checks

The functions asan_tag_access() and asan_tag_heap_free() are
always defined. When CFG_CORE_SANITIZE_KADDRESS is disabled, they
are compiled as no-ops. Thus

libutils: drop redundant IS_ENABLED checks

The functions asan_tag_access() and asan_tag_heap_free() are
always defined. When CFG_CORE_SANITIZE_KADDRESS is disabled, they
are compiled as no-ops. Thus, the surrounding IS_ENABLED() checks
are unnecessary and removed.

Signed-off-by: Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

ffe211e017-Jun-2025 Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>

libutils: tag only actual allocated size in ASan heap tagging

Tag exactly the requested allocation size (hdr_size + requested_size)
instead of the rounded-up buffer size. This ensures that ASan does

libutils: tag only actual allocated size in ASan heap tagging

Tag exactly the requested allocation size (hdr_size + requested_size)
instead of the rounded-up buffer size. This ensures that ASan does not
mark extra padding as valid memory.

Signed-off-by: Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

7749dda208-Jun-2025 Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>

core, libutils: unpoison stack on longjmp for ASan

Adds support for unpoisoning the stack when performing longjmp,
to ensure correct ASan behavior.

When a longjmp unwinds the stack, parts of the st

core, libutils: unpoison stack on longjmp for ASan

Adds support for unpoisoning the stack when performing longjmp,
to ensure correct ASan behavior.

When a longjmp unwinds the stack, parts of the stack that were
poisoned during deeper calls may remain marked as inaccessible.
This can lead to false ASan reports after longjmp, as the new
frame reuses that memory.

To avoid this, a call to asan_handle_longjmp() is added to
setjmp_a64.S, which unpoisons the stack range between the current
SP and the old SP (saved during setjmp).

Signed-off-by: Aleksandr Iashchenko <aleksandr.iashchenko@linutronix.de>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>

show more ...

941a58d704-Apr-2025 Jens Wiklander <jens.wiklander@linaro.org>

Add optee.ta.instanceKeepCrashed property

Add the optee.ta.instanceKeepCrashed property to prevent a TA with
gpd.ta.instanceKeepAlive=true to be restarted. This prevents unexpected
resetting of the

Add optee.ta.instanceKeepCrashed property

Add the optee.ta.instanceKeepCrashed property to prevent a TA with
gpd.ta.instanceKeepAlive=true to be restarted. This prevents unexpected
resetting of the state of the TA.

Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Reviewed-by: Alex Lewontin <alex.lewontin@canonical.com>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...


/optee_os/.github/workflows/ci.yml
/optee_os/MAINTAINERS
/optee_os/core/arch/arm/dts/stm32mp131.dtsi
/optee_os/core/arch/arm/dts/stm32mp135f-dk.dts
/optee_os/core/arch/arm/dts/stm32mp151.dtsi
/optee_os/core/arch/arm/dts/stm32mp15xx-dkx.dtsi
/optee_os/core/arch/arm/dts/stm32mp21-st-scmi-cfg.dtsi
/optee_os/core/arch/arm/dts/stm32mp211.dtsi
/optee_os/core/arch/arm/dts/stm32mp213.dtsi
/optee_os/core/arch/arm/dts/stm32mp215.dtsi
/optee_os/core/arch/arm/dts/stm32mp215f-dk-ca35tdcid-rcc.dtsi
/optee_os/core/arch/arm/dts/stm32mp215f-dk-ca35tdcid-rif.dtsi
/optee_os/core/arch/arm/dts/stm32mp215f-dk.dts
/optee_os/core/arch/arm/dts/stm32mp21xc.dtsi
/optee_os/core/arch/arm/dts/stm32mp21xf.dtsi
/optee_os/core/arch/arm/dts/stm32mp25-st-scmi-cfg.dtsi
/optee_os/core/arch/arm/dts/stm32mp251.dtsi
/optee_os/core/arch/arm/dts/stm32mp257f-ev1-ca35tdcid-rif.dtsi
/optee_os/core/arch/arm/dts/stm32mp257f-ev1.dts
/optee_os/core/arch/arm/include/arm64.h
/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/generic_timer.c
/optee_os/core/arch/arm/kernel/kern.ld.S
/optee_os/core/arch/arm/plat-stm32mp1/conf.mk
/optee_os/core/arch/arm/plat-stm32mp1/drivers/stm32mp1_pwr.c
/optee_os/core/arch/arm/plat-stm32mp2/conf.mk
/optee_os/core/arch/arm/plat-stm32mp2/drivers/stm32mp25_syscfg.c
/optee_os/core/arch/arm/plat-stm32mp2/stm32_sysconf.h
/optee_os/core/arch/arm/plat-versal2/conf.mk
/optee_os/core/arch/arm/plat-vexpress/main.c
/optee_os/core/arch/arm/plat-vexpress/platform_config.h
/optee_os/core/arch/riscv/include/kernel/riscv_elf.h
/optee_os/core/arch/riscv/include/kernel/thread_private_arch.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/kern.ld.S
/optee_os/core/arch/riscv/kernel/thread_arch.c
/optee_os/core/arch/riscv/mm/core_mmu_arch.c
/optee_os/core/arch/riscv/plat-sifive/conf.mk
/optee_os/core/arch/riscv/plat-virt/conf.mk
/optee_os/core/core.mk
/optee_os/core/drivers/amd/gpio_common.c
/optee_os/core/drivers/amd/gpio_private.h
/optee_os/core/drivers/amd/ps_gpio_driver.c
/optee_os/core/drivers/amd/sub.mk
/optee_os/core/drivers/clk/clk-stm32mp21.c
/optee_os/core/drivers/clk/clk-stm32mp25.c
/optee_os/core/drivers/clk/sub.mk
/optee_os/core/drivers/ffa_console.c
/optee_os/core/drivers/firewall/stm32_rifsc.c
/optee_os/core/drivers/hfic.c
/optee_os/core/drivers/rstctrl/stm32mp21_rstctrl.c
/optee_os/core/drivers/rstctrl/stm32mp25_rstctrl.c
/optee_os/core/drivers/rstctrl/sub.mk
/optee_os/core/drivers/stm32_exti.c
/optee_os/core/drivers/stm32_gpio.c
/optee_os/core/drivers/stm32_omm.c
/optee_os/core/drivers/stm32_rtc.c
/optee_os/core/drivers/stm32_tamp.c
/optee_os/core/drivers/sub.mk
/optee_os/core/include/drivers/stm32_gpio.h
/optee_os/core/include/drivers/stm32_rtc.h
/optee_os/core/include/drivers/stm32mp21_rcc.h
/optee_os/core/include/drivers/stm32mp_dt_bindings.h
/optee_os/core/include/dt-bindings/clock/st,stm32mp21-rcc.h
/optee_os/core/include/dt-bindings/clock/stm32mp21-clksrc.h
/optee_os/core/include/dt-bindings/firewall/stm32mp21-rifsc.h
/optee_os/core/include/dt-bindings/firewall/stm32mp25-rifsc.h
/optee_os/core/include/dt-bindings/reset/st,stm32mp21-rcc.h
/optee_os/core/include/dt-bindings/scmi/scmi-clock.h
/optee_os/core/include/dt-bindings/tamper/st,stm32-tamp.h
/optee_os/core/include/dt-bindings/tamper/st,stm32mp13-tamp.h
/optee_os/core/include/dt-bindings/tamper/st,stm32mp21-tamp.h
/optee_os/core/include/dt-bindings/tamper/st,stm32mp25-tamp.h
/optee_os/core/include/kernel/boot.h
/optee_os/core/include/kernel/dt_driver.h
/optee_os/core/include/kernel/interrupt.h
/optee_os/core/include/kernel/thread.h
/optee_os/core/kernel/boot.c
/optee_os/core/kernel/ree_fs_ta.c
/optee_os/core/kernel/tee_ta_manager.c
/optee_os/core/kernel/thread.c
/optee_os/core/kernel/user_ta.c
/optee_os/core/lib/scmi-server/conf-optee-stm32mp1.mk
/optee_os/core/lib/scmi-server/conf-optee-stm32mp2.mk
/optee_os/core/lib/scmi-server/conf.mk
/optee_os/core/lib/scmi-server/include/scmi_agent_configuration.h
/optee_os/core/lib/scmi-server/include/scmi_clock_consumer.h
/optee_os/core/lib/scmi-server/include/scmi_reset_consumer.h
/optee_os/core/lib/scmi-server/scmi_clock_consumer.c
/optee_os/core/lib/scmi-server/scmi_reset_consumer.c
/optee_os/core/lib/scmi-server/scmi_server.c
/optee_os/core/lib/scmi-server/scmi_server_scpfw.c
/optee_os/core/lib/scmi-server/sub.mk
/optee_os/core/mm/boot_mem.c
/optee_os/core/mm/core_mmu.c
libutee/include/user_ta_header.h
/optee_os/mk/config.mk
/optee_os/ta/user_ta_header.c
98dd4c7007-Mar-2025 Jerome Forissier <jerome.forissier@linaro.org>

libmbedtls: fix compilation warning with GCC14 (2)

Cherry-picking commit 7505c3588f44 ("libmbedtls: fix compilation warning
with GCC14") which was lost in commit c3deb3d6f3b1 ("Squashed commit
upgra

libmbedtls: fix compilation warning with GCC14 (2)

Cherry-picking commit 7505c3588f44 ("libmbedtls: fix compilation warning
with GCC14") which was lost in commit c3deb3d6f3b1 ("Squashed commit
upgrading to mbedtls-3.6.3"). It should have been pushed onto the
import/mbedtls-3.6.2 branch when it was accepted in master but that
didn't happen and therefore it was unfortunately left aside when
upgrading. This time it has been applied to import/mbedtls-3.6.3 [1] so
it will hopefully not be forgotten in the next upgrade.

Link: https://github.com/OP-TEE/optee_os/commit/b526c146f87 [1]
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...


/optee_os/.github/workflows/ci.yml
/optee_os/core/arch/arm/arm.mk
/optee_os/core/arch/arm/include/kernel/secure_partition.h
/optee_os/core/arch/arm/include/kernel/thread_arch.h
/optee_os/core/arch/arm/include/kernel/thread_private_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/entry_a32.S
/optee_os/core/arch/arm/kernel/entry_a64.S
/optee_os/core/arch/arm/kernel/secure_partition.c
/optee_os/core/arch/arm/kernel/thread.c
/optee_os/core/arch/arm/kernel/thread_a64.S
/optee_os/core/arch/arm/kernel/thread_spmc.c
/optee_os/core/arch/arm/kernel/virtualization.c
/optee_os/core/arch/arm/mm/core_mmu.c
/optee_os/core/arch/arm/mm/core_mmu_lpae.c
/optee_os/core/arch/arm/plat-k3/drivers/ti_sci.c
/optee_os/core/arch/arm/plat-k3/drivers/ti_sci.h
/optee_os/core/arch/arm/plat-k3/drivers/ti_sci_protocol.h
/optee_os/core/arch/arm/plat-rockchip/conf.mk
/optee_os/core/arch/arm/plat-rockchip/main.c
/optee_os/core/arch/arm/plat-rockchip/platform_config.h
/optee_os/core/arch/arm/plat-stm32mp1/main.c
/optee_os/core/arch/arm/plat-ti/a9_plat_init.S
/optee_os/core/arch/arm/sm/pm_a32.S
/optee_os/core/arch/arm/tests/ffa_lsp.c
/optee_os/core/arch/arm/tests/sub.mk
/optee_os/core/arch/riscv/include/mm/core_mmu_arch.h
/optee_os/core/arch/riscv/kernel/boot.c
/optee_os/core/arch/riscv/kernel/entry.S
/optee_os/core/arch/riscv/kernel/thread_rv.S
/optee_os/core/arch/riscv/mm/core_mmu_arch.c
/optee_os/core/crypto/signed_hdr.c
/optee_os/core/drivers/crypto/caam/include/caam_ae.h
/optee_os/core/drivers/firewall/stm32_rifsc.c
/optee_os/core/drivers/firewall/stm32_risab.c
/optee_os/core/drivers/stm32_hpdma.c
/optee_os/core/drivers/stm32_iwdg.c
/optee_os/core/drivers/wdt/watchdog_sm.c
/optee_os/core/include/drivers/wdt.h
/optee_os/core/include/kernel/thread.h
/optee_os/core/include/kernel/thread_private.h
/optee_os/core/include/mm/core_mmu.h
/optee_os/core/kernel/thread.c
/optee_os/core/mm/core_mmu.c
/optee_os/core/pta/tests/misc.c
/optee_os/keys/default.pem
libmbedtls/mbedtls/library/common.h
/optee_os/mk/clang.mk
/optee_os/mk/config.mk
76d920d325-Mar-2025 Raymond Mao <raymond.mao@linaro.org>

core: pta: add self tests for transfer list

Add self tests for transfer list.
Adapt CFG_TRANSFER_LIST with its dependencies and add
CFG_TRANSFER_LIST_TEST.

Signed-off-by: Raymond Mao <raymond.mao@l

core: pta: add self tests for transfer list

Add self tests for transfer list.
Adapt CFG_TRANSFER_LIST with its dependencies and add
CFG_TRANSFER_LIST_TEST.

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

show more ...

3a0fa64628-Apr-2025 Jens Wiklander <jens.wiklander@linaro.org>

libmbedtls: config: re-enable long long divisions

This reverts commit d3ec4328a070 ("libmbedtls: config: disable long long
divisions") to address performance regressions introduced by that
commit. T

libmbedtls: config: re-enable long long divisions

This reverts commit d3ec4328a070 ("libmbedtls: config: disable long long
divisions") to address performance regressions introduced by that
commit. The commit can be reverted now that __udivti3() needed by the
unsigned long long divisions is available again.

Link: https://github.com/OP-TEE/optee_os/pull/7359
Link: https://github.com/OP-TEE/optee_os/issues/7374
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>

show more ...

48952fd428-Apr-2025 Jens Wiklander <jens.wiklander@linaro.org>

libutils: add division routines from LLVM compiler-rt

Add division routines needed to provide __udivti3() needed for long long
divisions in mbedtls.

Selected files are imported from the compiler-rt

libutils: add division routines from LLVM compiler-rt

Add division routines needed to provide __udivti3() needed for long long
divisions in mbedtls.

Selected files are imported from the compiler-rt directory in LLVM
version 20.1.3, tag llvmorg-20.1, to lib/libutils/compiler-rt with no
local changes except for the added sub.mk files.

Link: https://github.com/OP-TEE/optee_os/pull/7359
Link: https://github.com/OP-TEE/optee_os/issues/7374
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-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 ...

c3deb3d628-Mar-2025 Etienne Carriere <etienne.carriere@foss.st.com>

Squashed commit upgrading to mbedtls-3.6.3

Squash merging branch import/mbedtls-3.6.3.

83dd409f0591 ("Import mbedtls-3.6.3")
aa3df5be08de ("mbedtls: remove default include/mbedtls/config.h")
10d3d4

Squashed commit upgrading to mbedtls-3.6.3

Squash merging branch import/mbedtls-3.6.3.

83dd409f0591 ("Import mbedtls-3.6.3")
aa3df5be08de ("mbedtls: remove default include/mbedtls/config.h")
10d3d445f46f ("mbedtls: configure mbedtls to reach for config")
03fd7670bc8e ("libmbedtls: make mbedtls_mpi_mont*() available")
134b0c7c7577 ("libmbedtls: add mbedtls_mpi_init_mempool()")
84a14c2a9e2a ("libmedtls: mpi_miller_rabin: increase count limit")
5e39a372b06e ("libmbedtls: add interfaces in mbedtls for context memory operation")
d5f89f104e2f ("libmbedtls: fix no CRT issue")
7efbd8164a57 ("libmbedtls: add SM2 curve")
ef671e650a67 ("libmbedtls: add fault mitigation in mbedtls_rsa_rsassa_pss_verify_ext()")
dd7fe0899a74 ("libmbedtls: add fault mitigation in mbedtls_rsa_rsassa_pkcs1_v15_verify()")
2ff56f350a3e ("libmbedtls: fix cipher_wrap.c for chacha20 and chachapoly")
63b52087554b ("libmbedtls: fix cipher_wrap.c for NIST AES Key Wrap mode")
1a615e16f58a ("libmbedtls: allow inclusion of arm_neon.h")
3de987540e82 ("libmbedtls: add CFG_CORE_UNSAFE_MODEXP and CFG_TA_MBEDTLS_UNSAFE_MODEXP")
878995ea5dee ("libmbedtls: use mempool_calloc() for temporary memory")
0a7b758bcd12 ("libmbedtls: fix build warning related to deprecated DTLS connect ID")
e7332889098e ("libmbedtls: libmbedtls: sync with DTLS connect ID build fix")

Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (vexpress-qemu_virt)
Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (vexpress-qemu_armv8a)

show more ...


/optee_os/core/mm/core_mmu.c
libmbedtls/mbedtls/ChangeLog
libmbedtls/mbedtls/SECURITY.md
libmbedtls/mbedtls/include/mbedtls/build_info.h
libmbedtls/mbedtls/include/mbedtls/check_config.h
libmbedtls/mbedtls/include/mbedtls/config_adjust_legacy_crypto.h
libmbedtls/mbedtls/include/mbedtls/config_adjust_legacy_from_psa.h
libmbedtls/mbedtls/include/mbedtls/config_adjust_psa_superset_legacy.h
libmbedtls/mbedtls/include/mbedtls/debug.h
libmbedtls/mbedtls/include/mbedtls/entropy.h
libmbedtls/mbedtls/include/mbedtls/error.h
libmbedtls/mbedtls/include/mbedtls/gcm.h
libmbedtls/mbedtls/include/mbedtls/net_sockets.h
libmbedtls/mbedtls/include/mbedtls/psa_util.h
libmbedtls/mbedtls/include/mbedtls/ssl.h
libmbedtls/mbedtls/include/mbedtls/threading.h
libmbedtls/mbedtls/include/psa/crypto_config.h
libmbedtls/mbedtls/include/psa/crypto_extra.h
libmbedtls/mbedtls/include/psa/crypto_sizes.h
libmbedtls/mbedtls/library/aesni.c
libmbedtls/mbedtls/library/bignum_core.c
libmbedtls/mbedtls/library/bignum_core.h
libmbedtls/mbedtls/library/bignum_core_invasive.h
libmbedtls/mbedtls/library/ccm.c
libmbedtls/mbedtls/library/common.h
libmbedtls/mbedtls/library/constant_time_impl.h
libmbedtls/mbedtls/library/ecp.c
libmbedtls/mbedtls/library/error.c
libmbedtls/mbedtls/library/net_sockets.c
libmbedtls/mbedtls/library/pk.c
libmbedtls/mbedtls/library/psa_crypto.c
libmbedtls/mbedtls/library/psa_crypto_cipher.c
libmbedtls/mbedtls/library/psa_crypto_core.h
libmbedtls/mbedtls/library/psa_crypto_driver_wrappers.h
libmbedtls/mbedtls/library/psa_crypto_ecp.c
libmbedtls/mbedtls/library/psa_crypto_slot_management.c
libmbedtls/mbedtls/library/psa_crypto_storage.h
libmbedtls/mbedtls/library/psa_util.c
libmbedtls/mbedtls/library/ssl_client.c
libmbedtls/mbedtls/library/ssl_debug_helpers_generated.c
libmbedtls/mbedtls/library/ssl_misc.h
libmbedtls/mbedtls/library/ssl_msg.c
libmbedtls/mbedtls/library/ssl_tls.c
libmbedtls/mbedtls/library/ssl_tls12_client.c
libmbedtls/mbedtls/library/ssl_tls12_server.c
libmbedtls/mbedtls/library/ssl_tls13_client.c
libmbedtls/mbedtls/library/ssl_tls13_server.c
libmbedtls/mbedtls/library/threading.c
libmbedtls/mbedtls/library/version_features.c
682ff6eb23-Feb-2025 Jens Wiklander <jens.wiklander@linaro.org>

pta: stats: add field for fragmentation metric

Add the field free2sum to struct pta_stats_alloc to enable xtest to
calculate fragmenation metric for the heap.

Signed-off-by: Jens Wiklander <jens.wi

pta: stats: add field for fragmentation metric

Add the field free2sum to struct pta_stats_alloc to enable xtest to
calculate fragmenation metric for the heap.

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 ...

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

libutils: bget: add free2_sum to struct bpoolset

Add the field free2_sum to struct bpoolset to be used to calculate a
metric for heap fragmentation. The value is calculated and kept up to
date when

libutils: bget: add free2_sum to struct bpoolset

Add the field free2_sum to struct bpoolset to be used to calculate a
metric for heap fragmentation. The value is calculated and kept up to
date when compiled with statistics (CFG_WITH_STATS=y) enabled. See
xtest and [1] for how to use the new field.

Link: https://asawicki.info/news_1757_a_metric_for_memory_fragmentation [1]
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>

show more ...

07603a1f01-Apr-2025 Jens Wiklander <jens.wiklander@linaro.org>

libutils: avoid unneeded zero init in realloc()

In raw_malloc_flags(), remove the special case for user space where
memory is always zero initialized regardless of MAF_ZERO_INIT. This
removes a case

libutils: avoid unneeded zero init in realloc()

In raw_malloc_flags(), remove the special case for user space where
memory is always zero initialized regardless of MAF_ZERO_INIT. This
removes a case of unneeded zero init for realloc().

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 ...

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

libutee: fix __utee_tcb_init()

Replace realloc() calls with calls to malloc_flags() to make sure that
newly allocated memory is zero initialized.

Fixes: 9d224046e710 ("ldelf, libutee: add minimal T

libutee: fix __utee_tcb_init()

Replace realloc() calls with calls to malloc_flags() to make sure that
newly allocated memory is zero initialized.

Fixes: 9d224046e710 ("ldelf, libutee: add minimal Thread Local Storage support")
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 ...

12345678910>>...36