All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: Qiurong Fang <fangqiurong@kylinos.cn>
Cc: sched-ext@lists.linux.dev, David Vernet <void@manifault.com>,
	Andrea Righi <arighi@nvidia.com>,
	Changwoo Min <changwoo@igalia.com>,
	Emil Tsalapatis <emil@etsalapatis.com>,
	linux-kernel@vger.kernel.org, tj@kernel.org
Subject: Re: [PATCH v2] sched_ext: Close the pre-enable ops error claim window
Date: Fri, 11 Sep 2026 05:24:45 -1000	[thread overview]
Message-ID: <664afc289472acecc783762fdf7a9baa@kernel.org> (raw)
In-Reply-To: <20260911024256.125287-1-fangqiurong@kylinos.cn>

Hello, Qiurong.

On Fri, Sep 11, 2026 at 10:42:56AM +0800, Qiurong Fang wrote:
> +		scx_tryset_enable_state(SCX_DISABLED, SCX_ENABLING);

All allocation failures precede ops->priv publication, so no disable can
race here and the state must still be SCX_ENABLING. Please use:

        WARN_ON_ONCE(scx_set_enable_state(SCX_DISABLED) != SCX_ENABLING);

Please also update the moved comment. Allocation failure still unwinds
locally. Full disabling on failure applies only after
scx_alloc_and_add_sched() succeeds.

Thanks.

-- 
tejun

  reply	other threads:[~2026-09-11 15:24 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-10  8:45 [PATCH] sched_ext: Close the pre-enable ops error claim window Qiurong Fang
2026-09-10  9:01 ` sashiko-bot
2026-09-10 21:40 ` Tejun Heo
2026-09-11  2:42 ` [PATCH v2] " Qiurong Fang
2026-09-11 15:24   ` Tejun Heo [this message]
2026-09-12 13:15   ` [PATCH v3] " Qiurong Fang
2026-09-13 15:59     ` Tejun Heo

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=664afc289472acecc783762fdf7a9baa@kernel.org \
    --to=tj@kernel.org \
    --cc=arighi@nvidia.com \
    --cc=changwoo@igalia.com \
    --cc=emil@etsalapatis.com \
    --cc=fangqiurong@kylinos.cn \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sched-ext@lists.linux.dev \
    --cc=void@manifault.com \
    /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.