All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Niedermaier <cniedermaier@dh-electronics.com>
To: Andrej Picej <andrej.picej@norik.com>,
	"support.opensource@diasemi.com" <support.opensource@diasemi.com>,
	"linux@roeck-us.net" <linux@roeck-us.net>,
	"linux-watchdog@vger.kernel.org" <linux-watchdog@vger.kernel.org>
Cc: "wim@linux-watchdog.org" <wim@linux-watchdog.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"robh+dt@kernel.org" <robh+dt@kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"shawnguo@kernel.org" <shawnguo@kernel.org>,
	"s.hauer@pengutronix.de" <s.hauer@pengutronix.de>,
	"kernel@pengutronix.de" <kernel@pengutronix.de>,
	"festevam@gmail.com" <festevam@gmail.com>,
	"linux-imx@nxp.com" <linux-imx@nxp.com>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>
Subject: RE: [PATCH v3 2/4] watchdog: da9062: reset board on watchdog timeout
Date: Thu, 2 Dec 2021 15:37:08 +0000	[thread overview]
Message-ID: <ae0838b3408746e188635f57ac942d5f@dh-electronics.com> (raw)
In-Reply-To: <9298e77a-d74e-f51a-187f-830da184e67d@norik.com>

From: Andrej Picej [mailto:andrej.picej@norik.com]
Sent: Thursday, December 2, 2021 8:43 AM

[...]
>> I have a question how to correctly restart the system after
>> watchdog timeout.
>> If I understand it correct after watchdog timeout the system
>> restarts only if WATCHDOG_SD (Bit 3) in register CONFIG_I is
>> set.
>> What is the difference if WATCHDOG_SD isn't set, but WAKE_UP
>> (Bit 2) in register CONTROL_F is set? From outside on my
>> system I observe the same behavior. After watchdog timeout
>> my system restarts. So where are the differences?
>> It would be nice if you could answer this question, as you
>> certainly know this chip very well.
> 
> To be honest I don't really know the chip that well, I'm just trying to
> add this feature and hopefully help others if they run into the same
> problem. I think @Adam will be more helpful here.
> 
> But from quick look at da9062 datasheet, mainly chapter "8.8 Power
> Modes" I see next main differences:
> - setting WATCHDOG_SD enables SHUTDOWN sequence when the watchdog
> timeout is triggered. This puts the chip (da9062) in RESET mode.
> Taken from DA9062 datasheet:
> > In RESET mode, the internal supplies, and LDO1 (if configured as an
> always-on supply) are enabled.
> > All other DA9062 supplies are disabled.
> > DA9062 is in RESET mode whenever a complete application shutdown is
> required
> > The DA9062’s register configuration will be re-loaded from OTP when
> leaving the RESET mode
> 
> - if you set the WAKE_UP bit than the chip enters POWERDOWN mode on
> watchdog timeout. I understand the POWERDOWN mode as a not that "deep"
> mode as a RESET mode Device will go from RESET mode to POWERDOWN mode in
> the sequence of powering-up.
> 
> The above explanation is just my understanding after quick look, @Adam
> please correct me if I'm talking nonsense.
> 
> Please have a look at the DA9062 datasheet for more information. Sorry,
> that I can't be more helpful here.


Hi Andrej,

Thanks a lot for your explanation. 
I think I would like to test your implementation, because this seems
to be the better way to restart the system to a reliable state.
I have a DA9061 which supplies an i.MX6ULL.
Would you be so kind to adapt your patch 1/4 for the DA9061?
For details I will also answer on your patch 1/4.

Thanks and regards
Christoph
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  parent reply	other threads:[~2021-12-02 15:45 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-01  8:15 [PATCH v3 1/4] mfd: da9062: make register CONFIG_I writable Andrej Picej
2021-12-01  8:15 ` Andrej Picej
2021-12-01  8:15 ` [PATCH v3 2/4] watchdog: da9062: reset board on watchdog timeout Andrej Picej
2021-12-01  8:15   ` Andrej Picej
2021-12-01 14:11   ` Christoph Niedermaier
2021-12-02  7:43     ` Andrej Picej
2021-12-02  7:43       ` Andrej Picej
2021-12-02 12:12       ` Adam Thomson
2021-12-02 12:12         ` Adam Thomson
2021-12-02 15:46         ` Christoph Niedermaier
2021-12-02 15:37       ` Christoph Niedermaier [this message]
2021-12-01 20:05   ` Adam Thomson
2021-12-01 20:05     ` Adam Thomson
2021-12-02  8:31     ` Andrej Picej
2021-12-02  8:31       ` Andrej Picej
2021-12-01 21:26   ` Guenter Roeck
2021-12-01 21:26     ` Guenter Roeck
2021-12-02  8:34     ` Andrej Picej
2021-12-02  8:34       ` Andrej Picej
2021-12-01  8:15 ` [PATCH v3 3/4] dt-bindings: watchdog: da9062: add watchdog timeout mode Andrej Picej
2021-12-01  8:15   ` Andrej Picej
2021-12-01  8:15 ` [PATCH v3 4/4] ARM: dts: imx6: phycore-som: set watchdog timeout mode to shutdown Andrej Picej
2021-12-01  8:15   ` Andrej Picej

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=ae0838b3408746e188635f57ac942d5f@dh-electronics.com \
    --to=cniedermaier@dh-electronics.com \
    --cc=andrej.picej@norik.com \
    --cc=devicetree@vger.kernel.org \
    --cc=festevam@gmail.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-imx@nxp.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-watchdog@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=robh+dt@kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=shawnguo@kernel.org \
    --cc=support.opensource@diasemi.com \
    --cc=wim@linux-watchdog.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 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.