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
61144378
Commit
61144378
authored
Aug 26, 2012
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
switch fadvise(2) to fget_light()
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
d6483b7a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
mm/fadvise.c
mm/fadvise.c
+3
-2
No files found.
mm/fadvise.c
View file @
61144378
...
...
@@ -26,7 +26,8 @@
*/
SYSCALL_DEFINE
(
fadvise64_64
)(
int
fd
,
loff_t
offset
,
loff_t
len
,
int
advice
)
{
struct
file
*
file
=
fget
(
fd
);
int
fput_needed
;
struct
file
*
file
=
fget_light
(
fd
,
&
fput_needed
);
struct
address_space
*
mapping
;
struct
backing_dev_info
*
bdi
;
loff_t
endbyte
;
/* inclusive */
...
...
@@ -128,7 +129,7 @@ SYSCALL_DEFINE(fadvise64_64)(int fd, loff_t offset, loff_t len, int advice)
ret
=
-
EINVAL
;
}
out:
fput
(
file
);
fput
_light
(
file
,
fput_needed
);
return
ret
;
}
#ifdef CONFIG_HAVE_SYSCALL_WRAPPERS
...
...
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