cpufreq: dt-platdev: Support building as module
authorZhipeng Wang <zhipeng.wang_1@nxp.com>
Wed, 24 May 2023 15:34:16 +0000 (15:34 +0000)
committerViresh Kumar <viresh.kumar@linaro.org>
Mon, 5 Jun 2023 11:03:05 +0000 (16:33 +0530)
Make the cpufreq platdev driver as tristate so that it can be built
as loadable module.

Also add MODULE_LICENSE to support building as module.

Signed-off-by: Zhipeng Wang <zhipeng.wang_1@nxp.com>
[ Viresh: Merged two commits, included module.h ]
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
drivers/cpufreq/Kconfig
drivers/cpufreq/cpufreq-dt-platdev.c

index 2c839bd..dda3a78 100644 (file)
@@ -218,7 +218,7 @@ config CPUFREQ_DT
          If in doubt, say N.
 
 config CPUFREQ_DT_PLATDEV
-       bool
+       tristate "Generic DT based cpufreq platdev driver"
        help
          This adds a generic DT based cpufreq platdev driver for frequency
          management.  This creates a 'cpufreq-dt' platform device, on the
index ea86c9f..e2b2008 100644 (file)
@@ -5,6 +5,7 @@
  */
 
 #include <linux/err.h>
+#include <linux/module.h>
 #include <linux/of.h>
 #include <linux/platform_device.h>
 
@@ -217,3 +218,4 @@ create_pdev:
                               sizeof(struct cpufreq_dt_platform_data)));
 }
 core_initcall(cpufreq_dt_platdev_init);
+MODULE_LICENSE("GPL");