1. 15 Sep, 2020 1 commit
  2. 14 Sep, 2020 1 commit
    • Andre Przywara's avatar
      SPE: Fix feature detection · b8535929
      Andre Przywara authored
      
      
      Currently the feature test for the SPE extension requires the feature
      bits in the ID_AA64DFR0 register to read exactly 0b0001.
      However the architecture guarantees that any values greater than 0
      indicate the presence of a feature, which is what we are after in
      our spe_supported() function.
      
      Change the comparison to include all values greater than 0.
      
      This fixes SPE support in non-secure world on implementations which
      include the Scalable Vector Extension (SVE), for instance on Zeus cores.
      
      Change-Id: If6cbd1b72d6abb8a303e2c0a7839d508f071cdbe
      Signed-off-by: default avatarAndre Przywara <andre.przywara@arm.com>
      b8535929
  3. 11 Sep, 2020 1 commit
  4. 10 Sep, 2020 1 commit
  5. 09 Sep, 2020 1 commit
  6. 03 Sep, 2020 2 commits
    • Andre Przywara's avatar
      libc: memset: improve performance by avoiding single byte writes · 75fab649
      Andre Przywara authored
      
      
      Currently our memset() implementation is safe, but slow. The main reason
      for that seems to be the single byte writes that it issues, which can
      show horrible performance, depending on the implementation of the
      load/store subsystem.
      
      Improve the algorithm by trying to issue 64-bit writes. As this only
      works with aligned pointers, have a head and a tail section which
      covers unaligned pointers, and leave the bulk of the work to the middle
      section that does use 64-bit writes.
      
      Put through some unit tests, which exercise all combinations of nasty
      input parameters (pointers with various alignments, various odd and even
      sizes, corner cases of content to write (-1, 256)).
      
      Change-Id: I28ddd3d388cc4989030f1a70447581985368d5bb
      Signed-off-by: default avatarAndre Przywara <andre.przywara@arm.com>
      75fab649
    • Sandeep Tripathy's avatar
      psci: utility api to invoke stop for other cores · 22744909
      Sandeep Tripathy authored
      
      
      The API can be used to invoke a 'stop_func' callback for all
      other cores from any initiating core. Optionally it can also
      wait for other cores to power down. There may be various use
      of such API by platform. Ex: Platform may use this to power
      down all other cores from a crashed core.
      Signed-off-by: default avatarSandeep Tripathy <sandeep.tripathy@broadcom.com>
      Change-Id: I4f9dc8a38d419f299c021535d5f1bcc6883106f9
      22744909
  7. 02 Sep, 2020 1 commit
    • Pramod Kumar's avatar
      lib: cpu: Check SCU presence in DSU before accessing DSU registers · 942013e1
      Pramod Kumar authored
      
      
      The DSU contains system control registers in the SCU and L3 logic to
      control the functionality of the cluster. If "DIRECT CONNECT" L3
      memory system variant is used, there won't be any L3 cache,
      snoop filter, and SCU logic present hence no system control register
      will be present. Hence check SCU presence before accessing DSU register
      for DSU_936184 errata.
      Signed-off-by: default avatarPramod Kumar <pramod.kumar@broadcom.com>
      Change-Id: I1ffa8afb0447ae3bd1032c9dd678d68021fe5a63
      942013e1
  8. 31 Aug, 2020 3 commits
  9. 26 Aug, 2020 1 commit
  10. 24 Aug, 2020 1 commit
    • Varun Wadekar's avatar
      lib: cpus: sanity check pointers before use · 601e3ed2
      Varun Wadekar authored
      
      
      The cpu_ops structure contains a lot of function pointers. It
      is a good idea to verify that the function pointer is not NULL
      before executing it.
      
      This patch sanity checks each pointer before use to prevent any
      unforeseen crashes. These checks have been enabled for debug
      builds only.
      
      Change-Id: Ib208331c20e60f0c7c582a20eb3d8cc40fb99d21
      Signed-off-by: default avatarVarun Wadekar <vwadekar@nvidia.com>
      601e3ed2
  11. 21 Aug, 2020 1 commit
  12. 19 Aug, 2020 2 commits
    • Alexei Fedorov's avatar
      libc/memset: Implement function in assembler · e7d344de
      Alexei Fedorov authored
      
      
      Trace analysis of FVP_Base_AEMv8A model running in
      Aarch32 mode with the build options listed below:
      TRUSTED_BOARD_BOOT=1 GENERATE_COT=1
      ARM_ROTPK_LOCATION=devel_ecdsa KEY_ALG=ecdsa
      ROT_KEY=plat/arm/board/common/rotpk/arm_rotprivk_ecdsa.pem
      shows that when auth_signature() gets called
      71.84% of CPU execution time is spent in memset() function
      written in C using single byte write operations,
      see lib\libc\memset.c.
      This patch replaces C memset() implementation with assembler
      version giving the following results:
      - for Aarch32 in auth_signature() call memset() CPU time
      reduced to 24.84%.
      - Number of CPU instructions executed during TF-A
      boot stage before start of BL33 in RELEASE builds:
      ----------------------------------------------
      |  Arch   |     C      |  assembler |    %   |
      ----------------------------------------------
      | Aarch32 | 2073275460 | 1487400003 | -28.25 |
      | Aarch64 | 2056807158 | 1244898303 | -39.47 |
      ----------------------------------------------
      The patch also replaces memset.c with aarch64/memset.S
      in plat\nvidia\tegra\platform.mk.
      
      Change-Id: Ifbf085a2f577a25491e2d28446ee95a4ac891597
      Signed-off-by: default avatarAlexei Fedorov <Alexei.Fedorov@arm.com>
      e7d344de
    • Ruari Phipps's avatar
      SPM: Change condition on saving/restoring EL2 registers · 6b704da3
      Ruari Phipps authored
      
      
      Make this more scalable by explicitly checking internal and hardware
      states at run_time
      Signed-off-by: default avatarRuari Phipps <ruari.phipps@arm.com>
      Change-Id: I1c6ed1c1badb3538a93bff3ac5b5189b59cccfa1
      6b704da3
  13. 18 Aug, 2020 4 commits
  14. 13 Aug, 2020 1 commit
    • Olivier Deprez's avatar
      TF-A AMU: remove AMU enable info print · e82eb8c8
      Olivier Deprez authored
      Following f3ccf036
      
       the INFO print in amu_enable is causing
      a lot of print outs on UART1 in DEBUG mode especially on PSCI test
      cases because CPU_ON or SUSPEND operations call:
      cm_prepare_el3_exit => enable_extensions_nonsecure => amu_enable.
      PSCI SUSPEND is also very frequent in linux boot cases causing test
      timeout failures.
      Signed-off-by: default avatarOlivier Deprez <olivier.deprez@arm.com>
      Change-Id: I63581f8fa489d44b3b1d10af3b7f6fdf3af44720
      e82eb8c8
  15. 12 Aug, 2020 1 commit
    • Manish Pandey's avatar
      cert_create: add Platform owned secure partitions support · 23d5f03a
      Manish Pandey authored
      
      
      Add support to generate a certificate named "plat-sp-cert" for Secure
      Partitions(SP) owned by Platform.
      Earlier a single certificate file "sip-sp-cert" was generated which
      contained hash of all 8 SPs, with this change SPs are divided into
      two categories viz "SiP owned" and "Plat owned" containing 4 SPs each.
      
      Platform RoT key pair is used for signing.
      Signed-off-by: default avatarManish Pandey <manish.pandey2@arm.com>
      Change-Id: I5bd493cfce4cf3fc14b87c8ed1045f633d0c92b6
      23d5f03a
  16. 10 Aug, 2020 1 commit
    • Alexei Fedorov's avatar
      TF-A AMU extension: fix detection of group 1 counters. · f3ccf036
      Alexei Fedorov authored
      
      
      This patch fixes the bug when AMUv1 group1 counters was
      always assumed being implemented without checking for its
      presence which was causing exception otherwise.
      The AMU extension code was also modified as listed below:
      - Added detection of AMUv1 for ARMv8.6
      - 'PLAT_AMU_GROUP1_NR_COUNTERS' build option is removed and
      number of group1 counters 'AMU_GROUP1_NR_COUNTERS' is now
      calculated based on 'AMU_GROUP1_COUNTERS_MASK' value
      - Added bit fields definitions and access functions for
      AMCFGR_EL0/AMCFGR and AMCGCR_EL0/AMCGCR registers
      - Unification of amu.c Aarch64 and Aarch32 source files
      - Bug fixes and TF-A coding style compliant changes.
      
      Change-Id: I14e407be62c3026ebc674ec7045e240ccb71e1fb
      Signed-off-by: default avatarAlexei Fedorov <Alexei.Fedorov@arm.com>
      f3ccf036
  17. 09 Aug, 2020 2 commits
  18. 08 Aug, 2020 1 commit
    • johpow01's avatar
      MISRA cleanup in mem_region and semihosting files · 633fa4cd
      johpow01 authored
      
      
      MISRA defect cleanup and general code cleanup in mem_region.c and
      semihosting.c.  This task also called for cleanup of the ARM NOR flash
      driver but that was removed at some point since the Jira task was
      created.  This patch fixes all MISRA defects in these files except for a
      few "Calling function "console_flush()" which returns error information
      without testing the error information." errors which can't really be
      avoided.
      
      Defects Fixed
      
      File                           Line Rule
      lib/semihosting/semihosting.c  70   MISRA C-2012 Rule 14.4 (required)
      lib/semihosting/semihosting.c  197  MISRA C-2012 Rule 14.3 (required)
      lib/semihosting/semihosting.c  210  MISRA C-2012 Rule 14.4 (required)
      lib/utils/mem_region.c         128  MISRA C-2012 Rule 12.1 (advisory)
      Signed-off-by: default avatarJohn Powell <john.powell@arm.com>
      Change-Id: I21a039d1cfccd6aa4301da09daec15e373305a80
      633fa4cd
  19. 04 Aug, 2020 1 commit
    • Grant Likely's avatar
      Use abspath to dereference $BUILD_BASE · 29214e95
      Grant Likely authored
      
      
      If the user tries to change BUILD_BASE to put the build products outside
      the build tree the compile will fail due to hard coded assumptions that
      $BUILD_BASE is a relative path. Fix by using $(abspath $(BUILD_BASE))
      to rationalize to an absolute path every time and remove the relative
      path assumptions.
      
      This patch also adds documentation that BUILD_BASE can be specified by
      the user.
      Signed-off-by: default avatarGrant Likely <grant.likely@arm.com>
      Signed-off-by: default avatarManish Pandey <manish.pandey2@arm.com>
      Change-Id: Ib1af874de658484aaffc672f30029b852d2489c8
      29214e95
  20. 29 Jul, 2020 1 commit
  21. 23 Jul, 2020 4 commits
  22. 21 Jul, 2020 1 commit
  23. 27 Jun, 2020 1 commit
  24. 25 Jun, 2020 3 commits
  25. 24 Jun, 2020 3 commits