1. 12 Jun, 2015 4 commits
  2. 10 Jun, 2015 2 commits
  3. 06 Jun, 2015 4 commits
    • Mike Looijmans's avatar
      ARM: 8387/1: arm/mm/dma-mapping.c: Add arm_coherent_dma_mmap · 55af8a91
      Mike Looijmans authored
      When dma-coherent transfers are enabled, the mmap call must
      not change the pg_prot flags in the vma struct.
      
      Split the arm_dma_mmap into a common and specific parts,
      and add a "arm_coherent_dma_mmap" implementation that does
      not alter the page protection flags.
      
      Tested on a topic-miami board (Zynq) using the ACP port
      to transfer data between FPGA and CPU using the Dyplo
      framework. Without this patch, byte-wise access to mmapped
      coherent DMA memory was about 20x slower because of the
      memory being marked as non-cacheable, and transfer speeds
      would not exceed 240MB/s.
      
      After this patch, the mapped memory is cacheable and the
      transfer speed is again 600MB/s (limited by the FPGA) when
      the data is in the L2 cache, while data integrity is being
      maintained.
      
      The patch has no effect on non-coherent DMA.
      Signed-off-by: default avatarMike Looijmans <mike.looijmans@topic.nl>
      Acked-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      55af8a91
    • Michael van der Westhuizen's avatar
      ARM: 8388/1: tcm: Don't crash when TCM banks are protected by TrustZone · 0bbe6b5a
      Michael van der Westhuizen authored
      Fixes the TCM initialisation code to handle TCM banks that are
      present but inaccessible due to TrustZone configuration.  This is
      the default case when enabling the non-secure world.  It may also
      be the case that that the user decided to use TCM for TrustZone.
      
      This change has exposed a bug in handling of TCM where no TCM bank
      was usable (the 0 size TCM case).  This change addresses the
      resulting hang.
      
      This code only handles the ARMv6 TCMTR register format, and will not
      work correctly on boards that use the ARMv7 (or any other) format.
      This is handled by performing an early exit from the initialisation
      function when the TCMTR reports any format other than v6.
      Signed-off-by: default avatarMichael van der Westhuizen <michael@smart-africa.com>
      Reviewed-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Reviewed-by: default avatarDave Martin <Dave.Martin@arm.com>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      0bbe6b5a
    • Nathan Lynch's avatar
      ARM: 8384/1: VDSO: force use of BFD linker · d2b30cd4
      Nathan Lynch authored
      When using a toolchain with gold as the default linker, the VDSO build
      fails:
      
        VDSO    arch/arm/vdso/vdso.so.raw
        HOSTCC  arch/arm/vdso/vdsomunge
        MUNGE   arch/arm/vdso/vdso.so.dbg
        OBJCOPY arch/arm/vdso/vdso.so
      BFD: arch/arm/vdso/vdso.so: Not enough room for program headers, try
      linking with -N
      
      For whatever reason, ld.gold is omitting an exidx program header that
      ld.bfd emits, and even when I work around that, I don't get a working
      VDSO.
      
      For now, instead of supporting gold (which will fail to link the
      kernel anyway since it does not implement --pic-veneer), direct the
      compiler to use the traditional bfd linker.  This is accomplished by
      using -fuse-ld, which is implemented in GCC 4.8 and later.
      
      Note: one limitation of this is that if the toolchain is configured
      to use gold by default, and the bfd linker is not in $PATH, the VDSO
      build will fail:
      
        VDSO    arch/arm/vdso/vdso.so.raw
      collect2: fatal error: cannot find 'ld'
      
      This will happen if CROSS_COMPILE begins with a path such as
      /opt/bin/arm-linux-gnu- but /opt/bin is not in $PATH.  This is
      considered an acceptable corner-case limitation and is easily worked
      around.
      
      Additonal note: we use cc-option instead of cc-ldoption so that
      -fuse-ld=bfd is placed in the command line if the compiler recognizes
      the option.  Using cc-ldoption results in an attempt to link, which
      fails in the situation just described, causing -fuse-ld=bfd to be
      omitted and gold to be used for the VDSO link, which is what we're
      trying to prevent.
      Reported-by: default avatarStefan Agner <stefan@agner.ch>
      Signed-off-by: default avatarNathan Lynch <nathan_lynch@mentor.com>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      d2b30cd4
    • Nathan Lynch's avatar
      ARM: 8385/1: VDSO: group link options · d33ce23b
      Nathan Lynch authored
      Currently the VDSO's link options are kind of a mess spread between
      
      ccflags-y and cmd_vdsold.  Collect linker directives into one
      variable, VDSO_LDFLAGS, and use that in cmd_vdsold.
      Signed-off-by: default avatarNathan Lynch <nathan_lynch@mentor.com>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      d33ce23b
  4. 02 Jun, 2015 9 commits
  5. 01 Jun, 2015 10 commits
  6. 28 May, 2015 2 commits
  7. 27 May, 2015 8 commits
  8. 18 May, 2015 1 commit