Re: [4/6] watchdog: da9062: Disable and wait before changing timeout

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Oct 17, 2017 at 05:30:25PM +0200, Michael Grzeschik wrote:
> The DA9062 watchdog occasionally enters error condition and resets the
> system if the timeout is changed quickly after the timer was enabled.
> 
> The method of disabling and waiting for > 150 µs before setting the
> new timeout is taken from the DA9052 driver.
> 
> Signed-off-by: Michael Grzeschik <m.grzeschik@xxxxxxxxxxxxxx>

Reviewed-by: Guenter Roeck <linux@xxxxxxxxxxxx>

> ---
>  drivers/watchdog/da9062_wdt.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/drivers/watchdog/da9062_wdt.c b/drivers/watchdog/da9062_wdt.c
> index b95719b349e5c..d43e0c46e23fb 100644
> --- a/drivers/watchdog/da9062_wdt.c
> +++ b/drivers/watchdog/da9062_wdt.c
> @@ -100,6 +100,13 @@ static int da9062_wdt_update_timeout_register(struct da9062_watchdog *wdt,
>  	if (ret)
>  		return ret;
>  
> +	regmap_update_bits(chip->regmap,
> +				  DA9062AA_CONTROL_D,
> +				  DA9062AA_TWDSCALE_MASK,
> +				  DA9062_TWDSCALE_DISABLE);
> +
> +	usleep_range(150, 300);
> +
>  	return regmap_update_bits(chip->regmap,
>  				  DA9062AA_CONTROL_D,
>  				  DA9062AA_TWDSCALE_MASK,
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux