1. 03 Aug, 2021 1 commit
  2. 02 Aug, 2021 5 commits
  3. 23 Jul, 2021 3 commits
  4. 20 Jul, 2021 1 commit
    • Pali Rohár's avatar
      feat(common/debug): add new macro ERROR_NL() to print just a newline · fd1360a3
      Pali Rohár authored
      
      
      Existing macro ERROR() prints string "ERROR" followed by string
      specified by caller. Therefore via this existing macro it is not
      possible to end incomplete / existing line by a newline character.
      
      This change adds a new macro ERROR_NL() which prints just a newline
      character without any prefix. Implementation of this macro is done via a
      new function tf_log_newline() which based on supplied log level either
      return or print newline character.
      
      If needed in future based on this tf_log_newline() function can be
      defined also macros for other log levels.
      Signed-off-by: default avatarPali Rohár <pali@kernel.org>
      Change-Id: I05414ca177f94cdc0f6077394d9c4af4a4382306
      fd1360a3
  5. 16 Jul, 2021 1 commit
  6. 09 Jul, 2021 1 commit
  7. 29 Jun, 2021 1 commit
  8. 28 Jun, 2021 1 commit
    • Max Shvetsov's avatar
      feat(sve): enable SVE for the secure world · 0c5e7d1c
      Max Shvetsov authored
      
      
      Enables SVE support for the secure world via ENABLE_SVE_FOR_SWD.
      ENABLE_SVE_FOR_SWD defaults to 0 and has to be explicitly set by the
      platform. SVE is configured during initial setup and then uses EL3
      context save/restore routine to switch between SVE configurations for
      different contexts.
      Reset value of CPTR_EL3 changed to be most restrictive by default.
      Signed-off-by: default avatarMax Shvetsov <maksims.svecovs@arm.com>
      Change-Id: I889fbbc2e435435d66779b73a2d90d1188bf4116
      0c5e7d1c
  9. 23 Jun, 2021 2 commits
  10. 22 Jun, 2021 1 commit
    • Chris Kay's avatar
      refactor(aarch64): remove `FEAT_BTI` architecture check · 4429b471
      Chris Kay authored
      
      
      BTI instructions are a part of the NOP space in earlier architecture
      versions, so it's not inherently incorrect to enable BTI code
      or instructions even if the target architecture does not support them.
      
      This change reduces our reliance on architecture versions when checking
      for features.
      
      Change-Id: I79f884eec3d65978c61e72e4268021040fd6c96e
      Signed-off-by: default avatarChris Kay <chris.kay@arm.com>
      4429b471
  11. 14 Jun, 2021 1 commit
  12. 04 Jun, 2021 2 commits
  13. 02 Jun, 2021 1 commit
    • Pali Rohár's avatar
      fix(plat/marvell/a3720/uart): fix UART parent clock rate determination · 5a91c439
      Pali Rohár authored
      
      
      The UART code for the A3K platform assumes that UART parent clock rate
      is always 25 MHz. This is incorrect, because the xtal clock can also run
      at 40 MHz (this is board specific).
      
      The frequency of the xtal clock is determined by a value on a strapping
      pin during SOC reset. The code to determine this frequency is already in
      A3K's comphy driver.
      
      Move the get_ref_clk() function from the comphy driver to a separate
      file and use it for UART parent clock rate determination.
      Signed-off-by: default avatarPali Rohár <pali@kernel.org>
      Change-Id: I8bb18a2d020ef18fe65aa06ffa4ab205c71be92e
      5a91c439
  14. 28 May, 2021 1 commit
  15. 27 May, 2021 2 commits
  16. 25 May, 2021 1 commit
  17. 19 May, 2021 1 commit
    • Manish V Badarkhe's avatar
      feat(hw_crc): add support for HW computed CRC · a1cedadf
      Manish V Badarkhe authored
      
      
      Added support for HW computed CRC using Arm ACLE intrinsics.
      These are built-in intrinsics available for ARMv8.1-A, and
      onwards.
      These intrinsics are enabled via '-march=armv8-a+crc' compile
      switch for ARMv8-A (supports CRC instructions optionally).
      
      HW CRC support is enabled unconditionally in BL2 for all Arm
      platforms.
      
      HW CRC calculation is verified offline to ensure a similar
      result as its respective ZLib utility function.
      
      HW CRC calculation support will be used in the upcoming
      firmware update patches.
      
      Change-Id: Ia2ae801f62d2003e89a9c3e6d77469b5312614b3
      Signed-off-by: default avatarManish V Badarkhe <Manish.Badarkhe@arm.com>
      a1cedadf
  18. 17 May, 2021 1 commit
  19. 14 May, 2021 1 commit
    • Alexei Fedorov's avatar
      fix(security): Set MDCR_EL3.MCCD bit · 12f6c064
      Alexei Fedorov authored
      
      
      This patch adds setting MDCR_EL3.MCCD in 'el3_arch_init_common'
      macro to disable cycle counting by PMCCNTR_EL0 in EL3 when
      FEAT_PMUv3p7 is implemented. This fixes failing test
      'Leak PMU CYCLE counter values from EL3 on PSCI suspend SMC'
      on FVP models with 'has_v8_7_pmu_extension' parameter set to
      1 or 2.
      Signed-off-by: default avatarAlexei Fedorov <Alexei.Fedorov@arm.com>
      Change-Id: I2ad3ef501b31ee11306f76cb5a61032ecfd0fbda
      12f6c064
  20. 13 May, 2021 1 commit
    • Daniel Boulby's avatar
      feat(spmd): add support for FFA_SPM_ID_GET · 70c121a2
      Daniel Boulby authored
      
      
      Handle calls to the FFA_SPM_ID_GET interface. If FFA_SPM_ID_GET is
      invoked from the non-secure physical FF-A instance, return the SPMC id
      (defined in the SPMC manifest). If FFA_SPM_ID_GET is invoked from
      the secure physical FF-A instance (e.g. the SPMC), return the SPMD id.
      
      Change-Id: Id6d4e96b1da2510386d344e09c4553dba01227ec
      Signed-off-by: default avatarDaniel Boulby <daniel.boulby@arm.com>
      70c121a2
  21. 29 Apr, 2021 1 commit
  22. 28 Apr, 2021 3 commits
    • David Horstmann's avatar
      refactor(plat/arm): store UUID as a string, rather than ints · 7d111d99
      David Horstmann authored
      
      
      NOTE: Breaking change to the way UUIDs are stored in the DT
      
      Currently, UUIDs are stored in the device tree as
      sequences of 4 integers. There is a mismatch in endianness
      between the way UUIDs are represented in memory and the way
      they are parsed from the device tree. As a result, we must either
      store the UUIDs in little-endian format in the DT (which means
      that they do not match up with their string representations)
      or perform endianness conversion after parsing them.
      
      Currently, TF-A chooses the second option, with unwieldy
      endianness-conversion taking place after reading a UUID.
      
      To fix this problem, and to make it convenient to copy and
      paste UUIDs from other tools, change to store UUIDs in string
      format, using a new wrapper function to parse them from the
      device tree.
      
      Change-Id: I38bd63c907be14e412f03ef0aab9dcabfba0eaa0
      Signed-off-by: default avatarDavid Horstmann <david.horstmann@arm.com>
      7d111d99
    • David Horstmann's avatar
      feat(fdt): introduce wrapper function to read DT UUIDs · d13dbb6f
      David Horstmann authored
      
      
      TF-A does not have the capability to read UUIDs in string form
      from the device tree. This capability is useful for readability,
      so add a wrapper function, fdtw_read_uuid() to parse UUIDs from
      the DT.
      This function should parse a string of the form:
      
      "aabbccdd-eeff-4099-8877-665544332211"
      
      to the byte sequence in memory:
      
      [aa bb cc dd ee ff 40 99 88 77 66 55 44 33 22 11]
      
      Change-Id: I99a92fbeb40f4f4713f3458b36cb3863354d2bdf
      Signed-off-by: default avatarDavid Horstmann <david.horstmann@arm.com>
      d13dbb6f
    • Manish V Badarkhe's avatar
      refactor(plat/arm): replace FIP base and size macro with a generic name · 49e9ac28
      Manish V Badarkhe authored
      
      
      Replaced PLAT_ARM_FIP_BASE and PLAT_ARM_FIP_MAX_SIZE macro with a
      generic name PLAT_ARM_FLASH_IMAGE_BASE and PLAT_ARM_FLASH_IMAGE_MAX_SIZE
      so that these macros can be reused in the subsequent GPT based support
      changes.
      
      Change-Id: I88fdbd53e1966578af4f1e8e9d5fef42c27b1173
      Signed-off-by: default avatarManish V Badarkhe <Manish.Badarkhe@arm.com>
      49e9ac28
  23. 27 Apr, 2021 1 commit
  24. 26 Apr, 2021 1 commit
    • Chris Kay's avatar
      docs(license): rectify `arm-gic.h` license · 3dbbbca2
      Chris Kay authored
      
      
      The `arm-gic.h` file distributed by the Linux kernel is disjunctively
      dual-licensed under the GPL-2.0 or MIT licenses, but the BSD-3-Clause
      license has been applied in violation of the requirements of both
      licenses. This change ensures the file is correctly licensed under the
      terms of the MIT license, and that we comply with it by distributing a
      copy of the license text.
      
      Change-Id: Ie90066753a5eb8c0e2fc95ba43e3f5bcbe2fa459
      Signed-off-by: default avatarChris Kay <chris.kay@arm.com>
      3dbbbca2
  25. 21 Apr, 2021 3 commits
    • Yann Gautier's avatar
      Add PIE support for AARCH32 · 4324a14b
      Yann Gautier authored
      
      
      Only BL32 (SP_min) is supported at the moment, BL1 and BL2_AT_EL3 are just
      stubbed with _pie_fixup_size=0.
      The changes are an adaptation for AARCH32 on what has been done for
      PIE support on AARCH64.
      The RELA_SECTION is redefined for AARCH32, as the created section is
      .rel.dyn and the symbols are .rel*.
      
      Change-Id: I92bafe70e6b77735f6f890f32f2b637b98cf01b9
      Signed-off-by: default avatarYann Gautier <yann.gautier@st.com>
      4324a14b
    • Yann Gautier's avatar
      Avoid the use of linker *_SIZE__ macros · fb4f511f
      Yann Gautier authored
      The use of end addresses is preferred over the size of sections.
      This was done for some AARCH64 files for PIE with commit [1],
      and some extra explanations can be found in its commit message.
      Align the missing AARCH64 files.
      
      For AARCH32 files, this is required to prepare PIE support introduction.
      
       [1] f1722b69
      
       ("PIE: Use PC relative adrp/adr for symbol reference")
      
      Change-Id: I8f1c06580182b10c680310850f72904e58a54d7d
      Signed-off-by: default avatarYann Gautier <yann.gautier@st.com>
      fb4f511f
    • Alexei Fedorov's avatar
      Plat FVP: Fix Generic Timer interrupt types · dfa6c540
      Alexei Fedorov authored
      
      
      The Arm Generic Timer specification mandates that the
      interrupt associated with each timer is low level triggered,
      see:
      
      Arm Cortex-A76 Core:
      "Each timer provides an active-LOW interrupt output to the SoC."
      
      Arm Cortex-A53 MPCore Processor:
      "It generates timer events as active-LOW interrupt outputs and
      event streams."
      
      The following files in fdts\
      
      fvp-base-gicv3-psci-common.dtsi
      fvp-base-gicv3-psci-aarch32-common.dtsi
      fvp-base-gicv2-psci-aarch32.dts
      fvp-base-gicv2-psci.dts
      fvp-foundation-gicv2-psci.dts
      fvp-foundation-gicv3-psci.dts
      
      describe interrupt types as edge rising
      IRQ_TYPE_EDGE_RISING = 0x01:
      
      interrupts = <1 13 0xff01>,
                   <1 14 0xff01>,
                   <1 11 0xff01>,
                   <1 10 0xff01>;
      
      , see include\dt-bindings\interrupt-controller\arm-gic.h:
      
      which causes Linux to generate the warnings below:
      arch_timer: WARNING: Invalid trigger for IRQ5, assuming level low
      arch_timer: WARNING: Please fix your firmware
      
      This patch adds GIC_CPU_MASK_RAW macro definition to
      include\dt-bindings\interrupt-controller\arm-gic.h,
      modifies interrupt type to IRQ_TYPE_LEVEL_LOW and
      makes use of type definitions in arm-gic.h.
      
      Change-Id: Iafa2552a9db85a0559c73353f854e2e0066ab2b9
      Signed-off-by: default avatarAlexei Fedorov <Alexei.Fedorov@arm.com>
      dfa6c540
  26. 20 Apr, 2021 2 commits
    • johpow01's avatar
      Add "_arm" suffix to Makalu ELP CPU lib · 97bc7f0d
      johpow01 authored
      
      
      ELP processors can sometimes have different MIDR values or features so
      we are adding the "_arm" suffix to differentiate the reference
      implementation from other future versions.
      Signed-off-by: default avatarJohn Powell <john.powell@arm.com>
      Change-Id: Ieea444288587c7c18a397d279ee4b22b7ad79e20
      97bc7f0d
    • Mikael Olsson's avatar
      Add SiP service to configure Arm Ethos-N NPU · 76a21174
      Mikael Olsson authored
      
      
      By default the Arm Ethos-N NPU will boot up in secure mode. In this mode
      the non-secure world cannot access the registers needed to use the NPU.
      To still allow the non-secure world to use the NPU, a SiP service has
      been added that can delegate non-secure access to the registers needed
      to use it.
      
      Only the HW_CONFIG for the Arm Juno platform has been updated to include
      the device tree for the NPU and the platform currently only loads the
      HW_CONFIG in AArch64 builds.
      Signed-off-by: default avatarMikael Olsson <mikael.olsson@arm.com>
      Change-Id: I65dfd864042ed43faae0a259dcf319cbadb5f3d2
      76a21174