lkml.org 
[lkml]   [2012]   [Jan]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH 2/11] input: RMI4 core bus and sensor drivers.
On 01/01/2012 10:38 PM, Shubhrajyoti wrote:
> Hi Christopher,
>
> On Thursday 22 December 2011 07:39 AM, Christopher Heiny wrote:
>> Signed-off-by: Christopher Heiny<cheiny@synaptics.com>
>>
[snip]

>> +#ifdef CONFIG_PM
>> +static int rmi_bus_suspend(struct device *dev)
>> +{
>> +#ifdef GENERIC_SUBSYS_PM_OPS
>> + const struct dev_pm_ops *pm = dev->driver ? dev->driver->pm : NULL;
>> +
>> + if (pm&& pm->suspend)
>> + return pm->suspend(dev);
> If driver-pm- suspend is not there should you not fall back to . suspend ?

You're thinking of dev->driver->suspend here, right? If so, that sounds
good to me.


>
>> +#endif
>> +
>> + return 0;
>> +}
>> +
>> +static int rmi_bus_resume(struct device *dev)
>> +{
>> +#ifdef GENERIC_SUBSYS_PM_OPS
>> + const struct dev_pm_ops *pm = dev->driver ? dev->driver->pm : NULL;
>> +
>> + if (pm&& pm->resume)
>> + return pm->resume(dev);
> same here?
>> +#endif
>> +
>> + return 0;
>> +}
>> +#endif


\
 
 \ /
  Last update: 2012-01-05 21:51    [W:0.222 / U:0.936 seconds]
©2003-2014 Jasper Spaans. Advertise on this site