[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v3 09/14] xen: sched: DOMCTL_*vcpuaffinity works with hard and soft affinity
>>> On 22.11.13 at 19:55, Dario Faggioli <dario.faggioli@xxxxxxxxxx> wrote: > On mar, 2013-11-19 at 16:39 +0000, Jan Beulich wrote: >> >>> On 18.11.13 at 19:17, Dario Faggioli <dario.faggioli@xxxxxxxxxx> wrote: >> > + online = cpupool_online_cpumask(v->domain->cpupool); >> > + cpumask_and(new_affinity, online, v->cpu_hard_affinity); >> > + if ( op->u.vcpuaffinity.flags & XEN_VCPUAFFINITY_SOFT) >> > + cpumask_and(new_affinity, new_affinity, >> > + v->cpu_soft_affinity); >> > + >> > + ret = cpumask_to_xenctl_bitmap( >> > + &op->u.vcpuaffinity.eff_cpumap, new_affinity); >> >> Considering that you have two bitmaps available from the caller, >> can't you just return both when both flags are set? >> > Well, it's true that there are two cpumaps, but only one is meant to be > an output parameter. "meant to be" based on what? Surely not because so far it was that way - as you say further down, this is not an interface required to be stable. > Also, I think this is more useful like this, i.e., > returning either: > - hard-affinity&online > - hard-affinity&soft-affinity&online, > > As it can be seen in the libxl patch (in the new series). > > Therefore, I kept this interface as it was here, also considering that: > - it's pretty late to re-re-redesign; > - neither this nor the xc one are stable interfaces, so we can come > back and revisit this later, if we want to. > > Do you think this could be acceptable? I wouldn't veto it, but I also dislike reduced flexibility when more flexibility is obviously achievable without much effort. Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |