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

[Xen-devel] [PATCH 08/10] x86/shadow: adjust sh_{make, destroy}_monitor_table() name tags



Instead of the misleading _guest_<level> ones use _sh_<level>,
expressing their sole dependency on the number of shadow levels.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>

--- a/xen/arch/x86/mm/shadow/multi.h
+++ b/xen/arch/x86/mm/shadow/multi.h
@@ -105,13 +105,6 @@ extern void
 SHADOW_INTERNAL_NAME(sh_guest_get_eff_l1e, GUEST_LEVELS)
     (struct vcpu *v, unsigned long va, void *eff_l1e);
 
-extern mfn_t
-SHADOW_INTERNAL_NAME(sh_make_monitor_table, GUEST_LEVELS)
-    (struct vcpu *v);
-extern void
-SHADOW_INTERNAL_NAME(sh_destroy_monitor_table, GUEST_LEVELS)
-    (struct vcpu *v, mfn_t mmfn);
-
 extern const struct paging_mode
 SHADOW_INTERNAL_NAME(sh_paging_mode, GUEST_LEVELS);
 
--- a/xen/arch/x86/mm/shadow/private.h
+++ b/xen/arch/x86/mm/shadow/private.h
@@ -151,10 +151,12 @@ extern void shadow_audit_tables(struct v
  * Macro for dealing with the naming of the internal names of the
  * shadow code's external entry points.
  */
-#define SHADOW_INTERNAL_NAME_HIDDEN(name, guest_levels) \
-    name ## __guest_ ## guest_levels
+#define SHADOW_INTERNAL_NAME_(name, kind, value)        \
+    name ## __ ## kind ## _ ## value
 #define SHADOW_INTERNAL_NAME(name, guest_levels)        \
-    SHADOW_INTERNAL_NAME_HIDDEN(name, guest_levels)
+    SHADOW_INTERNAL_NAME_(name, guest, guest_levels)
+#define SHADOW_SH_NAME(name, shadow_levels)             \
+    SHADOW_INTERNAL_NAME_(name, sh, shadow_levels)
 
 #define GUEST_LEVELS  2
 #include "multi.h"
--- a/xen/arch/x86/mm/shadow/types.h
+++ b/xen/arch/x86/mm/shadow/types.h
@@ -270,9 +270,12 @@ static inline shadow_l4e_t shadow_l4e_fr
 
 /* sh_make_monitor_table depends only on the number of shadow levels */
 #define sh_make_monitor_table \
-        SHADOW_INTERNAL_NAME(sh_make_monitor_table, SHADOW_PAGING_LEVELS)
+        SHADOW_SH_NAME(sh_make_monitor_table, SHADOW_PAGING_LEVELS)
 #define sh_destroy_monitor_table \
-        SHADOW_INTERNAL_NAME(sh_destroy_monitor_table, SHADOW_PAGING_LEVELS)
+        SHADOW_SH_NAME(sh_destroy_monitor_table, SHADOW_PAGING_LEVELS)
+
+mfn_t sh_make_monitor_table(struct vcpu *v);
+void sh_destroy_monitor_table(struct vcpu *v, mfn_t mmfn);
 
 #if SHADOW_PAGING_LEVELS == 3
 #define MFN_FITS_IN_HVM_CR3(_MFN) !(mfn_x(_MFN) >> 20)



Attachment: x86-sh-monitor-table-width.patch
Description: Text document

_______________________________________________
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®.