cpufreq: intel_pstate: Prioritize firmware-provided balance performance EPP
[linux-2.6-microblaze.git] / drivers / cpufreq / intel_pstate.c
index a534a1f..dd6d23e 100644 (file)
@@ -1691,13 +1691,6 @@ static void intel_pstate_update_epp_defaults(struct cpudata *cpudata)
 {
        cpudata->epp_default = intel_pstate_get_epp(cpudata, 0);
 
-       /*
-        * If this CPU gen doesn't call for change in balance_perf
-        * EPP return.
-        */
-       if (epp_values[EPP_INDEX_BALANCE_PERFORMANCE] == HWP_EPP_BALANCE_PERFORMANCE)
-               return;
-
        /*
         * If the EPP is set by firmware, which means that firmware enabled HWP
         * - Is equal or less than 0x80 (default balance_perf EPP)
@@ -1710,6 +1703,13 @@ static void intel_pstate_update_epp_defaults(struct cpudata *cpudata)
                return;
        }
 
+       /*
+        * If this CPU gen doesn't call for change in balance_perf
+        * EPP return.
+        */
+       if (epp_values[EPP_INDEX_BALANCE_PERFORMANCE] == HWP_EPP_BALANCE_PERFORMANCE)
+               return;
+
        /*
         * Use hard coded value per gen to update the balance_perf
         * and default EPP.