1. 18 Jan, 2019 4 commits
    • Anthony Zhou's avatar
      Tegra: common: drivers: fix MISRA defects · 61beb3e0
      Anthony Zhou authored
      
      
      Main fixes:
      
      Add suffix U for constant [Rule 10.1]
      
      Match the operands type [Rule 10.4]
      
      Use UL replace U for that constant define that need do "~"
      operation [Rule 12.4]
      
      Voided non c-library functions whose return types are not used
       [Rule 17.7]
      
      Change-Id: Ia1e814ca3890eab7904be9c79030502408f30936
      Signed-off-by: default avatarAnthony Zhou <anzhou@nvidia.com>
      61beb3e0
    • Anthony Zhou's avatar
      Tegra: pm: fix MISRA defects · b36aea5a
      Anthony Zhou authored
      
      
      Main fixes:
      
      * Use int32_t replace int, use uint32_t replace unsign int
        [Rule 4.6]
      * Add function define to header file [Rule 8.4]
      * Added curly braces ({}) around if statements in order to
        make them compound [Rule 15.6]
      * Voided non c-library functions whose return types are not used
        [Rule 17.7]
      
      Change-Id: Ifa3ba4e75046697cfede885096bee9a30efe6519
      Signed-off-by: default avatarAnthony Zhou <anzhou@nvidia.com>
      b36aea5a
    • Varun Wadekar's avatar
      Tegra: fix MISRA defects in tegra_bl31_setup.c · fcf23a14
      Varun Wadekar authored
      
      
      Main fixes:
      
      Add parentheses to avoid implicit operator precedence [Rule 12.1]
      
      Fixed if statement conditional to be essentially boolean [Rule 14.4]
      
      Added curly braces ({}) around if statements in order to
      make them compound [Rule 15.6]
      
      Voided non c-library functions whose return types are not used [Rule 17.7]
      
      Bug 200272157
      
      Change-Id: Ic3ab5a3de95aeb6d2265df940f7fb35ea0f19ab0
      Signed-off-by: default avatarAnthony Zhou <anzhou@nvidia.com>
      fcf23a14
    • Varun Wadekar's avatar
      Tegra: gpcdma: driver for general purpose DMA · 647d4a03
      Varun Wadekar authored
      
      
      This patch adds the driver for the general purpose DMA hardware
      block on newer Tegra SoCs. The GPCDMA is a special purpose DMA
      used to speed up memory copy operations to/from DRAM and TZSRAM.
      
      This patch introduces a macro 'USE_GPC_DMA' to allow platforms
      to override CPU based memory operations.
      
      Change-Id: I3170d409c83b77e785437b1002a8d70188fabbeb
      Signed-off-by: default avatarVarun Wadekar <vwadekar@nvidia.com>
      647d4a03
  2. 16 Jan, 2019 13 commits
  3. 04 Jan, 2019 1 commit
    • Antonio Nino Diaz's avatar
      Sanitise includes across codebase · 09d40e0e
      Antonio Nino Diaz authored
      Enforce full include path for includes. Deprecate old paths.
      
      The following folders inside include/lib have been left unchanged:
      
      - include/lib/cpus/${ARCH}
      - include/lib/el3_runtime/${ARCH}
      
      The reason for this change is that having a global namespace for
      includes isn't a good idea. It defeats one of the advantages of having
      folders and it introduces problems that are sometimes subtle (because
      you may not know the header you are actually including if there are two
      of them).
      
      For example, this patch had to be created because two headers were
      called the same way: e0ea0928 ("Fix gpio includes of mt8173 platform
      to avoid collision."). More recently, this patch has had similar
      problems: 46f9b2c3 ("drivers: add tzc380 support").
      
      This problem was introduced in commit 4ecca339
      
       ("Move include and
      source files to logical locations"). At that time, there weren't too
      many headers so it wasn't a real issue. However, time has shown that
      this creates problems.
      
      Platforms that want to preserve the way they include headers may add the
      removed paths to PLAT_INCLUDES, but this is discouraged.
      
      Change-Id: I39dc53ed98f9e297a5966e723d1936d6ccf2fc8f
      Signed-off-by: default avatarAntonio Nino Diaz <antonio.ninodiaz@arm.com>
      09d40e0e
  4. 18 Dec, 2018 1 commit
  5. 08 Nov, 2018 1 commit
    • Antonio Nino Diaz's avatar
      Standardise header guards across codebase · c3cf06f1
      Antonio Nino Diaz authored
      
      
      All identifiers, regardless of use, that start with two underscores are
      reserved. This means they can't be used in header guards.
      
      The style that this project is now to use the full name of the file in
      capital letters followed by 'H'. For example, for a file called
      "uart_example.h", the header guard is UART_EXAMPLE_H.
      
      The exceptions are files that are imported from other projects:
      
      - CryptoCell driver
      - dt-bindings folders
      - zlib headers
      
      Change-Id: I50561bf6c88b491ec440d0c8385c74650f3c106e
      Signed-off-by: default avatarAntonio Nino Diaz <antonio.ninodiaz@arm.com>
      c3cf06f1
  6. 28 Sep, 2018 1 commit
  7. 22 Aug, 2018 1 commit
  8. 17 Feb, 2018 1 commit
    • Andreas Färber's avatar
      tegra: Fix mmap_region_t struct mismatch · 28db3e96
      Andreas Färber authored
      Commit fdb1964c
      
       ("xlat: Introduce
      MAP_REGION2() macro") added a granularity field to mmap_region_t.
      
      Tegra platforms were using the v2 xlat_tables implementation in
      common/tegra_common.mk, but v1 xlat_tables.h headers in soc/*/plat_setup.c
      where arrays are being defined. This caused the next physical address to
      be read as granularity, causing EINVAL error and triggering an assert.
      
      Consistently use xlat_tables_v2.h header to avoid this.
      
      Fixes ARM-software/tf-issues#548.
      Signed-off-by: default avatarAndreas Färber <afaerber@suse.de>
      28db3e96
  9. 15 Jun, 2017 5 commits
    • Anthony Zhou's avatar
      Tegra186: mce: fix MISRA defects · ab712fd8
      Anthony Zhou authored
      
      
      Main fixes:
      
      * Added explicit casts (e.g. 0U) to integers in order for them to be
        compatible with whatever operation they're used in [Rule 10.1]
      * Force operands of an operator to the same type category [Rule 10.4]
      * Added curly braces ({}) around if/while statements in order to
        make them compound [Rule 15.6]
      * Added parentheses [Rule 12.1]
      * Voided non C-library functions whose return types are not used [Rule 17.7]
      
      Change-Id: I91404edec2e2194b1ce2672d2a3fc6a1f5bf41f1
      Signed-off-by: default avatarAnthony Zhou <anzhou@nvidia.com>
      Signed-off-by: default avatarVarun Wadekar <vwadekar@nvidia.com>
      ab712fd8
    • Varun Wadekar's avatar
      Tegra: gic: fix MISRA defects · 9a8f05e4
      Varun Wadekar authored
      
      
      Main fixes:
      
      * Use int32_t replace int, use uint32_t replace unsign int [Rule 4.6]
      * Added explicit casts (e.g. 0U) to integers in order for them to be
        compatible with whatever operation they're used in [Rule 10.1]
      * Force operands of an operator to the same type category [Rule 10.4]
      * Fixed assert/if statements conditions to be essentially boolean [Rule 14.4]
      * Added curly braces ({}) around if statements in order to
        make them compound [Rule 15.6]
      * Convert macros form headers to unsigned ints
      
      Change-Id: I8051cc16499cece2039c9751bd347645f40f0901
      Signed-off-by: default avatarAnthony Zhou <anzhou@nvidia.com>
      Signed-off-by: default avatarVarun Wadekar <vwadekar@nvidia.com>
      9a8f05e4
    • Anthony Zhou's avatar
      Tegra: pmc: fix defects flagged during MISRA analysis · 31d97dc2
      Anthony Zhou authored
      
      
      Main fixes:
      
      * Fixed if/while statement conditional to be essentially boolean [Rule 14.4]
      
      * Added curly braces ({}) around if/for/while statements in order to
        make them compound [Rule 15.6]
      
      * Added explicit casts (e.g. 0U) to integers in order for them to be
        compatible with whatever operation they're used in [Rule 10.1]
      
      Change-Id: Ic72b248aeede6cf18bf85051188ea7b8fd8ae829
      Signed-off-by: default avatarAnthony Zhou <anzhou@nvidia.com>
      31d97dc2
    • Varun Wadekar's avatar
      Tegra: memctrl: check GPU reset state from common place · f5f64e4d
      Varun Wadekar authored
      
      
      This patch moves the GPU reset state check, during VideoMem resize, to the
      common SiP handler, to reduce code duplication.
      
      Change-Id: I3818c5f104b809da83dc2a61d6a8149606f81c13
      Signed-off-by: default avatarVarun Wadekar <vwadekar@nvidia.com>
      f5f64e4d
    • Varun Wadekar's avatar
      Tegra: add explicit casts for integer macros · 70cb692e
      Varun Wadekar authored
      
      
      This patch adds explicit casts (U(x)) to integers in the tegra_def.h
      headers, to make them compatible with whatever operation they're used
      in [MISRA-C Rule 10.1]
      
      Change-Id: Ic5fc611aad986a2c6e6e6f625e0753ab9b69eb02
      Signed-off-by: default avatarVarun Wadekar <vwadekar@nvidia.com>
      70cb692e
  10. 12 May, 2017 1 commit
  11. 03 May, 2017 1 commit
  12. 01 May, 2017 2 commits
  13. 13 Apr, 2017 6 commits
  14. 10 Apr, 2017 1 commit
    • Varun Wadekar's avatar
      Tegra: memctrl_v1: enable 'xlat_table_v2' library · c05a2197
      Varun Wadekar authored
      
      
      This patch enables the 'xlat_table_v2' library for the Tegra Memory
      Controller driver. This library allows us to dynamically map/unmap
      memory regions, with MMU enabled.
      
      The Memory Controller driver maps/unmaps non-overlapping Video Memory
      region, to clean it of any secure contents, before it resizes the
      region.
      Signed-off-by: default avatarVarun Wadekar <vwadekar@nvidia.com>
      c05a2197
  15. 07 Apr, 2017 1 commit