ia64/xen-unstable
changeset 3893:1e288d225372
bitkeeper revision 1.1236 (421b49e0jUTlkllzShzryRgPs9Q-vg)
Fix x86/64 build.
Signed-off-by: Keir Fraser <keir.fraser@cl.cam.ac.uk>
Fix x86/64 build.
Signed-off-by: Keir Fraser <keir.fraser@cl.cam.ac.uk>
author | kaf24@scramble.cl.cam.ac.uk |
---|---|
date | Tue Feb 22 15:04:00 2005 +0000 (2005-02-22) |
parents | ff8c9a2be5f7 |
children | b57a97bb65bd 2d98340a3776 256ed63cbd2c |
files | xen/arch/x86/shadow.c xen/include/asm-x86/domain.h xen/include/asm-x86/shadow.h |
line diff
1.1 --- a/xen/arch/x86/shadow.c Tue Feb 22 14:28:58 2005 +0000 1.2 +++ b/xen/arch/x86/shadow.c Tue Feb 22 15:04:00 2005 +0000 1.3 @@ -453,7 +453,12 @@ void unshadow_table(unsigned long gpfn, 1.4 free_shadow_page(d, &frame_table[smfn]); 1.5 } 1.6 1.7 -#ifdef CONFIG_VMX 1.8 +/* 1.9 + * XXX KAF: 1.10 + * 1. Why is this VMX specific? 1.11 + * 2. Why is VMX using clear_state() rather than free_state()? 1.12 + * (could we get rid of clear_state and fold into free_state?) 1.13 + */ 1.14 void vmx_shadow_clear_state(struct domain *d) 1.15 { 1.16 SH_VVLOG("vmx_clear_shadow_state:"); 1.17 @@ -461,8 +466,6 @@ void vmx_shadow_clear_state(struct domai 1.18 clear_shadow_state(d); 1.19 shadow_unlock(d); 1.20 } 1.21 -#endif 1.22 - 1.23 1.24 unsigned long shadow_l2_table( 1.25 struct domain *d, unsigned long gmfn) 1.26 @@ -582,6 +585,10 @@ void shadow_invlpg(struct exec_domain *e 1.27 1.28 ASSERT(shadow_mode_enabled(ed->domain)); 1.29 1.30 + /* 1.31 + * XXX KAF: Why is this set-to-zero required? 1.32 + * Why, on failure, must we bin all our shadow state? 1.33 + */ 1.34 if (__put_user(0L, (unsigned long *) 1.35 &shadow_linear_pg_table[va >> PAGE_SHIFT])) { 1.36 vmx_shadow_clear_state(ed->domain);
2.1 --- a/xen/include/asm-x86/domain.h Tue Feb 22 14:28:58 2005 +0000 2.2 +++ b/xen/include/asm-x86/domain.h Tue Feb 22 15:04:00 2005 +0000 2.3 @@ -91,9 +91,9 @@ struct arch_exec_domain 2.4 struct desc_struct fast_trap_desc; 2.5 #endif 2.6 trap_info_t traps[256]; 2.7 -#ifdef CONFIG_VMX 2.8 - struct arch_vmx_struct arch_vmx; /* Virtual Machine Extensions */ 2.9 -#endif 2.10 + 2.11 + /* Virtual Machine Extensions */ 2.12 + struct arch_vmx_struct arch_vmx; 2.13 2.14 /* 2.15 * Every domain has a L1 pagetable of its own. Per-domain mappings
3.1 --- a/xen/include/asm-x86/shadow.h Tue Feb 22 14:28:58 2005 +0000 3.2 +++ b/xen/include/asm-x86/shadow.h Tue Feb 22 15:04:00 2005 +0000 3.3 @@ -7,10 +7,7 @@ 3.4 #include <xen/types.h> 3.5 #include <xen/perfc.h> 3.6 #include <asm/processor.h> 3.7 - 3.8 -#ifdef CONFIG_VMX 3.9 #include <asm/domain_page.h> 3.10 -#endif 3.11 3.12 /* Shadow PT flag bits in pfn_info */ 3.13 #define PSH_shadowed (1<<31) /* page has a shadow. PFN points to shadow */ 3.14 @@ -48,9 +45,7 @@ extern int shadow_mode_enable(struct dom 3.15 extern void free_shadow_state(struct domain *d); 3.16 extern void shadow_invlpg(struct exec_domain *, unsigned long); 3.17 3.18 -#ifdef CONFIG_VMX 3.19 extern void vmx_shadow_clear_state(struct domain *); 3.20 -#endif 3.21 3.22 #define __mfn_to_gpfn(_d, mfn) \ 3.23 ( (shadow_mode_translate(_d)) \ 3.24 @@ -654,8 +649,6 @@ static inline void set_shadow_status( 3.25 shadow_audit(d, 0); 3.26 } 3.27 3.28 -#ifdef CONFIG_VMX 3.29 - 3.30 static inline unsigned long gva_to_gpte(unsigned long gva) 3.31 { 3.32 unsigned long gpde, gpte, pfn, index; 3.33 @@ -691,8 +684,6 @@ static inline unsigned long gva_to_gpa(u 3.34 return (gpte & PAGE_MASK) + (gva & ~PAGE_MASK); 3.35 } 3.36 3.37 -#endif /* CONFIG_VMX */ 3.38 - 3.39 static inline void __update_pagetables(struct exec_domain *ed) 3.40 { 3.41 struct domain *d = ed->domain;