1BLK_PM_RUNTIME_INIT(9) Block Devices BLK_PM_RUNTIME_INIT(9)
2
3
4
6 blk_pm_runtime_init - Block layer runtime PM initialization routine
7
9 void blk_pm_runtime_init(struct request_queue * q,
10 struct device * dev);
11
13 q
14 the queue of the device
15
16 dev
17 the device the queue belongs to
18
20 Initialize runtime-PM-related fields for q and start auto suspend for
21 dev. Drivers that want to take advantage of request-based runtime PM
22 should call this function after dev has been initialized, and its
23 request queue q has been allocated, and runtime PM for it can not
24 happen yet(either due to disabled/forbidden or its usage_count > 0). In
25 most cases, driver should call this function before any I/O has taken
26 place.
27
28 This function takes care of setting up using auto suspend for the
29 device, the autosuspend delay is set to -1 to make runtime suspend
30 impossible until an updated value is either set by user or by driver.
31 Drivers do not need to touch other autosuspend settings.
32
33 The block layer runtime PM is request based, so only works for drivers
34 that use request as their IO unit instead of those directly use bio's.
35
37Kernel Hackers Manual 3.10 June 2019 BLK_PM_RUNTIME_INIT(9)