Re: [PATCH v1 1/1] drivers: base: Fix NULL pointer exception in __platform_driver_probe()

2020-04-29 Thread Greg KH
On Tue, Apr 28, 2020 at 12:24:05PM -0700, Kuppuswamy, Sathyanarayanan wrote:
> Hi Greg,
> 
> On 4/28/20 12:03 PM, Greg KH wrote:
> > On Wed, Apr 08, 2020 at 02:40:03PM -0700, 
> > sathyanarayanan.kuppusw...@linux.intel.com wrote:
> > > From: Kuppuswamy Sathyanarayanan 
> > > 
> > > 
> > > If platform bus driver registration is failed then,
> > 
> > How is your platform driver registration failing?  What caused that, is
> > it an in-kernel problem with something?  How can it be triggered?
> In my case I triggered it intentionally. For one of our internal
> project we want to strictly control the number of drivers/devices
> allowed in kernel. To verify the feasibility of adding above support,
> I intentionally failed few bus drivers and checked the behavior. In
> one of those tests I hence came across the mentioned issue.
> 
> In any case, platform bus driver registration failure is a valid case
> right ? Any issue we notice when this happens needs to be handled right?

That's fine, I just need to know if this is something that someone can
actually trigger today, and needs to be fixed up, or if this is just a
"hardening for when a driver author does something foolish" type of a
case.

It seems to be the "don't do foolish things" to me, so it's a much lower
priority as we can always fix foolish drivers because we have the source
to them :)

thanks,

greg k-h


Re: [PATCH v1 1/1] drivers: base: Fix NULL pointer exception in __platform_driver_probe()

2020-04-28 Thread Kuppuswamy, Sathyanarayanan

Hi Greg,

On 4/28/20 12:03 PM, Greg KH wrote:

On Wed, Apr 08, 2020 at 02:40:03PM -0700, 
sathyanarayanan.kuppusw...@linux.intel.com wrote:

From: Kuppuswamy Sathyanarayanan 

If platform bus driver registration is failed then,


How is your platform driver registration failing?  What caused that, is
it an in-kernel problem with something?  How can it be triggered?

In my case I triggered it intentionally. For one of our internal
project we want to strictly control the number of drivers/devices
allowed in kernel. To verify the feasibility of adding above support,
I intentionally failed few bus drivers and checked the behavior. In
one of those tests I hence came across the mentioned issue.

In any case, platform bus driver registration failure is a valid case
right ? Any issue we notice when this happens needs to be handled right?


thanks,

greg k-h



Re: [PATCH v1 1/1] drivers: base: Fix NULL pointer exception in __platform_driver_probe()

2020-04-28 Thread Greg KH
On Wed, Apr 08, 2020 at 02:40:03PM -0700, 
sathyanarayanan.kuppusw...@linux.intel.com wrote:
> From: Kuppuswamy Sathyanarayanan 
> 
> If platform bus driver registration is failed then,

How is your platform driver registration failing?  What caused that, is
it an in-kernel problem with something?  How can it be triggered?

thanks,

greg k-h