Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0b443ead authored by Viresh Kumar's avatar Viresh Kumar Committed by Rafael J. Wysocki
Browse files

cpufreq: remove unused notifier: CPUFREQ_{SUSPENDCHANGE|RESUMECHANGE}



Two cpufreq notifiers CPUFREQ_RESUMECHANGE and CPUFREQ_SUSPENDCHANGE have
not been used for some time, so remove them to clean up code a bit.

Signed-off-by: default avatarViresh Kumar <viresh.kumar@linaro.org>
Reviewed-by: default avatarSrivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
[rjw: Changelog]
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent 9832235f
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -92,7 +92,3 @@ values:
cpu	- number of the affected CPU
old	- old frequency
new	- new frequency

If the cpufreq core detects the frequency has changed while the system
was suspended, these notifiers are called with CPUFREQ_RESUMECHANGE as
second argument.
+1 −2
Original line number Diff line number Diff line
@@ -674,8 +674,7 @@ static int cpufreq_callback(struct notifier_block *nb,
	}

	if ((val == CPUFREQ_PRECHANGE  && freq->old < freq->new) ||
	    (val == CPUFREQ_POSTCHANGE && freq->old > freq->new) ||
	    (val == CPUFREQ_RESUMECHANGE || val == CPUFREQ_SUSPENDCHANGE)) {
	    (val == CPUFREQ_POSTCHANGE && freq->old > freq->new)) {
		loops_per_jiffy = cpufreq_scale(global_l_p_j_ref,
						global_l_p_j_ref_freq,
						freq->new);
+1 −1
Original line number Diff line number Diff line
@@ -166,7 +166,7 @@ static int twd_cpufreq_transition(struct notifier_block *nb,
	 * frequency.  The timer is local to a cpu, so cross-call to the
	 * changing cpu.
	 */
	if (state == CPUFREQ_POSTCHANGE || state == CPUFREQ_RESUMECHANGE)
	if (state == CPUFREQ_POSTCHANGE)
		smp_call_function_single(freqs->cpu, twd_update_frequency,
			NULL, 1);

+0 −3
Original line number Diff line number Diff line
@@ -885,9 +885,6 @@ static int viper_cpufreq_notifier(struct notifier_block *nb,
			viper_set_core_cpu_voltage(freq->new, 0);
		}
		break;
	case CPUFREQ_RESUMECHANGE:
		viper_set_core_cpu_voltage(freq->new, 0);
		break;
	default:
		/* ignore */
		break;
+1 −2
Original line number Diff line number Diff line
@@ -1121,8 +1121,7 @@ oprof_cpufreq_notify(struct notifier_block *nb, unsigned long val, void *data)
	int ret = 0;
	struct cpufreq_freqs *frq = data;
	if ((val == CPUFREQ_PRECHANGE && frq->old < frq->new) ||
	    (val == CPUFREQ_POSTCHANGE && frq->old > frq->new) ||
	    (val == CPUFREQ_RESUMECHANGE || val == CPUFREQ_SUSPENDCHANGE))
	    (val == CPUFREQ_POSTCHANGE && frq->old > frq->new))
		set_spu_profiling_frequency(frq->new, spu_cycle_reset);
	return ret;
}
Loading