Re: [RFCv5 PATCH 41/46] sched/fair: add triggers for OPP change requests

2015-08-10 Thread Juri Lelli
Hi Vincent, On 04/08/15 14:41, Vincent Guittot wrote: Hi Juri, On 7 July 2015 at 20:24, Morten Rasmussen morten.rasmus...@arm.com wrote: From: Juri Lelli juri.le...@arm.com Each time a task is {en,de}queued we might need to adapt the current frequency to the new usage. Add triggers on {en

Re: [PATCH 07/10] sched: Migrate sched to use new tick dependency mask model

2015-08-10 Thread Juri Lelli
Hi, On 04/08/15 08:41, Peter Zijlstra wrote: On Mon, Aug 03, 2015 at 07:30:32PM +0200, Frederic Weisbecker wrote: But you've forgotten about SCHED_DEADLINE, we count those in: rq-dl.dl_nr_running. Indeed. Hmm, there is no preemption between SCHED_DEALINE tasks, right? So I can treat it like

Re: [PATCH] sched/deadline: fix dl bandwidth of root domain overflow after dl task dead

2015-08-10 Thread Juri Lelli
On 06/08/15 09:39, Wanpeng Li wrote: Hi Juri, Hi, 2015-05-06 16:14 GMT+08:00 Juri Lelli juri.le...@arm.com mailto:juri.le...@arm.com: Hi Wanpeng, I finally got to review this, sorry about the huge delay. On 07/04/2015 04:36, Wanpeng Li wrote: The total used dl

Re: [RFC PATCH 0/3] CFS idle injection

2015-11-10 Thread Juri Lelli
Hi, On 9 November 2015 at 14:15, Peter Zijlstra wrote: > On Mon, Nov 09, 2015 at 11:56:51AM +, Punit Agrawal wrote: >> Jacob Pan writes: >> > My take is that RT and throttling will never go well together since they >> > are conflicting in

Re: [RFC PATCH 0/3] CFS idle injection

2015-11-10 Thread Juri Lelli
On 11/10/15, Peter Zijlstra wrote: > On Tue, Nov 10, 2015 at 10:07:35AM +0000, Juri Lelli wrote: > > Do you think that using SCHED_DEADLINE here would be completely > > foolish? I mean, we would have the duty_cycle/period thing for free, it > > would be know to the scheduler

Re: [PATCH] sched/deadline: fix earliest_dl.next is not the pushable candidate

2015-11-09 Thread Juri Lelli
Hi, On 10/22/15, Wanpeng Li wrote: > earliest_dl.next is used to cache the next earliest ready task > which also is pushable in order to be a candidate of pushable > tasks during pull algorithm. If the earliest_dl.next deadline > of the sr_rq is earlier than the earliest_dl.curr deadline of >

Re: [RFCv5 PATCH 38/46] sched: scheduler-driven cpu frequency selection

2015-10-08 Thread Juri Lelli
On 08/10/15 01:14, Steve Muckle wrote: > On 08/25/2015 03:45 AM, Juri Lelli wrote: >> But, it is true that if the above events happened the other way around >> (we trigger an update after load balancing and a new task arrives), we >> may miss the opportunity to jump to max wit

Re: [PATCH] Fix migration of SCHED_DEADLINE tasks

2015-10-16 Thread Juri Lelli
Hi, On 16/10/15 09:03, Luca Abeni wrote: > On 10/15/2015 06:40 PM, Juri Lelli wrote: >> On 15/10/15 12:09, Luca Abeni wrote: >>> Commit 9d5142624256 ("sched/deadline: Reduce rq lock contention by >>> eliminating locking of non-feasible

Re: [PATCH] Fix migration of SCHED_DEADLINE tasks

2015-10-15 Thread Juri Lelli
Hi Luca, On 15/10/15 12:09, Luca Abeni wrote: > Commit 9d5142624256 ("sched/deadline: Reduce rq lock contention by > eliminating locking of non-feasible target") broke select_task_rq_dl() > and find_lock_later_rq(), because it introduced a comparison between > the local task's deadline and

Re: [RFCv5 PATCH 43/46] sched/{fair,cpufreq_sched}: add reset_capacity interface

2015-10-09 Thread Juri Lelli
Hi Steve, On 08/10/15 21:40, Steve Muckle wrote: > Hi Juri, > > On 07/07/2015 11:24 AM, Morten Rasmussen wrote: >> From: Juri Lelli <juri.le...@arm.com> >> >> When a CPU is going idle it is pointless to ask for an OPP update as we >> would wake up another

Re: [RFCv5 PATCH 40/46] sched/cpufreq_sched: compute freq_new based on capacity_orig_of()

2015-07-09 Thread Juri Lelli
Hi Mike, On 08/07/15 16:22, Michael Turquette wrote: Quoting Morten Rasmussen (2015-07-07 11:24:23) From: Juri Lelli juri.le...@arm.com capacity is both cpu and freq scaled with EAS. We thus need to compute freq_new using capacity_orig_of(), so that we properly scale back the thing

Re: [RFCv5 PATCH 45/46] sched/cpufreq_sched: modify pcpu_capacity handling

2015-07-09 Thread Juri Lelli
Hi Mike, On 08/07/15 17:42, Michael Turquette wrote: Quoting Morten Rasmussen (2015-07-07 11:24:28) From: Juri Lelli juri.le...@arm.com Use the cpu argument of cpufreq_sched_set_cap() to handle per_cpu writes, as the thing can be called remotely (e.g., from load balacing code). cc: Ingo

Re: [RFCv5 PATCH 41/46] sched/fair: add triggers for OPP change requests

2015-07-09 Thread Juri Lelli
Hi Mike, On 08/07/15 16:42, Michael Turquette wrote: Hi Juri, Quoting Morten Rasmussen (2015-07-07 11:24:24) From: Juri Lelli juri.le...@arm.com Each time a task is {en,de}queued we might need to adapt the current frequency to the new usage. Add triggers on {en,de}queue_task_fair

Re: [RFCv5 PATCH 39/46] sched/cpufreq_sched: use static key for cpu frequency selection

2015-07-10 Thread Juri Lelli
Hi Mike, On 08/07/15 16:19, Michael Turquette wrote: Quoting Morten Rasmussen (2015-07-07 11:24:22) From: Juri Lelli juri.le...@arm.com Introduce a static key to only affect scheduler hot paths when sched governor is enabled. cc: Ingo Molnar mi...@redhat.com cc: Peter Zijlstra pet

Re: [RFCv5 PATCH 44/46] sched/fair: jump to max OPP when crossing UP threshold

2015-07-10 Thread Juri Lelli
Hi Mike, On 08/07/15 17:47, Michael Turquette wrote: Quoting Morten Rasmussen (2015-07-07 11:24:27) From: Juri Lelli juri.le...@arm.com Since the true utilization of a long running task is not detectable while it is running and might be bigger than the current cpu capacity, create

Re: [RFCv5 PATCH 38/46] sched: scheduler-driven cpu frequency selection

2015-08-25 Thread Juri Lelli
Hi Peter, On 15/08/15 14:05, Peter Zijlstra wrote: On Tue, Jul 07, 2015 at 07:24:21PM +0100, Morten Rasmussen wrote: +void cpufreq_sched_set_cap(int cpu, unsigned long capacity) +{ +unsigned int freq_new, cpu_tmp; +struct cpufreq_policy *policy; +struct gov_data *gd; +

Re: [PATCH] sched/deadline: fix dl bandwidth of root domain overflow after dl task dead

2015-09-01 Thread Juri Lelli
Hi, On 30/08/15 12:25, Wanpeng Li wrote: > On 8/10/15 10:10 PM, Juri Lelli wrote: >> On 06/08/15 09:39, Wanpeng Li wrote: >>> Hi Juri, >>> >> Hi, >> >>> 2015-05-06 16:14 GMT+08:00 Juri Lelli <juri.le...@arm.com >>> <mailto:juri.le...

Re: [RFCv5 PATCH 38/46] sched: scheduler-driven cpu frequency selection

2015-09-04 Thread Juri Lelli
On 15/08/15 13:35, Peter Zijlstra wrote: > On Tue, Jul 07, 2015 at 07:24:21PM +0100, Morten Rasmussen wrote: >> diff --git a/kernel/sched/cpufreq_sched.c b/kernel/sched/cpufreq_sched.c >> new file mode 100644 >> index 000..5020f24 >> --- /dev/null >> +++ b/kernel/sched/cpufreq_sched.c >> @@

[PATCH 1/4] sched/{cpuset,core}: restore complete root_domain status across hotplug

2015-09-02 Thread Juri Lelli
<mi...@redhat.com> Cc: Peter Zijlstra <pet...@infradead.org> Cc: Li Zefan <lize...@huawei.com> Cc: cgro...@vger.kernel.org Reported-by: Wanpeng Li <wanpeng...@linux.intel.com> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- include/linux/sched.h | 2

[PATCH 3/4] locking/rtmutex: fix open coded check in rt_mutex_waiter_less()

2015-09-02 Thread Juri Lelli
rt_mutex_waiter_less() check of tasks deadlines is open coded. Since this is subject to wraparound issues, make it use the correct helper. Cc: Ingo Molnar <mi...@redhat.com> Cc: Peter Zijlstra <pet...@infradead.org> Reported-by: Luca Abeni <luca.ab...@unitn.it> Signed-off-by: J

[PATCH 4/4] sched/rt: make (do_)balance_runtime() return void

2015-09-02 Thread Juri Lelli
The return value of (do_)balance_runtime() is not consumed by anybody. Make them return void. Cc: Ingo Molnar <mi...@redhat.com> Cc: Peter Zijlstra <pet...@infradead.org> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- kernel/sched/rt.c | 22 ++

[PATCH 2/4] sched/deadline: unify dl_time_before usage

2015-09-02 Thread Juri Lelli
Move dl_time_before static definition in include/linux/sched/deadline.h so that it can be used by different parties without being re-defined. Cc: Ingo Molnar <mi...@redhat.com> Cc: Peter Zijlstra <pet...@infradead.org> Reported-by: Luca Abeni <luca.ab...@unitn.it> Signed-

[PATCH 0/4] sched fixes and clean-ups

2015-09-02 Thread Juri Lelli
of admission control decisions (admitted bandwidth). This patch is invasive, but it seems to fix the problem (and I couldn't find cleaner fixes :-/). Please give special attention to it :-). Thanks! Best, - Juri Juri Lelli (4): sched/{cpuset,core}: restore complete root_domain status across

Re: [PATCH 1/4] sched/{cpuset,core}: restore complete root_domain status across hotplug

2015-09-10 Thread Juri Lelli
Hi Peter, On 09/09/15 16:11, Peter Zijlstra wrote: > On Wed, Sep 02, 2015 at 11:01:33AM +0100, Juri Lelli wrote: >> Hotplug operations are destructive w.r.t data associated with cpuset; >> in this case we care about root_domains. SCHED_DEADLINE puts bandwidth >> informati

Re: [RFCv5 PATCH 38/46] sched: scheduler-driven cpu frequency selection

2015-09-14 Thread Juri Lelli
On 04/09/15 14:27, Juri Lelli wrote: > On 15/08/15 13:35, Peter Zijlstra wrote: >> On Tue, Jul 07, 2015 at 07:24:21PM +0100, Morten Rasmussen wrote: >>> diff --git a/kernel/sched/cpufreq_sched.c b/kernel/sched/cpufreq_sched.c >>> new file mode 100644 >>> inde

Re: [RFC 08/14] sched/tune: add detailed documentation

2015-09-16 Thread Juri Lelli
Hi Steve, thanks a lot for this interesting discussion. On 16/09/15 00:55, Steve Muckle wrote: > On 09/15/2015 08:00 AM, Patrick Bellasi wrote: >>> Agreed, though I also think those tunable values might also change for a >>> given set of tasks in different circumstances. >> >> Could you provide

Re: [RFCv5 PATCH 38/46] sched: scheduler-driven cpu frequency selection

2015-09-15 Thread Juri Lelli
On 15/09/15 14:45, Peter Zijlstra wrote: > On Mon, Sep 14, 2015 at 04:57:35PM +0100, Juri Lelli wrote: >> On 04/09/15 14:27, Juri Lelli wrote: >>> So, just to recall what we discussed at LPC (I have Mike's slides >>> at hand :-)). It seems that key points are: >&g

Re: [PATCH 0/4] sched fixes and clean-ups

2015-09-18 Thread Juri Lelli
Hi Peter, On 02/09/15 11:01, Juri Lelli wrote: > Hi all, > > while trying to come up with 01/04, I collected the following set of fixes. > > Patches 02-04/04 are simple refactoring of code and clean-ups. > Patch 01/04 is instead my attempt to fix a problem highlighte

Re: [RFC PATCH 0/8] CPUs capacity information for heterogeneous systems

2015-12-07 Thread Juri Lelli
On 07/12/15 13:18, Russell King - ARM Linux wrote: > On Mon, Dec 07, 2015 at 12:36:54PM +0000, Juri Lelli wrote: > > On 07/12/15 12:11, Russell King - ARM Linux wrote: > > > It looks like the second patch doesn't yet have the backing from the DT > > > people, w

Re: [PATCH v5] sched/deadline: fix earliest_dl.next logic

2015-12-03 Thread Juri Lelli
Hi, On 03/12/15 16:59, Wanpeng Li wrote: > 2015-12-03 16:37 GMT+08:00 Luca Abeni : > > Hi, > > > > On 12/03/2015 03:25 AM, Wanpeng Li wrote: > > [...] > >>> > >>> @@ -202,16 +197,18 @@ static void dequeue_pushable_dl_task(struct rq *rq, > >>> struct task_struct *p) > >>> >

Re: [PATCH v6] sched/deadline: fix earliest_dl.next logic

2015-12-04 Thread Juri Lelli
hable_dl_tasks_leftmost = next_node; > + if (next_node) > + dl_rq->earliest_dl.next = rb_entry(next_node, > + struct task_struct, > pushable_dl_tasks)->dl.deadline; Small nitpick, we are breaking 80 columns here

Re: [RFC PATCH 0/8] CPUs capacity information for heterogeneous systems

2015-12-07 Thread Juri Lelli
On 07/12/15 12:11, Russell King - ARM Linux wrote: > On Mon, Dec 07, 2015 at 12:02:44PM +0000, Juri Lelli wrote: > > On 23/11/15 14:28, Juri Lelli wrote: > > > Hi all, > > > > > > > Hi again everybody, > > > > thanks a lot to Rob

Re: [RFC PATCH 0/8] CPUs capacity information for heterogeneous systems

2015-12-07 Thread Juri Lelli
On 23/11/15 14:28, Juri Lelli wrote: > Hi all, > Hi again everybody, thanks a lot to Rob and Vincent for feedback, but, IMHO, we'd need more discussion happening on this series to figure out how we move forward; so, this is a ping :-). It's a simple information that we need to figure o

Re: [PATCH v5] sched/deadline: fix earliest_dl.next logic

2015-12-02 Thread Juri Lelli
Hi, On 02/12/15 19:47, Wanpeng Li wrote: > earliest_dl.next should cache deadline of the earliest ready task that > is also enqueued in the pushable rbtree, as pull algorithm uses this > information to find candidates for migration: if the earliest_dl.next > deadline of source rq is earlier than

Re: [RFC PATCH 5/8] arm64: parse cpu capacity from DT

2015-12-11 Thread Juri Lelli
Hi, On 10/12/15 14:15, Dietmar Eggemann wrote: > On 23/11/15 14:28, Juri Lelli wrote: > > With the introduction of cpu capacity bindings, CPU capacities can now be > > extracted from DT. Add parsing of such information at boot time. Also, > > store such information using per

Re: [RFCv6 PATCH 07/10] sched/fair: jump to max OPP when crossing UP threshold

2015-12-11 Thread Juri Lelli
he cpu usage plus the capacity margin exceeds the > current capacity. This is also done to try to harm the performance of > a task the least. > > Original fair-class only version authored by Juri Lelli > <juri.le...@arm.com>. > > cc: Ingo Molnar <mi...@redhat.com&g

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-11 Thread Juri Lelli
Hi, On 10/12/15 14:14, Dietmar Eggemann wrote: > On 01/12/15 11:20, Juri Lelli wrote: > > Hi Vincent, > > > > On 30/11/15 10:59, Vincent Guittot wrote: > >> Hi Juri, > >> > >> On 24 November 2015

Re: [RFC PATCH 3/8] arm: parse cpu capacity from DT

2015-12-11 Thread Juri Lelli
Hi, On 10/12/15 14:14, Dietmar Eggemann wrote: > On 23/11/15 14:28, Juri Lelli wrote: > > With the introduction of cpu capacity bindings, CPU capacities can now be > > extracted from DT. Add parsing of such information at boot time. We keep > > code that can produce sa

Re: [RFCv6 PATCH 03/10] sched: scheduler-driven cpu frequency selection

2015-12-11 Thread Juri Lelli
here is no polling loop to > check cpu idle time nor any other method which is unsynchronized with > the scheduler, aside from a throttling mechanism to ensure frequency > changes are not attempted faster than the hardware can accommodate them. > > Thanks to Juri Lelli <juri.le...@ar

Re: [RFCv6 PATCH 10/10] sched: rt scheduler sets capacity requirement

2015-12-11 Thread Juri Lelli
On 08/12/15 22:19, Steve Muckle wrote: > From: Vincent Guittot > > RT tasks don't provide any running constraints like deadline ones > except their running priority. The only current usable input to > estimate the capacity needed by RT tasks is the rt_avg metric. We

Re: [RFC PATCH 8/8] arm64: add sysfs cpu_capacity attribute

2015-12-10 Thread Juri Lelli
Hi, On 10/12/15 15:59, Mark Brown wrote: > On Thu, Dec 10, 2015 at 02:15:04PM +, Dietmar Eggemann wrote: > > On 23/11/15 14:28, Juri Lelli wrote: > > > > The new attribute shows up as: > > > > /sys/devices/system/cpu/cpu*/cpu_capacity > > >

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-10 Thread Juri Lelli
Hi Mark, I certainly understand your (and Rob's) concerns, but let me try anyway to argument a bit more around this approach :-). On 10/12/15 15:30, Mark Brown wrote: > On Mon, Nov 23, 2015 at 08:06:31PM -0600, Rob Herring wrote: > > > I think you need something absolute and probably per MHz

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-17 Thread Juri Lelli
Hi, On 15/12/15 17:45, Mark Brown wrote: > On Tue, Dec 15, 2015 at 05:28:37PM +, Mark Rutland wrote: > > On Tue, Dec 15, 2015 at 05:17:13PM +, Mark Brown wrote: > > > > Obviously people are going to get upset if we introduce performance > > > regressions - but that's true always, we can

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-14 Thread Juri Lelli
Hi Mark, On 11/12/15 17:49, Mark Brown wrote: > On Thu, Dec 10, 2015 at 05:58:20PM +0000, Juri Lelli wrote: > > On 10/12/15 15:30, Mark Brown wrote: > > > On Mon, Nov 23, 2015 at 08:06:31PM -0600, Rob Herring wrote: > > > > > In other words, I want to see th

Re: [RFCv6 PATCH 09/10] sched: deadline: use deadline bandwidth in scale_rt_capacity

2015-12-14 Thread Juri Lelli
On 14/12/15 16:56, Vincent Guittot wrote: > On 14 December 2015 at 16:17, Peter Zijlstra wrote: > > On Tue, Dec 08, 2015 at 10:19:30PM -0800, Steve Muckle wrote: > >> From: Vincent Guittot > > > >> diff --git a/kernel/sched/deadline.c

Re: [RFCv6 PATCH 03/10] sched: scheduler-driven cpu frequency selection

2015-12-15 Thread Juri Lelli
On 14/12/15 18:02, Steve Muckle wrote: > Hi Juri, > > Thanks for the review. > > On 12/11/2015 03:04 AM, Juri Lelli wrote: > >> +config CPU_FREQ_GOV_SCHED > >> + bool "'sched' cpufreq governor" > >> + depends on CPU_FREQ > > > &

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-15 Thread Juri Lelli
On 14/12/15 16:59, Mark Brown wrote: > On Mon, Dec 14, 2015 at 12:36:16PM +0000, Juri Lelli wrote: > > On 11/12/15 17:49, Mark Brown wrote: > > > > The purpose of the capacity values is to influence the scheduler > > > behaviour and hence performance. Without

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-15 Thread Juri Lelli
Hi Mark, On 15/12/15 14:01, Mark Rutland wrote: > On Tue, Dec 15, 2015 at 01:39:51PM +, Mark Brown wrote: > > On Tue, Dec 15, 2015 at 12:22:38PM +0000, Juri Lelli wrote: > > > > So then why isn't it adequate to just have things like the core types in > > > > t

Re: [RFCv6 PATCH 09/10] sched: deadline: use deadline bandwidth in scale_rt_capacity

2015-12-16 Thread Juri Lelli
Hi Luca, On 15/12/15 22:24, Luca Abeni wrote: > On Tue, 15 Dec 2015 14:42:29 +0100 > Peter Zijlstra wrote: > > On Tue, Dec 15, 2015 at 02:30:07PM +0100, Luca Abeni wrote: > > > > > >So I remember something else from the BFQ code, which also had to > > > >track entries for

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-15 Thread Juri Lelli
On 15/12/15 14:50, Mark Rutland wrote: > On Tue, Dec 15, 2015 at 02:24:58PM +0000, Juri Lelli wrote: > > Hi Mark, > > Hi Juri, > > > On 15/12/15 14:01, Mark Rutland wrote: > > > I really don't want to see a table of magic numbers in the kernel. > > >

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-15 Thread Juri Lelli
On 15/12/15 15:32, Mark Rutland wrote: > On Tue, Dec 15, 2015 at 03:08:13PM +, Mark Brown wrote: > > On Tue, Dec 15, 2015 at 02:01:36PM +, Mark Rutland wrote: > > > > > I really don't want to see a table of magic numbers in the kernel. > > > > Right, there's pitfalls there too although

Re: [PATCH v3] sched/deadline: fix earliest_dl.next logic

2015-11-27 Thread Juri Lelli
Hi, [+Luca, as he has been testing this patch an he has probably findings to share] On 19/11/15 18:11, Wanpeng li wrote: > earliest_dl.next should cache deadline of the earliest ready task that > is also enqueued in the pushable rbtree, as pull algorithm uses this > information to find

Re: suspicious RCU usage on 4.4-rc2 ARM platform

2015-11-25 Thread Juri Lelli
On 24/11/15 08:52, Paul E. McKenney wrote: > On Tue, Nov 24, 2015 at 04:27:50PM +0000, Juri Lelli wrote: > > Hi Paul, > > > > I'm hitting these splats while running simple hotplug tests on an ARM > > TC2 platform. The following seems to cure it, but I don't think it ne

suspicious RCU usage on 4.4-rc2 ARM platform

2015-11-24 Thread Juri Lelli
Hi Paul, I'm hitting these splats while running simple hotplug tests on an ARM TC2 platform. The following seems to cure it, but I don't think it never made it to mainline: https://lkml.org/lkml/2015/5/12/892 Any reason why? Thanks, - Juri root@genericarmv7a:~# [ 283.868236] CPU0

Re: [PATCH v3] sched/deadline: fix earliest_dl.next logic

2015-12-01 Thread Juri Lelli
On 30/11/15 10:20, Wanpeng Li wrote: > 2015-11-27 20:14 GMT+08:00 Luca Abeni : > > Hi all, > > > > I ran some quick tests on this patch (because I was working on something > > related), and it seems to me that it triggers a bug. Here are some > > information: [snip] > > > >

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-12-01 Thread Juri Lelli
Hi Vincent, On 30/11/15 10:59, Vincent Guittot wrote: > Hi Juri, > > On 24 November 2015 at 11:54, Juri Lelli <juri.le...@arm.com> wrote: > > Hi, > > > > On 23/11/15 20:06, Rob Herring wrote: > >> On Mon, Nov 23, 2015 at 02:28:35PM +, Juri Lelli w

Re: [PATCH v2] sched/deadline: fix earliest_dl.next is not the pushable candidate

2015-11-19 Thread Juri Lelli
Hi, On 10/11/15 20:33, Wanpeng Li wrote: > earliest_dl.next is used to cache the next earliest ready task > which also is pushable in order to be a candidate of pushable > tasks during pull algorithm. If the earliest_dl.next deadline > of the sr_rq is earlier than the earliest_dl.curr deadline

[RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-11-23 Thread Juri Lelli
ctrons.com> Cc: Olof Johansson <o...@lixom.net> Cc: Gregory CLEMENT <gregory.clem...@free-electrons.com> Cc: Paul Walmsley <p...@pwsan.com> Cc: Linus Walleij <linus.wall...@linaro.org> Cc: Chen-Yu Tsai <w...@csie.org> Cc: Thomas Petazzoni <thomas.petazz...@free-el

[RFC PATCH 1/8] ARM: initialize cpu_scale to its default

2015-11-23 Thread Juri Lelli
Instead of looping through all cpus calling set_capacity_scale, we can initialise cpu_scale per-cpu variables to SCHED_CAPACITY_SCALE with their definition. Cc: Russell King <li...@arm.linux.org.uk> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm/kernel/topology.c | 4

[RFC PATCH 0/8] CPUs capacity information for heterogeneous systems

2015-11-23 Thread Juri Lelli
. Comments, concerns and rants are more than welcome! Best, - Juri Juri Lelli (8): ARM: initialize cpu_scale to its default Documentation: arm: define DT cpu capacity bindings arm: parse cpu capacity from DT arm, dts: add TC2 cpu capacity information arm64: parse cpu capacity from DT

[RFC PATCH 4/8] arm, dts: add TC2 cpu capacity information

2015-11-23 Thread Juri Lelli
<mark.rutl...@arm.com> Cc: Ian Campbell <ijc+devicet...@hellion.org.uk> Cc: Kumar Gala <ga...@codeaurora.org> Cc: Russell King <li...@arm.linux.org.uk> Cc: devicet...@vger.kernel.org Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm/boot/dts/vexpress-v2p-ca15_a7

[RFC PATCH 6/8] arm64, dts: add Juno cpu capacity information

2015-11-23 Thread Juri Lelli
Murphy <robin.mur...@arm.com> Cc: devicet...@vger.kernel.org Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm64/boot/dts/arm/juno.dts | 7 +++ 1 file changed, 7 insertions(+) diff --git a/arch/arm64/boot/dts/arm/juno.dts b/arch/arm64/boot/dts/arm/juno.dts index d7cbdd4.

[RFC PATCH 5/8] arm64: parse cpu capacity from DT

2015-11-23 Thread Juri Lelli
m.com> Cc: Mark Brown <broo...@linaro.org> Cc: Sudeep Holla <sudeep.ho...@arm.com> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm64/kernel/topology.c | 46 1 file changed, 46 insertions(+) diff --git a/arch/arm64/

[RFC PATCH 7/8] arm: add sysfs cpu_capacity attribute

2015-11-23 Thread Juri Lelli
*/cpu_capacity Cc: Russell King <li...@arm.linux.org.uk> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm/kernel/topology.c | 68 ++ 1 file changed, 68 insertions(+) diff --git a/arch/arm/kernel/topology.c b/arch/arm/kernel/topology.c i

[RFC PATCH 8/8] arm64: add sysfs cpu_capacity attribute

2015-11-23 Thread Juri Lelli
*/cpu_capacity Cc: Catalin Marinas <catalin.mari...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc: Mark Brown <broo...@linaro.org> Cc: Sudeep Holla <sudeep.ho...@arm.com> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm64/kernel/topology.c | 68 +

[RFC PATCH 3/8] arm: parse cpu capacity from DT

2015-11-23 Thread Juri Lelli
King <li...@arm.linux.org.uk> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm/kernel/topology.c | 50 +- 1 file changed, 49 insertions(+), 1 deletion(-) diff --git a/arch/arm/kernel/topology.c b/arch/arm/kernel/topology.c i

Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings

2015-11-24 Thread Juri Lelli
Hi, On 23/11/15 20:06, Rob Herring wrote: > On Mon, Nov 23, 2015 at 02:28:35PM +0000, Juri Lelli wrote: > > ARM systems may be configured to have cpus with different power/performance > > characteristics within the same chip. In this case, additional information > > has

Re: [PATCH v3] sched/deadline: fix earliest_dl.next logic

2015-11-24 Thread Juri Lelli
Hi, On 24/11/15 09:58, Wanpeng Li wrote: > Ping Peterz, :-) > On 11/19/15 6:11 PM, Wanpeng li wrote: > >earliest_dl.next should cache deadline of the earliest ready task that > >is also enqueued in the pushable rbtree, as pull algorithm uses this > >information to find candidates for migration:

Re: [PATCH] cgroup: disable irqs while holding css_set_lock

2016-06-07 Thread Juri Lelli
Hi, On 06/06/16 19:24, Daniel Bristot de Oliveira wrote: > While testing the deadline scheduler + cgroup setup I hit this > warning. > > [ 132.612935] [ cut here ] > [ 132.612951] WARNING: CPU: 5 PID: 0 at kernel/softirq.c:150 > __local_bh_enable_ip+0x6b/0x80 > [

Re: [PATCH] cgroup: disable irqs while holding css_set_lock

2016-06-07 Thread Juri Lelli
On 07/06/16 09:39, Daniel Bristot de Oliveira wrote: > Ciao Juri, > Ciao, :-) > On 06/07/2016 07:14 AM, Juri Lelli wrote: > > Interesting. And your test is using cpuset controller to partion > > DEADLINE tasks and then modify groups concurrently? > > Yes. I wa

Re: [PATCH] cgroup: disable irqs while holding css_set_lock

2016-06-07 Thread Juri Lelli
On 07/06/16 12:26, Daniel Bristot de Oliveira wrote: > Ciao Juri, > > On 06/07/2016 10:30 AM, Juri Lelli wrote: > > So, this and the partitioned one could actually overlap, since we don't > > set cpu_exclusive. Is that right? > > > > I guess affinity mask of bo

Re: [RFC PATCH 3/3] sched/fair: Change @running of __update_load_avg() to @update_util

2016-06-03 Thread Juri Lelli
On 02/06/16 18:27, Dietmar Eggemann wrote: > On 02/06/16 10:25, Juri Lelli wrote: > > [...] > > >> @@ -2757,7 +2754,7 @@ __update_load_avg(u64 now, int cpu, struct sched_avg > >> *sa, > >>

Re: [RFC][PATCH 1/8] rtmutex: Deboost before waking up the top waiter

2016-06-14 Thread Juri Lelli
gt; the next patch, where we have rt_mutex_setprio() cache a pointer to > the top-most waiter task. If we, as before this change, do the wakeup > first and then deboost, this pointer might point into thin air. > > Cc: Steven Rostedt <rost...@goodmis.org> > Cc: Ingo Molnar &

Re: [RFC][PATCH 2/8] sched/rtmutex/deadline: Fix a PI crash for deadline tasks

2016-06-14 Thread Juri Lelli
nd rtmutex lock, and remove rt_mutex_adjust_prio(). Since > now we moved the deboost point, in order to avoid current to be > preempted due to deboost earlier before wake_up_q(), we also moved > preempt_disable() before unlocking rtmutex. > > Cc: Steven Rostedt <rost...@goodmis

Re: [RFC][PATCH 5/8] rtmutex: Clean up

2016-06-14 Thread Juri Lelli
Hi, On 07/06/16 21:56, Peter Zijlstra wrote: > Previous patches changed the meaning of the return value of > rt_mutex_slowunlock(); update comments and code to reflect this. > > Signed-off-by: Peter Zijlstra (Intel) > --- > kernel/futex.c | 12

Re: [RFC][PATCH 1/8] rtmutex: Deboost before waking up the top waiter

2016-06-14 Thread Juri Lelli
On 14/06/16 14:54, Peter Zijlstra wrote: > On Tue, Jun 14, 2016 at 10:09:34AM +0100, Juri Lelli wrote: > > I've got only nitpicks for the changelog. Otherwise the patch looks good > > to me (and yes, without it bw inheritance would be a problem). > > So for bw inheritance I

Re: [RFC][PATCH 2/8] sched/rtmutex/deadline: Fix a PI crash for deadline tasks

2016-06-14 Thread Juri Lelli
On 14/06/16 20:53, Xunlei Pang wrote: > On 2016/06/14 at 18:21, Juri Lelli wrote: > > Hi, > > > > On 07/06/16 21:56, Peter Zijlstra wrote: > >> From: Xunlei Pang <xlp...@redhat.com> > >> > >> A crash happened while I was playing with deadline

Re: [RFC][PATCH 6/8] sched/rtmutex: Refactor rt_mutex_setprio()

2016-06-14 Thread Juri Lelli
Hi, still digesting this change, but I'll point out below why I think you are hitting a NULL ptr dereference (discussed on IRC). On 07/06/16 21:56, Peter Zijlstra wrote: > With the introduction of SCHED_DEADLINE the whole notion that priority > is a single number is gone, therefore the @prio

Re: [RFC][PATCH 3/8] sched/deadline/rtmutex: Dont miss the dl_runtime/dl_period update

2016-06-14 Thread Juri Lelli
!dl_prio() condition. > > [peterz: I should introduce more task state comparators like > rt_mutex_waiter_less, all PI prio comparisons already have this DL > exception, except this one] > > Cc: Steven Rostedt <rost...@goodmis.org> > Cc: Ingo Molnar <mi...@redhat.co

Re: [RFC][PATCH 5/8] rtmutex: Clean up

2016-06-14 Thread Juri Lelli
On 14/06/16 14:32, Peter Zijlstra wrote: > On Tue, Jun 14, 2016 at 01:08:13PM +0100, Juri Lelli wrote: > > > + postunlock = rt_mutex_futex_unlock(_state->pi_mutex, _q); > > > > > > /* > > >* First unlock HB so the waiter does not spin on it on

Re: [RFC][PATCH 2/8] sched/rtmutex/deadline: Fix a PI crash for deadline tasks

2016-06-14 Thread Juri Lelli
On 14/06/16 14:07, Juri Lelli wrote: > On 14/06/16 20:53, Xunlei Pang wrote: > > On 2016/06/14 at 18:21, Juri Lelli wrote: > > > Hi, > > > > > > On 07/06/16 21:56, Peter Zijlstra wrote: > > >> From: Xunlei Pang <xlp...@redhat.com> > > >

Re: [RFC][PATCH 8/8] rtmutex: Fix PI chain order integrity

2016-06-14 Thread Juri Lelli
On 07/06/16 21:56, Peter Zijlstra wrote: > rt_mutex_waiter::prio is a copy of task_struct::prio which is updated > during the PI chain walk, such that the PI chain order isn't messed up > by (asynchronous) task state updates. > > Currently rt_mutex_waiter_less() uses task state for deadline

Re: [RFC][PATCH 1/8] rtmutex: Deboost before waking up the top waiter

2016-06-14 Thread Juri Lelli
On 14/06/16 09:36, Davidlohr Bueso wrote: > On Tue, 14 Jun 2016, Juri Lelli wrote: > > >Do we have any specific tests for this set? I'm running mine. > > pi_stress from rt-tests is a good workload to run for such changes. > > (https://git.kernel.org/cgit/utils/rt-tes

[PATCH v5 1/8] Documentation: arm: define DT cpu capacity-dmips-mhz bindings

2016-06-15 Thread Juri Lelli
tazz...@free-electrons.com> Cc: devicet...@vger.kernel.org Signed-off-by: Juri Lelli <juri.le...@arm.com> --- Changes from v1: - removed section regarding capacity-scale - added information regarding normalization Changes from v4: - binding changed to capacity-dmips-mhz - sections and c

[PATCH v5 5/8] arm64, dts: add Juno cpu capacity-dmips-mhz information

2016-06-15 Thread Juri Lelli
; Cc: Robin Murphy <robin.mur...@arm.com> Cc: devicet...@vger.kernel.org Signed-off-by: Juri Lelli <juri.le...@arm.com> --- Changes from v1: - capacity-scale removed Changes from v4: - binding changed to capacity-dmips-mhz --- arch/arm64/boot/dts/arm/juno.dts | 6 ++ 1 file chang

[PATCH v5 0/8] CPUs capacity information for heterogeneous systems

2016-06-15 Thread Juri Lelli
anch contains additional patches, useful to better understand how CPU capacity information is actually used by the scheduler. However, discussion regarding these additional patches is outside the scope of this posting. Best, - Juri Juri Lelli (8): Documentation: arm: define DT cpu capacity-dmips

[PATCH v5 8/8] arm64: add sysfs cpu_capacity attribute

2016-06-15 Thread Juri Lelli
Marinas <catalin.mari...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc: Mark Brown <broo...@linaro.org> Cc: Sudeep Holla <sudeep.ho...@arm.com> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm64/kernel/topology.c | 68 ++

[PATCH v5 7/8] arm: add sysfs cpu_capacity attribute

2016-06-15 Thread Juri Lelli
<li...@arm.linux.org.uk> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- arch/arm/kernel/topology.c | 68 ++ 1 file changed, 68 insertions(+) diff --git a/arch/arm/kernel/topology.c b/arch/arm/kernel/topology.c index 2bab290..a240bbd 10064

[PATCH v5 3/8] arm, dts: add TC2 cpu capacity-dmips-mhz information

2016-06-15 Thread Juri Lelli
<mark.rutl...@arm.com> Cc: Ian Campbell <ijc+devicet...@hellion.org.uk> Cc: Kumar Gala <ga...@codeaurora.org> Cc: Russell King <li...@arm.linux.org.uk> Cc: devicet...@vger.kernel.org Signed-off-by: Juri Lelli <juri.le...@arm.com> --- Changes from v1: - capacity-scale rem

[PATCH v5 2/8] arm: parse cpu capacity-dmips-mhz from DT

2016-06-15 Thread Juri Lelli
(which gets used if arch_scale_cpu_capacity is not defined) is overwritten. Cc: Russell King <li...@arm.linux.org.uk> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- Changes from v1: - normalize w.r.t. highest capacity found in DT - bailout conditions (all-or-nothing) Cha

[PATCH v5 4/8] arm64: parse cpu capacity-dmips-mhz from DT

2016-06-15 Thread Juri Lelli
. Cc: Catalin Marinas <catalin.mari...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc: Mark Brown <broo...@linaro.org> Cc: Sudeep Holla <sudeep.ho...@arm.com> Signed-off-by: Juri Lelli <juri.le...@arm.com> --- Changes from v1: - normalize w.r.t. highest ca

[PATCH v5 6/8] arm64, dts: add Juno r2 cpu capacity-dmips-mhz information

2016-06-15 Thread Juri Lelli
; Cc: Robin Murphy <robin.mur...@arm.com> Cc: devicet...@vger.kernel.org Signed-off-by: Juri Lelli <juri.le...@arm.com> --- Changes from v4: - new patch since Juno r2 dt has been merged --- arch/arm64/boot/dts/arm/juno-r2.dts | 6 ++ 1 file changed, 6 insertions(+) diff --gi

Re: [PATCH v5 4/8] arm64: parse cpu capacity-dmips-mhz from DT

2016-06-15 Thread Juri Lelli
On 15/06/16 11:20, Mark Brown wrote: > On 15 June 2016 at 11:17, Juri Lelli <juri.le...@arm.com> wrote: > > > > Cc: Mark Brown <broo...@linaro.org> > > > > Please use broo...@kernel.org for any upstream work, I'm really not set up > to handle

Re: [RFC][PATCH 8/8] rtmutex: Fix PI chain order integrity

2016-06-15 Thread Juri Lelli
On 14/06/16 21:44, Peter Zijlstra wrote: > On Tue, Jun 14, 2016 at 06:39:08PM +0100, Juri Lelli wrote: > > On 07/06/16 21:56, Peter Zijlstra wrote: > > > rt_mutex_waiter::prio is a copy of task_struct::prio which is updated > > > during the PI chain walk, such that the

Re: [PATCH v5 1/8] Documentation: arm: define DT cpu capacity-dmips-mhz bindings

2016-06-15 Thread Juri Lelli
On 15/06/16 15:04, Mark Brown wrote: > On Wed, Jun 15, 2016 at 11:17:50AM +0100, Juri Lelli wrote: > > > +CPU capacities are obtained by running a suitable benchmark. This binding > > makes > > +no aspersions on the validity or suitability of any particular benchm

Re: [PATCH v5 1/8] Documentation: arm: define DT cpu capacity-dmips-mhz bindings

2016-06-15 Thread Juri Lelli
On 15/06/16 14:51, Vincent Guittot wrote: > On 15 June 2016 at 12:17, Juri Lelli <juri.le...@arm.com> wrote: [...] > > +== > > +ARM C

Re: [RFC PATCH 3/3] sched/fair: Change @running of __update_load_avg() to @update_util

2016-06-02 Thread Juri Lelli
Hi, another minor comment below. :-) On 01/06/16 20:39, Dietmar Eggemann wrote: > The information whether a se/cfs_rq should get its load and > utilization (se representing a task and root cfs_rq) or only its load > (se representing a task group and cfs_rq owned by this se) updated can > be

Re: [RFC PATCH 1/3] sched/fair: Aggregate task utilization only on root cfs_rq

2016-06-02 Thread Juri Lelli
Hi, minor comment below. On 01/06/16 20:39, Dietmar Eggemann wrote: > cpu utilization (cpu_util()) is defined as the cpu (original) capacity > capped cfs_rq->avg->util_avg signal of the root cfs_rq. > > With the current pelt version, the utilization of a task [en|de]queued > on/from a cfs_rq,

Re: [RFC PATCH 1/3] sched/fair: Aggregate task utilization only on root cfs_rq

2016-06-02 Thread Juri Lelli
On 02/06/16 16:53, Dietmar Eggemann wrote: > On 02/06/16 10:23, Juri Lelli wrote: > > >> diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c > >> index 218f8e83db73..212becd3708f 100644 > >> --- a/kernel/sched/fair.c > >> +++ b/kernel/sched/fair.c &g

Re: [PATCH v5 4/8] arm64: parse cpu capacity-dmips-mhz from DT

2016-06-15 Thread Juri Lelli
On 15/06/16 14:49, Mark Brown wrote: > On Wed, Jun 15, 2016 at 11:17:53AM +0100, Juri Lelli wrote: > > > + if (!raw_capacity) { > > + raw_capacity = kzalloc(sizeof(*raw_capacity) * > > + num_possible_cpus(), G

<    1   2   3   4   5   6   7   8   9   10   >