[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] Clean up the adjdom change a little.
# HG changeset patch # User kaf24@xxxxxxxxxxxxxxxxxxxx # Node ID bcbe322d80d9ec60c3d5b549d40f33c155c85b87 # Parent 85b79ab1e56df1cde42aa51071499b9c7e70163c Clean up the adjdom change a little. Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx> diff -r 85b79ab1e56d -r bcbe322d80d9 xen/common/schedule.c --- a/xen/common/schedule.c Tue Jan 31 15:24:16 2006 +++ b/xen/common/schedule.c Tue Jan 31 16:32:24 2006 @@ -305,7 +305,7 @@ long sched_adjdom(struct sched_adjdom_cmd *cmd) { struct domain *d; - struct vcpu *v, *vme; + struct vcpu *v; if ( (cmd->sched_id != ops.sched_id) || ((cmd->direction != SCHED_INFO_PUT) && @@ -328,28 +328,25 @@ * lock of the CPU they are running on. This CPU could be the * same as ours. */ - vme = NULL; for_each_vcpu ( d, v ) { - if ( v == current ) - vme = current; - else + if ( v != current ) vcpu_pause(v); } - if (vme) - vcpu_schedule_lock_irq(vme); + if ( d == current->domain ) + vcpu_schedule_lock_irq(current); SCHED_OP(adjdom, d, cmd); TRACE_1D(TRC_SCHED_ADJDOM, d->domain_id); - if (vme) - vcpu_schedule_unlock_irq(vme); + if ( d == current->domain ) + vcpu_schedule_unlock_irq(current); for_each_vcpu ( d, v ) { - if ( v != vme ) + if ( v != current ) vcpu_unpause(v); } _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |