mirror of
https://github.com/torvalds/linux.git
synced 2024-11-23 20:51:44 +00:00
This is a trivial patch that changes a check for a cpumask from a NULL
pointer to using cpumask_available(), which will do the check. This is because cpumasks when not allocated are always set, and clang complains about it. -----BEGIN PGP SIGNATURE----- iQExBAABCAAbBQJZEcUIFBxyb3N0ZWR0QGdvb2RtaXMub3JnAAoJEMm5BfJq2Y3L zygH/051hNj3aZlSZCD1pXwPkHgeVBn7lSB9k6hcJ5J/OknL/hNXws3Dv4Lb7Dzj cZhg62LTwwS6PVCJtOHk+PE/c5FIdY9o1mXJpAst6wbl9Sp1lzPJbFum45UadvWn UyU3RP0ncSgfojyrwIu6XyND7/NatdYk9irTMWL9+cDuy9xGvJgRX1sf7tXmxj4C AbZzQorDw7XDczDbvFM1XyPU3ApGUDqQ7VhCEBP6ivE+5Ceoo9xi/z7yfKyjLeb+ H7+/eA8ztaMLgTzLWwkFKdP/knqwPmAb+MHTR0DoLHcVe7fbbxFS7x+cfR8mfIA9 8tA5SUxc7bymRvDAcN2dMrtL7f8= =3hKI -----END PGP SIGNATURE----- Merge tag 'trace-v4.12-3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull tracing fix from Steven Rostedt: "This is a trivial patch that changes a check for a cpumask from a NULL pointer to using cpumask_available(), which will do the check. This is because cpumasks when not allocated are always set, and clang complains about it" * tag 'trace-v4.12-3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: tracing: Use cpumask_available() to check if cpumask variable may be used
This commit is contained in:
commit
29250d301b
@ -3311,13 +3311,14 @@ static void test_cpu_buff_start(struct trace_iterator *iter)
|
|||||||
if (!(iter->iter_flags & TRACE_FILE_ANNOTATE))
|
if (!(iter->iter_flags & TRACE_FILE_ANNOTATE))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (iter->started && cpumask_test_cpu(iter->cpu, iter->started))
|
if (cpumask_available(iter->started) &&
|
||||||
|
cpumask_test_cpu(iter->cpu, iter->started))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (per_cpu_ptr(iter->trace_buffer->data, iter->cpu)->skipped_entries)
|
if (per_cpu_ptr(iter->trace_buffer->data, iter->cpu)->skipped_entries)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (iter->started)
|
if (cpumask_available(iter->started))
|
||||||
cpumask_set_cpu(iter->cpu, iter->started);
|
cpumask_set_cpu(iter->cpu, iter->started);
|
||||||
|
|
||||||
/* Don't print started cpu buffer for the first entry of the trace */
|
/* Don't print started cpu buffer for the first entry of the trace */
|
||||||
|
Loading…
Reference in New Issue
Block a user