From: Wim Van Sebroeck <wim@iguana.be>
To: Guenter Roeck <linux@roeck-us.net>
Cc: "linux-watchdog@vger.kernel.org" <linux-watchdog@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
Laxman Dewangan <ldewangan@nvidia.com>,
Mans Rullgard <mans@mansr.com>,
Justin Chen <justinpopo6@gmail.com>,
Wenyou Yang <wenyou.yang@atmel.com>,
Naidu Tellapati <naidu.tellapati@gmail.com>
Subject: Re: Stopping watchdog in watchdog driver remove functions
Date: Sun, 1 Jan 2017 12:14:22 +0100 [thread overview]
Message-ID: <20170101111421.GA9695@spo001.leaseweb.nl> (raw)
In-Reply-To: <64c83c02-2c64-c536-3302-8079f438f0ab@roeck-us.net>
Hi Guenter,
> I noticed that several watchdog drivers stop the watchdog in trhe driver
> remove function.
> A non-exhaustive list of drivers doing that is
>
> drivers/watchdog/bcm7038_wdt.c
> drivers/watchdog/cadence_wdt.c
> drivers/watchdog/imgpdc_wdt.c
> drivers/watchdog/jz4740_wdt.c
> drivers/watchdog/kempld_wdt.c
> drivers/watchdog/max77620_wdt.c
> drivers/watchdog/moxart_wdt.c
> drivers/watchdog/sama5d4_wdt.c
> drivers/watchdog/tangox_wdt.c
> drivers/watchdog/tegra_wdt.c
>
> Since a watchdog has to be closed for its driver to be removable, one
> situation
> where a watchdog is still running on unload is where the watchdog was
> opened but
> not closed properly (eg by killing the watchdog application, or if the
> 'nowayout'
> flag is set).
>
> Given that, does it even make sense to stop the watchdog in the remove
> function ?
> Should it even be permitted ?
>From an API point of view: if WDIOF_MAGICCLOSE is being used then the watchdog
_SHOULD_ continue to run when the watchdog was not properly closed (which
normally also results in a reboot of the system).
if WDIOF_MAGICCLOSE is not being used then closing the watchdog device means
that the driver needs to stop the watchdog.
Kind regards and happy new year to you all,
Wim.
next prev parent reply other threads:[~2017-01-01 11:14 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-31 19:44 Guenter Roeck
2017-01-01 11:14 ` Wim Van Sebroeck [this message]
2017-01-01 15:24 ` Andy Shevchenko
2017-01-01 16:52 ` Guenter Roeck
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=20170101111421.GA9695@spo001.leaseweb.nl \
--to=wim@iguana.be \
--cc=justinpopo6@gmail.com \
--cc=ldewangan@nvidia.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=mans@mansr.com \
--cc=naidu.tellapati@gmail.com \
--cc=wenyou.yang@atmel.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
all inboxes | Powered by JetHome®