LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 11-07-2019, 09:43 PM   #1
Arul Jeniston
LQ Newbie
 
Registered: Nov 2019
Posts: 1

Rep: Reputation: Disabled
how to find last reboot caused by TCO watchdog


hi Team,

We use intel TCO hardware watchdog to recover the system from unexpected software hangs and hardware issues.
We have a requirement to show TCO watchdog caused last reboot.
Intel spec says, TCO1_STS and TCO2_STS register has the bits set if watchdog resets the CPU. We do observe the same in our testing.
But during iTCO driver initialization in iTCO_wdt_probe(). This puts a limitation in reading the reason for previous reboot.

- Is there any other way to find previous reboot caused by watchdog?

- Can be the value of TCO_STS registers saved in RAM before clearing it? This would help us to find that the cpu was reset by watchdog during previous run.

static int iTCO_wdt_probe(struct platform_device *pdev)
{
...
...
switch (p->iTCO_version) {
case 5:
case 4:
outw(0x0008, TCO1_STS(p)); /* Clear the Time Out Status bit */
outw(0x0002, TCO2_STS(p)); /* Clear SECOND_TO_STS bit */
break;
case 3:
outl(0x20008, TCO1_STS(p));
break;
case 2:
case 1:
default:
outw(0x0008, TCO1_STS(p)); /* Clear the Time Out Status bit */
outw(0x0002, TCO2_STS(p)); /* Clear SECOND_TO_STS bit */
outw(0x0004, TCO2_STS(p)); /* Clear BOOT_STS bit */
break;
}

Thanks and Regards,
Arul
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Get first day of last month and last day of last month in bash xowl Linux - Software 18 02-09-2017 09:49 AM
[FYI] "last -f <old wtmp> -x reboot shutdown" incorrect for last reboot and shutdown catkin Linux - General 1 03-25-2010 11:52 PM
Intel's watchdog support iTCO_wdt - does this mean watchdog is not present? kushalkoolwal Linux - Hardware 3 02-06-2009 03:16 PM
Hardware watchdog in BIOS and Linux watchdog driver are different? travishein Linux - Hardware 1 12-22-2008 09:41 PM
Spurious Reboot - How Can I Find Out What Caused It john.morris Linux - General 2 12-12-2005 12:01 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 09:07 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration