Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci
Commits
5d1e3230
Commit
5d1e3230
authored
Jun 19, 2008
by
Jonathan Corbet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tty_io: fasync BKL pushdown
Signed-off-by:
Jonathan Corbet
<
corbet@lwn.net
>
parent
9d319522
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
5 deletions
+9
-5
drivers/char/tty_io.c
drivers/char/tty_io.c
+9
-5
No files found.
drivers/char/tty_io.c
View file @
5d1e3230
...
...
@@ -2909,15 +2909,16 @@ static int tty_fasync(int fd, struct file *filp, int on)
{
struct
tty_struct
*
tty
;
unsigned
long
flags
;
int
retval
;
int
retval
=
0
;
lock_kernel
();
tty
=
(
struct
tty_struct
*
)
filp
->
private_data
;
if
(
tty_paranoia_check
(
tty
,
filp
->
f_path
.
dentry
->
d_inode
,
"tty_fasync"
))
return
0
;
goto
out
;
retval
=
fasync_helper
(
fd
,
filp
,
on
,
&
tty
->
fasync
);
if
(
retval
<=
0
)
return
retval
;
goto
out
;
if
(
on
)
{
enum
pid_type
type
;
...
...
@@ -2935,12 +2936,15 @@ static int tty_fasync(int fd, struct file *filp, int on)
spin_unlock_irqrestore
(
&
tty
->
ctrl_lock
,
flags
);
retval
=
__f_setown
(
filp
,
pid
,
type
,
0
);
if
(
retval
)
return
retval
;
goto
out
;
}
else
{
if
(
!
tty
->
fasync
&&
!
waitqueue_active
(
&
tty
->
read_wait
))
tty
->
minimum_to_wake
=
N_TTY_BUF_SIZE
;
}
return
0
;
retval
=
0
;
out:
unlock_kernel
();
return
retval
;
}
/**
...
...
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