linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/17] HSM driver for ACRN hypervisor
@ 2020-08-25  2:45 shuo.a.liu
  2020-08-25  2:45 ` [PATCH 01/17] docs: acrn: Introduce ACRN shuo.a.liu
                   ` (16 more replies)
  0 siblings, 17 replies; 28+ messages in thread
From: shuo.a.liu @ 2020-08-25  2:45 UTC (permalink / raw)
  To: linux-kernel
  Cc: Greg Kroah-Hartman, H . Peter Anvin, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, Sean Christopherson, Yu Wang,
	Reinette Chatre, x86, Shuo Liu

From: Shuo Liu <shuo.a.liu@intel.com>

ACRN is a Type 1 reference hypervisor stack, running directly on the bare-metal
hardware, and is suitable for a variety of IoT and embedded device solutions.

ACRN implements a hybrid VMM architecture, using a privileged Service VM. The
Service VM manages the system resources (CPU, memory, etc.) and I/O devices of
User VMs. Multiple User VMs are supported, with each of them running Linux,
Android OS or Windows. Both Service VM and User VMs are guest VM.

Below figure shows the architecture.

                Service VM                    User VM
      +----------------------------+  |  +------------------+
      |        +--------------+    |  |  |                  |
      |        |ACRN userspace|    |  |  |                  |
      |        +--------------+    |  |  |                  |
      |-----------------ioctl------|  |  |                  |   ...
      |kernel space   +----------+ |  |  |                  |
      |               |   HSM    | |  |  | Drivers          |
      |               +----------+ |  |  |                  |
      +--------------------|-------+  |  +------------------+
  +---------------------hypercall----------------------------------------+
  |                       ACRN Hypervisor                                |
  +----------------------------------------------------------------------+
  |                          Hardware                                    |
  +----------------------------------------------------------------------+

There is only one Service VM which could run Linux as OS.

In a typical case, the Service VM will be auto started when ACRN Hypervisor is
booted. Then the ACRN userspace (an application running in Service VM) could be
used to start/stop User VMs by communicating with ACRN Hypervisor Service
Module (HSM).

ACRN Hypervisor Service Module (HSM) is a middle layer that allows the ACRN
userspace and Service VM OS kernel to communicate with ACRN Hypervisor
and manage different User VMs. This middle layer provides the following
functionalities,
  - Issues hypercalls to the hypervisor to manage User VMs:
      * VM/vCPU management
      * Memory management
      * Device passthrough
      * Interrupts injection
  - I/O requests handling from User VMs.
  - Exports ioctl through HSM char device.
  - Exports function calls for other kernel modules

ACRN is focused on embedded system. So it doesn't support some features.
E.g.,
  - ACRN doesn't support VM migration.
  - ACRN doesn't support vCPU migration.

This patch set adds the HSM to the Linux kernel.

The basic ARCN support was merged to upstream already.
https://lore.kernel.org/lkml/1559108037-18813-3-git-send-email-yakui.zhao@intel.com/

Shuo Liu (16):
  docs: acrn: Introduce ACRN
  x86/acrn: Introduce acrn_{setup, remove}_intr_handler()
  x86/acrn: Introduce hypercall interfaces
  virt: acrn: Introduce ACRN HSM basic driver
  virt: acrn: Introduce VM management interfaces
  virt: acrn: Introduce an ioctl to set vCPU registers state
  virt: acrn: Introduce EPT mapping management
  virt: acrn: Introduce I/O request management
  virt: acrn: Introduce PCI configuration space PIO accesses combiner
  virt: acrn: Introduce interfaces for PCI device passthrough
  virt: acrn: Introduce interrupt injection interfaces
  virt: acrn: Introduce interfaces to query C-states and P-states
    allowed by hypervisor
  virt: acrn: Introduce I/O ranges operation interfaces
  virt: acrn: Introduce ioeventfd
  virt: acrn: Introduce irqfd
  virt: acrn: Introduce an interface for Service VM to control vCPU

Yin Fengwei (1):
  x86/acrn: Introduce an API to check if a VM is privileged

 .../userspace-api/ioctl/ioctl-number.rst      |   1 +
 Documentation/virt/acrn/index.rst             |  11 +
 Documentation/virt/acrn/introduction.rst      |  40 ++
 Documentation/virt/acrn/io-request.rst        |  97 +++
 Documentation/virt/index.rst                  |   1 +
 MAINTAINERS                                   |   9 +
 arch/x86/include/asm/acrn.h                   |  74 ++
 arch/x86/kernel/cpu/acrn.c                    |  38 +-
 drivers/virt/Kconfig                          |   2 +
 drivers/virt/Makefile                         |   1 +
 drivers/virt/acrn/Kconfig                     |  15 +
 drivers/virt/acrn/Makefile                    |   3 +
 drivers/virt/acrn/acrn_drv.h                  | 225 ++++++
 drivers/virt/acrn/hsm.c                       | 439 ++++++++++++
 drivers/virt/acrn/hypercall.h                 | 266 ++++++++
 drivers/virt/acrn/ioeventfd.c                 | 275 ++++++++
 drivers/virt/acrn/ioreq.c                     | 638 ++++++++++++++++++
 drivers/virt/acrn/irqfd.c                     | 236 +++++++
 drivers/virt/acrn/mm.c                        | 298 ++++++++
 drivers/virt/acrn/vm.c                        | 120 ++++
 include/uapi/linux/acrn.h                     | 499 ++++++++++++++
 21 files changed, 3287 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/virt/acrn/index.rst
 create mode 100644 Documentation/virt/acrn/introduction.rst
 create mode 100644 Documentation/virt/acrn/io-request.rst
 create mode 100644 arch/x86/include/asm/acrn.h
 create mode 100644 drivers/virt/acrn/Kconfig
 create mode 100644 drivers/virt/acrn/Makefile
 create mode 100644 drivers/virt/acrn/acrn_drv.h
 create mode 100644 drivers/virt/acrn/hsm.c
 create mode 100644 drivers/virt/acrn/hypercall.h
 create mode 100644 drivers/virt/acrn/ioeventfd.c
 create mode 100644 drivers/virt/acrn/ioreq.c
 create mode 100644 drivers/virt/acrn/irqfd.c
 create mode 100644 drivers/virt/acrn/mm.c
 create mode 100644 drivers/virt/acrn/vm.c
 create mode 100644 include/uapi/linux/acrn.h


base-commit: 18445bf405cb331117bc98427b1ba6f12418ad17
-- 
2.28.0


^ permalink raw reply	[flat|nested] 28+ messages in thread

end of thread, other threads:[~2020-08-31  6:26 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-25  2:45 [PATCH 00/17] HSM driver for ACRN hypervisor shuo.a.liu
2020-08-25  2:45 ` [PATCH 01/17] docs: acrn: Introduce ACRN shuo.a.liu
2020-08-25  2:45 ` [PATCH 02/17] x86/acrn: Introduce acrn_{setup, remove}_intr_handler() shuo.a.liu
2020-08-25  2:45 ` [PATCH 03/17] x86/acrn: Introduce an API to check if a VM is privileged shuo.a.liu
2020-08-25  2:45 ` [PATCH 04/17] x86/acrn: Introduce hypercall interfaces shuo.a.liu
2020-08-25  2:45 ` [PATCH 05/17] virt: acrn: Introduce ACRN HSM basic driver shuo.a.liu
2020-08-28 10:25   ` Greg Kroah-Hartman
2020-08-29 10:46     ` Shuo A Liu
2020-08-29 16:12       ` Dave Hansen
2020-08-30  8:16         ` Shuo A Liu
2020-08-25  2:45 ` [PATCH 06/17] virt: acrn: Introduce VM management interfaces shuo.a.liu
2020-08-28 10:27   ` Greg Kroah-Hartman
2020-08-29 10:55     ` Shuo A Liu
2020-08-28 10:27   ` Greg Kroah-Hartman
2020-08-29 11:04     ` Shuo A Liu
2020-08-30  7:23       ` Greg Kroah-Hartman
2020-08-31  6:25         ` Shuo A Liu
2020-08-25  2:45 ` [PATCH 07/17] virt: acrn: Introduce an ioctl to set vCPU registers state shuo.a.liu
2020-08-25  2:45 ` [PATCH 08/17] virt: acrn: Introduce EPT mapping management shuo.a.liu
2020-08-25  2:45 ` [PATCH 09/17] virt: acrn: Introduce I/O request management shuo.a.liu
2020-08-25  2:45 ` [PATCH 10/17] virt: acrn: Introduce PCI configuration space PIO accesses combiner shuo.a.liu
2020-08-25  2:45 ` [PATCH 11/17] virt: acrn: Introduce interfaces for PCI device passthrough shuo.a.liu
2020-08-25  2:45 ` [PATCH 12/17] virt: acrn: Introduce interrupt injection interfaces shuo.a.liu
2020-08-25  2:45 ` [PATCH 13/17] virt: acrn: Introduce interfaces to query C-states and P-states allowed by hypervisor shuo.a.liu
2020-08-25  2:45 ` [PATCH 14/17] virt: acrn: Introduce I/O ranges operation interfaces shuo.a.liu
2020-08-25  2:45 ` [PATCH 15/17] virt: acrn: Introduce ioeventfd shuo.a.liu
2020-08-25  2:45 ` [PATCH 16/17] virt: acrn: Introduce irqfd shuo.a.liu
2020-08-25  2:45 ` [PATCH 17/17] virt: acrn: Introduce an interface for Service VM to control vCPU shuo.a.liu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).