summaryrefslogtreecommitdiff
path: root/target-i386/cpu.h
diff options
context:
space:
mode:
authorBlue Swirl <blauwirbel@gmail.com>2011-05-16 19:38:48 +0000
committerBlue Swirl <blauwirbel@gmail.com>2011-06-26 18:25:19 +0000
commite694d4e289b05d0c9b118850eff961aa9ca33183 (patch)
tree25e25d221dd1d2c8486d9ab4ab342e6892d12866 /target-i386/cpu.h
parente67768d0f13c78144f17bcca8a64b9b812918198 (diff)
downloadqemu-e694d4e289b05d0c9b118850eff961aa9ca33183.tar.gz
qemu-e694d4e289b05d0c9b118850eff961aa9ca33183.tar.bz2
qemu-e694d4e289b05d0c9b118850eff961aa9ca33183.zip
x86: use caller supplied CPUState for interrupt related stuff
Several x86 specific functions are called from cpu-exec.c with the assumption that global env register is valid. This will be changed later, so make the functions use caller supplied CPUState parameter. It would be cleaner to move the functions to helper.c, but there are quite a lot of dependencies between do_interrupt() and other functions. Add helpers for svm_check_intercept() and cpu_cc_compute_all() instead of calling the helper (which uses global env, AREG0) directly. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Diffstat (limited to 'target-i386/cpu.h')
-rw-r--r--target-i386/cpu.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/target-i386/cpu.h b/target-i386/cpu.h
index cdf68ffd99..656d360716 100644
--- a/target-i386/cpu.h
+++ b/target-i386/cpu.h
@@ -1000,4 +1000,14 @@ void cpu_x86_inject_mce(Monitor *mon, CPUState *cenv, int bank,
uint64_t status, uint64_t mcg_status, uint64_t addr,
uint64_t misc, int flags);
+/* op_helper.c */
+void do_interrupt(CPUState *env);
+void do_interrupt_x86_hardirq(CPUState *env, int intno, int is_hw);
+
+void do_smm_enter(CPUState *env1);
+
+void svm_check_intercept(CPUState *env1, uint32_t type);
+
+uint32_t cpu_cc_compute_all(CPUState *env1, int op);
+
#endif /* CPU_I386_H */