From 7499a2ccb56974fae2663c2b44b38a8c68c3fd7d Mon Sep 17 00:00:00 2001
From: Zhang Xiantao <xiantao.zhang@intel.com>
Date: Wed, 5 Dec 2007 11:48:42 +0800
Subject: [PATCH] kvm: qemu: Make cpu-exec.c works for ia64 case.

Add some handlings for ia64 case in cpu-exec.c
Signed-off-by: Zhang Xiantao <xiantao.zhang@intel.com>
---
 qemu/cpu-exec.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/qemu/cpu-exec.c b/qemu/cpu-exec.c
index 79e18eb..b2abf6b 100644
--- a/qemu/cpu-exec.c
+++ b/qemu/cpu-exec.c
@@ -215,6 +215,10 @@ static inline TranslationBlock *tb_find_fast(void)
     flags = env->ps;
     cs_base = 0;
     pc = env->pc;
+#elif defined(TARGET_IA64)
+    flags = 0;
+    cs_base = 0;         /* XXXXX */
+    pc = 0;
 #else
 #error unsupported CPU
 #endif
@@ -289,6 +293,7 @@ int cpu_exec(CPUState *env1)
 #elif defined(TARGET_PPC)
 #elif defined(TARGET_MIPS)
 #elif defined(TARGET_SH4)
+#elif defined(TARGET_IA64)
     /* XXXXX */
 #else
 #error unsupported target CPU
@@ -342,6 +347,8 @@ int cpu_exec(CPUState *env1)
                     do_interrupt(env);
 #elif defined(TARGET_M68K)
                     do_interrupt(0);
+#elif defined(TARGET_IA64)
+ 		    do_interrupt(env);
 #endif
                 }
                 env->exception_index = -1;
@@ -779,6 +786,7 @@ int cpu_exec(CPUState *env1)
               | env->cc_dest | (env->cc_x << 4);
 #elif defined(TARGET_MIPS)
 #elif defined(TARGET_SH4)
+#elif defined(TARGET_IA64)
 #elif defined(TARGET_ALPHA)
     /* XXXXX */
 #else
-- 
1.5.2

