Re: [PATCH v2 3/8] core: platform: wakeup the parent before trying any driver operations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, May 25, 2015 at 01:36:43PM -0400, Alan Stern wrote:
> On Mon, 25 May 2015, Andy Shevchenko wrote:
> 
> > From: Heikki Krogerus <heikki.krogerus@xxxxxxxxxxxxxxx>
> > 
> > If the parent is still suspended when a driver probe,
> > remove or shutdown is attempted, the result may be a
> > failure.
> > 
> > For example, if the parent is a PCI MFD device that has been
> > suspended when we try to probe our device, any register
> > reads will return 0xffffffff.
> > 
> > To fix the problem, making sure the parent is always awake
> > before using driver probe, remove or shutdown.
> > 
> > Signed-off-by: Heikki Krogerus <heikki.krogerus@xxxxxxxxxxxxxxx>
> > Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>
> > ---
> >  drivers/base/platform.c | 21 ++++++++++++++++++++-
> 
> Why make the changes here rather than in dd.c?  Is there something 
> special about platform devices?
Right, also isn't there an assumption in runtime pm that
pm_runtime_get_sync() will wake up its parent. So why should platform core
do special handling here, if parent is set properly when creating this
device.

Or should the device probe "assume" that it is suspended and then do
pm_runtime_get_sync() which wakes its parent and ensures devices accesses are
okay

-- 
~Vinod
--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux