#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/types.h>
#include <linux/errno.h>
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/timer.h>
#include <linux/jiffies.h>
#include <linux/miscdevice.h>
#include <linux/watchdog.h>
#include <linux/reboot.h>
#include <linux/init.h>
#include <linux/fs.h>
#include <linux/isa.h>
#include <linux/ioport.h>
#include <linux/spinlock.h>
#include <linux/uaccess.h>
#include <linux/io.h>
Go to the source code of this file.
|
| module_param (debug, int, 0) |
|
| MODULE_PARM_DESC (debug,"Debug level: 0=Quiet, 1=Verbose, 2=Debug (default=0)") |
|
| module_param (heartbeat, int, 0) |
|
| MODULE_PARM_DESC (heartbeat,"Watchdog heartbeat in seconds. ""(2 <= heartbeat <= 7200 or 0=delay-time from dip-switches, default="__MODULE_STRING(WATCHDOG_HEARTBEAT)")") |
|
| module_param (nowayout, bool, 0) |
|
| MODULE_PARM_DESC (nowayout,"Watchdog cannot be stopped once started (default="__MODULE_STRING(WATCHDOG_NOWAYOUT)")") |
|
| module_init (pcwd_init_module) |
|
| module_exit (pcwd_cleanup_module) |
|
| MODULE_AUTHOR ("Ken Hollis <[email protected]>, ""Wim Van Sebroeck <[email protected]>") |
|
| MODULE_DESCRIPTION ("Berkshire ISA-PC Watchdog driver") |
|
| MODULE_VERSION (WATCHDOG_VERSION) |
|
| MODULE_LICENSE ("GPL") |
|
| MODULE_ALIAS_MISCDEV (WATCHDOG_MINOR) |
|
| MODULE_ALIAS_MISCDEV (TEMP_MINOR) |
|
#define CMD_ISA_ARM_0 0x07 |
#define CMD_ISA_ARM_30 0x08 |
#define CMD_ISA_ARM_60 0x09 |
#define CMD_ISA_DELAY_TIME_2SECS 0x0A |
#define CMD_ISA_DELAY_TIME_4SECS 0x0B |
#define CMD_ISA_DELAY_TIME_8SECS 0x0C |
#define CMD_ISA_IDLE 0x00 |
#define CMD_ISA_RESET_PC 0x06 |
#define CMD_ISA_RESET_RELAYS 0x0D |
#define CMD_ISA_SWITCH_SETTINGS 0x05 |
#define CMD_ISA_VERSION_HUNDRETH 0x03 |
#define CMD_ISA_VERSION_INTEGER 0x01 |
#define CMD_ISA_VERSION_MINOR 0x04 |
#define CMD_ISA_VERSION_TENTH 0x02 |
#define DEBUG 2 /* print fancy stuff too */ |
#define ISA_COMMAND_TIMEOUT 1000 |
#define PCWD_ISA_NR_CARDS 3 |
#define PCWD_REVISION_A 1 |
#define PCWD_REVISION_C 2 |
#define pr_fmt |
( |
|
fmt | ) |
KBUILD_MODNAME ": " fmt |
#define VERBOSE 1 /* Verbose */ |
#define WATCHDOG_DATE "18 Feb 2007" |
#define WATCHDOG_DRIVER_NAME "ISA-PC Watchdog" |
#define WATCHDOG_HEARTBEAT 0 |
#define WATCHDOG_NAME "pcwd" |
#define WATCHDOG_VERSION "1.20" |
#define WD_ENTP 0x20 /* Watchdog Enable Temperature Trip */ |
#define WD_HRTBT 0x04 /* Heartbeat sense */ |
#define WD_REVC_HRBT 0x02 /* Watchdog Heartbeat */ |
#define WD_REVC_R2DS 0x40 /* Relay 2 disable */ |
#define WD_REVC_RL1A 0x10 /* Relay 1 active */ |
Value:
Definition at line 115 of file pcwd.c.
#define WD_REVC_RLY2 0x80 /* Relay 2 activated? */ |
#define WD_REVC_TTRP 0x04 /* Temperature Trip status */ |
#define WD_REVC_WTRP 0x01 /* Watchdog Trip status */ |
#define WD_RLY2 0x08 /* External relay triggered */ |
#define WD_SRLY2 0x80 /* Software external relay triggered */ |
Value:
Definition at line 122 of file pcwd.c.
#define WD_T110 0x02 /* Temperature overheat sense */ |
#define WD_WCMD 0x80 /* Watchdog Command Mode */ |
#define WD_WDIS 0x10 /* Watchdog Disabled */ |
#define WD_WDRST 0x01 /* Previously reset state */ |
#define WDT_INTERVAL (HZ/2+1) |
MODULE_AUTHOR |
( |
"Ken Hollis <[email protected]> |
, |
|
|
""Wim Van Sebroeck< wim @iguana.be >" |
|
|
) |
| |
MODULE_DESCRIPTION |
( |
"Berkshire ISA-PC Watchdog driver" |
| ) |
|
module_exit |
( |
pcwd_cleanup_module |
| ) |
|
module_init |
( |
pcwd_init_module |
| ) |
|
module_param |
( |
nowayout |
, |
|
|
bool |
, |
|
|
0 |
|
|
) |
| |
MODULE_PARM_DESC |
( |
debug |
, |
|
|
"Debug level: |
0 = Quiet , |
|
|
1 |
= Verbose |
|
) |
| |
unsigned long next_heartbeat |