From: Viresh Kumar <viresh.kumar@linaro.org>
To: Duan Jiong <duanj.fnst@cn.fujitsu.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
"cpufreq@vger.kernel.org" <cpufreq@vger.kernel.org>,
"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>
Subject: Re: [PATCH] cpufreq: unicore32: replace IS_ERR and PTR_ERR with PTR_ERR_OR_ZERO
Date: Fri, 11 Apr 2014 13:45:55 +0530 [thread overview]
Message-ID: <CAKohpomaPtvxFXKcCm-pF+xSXrbN6Fg=QvfHSYkzDhWcWX005w@mail.gmail.com> (raw)
In-Reply-To: <1397203178-16780-1-git-send-email-duanj.fnst@cn.fujitsu.com>
On 11 April 2014 13:29, Duan Jiong <duanj.fnst@cn.fujitsu.com> wrote:
> This patch fixes coccinelle error regarding usage of IS_ERR and
> PTR_ERR instead of PTR_ERR_OR_ZERO.
>
> Signed-off-by: Duan Jiong <duanj.fnst@cn.fujitsu.com>
> ---
> drivers/cpufreq/unicore2-cpufreq.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/cpufreq/unicore2-cpufreq.c b/drivers/cpufreq/unicore2-cpufreq.c
> index 8d045af..6f9dfa8 100644
> --- a/drivers/cpufreq/unicore2-cpufreq.c
> +++ b/drivers/cpufreq/unicore2-cpufreq.c
> @@ -60,9 +60,7 @@ static int __init ucv2_cpu_init(struct cpufreq_policy *policy)
> policy->max = policy->cpuinfo.max_freq = 1000000;
> policy->cpuinfo.transition_latency = CPUFREQ_ETERNAL;
> policy->clk = clk_get(NULL, "MAIN_CLK");
> - if (IS_ERR(policy->clk))
> - return PTR_ERR(policy->clk);
> - return 0;
> + return PTR_ERR_OR_ZERO(policy->clk);
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
prev parent reply other threads:[~2014-04-11 8:15 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-11 7:59 [PATCH] cpufreq: unicore32: replace IS_ERR and PTR_ERR with PTR_ERR_OR_ZERO Duan Jiong
2014-04-11 8:15 ` Viresh Kumar [this message]
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='CAKohpomaPtvxFXKcCm-pF+xSXrbN6Fg=QvfHSYkzDhWcWX005w@mail.gmail.com' \
--to=viresh.kumar@linaro.org \
--cc=cpufreq@vger.kernel.org \
--cc=duanj.fnst@cn.fujitsu.com \
--cc=linux-pm@vger.kernel.org \
--cc=rjw@rjwysocki.net \
/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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).