From: Jordan Crouse <jordan.crouse@amd.com>
To: Lennart Sorensen <lsorense@csclub.uwaterloo.ca>
Cc: David Brigada <brigad@rpi.edu>, Ingo Molnar <mingo@elte.hu>,
Wim Van Sebroeck <wim@iguana.be>,
Linus Torvalds <torvalds@linux-foundation.org>,
Andrew Morton <akpm@linux-foundation.org>,
LKML <linux-kernel@vger.kernel.org>,
Samuel Tardieu <sam@rfc1149.net>,
Mike Frysinger <vapier.adi@gmail.com>,
Mingarelli@infomag.amd.com
Subject: Re: drivers/watchdog/geodewdt.c: build fix
Date: Fri, 30 May 2008 10:48:39 -0600 [thread overview]
Message-ID: <20080530164839.GA13959@cosmic.amd.com> (raw)
In-Reply-To: <20080530162442.GB16164@csclub.uwaterloo.ca>
On 30/05/08 12:24 -0400, Lennart Sorensen wrote:
> On Fri, May 30, 2008 at 10:05:05AM -0600, Jordan Crouse wrote:
> > I think the hamster dropping code is queued for 2.6.27, so at least we're
> > up to mammals.
> >
> > The story here is that in an unfortunate instance of bad planning the
> > MFGPT timers can only be configured once, so a module can't allocate a
> > timer at init and release it when it is done. The original object of this
> > code was to try give the timer back to a module if it happened to go away
> > and come back, but that is clearly a more complex process then just simply
> > storing the module name, and this code fell into bitrot.
>
> It is a bit unfortunate that someone decided to design 'configure once'
> hardware. What were they thinking?
Agreed, very sub-optimal. For all those prospective silicon vendors out
there, this is a good lesson. Always let your software people review
the specification before you freeze the RTL - it will save you grief in
the long run. </sermon>
> I run a watchdog using the mfgpt, and I simply tore out the code that
> prevents reuse of the timers, and I decided which timers I am going to
> use for which purpose and never reuse them for anything else, so the
> parts of the configuration in the hardware that is fixed isn't an issue
> then. I start the watchdog from grub, so I had to override the check
> when the kernel takes over the timer watchdog management after all.
I expect that this will be the primary usage model - every platform needs to
have a gentleman's agreement for how the timers are allocated and used.
> > So its not so much that we need to drop module support, rather it needs to
> > be understood that if you remove and insert your module on a regular basis
> > you will run out of timers, and deprive others of the timers too. I think
> > that is a reasonable restriction to impose, given the limited usefulness
> > of these timers for general purpose use.
>
> They are useful timers, but yes perhaps not for general purpose. As a
> source of interrupts at certain intervals or as a watchdog they are not
> too bad.
For the longest time, I thought they were only good as a watchdog or
driving an external output. I had to eat some crow when we figured out
that we could use them as the tick source for tickless, so I no longer say
that they won't be good for anything else, but their usefulness is
certainly limited.
--
Jordan Crouse
Systems Software Development Engineer
Advanced Micro Devices, Inc.
prev parent reply other threads:[~2008-05-30 16:47 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-25 10:09 [WATCHDOG] v2.6.26-rc3 patches Wim Van Sebroeck
2008-05-25 10:08 ` Alan Cox
2008-05-25 17:05 ` Wim Van Sebroeck
2008-05-30 15:02 ` [patch] drivers/watchdog/geodewdt.c: build fix Ingo Molnar
2008-05-30 15:39 ` Jordan Crouse
2008-05-30 15:54 ` David Brigada
2008-05-30 16:05 ` Jordan Crouse
2008-05-30 16:24 ` Lennart Sorensen
2008-05-30 16:48 ` Jordan Crouse [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=20080530164839.GA13959@cosmic.amd.com \
--to=jordan.crouse@amd.com \
--cc=Mingarelli@infomag.amd.com \
--cc=akpm@linux-foundation.org \
--cc=brigad@rpi.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=lsorense@csclub.uwaterloo.ca \
--cc=mingo@elte.hu \
--cc=sam@rfc1149.net \
--cc=torvalds@linux-foundation.org \
--cc=vapier.adi@gmail.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