| e419bc7f | 16-Dec-2024 |
Gatien Chevallier <gatien.chevallier@foss.st.com> |
drivers: stm32_rtc: introduce STM32 RTC driver
Driver interface allows to read date&time from RTC device, generate RTC timestamps and compute time delta between RTC date & time values.
The RTC is a
drivers: stm32_rtc: introduce STM32 RTC driver
Driver interface allows to read date&time from RTC device, generate RTC timestamps and compute time delta between RTC date & time values.
The RTC is a firewall-aware peripheral. It means that the RTC driver is in charge of configuring its own firewall restrictions and that the RTC has dedicated firewall configuration registers.
The RTC provide APIs with time structure compatible with linux kernel driver.
Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Signed-off-by: Clément Le Goffic <clement.legoffic@foss.st.com> Signed-off-by: Lionel Debieve <lionel.debieve@foss.st.com> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 0074d941 | 09-Jan-2025 |
Gatien Chevallier <gatien.chevallier@foss.st.com> |
drivers: atmel_rtc: fix and update RTC ranges
Use RTC_TIME() helper macro to initialize Atmel RTC ranges and fix its month and weekday values. Also add the milliseconds field even though it's not us
drivers: atmel_rtc: fix and update RTC ranges
Use RTC_TIME() helper macro to initialize Atmel RTC ranges and fix its month and weekday values. Also add the milliseconds field even though it's not used.
Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 73aafcc9 | 08-Jan-2025 |
Gatien Chevallier <gatien.chevallier@foss.st.com> |
drivers: rtc: check data consistency in rtc_set_time()
Ensure that arguments passed to rtc_set_time() are coherent to defined RTC range and Gregorian calendar values.
Signed-off-by: Gatien Chevalli
drivers: rtc: check data consistency in rtc_set_time()
Ensure that arguments passed to rtc_set_time() are coherent to defined RTC range and Gregorian calendar values.
Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| a83e616e | 08-Jan-2025 |
Gatien Chevallier <gatien.chevallier@foss.st.com> |
drivers: rtc: add RTC_TIME() helper macro
Add RTC_TIME() helper macro that allows to initialize all fields of a struct optee_rtc_time.
Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.co
drivers: rtc: add RTC_TIME() helper macro
Add RTC_TIME() helper macro that allows to initialize all fields of a struct optee_rtc_time.
Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 26899ca2 | 05-Feb-2024 |
Clément Le Goffic <clement.legoffic@foss.st.com> |
drivers: rtc: add RTC functions and millisecond field
Add a millisecond field in the optee_rtc_time structure.
Add different APIs to manipulate optee_rtc_time structures: rtc_is_a_leap_year(): Dete
drivers: rtc: add RTC functions and millisecond field
Add a millisecond field in the optee_rtc_time structure.
Add different APIs to manipulate optee_rtc_time structures: rtc_is_a_leap_year(): Detects if the given year is a leap year rtc_get_month_days(): Returns the number of day in the given month rtc_timecmp(): Compare two time captures rtc_diff_calendar_ms(): Returns the difference in milliseconds between two time captures rtc_diff_calendar_tick(): Returns the difference in number of ticks between two time captures
Signed-off-by: Clément Le Goffic <clement.legoffic@foss.st.com> Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| bd64a3f4 | 06-Sep-2023 |
Gabriel Fernandez <gabriel.fernandez@foss.st.com> |
dt-bindings: stm32: fix CLKSRC for RTC in stm32mp13 clock bindings
Bad copy/paste, use MUX ID to configure the clock source of RTC and not the clock ID.
Signed-off-by: Gabriel Fernandez <gabriel.fe
dt-bindings: stm32: fix CLKSRC for RTC in stm32mp13 clock bindings
Bad copy/paste, use MUX ID to configure the clock source of RTC and not the clock ID.
Signed-off-by: Gabriel Fernandez <gabriel.fernandez@foss.st.com> Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com> Fixes: 19a4632e0f17 ("dt-bindings: stm32: add stm32mp13 clock and reset bindings")
show more ...
|
| 4b6058e4 | 03-Nov-2021 |
Gabriel Fernandez <gabriel.fernandez@foss.st.com> |
clk: fix clk_get_rate() when parent clock rate was changed
clk_get_rate() returns a cached value of the clock rate.
If the rate of the parent clock changed, then the rate is not synchronized. Chan
clk: fix clk_get_rate() when parent clock rate was changed
clk_get_rate() returns a cached value of the clock rate.
If the rate of the parent clock changed, then the rate is not synchronized. Change the function to compute all clock parents' rates and return the synchronized value.
Signed-off-by: Gabriel Fernandez <gabriel.fernandez@foss.st.com> Signed-off-by: Gatien Chevallier <gatien.chevallier@foss.st.com> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com> Fixes: 2305544b3b9b ("drivers: clk: add generic clock framework")
show more ...
|
| 9b941cd7 | 23-Jan-2025 |
Sungbae Yoo <sungbaey@nvidia.com> |
core: mmu: fix memory regions found from ff-a manifest
Fix the 5th parameter of add_phys_mem() in collect_device_mem_ranges() that has to be the size of memory region and not the end address of the
core: mmu: fix memory regions found from ff-a manifest
Fix the 5th parameter of add_phys_mem() in collect_device_mem_ranges() that has to be the size of memory region and not the end address of the region.
Fixes: b8ef8d0b6ff4 ("core: mm: introduce struct memory_map") Signed-off-by: Sungbae Yoo <sungbaey@nvidia.com> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| edc125c5 | 20-Jan-2025 |
Jens Wiklander <jens.wiklander@linaro.org> |
libutils: add malloc_flags() and free_flags()
Add malloc_flags() and free_flags() for generic and flexible memory allocations based on a passed flags field.
Signed-off-by: Jens Wiklander <jens.wikl
libutils: add malloc_flags() and free_flags()
Add malloc_flags() and free_flags() for generic and flexible memory allocations based on a passed flags field.
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 ...
|
| 695be9d6 | 20-Jan-2025 |
Jens Wiklander <jens.wiklander@linaro.org> |
libutils: refactor the MDBG malloc functions
Replace the MDBG malloc functions and macros with a new function __mdbg_alloc() handling all the memory allocations similar to mem_alloc(). The old MDBG
libutils: refactor the MDBG malloc functions
Replace the MDBG malloc functions and macros with a new function __mdbg_alloc() handling all the memory allocations similar to mem_alloc(). The old MDBG macros are replace by new macros calling __mdbg_alloc().
mem_alloc(), mem_alloc_unlocked(), and mem_free() are updated to handle configuration with and without MDBG, removing the all the ENABLE_MDBG ifdefs in the C file.
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 ...
|
| 46452164 | 20-Jan-2025 |
Jens Wiklander <jens.wiklander@linaro.org> |
libutils: refactor the nexus malloc functions
Refactor the malloc functions operating on the nexus heap as simple wrappers around the recently added internal function mem_alloc().
Signed-off-by: Je
libutils: refactor the nexus malloc functions
Refactor the malloc functions operating on the nexus heap as simple wrappers around the recently added internal function mem_alloc().
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 ...
|
| 07c190fb | 20-Jan-2025 |
Jens Wiklander <jens.wiklander@linaro.org> |
libutils: refactor the default malloc functions
Refactor the malloc functions operating on the default heap as simple wrappers around the new internal function mem_alloc() similar to the recently ad
libutils: refactor the default malloc functions
Refactor the malloc functions operating on the default heap as simple wrappers around the new internal function mem_alloc() similar to the recently added raw_mem_alloc().
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 ...
|
| 46493333 | 20-Jan-2025 |
Jens Wiklander <jens.wiklander@linaro.org> |
libutils: refactor raw malloc functions
Refactor the raw malloc functions as simple wrappers around the new internal function raw_mem_alloc(). raw_mem_alloc() takes a flags field to control whether
libutils: refactor raw malloc functions
Refactor the raw malloc functions as simple wrappers around the new internal function raw_mem_alloc(). raw_mem_alloc() takes a flags field to control whether the allocated buffer should be cleared before it's returned.
The flags are defined in <malloc.h> since they will be needed there in later patches.
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 ...
|
| f3d9bdee | 20-Jan-2025 |
Jens Wiklander <jens.wiklander@linaro.org> |
libutils: add malloc_flags.h
Add malloc_flags.h defining flags to control how buffers are allocated. The flags will be used in later patches.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.or
libutils: add malloc_flags.h
Add malloc_flags.h defining flags to control how buffers are allocated. The flags will be used in later patches.
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 ...
|
| 0ed372c6 | 15-Jan-2025 |
Jerome Forissier <jerome.forissier@linaro.org> |
core: pta: device: fix enumeration for PTA_CMD_GET_DEVICES_SUPP
TAs which depend on TEE_STORAGE_PRIVATE do need the TEE supplicant if REE FS is disabled (in which case secure storage can only be RPM
core: pta: device: fix enumeration for PTA_CMD_GET_DEVICES_SUPP
TAs which depend on TEE_STORAGE_PRIVATE do need the TEE supplicant if REE FS is disabled (in which case secure storage can only be RPMB) and RPMB is not routed via the kernel.
Fixes: a96033ca7bee ("core: add flag to enumerate TAs when secure storage is ready") Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com> Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 10cc5912 | 21-Jun-2024 |
Runyang Chen <runyang.chen@mediatek.com> |
drivers: gic: Dynamically assign interrupts to non-secure world
Add gic_spi_release_to_ns() API function in GIC driver to release an interrupt to Non secure settings. This functionality is essential
drivers: gic: Dynamically assign interrupts to non-secure world
Add gic_spi_release_to_ns() API function in GIC driver to release an interrupt to Non secure settings. This functionality is essential for scenarios where a specific interrupt needs to be dynamically set to either Group 1 Secure (G1S) or Group 1 Non-Secure (G1NS) at different times.
Signed-off-by: Runyang Chen <runyang.chen@mediatek.com> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com> Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| bef959c8 | 02-Dec-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: arm: ffa: switch to FF-A version 1.2
Update FF-A minor version from 1 to 2. spmc_exchange_version() is updated to take the new version into account when negotiating with a caller.
Configurati
core: arm: ffa: switch to FF-A version 1.2
Update FF-A minor version from 1 to 2. spmc_exchange_version() is updated to take the new version into account when negotiating with a caller.
Configurations with SPMC at EL3 and S-EL2 supplies an SP manifest when booting OP-TEE, read the FF-A version to use from the manifest instead of using the hard coded version.
The configuration with SPMC at S-EL1, part of OP-TEE, keep the FF-A version at version 1.1 when configured with CFG_NS_VIRTUALIZATION=y as workaround to remain compatible with Xen. This workaround will not be needed after the next Xen release and can be removed then.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| ddec5d6b | 04-Dec-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: ffa: update FFA_CONSOLE_LOG_64 for v1.2 SPs
Update FFA_CONSOLE_LOG_64 to handle the ABI extension for FF-A v1.2. The extended ABI is only used for FF-A v1.2 SPs .
Signed-off-by: Jens Wiklande
core: ffa: update FFA_CONSOLE_LOG_64 for v1.2 SPs
Update FFA_CONSOLE_LOG_64 to handle the ABI extension for FF-A v1.2. The extended ABI is only used for FF-A v1.2 SPs .
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 750a54aa | 03-Dec-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: arm: ffa: add FF-A version 1.2 defines
Add defines for SMC IDs introduced with FF-A version 1.2.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Etienne Carriere <etienne.
core: arm: ffa: add FF-A version 1.2 defines
Add defines for SMC IDs introduced with FF-A version 1.2.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| d17db2af | 03-Dec-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: arm: ffa: use SMC Calling Convention 1.2
Add struct thread_smc_1_2_regs as a replacement for struct thread_smc_args when dealing with FF-A SMCs. struct thread_smc_1_2_regs covers the registers
core: arm: ffa: use SMC Calling Convention 1.2
Add struct thread_smc_1_2_regs as a replacement for struct thread_smc_args when dealing with FF-A SMCs. struct thread_smc_1_2_regs covers the registers x0-x17 to support passing arguments and results according to SMC Calling Convention (SMCCC) version 1.2.
The difference is that before this change x8-x17 couldn't be used as argument nor result and the content was preserved. With this patch are x8-x17 returned as zeroes. New FF-A SMCs can take and return values in the full range x0-x17.
64-bit SMCCC version 1.1 and earlier specified x4-x17 as unpredictable or scratch registers. FF-A has specified x0-x7 as argument and result registers, regardless of SMCCC. This has changed with SMCCC version 1.2 where the two standards harmonize on this.
struct thread_smc_1_2_regs is added in a 32-bit version for compatibility, but it only covers r0-r7.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 7d0f479e | 16-Sep-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: arm: mm: dynamic allocation of v7 translation tables
With CFG_DYN_CONFIG enabled allocate translation tables using the boot_mem_*() functions. Static allocation from global variables is still
core: arm: mm: dynamic allocation of v7 translation tables
With CFG_DYN_CONFIG enabled allocate translation tables using the boot_mem_*() functions. Static allocation from global variables is still used with CFG_DYN_CONFIG disabled.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| a28e4a0f | 09-Jul-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: arm: mm: dynamic allocation of LPAE translation tables
With CFG_DYN_CONFIG enabled allocate translation tables using the boot_mem_*() functions. Static allocation from global variables is stil
core: arm: mm: dynamic allocation of LPAE translation tables
With CFG_DYN_CONFIG enabled allocate translation tables using the boot_mem_*() functions. Static allocation from global variables is still used with CFG_DYN_CONFIG disabled.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 18715752 | 09-Jul-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: arm: mm: refactor LPAE translation table handling
Refactor translation table handling to use a more flexible layout of the translation tables in memory. Instead of relying on multidimensional
core: arm: mm: refactor LPAE translation table handling
Refactor translation table handling to use a more flexible layout of the translation tables in memory. Instead of relying on multidimensional array use helper functions to calculate the address of each translation table as needed.
Preparing for future changes, no change in behaviour.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| ef0d00c1 | 10-Jul-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: mm: extend temporary dummy memory map
core_init_mmu_map() uses a temporary dummy memory map for the virt_to_phys() and phys_to_virt() conversions to avoid asserting while setting up translatio
core: mm: extend temporary dummy memory map
core_init_mmu_map() uses a temporary dummy memory map for the virt_to_phys() and phys_to_virt() conversions to avoid asserting while setting up translation tables before the MMU is enabled. CFG_DYN_CONFIG will need a larger range of memory since translation tables might not be allocated from .nozi memory only. So for CFG_DYN_CONFIG extend of end of the unused memory range that the boot_mem_*() functions allocate memory from.
Introduce CFG_DYN_CONFIG, enabled by default if CFG_BOOT_MEM is enabled and CFG_WITH_PAGER disabled. CFG_DYN_CONFIG conflicts with CFG_WITH_PAGER since the pager uses a different mechanism for memory allocation.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| 0799b137 | 16-Sep-2024 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: arm: add boot mem paddings to the heap
Add the paddings added due to requested alignment in boot mem allocations to the heap.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-b
core: arm: add boot mem paddings to the heap
Add the paddings added due to requested alignment in boot mem allocations to the heap.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|