The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Dietmar Eggemann <dietmar.eggemann@arm.com>
To: Vincent Guittot <vincent.guittot@linaro.org>,
	Christian Borntraeger <borntraeger@de.ibm.com>
Cc: Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: 5.6-rc3: WARNING: CPU: 48 PID: 17435 at kernel/sched/fair.c:380 enqueue_task_fair+0x328/0x440
Date: Thu, 5 Mar 2020 12:54:59 +0100	[thread overview]
Message-ID: <b582bd06-cac3-bc5d-3b26-68d15e36454f@arm.com> (raw)
In-Reply-To: <20200305093003.GA32088@vingu-book>

On 05/03/2020 10:30, Vincent Guittot wrote:
> Le mercredi 04 mars 2020 à 20:59:33 (+0100), Christian Borntraeger a écrit :
>>
>> On 04.03.20 20:38, Christian Borntraeger wrote:
>>>
>>> On 04.03.20 20:19, Dietmar Eggemann wrote:

[...]

> Could you try to add the patch below on top of dietmar's one so we will have the status of
> each level of the hierarchy ?
> The 1st level seems ok but something wrong happens while walking the hierarchy
> 
> diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
> index 69fc30db7440..9ccde775e02e 100644
> --- a/kernel/sched/fair.c
> +++ b/kernel/sched/fair.c
> @@ -5331,14 +5331,17 @@ enqueue_task_fair(struct rq *rq, struct task_struct *p, int flags)
>  
>         if (rq->tmp_alone_branch != &rq->leaf_cfs_rq_list) {
>                 char path[64];
> +               se = &p->se;
>  
> -               cfs_rq = cfs_rq_of(&p->se);
> +               for_each_sched_entity(se) {
> +                       cfs_rq = cfs_rq_of(se);
>  
> -               sched_trace_cfs_rq_path(cfs_rq, path, 64);
> +                       sched_trace_cfs_rq_path(cfs_rq, path, 64);
>  
> -               printk("CPU%d path=%s on_list=%d nr_running=%d p=[%s %d]\n",
> -                      cpu_of(rq), path, cfs_rq->on_list, cfs_rq->nr_running,
> +                       printk("CPU%d path=%s on_list=%d nr_running=%d throttled=%d p=[%s %d]\n",
> +                      cpu_of(rq), path, cfs_rq->on_list, cfs_rq->nr_running, cfs_rq_throttled(cfs_rq),
>                        p->comm, p->pid);
> +               }
>         }
>  
>         assert_list_leaf_cfs_rq(rq);

Yeah, that's better.

The fact that the task 'CPU 1/KVM' in
'machine-qemu\x2d16\x2dtest14.scope' hit the assert only tells us that
some list_[add|\del]_leaf_cfs_rq on CPU62 before left
rq->tmp_alone_branch != rq->leaf_cfs_rq_list.

I see that cgroup-v2 is used here.

>> [   25.680326] CPU62 path=/machine.slice/machine-test.slice/machine-qemu\x2d16\x2dtest14. on_list=1 nr_running=1 p=[CPU 1/KVM 2543]
>> [   25.680334] ------------[ cut here ]------------
>> [   25.680335] rq->tmp_alone_branch != &rq->leaf_cfs_rq_list
>> [   25.680351] WARNING: CPU: 61 PID: 2535 at kernel/sched/fair.c:380 enqueue_task_fair+0x3f6/0x4a8

[...]

      parent reply	other threads:[~2020-03-05 11:55 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-28  7:54 5.6-rc3: WARNING: CPU: 48 PID: 17435 at kernel/sched/fair.c:380 enqueue_task_fair+0x328/0x440 Christian Borntraeger
2020-02-28 12:04 ` Christian Borntraeger
2020-02-28 13:32   ` Vincent Guittot
2020-02-28 13:43     ` Christian Borntraeger
2020-02-28 15:08       ` Christian Borntraeger
2020-02-28 15:37         ` Vincent Guittot
2020-02-28 15:42           ` Christian Borntraeger
2020-02-28 16:32             ` Qais Yousef
2020-02-28 16:35             ` Vincent Guittot
2020-03-02 11:16               ` Christian Borntraeger
2020-03-02 18:17                 ` Christian Borntraeger
2020-03-03  7:37                   ` Christian Borntraeger
2020-03-03  7:55                     ` Vincent Guittot
2020-03-04 15:26                       ` Vincent Guittot
2020-03-04 17:42                         ` Christian Borntraeger
2020-03-04 17:51                           ` Vincent Guittot
2020-03-04 19:19                           ` Dietmar Eggemann
2020-03-04 19:38                             ` Christian Borntraeger
2020-03-04 19:59                               ` Christian Borntraeger
2020-03-05  9:30                                 ` Vincent Guittot
2020-03-05 11:28                                   ` Christian Borntraeger
2020-03-05 12:12                                     ` Dietmar Eggemann
2020-03-05 12:33                                       ` Vincent Guittot
2020-03-05 12:48                                         ` Christian Borntraeger
2020-03-05 13:02                                           ` Vincent Guittot
2020-03-05 13:18                                           ` Christian Borntraeger
2020-03-05 12:14                                     ` Vincent Guittot
2020-03-05 11:54                                   ` Dietmar Eggemann [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b582bd06-cac3-bc5d-3b26-68d15e36454f@arm.com \
    --to=dietmar.eggemann@arm.com \
    --cc=borntraeger@de.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=vincent.guittot@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox