[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Minios-devel] [UNIKRAFT PATCHv5 00/46] Add arm64/kvm support for Unikraft



This patch series enable Unikraft on arm64/kvm. As we
haven't implemented GIC libraries and full timer support,
this patch series can ONLY work without uksched.

v1: 
https://lists.xenproject.org/archives/html/minios-devel/2018-03/msg00040.html
v2: 
https://lists.xenproject.org/archives/html/minios-devel/2018-04/msg00145.html
v3: https://github.com/Weichen81/unikraft for OSS demo
v4: 
https://lists.xenproject.org/archives/html/minios-devel/2018-07/msg00014.html

v4 -> v5:
 1. Base on latest upstream
 2. Fix some typos,
 3. Adjust some patches' order to make it more sensible,
 4. Drop bc command in Makefile function,
 5. Rewrite gcc_version_ge to replace test_gcc_version,
 6. Break down set_flags_if_gcc_version_ge,
 7. Modify the target processors' description,
 8. Using static inline functions to replace IOREG_ACCECSS macros,
 9. define inb/outb to UK_BUG() on Arm64,
10. Add comments to describe each pagetable size,
11. Rename PGD, PUD, PMD, PTE to L0, L1, L2, L3 page tables,
12. Add a source link to explain Arm64 QEMU/KVM memory layout,
13. Generate linker script from .S to share macros with source code,
14. Use macros in linker script to make it easier to understand,
15. Move console code to common foler,
16. Rename UART registers to REG_<REGNAME>_OFFSET,
17. Correct UART registers offset,
18. Use correct startoffset of searche UART node,
19. Parse the DT address based on address-cells and size-cells,
20. Mask and clear UART interrupts in UART initialization,
21. Move PL011 code to plat/common/arm,
22. Use Config.uk to define early debug console address,
23. Add 64-bytes alignment comment for boot stack,
24. Add cache maintenance functions by set/way,
25. Remove the support of FP&SIMD,
26. Add -mgeneral-regs-only to GCC flag to avoid using FP&SIMD registers,
27. Move virtual counter library to common,
28. Add counter workaround for Cortex-A73 erratum 858921,
29. Rename trap_handler to trap_el1_sync,
30. Remove el1_irq from vector table until GIC is ready,
31. Remove IRQ_handler until GIC is ready,
32. Move TRAP_STACK_SIZE to the same header of struct __regs,
33. Add mask IRQ to exception restore data,
34. Add brief comments to SCTLR bits,
35. Define SCTLR_RES0_x/SCTLR_RES1_x for reserved bits,
36. Invalidate cache before starting MMU,
37. Replace vmalle1is with vmalle1 for TLB invalidate,
38. Use pointer for cmdline instead of copying it,
39. Check address&size cells for DTB reg property,
40. Add warning for more than one memory bank,
41. Drop PSCI-0.1 support,
42. Add multiple parameters support for PSCI function,
43. Use WFI to implement halt instead of using PSCI suspend,
44. Move halt to loop,
45. Enable tscclock and PCI bus for x86_64 only.

Wei Chen (46):
  include: Reorganize base include folder to reflect CPU family schema
  build: Add a makefile function to check GCC version
  build: Add a makefile function to print error when GCC is too old
  arch/x86: Rename MARCH_* of x86_64 to MARCH_X86_64_*
  arch/arm: Rename MARCH_* of arm32 to MARCH_ARM32_*
  arch: Add arm64 architecture config to menuconfig
  arch: Rename ARMv7 to Armv7 in Kconfig
  arch/arm64: Add processor optimization GCC flags for arm64
  arch/arm: Check gcc version and set processor flags for arm32
  arch/arm: Add more CPU models to processor optimization list
  build: Override default pie option of GCC if possible
  uk/arch: Add necessary header files for Arm64
  uk/arch: Implement ukarch_ffsl for Arm64
  plat/include: Define macros for Arm64 to access registers
  plat/include: Define address offsets of boot stack and pagetable
  plat/kvm: Generate linker scripts from source code
  plat/kvm: Add linker script for Arm64
  plat/kvm: Add Arm64 basic entry code
  plat: Add variables in Config.uk for early debug console
  plat/common: Add early debug console library for Arm64
  plat/common: Add cache maintenance support for arm64
  arch/arm64: Avoid using the floating-point and Advanced SIMD registers
  plat/kvm: Enable tscclock for x86_64 only
  plat/kvm: Introduce a time_ops for different architectures
  plat/kvm: Add Arm64 virtual timer library to provide ticks
  plat/common: Add counter workaround for Cortex-A73 erratum 858921
  plat/common: Common arm64 CPU interrupt flag handling
  plat/kvm: Add interrupt handle APIs for arm64
  plat/kvm: Add trap handler to dump registers
  plat/kvm: Add exception table for Arm64
  plat/kvm: Create page tables for Arm64
  plat/kvm: Enable MMU for Arm64
  plat/kvm: Initialize device tree for Arm64
  plat/kvm: Initialize console from device tree for Arm64
  plat/kvm: Parse command line from device tree for Arm64
  plat/kvm: Parse memory info from device tree for Arm64
  plat/common: Implement PSCI despatch functions for arm64
  plat/kvm: Get PSCI conduit method from DTB for Arm64
  plat/common: Implement CPU halt function for arm64
  plat/common: Implement CPU reset for arm64
  plat/common: Implement system off for arm64
  plat/kvm: Implement shutdown for Arm64
  plat/kvm: Swith away from boot stack
  plat/kvm: Update linker.uk to link image for Arm64
  plat/kvm: Implement time_block_until for arm64
  plat/kvm: Build pci bus for x86_64 only

 Config.uk                                     |   2 +-
 Makefile                                      |   4 +
 Makefile.uk                                   |  21 +-
 arch/Arch.uk                                  |   2 +
 arch/Config.uk                                |   8 +-
 arch/arm/Compiler.uk                          |   4 +
 arch/arm/Makefile.uk                          |   4 +
 arch/arm/arm/Config.uk                        |   6 +-
 arch/arm/arm/Makefile.uk                      |  80 +++-
 arch/arm/arm64/Compiler.uk                    |   6 +
 arch/arm/arm64/Config.uk                      |  57 +++
 arch/arm/arm64/Makefile.uk                    |  59 +++
 arch/x86/x86_64/Config.uk                     |  34 +-
 arch/x86/x86_64/Makefile.uk                   |  60 +--
 include/uk/arch/arm/{ => arm}/atomic.h        |   0
 include/uk/arch/arm/{ => arm}/intsizes.h      |   0
 include/uk/arch/arm/{ => arm}/lcpu.h          |   0
 include/uk/arch/arm/{ => arm}/limits.h        |   0
 include/uk/arch/arm/{ => arm}/types.h         |   0
 include/uk/arch/arm/arm64/atomic.h            |  64 +++
 include/uk/arch/arm/arm64/intsizes.h          |  48 ++
 include/uk/arch/arm/arm64/lcpu.h              | 103 ++++
 include/uk/arch/arm/arm64/limits.h            |  48 ++
 include/uk/arch/{x86_64 => arm/arm64}/types.h |   0
 include/uk/arch/atomic.h                      |   8 +-
 include/uk/arch/lcpu.h                        |   8 +-
 include/uk/arch/limits.h                      |  16 +-
 include/uk/arch/types.h                       |  16 +-
 include/uk/arch/{ => x86}/x86_64/atomic.h     |   0
 include/uk/arch/{ => x86}/x86_64/intsizes.h   |   0
 include/uk/arch/{ => x86}/x86_64/lcpu.h       |   0
 include/uk/arch/{ => x86}/x86_64/limits.h     |   0
 include/uk/arch/x86/x86_64/types.h            |  38 ++
 include/uk/plat/time.h                        |   8 +
 plat/common/arm/cache64.S                     |  98 ++++
 plat/common/arm/console.c                     | 196 ++++++++
 plat/common/arm/cpu_native.c                  |  59 +++
 plat/common/arm/psci_arm64.S                  |  55 +++
 plat/common/arm/time.c                        | 154 ++++++
 plat/common/arm/traps.c                       |  72 +++
 plat/common/include/arm/arm64/asm.h           |  77 +++
 plat/common/include/arm/arm64/cpu.h           | 106 +++++
 plat/common/include/arm/arm64/cpu_defs.h      | 324 +++++++++++++
 plat/common/include/arm/arm64/irq.h           | 105 +++++
 plat/common/include/arm/arm64/mm.h            |  86 ++++
 plat/common/include/arm/asm.h                 |  43 ++
 plat/common/include/arm/cpu.h                 |  44 ++
 plat/common/include/arm/cpu_defs.h            |  44 ++
 plat/common/include/arm/irq.h                 |  44 ++
 plat/common/include/arm/mm.h                  |  44 ++
 plat/common/include/asm.h                     |  43 ++
 plat/common/include/cpu.h                     |   4 +-
 plat/common/include/irq.h                     |  47 ++
 plat/common/include/mm.h                      |  44 ++
 plat/kvm/Config.uk                            |  14 +-
 plat/kvm/Linker.uk                            |  13 +-
 plat/kvm/Makefile.uk                          |  30 +-
 plat/kvm/arm/entry64.S                        | 112 +++++
 plat/kvm/arm/exceptions.S                     | 187 ++++++++
 plat/kvm/arm/intctrl.c                        |  54 +++
 plat/kvm/arm/lcpu.c                           |  70 +++
 plat/kvm/arm/link64.lds.S                     | 124 +++++
 plat/kvm/arm/pagetable.S                      | 438 ++++++++++++++++++
 plat/kvm/arm/setup.c                          | 213 +++++++++
 plat/kvm/shutdown.c                           |  11 +-
 plat/kvm/time.c                               |   7 +-
 plat/kvm/tscclock.c                           |   6 +
 plat/kvm/x86/{link64.ld => link64.lds.S}      |   0
 support/build/Makefile.rules                  |  12 +
 69 files changed, 3583 insertions(+), 101 deletions(-)
 create mode 100644 arch/arm/arm64/Compiler.uk
 create mode 100644 arch/arm/arm64/Config.uk
 create mode 100644 arch/arm/arm64/Makefile.uk
 rename include/uk/arch/arm/{ => arm}/atomic.h (100%)
 rename include/uk/arch/arm/{ => arm}/intsizes.h (100%)
 rename include/uk/arch/arm/{ => arm}/lcpu.h (100%)
 rename include/uk/arch/arm/{ => arm}/limits.h (100%)
 rename include/uk/arch/arm/{ => arm}/types.h (100%)
 create mode 100644 include/uk/arch/arm/arm64/atomic.h
 create mode 100644 include/uk/arch/arm/arm64/intsizes.h
 create mode 100644 include/uk/arch/arm/arm64/lcpu.h
 create mode 100644 include/uk/arch/arm/arm64/limits.h
 rename include/uk/arch/{x86_64 => arm/arm64}/types.h (100%)
 rename include/uk/arch/{ => x86}/x86_64/atomic.h (100%)
 rename include/uk/arch/{ => x86}/x86_64/intsizes.h (100%)
 rename include/uk/arch/{ => x86}/x86_64/lcpu.h (100%)
 rename include/uk/arch/{ => x86}/x86_64/limits.h (100%)
 create mode 100644 include/uk/arch/x86/x86_64/types.h
 create mode 100644 plat/common/arm/cache64.S
 create mode 100644 plat/common/arm/console.c
 create mode 100644 plat/common/arm/cpu_native.c
 create mode 100644 plat/common/arm/psci_arm64.S
 create mode 100644 plat/common/arm/time.c
 create mode 100644 plat/common/arm/traps.c
 create mode 100644 plat/common/include/arm/arm64/asm.h
 create mode 100644 plat/common/include/arm/arm64/cpu.h
 create mode 100644 plat/common/include/arm/arm64/cpu_defs.h
 create mode 100644 plat/common/include/arm/arm64/irq.h
 create mode 100644 plat/common/include/arm/arm64/mm.h
 create mode 100644 plat/common/include/arm/asm.h
 create mode 100644 plat/common/include/arm/cpu.h
 create mode 100644 plat/common/include/arm/cpu_defs.h
 create mode 100644 plat/common/include/arm/irq.h
 create mode 100644 plat/common/include/arm/mm.h
 create mode 100644 plat/common/include/asm.h
 create mode 100644 plat/common/include/irq.h
 create mode 100644 plat/common/include/mm.h
 create mode 100644 plat/kvm/arm/entry64.S
 create mode 100644 plat/kvm/arm/exceptions.S
 create mode 100644 plat/kvm/arm/intctrl.c
 create mode 100644 plat/kvm/arm/lcpu.c
 create mode 100644 plat/kvm/arm/link64.lds.S
 create mode 100644 plat/kvm/arm/pagetable.S
 create mode 100644 plat/kvm/arm/setup.c
 rename plat/kvm/x86/{link64.ld => link64.lds.S} (100%)

-- 
2.17.1


_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.