|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/cpufreq-nforce2.c linux-3.10.0-229.el7/drivers/cpufreq/cpufreq-nforce2.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/cpufreq-nforce2.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/cpufreq-nforce2.c 2015-03-09 09:22:18.376023945 -0400
|
|
|
742bd8 |
@@ -270,7 +270,7 @@
|
|
|
742bd8 |
pr_debug("Old CPU frequency %d kHz, new %d kHz\n",
|
|
|
742bd8 |
freqs.old, freqs.new);
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
|
|
|
742bd8 |
/* Disable IRQs */
|
|
|
742bd8 |
/* local_irq_save(flags); */
|
|
|
742bd8 |
@@ -285,7 +285,7 @@
|
|
|
742bd8 |
/* Enable IRQs */
|
|
|
742bd8 |
/* local_irq_restore(flags); */
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, 0);
|
|
|
742bd8 |
|
|
|
742bd8 |
return 0;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
Binary files linux-3.10.0-229.el7.original/drivers/cpufreq/.cpufreq-nforce2.c.swp and linux-3.10.0-229.el7/drivers/cpufreq/.cpufreq-nforce2.c.swp differ
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/exynos5440-cpufreq.c linux-3.10.0-229.el7/drivers/cpufreq/exynos5440-cpufreq.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/exynos5440-cpufreq.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/exynos5440-cpufreq.c 2015-03-09 09:22:18.377023945 -0400
|
|
|
742bd8 |
@@ -238,7 +238,7 @@
|
|
|
742bd8 |
freqs.old = dvfs_info->cur_frequency;
|
|
|
742bd8 |
freqs.new = freq_table[index].frequency;
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
|
|
|
742bd8 |
/* Set the target frequency in all C0_3_PSTATE register */
|
|
|
742bd8 |
for_each_cpu(i, policy->cpus) {
|
|
|
742bd8 |
@@ -279,7 +279,7 @@
|
|
|
742bd8 |
dev_crit(dvfs_info->dev, "New frequency out of range\n");
|
|
|
742bd8 |
freqs.new = dvfs_info->cur_frequency;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, 0);
|
|
|
742bd8 |
|
|
|
742bd8 |
cpufreq_cpu_put(policy);
|
|
|
742bd8 |
mutex_unlock(&cpufreq_lock);
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/gx-suspmod.c linux-3.10.0-229.el7/drivers/cpufreq/gx-suspmod.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/gx-suspmod.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/gx-suspmod.c 2015-03-09 09:22:18.377023945 -0400
|
|
|
742bd8 |
@@ -265,7 +265,7 @@
|
|
|
742bd8 |
|
|
|
742bd8 |
freqs.new = new_khz;
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
local_irq_save(flags);
|
|
|
742bd8 |
|
|
|
742bd8 |
if (new_khz != stock_freq) {
|
|
|
742bd8 |
@@ -314,7 +314,7 @@
|
|
|
742bd8 |
|
|
|
742bd8 |
gx_params->pci_suscfg = suscfg;
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, 0);
|
|
|
742bd8 |
|
|
|
742bd8 |
pr_debug("suspend modulation w/ duration of ON:%d us, OFF:%d us\n",
|
|
|
742bd8 |
gx_params->on_duration * 32, gx_params->off_duration * 32);
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/integrator-cpufreq.c linux-3.10.0-229.el7/drivers/cpufreq/integrator-cpufreq.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/integrator-cpufreq.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/integrator-cpufreq.c 2015-03-09 09:22:18.377023945 -0400
|
|
|
742bd8 |
@@ -121,7 +121,7 @@
|
|
|
742bd8 |
return 0;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
|
|
|
742bd8 |
cm_osc = __raw_readl(CM_OSC);
|
|
|
742bd8 |
|
|
|
742bd8 |
@@ -142,7 +142,7 @@
|
|
|
742bd8 |
*/
|
|
|
742bd8 |
set_cpus_allowed(current, cpus_allowed);
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, 0);
|
|
|
742bd8 |
|
|
|
742bd8 |
return 0;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/longhaul.c linux-3.10.0-229.el7/drivers/cpufreq/longhaul.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/longhaul.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/longhaul.c 2015-03-09 09:22:18.377023945 -0400
|
|
|
742bd8 |
@@ -269,7 +269,7 @@
|
|
|
742bd8 |
freqs.old = calc_speed(longhaul_get_cpu_mult());
|
|
|
742bd8 |
freqs.new = speed;
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
|
|
|
742bd8 |
pr_debug("Setting to FSB:%dMHz Mult:%d.%dx (%s)\n",
|
|
|
742bd8 |
fsb, mult/10, mult%10, print_speed(speed/1000));
|
|
|
742bd8 |
@@ -386,7 +386,7 @@
|
|
|
742bd8 |
}
|
|
|
742bd8 |
}
|
|
|
742bd8 |
/* Report true CPU frequency */
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, 0);
|
|
|
742bd8 |
|
|
|
742bd8 |
if (!bm_timeout)
|
|
|
742bd8 |
printk(KERN_INFO PFX "Warning: Timeout while waiting for "
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/powernow-k6.c linux-3.10.0-229.el7/drivers/cpufreq/powernow-k6.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/powernow-k6.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/powernow-k6.c 2015-03-09 09:23:09.182024898 -0400
|
|
|
742bd8 |
@@ -83,7 +83,7 @@
|
|
|
742bd8 |
freqs.old = busfreq * powernow_k6_get_cpu_multiplier();
|
|
|
742bd8 |
freqs.new = busfreq * clock_ratio[best_i].driver_data;
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
|
|
|
742bd8 |
/* we now need to transform best_i to the BVC format, see AMD#23446 */
|
|
|
742bd8 |
|
|
|
742bd8 |
@@ -98,7 +98,7 @@
|
|
|
742bd8 |
msrval = POWERNOW_IOPORT + 0x0;
|
|
|
742bd8 |
wrmsr(MSR_K6_EPMR, msrval, 0); /* disable it again */
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, 0);
|
|
|
742bd8 |
|
|
|
742bd8 |
return;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/powernow-k7.c linux-3.10.0-229.el7/drivers/cpufreq/powernow-k7.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/powernow-k7.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/powernow-k7.c 2015-03-09 09:23:52.126025704 -0400
|
|
|
742bd8 |
@@ -269,7 +269,7 @@
|
|
|
742bd8 |
|
|
|
742bd8 |
freqs.new = powernow_table[index].frequency;
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
|
|
|
742bd8 |
/* Now do the magic poking into the MSRs. */
|
|
|
742bd8 |
|
|
|
742bd8 |
@@ -290,7 +290,7 @@
|
|
|
742bd8 |
if (have_a0 == 1)
|
|
|
742bd8 |
local_irq_enable();
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, 0);
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/sh-cpufreq.c linux-3.10.0-229.el7/drivers/cpufreq/sh-cpufreq.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/sh-cpufreq.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/sh-cpufreq.c 2015-03-09 09:22:18.378023945 -0400
|
|
|
742bd8 |
@@ -68,10 +68,10 @@
|
|
|
742bd8 |
freqs.new = (freq + 500) / 1000;
|
|
|
742bd8 |
freqs.flags = 0;
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
set_cpus_allowed_ptr(current, &cpus_allowed);
|
|
|
742bd8 |
clk_set_rate(cpuclk, freq);
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, 0);
|
|
|
742bd8 |
|
|
|
742bd8 |
dev_dbg(dev, "set frequency %lu Hz\n", freq);
|
|
|
742bd8 |
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/speedstep-centrino.c linux-3.10.0-229.el7/drivers/cpufreq/speedstep-centrino.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/speedstep-centrino.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/speedstep-centrino.c 2015-03-09 09:58:30.112064688 -0400
|
|
|
742bd8 |
@@ -345,7 +345,6 @@
|
|
|
742bd8 |
struct cpuinfo_x86 *cpu = &cpu_data(policy->cpu);
|
|
|
742bd8 |
unsigned freq;
|
|
|
742bd8 |
unsigned l, h;
|
|
|
742bd8 |
- int ret;
|
|
|
742bd8 |
int i;
|
|
|
742bd8 |
|
|
|
742bd8 |
/* Only Intel makes Enhanced Speedstep-capable CPUs */
|
|
|
742bd8 |
@@ -402,15 +401,8 @@
|
|
|
742bd8 |
|
|
|
742bd8 |
pr_debug("centrino_cpu_init: cur=%dkHz\n", policy->cur);
|
|
|
742bd8 |
|
|
|
742bd8 |
- ret = cpufreq_frequency_table_cpuinfo(policy,
|
|
|
742bd8 |
+ return cpufreq_table_validate_and_show(policy,
|
|
|
742bd8 |
per_cpu(centrino_model, policy->cpu)->op_points);
|
|
|
742bd8 |
- if (ret)
|
|
|
742bd8 |
- return (ret);
|
|
|
742bd8 |
-
|
|
|
742bd8 |
- cpufreq_frequency_table_get_attr(
|
|
|
742bd8 |
- per_cpu(centrino_model, policy->cpu)->op_points, policy->cpu);
|
|
|
742bd8 |
-
|
|
|
742bd8 |
- return 0;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
static int centrino_cpu_exit(struct cpufreq_policy *policy)
|
|
|
742bd8 |
@@ -428,19 +420,6 @@
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
/**
|
|
|
742bd8 |
- * centrino_verify - verifies a new CPUFreq policy
|
|
|
742bd8 |
- * @policy: new policy
|
|
|
742bd8 |
- *
|
|
|
742bd8 |
- * Limit must be within this model's frequency range at least one
|
|
|
742bd8 |
- * border included.
|
|
|
742bd8 |
- */
|
|
|
742bd8 |
-static int centrino_verify (struct cpufreq_policy *policy)
|
|
|
742bd8 |
-{
|
|
|
742bd8 |
- return cpufreq_frequency_table_verify(policy,
|
|
|
742bd8 |
- per_cpu(centrino_model, policy->cpu)->op_points);
|
|
|
742bd8 |
-}
|
|
|
742bd8 |
-
|
|
|
742bd8 |
-/**
|
|
|
742bd8 |
* centrino_setpolicy - set a new CPUFreq policy
|
|
|
742bd8 |
* @policy: new policy
|
|
|
742bd8 |
* @target_freq: the target frequency
|
|
|
742bd8 |
@@ -561,20 +540,15 @@
|
|
|
742bd8 |
return retval;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
-static struct freq_attr* centrino_attr[] = {
|
|
|
742bd8 |
- &cpufreq_freq_attr_scaling_available_freqs,
|
|
|
742bd8 |
- NULL,
|
|
|
742bd8 |
-};
|
|
|
742bd8 |
-
|
|
|
742bd8 |
static struct cpufreq_driver centrino_driver = {
|
|
|
742bd8 |
.name = "centrino", /* should be speedstep-centrino,
|
|
|
742bd8 |
but there's a 16 char limit */
|
|
|
742bd8 |
.init = centrino_cpu_init,
|
|
|
742bd8 |
.exit = centrino_cpu_exit,
|
|
|
742bd8 |
- .verify = centrino_verify,
|
|
|
742bd8 |
+ .verify = cpufreq_generic_frequency_table_verify,
|
|
|
742bd8 |
.target = centrino_target,
|
|
|
742bd8 |
.get = get_cur_freq,
|
|
|
742bd8 |
- .attr = centrino_attr,
|
|
|
742bd8 |
+ .attr = cpufreq_generic_attr,
|
|
|
742bd8 |
};
|
|
|
742bd8 |
|
|
|
742bd8 |
/*
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/speedstep-ich.c linux-3.10.0-229.el7/drivers/cpufreq/speedstep-ich.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/speedstep-ich.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/speedstep-ich.c 2015-03-09 09:58:30.113064688 -0400
|
|
|
742bd8 |
@@ -289,18 +289,6 @@
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
|
|
|
742bd8 |
-/**
|
|
|
742bd8 |
- * speedstep_verify - verifies a new CPUFreq policy
|
|
|
742bd8 |
- * @policy: new policy
|
|
|
742bd8 |
- *
|
|
|
742bd8 |
- * Limit must be within speedstep_low_freq and speedstep_high_freq, with
|
|
|
742bd8 |
- * at least one border included.
|
|
|
742bd8 |
- */
|
|
|
742bd8 |
-static int speedstep_verify(struct cpufreq_policy *policy)
|
|
|
742bd8 |
-{
|
|
|
742bd8 |
- return cpufreq_frequency_table_verify(policy, &speedstep_freqs[0]);
|
|
|
742bd8 |
-}
|
|
|
742bd8 |
-
|
|
|
742bd8 |
struct get_freqs {
|
|
|
742bd8 |
struct cpufreq_policy *policy;
|
|
|
742bd8 |
int ret;
|
|
|
742bd8 |
@@ -320,7 +308,6 @@
|
|
|
742bd8 |
|
|
|
742bd8 |
static int speedstep_cpu_init(struct cpufreq_policy *policy)
|
|
|
742bd8 |
{
|
|
|
742bd8 |
- int result;
|
|
|
742bd8 |
unsigned int policy_cpu, speed;
|
|
|
742bd8 |
struct get_freqs gf;
|
|
|
742bd8 |
|
|
|
742bd8 |
@@ -349,36 +336,18 @@
|
|
|
742bd8 |
/* cpuinfo and default policy values */
|
|
|
742bd8 |
policy->cur = speed;
|
|
|
742bd8 |
|
|
|
742bd8 |
- result = cpufreq_frequency_table_cpuinfo(policy, speedstep_freqs);
|
|
|
742bd8 |
- if (result)
|
|
|
742bd8 |
- return result;
|
|
|
742bd8 |
-
|
|
|
742bd8 |
- cpufreq_frequency_table_get_attr(speedstep_freqs, policy->cpu);
|
|
|
742bd8 |
-
|
|
|
742bd8 |
- return 0;
|
|
|
742bd8 |
+ return cpufreq_table_validate_and_show(policy, speedstep_freqs);
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
|
|
|
742bd8 |
-static int speedstep_cpu_exit(struct cpufreq_policy *policy)
|
|
|
742bd8 |
-{
|
|
|
742bd8 |
- cpufreq_frequency_table_put_attr(policy->cpu);
|
|
|
742bd8 |
- return 0;
|
|
|
742bd8 |
-}
|
|
|
742bd8 |
-
|
|
|
742bd8 |
-static struct freq_attr *speedstep_attr[] = {
|
|
|
742bd8 |
- &cpufreq_freq_attr_scaling_available_freqs,
|
|
|
742bd8 |
- NULL,
|
|
|
742bd8 |
-};
|
|
|
742bd8 |
-
|
|
|
742bd8 |
-
|
|
|
742bd8 |
static struct cpufreq_driver speedstep_driver = {
|
|
|
742bd8 |
.name = "speedstep-ich",
|
|
|
742bd8 |
- .verify = speedstep_verify,
|
|
|
742bd8 |
+ .verify = cpufreq_generic_frequency_table_verify,
|
|
|
742bd8 |
.target = speedstep_target,
|
|
|
742bd8 |
.init = speedstep_cpu_init,
|
|
|
742bd8 |
- .exit = speedstep_cpu_exit,
|
|
|
742bd8 |
+ .exit = cpufreq_generic_exit,
|
|
|
742bd8 |
.get = speedstep_get,
|
|
|
742bd8 |
- .attr = speedstep_attr,
|
|
|
742bd8 |
+ .attr = cpufreq_generic_attr,
|
|
|
742bd8 |
};
|
|
|
742bd8 |
|
|
|
742bd8 |
static const struct x86_cpu_id ss_smi_ids[] = {
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/speedstep-smi.c linux-3.10.0-229.el7/drivers/cpufreq/speedstep-smi.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/speedstep-smi.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/speedstep-smi.c 2015-03-09 09:58:30.113064688 -0400
|
|
|
742bd8 |
@@ -264,19 +264,6 @@
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
|
|
|
742bd8 |
-/**
|
|
|
742bd8 |
- * speedstep_verify - verifies a new CPUFreq policy
|
|
|
742bd8 |
- * @policy: new policy
|
|
|
742bd8 |
- *
|
|
|
742bd8 |
- * Limit must be within speedstep_low_freq and speedstep_high_freq, with
|
|
|
742bd8 |
- * at least one border included.
|
|
|
742bd8 |
- */
|
|
|
742bd8 |
-static int speedstep_verify(struct cpufreq_policy *policy)
|
|
|
742bd8 |
-{
|
|
|
742bd8 |
- return cpufreq_frequency_table_verify(policy, &speedstep_freqs[0]);
|
|
|
742bd8 |
-}
|
|
|
742bd8 |
-
|
|
|
742bd8 |
-
|
|
|
742bd8 |
static int speedstep_cpu_init(struct cpufreq_policy *policy)
|
|
|
742bd8 |
{
|
|
|
742bd8 |
int result;
|
|
|
742bd8 |
@@ -329,19 +316,7 @@
|
|
|
742bd8 |
policy->cpuinfo.transition_latency = CPUFREQ_ETERNAL;
|
|
|
742bd8 |
policy->cur = speed;
|
|
|
742bd8 |
|
|
|
742bd8 |
- result = cpufreq_frequency_table_cpuinfo(policy, speedstep_freqs);
|
|
|
742bd8 |
- if (result)
|
|
|
742bd8 |
- return result;
|
|
|
742bd8 |
-
|
|
|
742bd8 |
- cpufreq_frequency_table_get_attr(speedstep_freqs, policy->cpu);
|
|
|
742bd8 |
-
|
|
|
742bd8 |
- return 0;
|
|
|
742bd8 |
-}
|
|
|
742bd8 |
-
|
|
|
742bd8 |
-static int speedstep_cpu_exit(struct cpufreq_policy *policy)
|
|
|
742bd8 |
-{
|
|
|
742bd8 |
- cpufreq_frequency_table_put_attr(policy->cpu);
|
|
|
742bd8 |
- return 0;
|
|
|
742bd8 |
+ return cpufreq_table_validate_and_show(policy, speedstep_freqs);
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
static unsigned int speedstep_get(unsigned int cpu)
|
|
|
742bd8 |
@@ -362,20 +337,15 @@
|
|
|
742bd8 |
return result;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
-static struct freq_attr *speedstep_attr[] = {
|
|
|
742bd8 |
- &cpufreq_freq_attr_scaling_available_freqs,
|
|
|
742bd8 |
- NULL,
|
|
|
742bd8 |
-};
|
|
|
742bd8 |
-
|
|
|
742bd8 |
static struct cpufreq_driver speedstep_driver = {
|
|
|
742bd8 |
.name = "speedstep-smi",
|
|
|
742bd8 |
- .verify = speedstep_verify,
|
|
|
742bd8 |
+ .verify = cpufreq_generic_frequency_table_verify,
|
|
|
742bd8 |
.target = speedstep_target,
|
|
|
742bd8 |
.init = speedstep_cpu_init,
|
|
|
742bd8 |
- .exit = speedstep_cpu_exit,
|
|
|
742bd8 |
+ .exit = cpufreq_generic_exit,
|
|
|
742bd8 |
.get = speedstep_get,
|
|
|
742bd8 |
.resume = speedstep_resume,
|
|
|
742bd8 |
- .attr = speedstep_attr,
|
|
|
742bd8 |
+ .attr = cpufreq_generic_attr,
|
|
|
742bd8 |
};
|
|
|
742bd8 |
|
|
|
742bd8 |
static const struct x86_cpu_id ss_smi_ids[] = {
|
|
|
742bd8 |
diff -urN linux-3.10.0-229.el7.original/drivers/cpufreq/unicore2-cpufreq.c linux-3.10.0-229.el7/drivers/cpufreq/unicore2-cpufreq.c
|
|
|
742bd8 |
--- linux-3.10.0-229.el7.original/drivers/cpufreq/unicore2-cpufreq.c 2015-01-29 18:15:53.000000000 -0500
|
|
|
742bd8 |
+++ linux-3.10.0-229.el7/drivers/cpufreq/unicore2-cpufreq.c 2015-03-09 09:24:33.053026472 -0400
|
|
|
742bd8 |
@@ -50,14 +50,14 @@
|
|
|
742bd8 |
struct cpufreq_freqs freqs;
|
|
|
742bd8 |
struct clk *mclk = clk_get(NULL, "MAIN_CLK");
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_begin(policy, &freqs);
|
|
|
742bd8 |
|
|
|
742bd8 |
if (!clk_set_rate(mclk, target_freq * 1000)) {
|
|
|
742bd8 |
freqs.old = cur;
|
|
|
742bd8 |
freqs.new = target_freq;
|
|
|
742bd8 |
}
|
|
|
742bd8 |
|
|
|
742bd8 |
- cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE);
|
|
|
742bd8 |
+ cpufreq_freq_transition_end(policy, &freqs, ret);
|
|
|
742bd8 |
|
|
|
742bd8 |
return 0;
|
|
|
742bd8 |
}
|