diff options
| author | Jim Wylder <jwylder@motorola.com> | 2014-05-12 17:52:31 -0500 |
|---|---|---|
| committer | Jim Wylder <jwylder@motorola.com> | 2014-05-12 17:52:31 -0500 |
| commit | 7be3e53f2d72ba5a931397c92c38a0d31f97c48f (patch) | |
| tree | baf5d4dfa53eaacc08ed207e29db2078aaafff22 /arch/arm/mach-omap2/omap-pm-noop.c | |
| parent | 0836c4b0758d484fcd328c3cd906fede829db2b4 (diff) | |
| download | olio-linux-3.10-7be3e53f2d72ba5a931397c92c38a0d31f97c48f.tar.xz olio-linux-3.10-7be3e53f2d72ba5a931397c92c38a0d31f97c48f.zip | |
Revert "IKXCLOCK-1044 arm: omap2: enable OMAP offmode"
This reverts commit 45c7061a5c2c4ac7e4e2f0c01e2db05e7c4a0b0a.
Diffstat (limited to 'arch/arm/mach-omap2/omap-pm-noop.c')
| -rw-r--r-- | arch/arm/mach-omap2/omap-pm-noop.c | 29 |
1 files changed, 25 insertions, 4 deletions
diff --git a/arch/arm/mach-omap2/omap-pm-noop.c b/arch/arm/mach-omap2/omap-pm-noop.c index aeb217bfab1..6a3be2bebdd 100644 --- a/arch/arm/mach-omap2/omap-pm-noop.c +++ b/arch/arm/mach-omap2/omap-pm-noop.c @@ -25,6 +25,7 @@ #include "omap_device.h" #include "omap-pm.h" +static bool off_mode_enabled; static int dummy_context_loss_counter; /* @@ -280,6 +281,28 @@ unsigned long omap_pm_cpu_get_freq(void) return 0; } +/** + * omap_pm_enable_off_mode - notify OMAP PM that off-mode is enabled + * + * Intended for use only by OMAP PM core code to notify this layer + * that off mode has been enabled. + */ +void omap_pm_enable_off_mode(void) +{ + off_mode_enabled = true; +} + +/** + * omap_pm_disable_off_mode - notify OMAP PM that off-mode is disabled + * + * Intended for use only by OMAP PM core code to notify this layer + * that off mode has been disabled. + */ +void omap_pm_disable_off_mode(void) +{ + off_mode_enabled = false; +} + /* * Device context loss tracking */ @@ -297,14 +320,12 @@ int omap_pm_get_dev_context_loss_count(struct device *dev) if (dev->pm_domain == &omap_device_pm_domain) { count = omap_device_get_context_loss_count(pdev); } else { - WARN_ONCE(omap_pm_get_off_mode(), - "omap_pm: using dummy context loss counter; device %s " - "should be converted to omap_device", + WARN_ONCE(off_mode_enabled, "omap_pm: using dummy context loss counter; device %s should be converted to omap_device", dev_name(dev)); count = dummy_context_loss_counter; - if (omap_pm_get_off_mode()) { + if (off_mode_enabled) { count++; /* * Context loss count has to be a non-negative value. |