Kevin,
[...]
> > -#endif
> > - default:
> > - continue;
> > - }
> > + if (!bank->suspend_support)
> > + return 0;
>
> Rather than check the flag here in every suspend, don't add a suspend
> method in dev_pm_ops for banks that don't have the wkup_* registers.
While trying to implement this comment I am facing issues:
struct device_driver {
...
const struct dev_pm_ops *pm;
...
};
Since *pm is constant we can not assign pm->suspend/resume dynamically.
Also, I am not sure if it is permissible to have following code in probe:
... omap_gpio_probe(...)
{
...
if (bank->regs->wkup_status) {
pdrv->driver.pm->suspend = omap_gpio_suspend;
pdrv->driver.pm->resume = omap_gpio_resume;
}
...
[...]
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html