pcwd-watchdog.txt 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. Last reviewed: 10/05/2007
  2. Berkshire Products PC Watchdog Card
  3. Support for ISA Cards Revision A and C
  4. Documentation and Driver by Ken Hollis <kenji@bitgate.com>
  5. The PC Watchdog is a card that offers the same type of functionality that
  6. the WDT card does, only it doesn't require an IRQ to run. Furthermore,
  7. the Revision C card allows you to monitor any IO Port to automatically
  8. trigger the card into being reset. This way you can make the card
  9. monitor hard drive status, or anything else you need.
  10. The Watchdog Driver has one basic role: to talk to the card and send
  11. signals to it so it doesn't reset your computer ... at least during
  12. normal operation.
  13. The Watchdog Driver will automatically find your watchdog card, and will
  14. attach a running driver for use with that card. After the watchdog
  15. drivers have initialized, you can then talk to the card using a PC
  16. Watchdog program.
  17. I suggest putting a "watchdog -d" before the beginning of an fsck, and
  18. a "watchdog -e -t 1" immediately after the end of an fsck. (Remember
  19. to run the program with an "&" to run it in the background!)
  20. If you want to write a program to be compatible with the PC Watchdog
  21. driver, simply use of modify the watchdog test program:
  22. Documentation/watchdog/src/watchdog-test.c
  23. Other IOCTL functions include:
  24. WDIOC_GETSUPPORT
  25. This returns the support of the card itself. This
  26. returns in structure "PCWDS" which returns:
  27. options = WDIOS_TEMPPANIC
  28. (This card supports temperature)
  29. firmware_version = xxxx
  30. (Firmware version of the card)
  31. WDIOC_GETSTATUS
  32. This returns the status of the card, with the bits of
  33. WDIOF_* bitwise-anded into the value. (The comments
  34. are in linux/pcwd.h)
  35. WDIOC_GETBOOTSTATUS
  36. This returns the status of the card that was reported
  37. at bootup.
  38. WDIOC_GETTEMP
  39. This returns the temperature of the card. (You can also
  40. read /dev/watchdog, which gives a temperature update
  41. every second.)
  42. WDIOC_SETOPTIONS
  43. This lets you set the options of the card. You can either
  44. enable or disable the card this way.
  45. WDIOC_KEEPALIVE
  46. This pings the card to tell it not to reset your computer.
  47. And that's all she wrote!
  48. -- Ken Hollis
  49. (kenji@bitgate.com)