All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH v4 0/7] KVM: x86: Allow Qemu/KVM to use PVH entry point
@ 2018-02-28 18:27 ` Maran Wilson
  0 siblings, 0 replies; 85+ messages in thread
From: Maran Wilson @ 2018-02-28 18:27 UTC (permalink / raw)
  To: pbonzini, jgross, boris.ostrovsky, roger.pau, andrew.cooper3,
	hch, JBeulich, x86, xen-devel, linux-kernel, kvm
  Cc: tglx, mingo, hpa, rkrcmar, jpoimboe, bp, kirill.shutemov,
	thomas.lendacky, luto, maran.wilson, dave.hansen, davem, gregkh,
	mchehab, linus.walleij, rdunlap


Sorry for the delay between this version and the last -- it was mostly
due to holidays and everyone being focused on security bug mitigation
issues. Here are the links to the previous email threads in case it is
helpful:

V3: https://lkml.org/lkml/2017/12/12/1230
V2: https://lkml.org/lkml/2017/12/7/1624
V1: https://lkml.org/lkml/2017/11/28/1280

Changes from v3:

 * Implemented Juergen's suggestion for refactoring and moving the PVH
   code so that CONFIG_XEN is no longer required for booting KVM guests
   via the PVH entry point.
   Functionally, nothing has changed from V3 really, but the patches
   look completely different now because of all the code movement and
   refactoring. Some of these patches can be combined, but I've left
   them very small in some cases to make the refactoring and code
   movement easier to review.
   My approach for refactoring has been to create a PVH entry layer that
   still has understanding and knowledge about Xen vs non-Xen guest types
   so that it can make run time decisions to handle either case, as
   opposed to going all the way and re-writing it to be a completely
   hypervisor agnostic and architecturally pure layer that is separate
   from guest type details. The latter seemed a bit overkill in this
   situation. And I've handled the complexity of having to support
   Qemu/KVM boot of kernels compiled with or without CONFIG_XEN via a
   pair of xen specific __weak routines that can be overridden in kernels
   that support Xen guests. Importantly, the __weak routines are for
   xen specific code only (not generic "guest type" specific code) so
   there is no clashing between xen version of the strong routine and,
   say, a KVM version of the same routine. But I'm sure there are many
   ways to skin this cat, so I'm open to alternate suggestions if there
   is a compelling reason for not using __weak in this situation.

Changes from v2:

 * All structures (including memory map table entries) are padded and
   aligned to an 8 byte boundary.

 * Removed the "packed" attributes and made changes to comments as
   suggested by Jan.

Changes from v1:

 * Adopted Paolo's suggestion for defining a v2 PVH ABI that includes the
   e820 map instead of using the second module entry to pass the table.

 * Cleaned things up a bit to reduce the number of xen vs non-xen special
   cases.

Maran Wilson (7):
      xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH
      xen/pvh: Move PVH entry code out of Xen specific tree
      xen/pvh: Create a new file for Xen specific PVH code
      xen/pvh: Move Xen specific PVH VM initialization out of common code
      xen/pvh: Move Xen code for getting mem map via hcall out of common file
      xen/pvh: Add memory map pointer to hvm_start_info struct
      KVM: x86: Allow Qemu/KVM to use PVH entry point

 MAINTAINERS                            |   1 +
 arch/x86/Kbuild                        |   3 +
 arch/x86/Kconfig                       |   8 ++
 arch/x86/kernel/head_64.S              |   4 +-
 arch/x86/pvh-head.S                    | 161 +++++++++++++++++++++++
 arch/x86/pvh.c                         | 130 ++++++++++++++++++
 arch/x86/xen/Kconfig                   |   3 +-
 arch/x86/xen/Makefile                  |   1 -
 arch/x86/xen/enlighten_pvh.c           |  87 +++---------
 arch/x86/xen/xen-pvh.S                 | 161 -----------------------
 include/xen/interface/hvm/start_info.h |  50 ++++++-
 11 files changed, 374 insertions(+), 235 deletions(-)

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

end of thread, other threads:[~2018-03-20 20:56 UTC | newest]

Thread overview: 85+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-28 18:27 [RFC PATCH v4 0/7] KVM: x86: Allow Qemu/KVM to use PVH entry point Maran Wilson
2018-02-28 18:27 ` Maran Wilson
2018-02-28 18:27 ` [RFC PATCH v4 1/7] xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH Maran Wilson
2018-02-28 18:27 ` Maran Wilson
2018-02-28 21:07   ` Konrad Rzeszutek Wilk
2018-02-28 21:07   ` [Xen-devel] " Konrad Rzeszutek Wilk
2018-03-01  5:43     ` Juergen Gross
2018-03-01  5:43     ` [Xen-devel] " Juergen Gross
2018-03-01  7:19   ` Juergen Gross
2018-03-01  7:19   ` Juergen Gross
2018-03-01 15:02   ` Boris Ostrovsky
2018-03-01 15:02   ` Boris Ostrovsky
2018-03-01 15:17     ` Paolo Bonzini
2018-03-01 15:17     ` Paolo Bonzini
2018-03-01 17:24       ` Maran Wilson
2018-03-01 17:24       ` Maran Wilson
2018-02-28 18:27 ` [RFC PATCH v4 2/7] xen/pvh: Move PVH entry code out of Xen specific tree Maran Wilson
2018-02-28 21:08   ` [Xen-devel] " Konrad Rzeszutek Wilk
2018-02-28 21:35     ` Paolo Bonzini
2018-02-28 21:35     ` [Xen-devel] " Paolo Bonzini
2018-03-01  6:11       ` Juergen Gross
2018-03-01  6:11       ` [Xen-devel] " Juergen Gross
2018-03-01  8:46         ` Paolo Bonzini
2018-03-01 16:15           ` Boris Ostrovsky
2018-03-01 16:15           ` [Xen-devel] " Boris Ostrovsky
2018-03-01  8:46         ` Paolo Bonzini
2018-03-01 17:22       ` [Xen-devel] " Maran Wilson
2018-03-01 17:22       ` Maran Wilson
2018-02-28 21:08   ` Konrad Rzeszutek Wilk
2018-02-28 18:27 ` Maran Wilson
2018-02-28 18:27 ` [RFC PATCH v4 3/7] xen/pvh: Create a new file for Xen specific PVH code Maran Wilson
2018-02-28 18:27 ` Maran Wilson
2018-02-28 21:09   ` Konrad Rzeszutek Wilk
2018-02-28 21:09   ` [Xen-devel] " Konrad Rzeszutek Wilk
2018-02-28 18:28 ` [RFC PATCH v4 4/7] xen/pvh: Move Xen specific PVH VM initialization out of common code Maran Wilson
2018-02-28 21:10   ` [Xen-devel] " Konrad Rzeszutek Wilk
2018-02-28 21:10     ` Konrad Rzeszutek Wilk
2018-03-01  7:20   ` Juergen Gross
2018-03-01  7:20   ` Juergen Gross
2018-03-01 16:05   ` Boris Ostrovsky
2018-03-01 17:43     ` Maran Wilson
2018-03-01 17:43     ` Maran Wilson
2018-03-01 16:05   ` Boris Ostrovsky
2018-02-28 18:28 ` Maran Wilson
2018-02-28 18:28 ` [RFC PATCH v4 5/7] xen/pvh: Move Xen code for getting mem map via hcall out of common file Maran Wilson
2018-03-01  7:21   ` Juergen Gross
2018-03-01  7:21   ` Juergen Gross
2018-02-28 18:28 ` Maran Wilson
2018-02-28 18:28 ` [RFC PATCH v4 6/7] xen/pvh: Add memory map pointer to hvm_start_info struct Maran Wilson
2018-02-28 18:28 ` Maran Wilson
2018-03-01  7:29   ` Juergen Gross
2018-03-01  7:29   ` Juergen Gross
2018-03-01  7:41     ` Jan Beulich
2018-03-01  7:41       ` Jan Beulich
2018-03-01 17:19       ` Maran Wilson
2018-03-01 17:19       ` Maran Wilson
2018-03-01  7:41     ` Jan Beulich
2018-03-01 15:23   ` [Xen-devel] " Konrad Rzeszutek Wilk
2018-03-01 15:23     ` Konrad Rzeszutek Wilk
2018-02-28 18:28 ` [RFC PATCH v4 7/7] KVM: x86: Allow Qemu/KVM to use PVH entry point Maran Wilson
2018-02-28 18:28 ` Maran Wilson
2018-03-01  7:31   ` Juergen Gross
2018-03-01  7:31   ` Juergen Gross
2018-02-28 21:39 ` [RFC PATCH v4 0/7] " Paolo Bonzini
2018-02-28 21:39 ` Paolo Bonzini
2018-03-20 19:16 ` [PATCH v5 " Maran Wilson
2018-03-20 19:18   ` [PATCH v5 1/7] xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH Maran Wilson
2018-03-20 19:18   ` Maran Wilson
2018-03-20 19:23     ` Randy Dunlap
2018-03-20 20:55       ` Maran Wilson
2018-03-20 20:55       ` Maran Wilson
2018-03-20 19:23     ` Randy Dunlap
2018-03-20 19:18   ` [PATCH v5 2/7] xen/pvh: Move PVH entry code out of Xen specific tree Maran Wilson
2018-03-20 19:18   ` Maran Wilson
2018-03-20 19:19   ` [PATCH v5 3/7] xen/pvh: Create a new file for Xen specific PVH code Maran Wilson
2018-03-20 19:19   ` Maran Wilson
2018-03-20 19:19   ` [PATCH v5 4/7] xen/pvh: Move Xen specific PVH VM initialization out of common file Maran Wilson
2018-03-20 19:19   ` Maran Wilson
2018-03-20 19:19   ` [PATCH v5 5/7] xen/pvh: Move Xen code for getting mem map via hcall " Maran Wilson
2018-03-20 19:19   ` Maran Wilson
2018-03-20 19:20   ` [PATCH v5 6/7] xen/pvh: Add memory map pointer to hvm_start_info struct Maran Wilson
2018-03-20 19:20   ` Maran Wilson
2018-03-20 19:21   ` [PATCH v5 7/7] KVM: x86: Allow Qemu/KVM to use PVH entry point Maran Wilson
2018-03-20 19:21   ` Maran Wilson
2018-03-20 19:16 ` [PATCH v5 0/7] " Maran Wilson

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.