diff options
author | 2025-07-12 03:33:46 +0000 | |
---|---|---|
committer | 2025-07-14 17:16:32 +0200 | |
commit | aa4f74dfd42ba4399f785fb9c460a11bd1756f0a (patch) | |
tree | 193e027519bfbc5bc10fdfea5407031b9e707802 /rust/pin-init/internal/src | |
parent | sched: Move update_curr_task logic into update_curr_se (diff) | |
download | wireguard-linux-aa4f74dfd42ba4399f785fb9c460a11bd1756f0a.tar.xz wireguard-linux-aa4f74dfd42ba4399f785fb9c460a11bd1756f0a.zip |
sched: Fix runtime accounting w/ split exec & sched contexts
Without proxy-exec, we normally charge the "current" task for
both its vruntime as well as its sum_exec_runtime.
With proxy, however, we have two "current" contexts: the
scheduler context and the execution context. We want to charge
the execution context rq->curr (ie: proxy/lock holder) execution
time to its sum_exec_runtime (so it's clear to userland the
rq->curr task *is* running), as well as its thread group.
However the rest of the time accounting (such a vruntime and
cgroup accounting), we charge against the scheduler context
(rq->donor) task, because it is from that task that the time
is being "donated".
If the donor and curr tasks are the same, then it's the same as
without proxy.
Signed-off-by: John Stultz <jstultz@google.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: K Prateek Nayak <kprateek.nayak@amd.com>
Link: https://lkml.kernel.org/r/20250712033407.2383110-6-jstultz@google.com
Diffstat (limited to 'rust/pin-init/internal/src')
0 files changed, 0 insertions, 0 deletions