]> www.infradead.org Git - linux-platform-drivers-x86.git/commitdiff
cpufreq: st: Add missing MODULE_DEVICE_TABLE
authorPali Rohár <pali@kernel.org>
Tue, 3 Nov 2020 15:11:35 +0000 (16:11 +0100)
committerViresh Kumar <viresh.kumar@linaro.org>
Mon, 7 Dec 2020 07:32:37 +0000 (13:02 +0530)
This patch adds missing MODULE_DEVICE_TABLE definition which generates
correct modalias for automatic loading of this cpufreq driver when it is
compiled as an external module.

Signed-off-by: Pali Rohár <pali@kernel.org>
Fixes: ab0ea257fc58d ("cpufreq: st: Provide runtime initialised driver for ST's platforms")
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
drivers/cpufreq/sti-cpufreq.c

index aab565edc4d30b166a3c341dd6b3e68f81402645..fdb0a722d881209eb928039bf646b2ffc2244eb3 100644 (file)
@@ -297,6 +297,13 @@ register_cpufreq_dt:
 }
 module_init(sti_cpufreq_init);
 
+static const struct of_device_id __maybe_unused sti_cpufreq_of_match[] = {
+       { .compatible = "st,stih407" },
+       { .compatible = "st,stih410" },
+       { },
+};
+MODULE_DEVICE_TABLE(of, sti_cpufreq_of_match);
+
 MODULE_DESCRIPTION("STMicroelectronics CPUFreq/OPP driver");
 MODULE_AUTHOR("Ajitpal Singh <ajitpal.singh@st.com>");
 MODULE_AUTHOR("Lee Jones <lee.jones@linaro.org>");