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
Kirill Smelkov
linux
Commits
c5faa90f
Commit
c5faa90f
authored
May 07, 2003
by
Hanna V. Linder
Committed by
Greg Kroah-Hartman
May 07, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] pcxx tty_driver add .owner field remove MOD_INC/DEC_USE_COUNT
parent
fda3b647
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
5 deletions
+1
-5
drivers/char/pcxx.c
drivers/char/pcxx.c
+1
-5
No files found.
drivers/char/pcxx.c
View file @
c5faa90f
...
@@ -431,8 +431,6 @@ int pcxe_open(struct tty_struct *tty, struct file * filp)
...
@@ -431,8 +431,6 @@ int pcxe_open(struct tty_struct *tty, struct file * filp)
return
(
-
ENODEV
);
return
(
-
ENODEV
);
}
}
/* flag the kernel that there is somebody using this guy */
MOD_INC_USE_COUNT
;
/*
/*
* If the device is in the middle of being closed, then block
* If the device is in the middle of being closed, then block
* until it's done, and then try again.
* until it's done, and then try again.
...
@@ -576,7 +574,6 @@ static void pcxe_close(struct tty_struct * tty, struct file * filp)
...
@@ -576,7 +574,6 @@ static void pcxe_close(struct tty_struct * tty, struct file * filp)
if
(
tty_hung_up_p
(
filp
))
{
if
(
tty_hung_up_p
(
filp
))
{
/* flag that somebody is done with this module */
/* flag that somebody is done with this module */
MOD_DEC_USE_COUNT
;
restore_flags
(
flags
);
restore_flags
(
flags
);
return
;
return
;
}
}
...
@@ -594,7 +591,6 @@ static void pcxe_close(struct tty_struct * tty, struct file * filp)
...
@@ -594,7 +591,6 @@ static void pcxe_close(struct tty_struct * tty, struct file * filp)
}
}
if
(
info
->
count
--
>
1
)
{
if
(
info
->
count
--
>
1
)
{
restore_flags
(
flags
);
restore_flags
(
flags
);
MOD_DEC_USE_COUNT
;
return
;
return
;
}
}
if
(
info
->
count
<
0
)
{
if
(
info
->
count
<
0
)
{
...
@@ -651,7 +647,6 @@ static void pcxe_close(struct tty_struct * tty, struct file * filp)
...
@@ -651,7 +647,6 @@ static void pcxe_close(struct tty_struct * tty, struct file * filp)
info
->
asyncflags
&=
~
(
ASYNC_NORMAL_ACTIVE
|
info
->
asyncflags
&=
~
(
ASYNC_NORMAL_ACTIVE
|
ASYNC_CALLOUT_ACTIVE
|
ASYNC_CLOSING
);
ASYNC_CALLOUT_ACTIVE
|
ASYNC_CLOSING
);
wake_up_interruptible
(
&
info
->
close_wait
);
wake_up_interruptible
(
&
info
->
close_wait
);
MOD_DEC_USE_COUNT
;
restore_flags
(
flags
);
restore_flags
(
flags
);
}
}
}
}
...
@@ -1228,6 +1223,7 @@ int __init pcxe_init(void)
...
@@ -1228,6 +1223,7 @@ int __init pcxe_init(void)
memset
(
&
pcxe_driver
,
0
,
sizeof
(
struct
tty_driver
));
memset
(
&
pcxe_driver
,
0
,
sizeof
(
struct
tty_driver
));
pcxe_driver
.
magic
=
TTY_DRIVER_MAGIC
;
pcxe_driver
.
magic
=
TTY_DRIVER_MAGIC
;
pcxe_driver
.
owner
=
THIS_MODULE
;
pcxe_driver
.
name
=
"ttyD"
;
pcxe_driver
.
name
=
"ttyD"
;
pcxe_driver
.
major
=
DIGI_MAJOR
;
pcxe_driver
.
major
=
DIGI_MAJOR
;
pcxe_driver
.
minor_start
=
0
;
pcxe_driver
.
minor_start
=
0
;
...
...
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