From: Timur Tabi <b04825@freescale.com>
To: Josh Boyer <jwboyer@gmail.com>
Cc: "linuxppc-dev@lists.ozlabs.org" <linuxppc-dev@lists.ozlabs.org>,
Jiang Lu <lu.jiang@windriver.com>
Subject: Re: [PATCH] ppc44x/watchdog: Select WATCHDOG_NOWAYOUT option
Date: Mon, 16 Jul 2012 16:03:04 -0500 [thread overview]
Message-ID: <50048188.8060409@freescale.com> (raw)
In-Reply-To: <CA+5PVA7WSTK9Ad7yocSrsnFcsp7L1hyzJjKrWkKU7Yak=2ZoZg@mail.gmail.com>
Josh Boyer wrote:
> I have no idea about FSL cores, but the 4xx maximum value selects TBU
> bit 31. When that bit flips is going to be determined by the speed of
> the clock driving TB. Most of the 4xx implementations I have seen use
> the CPU clock, so to take the example from the 44x user manuals, a 400
> MHz clock results in a maximum time period of ~21 seconds. Multiply
> by 3 to get the time before the WDT actually does a reset and you're
> at about 1min.
Ah, that is a problem.
> NOWAYOUT is working. The patch was basically forcing it on, even if
> the end user doesn't want the behavior described. From what you've
> said, that simply doesn't matter in the FSL case because the machine
> will run for a really long time. On 4xx, something needs to be done
> to keep the machine running if the user doesn't want the NOWAYOUT
> behavior, which is why I suggested a kernel timer.
Yes, I agree now -- a kernel timer is a better idea. And it doesn't need
to be 4xx-specific. Although, I wonder if it's the time is reliable enough.
We already have an exception handler:
#ifdef CONFIG_BOOKE_WDT
/*
* Default handler for a Watchdog exception,
* spins until a reboot occurs
*/
void __attribute__ ((weak)) WatchdogHandler(struct pt_regs *regs)
{
/* Generic WatchdogHandler, implement your own */
mtspr(SPRN_TCR, mfspr(SPRN_TCR)&(~TCR_WIE));
return;
}
void WatchdogException(struct pt_regs *regs)
{
printk (KERN_EMERG "PowerPC Book-E Watchdog Exception\n");
WatchdogHandler(regs);
}
#endif
Maybe instead of disabling interrupts, we should ping the watchdog instead?
--
Timur Tabi
Linux kernel developer at Freescale
next prev parent reply other threads:[~2012-07-16 21:03 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-13 2:44 [PATCH] ppc44x/watchdog: Select WATCHDOG_NOWAYOUT option Jiang Lu
2012-07-13 11:50 ` Kumar Gala
2012-07-13 12:25 ` Josh Boyer
2012-07-13 12:52 ` Kumar Gala
2012-07-16 20:28 ` Tabi Timur-B04825
2012-07-16 20:57 ` Josh Boyer
2012-07-16 21:03 ` Timur Tabi [this message]
2012-07-16 2:07 ` Lu.Jiang
2012-07-16 14:43 ` Scott Wood
2012-07-16 20:30 ` Tabi Timur-B04825
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=50048188.8060409@freescale.com \
--to=b04825@freescale.com \
--cc=jwboyer@gmail.com \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=lu.jiang@windriver.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 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.