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
6b6dabc8
Commit
6b6dabc8
authored
Jun 21, 2015
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
nilfs2_direct_IO(): remove dead code
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
2726d566
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
20 deletions
+2
-20
fs/nilfs2/inode.c
fs/nilfs2/inode.c
+2
-20
No files found.
fs/nilfs2/inode.c
View file @
6b6dabc8
...
...
@@ -307,31 +307,13 @@ static int nilfs_write_end(struct file *file, struct address_space *mapping,
static
ssize_t
nilfs_direct_IO
(
struct
kiocb
*
iocb
,
struct
iov_iter
*
iter
,
loff_t
offset
)
{
struct
file
*
file
=
iocb
->
ki_filp
;
struct
address_space
*
mapping
=
file
->
f_mapping
;
struct
inode
*
inode
=
file
->
f_mapping
->
host
;
size_t
count
=
iov_iter_count
(
iter
);
ssize_t
size
;
struct
inode
*
inode
=
file_inode
(
iocb
->
ki_filp
);
if
(
iov_iter_rw
(
iter
)
==
WRITE
)
return
0
;
/* Needs synchronization with the cleaner */
size
=
blockdev_direct_IO
(
iocb
,
inode
,
iter
,
offset
,
nilfs_get_block
);
/*
* In case of error extending write may have instantiated a few
* blocks outside i_size. Trim these off again.
*/
if
(
unlikely
(
iov_iter_rw
(
iter
)
==
WRITE
&&
size
<
0
))
{
loff_t
isize
=
i_size_read
(
inode
);
loff_t
end
=
offset
+
count
;
if
(
end
>
isize
)
nilfs_write_failed
(
mapping
,
end
);
}
return
size
;
return
blockdev_direct_IO
(
iocb
,
inode
,
iter
,
offset
,
nilfs_get_block
);
}
const
struct
address_space_operations
nilfs_aops
=
{
...
...
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