]> git.baikalelectronics.ru Git - arm-tf.git/log
arm-tf.git
2 years agoMerge "chore(docs): fix broken url references to arm procedure call" into integration
Manish V Badarkhe [Thu, 10 Nov 2022 18:25:01 +0000 (19:25 +0100)]
Merge "chore(docs): fix broken url references to arm procedure call" into integration

2 years agoMerge changes from topic "mp/ras_refactoring" into integration
Olivier Deprez [Thu, 10 Nov 2022 16:46:21 +0000 (17:46 +0100)]
Merge changes from topic "mp/ras_refactoring" into integration

* changes:
  docs: document do_panic() and panic() helper functions
  fix(ras): restrict RAS support for NS world

2 years agochore(docs): fix broken url references to arm procedure call
Govindraj Raja [Thu, 10 Nov 2022 15:27:35 +0000 (15:27 +0000)]
chore(docs): fix broken url references to arm procedure call

Couple for urls under section: `5.6. Use of built-in C and libc
data types` from docs has broken urls since the new arm procedure
call doc is moved to be part of `ARM-software/abi-aa`.

Change-Id: Ied184ed56c8335d4cbc687e56962439091a18e42
Signed-off-by: Govindraj Raja <govindraj.raja@arm.com>
2 years agoMerge changes from topic "mp/ras_refactoring" into integration
Manish Pandey [Thu, 10 Nov 2022 16:22:39 +0000 (17:22 +0100)]
Merge changes from topic "mp/ras_refactoring" into integration

* changes:
  fix(debug): decouple "get_el_str()" from backtrace
  fix(bl31): harden check in delegate_async_ea

2 years agoMerge changes from topic "ffa_el3_spmc_fixes" into integration
Joanna Farley [Thu, 10 Nov 2022 12:46:33 +0000 (13:46 +0100)]
Merge changes from topic "ffa_el3_spmc_fixes" into integration

* changes:
  fix(el3-spmc): check descriptor size for overflow
  fix(el3-spmc): fix location of fragment length check
  fix(el3-spmc): fix detection of overlapping memory regions
  fix(el3-spmc): fix incomplete reclaim validation

2 years agoMerge "chore(docs): move deprecated platforms information around" into integration
Manish Pandey [Thu, 10 Nov 2022 11:59:17 +0000 (12:59 +0100)]
Merge "chore(docs): move deprecated platforms information around" into integration

2 years agoMerge "build: warn about RSS driver experimental status" into integration
Sandrine Bailleux [Thu, 10 Nov 2022 06:46:25 +0000 (07:46 +0100)]
Merge "build: warn about RSS driver experimental status" into integration

2 years agoMerge changes from topic "errata" into integration
Madhukar Pappireddy [Wed, 9 Nov 2022 20:20:24 +0000 (21:20 +0100)]
Merge changes from topic "errata" into integration

* changes:
  fix(cpus): workaround for Cortex-A76 erratum 2743102
  fix(cpus): workaround for Neoverse N1 erratum 2743102

2 years agoMerge "refactor(trng): cleanup the existing TRNG support" into integration
Manish V Badarkhe [Wed, 9 Nov 2022 16:30:17 +0000 (17:30 +0100)]
Merge "refactor(trng): cleanup the existing TRNG support" into integration

2 years agoMerge "fix(versal-net): add default values for silicon" into integration
Joanna Farley [Wed, 9 Nov 2022 11:49:28 +0000 (12:49 +0100)]
Merge "fix(versal-net): add default values for silicon" into integration

2 years agoMerge "docs(rme): add instruction to build rmm" into integration
Soby Mathew [Wed, 9 Nov 2022 11:48:38 +0000 (12:48 +0100)]
Merge "docs(rme): add instruction to build rmm" into integration

2 years agoMerge "docs(security): rename Makalu and SB optimisation" into integration
Joanna Farley [Wed, 9 Nov 2022 11:48:23 +0000 (12:48 +0100)]
Merge "docs(security): rename Makalu and SB optimisation" into integration

2 years agoMerge "docs(maintainers): update qti maintainer" into integration
Joanna Farley [Wed, 9 Nov 2022 11:38:48 +0000 (12:38 +0100)]
Merge "docs(maintainers): update qti maintainer" into integration

2 years agodocs(rme): add instruction to build rmm
Shruti Gupta [Wed, 2 Nov 2022 11:33:38 +0000 (11:33 +0000)]
docs(rme): add instruction to build rmm

Add documentation to build and run TF-A with RMM,
Linux kernel and TFTF Realm Payload.

Signed-off-by: Shruti Gupta <shruti.gupta@arm.com>
Change-Id: I951b41a144aabe0fec16eb933d7f005a65f06fb2

2 years agoMerge "docs: add link to DCO" into integration
Manish V Badarkhe [Wed, 9 Nov 2022 09:43:51 +0000 (10:43 +0100)]
Merge "docs: add link to DCO" into integration

2 years agofix(versal-net): add default values for silicon
Michal Simek [Sat, 5 Nov 2022 22:39:47 +0000 (15:39 -0700)]
fix(versal-net): add default values for silicon

Add missing default value for silicon.

Signed-off-by: Michal Simek <michal.simek@amd.com>
Change-Id: Iac7d4db17a29a148298e9e3bd3eb3f74cafe7bc1

2 years agochore(docs): move deprecated platforms information around
Sandrine Bailleux [Tue, 8 Nov 2022 12:36:42 +0000 (13:36 +0100)]
chore(docs): move deprecated platforms information around

We used to have a dedicated page for deprecated platforms information.
This document contained 2 pieces of information:

 a) the process for deprecating a platform port;
 b) the list of deprecated platforms to this day.

I think it makes more sense to move b) to the platforms ports landing
page, such that it is more visible.

This also has the nice effect to move the 'Deprecated platforms' title
as the last entry of the 'Platform ports' table of contents, like so:

 - Platform ports
   - 1. Allwinner ARMv8 SoCs
   - 2. Arm Development Platforms
     ...
   - 39. Broadcom Stingray
   - Deprecated platforms

instead of it being lost in the middle of supported platform ports.

Regarding a), this gets moved under the "Processes & Policies" section.
More specifically, it gets clubbed with the existing platform
compatibility policy. The combined document gets renamed into a
"Platforms Ports Policy" document.

Change-Id: I6e9ce2abc68b8a8ac88e7bd5f21749c14c9a2af6
Signed-off-by: Sandrine Bailleux <sandrine.bailleux@arm.com>
2 years agoMerge "chore(docs): refresh platform ports landing page" into integration
Sandrine Bailleux [Wed, 9 Nov 2022 09:28:07 +0000 (10:28 +0100)]
Merge "chore(docs): refresh platform ports landing page" into integration

2 years agoMerge changes from topic "rdn2cfg2_spi_support" into integration
Manish V Badarkhe [Wed, 9 Nov 2022 09:21:56 +0000 (10:21 +0100)]
Merge changes from topic "rdn2cfg2_spi_support" into integration

* changes:
  feat(rdn2): enable extended SPI support
  feat(rdn2): add SPI ID ranges for RD-N2 multichip platform

2 years agoMerge "feat: pass SMCCCv1.3 SVE hint bit to dispatchers" into integration
Olivier Deprez [Wed, 9 Nov 2022 08:04:07 +0000 (09:04 +0100)]
Merge "feat: pass SMCCCv1.3 SVE hint bit to dispatchers" into integration

2 years agodocs(security): rename Makalu and SB optimisation
Bipin Ravi [Sat, 5 Nov 2022 03:52:56 +0000 (22:52 -0500)]
docs(security): rename Makalu and SB optimisation

Changing Makalu reference to the public name Cortex-A715. Also, added
a note on use of SB instruction for all CPUs supporting ENABLE_FEAT_SB.

Signed-off-by: Bipin Ravi <bipin.ravi@arm.com>
Change-Id: I98bd36c684fa7ae79bd4e8e641fd73404435c202

2 years agodocs: add link to DCO
Chris Kay [Tue, 8 Nov 2022 17:24:23 +0000 (17:24 +0000)]
docs: add link to DCO

The link to the Developer Certificate of Origin was mistakenly removed
in a patch some time ago. This change re-adds it.

Change-Id: Ia8aed055cb449cdf4c1aaeac9b81ca15099e73f5
Signed-off-by: Chris Kay <chris.kay@arm.com>
2 years agoMerge "docs(changelog): add missing scopes for release" into integration
Lauren Wehrmeister [Tue, 8 Nov 2022 17:06:39 +0000 (18:06 +0100)]
Merge "docs(changelog): add missing scopes for release" into integration

2 years agoMerge changes from topic "npm-dependencies" into integration
Manish Pandey [Tue, 8 Nov 2022 16:20:53 +0000 (17:20 +0100)]
Merge changes from topic "npm-dependencies" into integration

* changes:
  docs(changelog): fix invalid context management scope
  docs(commit-style): fix incorrect instructions for adding scopes
  docs(prerequisites): update Node.js prerequisites documentation

2 years agodocs: document do_panic() and panic() helper functions
Manish Pandey [Wed, 2 Nov 2022 16:30:09 +0000 (16:30 +0000)]
docs: document do_panic() and panic() helper functions

panic() and do_panic() are widely used helper functions called when
encountering a critical failure that cannot be recovered from.
Document them in porting guide. Also, remove panic() documentation
from PSCI guide(where it is unused anyways).

Signed-off-by: Manish Pandey <manish.pandey2@arm.com>
Change-Id: Ib0965cce56c03d0de5ac0d05d5714a6942793ede

2 years agobuild: warn about RSS driver experimental status
Sandrine Bailleux [Tue, 8 Nov 2022 14:04:36 +0000 (15:04 +0100)]
build: warn about RSS driver experimental status

Change-Id: I93b7afe17395a94e1ec0ae09457eb2fd320d59a9
Signed-off-by: Sandrine Bailleux <sandrine.bailleux@arm.com>
2 years agorefactor(trng): cleanup the existing TRNG support
Jayanth Dodderi Chidanand [Tue, 11 Oct 2022 16:16:07 +0000 (17:16 +0100)]
refactor(trng): cleanup the existing TRNG support

This patch adds the following changes to complete the existing
TRNG implementation:

1. Adds a feature specific scope for buildlog generation.
2. Updates the docs on the build flag "TRNG_SUPPORT" and its values.
3. Makefile update and improves the existing comments at few sections
for better understanding of the underlying logic.

Change-Id: I3f72f0ccd5c94005a2df87158cf23199d2160d37
Signed-off-by: Jayanth Dodderi Chidanand <jayanthdodderi.chidanand@arm.com>
2 years agochore(docs): refresh platform ports landing page
Sandrine Bailleux [Tue, 8 Nov 2022 12:22:20 +0000 (13:22 +0100)]
chore(docs): refresh platform ports landing page

 - Remove mentions of Arm SGM-775 and MediaTek MT6795 platforms.
   Both platform ports were deleted from TF-A source tree in the
   last release (v2.7).

 - Remove mention of Arm Morello platform, as it now has a dedicated
   documentation page accessible from the table of contents
   (see docs/plat/arm/morello/).

Change-Id: Ie3acdddab81f5589bb36114a8a766200f5b08ad4
Signed-off-by: Sandrine Bailleux <sandrine.bailleux@arm.com>
2 years agoMerge "build(bl2): only set BL2_CPPFLAGS for armv8" into integration
Manish Pandey [Tue, 8 Nov 2022 11:48:31 +0000 (12:48 +0100)]
Merge "build(bl2): only set BL2_CPPFLAGS for armv8" into integration

2 years agofix(ras): restrict RAS support for NS world
Manish Pandey [Mon, 10 Oct 2022 10:43:08 +0000 (11:43 +0100)]
fix(ras): restrict RAS support for NS world

Current RAS framework in TF-A only supports handling errors originating
from NS world but the HANDLE_EA_EL3_FIRST flag configures it for all
lower Els. To make the current design of RAS explicit, rename this macro
to HANDLE_EA_EL3_FIRST_NS and set EA bit in scr_el3 only when
switching to NS world.

Note: I am unaware of any platform which traps errors originating in
Secure world to EL3, if there is any such platform then it need to
be explicitly implemented in TF-A

Signed-off-by: Manish Pandey <manish.pandey2@arm.com>
Change-Id: If58eb201d8fa792c16325c85c26056e9b409b750

2 years agofix(debug): decouple "get_el_str()" from backtrace
Manish Pandey [Tue, 1 Nov 2022 16:16:55 +0000 (16:16 +0000)]
fix(debug): decouple "get_el_str()" from backtrace

get_el_str() was implemented under ENABLE_BACKTRACE macro but being
used at generic places too, this causes multiple definition of this
function.
Remove duplicate definition of this function and move it out of
backtrace scope. Also, this patch fixes a small bug where in default
case S-EL1 is returned which ideally should be EL1, as there is no
notion of security state in EL string.

Signed-off-by: Manish Pandey <manish.pandey2@arm.com>
Change-Id: Ib186ea03b776e2478eff556065449ebd478c3538

2 years agofeat: pass SMCCCv1.3 SVE hint bit to dispatchers
Olivier Deprez [Tue, 11 Oct 2022 13:38:27 +0000 (15:38 +0200)]
feat: pass SMCCCv1.3 SVE hint bit to dispatchers

SMCCCv1.3 introduces the SVE hint bit added to the SMC FID (bit 16)
denoting that the world issuing an SMC doesn't expect the callee to
preserve the SVE state (FFR, predicates, Zn vector bits greater than
127). Update the generic SMC handler to copy the SVE hint bit state
to SMC flags and mask out the bit by default for the services called
by the standard dispatcher. It is permitted by the SMCCC standard to
ignore the bit as long as the SVE state is preserved. In any case a
callee must preserve the NEON state (FPCR/FPSR, Vn 128b vectors)
whichever the SVE hint bit state.

Signed-off-by: Olivier Deprez <olivier.deprez@arm.com>
Change-Id: I2b163ed83dc311b8f81f96b23c942829ae9fa1b5

2 years agodocs(maintainers): update qti maintainer
Muhammad Arsath K F [Tue, 8 Nov 2022 05:42:34 +0000 (21:42 -0800)]
docs(maintainers): update qti maintainer

Add Muhammad Arsath K F in qti maintainer

Signed-off-by: Muhammad Arsath K F <quic_mkf@quicinc.com>
Change-Id: I71e6cc72b3c658730abe5255977f3b93dd7e4563

2 years agodocs(changelog): add missing scopes for release
laurenw-arm [Tue, 1 Nov 2022 19:45:33 +0000 (14:45 -0500)]
docs(changelog): add missing scopes for release

Add missing scopes from commits for the upcoming release.

Change-Id: I22e38fb0658e42b45591c82aa30e063f7a7edc86
Signed-off-by: Lauren Wehrmeister <lauren.wehrmeister@arm.com>
2 years agofix(bl31): harden check in delegate_async_ea
Manish Pandey [Tue, 11 Oct 2022 16:28:14 +0000 (17:28 +0100)]
fix(bl31): harden check in delegate_async_ea

Following hardening done around ESR_EL3 register usage
 - Panic if exception is anyting other than SError
 - AET bit is only valid if DFSC is 0x11, move DFSC check before AET.

Signed-off-by: Manish Pandey <manish.pandey2@arm.com>
Change-Id: Ib15159920f6cad964332fd40f88943aee2bc73b4

2 years agofix(el3-spmc): check descriptor size for overflow
Marc Bonnici [Tue, 18 Oct 2022 13:03:13 +0000 (14:03 +0100)]
fix(el3-spmc): check descriptor size for overflow

Ensure that the provided descriptor size used when reserving space
for a memory descriptor does not overflow to prevent scope for
memory corruption. Reported by Matt Oh, Google Android Red Team.

Reported-by: mattoh@google.com
Signed-off-by: Marc Bonnici <marc.bonnici@arm.com>
Change-Id: If06985c4de9a88ff82ce60d10e346da948ed383f

2 years agofix(el3-spmc): fix location of fragment length check
Marc Bonnici [Tue, 18 Oct 2022 12:57:16 +0000 (13:57 +0100)]
fix(el3-spmc): fix location of fragment length check

Ensure that the fragment_length parameter is validated to prevent
a buffer overflow before it is used. Reported by Matt Oh, Google Android Red Team.

