The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Juri Lelli <juri.lelli@redhat.com>
To: trix@redhat.com
Cc: mingo@redhat.com, peterz@infradead.org,
	vincent.guittot@linaro.org, dietmar.eggemann@arm.com,
	rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de,
	bristot@redhat.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] sched/deadline: fix BUG_ON() ENQUEUE_REPLENISH check
Date: Mon, 8 Feb 2021 11:41:31 +0100	[thread overview]
Message-ID: <20210208104131.GB5756@localhost.localdomain> (raw)
In-Reply-To: <20210206204851.3673588-1-trix@redhat.com>

Hi,

On 06/02/21 12:48, trix@redhat.com wrote:
> From: Tom Rix <trix@redhat.com>
> 
> When the BUG_ON check for (flags != ENQUEUE_REPLENISH) was created, the
> flag was set to ENQUEUE_REPLENISH in rt_mutex_setprio(), now it is or-ed
> in.  So the checking logic needs to change.
> 
> Fixes: 1de64443d755 ("sched/core: Fix task and run queue sched_info::run_delay inconsistencies")
> Signed-off-by: Tom Rix <trix@redhat.com>
> ---
>  kernel/sched/deadline.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/kernel/sched/deadline.c b/kernel/sched/deadline.c
> index 1508d126e88b..f50d20b7fe7c 100644
> --- a/kernel/sched/deadline.c
> +++ b/kernel/sched/deadline.c
> @@ -1561,7 +1561,7 @@ static void enqueue_task_dl(struct rq *rq, struct task_struct *p, int flags)
>  		 * the throttle.
>  		 */
>  		p->dl.dl_throttled = 0;
> -		BUG_ON(!is_dl_boosted(&p->dl) || flags != ENQUEUE_REPLENISH);
> +		BUG_ON(!is_dl_boosted(&p->dl) || !(flags & ENQUEUE_REPLENISH));

Uhu, isn't this actually the else branch of "if (is_dl_boosted())"? If
yes, I don't see how this is not always triggering. :-/

Thanks,
Juri


      reply	other threads:[~2021-02-08 10:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-06 20:48 [PATCH] sched/deadline: fix BUG_ON() ENQUEUE_REPLENISH check trix
2021-02-08 10:41 ` Juri Lelli [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=20210208104131.GB5756@localhost.localdomain \
    --to=juri.lelli@redhat.com \
    --cc=bristot@redhat.com \
    --cc=bsegall@google.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=trix@redhat.com \
    --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