aboutsummaryrefslogtreecommitdiffstats
path: root/xen/include/asm-x86/hvm
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2008-03-27 10:52:54 +0000
committerKeir Fraser <keir.fraser@citrix.com>2008-03-27 10:52:54 +0000
commit8c8df59519d782fc31b41e7d1ec276c105e4eb4a (patch)
treeea91fd4236aa91a1c1f1d74ebf6a76c8ebf567d9 /xen/include/asm-x86/hvm
parent54e034136e4c4655f728edb332fb35195f1a3f13 (diff)
downloadxen-8c8df59519d782fc31b41e7d1ec276c105e4eb4a.tar.gz
xen-8c8df59519d782fc31b41e7d1ec276c105e4eb4a.tar.bz2
xen-8c8df59519d782fc31b41e7d1ec276c105e4eb4a.zip
x86_emulate: On HVM MMIO emulation, cache the gva->pfn mapping for the
MMIO page. Speeds up Windows installation by about 20 percent. Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Diffstat (limited to 'xen/include/asm-x86/hvm')
-rw-r--r--xen/include/asm-x86/hvm/io.h1
-rw-r--r--xen/include/asm-x86/hvm/vcpu.h9
2 files changed, 10 insertions, 0 deletions
diff --git a/xen/include/asm-x86/hvm/io.h b/xen/include/asm-x86/hvm/io.h
index 8fd631d8cf..535f909d5a 100644
--- a/xen/include/asm-x86/hvm/io.h
+++ b/xen/include/asm-x86/hvm/io.h
@@ -99,6 +99,7 @@ static inline int register_buffered_io_handler(
void send_timeoffset_req(unsigned long timeoff);
void send_invalidate_req(void);
int handle_mmio(void);
+int handle_mmio_with_translation(unsigned long gva, unsigned long gpfn);
void hvm_interrupt_post(struct vcpu *v, int vector, int type);
void hvm_io_assist(void);
void hvm_dpci_eoi(struct domain *d, unsigned int guest_irq,
diff --git a/xen/include/asm-x86/hvm/vcpu.h b/xen/include/asm-x86/hvm/vcpu.h
index 0c76551575..d3281d20dc 100644
--- a/xen/include/asm-x86/hvm/vcpu.h
+++ b/xen/include/asm-x86/hvm/vcpu.h
@@ -80,6 +80,15 @@ struct hvm_vcpu {
/* I/O request in flight to device model. */
enum hvm_io_state io_state;
unsigned long io_data;
+
+ /*
+ * HVM emulation:
+ * Virtual address @mmio_gva maps to MMIO physical frame @mmio_gpfn.
+ * The latter is known to be an MMIO frame (not RAM).
+ * This translation is only valid if @mmio_gva is non-zero.
+ */
+ unsigned long mmio_gva;
+ unsigned long mmio_gpfn;
};
#endif /* __ASM_X86_HVM_VCPU_H__ */