Bart Van Assche | bca6b06 | 2018-09-26 14:01:03 -0700 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
| 2 | |
| 3 | #ifndef _BLK_PM_H_ |
| 4 | #define _BLK_PM_H_ |
| 5 | |
| 6 | struct device; |
| 7 | struct request_queue; |
| 8 | |
| 9 | /* |
| 10 | * block layer runtime pm functions |
| 11 | */ |
| 12 | #ifdef CONFIG_PM |
| 13 | extern void blk_pm_runtime_init(struct request_queue *q, struct device *dev); |
| 14 | extern int blk_pre_runtime_suspend(struct request_queue *q); |
| 15 | extern void blk_post_runtime_suspend(struct request_queue *q, int err); |
| 16 | extern void blk_pre_runtime_resume(struct request_queue *q); |
| 17 | extern void blk_post_runtime_resume(struct request_queue *q, int err); |
| 18 | extern void blk_set_runtime_active(struct request_queue *q); |
| 19 | #else |
| 20 | static inline void blk_pm_runtime_init(struct request_queue *q, |
| 21 | struct device *dev) {} |
| 22 | #endif |
| 23 | |
| 24 | #endif /* _BLK_PM_H_ */ |