]> git.baikalelectronics.ru Git - kernel.git/commit
perf: Fix PERF_EVENT_IOC_PERIOD migration race
authorPeter Zijlstra <peterz@infradead.org>
Tue, 4 Aug 2015 17:22:49 +0000 (19:22 +0200)
committerIngo Molnar <mingo@kernel.org>
Wed, 12 Aug 2015 09:37:22 +0000 (11:37 +0200)
commit78d45574d27cbc0c7c02547603936b18ff7c4478
treeecd84ef16259aedf4343b5b908eec40953c696d8
parent826c3b4a32807b97963db6a02f5dbc74b00aae0d
perf: Fix PERF_EVENT_IOC_PERIOD migration race

I ran the perf fuzzer, which triggered some WARN()s which are due to
trying to stop/restart an event on the wrong CPU.

Use the normal IPI pattern to ensure we run the code on the correct CPU.

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Vince Weaver <vincent.weaver@maine.edu>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Fixes: aa7d70b41e5d ("perf: Fix PERF_EVENT_IOC_PERIOD to force-reset the period")
Signed-off-by: Ingo Molnar <mingo@kernel.org>
kernel/events/core.c