diff options
Diffstat (limited to 'include/linux/pm_runtime.h')
| -rw-r--r-- | include/linux/pm_runtime.h | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/include/linux/pm_runtime.h b/include/linux/pm_runtime.h index 6fa7cea25da9..2a5897a4afbc 100644 --- a/include/linux/pm_runtime.h +++ b/include/linux/pm_runtime.h | |||
| @@ -23,6 +23,18 @@ | |||
| 23 | usage_count */ | 23 | usage_count */ |
| 24 | #define RPM_AUTO 0x08 /* Use autosuspend_delay */ | 24 | #define RPM_AUTO 0x08 /* Use autosuspend_delay */ |
| 25 | 25 | ||
| 26 | #ifdef CONFIG_PM | ||
| 27 | extern int pm_generic_runtime_suspend(struct device *dev); | ||
| 28 | extern int pm_generic_runtime_resume(struct device *dev); | ||
| 29 | extern int pm_runtime_force_suspend(struct device *dev); | ||
| 30 | extern int pm_runtime_force_resume(struct device *dev); | ||
| 31 | #else | ||
| 32 | static inline int pm_generic_runtime_suspend(struct device *dev) { return 0; } | ||
| 33 | static inline int pm_generic_runtime_resume(struct device *dev) { return 0; } | ||
| 34 | static inline int pm_runtime_force_suspend(struct device *dev) { return 0; } | ||
| 35 | static inline int pm_runtime_force_resume(struct device *dev) { return 0; } | ||
| 36 | #endif | ||
| 37 | |||
| 26 | #ifdef CONFIG_PM_RUNTIME | 38 | #ifdef CONFIG_PM_RUNTIME |
| 27 | 39 | ||
| 28 | extern struct workqueue_struct *pm_wq; | 40 | extern struct workqueue_struct *pm_wq; |
| @@ -37,8 +49,6 @@ extern void pm_runtime_enable(struct device *dev); | |||
| 37 | extern void __pm_runtime_disable(struct device *dev, bool check_resume); | 49 | extern void __pm_runtime_disable(struct device *dev, bool check_resume); |
| 38 | extern void pm_runtime_allow(struct device *dev); | 50 | extern void pm_runtime_allow(struct device *dev); |
| 39 | extern void pm_runtime_forbid(struct device *dev); | 51 | extern void pm_runtime_forbid(struct device *dev); |
| 40 | extern int pm_generic_runtime_suspend(struct device *dev); | ||
| 41 | extern int pm_generic_runtime_resume(struct device *dev); | ||
| 42 | extern void pm_runtime_no_callbacks(struct device *dev); | 52 | extern void pm_runtime_no_callbacks(struct device *dev); |
| 43 | extern void pm_runtime_irq_safe(struct device *dev); | 53 | extern void pm_runtime_irq_safe(struct device *dev); |
| 44 | extern void __pm_runtime_use_autosuspend(struct device *dev, bool use); | 54 | extern void __pm_runtime_use_autosuspend(struct device *dev, bool use); |
| @@ -142,8 +152,6 @@ static inline bool pm_runtime_active(struct device *dev) { return true; } | |||
| 142 | static inline bool pm_runtime_status_suspended(struct device *dev) { return false; } | 152 | static inline bool pm_runtime_status_suspended(struct device *dev) { return false; } |
| 143 | static inline bool pm_runtime_enabled(struct device *dev) { return false; } | 153 | static inline bool pm_runtime_enabled(struct device *dev) { return false; } |
| 144 | 154 | ||
| 145 | static inline int pm_generic_runtime_suspend(struct device *dev) { return 0; } | ||
| 146 | static inline int pm_generic_runtime_resume(struct device *dev) { return 0; } | ||
| 147 | static inline void pm_runtime_no_callbacks(struct device *dev) {} | 155 | static inline void pm_runtime_no_callbacks(struct device *dev) {} |
| 148 | static inline void pm_runtime_irq_safe(struct device *dev) {} | 156 | static inline void pm_runtime_irq_safe(struct device *dev) {} |
| 149 | 157 | ||
