Commit graph

6476 commits

Author SHA1 Message Date
Manish V Badarkhe
eb46520c5c Merge "feat(morello): add cpuidle support" into integration 2023-09-06 12:47:46 +02:00
Yann Gautier
88b2d81345 Merge "fix(scmi): add parameter for plat_scmi_clock_rates_array" into integration 2023-09-06 11:26:32 +02:00
Yann Gautier
117b357260 Merge "feat(imx8m): move the gpc reg & macro to a separate header file" into integration 2023-09-06 11:20:14 +02:00
Yann Gautier
b8f365c39c Merge "feat(imx8m): add more dram pll setting" into integration 2023-09-06 11:20:00 +02:00
Manish Pandey
ce64c650e8 Merge "fix(arm/fpga): enable CPU features required for ARMv9.2 cores" into integration 2023-09-05 10:33:52 +02:00
sahil
4f7330dc78 feat(morello): add cpuidle support
This patch adds necessary device-tree idle state definitions and enables
relevant platform makefile options.

Co-authored-by: Karl Meakin <karl.meakin@arm.com>
Signed-off-by: sahil <sahil@arm.com>
Change-Id: Iaf95867095f0514ec3994b9c9efd9756ed49ef43
2023-09-05 11:44:19 +05:30
Madhukar Pappireddy
21eb18a3f9 Merge "fix(ti): fix TISCI API changes during refactor" into integration 2023-08-31 17:56:06 +02:00
Jacky Bai
2a6ffa99af feat(imx8m): move the gpc reg & macro to a separate header file
move the gpc reg offset, bit define & macro to a separate header
file for code reuse.

This fixes suspend to mem on i.MX8M Plus too, since the register
layout is different there.

Change-Id: Ibec60c3a68ffa8c378de5334577a7b0e463ca875
Signed-off-by: Jacky Bai <ping.bai@nxp.com>
Signed-off-by: Marek Vasut <marex@denx.de> # Upgrade to latest, update commit message
2023-08-31 17:35:28 +02:00
Marek Vasut
89474044a5 feat(imx8m): add more dram pll setting
Add DRAM PLL frequency setting for 3732mts & 3733mts.

Change-Id: I74feab2185376bbb84826d7ee79b5e25cbc4d263
Signed-off-by: Marek Vasut <marex@denx.de>
2023-08-31 17:10:14 +02:00
Andre Przywara
b321c24342 fix(arm/fpga): enable CPU features required for ARMv9.2 cores
Similar to the FVP and QEMU, the Arm FPGA systems come with different
CPU cores, and gain new features over time.

Add a list of ARMv9.2 features that require TF-A enablement to be usable
from non-secure world. Their existence will be detected at runtime, so
supporting all those features is not required for using the build.

This fixes the Linux kernel booting on a ARMv9.2 FPGA core.

Change-Id: Ie93c32b13ce4f9968081bf38296cd45edad0a928
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2023-08-31 15:58:22 +01:00
Amit Nagal
fdf8f929df fix(xilinx): update dtb when dtb address and tf-a ddr flow is used
Memory reservation in dtb will be done only when TF-A runs from
ddr and dtb load address is provided.
Otherwise prepare_dtb will simply return.
Empty definition of prepare_dtb is removed.

Signed-off-by: Amit Nagal <amit.nagal@amd.com>
Change-Id: Ie8a3ec51d60a7389831cfe6a112f722777930623
2023-08-31 09:15:26 +02:00
Amit Nagal
56afab73a8 fix(versal): use correct macro name for ocm base address
In absence of definition, PLAT_OCM_BASE is always 0
and IS_TFA_IN_OCM(x) always returns true irrespective
of address passed to it. Reasoning is as mentioned in
Refer section 4.2.3 in
https://gcc.gnu.org/onlinedocs/gcc-3.0.2/cpp_4.html
Due to this,functionality for reservation of TF-A DDR memory in
dtb is never executed.

Signed-off-by: Amit Nagal <amit.nagal@amd.com>
Change-Id: Iafb6b7c6aec29bba22f8f7a8395f9caf97548157
2023-08-31 09:15:04 +02:00
Manish V Badarkhe
cf6371bc34 Merge "refactor(ast2700): update memory layout" into integration 2023-08-30 12:19:38 +02:00
Chia-Wei Wang
e681f1b8b3 refactor(ast2700): update memory layout
Update the memory layout for both BL31 and BL32 FW based on
the 1GB DRAM space of the AST2700 EVB.

