aboutsummaryrefslogtreecommitdiff
path: root/exec.c
diff options
context:
space:
mode:
authoraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-03-28 22:29:15 +0000
committeraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-03-28 22:29:15 +0000
commit15a5115690558ad65de02d9b9bb4ec89bc4cf8ac (patch)
tree4407ce082f2a29ecb358cab23dd5b0f120f92864 /exec.c
parentf9e7bcfe6b8d32431374c86542a1d671681a7db1 (diff)
Use spinlock_t for interrupt_lock, lock support for HPPA (Stuart Brady)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4118 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'exec.c')
-rw-r--r--exec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/exec.c b/exec.c
index b74d90920c..48dabd67ad 100644
--- a/exec.c
+++ b/exec.c
@@ -1215,7 +1215,7 @@ void cpu_set_log_filename(const char *filename)
void cpu_interrupt(CPUState *env, int mask)
{
TranslationBlock *tb;
- static int interrupt_lock;
+ static spinlock_t interrupt_lock = SPIN_LOCK_UNLOCKED;
env->interrupt_request |= mask;
/* if the cpu is currently executing code, we must unlink it and
@@ -1224,7 +1224,7 @@ void cpu_interrupt(CPUState *env, int mask)
if (tb && !testandset(&interrupt_lock)) {
env->current_tb = NULL;
tb_reset_jump_recursive(tb);
- interrupt_lock = 0;
+ resetlock(&interrupt_lock);
}
}