summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/task-analyzer.py
diff options
context:
space:
mode:
authorAndreas Hindborg <a.hindborg@kernel.org>2026-06-08 14:32:00 +0200
committerAndreas Hindborg <a.hindborg@kernel.org>2026-09-29 10:30:08 +0200
commite84c9b64df615e658e47561b835c1364dc48f0c0 (patch)
tree18b980ae5152dbc5ea5dd5f3f5c33746a6458a29 /tools/perf/scripts/python/task-analyzer.py
parentec27f3b700010d2ebae1cde2df0246197689d159 (diff)
downloadlinux-e84c9b64df615e658e47561b835c1364dc48f0c0.tar.gz
linux-e84c9b64df615e658e47561b835c1364dc48f0c0.zip
rust: configfs: fix data offset calculation for subsystem callbacks
`get_group_data()` chooses between `Group::<Parent>::container_of()` and `Subsystem::<Parent>::container_of()` based on whether `this` represents the root group of a configfs subsystem. It detects this by checking `(*this).cg_subsys.is_null()`, but `link_group()` in `fs/configfs/dir.c` unconditionally sets `cg_subsys` for every `config_group` attached anywhere in a registered subsystem, including the subsystem's own `su_group`. The only `config_group` with a NULL `cg_subsys` is the configfs root, on which userspace cannot trigger callbacks. The check is therefore always false at runtime, and the `Subsystem` branch is dead. Subsystem-level callbacks reach the `Group` branch and may read `data` at the wrong offset. Thus change the `is_root` check to correctly identify whether a group is a root group by comparing `this` to `subsys.su_group`. Cc: stable@vger.kernel.org Fixes: 446cafc295bf ("rust: configfs: introduce rust support for configfs") Link: https://msgid.link/20260608-configfs-fix-offset-v1-1-7f01b8fb9e5f@kernel.org [ Andreas: Fix clippy warning on 1.85.0 by moving safety comment. ] Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/task-analyzer.py')
0 files changed, 0 insertions, 0 deletions