From: Tejun Heo <tj@kernel.org>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Thomas Graf <tgraf@suug.ch>, David Vernet <void@manifault.com>,
Andrea Righi <arighi@nvidia.com>,
Changwoo Min <changwoo@igalia.com>,
Emil Tsalapatis <emil@etsalapatis.com>,
linux-crypto@vger.kernel.org, sched-ext@lists.linux.dev,
linux-kernel@vger.kernel.org, Florian Westphal <fw@strlen.de>,
netdev@vger.kernel.org, NeilBrown <neil@brown.name>
Subject: [PATCH v2 sched_ext/for-7.1-fixes] sched_ext: Mark scx_sched_hash insecure_elasticity
Date: Sun, 19 Apr 2026 05:33:41 -1000 [thread overview]
Message-ID: <aeT11WIF6kzvifm7@slm.duckdns.org> (raw)
In-Reply-To: <aeLhQRFPEY24ySIq@gondor.apana.org.au>
scx_sched_hash is inserted into under scx_sched_lock (raw_spinlock_irq)
in scx_link_sched(). rhashtable's sync grow path calls get_random_u32()
and does a GFP_ATOMIC allocation; both acquire regular spinlocks, which
is unsafe under raw_spinlock_t. Set insecure_elasticity to skip the
sync grow.
v2:
- Dropped dsq_hash changes. Insertion is not under raw_spin_lock.
- Switched from no_sync_grow flag to insecure_elasticity.
Fixes: 25037af712eb ("sched_ext: Add rhashtable lookup for sub-schedulers")
Signed-off-by: Tejun Heo <tj@kernel.org>
---
kernel/sched/ext.c | 1 +
1 file changed, 1 insertion(+)
--- a/kernel/sched/ext.c
+++ b/kernel/sched/ext.c
@@ -32,6 +32,7 @@ static const struct rhashtable_params sc
.key_len = sizeof_field(struct scx_sched, ops.sub_cgroup_id),
.key_offset = offsetof(struct scx_sched, ops.sub_cgroup_id),
.head_offset = offsetof(struct scx_sched, hash_node),
+ .insecure_elasticity = true, /* inserted under scx_sched_lock */
};
static struct rhashtable scx_sched_hash;
next prev parent reply other threads:[~2026-04-19 15:33 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-17 0:24 [PATCH for-7.1-fixes 1/2] rhashtable: add no_sync_grow option Tejun Heo
2026-04-17 0:24 ` [PATCH for-7.1-fixes 2/2] sched_ext: mark scx_sched_hash and dsq_hash no_sync_grow Tejun Heo
2026-04-17 0:43 ` [PATCH for-7.1-fixes 1/2] rhashtable: add no_sync_grow option Herbert Xu
2026-04-17 0:53 ` Tejun Heo
2026-04-17 1:11 ` Herbert Xu
2026-04-17 7:38 ` Tejun Heo
2026-04-17 7:51 ` Herbert Xu
2026-04-17 16:25 ` Tejun Heo
2026-04-18 0:44 ` Herbert Xu
2026-04-18 0:52 ` Tejun Heo
2026-04-18 0:53 ` Herbert Xu
2026-04-18 1:38 ` [PATCH] rhashtable: Restore insecure_elasticity toggle Herbert Xu
2026-04-18 1:41 ` [v2 PATCH] " Herbert Xu
2026-04-19 15:33 ` Tejun Heo [this message]
2026-04-19 15:34 ` [PATCH v2 sched_ext/for-7.1-fixes] sched_ext: Mark scx_sched_hash insecure_elasticity Tejun Heo
2026-04-20 1:46 ` [PATCH] rhashtable: Restore insecure_elasticity toggle kernel test robot
2026-04-20 1:46 ` kernel test robot
2026-04-20 17:22 ` kernel test robot
2026-04-17 1:22 ` [PATCH for-7.1-fixes 1/2] rhashtable: add no_sync_grow option Herbert Xu
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=aeT11WIF6kzvifm7@slm.duckdns.org \
--to=tj@kernel.org \
--cc=arighi@nvidia.com \
--cc=changwoo@igalia.com \
--cc=emil@etsalapatis.com \
--cc=fw@strlen.de \
--cc=herbert@gondor.apana.org.au \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=neil@brown.name \
--cc=netdev@vger.kernel.org \
--cc=sched-ext@lists.linux.dev \
--cc=tgraf@suug.ch \
--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.