linux-watchdog.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: Marco Felsch <m.felsch@pengutronix.de>
Cc: support.opensource@diasemi.com, stwiss.opensource@diasemi.com,
	Adam.Thomson.Opensource@diasemi.com,
	linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org,
	kernel@pengutronix.de
Subject: Re: [PATCH] watchdog: da9062: do not ping the hw during stop()
Date: Sat, 25 Jan 2020 15:11:26 -0800	[thread overview]
Message-ID: <20200125231126.GA25513@roeck-us.net> (raw)
In-Reply-To: <20200120091729.16256-1-m.felsch@pengutronix.de>

On Mon, Jan 20, 2020 at 10:17:29AM +0100, Marco Felsch wrote:
> The da9062 hw has a minimum ping cool down phase of at least 200ms. The
> driver takes that into account by setting the min_hw_heartbeat_ms to
> 300ms and the core guarantees that the hw limit is observed for the
> ping() calls. But the core can't guarantees the required minimum ping

guarantee

> cool down phase if a stop() command is send immediately after the ping()
> command. So it is not allowed to ping the watchdog within the stop()
> command as the driver do. Remove the ping can be done without doubts

does

> because the watchdog gets disabled anyway and a (re)start reset the

resets

> watchdog counter too.
> 
> Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>

Reviewed-by: Guenter Roeck <linux@roeck-us.net>

> ---
>  drivers/watchdog/da9062_wdt.c | 7 -------
>  1 file changed, 7 deletions(-)
> 
> diff --git a/drivers/watchdog/da9062_wdt.c b/drivers/watchdog/da9062_wdt.c
> index 77b6b5336067..0ad15d55071c 100644
> --- a/drivers/watchdog/da9062_wdt.c
> +++ b/drivers/watchdog/da9062_wdt.c
> @@ -97,13 +97,6 @@ static int da9062_wdt_stop(struct watchdog_device *wdd)
>  	struct da9062_watchdog *wdt = watchdog_get_drvdata(wdd);
>  	int ret;
>  
> -	ret = da9062_reset_watchdog_timer(wdt);
> -	if (ret) {
> -		dev_err(wdt->hw->dev, "Failed to ping the watchdog (err = %d)\n",
> -			ret);
> -		return ret;
> -	}
> -
>  	ret = regmap_update_bits(wdt->hw->regmap,
>  				 DA9062AA_CONTROL_D,
>  				 DA9062AA_TWDSCALE_MASK,

  reply	other threads:[~2020-01-25 23:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-20  9:17 [PATCH] watchdog: da9062: do not ping the hw during stop() Marco Felsch
2020-01-25 23:11 ` Guenter Roeck [this message]
2020-01-28 10:13 ` Adam Thomson

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=20200125231126.GA25513@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=Adam.Thomson.Opensource@diasemi.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-watchdog@vger.kernel.org \
    --cc=m.felsch@pengutronix.de \
    --cc=stwiss.opensource@diasemi.com \
    --cc=support.opensource@diasemi.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;
as well as URLs for NNTP newsgroup(s).