Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
6a4667e8
Commit
6a4667e8
authored
Jan 10, 2003
by
Dave Jones
Committed by
Dave Jones
Jan 10, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[WATCHDOG] SC520 nowayout fixes from 2.4
parent
15e13a00
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
12 deletions
+21
-12
drivers/char/watchdog/sc520_wdt.c
drivers/char/watchdog/sc520_wdt.c
+21
-12
No files found.
drivers/char/watchdog/sc520_wdt.c
View file @
6a4667e8
...
@@ -110,6 +110,15 @@ static unsigned long next_heartbeat;
...
@@ -110,6 +110,15 @@ static unsigned long next_heartbeat;
static
unsigned
long
wdt_is_open
;
static
unsigned
long
wdt_is_open
;
static
int
wdt_expect_close
;
static
int
wdt_expect_close
;
#ifdef CONFIG_WATCHDOG_NOWAYOUT
static
int
nowayout
=
1
;
#else
static
int
nowayout
=
0
;
#endif
MODULE_PARM
(
nowayout
,
"i"
);
MODULE_PARM_DESC
(
nowayout
,
"Watchdog cannot be stopped once started (default=CONFIG_WATCHDOG_NOWAYOUT)"
);
static
spinlock_t
wdt_spinlock
;
static
spinlock_t
wdt_spinlock
;
/*
/*
* Whack the dog
* Whack the dog
...
@@ -172,12 +181,12 @@ static void wdt_startup(void)
...
@@ -172,12 +181,12 @@ static void wdt_startup(void)
static
void
wdt_turnoff
(
void
)
static
void
wdt_turnoff
(
void
)
{
{
#ifndef CONFIG_WATCHDOG_NOWAYOUT
if
(
!
nowayout
)
{
/* Stop the timer */
/* Stop the timer */
del_timer
(
&
timer
);
del_timer
(
&
timer
);
wdt_config
(
0
);
wdt_config
(
0
);
printk
(
OUR_NAME
": Watchdog timer is now disabled...
\n
"
);
printk
(
OUR_NAME
": Watchdog timer is now disabled...
\n
"
);
#endif
}
}
}
...
@@ -226,9 +235,9 @@ static int fop_open(struct inode * inode, struct file * file)
...
@@ -226,9 +235,9 @@ static int fop_open(struct inode * inode, struct file * file)
return
-
EBUSY
;
return
-
EBUSY
;
/* Good, fire up the show */
/* Good, fire up the show */
wdt_startup
();
wdt_startup
();
#ifdef CONFIG_WATCHDOG_NOWAYOUT
if
(
nowayout
)
MOD_INC_USE_COUNT
;
MOD_INC_USE_COUNT
;
#endif
return
0
;
return
0
;
default:
default:
return
-
ENODEV
;
return
-
ENODEV
;
...
@@ -260,9 +269,9 @@ static int fop_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
...
@@ -260,9 +269,9 @@ static int fop_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
{
{
static
struct
watchdog_info
ident
=
static
struct
watchdog_info
ident
=
{
{
0
,
.
options
=
WDIOF_MAGICCLOSE
,
1
,
.
firmware_version
=
1
,
"SC520"
.
identity
=
"SC520"
};
};
switch
(
cmd
)
switch
(
cmd
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment