summaryrefslogtreecommitdiff
path: root/drivers/mfd
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2010-11-26 17:19:34 +0000
committerSamuel Ortiz <sameo@linux.intel.com>2011-01-14 12:37:42 +0100
commit4c90aa94f6b3e33f57faaf19ef9819195dff61d3 (patch)
tree14eea47a6ca27e03d16514fe397a1cd9fbf4a901 /drivers/mfd
parentd7b9f3220fd97522559316cdd72778f42ac4de04 (diff)
downloadlinux-3.10-4c90aa94f6b3e33f57faaf19ef9819195dff61d3.tar.gz
linux-3.10-4c90aa94f6b3e33f57faaf19ef9819195dff61d3.tar.bz2
linux-3.10-4c90aa94f6b3e33f57faaf19ef9819195dff61d3.zip
mfd: Provide pm_runtime_no_callbacks flag in cell data
Allow MFD cells to have pm_runtime_no_callbacks() called on them during registration. This causes the runtime PM framework to ignore them, allowing use of runtime PM to suspend the device as a whole even if not all drivers for the MFD can usefully implement runtime PM. For example, RTCs are likely to run continuously regardless of the power state of the system. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/mfd')
-rw-r--r--drivers/mfd/mfd-core.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/mfd/mfd-core.c b/drivers/mfd/mfd-core.c
index ec99f681e77..d83ad0f141a 100644
--- a/drivers/mfd/mfd-core.c
+++ b/drivers/mfd/mfd-core.c
@@ -15,6 +15,7 @@
#include <linux/platform_device.h>
#include <linux/acpi.h>
#include <linux/mfd/core.h>
+#include <linux/pm_runtime.h>
#include <linux/slab.h>
static int mfd_add_device(struct device *parent, int id,
@@ -82,6 +83,9 @@ static int mfd_add_device(struct device *parent, int id,
if (ret)
goto fail_res;
+ if (cell->pm_runtime_no_callbacks)
+ pm_runtime_no_callbacks(&pdev->dev);
+
kfree(res);
return 0;