1. 17 12月, 2017 2 次提交
    • M
      xtensa: add support for KASAN · c633544a
      Max Filippov 提交于
      Cover kernel addresses above 0x90000000 by the shadow map. Enable
      HAVE_ARCH_KASAN when MMU is enabled. Provide kasan_early_init that fills
      shadow map with writable copies of kasan_zero_page. Call
      kasan_early_init right after mmu initialization in the setup_arch.
      Provide kasan_init that allocates proper shadow map pages from the
      memblock and puts these pages into the shadow map for addresses from
      VMALLOC area to the end of KSEG. Call kasan_init right after memblock
      initialization. Don't use KASAN for the boot code, MMU and KASAN
      initialization and page fault handler. Make kernel stack size 4 times
      larger when KASAN is enabled to avoid stack overflows.
      GCC 7.3, 8 or newer is required to build the xtensa kernel with KASAN.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      c633544a
    • M
      xtensa: move fixmap and kmap just above the KSEG · 1af1e8a3
      Max Filippov 提交于
      The virtual address space between the page table and the VMALLOC region
      is big enough to host KASAN shadow map and there's enough space between
      the VMALLOC area and KSEG for the fixmap and kmap.
      Move fixmap and kmap to the gap between VMALLOC area and KSEG, just
      above the KSEG. Reorder entries in the kernel memory layout printing
      code. Drop duplicate PGTABLE_START definition, use
      XCHAL_PAGE_TABLE_VADDR instead.
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      1af1e8a3
  2. 23 6月, 2017 1 次提交
    • F
      of: update ePAPR references to point to Devicetree Specification · 076fb0c4
      Frank Rowand 提交于
      The Devicetree Specification has superseded the ePAPR as the
      base specification for bindings.  Update files in Documentation
      to reference the new document.
      
      First reference to ePAPR in Documentation/devicetree/bindings/arm/cci.txt
      is generic, remove it.
      
      Some files are not updated because there is no hypervisor chapter
      in the Devicetree Specification:
         Documentation/devicetree/bindings/powerpc/fsl/msi-pic.txt
         Documenation/virtual/kvm/api.txt
         Documenation/virtual/kvm/ppc-pv.txt
      Signed-off-by: NFrank Rowand <frank.rowand@sony.com>
      Signed-off-by: NRob Herring <robh@kernel.org>
      076fb0c4
  3. 24 7月, 2016 2 次提交
    • 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
  4. 15 1月, 2014 1 次提交
    • B
      xtensa: remap io area defined in device tree · 6cb97111
      Baruch Siach 提交于
      Use the simple-bus node to discover the io area, and remap the cached and
      bypass io ranges. The parent-bus-address value of the first triplet in the
      "ranges" property is used. This value is rounded down to the nearest 256MB
      boundary. The length of the io area is fixed at 256MB; the "ranges" property
      length value is ignored.
      
      Other limitations: (1) only the first simple-bus node is considered, and (2)
      only the first triplet of the "ranges" property is considered.
      
      See ePAPR 1.1 §6.5 for the simple-bus node description, and §2.3.8 for the
      "ranges" property description.
      Signed-off-by: NBaruch Siach <baruch@tkos.co.il>
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      6cb97111
  5. 09 5月, 2013 1 次提交