summaryrefslogtreecommitdiff
path: root/drivers/pinctrl
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2018-08-30 19:27:43 +0300
committerLinus Walleij <linus.walleij@linaro.org>2018-08-31 12:25:23 +0300
commit6d7c05faaf01a082fa2458ff615d8373d876905c (patch)
tree24849a2eca930935f70f8545d039fd9b4edb4d03 /drivers/pinctrl
parent0c03e92e7d665b01afbddf057b2cc07587ffc2cc (diff)
downloadlinux-6d7c05faaf01a082fa2458ff615d8373d876905c.tar.xz
pinctrl: intel: Introduce common macro for PM operations
This common macro will simplify the code of pin control drivers for Intel SoCs. Suggested-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl')
-rw-r--r--drivers/pinctrl/intel/pinctrl-intel.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/pinctrl/intel/pinctrl-intel.h b/drivers/pinctrl/intel/pinctrl-intel.h
index 83a29e002f89..acb723bbad87 100644
--- a/drivers/pinctrl/intel/pinctrl-intel.h
+++ b/drivers/pinctrl/intel/pinctrl-intel.h
@@ -181,4 +181,9 @@ int intel_pinctrl_suspend(struct device *dev);
int intel_pinctrl_resume(struct device *dev);
#endif
+#define INTEL_PINCTRL_PM_OPS(_name) \
+const struct dev_pm_ops _name = { \
+ SET_LATE_SYSTEM_SLEEP_PM_OPS(intel_pinctrl_suspend, intel_pinctrl_resume) \
+}
+
#endif /* PINCTRL_INTEL_H */