From: Viresh Kumar <viresh.kumar@linaro.org>
To: Fabio Estevam <fabio.estevam@nxp.com>
Cc: vireshk@kernel.org, nm@ti.com, sboyd@codeaurora.org,
rjw@rjwysocki.net, linux-pm@vger.kernel.org, festevam@gmail.com,
shawnguo@kernel.org, anson.huang@nxp.com
Subject: Re: [PATCH] PM / OPP: Move error message to debug level
Date: Wed, 4 Oct 2017 12:19:00 +0530 [thread overview]
Message-ID: <20171004064900.GA28593@vireshk-i7> (raw)
In-Reply-To: <1506706789-7717-1-git-send-email-fabio.estevam@nxp.com>
On 29-09-17, 14:39, Fabio Estevam wrote:
> On some i.MX6 platforms which do not have speed grading
> check, opp table will not be created in platform code,
> so cpufreq driver prints the following error message:
>
> cpu cpu0: dev_pm_opp_get_opp_count: OPP table not found (-19)
>
> However, this is not really an error in this case because the
> imx6q-cpufreq driver first calls dev_pm_opp_get_opp_count()
> and if it fails, it means that platform code does not provide
> OPP and then dev_pm_opp_of_add_table() will be called.
>
> In order to avoid such confusing error message, move it to
> debug level.
>
> It is up to the caller of dev_pm_opp_get_opp_count() to check its
> return value and decide if it will print an error or not.
>
> Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
> ---
> Previous discussion on this topic:
> https://patchwork.kernel.org/patch/9295059/
>
> drivers/base/power/opp/core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/base/power/opp/core.c b/drivers/base/power/opp/core.c
> index a6de325..0459b12 100644
> --- a/drivers/base/power/opp/core.c
> +++ b/drivers/base/power/opp/core.c
> @@ -296,7 +296,7 @@ int dev_pm_opp_get_opp_count(struct device *dev)
> opp_table = _find_opp_table(dev);
> if (IS_ERR(opp_table)) {
> count = PTR_ERR(opp_table);
> - dev_err(dev, "%s: OPP table not found (%d)\n",
> + dev_dbg(dev, "%s: OPP table not found (%d)\n",
> __func__, count);
> return count;
> }
Applied. Thanks.
--
viresh
next prev parent reply other threads:[~2017-10-04 6:49 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-29 17:39 [PATCH] PM / OPP: Move error message to debug level Fabio Estevam
2017-10-04 6:49 ` Viresh Kumar [this message]
2017-10-18 12:01 ` Fabio Estevam
2017-10-18 13:07 ` Rafael J. Wysocki
2017-10-18 14:49 ` Fabio Estevam
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=20171004064900.GA28593@vireshk-i7 \
--to=viresh.kumar@linaro.org \
--cc=anson.huang@nxp.com \
--cc=fabio.estevam@nxp.com \
--cc=festevam@gmail.com \
--cc=linux-pm@vger.kernel.org \
--cc=nm@ti.com \
--cc=rjw@rjwysocki.net \
--cc=sboyd@codeaurora.org \
--cc=shawnguo@kernel.org \
--cc=vireshk@kernel.org \
/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 NNTP newsgroup(s).