Minor:
 - Use SZ_xx macro to define size for better readability

Signed-off-by: Chia-Wei Wang <chiawei_wang@aspeedtech.com>
Change-Id: I6d8285bd675321f615bb67cdd27bb4b6cb4c8b16
2023-08-30 16:34:45 +08:00
Bipin Ravi
38f7b43409 Merge "feat(cpus): add support for Nevis CPU" into integration 2023-08-29 00:28:35 +02:00
Juan Pablo Conde
549795895c feat(cpus): add support for Nevis CPU
Adding basic CPU library code to support Nevis CPU

Change-Id: I399cc9b7b2d907b02b76ea2a3e5abb54e28fbf6c
Signed-off-by: Juan Pablo Conde <juanpablo.conde@arm.com>
2023-08-28 13:18:20 -05:00
Govindraj Raja
450cbe11a9 chore(npcm845x): remove pauth_helpers.S additions in platform makefile
Currently 'pauth_helpers.S' is added if pauth is enabled from main
level makefile.

Change-Id: I33800e280daea6dba6d11e2c494101b369cd8a0b
Signed-off-by: Govindraj Raja <govindraj.raja@arm.com>
2023-08-28 10:27:20 -05:00
Madhukar Pappireddy
74e3f593be Merge "fix(nuvoton): fix typo in platform.mk" into integration 2023-08-28 15:07:14 +02:00
Madhukar Pappireddy
5f01b0b116 Merge "build(bl32): added check for AARCH32_SP" into integration 2023-08-25 00:34:00 +02:00
Juan Pablo Conde
043f38fd50 build(bl32): added check for AARCH32_SP
If AACRH32_SP is not specified, it causes the DEFAULT_LINKER_SCRIPT
variable to be empty, and then the linker takes the variable following
it as if it was the linker script, which is not one. This patch
addresses that issue by requiring the AARCH32_SP variable to be set
before continuing.

Change-Id: I21db7d5bd86b98faaa1a1cd3f985daa592556a2d
Signed-off-by: Juan Pablo Conde <juanpablo.conde@arm.com>
2023-08-24 14:22:34 -05:00
Olivier Deprez
9de6b16ff7 Merge "feat(mt8188): add support for SMC from OP-TEE" into integration 2023-08-24 17:08:01 +02:00
Manorit Chawdhry
d7a7135d32 fix(ti): fix TISCI API changes during refactor
The refactor caused many APIs to be regressed due to copy paste changes
so fix them.

Fixes: 6688fd7aec ("refactor(ti): refactor ti_sci_{setup,do}_xfer to allow zero size response")
Change-Id: I03a808fa0bf2cbefbc1c9924bdaf4cfb2ad7f2cb
Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
2023-08-24 15:04:15 +05:30
Marcin Juszkiewicz
51ce1f3469 refactor(qemu): handle pointer authentication
Pointer authentication requires CTX_INCLUDE_PAUTH_REGS to be defined.

Change-Id: I4ca95d6d9e619e7a7296a2c3ecb799683bf70575
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
2023-08-23 12:48:26 +02:00
Marcin Juszkiewicz
4a2e7547b3 refactor(qemu): move options to start of file
There are some variables to enable/disable options. Let keep them at top
of file.

Change-Id: I108dd814557b6c713aba0d73a52148c766079c8b
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
2023-08-21 22:06:41 +02:00
Marcin Juszkiewicz
035c6da4af refactor(qemu): keep AArch64 cpu flags in one section
There is no need to have two "if" checks for same thing one after
another.

FGT, RNG, SVE, SME are aarch64 only flags.

Change-Id: I6e5850211c859dc7a4ccf6bc8dc6a8d600ffe692
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
2023-08-21 22:06:41 +02:00
Marcin Juszkiewicz
941fc3834d refactor(qemu): handle SPM_MM builds
SPM_MM is not compatible with ENABLE_SVE_FOR_NS and breaks build early:

> Including SPM Management Mode (MM) makefile
> services/std_svc/spm/spm_mm/spm_mm.mk:14: *** "Error: SPM_MM is not compatible with ENABLE_SVE_FOR_NS". Stop.

Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
Change-Id: Iabe181647fce00a432ae11dc4599b71619364c24
2023-08-21 22:06:29 +02:00
Marcin Juszkiewicz
3b61457b4e refactor(qemu): handle AArch64 flags
Handle coherency in one place for AArch64 mode.

