All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thierry Reding <thierry.reding@gmail.com>
To: Dmitry Osipenko <digetx@gmail.com>
Cc: Jonathan Hunter <jonathanh@nvidia.com>,
	Peter Geis <pgwipeout@gmail.com>,
	Matt Merhar <mattmerhar@protonmail.com>,
	linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 5/5] soc/tegra: pmc: Rate-limit error message about failed to acquire of reset
Date: Thu, 25 Mar 2021 15:42:15 +0100	[thread overview]
Message-ID: <YFyhR1XgFGzJkkLt@orome.fritz.box> (raw)
In-Reply-To: <20210302122502.20874-6-digetx@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1370 bytes --]

On Tue, Mar 02, 2021 at 03:25:02PM +0300, Dmitry Osipenko wrote:
> PMC domain could be easily bombarded with the enable requests if there is
> a problem in regards to acquiring reset control of a domain and kernel
> log will be flooded with the error message in this case. Hence rate-limit
> the message in order to prevent missing other important messages.
> 
> Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
> ---
>  drivers/soc/tegra/pmc.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/soc/tegra/pmc.c b/drivers/soc/tegra/pmc.c
> index bf29ea22480a..84ab27d85d92 100644
> --- a/drivers/soc/tegra/pmc.c
> +++ b/drivers/soc/tegra/pmc.c
> @@ -868,8 +868,8 @@ static int tegra_genpd_power_off(struct generic_pm_domain *domain)
>  
>  	err = reset_control_acquire(pg->reset);
>  	if (err < 0) {
> -		dev_err(dev, "failed to acquire resets for PM domain %s: %d\n",
> -			pg->genpd.name, err);
> +		dev_err_ratelimited(dev, "failed to acquire resets for PM domain %s: %d\n",
> +				    pg->genpd.name, err);

That doesn't look right. This is a serious error condition that
shouldn't happen at all. Ever. If this shows up even once we've got a
serious bug somewhere and we need to fix it rather than "downplay" it
by ratelimiting these errors.

What's the exact use-case where you see this?

Thierry

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2021-03-25 14:42 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-02 12:24 [PATCH v4 0/5] Tegra PMC driver fixes and improvements Dmitry Osipenko
2021-03-02 12:24 ` [PATCH v4 1/5] soc/tegra: pmc: Fix imbalanced clock disabling in error code path Dmitry Osipenko
2021-03-25 14:27   ` Thierry Reding
2021-03-02 12:24 ` [PATCH v4 2/5] soc/tegra: pmc: Fix completion of power-gate toggling Dmitry Osipenko
2021-03-25 14:32   ` Thierry Reding
2021-03-02 12:25 ` [PATCH v4 3/5] soc/tegra: pmc: Ensure that clock rates aren't too high Dmitry Osipenko
2021-03-25 14:39   ` Thierry Reding
2021-03-25 15:02     ` Dmitry Osipenko
2021-03-25 15:05       ` Dmitry Osipenko
2021-03-02 12:25 ` [PATCH v4 4/5] soc/tegra: pmc: Print out domain name when reset fails to acquire Dmitry Osipenko
2021-03-25 14:40   ` Thierry Reding
2021-03-02 12:25 ` [PATCH v4 5/5] soc/tegra: pmc: Rate-limit error message about failed to acquire of reset Dmitry Osipenko
2021-03-25 14:42   ` Thierry Reding [this message]
2021-03-25 14:53     ` Dmitry Osipenko

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=YFyhR1XgFGzJkkLt@orome.fritz.box \
    --to=thierry.reding@gmail.com \
    --cc=digetx@gmail.com \
    --cc=jonathanh@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=mattmerhar@protonmail.com \
    --cc=pgwipeout@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.