* [PATCH -next] cpufreq: cppc: Remove unnecessary INIT_LIST_HEAD()
@ 2021-05-11 11:47 Yang Yingliang
2021-05-12 5:36 ` Viresh Kumar
0 siblings, 1 reply; 2+ messages in thread
From: Yang Yingliang @ 2021-05-11 11:47 UTC (permalink / raw)
To: linux-kernel, linux-pm; +Cc: viresh.kumar, rjw
The list_head cpu_data_list is initialized statically.
It is unnecessary to initialize by INIT_LIST_HEAD().
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
drivers/cpufreq/cppc_cpufreq.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/cpufreq/cppc_cpufreq.c b/drivers/cpufreq/cppc_cpufreq.c
index 3848b4c222e1..b312fa210a39 100644
--- a/drivers/cpufreq/cppc_cpufreq.c
+++ b/drivers/cpufreq/cppc_cpufreq.c
@@ -723,8 +723,6 @@ static int __init cppc_cpufreq_init(void)
if ((acpi_disabled) || !acpi_cpc_valid())
return -ENODEV;
- INIT_LIST_HEAD(&cpu_data_list);
-
cppc_check_hisi_workaround();
ret = cpufreq_register_driver(&cppc_cpufreq_driver);
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH -next] cpufreq: cppc: Remove unnecessary INIT_LIST_HEAD()
2021-05-11 11:47 [PATCH -next] cpufreq: cppc: Remove unnecessary INIT_LIST_HEAD() Yang Yingliang
@ 2021-05-12 5:36 ` Viresh Kumar
0 siblings, 0 replies; 2+ messages in thread
From: Viresh Kumar @ 2021-05-12 5:36 UTC (permalink / raw)
To: Yang Yingliang; +Cc: linux-kernel, linux-pm, rjw
On 11-05-21, 19:47, Yang Yingliang wrote:
> The list_head cpu_data_list is initialized statically.
> It is unnecessary to initialize by INIT_LIST_HEAD().
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
> ---
> drivers/cpufreq/cppc_cpufreq.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/cpufreq/cppc_cpufreq.c b/drivers/cpufreq/cppc_cpufreq.c
> index 3848b4c222e1..b312fa210a39 100644
> --- a/drivers/cpufreq/cppc_cpufreq.c
> +++ b/drivers/cpufreq/cppc_cpufreq.c
> @@ -723,8 +723,6 @@ static int __init cppc_cpufreq_init(void)
> if ((acpi_disabled) || !acpi_cpc_valid())
> return -ENODEV;
>
> - INIT_LIST_HEAD(&cpu_data_list);
> -
> cppc_check_hisi_workaround();
>
> ret = cpufreq_register_driver(&cppc_cpufreq_driver);
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
--
viresh
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-05-12 5:36 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-11 11:47 [PATCH -next] cpufreq: cppc: Remove unnecessary INIT_LIST_HEAD() Yang Yingliang
2021-05-12 5:36 ` Viresh Kumar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).