static int ux500_pd_amba_resume_noirq(struct device *dev) { struct pm_runtime_data *prd = __to_prd(dev); int (*callback)(struct device *) = NULL; int ret = 0; bool is_suspended = pm_runtime_status_suspended(dev); dev_vdbg(dev, "%s()\n", __func__); /* * Do not bypass AMBA bus pm functions by calling generic * pm directly. A future fix could be to implement a * "pm_bus_generic_*" API which we can use instead. */ if (dev->bus && dev->bus->pm) callback = dev->bus->pm->resume_noirq; if (callback) ret = callback(dev); else ret = pm_generic_resume_noirq(dev); if (!ret && !is_suspended) ux500_pd_enable(prd); return ret; }
static int _od_resume_noirq(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); struct omap_device *od = to_omap_device(pdev); if (od->flags & OMAP_DEVICE_NO_IDLE_ON_SUSPEND) return pm_generic_resume_noirq(dev); if ((od->flags & OMAP_DEVICE_SUSPENDED) && !pm_runtime_status_suspended(dev)) { od->flags &= ~OMAP_DEVICE_SUSPENDED; omap_device_enable(pdev); pm_generic_runtime_resume(dev); } return pm_generic_resume_noirq(dev); }
static int _od_resume_noirq(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); struct omap_device *od = to_omap_device(pdev); if (od->flags & OMAP_DEVICE_SUSPENDED) { od->flags &= ~OMAP_DEVICE_SUSPENDED; omap_device_enable(pdev); pm_generic_runtime_resume(dev); } return pm_generic_resume_noirq(dev); }
static int _od_resume_noirq(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); struct omap_device *od = to_omap_device(pdev); if (od->flags & OMAP_DEVICE_SUSPENDED) { od->flags &= ~OMAP_DEVICE_SUSPENDED; omap_device_enable(pdev); /* * XXX: we run before core runtime pm has resumed itself. At * this point in time, we just restore the runtime pm state and * considering symmetric operations in resume, we donot expect * to fail. If we failed, something changed in core runtime_pm * framework OR some device driver messed things up, hence, WARN */ WARN(pm_runtime_set_active(dev), "Could not set %s runtime state active\n", dev_name(dev)); pm_generic_runtime_resume(dev); } return pm_generic_resume_noirq(dev); }