Reported-by: mattoh@google.com
Signed-off-by: Marc Bonnici <marc.bonnici@arm.com>
Change-Id: I0323c096ffd988fbd85bbd4ade3abd8427aea977

2 years agofix(el3-spmc): fix detection of overlapping memory regions
Marc Bonnici [Tue, 18 Oct 2022 12:50:04 +0000 (13:50 +0100)]
fix(el3-spmc): fix detection of overlapping memory regions

The current logic does not cover all scenarios of overlapping
memory regions. Update the implementation to verify non-overlapping
regions instead. Reported by Matt Oh, Google Android Red Team.

Reported-by: mattoh@google.com
Signed-off-by: Marc Bonnici <marc.bonnici@arm.com>
Change-Id: I16c53d081e4455bc0e28399d28a1b27b1a9eb49c

2 years agofix(el3-spmc): fix incomplete reclaim validation
Marc Bonnici [Tue, 18 Oct 2022 12:39:48 +0000 (13:39 +0100)]
fix(el3-spmc): fix incomplete reclaim validation

Ensure that the full memory transaction descriptor has been transmitted
before a request to reclaim the memory transaction is permitted.
This prevents any potential accesses to the incomplete descriptor.
Reported by Matt Oh, Google Android Red Team.

Reported-by: mattoh@google.com
Signed-off-by: Marc Bonnici <marc.bonnici@arm.com>
Change-Id: I33e993c6b754632051e899ab20edd19b18b6cf65

2 years agobuild(bl2): only set BL2_CPPFLAGS for armv8
Diego Sueiro [Thu, 3 Nov 2022 17:01:39 +0000 (17:01 +0000)]
build(bl2): only set BL2_CPPFLAGS for armv8

If ARM_ARCH_MAJOR is 9 and ARM_ARCH_MINOR is 0 we don't want need to
have "-march=armv8-a+crc" in BL2_CPPFLAGS.

Change-Id: I9ac11522fde00953da40b95eebf82ff8ab2559ba
Signed-off-by: Diego Sueiro <diego.sueiro@arm.com>
2 years agoMerge "feat(qti): updated soc version for sc7180 and sc7280" into integration
Manish V Badarkhe [Fri, 4 Nov 2022 17:55:26 +0000 (18:55 +0100)]
Merge "feat(qti): updated soc version for sc7180 and sc7280" into integration

2 years agodocs(changelog): fix invalid context management scope
Chris Kay [Mon, 10 Oct 2022 15:57:45 +0000 (16:57 +0100)]
docs(changelog): fix invalid context management scope

Change-Id: Ia94b944a023568fc53a812cefffe97a7b3af4266
Signed-off-by: Chris Kay <chris.kay@arm.com>
2 years agodocs(commit-style): fix incorrect instructions for adding scopes
Chris Kay [Mon, 10 Oct 2022 15:50:14 +0000 (16:50 +0100)]
docs(commit-style): fix incorrect instructions for adding scopes

Change-Id: I3ce7abd1c21b084dea6b618c603f71b5bb4c50e8
Signed-off-by: Chris Kay <chris.kay@arm.com>
2 years agodocs(prerequisites): update Node.js prerequisites documentation
Chris Kay [Mon, 10 Oct 2022 13:34:23 +0000 (14:34 +0100)]
docs(prerequisites): update Node.js prerequisites documentation

This change updates the version of the Node Version Manager suggested by
the prerequisites documentation. The NVM installation command line hint
has been replaced with the snippet provided by NVM's user guide, and the
second line now automatically installs a version of Node.js compatible
with TF-A's repository scripts.

Change-Id: I6ef5e504118238716ceb45a52083450c424c5d20
Signed-off-by: Chris Kay <chris.kay@arm.com>
2 years agoMerge changes from topic "hikey960-el3-spmc" into integration
Olivier Deprez [Fri, 4 Nov 2022 09:47:54 +0000 (10:47 +0100)]
Merge changes from topic "hikey960-el3-spmc" into integration

* changes:
  feat(hikey960): read serial number from UFS
  feat(hikey960): add a FF-A logical partition
  feat(hikey960): add memory sharing hooks for SPMC_AT_EL3
  feat(hikey960): add plat-defines for SPMC_AT_EL3
  feat(hikey960): define a datastore for SPMC_AT_EL3
  feat(hikey960): add SP manifest for SPMC_AT_EL3
  feat(hikey960): increase secure workspace to 64MB
  feat(hikey960): upgrade to xlat_tables_v2

2 years agoMerge "fix(build): fix arch32 build issue for clang" into integration
Manish Pandey [Fri, 4 Nov 2022 09:42:17 +0000 (10:42 +0100)]
Merge "fix(build): fix arch32 build issue for clang" into integration

2 years agofix(cpus): workaround for Cortex-A76 erratum 2743102
Bipin Ravi [Wed, 2 Nov 2022 21:50:03 +0000 (16:50 -0500)]
fix(cpus): workaround for Cortex-A76 erratum 2743102

Cortex-A76 erratum 2743102 is a Cat B erratum that applies to
all revisions <=r4p1 and is still open. The workaround is to
insert a dsb before the isb in the power down sequence.

SDEN documentation:
https://developer.arm.com/documentation/SDEN885749/latest

Signed-off-by: Bipin Ravi <bipin.ravi@arm.com>
Change-Id: Ie2cd73bd91417d30b5633d80b2fbee32944bc2de

2 years agofix(cpus): workaround for Neoverse N1 erratum 2743102
Bipin Ravi [Wed, 2 Nov 2022 21:12:01 +0000 (16:12 -0500)]
fix(cpus): workaround for Neoverse N1 erratum 2743102

Neoverse N1 erratum 2743102 is a Cat B erratum that applies to
all revisions <=r4p1 and is still open. The workaround is to
insert a dsb before the isb in the power down sequence.

SDEN documentation:
https://developer.arm.com/documentation/SDEN885747/latest

Signed-off-by: Bipin Ravi <bipin.ravi@arm.com>
Change-Id: I81a8793c1a118764df3ac97b67f5e088f56f6a20

2 years agoMerge "style(linker_script): fix indentation" into integration
Joanna Farley [Thu, 3 Nov 2022 17:01:20 +0000 (18:01 +0100)]
Merge "style(linker_script): fix indentation" into integration

2 years agoMerge "feat(drtm): add DRTM parameters structure version check" into integration
Manish Pandey [Thu, 3 Nov 2022 16:56:35 +0000 (17:56 +0100)]
Merge "feat(drtm): add DRTM parameters structure version check" into integration

2 years agofeat(qti): updated soc version for sc7180 and sc7280
Bharath N [Tue, 1 Nov 2022 12:27:17 +0000 (17:57 +0530)]
feat(qti): updated soc version for sc7180 and sc7280

SMCCC_GET_SOC_VERSION SMC will return soc id to distinguish
different varaints in sc7180 and sc7280

Signed-off-by: Bharath N <quic_bharn@quicinc.com>
Change-Id: I72ea4bdb8193c816ba249c1e0755784c9b9bb7da

2 years agofeat(drtm): add DRTM parameters structure version check
Manish V Badarkhe [Wed, 21 Sep 2022 09:04:16 +0000 (10:04 +0100)]
feat(drtm): add DRTM parameters structure version check

Added DRTM parameters structure version check that as per
the current released DRTM specification [1].

Mainly to cater below mentioned in the specification [1]
section 3.12 -
For a given DRTM major version number this structure will
always be extended in a backwards compatible manner.

[1]: https://developer.arm.com/documentation/den0113/a

Change-Id: I9f312c7f9f20152c5d7e40a22b462c7fe8db70bc
Signed-off-by: Manish V Badarkhe <Manish.Badarkhe@arm.com>
2 years agoMerge changes from topic "el3-spmc" into integration
Olivier Deprez [Wed, 2 Nov 2022 18:47:31 +0000 (19:47 +0100)]
Merge changes from topic "el3-spmc" into integration

* changes:
  fix(el3-spmc): error handling in allocation
  fix(el3-spmc): deadlock when relinquishing memory
  fix(el3-spmc): compute full FF-A V1.1 desc size

2 years agoMerge "chore(docs): update supported FVP models doc" into integration
Manish V Badarkhe [Wed, 2 Nov 2022 14:51:49 +0000 (15:51 +0100)]
Merge "chore(docs): update supported FVP models doc" into integration

2 years agofeat(hikey960): read serial number from UFS
Arthur Cassegrain [Fri, 26 Nov 2021 15:39:12 +0000 (16:39 +0100)]
feat(hikey960): read serial number from UFS

Serial number is written into UFS by fastboot
Pass BL2 params to BL31 (serial number)

Change-Id: I9a490db07ca10088da69191a2f2c1621d44a278c
Signed-off-by: vallau01 <valentin.laurent@trustonic.com>
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agofeat(hikey960): add a FF-A logical partition
Lukas Hanel [Mon, 24 Oct 2022 14:55:11 +0000 (16:55 +0200)]
feat(hikey960): add a FF-A logical partition

Required to compile with SPMC_AT_EL3=1
Copied from FVP, sample code for platforms

Change-Id: I7d8a4d8846a328b05cf45a5044802ea3e2f7fb67
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agofeat(hikey960): add memory sharing hooks for SPMC_AT_EL3
vallau01 [Tue, 2 Aug 2022 14:16:11 +0000 (16:16 +0200)]
feat(hikey960): add memory sharing hooks for SPMC_AT_EL3

These allows a platform to do any System-MMU/IOMMU configuration
in line with FF-A memory sharing.

Change-Id: Id517759198421a32c5d16bf5bb99590275e77736
Signed-off-by: vallau01 <valentin.laurent@trustonic.com>
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agofeat(hikey960): add plat-defines for SPMC_AT_EL3
Lukas Hanel [Tue, 1 Mar 2022 14:40:39 +0000 (15:40 +0100)]
feat(hikey960): add plat-defines for SPMC_AT_EL3

To use SPMC_AT_EL3, a platform must define a few configuration
options. Copied them from fvp platform to hikey960.

Change-Id: Ifd60d69bf79f2f340fe93fe030ab8c538b3a56e4
Signed-off-by: vallau01 <valentin.laurent@trustonic.com>
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agofeat(hikey960): define a datastore for SPMC_AT_EL3
Lukas Hanel [Tue, 1 Mar 2022 16:02:31 +0000 (17:02 +0100)]
feat(hikey960): define a datastore for SPMC_AT_EL3

Kinibi now has 60MB (instead of 64MB).
Increase XLAT tables for BL31

Change-Id: I6843d26198a7d8bdb812e394e4482b1c35afa4c0
Signed-off-by: vallau01 <valentin.laurent@trustonic.com>
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agofeat(hikey960): add SP manifest for SPMC_AT_EL3
Lukas Hanel [Tue, 1 Mar 2022 13:18:22 +0000 (14:18 +0100)]
feat(hikey960): add SP manifest for SPMC_AT_EL3

The purpose of this patch is to show silicon partners how to upgrade
existing TF-A port to include a manifest that is required with FF-A.

The manifest values are consumed by TF-A SPMC_AT_EL3 and by the TEE.

Change-Id: Ied81187d6b1cfb72ad2e9020dfc19ad73d80186f
Signed-off-by: Cedric Chan <cedric.chan@trustonic.com>
Signed-off-by: vallau01 <valentin.laurent@trustonic.com>
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agofix(el3-spmc): error handling in allocation
vallau01 [Tue, 9 Aug 2022 16:03:28 +0000 (18:03 +0200)]
fix(el3-spmc): error handling in allocation

Error check must be done on the previously allocated pointer, not a
random one from the code.

Change-Id: I1c8253eacbe778cc4a9a8d71081fc615fa7e5293
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agofix(el3-spmc): deadlock when relinquishing memory
vallau01 [Tue, 9 Aug 2022 15:06:53 +0000 (17:06 +0200)]
fix(el3-spmc): deadlock when relinquishing memory

Do not forget to pass via err_unlock_mailbox: label.

Change-Id: Icfb997b1c7cce196003af2c28bffc50dc73e30b4
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agofix(el3-spmc): compute full FF-A V1.1 desc size
vallau01 [Mon, 8 Aug 2022 12:10:14 +0000 (14:10 +0200)]
fix(el3-spmc): compute full FF-A V1.1 desc size

This patch fixes an issue in spmc_ffa_fill_desc.

In order to compute the spmc_shm_get_v1_1_descriptor_size,
fragment_length which is a fraction of the descriptor size is used as
desc_size parameter. It has to be replaced with the
full V1.0 descriptor size(obj->desc_filled).

Ran a subset of our tests and they are passing.

Change-Id: Ia4bbc5dabf0b77fa53d923ff609ee48ecd5bf549
Signed-off-by: vallau01 <valentin.laurent@trustonic.com>
Signed-off-by: Lukas Hanel <lukas.hanel@trustonic.com>
2 years agoMerge "feat(imx8mm): add BL31 PIE support" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:16:07 +0000 (15:16 +0100)]
Merge "feat(imx8mm): add BL31 PIE support" into integration

2 years agoMerge "refactor(imx8mm): introduce BL2_SIZE and BL31_SIZE" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:16:03 +0000 (15:16 +0100)]
Merge "refactor(imx8mm): introduce BL2_SIZE and BL31_SIZE" into integration

2 years agoMerge "refactor(imx8mm): make use of setup_page_tables()" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:15:52 +0000 (15:15 +0100)]
Merge "refactor(imx8mm): make use of setup_page_tables()" into integration

2 years agoMerge "refactor(imx8mm): cleanup the mmap region settings" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:15:45 +0000 (15:15 +0100)]
Merge "refactor(imx8mm): cleanup the mmap region settings" into integration

2 years agoMerge "feat(imx8mn): add BL31 PIE support" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:15:04 +0000 (15:15 +0100)]
Merge "feat(imx8mn): add BL31 PIE support" into integration

2 years agoMerge "refactor(imx8mn): introduce BL31_SIZE" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:58 +0000 (15:14 +0100)]
Merge "refactor(imx8mn): introduce BL31_SIZE" into integration

2 years agoMerge "refactor(imx8mn): make use of setup_page_tables()" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:53 +0000 (15:14 +0100)]
Merge "refactor(imx8mn): make use of setup_page_tables()" into integration

2 years agoMerge "refactor(imx8mn): cleanup the mmap region settings" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:48 +0000 (15:14 +0100)]
Merge "refactor(imx8mn): cleanup the mmap region settings" into integration

2 years agoMerge "feat(imx8mp): add BL31 PIE support" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:41 +0000 (15:14 +0100)]
Merge "feat(imx8mp): add BL31 PIE support" into integration

2 years agoMerge "refactor(imx8mp): introduce BL2_SIZE and BL31_SIZE" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:36 +0000 (15:14 +0100)]
Merge "refactor(imx8mp): introduce BL2_SIZE and BL31_SIZE" into integration

2 years agoMerge "refactor(imx8mp): make use of setup_page_tables()" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:30 +0000 (15:14 +0100)]
Merge "refactor(imx8mp): make use of setup_page_tables()" into integration

2 years agoMerge "refactor(imx8mp): cleanup the mmap region settings" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:25 +0000 (15:14 +0100)]
Merge "refactor(imx8mp): cleanup the mmap region settings" into integration

2 years agoMerge "feat(imx8m): make psci common code pie compatible" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:16 +0000 (15:14 +0100)]
Merge "feat(imx8m): make psci common code pie compatible" into integration

2 years agoMerge "fix(imx8m): fix dram retention fsp_table access" into integration
Madhukar Pappireddy [Tue, 1 Nov 2022 14:14:10 +0000 (15:14 +0100)]
Merge "fix(imx8m): fix dram retention fsp_table access" into integration

2 years agoMerge "fix(mediatek): switch console to runtime state before leaving BL31" into integ...
Manish Pandey [Tue, 1 Nov 2022 11:44:02 +0000 (12:44 +0100)]
Merge "fix(mediatek): switch console to runtime state before leaving BL31" into integration

2 years agochore(docs): update supported FVP models doc
laurenw-arm [Wed, 14 Sep 2022 20:44:42 +0000 (15:44 -0500)]
chore(docs): update supported FVP models doc

Update supported models list according to changes for v2.8 release in
ci/tf-a-ci-scripts repository

Signed-off-by: Lauren Wehrmeister <lauren.wehrmeister@arm.com>
Change-Id: Ica7e062db77237220bcd861837f392496db1653a

2 years agoMerge "build: deprecate Arm rdn1edge and sgi575 FVP platforms" into integration
Manish Pandey [Mon, 31 Oct 2022 10:23:45 +0000 (11:23 +0100)]
Merge "build: deprecate Arm rdn1edge and sgi575 FVP platforms" into integration

2 years agoMerge changes from topic "db/deps" into integration
Manish V Badarkhe [Fri, 28 Oct 2022 13:56:28 +0000 (15:56 +0200)]
Merge changes from topic "db/deps" into integration

* changes:
  feat(compiler-rt): update compiler-rt source files
  fix(deps): add missing aeabi_memcpy.S
  feat(zlib): update zlib source files
  docs(changelog): add zlib and compiler-rt scope
  feat(libfdt): upgrade libfdt source files
  docs(prerequisites): upgrade to Mbed TLS 2.28.1

2 years agoMerge changes from topic "ffa_el3_spmc" into integration
Olivier Deprez [Fri, 28 Oct 2022 08:22:39 +0000 (10:22 +0200)]
Merge changes from topic "ffa_el3_spmc" into integration

* changes:
  docs(spm): add threat model for el3 spmc
  docs(spm): add design documentation

2 years agoMerge "fix(aarch64): make AArch64 FGT feature detection more robust" into integration
Sandrine Bailleux [Fri, 28 Oct 2022 06:15:46 +0000 (08:15 +0200)]
Merge "fix(aarch64): make AArch64 FGT feature detection more robust" into integration

2 years agoMerge changes I7d3a97df,I5935b4bc,I9a325c5b,Ie29bd3a5,Iebb90cf2 into integration
Bipin Ravi [Thu, 27 Oct 2022 17:21:46 +0000 (19:21 +0200)]
Merge changes I7d3a97df,I5935b4bc,I9a325c5b,Ie29bd3a5,Iebb90cf2 into integration

* changes:
  fix(cpus): workaround for Cortex-A710 erratum 2291219
  fix(cpus): workaround for Cortex-X3 erratum 2313909
  fix(cpus): workaround for Neoverse-N2 erratum 2326639
  fix(rpi3): tighten platform pwr_domain_pwr_down_wfi behaviour
  chore: rename Makalu ELP to Cortex-X3

2 years agoMerge "fix(imx8m): update poweroff related SNVS_LPCR bits only" into integration
Madhukar Pappireddy [Thu, 27 Oct 2022 13:24:57 +0000 (15:24 +0200)]
Merge "fix(imx8m): update poweroff related SNVS_LPCR bits only" into integration

2 years agofix(cpus): workaround for Cortex-A710 erratum 2291219
Boyan Karatotev [Mon, 3 Oct 2022 13:21:28 +0000 (14:21 +0100)]
fix(cpus): workaround for Cortex-A710 erratum 2291219

Cortex-A710 erratum 2291219 is a Cat B erratum that applies to revisions
r0p0, r1p0, and r2p0, and is fixed in r2p1. The workaround is to set
CPUACTLR2_EL1[36] to 1 before the power down sequence that sets
CORE_PWRDN_EN. This allows the cpu to retry the power down and prevents
the deadlock. TF-A never clears this bit even if it wakes up from the
wfi in the sequence since it is not expected to do anything but retry to
power down after and the bit is cleared on reset.

SDEN can be found here:
https://developer.arm.com/documentation/SDEN1775101/latest

Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com>
Change-Id: I7d3a97dfac0c433c0be386c1f3d2f2e895a3f691

2 years agofix(cpus): workaround for Cortex-X3 erratum 2313909
Boyan Karatotev [Mon, 3 Oct 2022 13:18:28 +0000 (14:18 +0100)]
fix(cpus): workaround for Cortex-X3 erratum 2313909

Cortex-X3 erratum 2313909 is a Cat B erratum that applies to revisions
r0p0 and r1p0, and is fixed in r1p1. The workaround is to set
CPUACTLR2_EL1[36] to 1 before the power down sequence that sets
CORE_PWRDN_EN. This allows the cpu to retry the power down and prevents
the deadlock. TF-A never clears this bit even if it wakes up from the
wfi in the sequence since it is not expected to do anything but retry to
power down after and the bit is cleared on reset.

SDEN can be found here:
https://developer.arm.com/documentation/SDEN2055130/latest

Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com>
Change-Id: I5935b4bcd1e6712477c0d6eab2acc96d7964a35d

2 years agofix(cpus): workaround for Neoverse-N2 erratum 2326639
Boyan Karatotev [Mon, 3 Oct 2022 13:07:08 +0000 (14:07 +0100)]
fix(cpus): workaround for Neoverse-N2 erratum 2326639

Neoverse-N2 erratum 2326639 is a Cat B erratum that applies to revision
r0p0 and is fixed in r0p1. The workaround is to set CPUACTLR2_EL1[36] to
1 before the power down sequence that sets CORE_PWRDN_EN. This allows
the cpu to retry the power down and prevents the deadlock. TF-A never
clears this bit even if it wakes up from the wfi in the sequence since
it is not expected to do anything but retry to power down after and the
bit is cleared on reset.

SDEN can be found here:
https://developer.arm.com/documentation/SDEN1982442/latest/

Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com>
Change-Id: I9a325c5b9b498798e5efd5c79a4a6d5bed97c619

