Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-28 Thread Rafael J. Wysocki
On Thursday, January 28, 2016 07:45:53 AM Viresh Kumar wrote: > On 27-01-16, 23:54, Rafael J. Wysocki wrote: > > So I've applied this, but I'm not sure it is sufficient yet. > > At least, this solves the crash Juri was hitting on a multi cluster > box. Yes, it makes the crash go away in his setup

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-28 Thread Juri Lelli
On 28/01/16 07:45, Viresh Kumar wrote: > On 27-01-16, 23:54, Rafael J. Wysocki wrote: > > So I've applied this, but I'm not sure it is sufficient yet. > > At least, this solves the crash Juri was hitting on a multi cluster > box. > > > Have you double checked whether or not stuff cannot be reorde

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-27 Thread Viresh Kumar
On 27-01-16, 23:54, Rafael J. Wysocki wrote: > So I've applied this, but I'm not sure it is sufficient yet. At least, this solves the crash Juri was hitting on a multi cluster box. > Have you double checked whether or not stuff cannot be reordered by > the CPU and/or the compiler and no additiona

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-27 Thread Rafael J. Wysocki
On Monday, January 25, 2016 10:33:46 PM Viresh Kumar wrote: > There is a little race discovered by Juri, where we are able to: > - create and read a sysfs file before policy->governor_data is being set > to a non NULL value. > OR > - set policy->governor_data to NULL, and reading a file before

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-27 Thread Juri Lelli
On 26/01/16 23:49, Rafael J. Wysocki wrote: > On Tuesday, January 26, 2016 06:01:19 PM Juri Lelli wrote: > > On 26/01/16 09:57, Juri Lelli wrote: > > > Hi Viresh, > > > > > > On 25/01/16 22:33, Viresh Kumar wrote: > > > > There is a little race discovered by Juri, where we are able to: > > > > - c

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-27 Thread Juri Lelli
On 27/01/16 08:40, Viresh Kumar wrote: > On 26-01-16, 09:57, Juri Lelli wrote: > > This patch fixes the crash I was seeing. > > > > Tested-by: Juri Lelli > > Thanks. > > > However, it exposes another problem (running the concurrent lockdep test > > It exposes? How can this patch expose the bel

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-26 Thread Viresh Kumar
On 26-01-16, 18:01, Juri Lelli wrote: > So, this goes away with your patch (that I forward ported) and a small > additional fix on top of that. I pushed all that here (so that it is > also tested by 0-day): I am surprised :) > git://linux-arm.org/linux-jl.git fixes/cpufreq/policy_exit_race > >

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-26 Thread Viresh Kumar
On 26-01-16, 09:57, Juri Lelli wrote: > This patch fixes the crash I was seeing. > > Tested-by: Juri Lelli Thanks. > However, it exposes another problem (running the concurrent lockdep test It exposes? How can this patch expose the below crash. AFAIR, you reported that you are getting below cr

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-26 Thread Rafael J. Wysocki
On Tuesday, January 26, 2016 06:01:19 PM Juri Lelli wrote: > On 26/01/16 09:57, Juri Lelli wrote: > > Hi Viresh, > > > > On 25/01/16 22:33, Viresh Kumar wrote: > > > There is a little race discovered by Juri, where we are able to: > > > - create and read a sysfs file before policy->governor_data i

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-26 Thread Juri Lelli
On 26/01/16 09:57, Juri Lelli wrote: > Hi Viresh, > > On 25/01/16 22:33, Viresh Kumar wrote: > > There is a little race discovered by Juri, where we are able to: > > - create and read a sysfs file before policy->governor_data is being set > > to a non NULL value. > > OR > > - set policy->gover

Re: [PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-26 Thread Juri Lelli
Hi Viresh, On 25/01/16 22:33, Viresh Kumar wrote: > There is a little race discovered by Juri, where we are able to: > - create and read a sysfs file before policy->governor_data is being set > to a non NULL value. > OR > - set policy->governor_data to NULL, and reading a file before being >

[PATCH] cpufreq: Fix NULL reference crash while accessing policy->governor_data

2016-01-25 Thread Viresh Kumar
There is a little race discovered by Juri, where we are able to: - create and read a sysfs file before policy->governor_data is being set to a non NULL value. OR - set policy->governor_data to NULL, and reading a file before being destroyed. And so such a crash is reported: Unable to handle