Commit a1bd0685 authored by Phil Auld's avatar Phil Auld Committed by Ingo Molnar

sched: Fix use of count for nr_running tracepoint

The count field is meant to tell if an update to nr_running
is an add or a subtract. Make it do so by adding the missing
minus sign.

Fixes: 9d246053 ("sched: Add a tracepoint to track rq->nr_running")
Signed-off-by: default avatarPhil Auld <pauld@redhat.com>
Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/20200805203138.1411-1-pauld@redhat.com
parent 4da9f330
...@@ -1999,7 +1999,7 @@ static inline void sub_nr_running(struct rq *rq, unsigned count) ...@@ -1999,7 +1999,7 @@ static inline void sub_nr_running(struct rq *rq, unsigned count)
{ {
rq->nr_running -= count; rq->nr_running -= count;
if (trace_sched_update_nr_running_tp_enabled()) { if (trace_sched_update_nr_running_tp_enabled()) {
call_trace_sched_update_nr_running(rq, count); call_trace_sched_update_nr_running(rq, -count);
} }
/* Check if we still need preemption */ /* Check if we still need preemption */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment