Re: [v2] powerpc/perf: Fix kernel address leak to userspace via BHRB buffer

2018-03-28 Thread Michael Ellerman
On Wed, 2018-03-21 at 11:40:25 UTC, Madhavan Srinivasan wrote: > The current Branch History Rolling Buffer (BHRB) code does > not check for any privilege levels before updating the data > from BHRB. This leaks kernel addresses to userspace even when > profiling only with userspace privileges. Add

[PATCH v2] powerpc/perf: Fix kernel address leak to userspace via BHRB buffer

2018-03-21 Thread Madhavan Srinivasan
The current Branch History Rolling Buffer (BHRB) code does not check for any privilege levels before updating the data from BHRB. This leaks kernel addresses to userspace even when profiling only with userspace privileges. Add proper checks to prevent it. Acked-by: Balbir Singh