From: Giel van Schijndel <me@mortis.eu>
To: Lutz Ballaschke <vegan.grindcore@googlemail.com>
Cc: wim@iguana.be, linux-watchdog@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCHv3 2/3] watchdog: add f71862fg support
Date: Sun, 26 Sep 2010 17:19:47 +0200 [thread overview]
Message-ID: <20100926151947.GD7185@salidar.me.mortis.eu> (raw)
In-Reply-To: <20100926143241.GC2150@kreios.titan>
[-- Attachment #1: Type: text/plain, Size: 1057 bytes --]
On Sun, Sep 26, 2010 at 04:32:41PM +0200, Lutz Ballaschke wrote:
> ioctl WDIOC_GETTIMELEFT and helper function added to watchdog driver
> for common usage.
>
> ... snip ...
>
> +static int watchdog_time_left(void)
> +{
> + int ret = 0;
> +
> + mutex_lock(&watchdog.lock);
> + ret = superio_enter(watchdog.sioaddr);
> + if (ret)
> + goto exit_unlock;
> +
> + superio_select(watchdog.sioaddr, SIO_F71808FG_LD_WDT);
> + ret = superio_inb(watchdog.sioaddr, F71808FG_REG_WD_TIME);
> + superio_exit(watchdog.sioaddr);
> +
> +exit_unlock:
> + mutex_unlock(&watchdog.lock);
> + return ret;
> +}
This function still has the problem I described earlier, namely that of
returning minutes to userspace (which expects seconds) when minutes_mode
is true.
I would thus suggest not to commit this patch as it violates the
Watchdog API.
--
Met vriendelijke groet,
With kind regards,
Giel van Schijndel
--
"There are only two kinds of languages: the ones people complain about
and the ones nobody uses."
-- Bjarne Stroustrup
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
prev parent reply other threads:[~2010-09-26 15:19 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-26 14:32 [PATCHv3 2/3] watchdog: add f71862fg support Lutz Ballaschke
2010-09-26 15:19 ` Giel van Schijndel [this message]
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=20100926151947.GD7185@salidar.me.mortis.eu \
--to=me@mortis.eu \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=vegan.grindcore@googlemail.com \
--cc=wim@iguana.be \
/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).