diff options
| author | Peter Zijlstra <[email protected]> | 2021-06-11 08:28:13 +0000 |
|---|---|---|
| committer | Peter Zijlstra <[email protected]> | 2021-06-18 09:43:07 +0000 |
| commit | 3ba9f93b12361e005dd65fcc8072b42e3189f4f4 (patch) | |
| tree | ff7b3224fb4f03ea17ac76b0d1ad0c2431d0a7ab /tools/perf/scripts/python/exported-sql-viewer.py | |
| parent | sched: Introduce task_is_running() (diff) | |
| download | kernel-3ba9f93b12361e005dd65fcc8072b42e3189f4f4.tar.gz kernel-3ba9f93b12361e005dd65fcc8072b42e3189f4f4.zip | |
sched,perf,kvm: Fix preemption condition
When ran from the sched-out path (preempt_notifier or perf_event),
p->state is irrelevant to determine preemption. You can get preempted
with !task_is_running() just fine.
The right indicator for preemption is if the task is still on the
runqueue in the sched-out path.
Signed-off-by: Peter Zijlstra (Intel) <[email protected]>
Acked-by: Mark Rutland <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions
