Skip to content

Commit a6b0373

Browse files
committed
Merge tag 'pm-5.4-final' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull power management regression fix from Rafael Wysocki: "Fix problems with switching cpufreq drivers on some x86 systems with ACPI (and with changing the operation modes of the intel_pstate driver on those systems) introduced by recent changes related to the management of frequency limits in cpufreq" * tag 'pm-5.4-final' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: PM: QoS: Invalidate frequency QoS requests after removal
2 parents 5d867ab + 05ff1ba commit a6b0373

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

kernel/power/qos.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -814,14 +814,20 @@ EXPORT_SYMBOL_GPL(freq_qos_update_request);
814814
*/
815815
int freq_qos_remove_request(struct freq_qos_request *req)
816816
{
817+
int ret;
818+
817819
if (!req)
818820
return -EINVAL;
819821

820822
if (WARN(!freq_qos_request_active(req),
821823
"%s() called for unknown object\n", __func__))
822824
return -EINVAL;
823825

824-
return freq_qos_apply(req, PM_QOS_REMOVE_REQ, PM_QOS_DEFAULT_VALUE);
826+
ret = freq_qos_apply(req, PM_QOS_REMOVE_REQ, PM_QOS_DEFAULT_VALUE);
827+
req->qos = NULL;
828+
req->type = 0;
829+
830+
return ret;
825831
}
826832
EXPORT_SYMBOL_GPL(freq_qos_remove_request);
827833

0 commit comments

Comments
 (0)