All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 00/30] PVHv2 Dom0
@ 2016-09-27 15:56 Roger Pau Monne
  2016-09-27 15:56 ` [PATCH v2 01/30] xen/x86: move setup of the VM86 TSS to the domain builder Roger Pau Monne
                   ` (30 more replies)
  0 siblings, 31 replies; 146+ messages in thread
From: Roger Pau Monne @ 2016-09-27 15:56 UTC (permalink / raw)
  To: xen-devel; +Cc: boris.ostrovsky

Hello,

This is the first "complete" PVHv2 implementation in the sense that
it has feature parity with classic PVH Dom0. It is still very experimental,
but I've managed to boot it on all Intel boxes I've tried (OK, only 3 so far).
I've also tried on an AMD box, but sadly the ACPI tables there didn't contain
any RMRR regions and the IOMMU started spitting a bunch of page faults caused
by devices trying to access memory regions marked as reserved in the e820.

Here is the list of most relevant changes compared to classic PVH or PV:

 - An emulated local APIC (for each vCPU) and IO APIC is provided to Dom0.
 - The MADT has been replaced in order to reflect the real topology seen by
   the guest. This needs a little bit more of work so that the new MADT is
   not placed over the old one.
 - BARs of PCI devices are automatically mapped by Xen into Dom0 memory space.
   Currently there's no support for changing the position of the BARs, and Xen
   will just crash the domain if this is attempted.
 - Interrupts from physical devices are configured and routed using native
   mechanism, PIRQs are not available to this PVH Dom0 implementation at all.
   Xen will automatically detect the features of the physical devices available
   to Dom0, and will setup traps/handlers in order to intercept all relevant
   configuration accesses.
 - Access to PCIe regions is also trapped by Xen, so configuration can be done
   using the IO ports or the memory mapped configuration areas, as supported
   by each device.
 - Some ACPI tables are zapped (it's signature is inverted) to prevent Dom0
   from poking at them, those are: HPET, SLIT, SRAT, MPST and PMTT.

I know this series is quite big, but I think some of the initial changes can
go in as bugfixes, which would help me reduce the size.

Thanks, Roger.

Changes in this series:
 docs/misc/printk-formats.txt                |    5 +
 docs/misc/xen-command-line.markdown         |   15 +
 tools/firmware/hvmloader/hvmloader.c        |   17 -
 tools/libxc/include/xc_dom.h                |    2 +-
 tools/libxc/xc_dom_x86.c                    |   16 +
 xen/arch/arm/domain.c                       |    2 +-
 xen/arch/arm/domain_build.c                 |   16 +-
 xen/arch/arm/kernel.c                       |    4 +-
 xen/arch/arm/percpu.c                       |    3 +-
 xen/arch/x86/domain.c                       |   30 +-
 xen/arch/x86/domain_build.c                 | 1003 +++++++++++++++++++++++---
 xen/arch/x86/e820.c                         |    2 +-
 xen/arch/x86/hvm/hvm.c                      |   26 +-
 xen/arch/x86/hvm/io.c                       |  921 +++++++++++++++++++++++-
 xen/arch/x86/hvm/ioreq.c                    |   11 +
 xen/arch/x86/hvm/irq.c                      |    9 +
 xen/arch/x86/hvm/svm/nestedsvm.c            |    8 +-
 xen/arch/x86/hvm/svm/vmcb.c                 |    5 +-
 xen/arch/x86/hvm/vioapic.c                  |   28 +-
 xen/arch/x86/hvm/vmsi.c                     | 1036 +++++++++++++++++++++++++++
 xen/arch/x86/mm/hap/hap.c                   |   22 +-
 xen/arch/x86/mm/p2m.c                       |   88 +--
 xen/arch/x86/mm/paging.c                    |   16 +
 xen/arch/x86/mm/shadow/common.c             |   10 +-
 xen/arch/x86/percpu.c                       |    3 +-
 xen/arch/x86/physdev.c                      |    9 +-
 xen/arch/x86/setup.c                        |   11 +
 xen/arch/x86/smpboot.c                      |    4 +-
 xen/arch/x86/traps.c                        |   39 -
 xen/common/kernel.c                         |    3 +-
 xen/common/kexec.c                          |    2 +-
 xen/common/page_alloc.c                     |    2 +-
 xen/common/tmem_xen.c                       |    2 +-
 xen/common/vsprintf.c                       |   15 +
 xen/common/xmalloc_tlsf.c                   |    6 +-
 xen/drivers/char/console.c                  |    6 +-
 xen/drivers/char/serial.c                   |    2 +-
 xen/drivers/passthrough/amd/iommu_init.c    |   17 +-
 xen/drivers/passthrough/amd/pci_amd_iommu.c |    3 +-
 xen/drivers/passthrough/io.c                |  148 +++-
 xen/drivers/passthrough/pci.c               |  438 ++++++++++-
 xen/drivers/passthrough/vtd/iommu.c         |   23 +-
 xen/include/asm-x86/domain.h                |   12 +-
 xen/include/asm-x86/e820.h                  |    1 +
 xen/include/asm-x86/event.h                 |    3 +
 xen/include/asm-x86/flushtlb.h              |    2 +-
 xen/include/asm-x86/hap.h                   |    2 +-
 xen/include/asm-x86/hvm/domain.h            |    4 +
 xen/include/asm-x86/hvm/io.h                |  251 +++++++
 xen/include/asm-x86/hvm/ioreq.h             |    1 +
 xen/include/asm-x86/irq.h                   |    5 +
 xen/include/asm-x86/msi.h                   |   34 +
 xen/include/asm-x86/p2m.h                   |    5 -
 xen/include/asm-x86/paging.h                |    7 +
 xen/include/asm-x86/shadow.h                |    8 +
 xen/include/public/arch-x86/xen.h           |    4 +-
 xen/include/xen/hvm/irq.h                   |    4 +
 xen/include/xen/iommu.h                     |    1 +
 xen/include/xen/mm.h                        |   12 +-
 xen/include/xen/p2m-common.h                |   30 +
 xen/include/xen/pci.h                       |   10 +
 xen/include/xen/pci_regs.h                  |    4 +
 62 files changed, 4031 insertions(+), 397 deletions(-)

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

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

end of thread, other threads:[~2016-10-28 13:49 UTC | newest]

Thread overview: 146+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-27 15:56 [PATCH v2 00/30] PVHv2 Dom0 Roger Pau Monne
2016-09-27 15:56 ` [PATCH v2 01/30] xen/x86: move setup of the VM86 TSS to the domain builder Roger Pau Monne
2016-09-28 15:35   ` Jan Beulich
2016-09-29 12:57     ` Roger Pau Monne
2016-09-27 15:56 ` [PATCH v2 02/30] xen/x86: remove XENFEAT_hvm_pirqs for PVHv2 guests Roger Pau Monne
2016-09-28 16:03   ` Jan Beulich
2016-09-29 14:17     ` Roger Pau Monne
2016-09-29 16:07       ` Jan Beulich
2016-09-27 15:56 ` [PATCH v2 03/30] xen/x86: fix parameters and return value of *_set_allocation functions Roger Pau Monne
2016-09-28  9:34   ` Tim Deegan
2016-09-29 10:39   ` Jan Beulich
2016-09-29 14:33     ` Roger Pau Monne
2016-09-29 16:09       ` Jan Beulich
2016-09-30 16:48   ` George Dunlap
2016-10-03  8:05   ` Paul Durrant
2016-10-06 11:33     ` Roger Pau Monne
2016-09-27 15:56 ` [PATCH v2 04/30] xen/x86: allow calling {sh/hap}_set_allocation with the idle domain Roger Pau Monne
2016-09-29 10:43   ` Jan Beulich
2016-09-29 14:37     ` Roger Pau Monne
2016-09-29 16:10       ` Jan Beulich
2016-09-30 16:56   ` George Dunlap
2016-09-30 16:56     ` George Dunlap
2016-09-27 15:57 ` [PATCH v2 05/30] xen/x86: assert that local_events_need_delivery is not called by " Roger Pau Monne
2016-09-29 10:45   ` Jan Beulich
2016-09-30  8:32     ` Roger Pau Monne
2016-09-30  8:59       ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 06/30] x86/paging: introduce paging_set_allocation Roger Pau Monne
2016-09-29 10:51   ` Jan Beulich
2016-09-29 14:51     ` Roger Pau Monne
2016-09-29 16:12       ` Jan Beulich
2016-09-29 16:57         ` Roger Pau Monne
2016-09-30 17:00   ` George Dunlap
2016-09-27 15:57 ` [PATCH v2 07/30] xen/x86: split the setup of Dom0 permissions to a function Roger Pau Monne
2016-09-29 13:47   ` Jan Beulich
2016-09-29 15:53     ` Roger Pau Monne
2016-09-27 15:57 ` [PATCH v2 08/30] xen/x86: do the PCI scan unconditionally Roger Pau Monne
2016-09-29 13:55   ` Jan Beulich
2016-09-29 15:11     ` Roger Pau Monne
2016-09-29 16:14       ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 09/30] x86/vtd: fix and simplify mapping RMRR regions Roger Pau Monne
2016-09-29 14:18   ` Jan Beulich
2016-09-30 11:27     ` Roger Pau Monne
2016-09-30 13:21       ` Jan Beulich
2016-09-30 15:02         ` Roger Pau Monne
2016-09-30 15:09           ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 10/30] xen/x86: allow the emulated APICs to be enbled for the hardware domain Roger Pau Monne
2016-09-29 14:26   ` Jan Beulich
2016-09-30 15:44     ` Roger Pau Monne
2016-09-27 15:57 ` [PATCH v2 11/30] xen/x86: split Dom0 build into PV and PVHv2 Roger Pau Monne
2016-09-30 15:03   ` Jan Beulich
2016-10-03 10:09     ` Roger Pau Monne
2016-10-04  6:54       ` Jan Beulich
2016-10-04  7:09         ` Andrew Cooper
2016-09-27 15:57 ` [PATCH v2 12/30] xen/x86: make print_e820_memory_map global Roger Pau Monne
2016-09-30 15:04   ` Jan Beulich
2016-10-03 16:23     ` Roger Pau Monne
2016-10-04  6:47       ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 13/30] xen: introduce a new format specifier to print sizes in human-readable form Roger Pau Monne
2016-09-28  8:24   ` Juergen Gross
2016-09-28 11:56     ` Roger Pau Monne
2016-09-28 12:01       ` Andrew Cooper
2016-10-03  8:36   ` Paul Durrant
2016-10-11 10:27   ` Roger Pau Monne
2016-09-27 15:57 ` [PATCH v2 14/30] xen/mm: add a ceil sufix to current page calculation routine Roger Pau Monne
2016-09-30 15:20   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 15/30] xen/x86: populate PVHv2 Dom0 physical memory map Roger Pau Monne
2016-09-30 15:52   ` Jan Beulich
2016-10-04  9:12     ` Roger Pau Monne
2016-10-04 11:16       ` Jan Beulich
2016-10-11 14:01         ` Roger Pau Monne
2016-10-12 11:51           ` Jan Beulich
2016-10-11 14:06     ` Roger Pau Monne
2016-10-12 11:58       ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 16/30] xen/x86: parse Dom0 kernel for PVHv2 Roger Pau Monne
2016-10-06 15:14   ` Jan Beulich
2016-10-11 15:02     ` Roger Pau Monne
2016-09-27 15:57 ` [PATCH v2 17/30] xen/x86: setup PVHv2 Dom0 CPUs Roger Pau Monne
2016-10-06 15:20   ` Jan Beulich
2016-10-12 11:06     ` Roger Pau Monne
2016-10-12 11:32       ` Andrew Cooper
2016-10-12 12:02       ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 18/30] xen/x86: setup PVHv2 Dom0 ACPI tables Roger Pau Monne
2016-10-06 15:40   ` Jan Beulich
2016-10-06 15:48     ` Andrew Cooper
2016-10-12 15:35     ` Roger Pau Monne
2016-10-12 15:55       ` Jan Beulich
2016-10-26 11:35         ` Roger Pau Monne
2016-10-26 14:10           ` Jan Beulich
2016-10-26 15:08             ` Roger Pau Monne
2016-10-26 15:16               ` Jan Beulich
2016-10-26 16:03                 ` Roger Pau Monne
2016-10-27  7:25                   ` Jan Beulich
2016-10-27 11:08                     ` Roger Pau Monne
2016-10-26 17:14                 ` Boris Ostrovsky
2016-10-27  7:27                   ` Jan Beulich
2016-10-27 11:13                   ` Roger Pau Monne
2016-10-27 11:25                     ` Jan Beulich
2016-10-27 13:51                     ` Boris Ostrovsky
2016-10-27 14:02                       ` Jan Beulich
2016-10-27 14:15                         ` Boris Ostrovsky
2016-10-27 14:30                           ` Jan Beulich
2016-10-27 14:40                             ` Boris Ostrovsky
2016-10-27 15:04                               ` Roger Pau Monne
2016-10-27 15:20                                 ` Jan Beulich
2016-10-27 15:37                                   ` Roger Pau Monne
2016-10-28 13:51                                 ` Boris Ostrovsky
2016-09-27 15:57 ` [PATCH v2 19/30] xen/dcpi: add a dpci passthrough handler for hardware domain Roger Pau Monne
2016-10-03  9:02   ` Paul Durrant
2016-10-06 14:31     ` Roger Pau Monne
2016-10-06 15:44   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 20/30] xen/x86: add the basic infrastructure to import QEMU passthrough code Roger Pau Monne
2016-10-03  9:54   ` Paul Durrant
2016-10-06 15:08     ` Roger Pau Monne
2016-10-06 15:52       ` Lars Kurth
2016-10-07  9:13       ` Jan Beulich
2016-10-06 15:47   ` Jan Beulich
2016-10-10 12:41   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 21/30] xen/pci: split code to size BARs from pci_add_device Roger Pau Monne
2016-10-06 16:00   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 22/30] xen/x86: support PVHv2 Dom0 BAR remapping Roger Pau Monne
2016-10-03 10:10   ` Paul Durrant
2016-10-06 15:25     ` Roger Pau Monne
2016-09-27 15:57 ` [PATCH v2 23/30] xen/x86: route legacy PCI interrupts to Dom0 Roger Pau Monne
2016-10-10 13:37   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 24/30] x86/vmsi: add MSI emulation for hardware domain Roger Pau Monne
2016-09-27 15:57 ` [PATCH v2 25/30] xen/x86: add all PCI devices to PVHv2 Dom0 Roger Pau Monne
2016-10-10 13:44   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 26/30] xen/x86: add PCIe emulation Roger Pau Monne
2016-10-03 10:46   ` Paul Durrant
2016-10-06 15:53     ` Roger Pau Monne
2016-10-10 13:57   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 27/30] x86/msixtbl: disable MSI-X intercepts for domains without an ioreq server Roger Pau Monne
2016-10-10 14:18   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 28/30] xen/x86: add MSI-X emulation to PVHv2 Dom0 Roger Pau Monne
2016-10-03 10:57   ` Paul Durrant
2016-10-06 15:58     ` Roger Pau Monne
2016-10-10 16:15   ` Jan Beulich
2016-09-27 15:57 ` [PATCH v2 29/30] xen/x86: allow PVHv2 to perform foreign memory mappings Roger Pau Monne
2016-09-30 17:36   ` George Dunlap
2016-10-10 14:21   ` Jan Beulich
2016-10-10 14:27     ` George Dunlap
2016-10-10 14:50       ` Jan Beulich
2016-10-10 14:58         ` George Dunlap
2016-09-27 15:57 ` [PATCH v2 30/30] xen: allow setting the store pfn HVM parameter Roger Pau Monne
2016-10-03 11:01   ` Paul Durrant
2016-09-28 12:22 ` [PATCH v2 00/30] PVHv2 Dom0 Roger Pau Monne

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.