Commit 3c2002ae authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Rafael J. Wysocki

cpufreq: mediatek: allow building as a module

The MT8173 cpufreq driver can currently only be built-in, but
it has a Kconfig dependency on the thermal core. THERMAL
can be a loadable module, which in turn makes this driver
impossible to build.

It is nicer to make the cpufreq driver a module as well, so
this patch turns the option in to a 'tristate' and adapts
the dependency accordingly.

The driver has no module_exit() function, so it will continue
to not support unloading, but it can be built as a module
and loaded at runtime now.
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Fixes: 5269e706 (cpufreq: Add ARM_MT8173_CPUFREQ dependency on THERMAL)
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent ddd30ef4
...@@ -84,10 +84,10 @@ config ARM_KIRKWOOD_CPUFREQ ...@@ -84,10 +84,10 @@ config ARM_KIRKWOOD_CPUFREQ
SoCs. SoCs.
config ARM_MT8173_CPUFREQ config ARM_MT8173_CPUFREQ
bool "Mediatek MT8173 CPUFreq support" tristate "Mediatek MT8173 CPUFreq support"
depends on ARCH_MEDIATEK && REGULATOR depends on ARCH_MEDIATEK && REGULATOR
depends on ARM64 || (ARM_CPU_TOPOLOGY && COMPILE_TEST) depends on ARM64 || (ARM_CPU_TOPOLOGY && COMPILE_TEST)
depends on !CPU_THERMAL || THERMAL=y depends on !CPU_THERMAL || THERMAL
select PM_OPP select PM_OPP
help help
This adds the CPUFreq driver support for Mediatek MT8173 SoC. This adds the CPUFreq driver support for Mediatek MT8173 SoC.
......
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
#include <linux/cpu_cooling.h> #include <linux/cpu_cooling.h>
#include <linux/cpufreq.h> #include <linux/cpufreq.h>
#include <linux/cpumask.h> #include <linux/cpumask.h>
#include <linux/module.h>
#include <linux/of.h> #include <linux/of.h>
#include <linux/platform_device.h> #include <linux/platform_device.h>
#include <linux/pm_opp.h> #include <linux/pm_opp.h>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment