[PATCH 2/2] watchdog: add watchdog behavior configuration

Tom Rini trini at konsulko.com
Wed Sep 23 19:14:09 CEST 2020


On Wed, Sep 23, 2020 at 07:01:54PM +0200, Mark Kettenis wrote:
> > From: Michael Walle <michael at walle.cc>
> > Date: Wed, 23 Sep 2020 18:45:27 +0200
> > 
> > Let the user choose between three different behaviours of the watchdog:
> >  (1) Keep the watchdog disabled
> >  (2) Supervise u-boot
> >  (3) Supervise u-boot and the operating systen (default)
> > 
> > Option (2) will disable the watchdog right before handing control to the
> > operating system. This is useful when the OS is not aware of the
> > watchdog. Option (3) doesn't disable the watchdog and assumes the OS
> > will continue servicing.
> 
> (3) can't be the default, at least for EFI
> 
> The UEFI standard explicitly says that upon calling
> ExitBootServices(), the watchdog timer is disabled.
> 
> In general, you can't expect an OS to have support for a particular
> watchdog timer.  So (3) only makes sense in cases where U-Boot is
> bundled with an OS image.

We need to be careful here then.  The current and historical / generally
expected behavior is if we've enabled the watchdog we supervise it and
leave it enabled for the OS.  Given what UEFI requires I'd like to see
that case handled with a print about disabling the watchdog so it's not
a surprise to the user.  I say this because it's a surprise to me and I
guess answers the question of "how does x86 handle this?" I had the
other day.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200923/34d47213/attachment.sig>


More information about the U-Boot mailing list