Skip to content

Commit 2a9a86d

Browse files
Tero Kristorafaeljw
authored andcommitted
PM / QoS: Fix default runtime_pm device resume latency
The recent change to the PM QoS framework to introduce a proper no constraint value overlooked to handle the devices which don't implement PM QoS OPS. Runtime PM is one of the more severely impacted subsystems, failing every attempt to runtime suspend a device. This leads into some nasty second level issues like probe failures and increased power consumption among other things. Fix this by adding a proper return value for devices that don't implement PM QoS. Fixes: 0cc2b4e (PM / QoS: Fix device resume latency PM QoS) Signed-off-by: Tero Kristo <[email protected]> Cc: All applicable <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
1 parent 0b07194 commit 2a9a86d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

include/linux/pm_qos.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,8 @@ static inline s32 dev_pm_qos_requested_flags(struct device *dev)
175175
static inline s32 dev_pm_qos_raw_read_value(struct device *dev)
176176
{
177177
return IS_ERR_OR_NULL(dev->power.qos) ?
178-
0 : pm_qos_read_value(&dev->power.qos->resume_latency);
178+
PM_QOS_RESUME_LATENCY_NO_CONSTRAINT :
179+
pm_qos_read_value(&dev->power.qos->resume_latency);
179180
}
180181
#else
181182
static inline enum pm_qos_flags_status __dev_pm_qos_flags(struct device *dev,

0 commit comments

Comments
 (0)