From: Steven Rostedt <rostedt@goodmis.org>
To: Kirill Tkhai <ktkhai@virtuozzo.com>
Cc: Daniel Bristot de Oliveira <bristot@redhat.com>,
linux-kernel@vger.kernel.org, Juri Lelli <juri.lelli@redhat.com>,
Luca Abeni <luca.abeni@santannapisa.it>,
Tommaso Cucinotta <tommaso.cucinotta@santannapisa.it>,
Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@kernel.org>,
stable@vger.kernel.org
Subject: Re: [PATCH V2] sched/deadline: Update rq_clock of later_rq when pushing a task
Date: Wed, 1 Aug 2018 22:45:56 -0400 [thread overview]
Message-ID: <20180801224556.2d0b9342@vmware.local.home> (raw)
In-Reply-To: <12b65bbb-e82a-7fa5-1225-5047096d48f8@virtuozzo.com>
On Mon, 16 Jul 2018 13:45:21 +0300
Kirill Tkhai <ktkhai@virtuozzo.com> wrote:
> > --- a/kernel/sched/deadline.c
> > +++ b/kernel/sched/deadline.c
> > @@ -2090,8 +2090,16 @@ static int push_dl_task(struct rq *rq)
> > sub_rq_bw(&next_task->dl, &rq->dl);
> > set_task_cpu(next_task, later_rq->cpu);
> > add_rq_bw(&next_task->dl, &later_rq->dl);
> > +
> > + /*
> > + * Update the later_rq clock here, because the clock is used
> > + * by the cpufreq_update_util() inside __add_running_bw().
> > + * Then, set ENQUEUE_NOCLOCK flag to avoid updating the rq_clock
> > + * again in the activate_task()->enqueue_task().
>
> Is the second sentence really needed? It seems everybody knows, what NOCLOCK
> flag does, and we does not have to paraphrase this in every place it's used :)
I would keep the mention, but change the comment:
/*
* Update the later_rq clock before calling add_running_bw()
* because the clock is used by cpufreq_update_util() that is
* inside __add_running_bw(). As the later_rq clock is already
* updated, we need to set ENQUEUE_NOCLOCK to prevent
* activate_task() from updating it again.
*/
Other than that...
Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
-- Steve
>
> > + */
> > + update_rq_clock(later_rq);
> > add_running_bw(&next_task->dl, &later_rq->dl);
> > - activate_task(later_rq, next_task, 0);
> > + activate_task(later_rq, next_task, ENQUEUE_NOCLOCK);
> > ret = 1;
> >
> > resched_curr(later_rq);
prev parent reply other threads:[~2018-08-02 2:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-13 14:09 [PATCH] sched/deadline: Update rq_clock of later_rq when pushing a task Daniel Bristot de Oliveira
2018-07-14 13:37 ` [PATCH V2] " Daniel Bristot de Oliveira
2018-07-16 9:37 ` Juri Lelli
2018-07-16 12:10 ` Daniel Bristot de Oliveira
2018-07-16 10:45 ` Kirill Tkhai
2018-08-02 2:45 ` Steven Rostedt [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=20180801224556.2d0b9342@vmware.local.home \
--to=rostedt@goodmis.org \
--cc=bristot@redhat.com \
--cc=juri.lelli@redhat.com \
--cc=ktkhai@virtuozzo.com \
--cc=linux-kernel@vger.kernel.org \
--cc=luca.abeni@santannapisa.it \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=stable@vger.kernel.org \
--cc=tommaso.cucinotta@santannapisa.it \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.