Change-Id: Id3678a8f478e5ef731c81c0df30059000e380758
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
2023-08-21 21:41:26 +02:00
Marcin Juszkiewicz
c1baf17821 refactor(qemu): common cpu features enablement
Enable SVE, SME, RNG, FGT in one place.

qemu gains FGT (needed for 'max' cpu to boot Linux)
qemu_sbsa gains RNG

Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
Change-Id: I2e8f971ef3e42d9ebe9f20641b288cc8c40f806a
2023-08-21 21:41:26 +02:00
Marcin Juszkiewicz
1888475005 refactor(qemu): common BL31 sources
Move BL31 source list into common file.

Change-Id: Iaa27cfd8f87b691728379c87a6ff6331e87951e1
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
2023-08-21 21:30:39 +02:00
Marcin Juszkiewicz
71f5359b11 refactor(qemu): common BL1/2 sources
Move BL1 and BL2 source list into common file.

Change-Id: I8f9a835f6cd1c5d67728a071860173f80f03c84e
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
2023-08-21 21:30:39 +02:00
Marcin Juszkiewicz
886688d136 refactor(qemu): move CPU definitions into one place
Keep list of supported cpu cores in one place for both platforms.
qemu_sbsa does not handle some of them but with 256MB firmware space it
does not matter.

Change-Id: I5b8f7d18dc903e86e0cc7babbc2fb3f26a1bfdfa
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
2023-08-21 21:30:34 +02:00
Marcin Juszkiewicz
a63cdc74ce refactor(qemu): move FDT stuff into one place
Move libfdt includes into common file and use definitions from them.

Change-Id: Ic4fe784fdbedcf5e9e3804a633fcac68464f38a6
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
2023-08-21 21:19:14 +02:00
Margarita Glushkin
c7efb78f8e fix(nuvoton): fix typo in platform.mk
Fix typo of SPMD_SPM_AT_SEL2 in platform.mk

Signed-off-by: Margarita Glushkin <rutigl@gmail.com>
Change-Id: I06cfe2f1f0783edff513d83fef08eeed5f4fc58b
2023-08-21 16:53:55 +03:00
XiaoDong Huang
ca9d6edc89 fix(scmi): add parameter for plat_scmi_clock_rates_array
Pass "start_idx" to plat_scmi_clock_rates_array.
This parameter is required to obtain the rate table
a second time.

Signed-off-by: XiaoDong Huang <derrick.huang@rock-chips.com>
Change-Id: I97c6751e7d34c839ced8f22bddc39fb534978cc4
2023-08-21 19:46:52 +08:00
Manish V Badarkhe
b3d7e9c282 Merge "build(juno): added error check for BL32 dependency" into integration 2023-08-21 11:35:40 +02:00
Joanna Farley
c89d591218 Merge "fix(versal-net): don't clear pending interrupts" into integration 2023-08-21 09:54:32 +02:00
Juan Pablo Conde
7557486408 build(juno): added error check for BL32 dependency
Macro PLAT_ARM_MAX_BL32_SIZE definition is dependent on
JUNO_AARCH32_EL3_RUNTIME=1. When this value is not set and building
for AArch32, the build fails as it cannot find the definition of the
first macro. With this patch, the problem is addressed by producing
an error when the dependency is not set properly.

Change-Id: Ibe4e976bf79892fd26f3b266bd546218f5616825
Signed-off-by: Juan Pablo Conde <juanpablo.conde@arm.com>
2023-08-18 21:21:47 -05:00
Saeed Nowshadi
fb73ea6cc3 fix(versal-net): don't clear pending interrupts
All pending interrupts should be handled by their interrupt handlers.  CPU
cores remain in suspend state if pending interrupts are cleared.

Signed-off-by: Saeed Nowshadi <saeed.nowshadi@amd.com>
Change-Id: Id8ddf36cbcc07484f232c477277c4da106985c8f
2023-08-17 12:37:05 -07:00
Naman Trivedi Manojbhai
abc79c275b fix(zynqmp): validate clock_id to avoid OOB variable access
The input argument clock_id in pm_api_clock_get_name function is not
validated against the maximum allowed number. This can lead to OOB
access for ext_clocks variable.

Add check in the pm_api_clock_get_name() to validate clock_id against
CLK_MAX.

