1. 18 12月, 2015 1 次提交
    • A
      ARM: make default platform work for NOMMU · 70722803
      Arnd Bergmann 提交于
      Moving ARCH_VERSATILE into ARCH_MULTIPLATFORM means that it no longer
      works as the default target for MMU-less kernels. While we might
      want to get that working again in the future, it's also a rather
      bad default, and it makes sense to make ARM_SINGLE_V7M the default
      because that is what realistically all NOMMU users on ARM are using,
      and it actually is what gets selected by default in the absence of
      versatile in the choice statement.
      
      Related to this, 'allnoconfig' kernels fail to link with the new
      default, as they do not include a machine record:
      
      arm-linux-gnueabi-ld: no machine record defined
      
      For ARCH_MULTIPLATFORM kernels, we avoid this error by using a
      default machine descriptor that works for all trivial platforms,
      like ARCH_VIRT. The same reasoning applies for ARM_SINGLE_V7M,
      as that can also boot with empty machine descriptors both on
      qemu and on real hardware, as long as all the drivers are present.
      
      We could also follow up with a patch to remove the existing
      machine descriptors for the ARMv7M platforms, the only callback
      pointer the four platforms contain today is the armv7m_restart
      handler and we can simply make that the default for v7M with an
      add-on patch.
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      70722803
  2. 16 12月, 2015 2 次提交
    • R
      ARM: versatile: convert to multi-platform · a29da136
      Rob Herring 提交于
      Now that all the prerequisites are in place, we can enable Versatile
      boards for multi-platform kernels.
      Signed-off-by: NRob Herring <robh@kernel.org>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      a29da136
    • R
      ARM: versatile: switch to DT only booting and remove legacy code · 16956fed
      Rob Herring 提交于
      With DT support for clocks, irqchips, timers, and PCI now in place, DT
      based booting has feature parity with non-DT legacy boot. The final
      piece is actually enabling common clock support on Versatile. Enabling
      full DT support requires either removing the old Versatile clock code,
      updating the legacy boot to use the common clock code, or making DT and
      legacy boot mutually exclusive. Given that removing legacy boot code is
      the goal anyway, I am going with the 1st option.
      Signed-off-by: NRob Herring <robh@kernel.org>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Cc: Mike Turquette <mturquette@linaro.org>
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      16956fed
  3. 15 12月, 2015 1 次提交
    • A
      ARM: realview: remove sparsemem hack · fd0053c9
      Arnd Bergmann 提交于
      The realview-pbx platform has an elaborate way of avoiding the use of highmem
      by redefining its phys_to_virt function. In practice this doesn't help all
      that much, and it gets in the way of doing multiplatform builds for
      realview.
      
      This removes the feature and kills off the mach/memory.h file for realview.
      We also lose the ability to do sparsemem with this patch, but that should
      be put back into place for generic multiplatform configurations, to save
      a little memory on PBX.
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      fd0053c9
  4. 08 12月, 2015 5 次提交
  5. 02 12月, 2015 3 次提交
  6. 29 11月, 2015 1 次提交
    • A
      ARM: 8454/1: OF implies OF_FLATTREE · aa7d5f18
      Arnd Bergmann 提交于
      On the ARM architecture, individual platforms select CONFIG_USE_OF if they
      need it, but all device tree code is keyed off CONFIG_OF. When building
      a platform without DT support and manually enabling CONFIG_OF, we now
      get a number of build errors, e.g.
      
      arch/arm/kernel/devtree.c: In function 'setup_machine_fdt':
      arch/arm/kernel/devtree.c:215:19: error: implicit declaration of function 'early_init_dt_verify' [-Werror=implicit-function-declaration]
      
      We could now try to separate the use case of booting from DT vs. the
      case of using the dynamic implementation, but that seems more complicated
      than it can gain us.
      
      This simply changes the ARM Kconfig file to always enable OF_RESERVED_MEM
      and OF_EARLY_FLATTREE when CONFIG_OF is enabled. These options add a little
      extra code when we just want the dynamic OF implementation, but that seems
      like a rather obscure case, and this version solves all CONFIG_OF related
      randconfig regressions.
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Fixes: 0166dc11 ("of: make CONFIG_OF user selectable")
      Acked-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      aa7d5f18
  7. 14 10月, 2015 1 次提交
  8. 10 10月, 2015 1 次提交
  9. 03 10月, 2015 3 次提交
  10. 28 9月, 2015 1 次提交
    • R
      ARM: make RiscPC depend on MMU · 868e87cc
      Russell King 提交于
      RiscPC fails to build if MMU is disabled:
      
      arch/arm/mach-rpc/ecard.c: In function 'ecard_init_pgtables':
      arch/arm/mach-rpc/ecard.c:229:2: error: implicit declaration of function 'pgd_offset' [-Werror=implicit-function-declaration]
      
      arrange for RiscPC to depend on MMU.
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      868e87cc
  11. 14 9月, 2015 1 次提交
  12. 11 9月, 2015 1 次提交
    • D
      kexec: split kexec_load syscall from kexec core code · 2965faa5
      Dave Young 提交于
      There are two kexec load syscalls, kexec_load another and kexec_file_load.
       kexec_file_load has been splited as kernel/kexec_file.c.  In this patch I
      split kexec_load syscall code to kernel/kexec.c.
      
      And add a new kconfig option KEXEC_CORE, so we can disable kexec_load and
      use kexec_file_load only, or vice verse.
      
      The original requirement is from Ted Ts'o, he want kexec kernel signature
      being checked with CONFIG_KEXEC_VERIFY_SIG enabled.  But kexec-tools use
      kexec_load syscall can bypass the checking.
      
      Vivek Goyal proposed to create a common kconfig option so user can compile
      in only one syscall for loading kexec kernel.  KEXEC/KEXEC_FILE selects
      KEXEC_CORE so that old config files still work.
      
      Because there's general code need CONFIG_KEXEC_CORE, so I updated all the
      architecture Kconfig with a new option KEXEC_CORE, and let KEXEC selects
      KEXEC_CORE in arch Kconfig.  Also updated general kernel code with to
      kexec_load syscall.
      
      [akpm@linux-foundation.org: coding-style fixes]
      Signed-off-by: NDave Young <dyoung@redhat.com>
      Cc: Eric W. Biederman <ebiederm@xmission.com>
      Cc: Vivek Goyal <vgoyal@redhat.com>
      Cc: Petr Tesarik <ptesarik@suse.cz>
      Cc: Theodore Ts'o <tytso@mit.edu>
      Cc: Josh Boyer <jwboyer@fedoraproject.org>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      2965faa5
  13. 27 8月, 2015 1 次提交
    • R
      ARM: software-based priviledged-no-access support · a5e090ac
      Russell King 提交于
      Provide a software-based implementation of the priviledged no access
      support found in ARMv8.1.
      
      Userspace pages are mapped using a different domain number from the
      kernel and IO mappings.  If we switch the user domain to "no access"
      when we enter the kernel, we can prevent the kernel from touching
      userspace.
      
      However, the kernel needs to be able to access userspace via the
      various user accessor functions.  With the wrapping in the previous
      patch, we can temporarily enable access when the kernel needs user
      access, and re-disable it afterwards.
      
      This allows us to trap non-intended accesses to userspace, eg, caused
      by an inadvertent dereference of the LIST_POISON* values, which, with
      appropriate user mappings setup, can be made to succeed.  This in turn
      can allow use-after-free bugs to be further exploited than would
      otherwise be possible.
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      a5e090ac
  14. 21 8月, 2015 1 次提交
  15. 18 8月, 2015 1 次提交
    • S
      ARM: 8415/1: early fixmap support for earlycon · a5f4c561
      Stefan Agner 提交于
      Add early fixmap support, initially to support permanent, fixed
      mapping support for early console. A temporary, early pte is
      created which is migrated to a permanent mapping in paging_init.
      This is also needed since the attributes may change as the memory
      types are initialized. The 3MiB range of fixmap spans two pte
      tables, but currently only one pte is created for early fixmap
      support.
      
      Re-add FIX_KMAP_BEGIN to the index calculation in highmem.c since
      the index for kmap does not start at zero anymore. This reverts
      4221e2e6 ("ARM: 8031/1: fixmap: remove FIX_KMAP_BEGIN and
      FIX_KMAP_END") to some extent.
      
      Cc: Mark Salter <msalter@redhat.com>
      Cc: Kees Cook <keescook@chromium.org>
      Cc: Laura Abbott <lauraa@codeaurora.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
      Signed-off-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NStefan Agner <stefan@agner.ch>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      a5f4c561
  16. 03 8月, 2015 1 次提交
    • M
      ARM: migrate to common PSCI client code · be120397
      Mark Rutland 提交于
      Now that the common PSCI client code has been factored out to
      drivers/firmware, and made safe for 32-bit use, move the 32-bit ARM code
      over to it. This results in a moderate reduction of duplicated lines,
      and will prevent further duplication as the PSCI client code is updated
      for PSCI 1.0 and beyond.
      
      The two legacy platform users of the PSCI invocation code are updated to
      account for interface changes. In both cases the power state parameter
      (which is constant) is now generated using macros, so that the
      pack/unpack logic can be killed in preparation for PSCI 1.0 power state
      changes.
      Signed-off-by: NMark Rutland <mark.rutland@arm.com>
      Acked-by: NRob Herring <robh@kernel.org>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Ashwin Chaugule <ashwin.chaugule@linaro.org>
      Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Russell King <rmk+kernel@arm.linux.org.uk>
      Cc: Will Deacon <will.deacon@arm.com>
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      be120397
  17. 31 7月, 2015 1 次提交
    • M
      arm: perf: factor arm_pmu core out to drivers · fa8ad788
      Mark Rutland 提交于
      To enable sharing of the arm_pmu code with arm64, this patch factors it
      out to drivers/perf/. A new drivers/perf directory is added for
      performance monitor drivers to live under.
      
      MAINTAINERS is updated accordingly. Files added previously without a
      corresponsing MAINTAINERS update (perf_regs.c, perf_callchain.c, and
      perf_event.h) are also added.
      
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Will Deacon <will.deacon@arm.com>
      Signed-off-by: NMark Rutland <mark.rutland@arm.com>
      [will: augmented Kconfig help slightly]
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      fa8ad788
  18. 17 7月, 2015 1 次提交
  19. 08 7月, 2015 1 次提交
  20. 29 6月, 2015 1 次提交
  21. 02 6月, 2015 1 次提交
  22. 01 6月, 2015 1 次提交
  23. 30 5月, 2015 1 次提交
  24. 28 5月, 2015 4 次提交
    • B
      EDAC: Cleanup atomic_scrub mess · b01aec9b
      Borislav Petkov 提交于
      So first of all, this atomic_scrub() function's naming is bad. It looks
      like an atomic_t helper. Change it to edac_atomic_scrub().
      
      The bigger problem is that this function is arch-specific and every new
      arch which doesn't necessarily need that functionality still needs to
      define it, otherwise EDAC doesn't compile.
      
      So instead of doing that and including arch-specific headers, have each
      arch define an EDAC_ATOMIC_SCRUB symbol which can be used in edac_mc.c
      for ifdeffery. Much cleaner.
      
      And we already are doing this with another symbol - EDAC_SUPPORT. This
      is also much cleaner than having CONFIG_EDAC enumerate all the arches
      which need/have EDAC support and drivers.
      
      This way I can kill the useless edac.h header in tile too.
      Acked-by: NRalf Baechle <ralf@linux-mips.org>
      Acked-by: NMichael Ellerman <mpe@ellerman.id.au>
      Acked-by: NChris Metcalf <cmetcalf@ezchip.com>
      Acked-by: NIngo Molnar <mingo@kernel.org>
      Acked-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Doug Thompson <dougthompson@xmission.com>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linux-edac@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-mips@linux-mips.org
      Cc: linuxppc-dev@lists.ozlabs.org
      Cc: "Maciej W. Rozycki" <macro@codesourcery.com>
      Cc: Markos Chandras <markos.chandras@imgtec.com>
      Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: "Steven J. Hill" <Steven.Hill@imgtec.com>
      Cc: x86@kernel.org
      Signed-off-by: NBorislav Petkov <bp@suse.de>
      b01aec9b
    • A
      ARM: 8375/1: disable some options on ARMv7-M · cb1293e2
      Arnd Bergmann 提交于
      Kprobes, irqflags tracing and kexec don't currently build on
      kernels targetting ARMv7-M, so for now, we should just disallow
      those combinations.
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      cb1293e2
    • A
      ARM: 8372/1: KGDB does not build on BE32 · cfeec79e
      Arnd Bergmann 提交于
      KGDB requires code patching, which only works on little-endian
      or newer big-endian (BE8) machines but not on the older big-endian
      ones (BE32) where it results in this build error:
      
      arch/arm/kernel/patch.c: In function '__patch_text_real':
      arch/arm/kernel/patch.c:93:4: error: implicit declaration of function '__opcode_to_mem_thumb32' [-Werror=implicit-function-declaration]
          insn = __opcode_to_mem_thumb32(insn);
      
      This adds a Kconfig dependency to avoid the broken case and
      for all other symbols that require code patching.
      
      Fixes: 23a4e405 ("arm: kgdb: Handle read-only text / modules")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      cfeec79e
    • A
      ARM: 8371/1: always select IRQ_WORK on SMP · 0361748f
      Arnd Bergmann 提交于
      Any SMP kernel now requires the irq_work code after
      generic_smp_call_function_single_interrupt() started using it,
      or we get:
      
      kernel/built-in.o: In function `flush_smp_call_function_queue':
      :(.text+0x4dc3a): undefined reference to `irq_work_run'
      
      Fixes: 47885016 ("irq_work: Implement remote queueing")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      0361748f
  25. 22 5月, 2015 1 次提交
  26. 21 5月, 2015 3 次提交
    • S
      ARM: introduce ARM_SINGLE_ARMV7M for ARMv7-M platforms · 9c77bc43
      Stefan Agner 提交于
      This introduces a new top level config symbol ARM_SINGLE_ARMV7M
      for non-MMU, ARMv7-M platforms. It also support multiple ARMv7-M
      platforms in one kernel image since the cores share the same
      basic memory layout and interrupt controller. However, this works
      only if the combined platforms also have a similar (main) memory
      layout.
      Signed-off-by: NStefan Agner <stefan@agner.ch>
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      9c77bc43
    • T
      ARM: OMAP1: Change interrupt numbering for sparse IRQ · 685e2d08
      Tony Lindgren 提交于
      Change interrupt numbering for sparse IRQ. We do this using
      a fixed offset until we can drop irqs.h once all it's users
      have been updated.
      
      Note that this depends on the GPIO fix for the MPUIO IRQs
      "gpio: omap: Fix regression for MPUIO interrupts".
      
      Also note that this patch adds some extra irq alloc warnings
      that will go away when we stop calling irq_alloc_descs
      in gpio-omap.c with a follow-up patch.
      
      Cc: Aaro Koskinen <aaro.koskinen@iki.fi>
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      685e2d08
    • T
      ARM: omap1: Switch to use MULTI_IRQ · b694331c
      Tony Lindgren 提交于
      This allows us to get a bit further with SPARSE_IRQ and
      MULTIARCH support.
      
      Note that we now also rename omap_irq_flags to omap_l2_irq
      as that's the omap_irq_flags naming is confusing. It just
      contains the interrupt number for the l2 irq.
      
      Cc: Aaro Koskinen <aaro.koskinen@iki.fi>
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      b694331c