Some of cpufreq drivers are tristate, can be compiled as modules, but do not have defined modalias for automatic loading. This patch series add for all those cpufreq drivers missing MODULE_DEVICE_TABLE macro, based on OF definitions, or MODULE_ALIAS for platform drivers. MODULE_DEVICE_TABLE is not explictily added only for speedstep-centrino, speedstep-ich and speedstep-smi drivers as it was removed in commit b11d77fa300d9 ("cpufreq: Convert to new X86 CPU match macros"). Pali Rohár (9): cpufreq: ap806: Add missing MODULE_DEVICE_TABLE cpufreq: highbank: Add missing MODULE_DEVICE_TABLE cpufreq: mediatek: Add missing MODULE_DEVICE_TABLE cpufreq: qcom: Add missing MODULE_DEVICE_TABLE cpufreq: st: Add missing MODULE_DEVICE_TABLE cpufreq: sun50i: Add missing MODULE_DEVICE_TABLE cpufreq: loongson1: Add missing MODULE_ALIAS cpufreq: scpi: Add missing MODULE_ALIAS cpufreq: vexpress-spc: Add missing MODULE_ALIAS drivers/cpufreq/armada-8k-cpufreq.c | 6 ++++++ drivers/cpufreq/highbank-cpufreq.c | 7 +++++++ drivers/cpufreq/loongson1-cpufreq.c | 1 + drivers/cpufreq/mediatek-cpufreq.c | 1 + drivers/cpufreq/qcom-cpufreq-nvmem.c | 1 + drivers/cpufreq/scpi-cpufreq.c | 1 + drivers/cpufreq/sti-cpufreq.c | 7 +++++++ drivers/cpufreq/sun50i-cpufreq-nvmem.c | 1 + drivers/cpufreq/vexpress-spc-cpufreq.c | 1 + 9 files changed, 26 insertions(+) -- 2.20.1
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: f525a670533d9 ("cpufreq: ap806: add cpufreq driver for Armada 8K") --- drivers/cpufreq/armada-8k-cpufreq.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/cpufreq/armada-8k-cpufreq.c b/drivers/cpufreq/armada-8k-cpufreq.c index 39e34f5066d3..b0fc5e84f857 100644 --- a/drivers/cpufreq/armada-8k-cpufreq.c +++ b/drivers/cpufreq/armada-8k-cpufreq.c @@ -204,6 +204,12 @@ static void __exit armada_8k_cpufreq_exit(void) } module_exit(armada_8k_cpufreq_exit); +static const struct of_device_id __maybe_unused armada_8k_cpufreq_of_match[] = { + { .compatible = "marvell,ap806-cpu-clock" }, + { }, +}; +MODULE_DEVICE_TABLE(of, armada_8k_cpufreq_of_match); + MODULE_AUTHOR("Gregory Clement <gregory.clement@bootlin.com>"); MODULE_DESCRIPTION("Armada 8K cpufreq driver"); MODULE_LICENSE("GPL"); -- 2.20.1
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: 6754f556103be ("cpufreq / highbank: add support for highbank cpufreq") --- drivers/cpufreq/highbank-cpufreq.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/cpufreq/highbank-cpufreq.c b/drivers/cpufreq/highbank-cpufreq.c index 5a7f6dafcddb..ac57cddc5f2f 100644 --- a/drivers/cpufreq/highbank-cpufreq.c +++ b/drivers/cpufreq/highbank-cpufreq.c @@ -101,6 +101,13 @@ static int hb_cpufreq_driver_init(void) } module_init(hb_cpufreq_driver_init); +static const struct of_device_id __maybe_unused hb_cpufreq_of_match[] = { + { .compatible = "calxeda,highbank" }, + { .compatible = "calxeda,ecx-2000" }, + { }, +}; +MODULE_DEVICE_TABLE(of, hb_cpufreq_of_match); + MODULE_AUTHOR("Mark Langsdorf <mark.langsdorf@calxeda.com>"); MODULE_DESCRIPTION("Calxeda Highbank cpufreq driver"); MODULE_LICENSE("GPL"); -- 2.20.1
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: 501c574f4e3a5 ("cpufreq: mediatek: Add support of cpufreq to MT2701/MT7623 SoC") --- drivers/cpufreq/mediatek-cpufreq.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/cpufreq/mediatek-cpufreq.c b/drivers/cpufreq/mediatek-cpufreq.c index 7d1212c9b7c8..a310372dc53e 100644 --- a/drivers/cpufreq/mediatek-cpufreq.c +++ b/drivers/cpufreq/mediatek-cpufreq.c @@ -540,6 +540,7 @@ static const struct of_device_id mtk_cpufreq_machines[] __initconst = { { } }; +MODULE_DEVICE_TABLE(of, mtk_cpufreq_machines); static int __init mtk_cpufreq_driver_init(void) { -- 2.20.1
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: 46e2856b8e188 ("cpufreq: Add Kryo CPU scaling driver") --- drivers/cpufreq/qcom-cpufreq-nvmem.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/cpufreq/qcom-cpufreq-nvmem.c b/drivers/cpufreq/qcom-cpufreq-nvmem.c index d06b37822c3d..fba9937a406b 100644 --- a/drivers/cpufreq/qcom-cpufreq-nvmem.c +++ b/drivers/cpufreq/qcom-cpufreq-nvmem.c @@ -464,6 +464,7 @@ static const struct of_device_id qcom_cpufreq_match_list[] __initconst = { { .compatible = "qcom,msm8960", .data = &match_data_krait }, {}, }; +MODULE_DEVICE_TABLE(of, qcom_cpufreq_match_list); /* * Since the driver depends on smem and nvmem drivers, which may -- 2.20.1
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") --- drivers/cpufreq/sti-cpufreq.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/cpufreq/sti-cpufreq.c b/drivers/cpufreq/sti-cpufreq.c index 4ac6fb23792a..c40d3d7d4ea4 100644 --- a/drivers/cpufreq/sti-cpufreq.c +++ b/drivers/cpufreq/sti-cpufreq.c @@ -292,6 +292,13 @@ static int sti_cpufreq_init(void) } 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>"); -- 2.20.1
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: f328584f7bff8 ("cpufreq: Add sun50i nvmem based CPU scaling driver") --- drivers/cpufreq/sun50i-cpufreq-nvmem.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/cpufreq/sun50i-cpufreq-nvmem.c b/drivers/cpufreq/sun50i-cpufreq-nvmem.c index 9907a165135b..2deed8d8773f 100644 --- a/drivers/cpufreq/sun50i-cpufreq-nvmem.c +++ b/drivers/cpufreq/sun50i-cpufreq-nvmem.c @@ -167,6 +167,7 @@ static const struct of_device_id sun50i_cpufreq_match_list[] = { { .compatible = "allwinner,sun50i-h6" }, {} }; +MODULE_DEVICE_TABLE(of, sun50i_cpufreq_match_list); static const struct of_device_id *sun50i_cpufreq_match_node(void) { -- 2.20.1
This patch adds missing MODULE_ALIAS 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: a0a22cf14472f ("cpufreq: Loongson1: Add cpufreq driver for Loongson1B") --- drivers/cpufreq/loongson1-cpufreq.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/cpufreq/loongson1-cpufreq.c b/drivers/cpufreq/loongson1-cpufreq.c index 0ea88778882a..86f612593e49 100644 --- a/drivers/cpufreq/loongson1-cpufreq.c +++ b/drivers/cpufreq/loongson1-cpufreq.c @@ -216,6 +216,7 @@ static struct platform_driver ls1x_cpufreq_platdrv = { module_platform_driver(ls1x_cpufreq_platdrv); +MODULE_ALIAS("platform:ls1x-cpufreq"); MODULE_AUTHOR("Kelvin Cheung <keguang.zhang@gmail.com>"); MODULE_DESCRIPTION("Loongson1 CPUFreq driver"); MODULE_LICENSE("GPL"); -- 2.20.1
This patch adds missing MODULE_ALIAS 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: 8def31034d033 ("cpufreq: arm_big_little: add SCPI interface driver") --- drivers/cpufreq/scpi-cpufreq.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/cpufreq/scpi-cpufreq.c b/drivers/cpufreq/scpi-cpufreq.c index 43db05b949d9..e5140ad63db8 100644 --- a/drivers/cpufreq/scpi-cpufreq.c +++ b/drivers/cpufreq/scpi-cpufreq.c @@ -233,6 +233,7 @@ static struct platform_driver scpi_cpufreq_platdrv = { }; module_platform_driver(scpi_cpufreq_platdrv); +MODULE_ALIAS("platform:scpi-cpufreq"); MODULE_AUTHOR("Sudeep Holla <sudeep.holla@arm.com>"); MODULE_DESCRIPTION("ARM SCPI CPUFreq interface driver"); MODULE_LICENSE("GPL v2"); -- 2.20.1
This patch adds missing MODULE_ALIAS 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: 47ac9aa165540 ("cpufreq: arm_big_little: add vexpress SPC interface driver") --- drivers/cpufreq/vexpress-spc-cpufreq.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/cpufreq/vexpress-spc-cpufreq.c b/drivers/cpufreq/vexpress-spc-cpufreq.c index e89b905754d2..f711d8eaea6a 100644 --- a/drivers/cpufreq/vexpress-spc-cpufreq.c +++ b/drivers/cpufreq/vexpress-spc-cpufreq.c @@ -591,6 +591,7 @@ static struct platform_driver ve_spc_cpufreq_platdrv = { }; module_platform_driver(ve_spc_cpufreq_platdrv); +MODULE_ALIAS("platform:vexpress-spc-cpufreq"); MODULE_AUTHOR("Viresh Kumar <viresh.kumar@linaro.org>"); MODULE_AUTHOR("Sudeep Holla <sudeep.holla@arm.com>"); MODULE_DESCRIPTION("Vexpress SPC ARM big LITTLE cpufreq driver"); -- 2.20.1
On Tue, Nov 3, 2020 at 4:14 PM Pali Rohár <pali@kernel.org> wrote:
>
> Some of cpufreq drivers are tristate, can be compiled as modules, but do
> not have defined modalias for automatic loading. This patch series add
> for all those cpufreq drivers missing MODULE_DEVICE_TABLE macro, based
> on OF definitions, or MODULE_ALIAS for platform drivers.
>
> MODULE_DEVICE_TABLE is not explictily added only for speedstep-centrino,
> speedstep-ich and speedstep-smi drivers as it was removed in commit
> b11d77fa300d9 ("cpufreq: Convert to new X86 CPU match macros").
>
> Pali Rohár (9):
> cpufreq: ap806: Add missing MODULE_DEVICE_TABLE
> cpufreq: highbank: Add missing MODULE_DEVICE_TABLE
> cpufreq: mediatek: Add missing MODULE_DEVICE_TABLE
> cpufreq: qcom: Add missing MODULE_DEVICE_TABLE
> cpufreq: st: Add missing MODULE_DEVICE_TABLE
> cpufreq: sun50i: Add missing MODULE_DEVICE_TABLE
> cpufreq: loongson1: Add missing MODULE_ALIAS
> cpufreq: scpi: Add missing MODULE_ALIAS
> cpufreq: vexpress-spc: Add missing MODULE_ALIAS
>
> drivers/cpufreq/armada-8k-cpufreq.c | 6 ++++++
> drivers/cpufreq/highbank-cpufreq.c | 7 +++++++
> drivers/cpufreq/loongson1-cpufreq.c | 1 +
> drivers/cpufreq/mediatek-cpufreq.c | 1 +
> drivers/cpufreq/qcom-cpufreq-nvmem.c | 1 +
> drivers/cpufreq/scpi-cpufreq.c | 1 +
> drivers/cpufreq/sti-cpufreq.c | 7 +++++++
> drivers/cpufreq/sun50i-cpufreq-nvmem.c | 1 +
> drivers/cpufreq/vexpress-spc-cpufreq.c | 1 +
> 9 files changed, 26 insertions(+)
>
> --
Viresh, any comments?
On 09-11-20, 15:18, Rafael J. Wysocki wrote:
> On Tue, Nov 3, 2020 at 4:14 PM Pali Rohár <pali@kernel.org> wrote:
> >
> > Some of cpufreq drivers are tristate, can be compiled as modules, but do
> > not have defined modalias for automatic loading. This patch series add
> > for all those cpufreq drivers missing MODULE_DEVICE_TABLE macro, based
> > on OF definitions, or MODULE_ALIAS for platform drivers.
> >
> > MODULE_DEVICE_TABLE is not explictily added only for speedstep-centrino,
> > speedstep-ich and speedstep-smi drivers as it was removed in commit
> > b11d77fa300d9 ("cpufreq: Convert to new X86 CPU match macros").
> >
> > Pali Rohár (9):
> > cpufreq: ap806: Add missing MODULE_DEVICE_TABLE
> > cpufreq: highbank: Add missing MODULE_DEVICE_TABLE
> > cpufreq: mediatek: Add missing MODULE_DEVICE_TABLE
> > cpufreq: qcom: Add missing MODULE_DEVICE_TABLE
> > cpufreq: st: Add missing MODULE_DEVICE_TABLE
> > cpufreq: sun50i: Add missing MODULE_DEVICE_TABLE
> > cpufreq: loongson1: Add missing MODULE_ALIAS
> > cpufreq: scpi: Add missing MODULE_ALIAS
> > cpufreq: vexpress-spc: Add missing MODULE_ALIAS
> >
> > drivers/cpufreq/armada-8k-cpufreq.c | 6 ++++++
> > drivers/cpufreq/highbank-cpufreq.c | 7 +++++++
> > drivers/cpufreq/loongson1-cpufreq.c | 1 +
> > drivers/cpufreq/mediatek-cpufreq.c | 1 +
> > drivers/cpufreq/qcom-cpufreq-nvmem.c | 1 +
> > drivers/cpufreq/scpi-cpufreq.c | 1 +
> > drivers/cpufreq/sti-cpufreq.c | 7 +++++++
> > drivers/cpufreq/sun50i-cpufreq-nvmem.c | 1 +
> > drivers/cpufreq/vexpress-spc-cpufreq.c | 1 +
> > 9 files changed, 26 insertions(+)
> >
> > --
>
> Viresh, any comments?
I found the patches to be fine and marked it to be applied soon in mutt. I was
waiting for the maintainers of the drivers to respond, after that I would have
applied it for 5.11.
--
viresh
On Tue, Nov 3, 2020 at 11:14 PM Pali Rohár <pali@kernel.org> wrote:
>
> 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: f328584f7bff8 ("cpufreq: Add sun50i nvmem based CPU scaling driver")
> ---
> drivers/cpufreq/sun50i-cpufreq-nvmem.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/cpufreq/sun50i-cpufreq-nvmem.c b/drivers/cpufreq/sun50i-cpufreq-nvmem.c
> index 9907a165135b..2deed8d8773f 100644
> --- a/drivers/cpufreq/sun50i-cpufreq-nvmem.c
> +++ b/drivers/cpufreq/sun50i-cpufreq-nvmem.c
> @@ -167,6 +167,7 @@ static const struct of_device_id sun50i_cpufreq_match_list[] = {
> { .compatible = "allwinner,sun50i-h6" },
> {}
> };
> +MODULE_DEVICE_TABLE(of, sun50i_cpufreq_match_list);
Reviewed-by: Yangtao Li <tiny.windzz@gmail.com>
Thx!
On Tue, Nov 10, 2020 at 3:35 AM Viresh Kumar <viresh.kumar@linaro.org> wrote:
>
> On 09-11-20, 15:18, Rafael J. Wysocki wrote:
> > On Tue, Nov 3, 2020 at 4:14 PM Pali Rohár <pali@kernel.org> wrote:
> > >
> > > Some of cpufreq drivers are tristate, can be compiled as modules, but do
> > > not have defined modalias for automatic loading. This patch series add
> > > for all those cpufreq drivers missing MODULE_DEVICE_TABLE macro, based
> > > on OF definitions, or MODULE_ALIAS for platform drivers.
> > >
> > > MODULE_DEVICE_TABLE is not explictily added only for speedstep-centrino,
> > > speedstep-ich and speedstep-smi drivers as it was removed in commit
> > > b11d77fa300d9 ("cpufreq: Convert to new X86 CPU match macros").
> > >
> > > Pali Rohár (9):
> > > cpufreq: ap806: Add missing MODULE_DEVICE_TABLE
> > > cpufreq: highbank: Add missing MODULE_DEVICE_TABLE
> > > cpufreq: mediatek: Add missing MODULE_DEVICE_TABLE
> > > cpufreq: qcom: Add missing MODULE_DEVICE_TABLE
> > > cpufreq: st: Add missing MODULE_DEVICE_TABLE
> > > cpufreq: sun50i: Add missing MODULE_DEVICE_TABLE
> > > cpufreq: loongson1: Add missing MODULE_ALIAS
> > > cpufreq: scpi: Add missing MODULE_ALIAS
> > > cpufreq: vexpress-spc: Add missing MODULE_ALIAS
> > >
> > > drivers/cpufreq/armada-8k-cpufreq.c | 6 ++++++
> > > drivers/cpufreq/highbank-cpufreq.c | 7 +++++++
> > > drivers/cpufreq/loongson1-cpufreq.c | 1 +
> > > drivers/cpufreq/mediatek-cpufreq.c | 1 +
> > > drivers/cpufreq/qcom-cpufreq-nvmem.c | 1 +
> > > drivers/cpufreq/scpi-cpufreq.c | 1 +
> > > drivers/cpufreq/sti-cpufreq.c | 7 +++++++
> > > drivers/cpufreq/sun50i-cpufreq-nvmem.c | 1 +
> > > drivers/cpufreq/vexpress-spc-cpufreq.c | 1 +
> > > 9 files changed, 26 insertions(+)
> > >
> > > --
> >
> > Viresh, any comments?
>
> I found the patches to be fine and marked it to be applied soon in mutt. I was
> waiting for the maintainers of the drivers to respond, after that I would have
> applied it for 5.11.
OK, so please take all of them then (some of them are not ARM-related AFAICS).
On 03-11-20, 16:11, Pali Rohár wrote:
> Some of cpufreq drivers are tristate, can be compiled as modules, but do
> not have defined modalias for automatic loading. This patch series add
> for all those cpufreq drivers missing MODULE_DEVICE_TABLE macro, based
> on OF definitions, or MODULE_ALIAS for platform drivers.
>
> MODULE_DEVICE_TABLE is not explictily added only for speedstep-centrino,
> speedstep-ich and speedstep-smi drivers as it was removed in commit
> b11d77fa300d9 ("cpufreq: Convert to new X86 CPU match macros").
>
> Pali Rohár (9):
> cpufreq: ap806: Add missing MODULE_DEVICE_TABLE
> cpufreq: highbank: Add missing MODULE_DEVICE_TABLE
> cpufreq: mediatek: Add missing MODULE_DEVICE_TABLE
> cpufreq: qcom: Add missing MODULE_DEVICE_TABLE
> cpufreq: st: Add missing MODULE_DEVICE_TABLE
> cpufreq: sun50i: Add missing MODULE_DEVICE_TABLE
> cpufreq: loongson1: Add missing MODULE_ALIAS
> cpufreq: scpi: Add missing MODULE_ALIAS
> cpufreq: vexpress-spc: Add missing MODULE_ALIAS
>
> drivers/cpufreq/armada-8k-cpufreq.c | 6 ++++++
> drivers/cpufreq/highbank-cpufreq.c | 7 +++++++
> drivers/cpufreq/loongson1-cpufreq.c | 1 +
> drivers/cpufreq/mediatek-cpufreq.c | 1 +
> drivers/cpufreq/qcom-cpufreq-nvmem.c | 1 +
> drivers/cpufreq/scpi-cpufreq.c | 1 +
> drivers/cpufreq/sti-cpufreq.c | 7 +++++++
> drivers/cpufreq/sun50i-cpufreq-nvmem.c | 1 +
> drivers/cpufreq/vexpress-spc-cpufreq.c | 1 +
> 9 files changed, 26 insertions(+)
Applied. Thanks.
--
viresh