1. 24 Feb, 2021 1 commit
  2. 20 Jan, 2021 1 commit
  3. 18 Jan, 2021 2 commits
    • Pali Rohár's avatar
      marvell: uart: a3720: Fix macro name for 6th bit of Status Register · b8e637f4
      Pali Rohár authored
      
      
      This patch does not change code, it only updates comments and macro name
      for 6th bit of Status Register. So TF-A binary stay same.
      
      6th bit of the Status Register is named TX EMPTY and is set to 1 when both
      Transmitter Holding Register (THR) or Transmitter Shift Register (TSR) are
      empty. It is when all characters were already transmitted.
      
      There is also TX FIFO EMPTY bit in the Status Register which is set to 1
      only when THR is empty.
      
      In both console_a3700_core_init() and console_a3700_core_flush() functions
      we should wait until both THR and TSR are empty therefore we should check
      6th bit of the Status Register.
      
      So current code is correct, just had misleading macro names and comments.
      This change fixes this "documentation" issue, fixes macro name for 6th bit
      of the Status Register and also updates comments.
      Signed-off-by: default avatarPali Rohár <pali@kernel.org>
      Change-Id: I19e4e7f53a90bcfb318e6dd1b1249b6cbf81c4d3
      b8e637f4
    • Pali Rohár's avatar
      marvell: uart: a3720: Implement console_a3700_core_getc · 74867756
      Pali Rohár authored
      
      
      Implementation is simple, just check if there is a pending character in
      RX FIFO via RXRDY bit of Status Register and if yes, read it from
      UART_RX_REG register.
      Signed-off-by: default avatarPali Rohár <pali@kernel.org>
      Change-Id: I226b6e336f44f5d0ca8dcb68e49a68e8f2f49708
      74867756
  4. 13 Jan, 2021 19 commits
  5. 11 Jan, 2021 11 commits
  6. 23 Dec, 2020 1 commit
    • Pali Rohár's avatar
      marvell: uart: a3720: Implement console_a3700_core_flush · e63e4140
      Pali Rohár authored
      
      
      Implementation is simple, just wait for the TX FIFO to be empty.
      
      Without this patch TF-A on A3720 truncate the last line:
      
        NOTICE:  BL31: Built : 16:1
      
      With this patch TF-A on A3720 print correctly also the last line:
      
        NOTICE:  BL31: Built : 19:03:31, Dec 23 2020
      Signed-off-by: default avatarPali Rohár <pali@kernel.org>
      Change-Id: I2f2ea42beab66ba132afdb400ca7898c5419db09
      e63e4140
  7. 21 Dec, 2020 1 commit
  8. 08 Dec, 2020 1 commit
    • Marek Vasut's avatar
      rcar_gen3: drivers: console: Treat log as device memory · 60576747
      Marek Vasut authored
      
      
      The BL31 log driver is registered before the xlat tables are initialized,
      at that point the log memory is configured as device memory and can only
      be accessed with up-to-32bit aligned accesses. Adjust the driver to do
      just that.
      
      The memset() call has to be replaced by a loop of 32bit writes to the log,
      the memcpy() is trivial to replace with a single 32bit write of the entire
      TLOG word. In the end, this even simplifies the code.
      Signed-off-by: default avatarMarek Vasut <marek.vasut+renesas@gmail.com>
      Change-Id: Ie9152e782e67d93e7236069a294df812e2b873bf
      60576747
  9. 13 Oct, 2020 1 commit
  10. 12 Oct, 2020 2 commits
    • Jimmy Brisson's avatar
      Increase type widths to satisfy width requirements · d7b5f408
      Jimmy Brisson authored
      
      
      Usually, C has no problem up-converting types to larger bit sizes. MISRA
      rule 10.7 requires that you not do this, or be very explicit about this.
      This resolves the following required rule:
      
          bl1/aarch64/bl1_context_mgmt.c:81:[MISRA C-2012 Rule 10.7 (required)]<None>
          The width of the composite expression "0U | ((mode & 3U) << 2U) | 1U |
          0x3c0U" (32 bits) is less that the right hand operand
          "18446744073709547519ULL" (64 bits).
      
      This also resolves MISRA defects such as:
      
          bl2/aarch64/bl2arch_setup.c:18:[MISRA C-2012 Rule 12.2 (required)]
          In the expression "3U << 20", shifting more than 7 bits, the number
          of bits in the essential type of the left expression, "3U", is
          not allowed.
      
      Further, MISRA requires that all shifts don't overflow. The definition of
      PAGE_SIZE was (1U << 12), and 1U is 8 bits. This caused about 50 issues.
      This fixes the violation by changing the definition to 1UL << 12. Since
      this uses 32bits, it should not create any issues for aarch32.
      
      This patch also contains a fix for a build failure in the sun50i_a64
      platform. Specifically, these misra fixes removed a single and
      instruction,
      
          92407e73        and     x19, x19, #0xffffffff
      
      from the cm_setup_context function caused a relocation in
      psci_cpus_on_start to require a linker-generated stub. This increased the
      size of the .text section and caused an alignment later on to go over a
      page boundary and round up to the end of RAM before placing the .data
      section. This sectionn is of non-zero size and therefore causes a link
      error.
      
      The fix included in this reorders the functions during link time
      without changing their ording with respect to alignment.
      
      Change-Id: I76b4b662c3d262296728a8b9aab7a33b02087f16
      Signed-off-by: default avatarJimmy Brisson <jimmy.brisson@arm.com>
      d7b5f408
    • Lionel Debieve's avatar
      drivers: stm32_fmc2_nand: fix boundary check for chip select · 495885bc
      Lionel Debieve authored
      
      
      Chip select is retrieved from device tree and check
      must be done regarding the MAX_CS defined.
      Signed-off-by: default avatarLionel Debieve <lionel.debieve@st.com>
      Reviewed-by: default avatarChristophe KERELLO <christophe.kerello@st.com>
      Change-Id: I03144b133bd51a845a4794f0f6bbd9402fc04936
      495885bc