cpufreq: intel_pstate: Drop redundant intel_pstate_get_hwp_cap() call
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 10 Dec 2021 16:12:18 +0000 (17:12 +0100)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 17 Dec 2021 15:26:50 +0000 (16:26 +0100)
commit458b03f81afbb27143c45d47c2d8f418b2ba2407
tree8ee24d7639c3d651ee5b50bf46bc3aaa9c09ce22
parent2585cf9dfaaddf00b069673f27bb3f8530e2039c
cpufreq: intel_pstate: Drop redundant intel_pstate_get_hwp_cap() call

It is not necessary to call intel_pstate_get_hwp_cap() from
intel_pstate_update_perf_limits(), because it gets called from
intel_pstate_verify_cpu_policy() which is either invoked directly
right before intel_pstate_update_perf_limits(), in
intel_cpufreq_verify_policy() in the passive mode, or called
from driver callbacks in a sequence that causes it to be followed
by an immediate intel_pstate_update_perf_limits().

Namely, in the active mode intel_cpufreq_verify_policy() is called
by intel_pstate_verify_policy() which is the ->verify() callback
routine of intel_pstate and gets called by the cpufreq core right
before intel_pstate_set_policy(), which is the driver's ->setoplicy()
callback routine, where intel_pstate_update_perf_limits() is called.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/cpufreq/intel_pstate.c