Merge tag 'pm-4.18-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull power management updates from Rafael Wysocki: "These are mostly fixes, including some fixes for changes made during the recent merge window and some "stable" material, plus some minor extensions of the turbostat utility. Specifics: - Fix the PM core to avoid introducing a runtime PM usage counter imbalance when adding device links during driver probe (Rafael Wysocki). - Fix the operating performance points (OPP) framework to ensure that the regulator voltage is always updated as appropriate when updating clock rates (Waldemar Rymarkiewicz). - Fix the intel_pstate driver to use correct max/min limits for cores with differing maximum frequences (Srinivas Pandruvada). - Fix a typo in the intel_pstate driver documentation (Rafael Wysocki). - Fix two issues with the recently added Kryo cpufreq driver (Ilia Lin). - Fix two recent regressions and some other minor issues in the turbostat utility and extend it to provide some more diagnostic information (Len Brown, Nathan Ciobanu)" * tag 'pm-4.18-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: Documentation: intel_pstate: Fix typo tools/power turbostat: version 18.06.20 tools/power turbostat: add the missing command line switches tools/power turbostat: add single character tokens to help tools/power turbostat: alphabetize the help output tools/power turbostat: fix segfault on 'no node' machines tools/power turbostat: add optional APIC X2APIC columns tools/power turbostat: decode cpuid.1.HT tools/power turbostat: fix show/hide issues resulting from mis-merge PM / OPP: Update voltage in case freq == old_freq cpufreq: intel_pstate: Fix scaling max/min limits with Turbo 3.0 cpufreq: kryo: Add module remove and exit cpufreq: kryo: Fix possible error code dereference PM / core: Fix supplier device runtime PM usage counter imbalance
This commit is contained in:
@@ -236,6 +236,13 @@ struct device_link *device_link_add(struct device *consumer,
|
||||
link->rpm_active = true;
|
||||
}
|
||||
pm_runtime_new_link(consumer);
|
||||
/*
|
||||
* If the link is being added by the consumer driver at probe
|
||||
* time, balance the decrementation of the supplier's runtime PM
|
||||
* usage counter after consumer probe in driver_probe_device().
|
||||
*/
|
||||
if (consumer->links.status == DL_DEV_PROBING)
|
||||
pm_runtime_get_noresume(supplier);
|
||||
}
|
||||
get_device(supplier);
|
||||
link->supplier = supplier;
|
||||
@@ -255,12 +262,12 @@ struct device_link *device_link_add(struct device *consumer,
|
||||
switch (consumer->links.status) {
|
||||
case DL_DEV_PROBING:
|
||||
/*
|
||||
* Balance the decrementation of the supplier's
|
||||
* runtime PM usage counter after consumer probe
|
||||
* in driver_probe_device().
|
||||
* Some callers expect the link creation during
|
||||
* consumer driver probe to resume the supplier
|
||||
* even without DL_FLAG_RPM_ACTIVE.
|
||||
*/
|
||||
if (flags & DL_FLAG_PM_RUNTIME)
|
||||
pm_runtime_get_sync(supplier);
|
||||
pm_runtime_resume(supplier);
|
||||
|
||||
link->status = DL_STATE_CONSUMER_PROBE;
|
||||
break;
|
||||
|
Reference in New Issue
Block a user