Signed-off-by: Naman Trivedi Manojbhai <naman.trivedimanojbhai@amd.com>
Change-Id: Ifa0033d2c557efd6a87b40e366560bc3ba8c602b
2023-08-17 05:42:28 -07:00
Lauren Wehrmeister
abc2919c6c Merge "feat(cpus): add support for Gelas CPU" into integration 2023-08-14 21:05:23 +02:00
Madhukar Pappireddy
4ede8c39a2 Merge changes from topic "el3_direct_msg" into integration
* changes:
  docs(spm): document new build option
  feat(fvp): spmd logical partition smc handler
  feat(fvp): add spmd logical partition
  feat(spmd): get logical partitions info
  feat(spmd): add partition info get regs
  refactor(ff-a): move structure definitions
  feat(spmd): el3 direct message API
  feat(spmd): add spmd logical partitions
2023-08-14 17:12:59 +02:00
Dawei Chien
34d9d619f1 feat(mt8188): add support for SMC from OP-TEE
- Add MTK_SIP_SMC_FROM_S_EL1_TABLE to handle the SMC call from OP-TEE.
- Register optee for EMI MPU.

Change-Id: Ie94542f0e3966c4c25f2b7233b9355d41f8f36a5
Signed-off-by: Dawei Chien <dawei.chien@mediatek.com>
Signed-off-by: Jason Chen <Jason-ch.Chen@mediatek.com>
2023-08-14 10:49:41 +08:00
Raghu Krishnamurthy
a1a9a95071 feat(fvp): spmd logical partition smc handler
This patch adds a basic el3 spmd logical partition to the fvp platform
via a platform specific smc handler. One of the use cases for el3
logical partitions is to have the ability to translate sip calls into
ff-a direct requests via the use of spmd logical partitions. The smc
handler creates a direct request based on the incoming smc parameters
and forwards the call as a direct request from the spmd logical
partition to the target secure partition.

Change-Id: If8ba9aab8203924bd00fc1dcdf9cd05a9a04a147
2023-08-11 18:57:50 -07:00
Raghu Krishnamurthy
5cf311f3a4 feat(fvp): add spmd logical partition
This patch changes spmd.mk to include one or more SPMD logical
partitions specific to a platform. It also adds a basic SPMD logical
partition to fvp.

Change-Id: I2075e0458c92813913b28cbf4cfffc1f151e65cf
Signed-off-by: Raghu Krishnamurthy <raghu.ncstate@gmail.com>
2023-08-11 18:56:36 -07:00
Juan Pablo Conde
02586e0e28 feat(cpus): add support for Gelas CPU
This patch adds the necessary CPU library code to support the Gelas CPU

Change-Id: I13ec4a8bb7055c1ebd0796a4a1378983d930fcb3
Signed-off-by: Juan Pablo Conde <juanpablo.conde@arm.com>
2023-08-11 15:57:33 -05:00
Bipin Ravi
705832b3a3 Merge changes I2f4961fe,I0039c724,Iaa3076c1,Ic19973a8 into integration
* changes:
  feat(bl32): print entry point before exiting SP_MIN
  fix(bl32): avoid clearing argument registers in RESET_TO_SP_MIN case
  fix(bl32): always include arm_arch_svc in SP_MIN
  fix(services): disable workaround discovery on aarch32 for now
2023-08-11 16:57:09 +02:00
Joanna Farley
38d1679db2 Merge changes from topic "xlnx_security_flag_change" into integration
* changes:
  fix(versal-net): make pmc ipi channel as secure
  fix(versal): make pmc ipi channel as secure
  fix(versal-net): add redundant call to avoid glitches
  fix(versal-net): change flag to increase security
2023-08-10 16:08:15 +02:00
Manish V Badarkhe
72e8f2456a Merge "chore: update to use Arm word across TF-A" into integration 2023-08-08 17:26:48 +02:00
Govindraj Raja
4c700c1563 chore: update to use Arm word across TF-A
Align entire TF-A to use Arm in copyright header.

Change-Id: Ief9992169efdab61d0da6bd8c5180de7a4bc2244
Signed-off-by: Govindraj Raja <govindraj.raja@arm.com>
2023-08-08 15:12:30 +01:00
Manish V Badarkhe
c399679cdc Merge "feat(stm32mp1): add FWU with boot from NOR-SPI" into integration 2023-08-08 15:46:02 +02:00