From: Viresh Kumar <viresh.kumar@linaro.org>
To: Jia Hongtao <hongtao.jia@nxp.com>
Cc: linux-pm@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,
scott.wood@nxp.com, yuantian.tang@nxp.com
Subject: Re: [PATCH V2] cpufreq: qoriq: Fix cooling device registration issue during suspend
Date: Tue, 19 Apr 2016 13:24:00 +0530 [thread overview]
Message-ID: <20160419075400.GB2715@vireshk-i7> (raw)
In-Reply-To: <1461048206-23567-1-git-send-email-hongtao.jia@nxp.com>
On 19-04-16, 14:43, Jia Hongtao wrote:
> Cooling device is registered by ready callback. It's also invoked while
> system resuming from sleep (Enabling non-boot cpus). Thus cooling device
> may be multiple registered. Matchable unregistration is added to exit
> callback to fix this issue.
>
> Signed-off-by: Jia Hongtao <hongtao.jia@nxp.com>
> ---
> Changes for V2:
> * Using qoriq_cpufreq_cpu_exit() callback instead of adding stop_cpu().
>
> drivers/cpufreq/qoriq-cpufreq.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/cpufreq/qoriq-cpufreq.c b/drivers/cpufreq/qoriq-cpufreq.c
> index b23e525..0b85f90 100644
> --- a/drivers/cpufreq/qoriq-cpufreq.c
> +++ b/drivers/cpufreq/qoriq-cpufreq.c
> @@ -301,10 +301,11 @@ err_np:
> return -ENODEV;
> }
>
> -static int __exit qoriq_cpufreq_cpu_exit(struct cpufreq_policy *policy)
> +static int qoriq_cpufreq_cpu_exit(struct cpufreq_policy *policy)
Yes, __exit should have been removed, but not in this patch to create confusion.
You should have submitted two separate patches for these changes.
> {
> struct cpu_data *data = policy->driver_data;
>
> + cpufreq_cooling_unregister(data->cdev);
> kfree(data->pclk);
> kfree(data->table);
> kfree(data);
> @@ -348,7 +349,7 @@ static struct cpufreq_driver qoriq_cpufreq_driver = {
> .name = "qoriq_cpufreq",
> .flags = CPUFREQ_CONST_LOOPS,
> .init = qoriq_cpufreq_cpu_init,
> - .exit = __exit_p(qoriq_cpufreq_cpu_exit),
> + .exit = qoriq_cpufreq_cpu_exit,
> .verify = cpufreq_generic_frequency_table_verify,
> .target_index = qoriq_cpufreq_target,
> .get = cpufreq_generic_get,
> --
> 2.1.0.27.g96db324
--
viresh
next prev parent reply other threads:[~2016-04-19 7:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-19 6:43 [PATCH V2] cpufreq: qoriq: Fix cooling device registration issue during suspend Jia Hongtao
2016-04-19 7:54 ` Viresh Kumar [this message]
2016-04-19 8:51 ` 答复: " Hongtao Jia
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160419075400.GB2715@vireshk-i7 \
--to=viresh.kumar@linaro.org \
--cc=hongtao.jia@nxp.com \
--cc=linux-pm@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=scott.wood@nxp.com \
--cc=yuantian.tang@nxp.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox