aboutsummaryrefslogtreecommitdiffstats
path: root/xen/common/event_channel.c
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2009-03-03 13:17:05 +0000
committerKeir Fraser <keir.fraser@citrix.com>2009-03-03 13:17:05 +0000
commitb47276c18fabaf6f0dbb855d3b1d2063b1c73e01 (patch)
tree32c5b5d0d1cbe76493925d00d0c1b1cb31dc6ef3 /xen/common/event_channel.c
parent6deab1ae316b5f7da431d8add34c676dfca9c4f9 (diff)
downloadxen-b47276c18fabaf6f0dbb855d3b1d2063b1c73e01.tar.gz
xen-b47276c18fabaf6f0dbb855d3b1d2063b1c73e01.tar.bz2
xen-b47276c18fabaf6f0dbb855d3b1d2063b1c73e01.zip
x86: Fix event-channel access for 32-bit HVM guests.
Based on a patch by Joe Jin <joe.jin@oracle.com> Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Diffstat (limited to 'xen/common/event_channel.c')
-rw-r--r--xen/common/event_channel.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/xen/common/event_channel.c b/xen/common/event_channel.c
index 09702e3d1f..3f36d09e83 100644
--- a/xen/common/event_channel.c
+++ b/xen/common/event_channel.c
@@ -548,7 +548,7 @@ static int evtchn_set_pending(struct vcpu *v, int port)
return 1;
if ( !test_bit (port, &shared_info(d, evtchn_mask)) &&
- !test_and_set_bit(port / BITS_PER_GUEST_LONG(d),
+ !test_and_set_bit(port / BITS_PER_EVTCHN_WORD(d),
&vcpu_info(v, evtchn_pending_sel)) )
{
vcpu_mark_events_pending(v);
@@ -783,7 +783,7 @@ int evtchn_unmask(unsigned int port)
*/
if ( test_and_clear_bit(port, &shared_info(d, evtchn_mask)) &&
test_bit (port, &shared_info(d, evtchn_pending)) &&
- !test_and_set_bit (port / BITS_PER_GUEST_LONG(d),
+ !test_and_set_bit (port / BITS_PER_EVTCHN_WORD(d),
&vcpu_info(v, evtchn_pending_sel)) )
{
vcpu_mark_events_pending(v);