#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/types.h>
#include <linux/kernel.h>
#include <linux/fs.h>
#include <linux/mm.h>
#include <linux/reboot.h>
#include <linux/init.h>
#include <linux/delay.h>
#include <asm/uaccess.h>
#include <linux/sysrq.h>
#include <linux/timer.h>
#include <linux/time.h>
Go to the source code of this file.
|
| module_param (hangcheck_tick, int, 0) |
|
| MODULE_PARM_DESC (hangcheck_tick,"Timer delay.") |
|
| module_param (hangcheck_margin, int, 0) |
|
| MODULE_PARM_DESC (hangcheck_margin,"If the hangcheck timer has been delayed more than hangcheck_margin seconds, the driver will fire.") |
|
| module_param (hangcheck_reboot, int, 0) |
|
| MODULE_PARM_DESC (hangcheck_reboot,"If nonzero, the machine will reboot when the timer margin is exceeded.") |
|
| module_param (hangcheck_dump_tasks, int, 0) |
|
| MODULE_PARM_DESC (hangcheck_dump_tasks,"If nonzero, the machine will dump the system task state when the timer margin is exceeded.") |
|
| MODULE_AUTHOR ("Oracle") |
|
| MODULE_DESCRIPTION ("Hangcheck-timer detects when the system has gone out to lunch past a certain margin.") |
|
| MODULE_LICENSE ("GPL") |
|
| MODULE_VERSION (VERSION_STR) |
|
| __setup ("hcheck_tick", hangcheck_parse_tick) |
|
| __setup ("hcheck_margin", hangcheck_parse_margin) |
|
| __setup ("hcheck_reboot", hangcheck_parse_reboot) |
|
| __setup ("hcheck_dump_tasks", hangcheck_parse_dump_tasks) |
|
| module_init (hangcheck_init) |
|
| module_exit (hangcheck_exit) |
|
#define TIMER_FREQ 1000000000ULL |
#define VERSION_STR "0.9.1" |
__setup |
( |
"hcheck_tick" |
, |
|
|
hangcheck_parse_tick |
|
|
) |
| |
__setup |
( |
"hcheck_margin" |
, |
|
|
hangcheck_parse_margin |
|
|
) |
| |
__setup |
( |
"hcheck_reboot" |
, |
|
|
hangcheck_parse_reboot |
|
|
) |
| |
__setup |
( |
"hcheck_dump_tasks" |
, |
|
|
hangcheck_parse_dump_tasks |
|
|
) |
| |
MODULE_AUTHOR |
( |
"Oracle" |
| ) |
|
MODULE_DESCRIPTION |
( |
"Hangcheck-timer detects when the system has gone out to lunch past a certain margin." |
| ) |
|
module_exit |
( |
hangcheck_exit |
| ) |
|
module_init |
( |
hangcheck_init |
| ) |
|
module_param |
( |
hangcheck_tick |
, |
|
|
int |
, |
|
|
0 |
|
|
) |
| |
module_param |
( |
hangcheck_margin |
, |
|
|
int |
, |
|
|
0 |
|
|
) |
| |
module_param |
( |
hangcheck_reboot |
, |
|
|
int |
, |
|
|
0 |
|
|
) |
| |
module_param |
( |
hangcheck_dump_tasks |
, |
|
|
int |
, |
|
|
0 |
|
|
) |
| |
MODULE_PARM_DESC |
( |
hangcheck_tick |
, |
|
|
"Timer delay." |
|
|
) |
| |
MODULE_PARM_DESC |
( |
hangcheck_margin |
, |
|
|
"If the hangcheck timer has been delayed more than hangcheck_margin |
seconds, |
|
|
the driver will fire." |
|
|
) |
| |
MODULE_PARM_DESC |
( |
hangcheck_reboot |
, |
|
|
"If |
nonzero, |
|
|
the machine will reboot when the timer margin is exceeded." |
|
|
) |
| |