[PATCH 4.4.y-cip 09/11] cpufreq: dt: Don't use generic platdev driver for ti-cpufreq platforms

Chen-Yu Tsai (Moxa) <wens@...>

From: Dave Gerlach <d-gerlach@ti.com>

commit 051bd84bb45bc994b7d762467f60b3bd0c7aa6bc upstream.

Some TI platforms, specifically those in the am33xx, am43xx, dra7xx, and
am57xx families of SoCs can make use of the ti-cpufreq driver to
selectively enable OPPs based on the exact configuration in use. The
ti-cpufreq is given the responsibility of creating the cpufreq-dt
platform device when the driver is in use so drop am33xx and dra7xx
from the cpufreq-dt-platdev driver so it is not created twice.

Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
[wens@csie.org: Backport to pre generic platdev driver]
Signed-off-by: Chen-Yu Tsai (Moxa) <wens@csie.org>

I kept the original patch subject to make it easier for scripts to match
against upstream patches.

arch/arm/mach-omap2/pm.c | 3 +++
1 file changed, 3 insertions(+)

diff --git a/arch/arm/mach-omap2/pm.c b/arch/arm/mach-omap2/pm.c
index 3d876bde8c859..88cb34c608ab8 100644
--- a/arch/arm/mach-omap2/pm.c
+++ b/arch/arm/mach-omap2/pm.c
@@ -281,6 +281,9 @@ static inline void omap_init_cpufreq(void)
if (!of_have_populated_dt())
devinfo.name =3D "omap-cpufreq";
+ else if (of_machine_is_compatible("ti,am33xx") ||
+ of_machine_is_compatible("ti,dra7"))
+ return;
devinfo.name =3D "cpufreq-dt";

Join cip-dev@lists.cip-project.org to automatically receive all group messages.