1. 12 Jun, 2015 9 commits
  2. 10 Jun, 2015 2 commits
  3. 06 Jun, 2015 5 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
    • Russell King's avatar
      Merge branch 'for-rmk/perf' of... · bcc8fa83
      Russell King authored
      Merge branch 'for-rmk/perf' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into devel-stable
      
      There's quite a lot here, most of it from Mark Rutland, who has been
      working on big.LITTLE PMU support for a while now. His work also brings
      us significantly closer to moving the bulk of the CPU PMU driver out
      into drivers/, where it can be shared with arm64.
      
      As part of this work, there is a small patch to perf/core, which has
      been Acked-by PeterZ and doesn't conflict with tip/perf/core at present.
      I've kept that patch on a separate branch, merged in here, so that the
      tip guys can pull it too if any unexpected issues crop up.
      
      Please note that there is a conflict with mainline, since we remove
      perf_event_cpu.c. The correct resolution is also to remove the file,
      since the changes there are already reflected in the rework (and this
      resolution is already included in linux-next).
      bcc8fa83
  4. 02 Jun, 2015 9 commits
  5. 01 Jun, 2015 11 commits
  6. 28 May, 2015 4 commits
    • Mark Rutland's avatar
      arm: perf: unify perf_event{,_cpu}.c · 74cf0bc7
      Mark Rutland authored
      Now that the arm_pmu framework is only used for CPU PMUs, there's no
      reason to keep the pseudo-generic and CPU-specific framework portions
      separate.
      
      This patch folds the two into perf_event.c.
      Signed-off-by: default avatarMark Rutland <mark.rutland@arm.com>
      [will: fixed up irq cfg to match upstream]
      Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
      74cf0bc7
    • Mark Rutland's avatar
      arm: perf: factor out armv7 pmu driver · 29ba0f37
      Mark Rutland authored
      Now that the core arm perf code maintains no global state and all
      microarchitecture-specific PMU data can be fed in through the shared
      probe function, it's possible to use it as a library and get rid of the
      C file includes we have currently.
      
      This patch factors out the ARMv7-specific portions out into the ARMv7
      driver. For the moment this is always built if perf event support is
      enabled, but the preprocessor guards will leave behind an empty file.
      
      Now that perf_event_cpu.c contains no microarchitecture-specific data,
      the associated probing code is removed, completing its relegation to a
      library file. The vestigal "arm-pmu" platform device ID is removed in
      this patch, as it has been unused since platform files were updated to
      specify a more specific PMU variant.
      Signed-off-by: default avatarMark Rutland <mark.rutland@arm.com>
      Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
      29ba0f37
    • Mark Rutland's avatar
      arm: perf: factor out armv6 pmu driver · 1fe115b3
      Mark Rutland authored
      Now that the core arm perf code maintains no global state and all
      microarchitecture-specific PMU data can be fed in through the shared
      probe function, it's possible to use it as a library and get rid of the
      C file includes we have currently.
      
      This patch factors out the ARMv6-specific portions out into the ARMv6
      driver. For the moment this is always built if perf event support is
      enabled, but the preprocessor guards will leave behind an empty file.
      Signed-off-by: default avatarMark Rutland <mark.rutland@arm.com>
      Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
      1fe115b3
    • Mark Rutland's avatar
      arm: perf: factor out xscale pmu driver · a12c72cc
      Mark Rutland authored
      Now that the core arm perf code maintains no global state and all
      microarchitecture-specific PMU data can be fed in through the shared
      probe function, it's possible to use it as a library and get rid of the
      C file includes we have currently.
      
      This patch factors out the xscale-specific portions out into the xscale
      driver. For the moment this is always built if perf event support is
      enabled, but the preprocessor guards will leave behind an empty file.
      Signed-off-by: default avatarMark Rutland <mark.rutland@arm.com>
      Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
      a12c72cc