[MinnowBoard] MinnowBoard Turbot Watchdog

Krau, Michael P michael.p.krau at intel.com
Fri Apr 8 21:06:03 UTC 2016


As a firmware developer, this is a possibility, but it is an extremely dangerous one.  

Basically, the firmware sets up an SMI (System Management Interrupt - which puts the processor into SMM - System Management Mode), on some timer tick.  Every time the timer ticks, a counter is incremented and checked.   If the counter is over the predefined maximum value, the SMM will force a reboot.   Since SMI is a completely non-maskable hardware interrupt, it will not be influenced by the OS.  (Which is why many OS developers do not like SMI/SMM - it can create "lost time" within systems)

The location of the counter is another interesting discussion, as it needs to be somewhere where the operating environment can get to it (not in SMM memory) but somewhere 'hardened enough that it does not get hijacked or overwritten outside of its use as watchdog.

The dangers are that every operating environment in the system (or that will be in the system), has to be aware to reset the counter (take it back to zero) on some loop, or eventually the timeout value will be reached, and the system will reset - again and again...  Which is John's 'panic' situation mentioned below.

This is a very advanced feature, and not on that would be added to the general MinnowBoard MAX production firmware as it would more likely create more usability issues than it resolves.  That said, it is something that could be custom added to the firmware by a specific customer for a specific firmware.  But that is a more of a personal project than a MinnowBoard MAX product feature. 


That said, I should mention that the E3825 (the processor in the MinnowBoard MAX/Turbot - in fact the whole family) does have a hardware watchdog timer, but it is very specific in design and function.  Information on the hardware watchdog can be found on Intel.com in the specification for the E3800 family processor.  

Thank you, 



Michael Krau
 

-----Original Message-----
From: elinux-MinnowBoard [mailto:elinux-minnowboard-bounces at lists.elinux.org] On Behalf Of John 'Warthog9' Hawley
Sent: Friday, April 08, 2016 1:17 PM
To: MinnowBoard Development and Community Discussion <elinux-minnowboard at lists.elinux.org>
Subject: Re: [MinnowBoard] MinnowBoard Turbot Watchdog

Under Linux there's a few things that can do this for you.  Is the worry more that the board is going to panic and crash, or that the program you are running is going to break?

On 04/08/2016 01:07 PM, Ken Tait wrote:
> It would be difficult to implement this using a standard, hardware 
> watchdog timer when running an OS like linux or windows. The reason is 
> there is no clear place to reset the watchdog since many threads will 
> be running. In an embedded system, the watchdog is usually only reset 
> once, in the 'main'. With an OS there is no main....
> 
> A better approach might be to start a chron timer at startup (which 
> will be the watchdog) ,which will trigger some kind of simple 
> flag/operation to check if your app is still running. Maybe checking 
> the pid of the app may be of some help. If your app is locked, then 
> the chron app can gracefully take the OS down and force a physical 
> reset. At least this way, any open files can get flushed and not screw up the inode tables.
> 
> just a thought
> Ken
> 
> _______________________________________________
> elinux-MinnowBoard mailing list
> elinux-MinnowBoard at lists.elinux.org
> http://lists.elinux.org/mailman/listinfo/elinux-minnowboard
> 

_______________________________________________
elinux-MinnowBoard mailing list
elinux-MinnowBoard at lists.elinux.org
http://lists.elinux.org/mailman/listinfo/elinux-minnowboard


More information about the elinux-MinnowBoard mailing list