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

[Xen-devel] [PATCH] x86: add feature flags to shared_info page



In order to indicate the Xen tools capability to support the virtual
mapped linear p2m list instead the 3 level mfn tree add feature flags
to the shared_info page.

Signed-off-by: Juergen Gross <jgross@xxxxxxxx>
---
 tools/include/xen-foreign/reference.size |  4 ++--
 xen/include/public/arch-x86/xen.h        | 10 ++++++++++
 2 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/tools/include/xen-foreign/reference.size 
b/tools/include/xen-foreign/reference.size
index a0409db..9fb1eda 100644
--- a/tools/include/xen-foreign/reference.size
+++ b/tools/include/xen-foreign/reference.size
@@ -9,6 +9,6 @@ vcpu_guest_context        |     344     344    2800    5168
 arch_vcpu_info            |       0       0      24      16
 vcpu_time_info            |      32      32      32      32
 vcpu_info                 |      48      48      64      64
-arch_shared_info          |       0       0      28      48
-shared_info               |    1088    1088    2344    3136
+arch_shared_info          |       0       0      32      56
+shared_info               |    1088    1088    2348    3144
 
diff --git a/xen/include/public/arch-x86/xen.h 
b/xen/include/public/arch-x86/xen.h
index 232d4a5..ee3b5da 100644
--- a/xen/include/public/arch-x86/xen.h
+++ b/xen/include/public/arch-x86/xen.h
@@ -231,6 +231,9 @@ struct arch_shared_info {
      * been set to invalid e.g. due to the p2m being too large for the 3-level
      * p2m tree. In this case the linear mapper p2m list anchored at p2m_vaddr
      * is to be used.
+     * There is no need for the guest to set pfn_to_mfn_frame_list_list when
+     * Xen indicates the support of the linear mapped p2m list by having set
+     * XEN_FEATURE_P2M_VIRTUAL in features.
      */
     xen_pfn_t     pfn_to_mfn_frame_list_list;
     unsigned long nmi_reason;
@@ -259,6 +262,13 @@ struct arch_shared_info {
     /* There's no room for this field in the generic structure. */
     uint32_t wc_sec_hi;
 #endif
+    /* Features supported by Xen (hypervisor and/or tools) */
+    uint32_t features;
+    /*
+     * Xen supports the linear mapped p2m list, pfn_to_mfn_frame_list_list
+     * isn't required if p2m_cr3 and p2m_vaddr are specified by the guest.
+     */
+#define XEN_FEATURE_P2M_VIRTUAL (1 << 0)
 };
 typedef struct arch_shared_info arch_shared_info_t;
 
-- 
2.1.4


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


 


Rackspace

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