diff options
| author | Chen Yu <yu.c.chen@intel.com> | 2026-05-13 13:39:21 -0700 |
|---|---|---|
| committer | Peter Zijlstra <peterz@infradead.org> | 2026-05-18 21:33:17 +0200 |
| commit | 03755348b8e74421f92ffed9da159175a698290b (patch) | |
| tree | e1abf78629f96711a2405d5e125e1086f48c8c4b /scripts/objdiff | |
| parent | 91d07324c9305c0e4afff0cc859cac96594daa88 (diff) | |
sched/cache: Fix unpaired account_llc_enqueue/dequeue
There is a race condition that, after a task is enqueued
on a runqueue, task_llc(p) may change due to CPU hotplug,
because the llc_id is dynamically allocated and adjusted
at runtime.
Therefore, checking task_llc(p) to determine whether the
task is being dequeued from its preferred LLC is unreliable
and can cause inconsistent values.
To fix this problem, record whether p is enqueued on its
preferred LLC, in order to pair with account_llc_dequeue()
to maintain a consistent nr_pref_llc_running per runqueue.
This bug was reported by sashiko, and the solution was once
suggested by Prateek.
Fixes: 46afe3af7ead ("sched/cache: Track LLC-preferred tasks per runqueue")
Suggested-by: K Prateek Nayak <kprateek.nayak@amd.com>
Signed-off-by: Chen Yu <yu.c.chen@intel.com>
Co-developed-by: Tim Chen <tim.c.chen@linux.intel.com>
Signed-off-by: Tim Chen <tim.c.chen@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://patch.msgid.link/0c8c6a1571d66792a4d2ff0103ba3cc13e059046.1778703694.git.tim.c.chen@linux.intel.com
Diffstat (limited to 'scripts/objdiff')
0 files changed, 0 insertions, 0 deletions
