1. 12 10月, 2017 1 次提交
  2. 01 7月, 2017 1 次提交
    • V
      drivers: dma-mapping: allow dma_common_mmap() for NOMMU · 07c75d7a
      Vladimir Murzin 提交于
      Currently, internals of dma_common_mmap() is compiled out if build is
      done for either NOMMU or target which explicitly says it does not
      have/want coherent DMA mmap. It turned out that dma_common_mmap() can
      be handy in NOMMU setup (at least for ARM).
      
      This patch converts exitent NOMMU targets to use ARCH_NO_COHERENT_DMA_MMAP,
      thus when CONFIG_MMU is gone from dma_common_mmap() their behaviour stays
      unchanged.
      
      ARM is not converted to ARCH_NO_COHERENT_DMA_MMAP because it 1)
      already has mmap callback which can handle (at some extent) NOMMU 2)
      already defines dummy pgprot_noncached() for NOMMU build.
      
      c6x and frv stay untouched since they already have ARCH_NO_COHERENT_DMA_MMAP.
      
      Cc: Steven Miao <realmz6@gmail.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Rich Felker <dalias@libc.org>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: Max Filippov <jcmvbkbc@gmail.com>
      Suggested-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NVladimir Murzin <vladimir.murzin@arm.com>
      Tested-by: NBenjamin Gaignard <benjamin.gaignard@linaro.org>
      07c75d7a
  3. 27 4月, 2017 1 次提交
  4. 29 3月, 2017 1 次提交
  5. 16 12月, 2016 1 次提交
    • M
      xtensa: enable HAVE_DMA_CONTIGUOUS · 9d2ffe5c
      Max Filippov 提交于
      Enable HAVE_DMA_CONTIGUOUS, reserve contiguous memory at bootmem_init,
      use dma_alloc_from_contiguous and dma_release_from_contiguous in
      xtensa_dma_alloc/free.
      This allows for big contiguous DMA buffer allocation from designated
      area configured in the device tree.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      9d2ffe5c
  6. 30 9月, 2016 1 次提交
    • M
      xtensa: disable MMU initialization option on MMUv2 cores · a4c6be5a
      Max Filippov 提交于
      MMU initialization option is currently ignored on MMUv2 cores, but it is
      used in Kconfig to select kernel load and start addresses. This choice
      is not available for MMUv2 cores as they have hardwired TLB entries.
      Disable MMU initialization option for known MMUv2 cores so that they get
      correct kernel load/start address by default.
      This fixes the default allmodconfig build.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      a4c6be5a
  7. 10 9月, 2016 1 次提交
    • M
      xtensa: fix default kernel load address · 73a3eed0
      Max Filippov 提交于
      Make default kernel load address 0xd0003000 for MMUv2 cores and
      0x60003000 for noMMU cores. Don't initialize MMU inside vmlinux for
      predefined MMUv2 cores (it's noop anyway).
      
      This fixes the following defconfig build error:
        arch/xtensa/kernel/built-in.o: In function `fast_alloca':
        (.text+0x99a): dangerous relocation: j: cannot encode: _WindowUnderflow12
        arch/xtensa/kernel/built-in.o: In function `fast_alloca':
        (.text+0x99d): dangerous relocation: j: cannot encode: _WindowUnderflow8
        arch/xtensa/kernel/built-in.o: In function `fast_alloca':
        (.text+0x9a0): dangerous relocation: j: cannot encode: _WindowUnderflow4
        arch/xtensa/kernel/built-in.o: In function `window_overflow_restore_a0_fixup':
        (.text+0x23a3): dangerous relocation: j: cannot encode: (.DoubleExceptionVector.text+0x104)
        arch/xtensa/kernel/built-in.o: In function `window_overflow_restore_a0_fixup':
        (.text+0x23c1): dangerous relocation: j: cannot encode: (.DoubleExceptionVector.text+0x104)
        arch/xtensa/kernel/built-in.o: In function `window_overflow_restore_a0_fixup':
        (.text+0x23dd): dangerous relocation: j: cannot encode: (.DoubleExceptionVector.text+0x104)
      
      With this change all xtensa defconfigs build correctly.
      Reported-by: NGuenter Roeck <linux@roeck-us.net>
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      73a3eed0
  8. 24 7月, 2016 5 次提交
    • M
      xtensa: support reserved-memory DT node · 4e7c84ec
      Max Filippov 提交于
      This allows reserving regions of physical memory from the device tree.
      See Documentation/devicetree/bindings/reserved-memory/reserved-memory.txt
      for more details.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      4e7c84ec
    • M
      xtensa: drop sysmem and switch to memblock · 0e46c111
      Max Filippov 提交于
      Memblock is the standard kernel boot-time memory tracker/allocator. Use
      it instead of the custom sysmem allocator. This allows using kmemleak,
      CMA and device tree memory reservation.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      0e46c111
    • M
      xtensa: minimize use of PLATFORM_DEFAULT_MEM_{ADDR,SIZE} · 3de00482
      Max Filippov 提交于
      Now that the kernel load address and KSEG physical base address have
      their own Kconfig symbols PLATFORM_DEFAULT_MEM seems redundant. It makes
      little sense to use it in MMU configurations instead of KSEG_PADDR.
      In noMMU configurations there's no explicit KSEG, so it's still useful
      for the early cache initialization and definition of ARCH_PFN_OFFSET,
      which affects mem_map size.
      
      - limit it to noMMU; MMU variants have XCHAL_KSEG_PADDR and
        XCHAL_KSEG_SIZE;
      - don't use it to define TASK_SIZE or MAX_LOW_PFN: first doesn't make
        any difference in noMMU, second is meaningless as there's no high
        memory;
      - don't add default physical memory region: memory layout should come
        from the DT, bootloader tags, or memmap= command line parameter.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      3de00482
    • M
      xtensa: cleanup MMU setup and kernel layout macros · a9f2fc62
      Max Filippov 提交于
      Make kernel load address explicit, independent of the selected MMU
      configuration and configurable from Kconfig. Do not restrict it to the
      first 512MB of the physical address space.
      
      Cleanup kernel memory layout macros:
      
      - rename VECBASE_RESET_VADDR to VECBASE_VADDR, XC_VADDR to VECTOR_VADDR;
      - drop VIRTUAL_MEMORY_ADDRESS and LOAD_MEMORY_ADDRESS;
      - introduce PHYS_OFFSET and use it in __va and __pa definitions;
      - synchronize MMU/noMMU vectors, drop unused NMI vector;
      - replace hardcoded vectors offset of 0x3000 with Kconfig symbol.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      a9f2fc62
    • M
      xtensa: add alternative kernel memory layouts · d39af902
      Max Filippov 提交于
      MMUv3 is able to support low memory bigger than 128MB.
      Implement 256MB and 512MB KSEG layouts:
      
      - add Kconfig selector for KSEG layout;
      - add KSEG base address, size and alignment definitions to
        arch/xtensa/include/asm/kmem_layout.h;
      - use new definitions in TLB initialization;
      - add build time memory map consistency checks.
      
      See Documentation/xtensa/mmu.txt for the details of new memory layouts.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      d39af902
  9. 21 5月, 2016 1 次提交
    • J
      exit_thread: remove empty bodies · 5f56a5df
      Jiri Slaby 提交于
      Define HAVE_EXIT_THREAD for archs which want to do something in
      exit_thread. For others, let's define exit_thread as an empty inline.
      
      This is a cleanup before we change the prototype of exit_thread to
      accept a task parameter.
      
      [akpm@linux-foundation.org: fix mips]
      Signed-off-by: NJiri Slaby <jslaby@suse.cz>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: "James E.J. Bottomley" <jejb@parisc-linux.org>
      Cc: Aurelien Jacquiot <a-jacquiot@ti.com>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Chen Liqin <liqin.linux@gmail.com>
      Cc: Chris Metcalf <cmetcalf@mellanox.com>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Fenghua Yu <fenghua.yu@intel.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
      Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Helge Deller <deller@gmx.de>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: James Hogan <james.hogan@imgtec.com>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Jesper Nilsson <jesper.nilsson@axis.com>
      Cc: Jiri Slaby <jslaby@suse.cz>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
      Cc: Lennox Wu <lennox.wu@gmail.com>
      Cc: Ley Foon Tan <lftan@altera.com>
      Cc: Mark Salter <msalter@redhat.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Matt Turner <mattst88@gmail.com>
      Cc: Max Filippov <jcmvbkbc@gmail.com>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Rich Felker <dalias@libc.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Richard Kuo <rkuo@codeaurora.org>
      Cc: Richard Weinberger <richard@nod.at>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Steven Miao <realmz6@gmail.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Tony Luck <tony.luck@intel.com>
      Cc: Vineet Gupta <vgupta@synopsys.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      5f56a5df
  10. 26 4月, 2016 1 次提交
  11. 11 3月, 2016 1 次提交
    • M
      xtensa: support hardware breakpoints/watchpoints · c91e02bd
      Max Filippov 提交于
      Use perf framework to manage hardware instruction and data breakpoints.
      Add two new ptrace calls: PTRACE_GETHBPREGS and PTRACE_SETHBPREGS to
      query and set instruction and data breakpoints.
      Address bit 0 choose instruction (0) or data (1) break register, bits
      31..1 are the register number.
      Both calls transfer two 32-bit words: address (0) and control (1).
      Instruction breakpoint contorl word is 0 to clear breakpoint, 1 to set.
      Data breakpoint control word bit 31 is 'trigger on store', bit 30 is
      'trigger on load, bits 29..0 are length. Length 0 is used to clear a
      breakpoint. To set a breakpoint length must be a power of 2 in the range
      1..64 and the address must be length-aligned.
      
      Introduce new thread_info flag: TIF_DB_DISABLED. Set it if debug
      exception is raised by the kernel code accessing watched userspace
      address and disable corresponding data breakpoint. On exit to userspace
      check that flag and, if set, restore all data breakpoints.
      
      Handle debug exceptions raised with PS.EXCM set. This may happen when
      window overflow/underflow handler or fast exception handler hits data
      breakpoint, in which case save and disable all data breakpoints,
      single-step faulting instruction and restore data breakpoints.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      c91e02bd
  12. 09 3月, 2016 1 次提交
    • B
      PCI: Include pci/hotplug Kconfig directly from pci/Kconfig · e7e127e3
      Bjorn Helgaas 提交于
      Include pci/hotplug/Kconfig directly from pci/Kconfig, so arches don't
      have to source both pci/Kconfig and pci/hotplug/Kconfig.
      
      Note that this effectively adds pci/hotplug/Kconfig to the following
      arches, because they already sourced drivers/pci/Kconfig but they
      previously did not source drivers/pci/hotplug/Kconfig:
      
        alpha
        arm
        avr32
        frv
        m68k
        microblaze
        mn10300
        sparc
        unicore32
      
      Inspired-by-patch-from: Bogicevic Sasa <brutallesale@gmail.com>
      Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
      e7e127e3
  13. 21 1月, 2016 1 次提交
    • C
      dma-mapping: always provide the dma_map_ops based implementation · e1c7e324
      Christoph Hellwig 提交于
      Move the generic implementation to <linux/dma-mapping.h> now that all
      architectures support it and remove the HAVE_DMA_ATTR Kconfig symbol now
      that everyone supports them.
      
      [valentinrothberg@gmail.com: remove leftovers in Kconfig]
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Aurelien Jacquiot <a-jacquiot@ti.com>
      Cc: Chris Metcalf <cmetcalf@ezchip.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
      Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no>
      Cc: Helge Deller <deller@gmx.de>
      Cc: James Hogan <james.hogan@imgtec.com>
      Cc: Jesper Nilsson <jesper.nilsson@axis.com>
      Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
      Cc: Ley Foon Tan <lftan@altera.com>
      Cc: Mark Salter <msalter@redhat.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: Steven Miao <realmz6@gmail.com>
      Cc: Vineet Gupta <vgupta@synopsys.com>
      Cc: Christian Borntraeger <borntraeger@de.ibm.com>
      Cc: Joerg Roedel <jroedel@suse.de>
      Cc: Sebastian Ott <sebott@linux.vnet.ibm.com>
      Signed-off-by: NValentin Rothberg <valentinrothberg@gmail.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      e1c7e324
  14. 11 1月, 2016 1 次提交
    • M
      xtensa: make fake NMI configurable · e4629194
      Max Filippov 提交于
      Do not always use fake NMI when safe, provide Kconfig option instead.
      Print a warning if fake NMI is chosen in unsafe configuration, but allow
      it, because it may work if the user knows that interrupts with
      priorities at or above PMM IRQ are not used. Add a check to NMI handler
      that BUGs if any of these IRQs fire.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      e4629194
  15. 03 11月, 2015 1 次提交
  16. 02 11月, 2015 2 次提交
  17. 17 8月, 2015 4 次提交
  18. 26 5月, 2015 1 次提交
  19. 27 2月, 2015 1 次提交
  20. 09 12月, 2014 1 次提交
  21. 21 10月, 2014 3 次提交
  22. 06 10月, 2014 2 次提交
  23. 14 8月, 2014 6 次提交
  24. 06 5月, 2014 1 次提交