aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2010-02-24 10:57:24 +0000
committerKeir Fraser <keir.fraser@citrix.com>2010-02-24 10:57:24 +0000
commit25a63390b97f5e654a197166fe9c7b891fcb35ee (patch)
treef73027aadeeacc6650d9f22b2dbe36bd7badab65
parente54b0e627e15b90e86b5c566d22020fdba819b66 (diff)
downloadxen-25a63390b97f5e654a197166fe9c7b891fcb35ee.tar.gz
xen-25a63390b97f5e654a197166fe9c7b891fcb35ee.tar.bz2
xen-25a63390b97f5e654a197166fe9c7b891fcb35ee.zip
cpuidle: Small fix to urgent_count update logic.
From: Ke Yu <ke.yu@intel.com> Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
-rw-r--r--xen/common/schedule.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/xen/common/schedule.c b/xen/common/schedule.c
index d02eb1f0af..fdb9e8d0d2 100644
--- a/xen/common/schedule.c
+++ b/xen/common/schedule.c
@@ -107,7 +107,8 @@ static inline void vcpu_urgent_count_update(struct vcpu *v)
if ( unlikely(v->is_urgent) )
{
- if ( !test_bit(v->vcpu_id, v->domain->poll_mask) )
+ if ( !test_bit(_VPF_blocked, &v->pause_flags) ||
+ !test_bit(v->vcpu_id, v->domain->poll_mask) )
{
v->is_urgent = 0;
atomic_dec(&per_cpu(schedule_data,v->processor).urgent_count);
@@ -115,7 +116,8 @@ static inline void vcpu_urgent_count_update(struct vcpu *v)
}
else
{
- if ( unlikely(test_bit(v->vcpu_id, v->domain->poll_mask)) )
+ if ( unlikely(test_bit(_VPF_blocked, &v->pause_flags) &&
+ test_bit(v->vcpu_id, v->domain->poll_mask)) )
{
v->is_urgent = 1;
atomic_inc(&per_cpu(schedule_data,v->processor).urgent_count);