2 years agofix(rpi3): tighten platform pwr_domain_pwr_down_wfi behaviour
Boyan Karatotev [Wed, 5 Oct 2022 12:41:56 +0000 (13:41 +0100)]
fix(rpi3): tighten platform pwr_domain_pwr_down_wfi behaviour

Platforms which implement pwr_domain_pwr_down_wfi differ substantially
in behaviour. However, different cpus require similar sequences to power
down. This patch tightens the behaviour of these platforms to end on a
wfi loop after performing platform power down. This is required so that
platforms behave more consistently on power down, in cases where the wfi
can fall through.

Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com>
Change-Id: Ie29bd3a5e654780bacb4e07a6d123ac6d2467c1f

2 years agodocs(spm): add threat model for el3 spmc
Shruti Gupta [Tue, 27 Sep 2022 13:21:13 +0000 (14:21 +0100)]
docs(spm): add threat model for el3 spmc

Threat model for EL3 SPMC.
The mitigations are based on the guidance
provided in FF-A v1.1 EAC0 spec.

Signed-off-by: Shruti Gupta <shruti.gupta@arm.com>
Change-Id: I7f4c9370b6eefe6d1a7d1afac27e8b3a7b476072

2 years agodocs(spm): add design documentation
Shruti Gupta [Tue, 20 Sep 2022 08:53:53 +0000 (09:53 +0100)]
docs(spm): add design documentation

Add documentation how to build EL3 SPMC,
briefly describes all FF-A interfaces,
SP boot flow, SP Manifest, Power Management,
Boot Info Protocol, Runtime model and state
transition and Interrupt Handling.

Signed-off-by: Shruti Gupta <shruti.gupta@arm.com>
Change-Id: I630df1d50a4621b344a09e462563eacc90109de4

2 years agochore: rename Makalu ELP to Cortex-X3
Boyan Karatotev [Tue, 25 Oct 2022 10:29:04 +0000 (11:29 +0100)]
chore: rename Makalu ELP to Cortex-X3

The Cortex-X3 cpu port was developed before its public release when it
was known as Makalu ELP. Now that it's released we can use the official
product name.

Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com>
Change-Id: Iebb90cf2f77330ed848a3d61c5f6928942189c5a

2 years agoMerge "fix(security): optimisations for CVE-2022-23960" into integration
Lauren Wehrmeister [Wed, 26 Oct 2022 22:00:11 +0000 (00:00 +0200)]
Merge "fix(security): optimisations for CVE-2022-23960" into integration

2 years agofix(security): optimisations for CVE-2022-23960
Bipin Ravi [Thu, 13 Oct 2022 22:25:51 +0000 (17:25 -0500)]
fix(security): optimisations for CVE-2022-23960

Optimised the loop workaround for Spectre_BHB mitigation:
1. use of speculation barrier for cores implementing SB instruction.
2. use str/ldr instead of stp/ldp as the loop uses only X2 register.

Signed-off-by: Bipin Ravi <bipin.ravi@arm.com>
Change-Id: I8ac53ea1e42407ad8004c1d59c05f791011f195d

2 years agofix(mediatek): switch console to runtime state before leaving BL31
Rex-BC Chen [Wed, 26 Oct 2022 09:26:05 +0000 (17:26 +0800)]
fix(mediatek): switch console to runtime state before leaving BL31

We should switch console to runtime state. If we don't do this, the
state will keep boot state even we exit from BL31.

Signed-off-by: Bo-Chen Chen <rex-bc.chen@mediatek.com>
Change-Id: Id2269ccf2fdc22e0fa088c3c0365836730172233

2 years agoMerge "fix(sme): add missing ISBs" into integration
Manish Pandey [Wed, 26 Oct 2022 12:27:43 +0000 (14:27 +0200)]
Merge "fix(sme): add missing ISBs" into integration

2 years agofix(imx8m): update poweroff related SNVS_LPCR bits only
Shawn Guo [Wed, 26 Oct 2022 08:38:53 +0000 (16:38 +0800)]
fix(imx8m): update poweroff related SNVS_LPCR bits only

Function imx_system_off() writes SNVS_LPCR register to power off the SoC
without bit masking.  This clears other bits like LPWUI_EN and breaks
the function of SoC wake-up using RTC alarm.  Fix it by updating poweroff
related bits only.

Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Change-Id: If641af4dc1103c67e1a645c03bb36a5f56665aef

2 years agoMerge "fix(gicv3/multichip): fix overflow caused by left shift" into integration
Manish V Badarkhe [Wed, 26 Oct 2022 07:45:24 +0000 (09:45 +0200)]
Merge "fix(gicv3/multichip): fix overflow caused by left shift" into integration

2 years agoMerge "fix(stm32mp13-fdts): correct PLL nodes name" into integration
Madhukar Pappireddy [Mon, 24 Oct 2022 19:41:31 +0000 (21:41 +0200)]
Merge "fix(stm32mp13-fdts): correct PLL nodes name" into integration

2 years agofix(build): fix arch32 build issue for clang
Arvind Ram Prakash [Wed, 19 Oct 2022 20:44:51 +0000 (15:44 -0500)]
fix(build): fix arch32 build issue for clang

Fixed the qemu 32 bit clang build fail caused because of
no march32 directives in TF_CFLAGS_aarch32 variable

march32_directive is initialized later in Makefile and since clang build
uses Immediate set instead of Lazy set , TF_CFLAGS_aarch32 doesn't
have mcpu variable.

Signed-off-by: Arvind Ram Prakash <arvind.ramprakash@arm.com>
Change-Id: I09094a0912ee2d9d0e11f65135a352de8a135936