[PATCH RFC 0/3] voltage scaling via clock rate-change notifiers
From: Mike Turquette
Date: Sun Jul 07 2013 - 21:46:01 EST
Scaling regulator voltage as a function of clock frequency is a common
power saving technique. It is often referred to as dynamic voltage &
frequency scaling (DVFS). The common clock framework has clock
rate-change notifier (pre & post) which provide a convenient hook for
scaling voltage whenever clk_set_rate is called.
The first patch in the series provides helper functions for drivers that
wish to scale voltage through the clock rate-change notifiers. The
approach taken is that the driver does not care about the details of the
OPP table, nor does it care about handling the voltage regulator
directly. The driver only has a pointer to the struct clk object; the
other details are hidden in the helper functions.
The second patch provides a CPUfreq-centric helper, built on top of the
first one. This is primarly to help with the struct
cpufreq_frequency_table bits and latency calculation.
The final patch in the series converts the cpufreq-cpu0 driver to use
these functions. Other cpufreq drivers can be converted later.
There are not many cases of DVFS usage in the kernel; vendors often keep
these out-of-tree. By providing a common approach using the clock rate
change notifiers this series hopes to consolidate code across drivers
and encourage vendors to upstream their DVFS bits.
Mike Turquette (3):
clk: notifier handler for dynamic voltage scaling
clk: cpufreq helper for voltage scaling
cpufreq: cpufreq-cpu0: clk rate-change notifiers
drivers/clk/Makefile | 1 +
drivers/clk/clk-voltage-notifier.c | 206 +++++++++++++++++++++++++++++++++++++
drivers/cpufreq/cpufreq-cpu0.c | 125 ++++------------------
include/linux/clk.h | 13 ++-
4 files changed, 241 insertions(+), 104 deletions(-)
create mode 100644 drivers/clk/clk-voltage-notifier.c
--
1.8.1.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/