ia64/xen-unstable

changeset 7884:1a1c0f9b242e

Fix event_pending() macro to match the assembly-language
checks in entry.S. This will avoid a hard-to-debug loop
that we found ourselves in recently, involving
hypercall_preempt_check() spuriously returning TRUE, but
no event getting propagated to the guest (since mask != 0).

Signed-off-by: Keir Fraser <keir@xensource.com>
author kaf24@firebug.cl.cam.ac.uk
date Thu Nov 17 13:02:19 2005 +0100 (2005-11-17)
parents c640c0c7f821
children 65e0699dc9e1
files xen/include/xen/event.h
line diff
     1.1 --- a/xen/include/xen/event.h	Thu Nov 17 12:52:42 2005 +0100
     1.2 +++ b/xen/include/xen/event.h	Thu Nov 17 13:02:19 2005 +0100
     1.3 @@ -60,7 +60,7 @@ extern void send_guest_pirq(struct domai
     1.4  
     1.5  /* Note: Bitwise operations result in fast code with no branches. */
     1.6  #define event_pending(v)                        \
     1.7 -    ((v)->vcpu_info->evtchn_upcall_pending &    \
     1.8 -     ~(v)->vcpu_info->evtchn_upcall_mask)
     1.9 +    (!!(v)->vcpu_info->evtchn_upcall_pending &  \
    1.10 +      !(v)->vcpu_info->evtchn_upcall_mask)
    1.11  
    1.12  #endif /* __XEN_EVENT_H__ */