Re: [PATCH] powerpc/perf: Fix crash with 'is_sier_available' when pmu is not set

2020-11-23 Thread Athira Rajeev
> On 23-Nov-2020, at 4:49 PM, Michael Ellerman wrote: > > Hi Athira, > > Athira Rajeev writes: >> On systems without any platform specific PMU driver support registered or >> Generic Compat PMU support registered, > > The compat PMU is registered just like other PMUs, so I don't see how we

Re: [PATCH] powerpc/perf: Fix crash with 'is_sier_available' when pmu is not set

2020-11-23 Thread Michael Ellerman
Hi Athira, Athira Rajeev writes: > On systems without any platform specific PMU driver support registered or > Generic Compat PMU support registered, The compat PMU is registered just like other PMUs, so I don't see how we can crash like this if the compat PMU is active? ie. if we're using the

Re: [PATCH] powerpc/perf: Fix crash with 'is_sier_available' when pmu is not set

2020-11-23 Thread Sachin Sant
> When perf record session started with "-I" option, capture registers > via intr-regs, on each sample ‘is_sier_available()'i is called to check > for the SIER ( Sample Instruction Event Register) availability in the > platform. This function in core-book3s access 'ppmu->flags'. If platform > speci

[PATCH] powerpc/perf: Fix crash with 'is_sier_available' when pmu is not set

2020-11-23 Thread Athira Rajeev
On systems without any platform specific PMU driver support registered or Generic Compat PMU support registered, running 'perf record' with —intr-regs will crash ( perf record -I ). The relevant portion from crash logs and Call Trace: Unable to handle kernel paging request for data at address 0