[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v2 30/48] xen/sched: introduce unit_runnable_state()
On Wed, 2019-09-11 at 12:30 +0200, Jan Beulich wrote: > On 09.08.2019 16:58, Juergen Gross wrote: > > > > --- a/xen/include/xen/sched-if.h > > +++ b/xen/include/xen/sched-if.h > > @@ -75,6 +75,20 @@ static inline bool unit_runnable(const struct > > sched_unit *unit) > > return vcpu_runnable(unit->vcpu_list); > > } > > > > +static inline bool unit_runnable_state(const struct sched_unit > > *unit) > > +{ > > + struct vcpu *v; > > + bool runnable; > > + > > + v = unit->vcpu_list; > > + runnable = vcpu_runnable(v); > > + > > + v->new_state = runnable ? RUNSTATE_running > > + : (v->pause_flags & VPF_blocked) > > + ? RUNSTATE_blocked : > > RUNSTATE_offline; > > + return runnable; > > +} > > Especially for understanding the (correctness of the) credit1 > changes it would be rather helpful if once again this function > actually iterated over all vCPU-s right away (even if there's > only one per unit right now), to see how their varying states > get combined. > Yep, I agree. Regards -- Dario Faggioli, Ph.D http://about.me/dario.faggioli Virtualization Software Engineer SUSE Labs, SUSE https://www.suse.com/ ------------------------------------------------------------------- <<This happens because _I_ choose it to happen!>> (Raistlin Majere) Attachment:
signature.asc _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |