Commit ce0f17fc authored by Peter Zijlstra's avatar Peter Zijlstra

perf: Fix get_recursion_context()

One should use in_serving_softirq() to detect SoftIRQ context.

Fixes: 96f6d444 ("perf_counter: avoid recursion")
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20201030151955.120572175@infradead.org
parent 9dfa9a5c
...@@ -211,7 +211,7 @@ static inline int get_recursion_context(int *recursion) ...@@ -211,7 +211,7 @@ static inline int get_recursion_context(int *recursion)
rctx = 3; rctx = 3;
else if (in_irq()) else if (in_irq())
rctx = 2; rctx = 2;
else if (in_softirq()) else if (in_serving_softirq())
rctx = 1; rctx = 1;
else else
rctx = 0; rctx = 0;
......
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