Re: [PATCH RFC 1/2] sched: cfs: introduce capacity_ops

2014-10-09 Thread Peter Zijlstra
On Thu, Oct 09, 2014 at 10:34:33AM -0700, Mike Turquette wrote: > Quoting Peter Zijlstra (2014-10-09 02:00:24) > > On Wed, Oct 08, 2014 at 04:28:36PM -0700, Mike Turquette wrote: > > > > Yeah, like hell no. We do not want modules to affect scheduler > > > > behaviour. > > > > > > If a CPUfreq driv

Re: [PATCH RFC 1/2] sched: cfs: introduce capacity_ops

2014-10-09 Thread Peter Zijlstra
On Wed, Oct 08, 2014 at 04:28:36PM -0700, Mike Turquette wrote: > > Yeah, like hell no. We do not want modules to affect scheduler > > behaviour. > > If a CPUfreq driver is the best place to know how frequency affects the > capacity of a CPU for a given system, are you suggesting that we must > co

Re: [PATCH RFC 1/2] sched: cfs: introduce capacity_ops

2014-10-08 Thread Peter Zijlstra
On Tue, Oct 07, 2014 at 11:26:11PM -0700, Mike Turquette wrote: > +struct capacity_ops { > + unsigned long (*get_capacity)(int cpu); > + spinlock_t lock; > +}; Yeah, fail there. Ops vectors should not contain serialization, that simply doesn't work. It means you cannot switch the entire ve

[PATCH RFC 1/2] sched: cfs: introduce capacity_ops

2014-10-07 Thread Mike Turquette
The scheduler needs to know the current capacity of a cpu taking into account micro-architectural differences as well as current cpu frequency. The method for determining this may vary not only from architecture to architecture, but also within differnt platforms of the same architectures. struct