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
4a7f4e88
Commit
4a7f4e88
authored
Jul 29, 2016
by
Miklos Szeredi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fuse: use filemap_check_errors()
Signed-off-by:
Miklos Szeredi
<
mszeredi@redhat.com
>
parent
d72d9e2a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
12 deletions
+2
-12
fs/fuse/file.c
fs/fuse/file.c
+2
-12
No files found.
fs/fuse/file.c
View file @
4a7f4e88
...
@@ -417,12 +417,7 @@ static int fuse_flush(struct file *file, fl_owner_t id)
...
@@ -417,12 +417,7 @@ static int fuse_flush(struct file *file, fl_owner_t id)
fuse_sync_writes
(
inode
);
fuse_sync_writes
(
inode
);
inode_unlock
(
inode
);
inode_unlock
(
inode
);
if
(
test_bit
(
AS_ENOSPC
,
&
file
->
f_mapping
->
flags
)
&&
err
=
filemap_check_errors
(
file
->
f_mapping
);
test_and_clear_bit
(
AS_ENOSPC
,
&
file
->
f_mapping
->
flags
))
err
=
-
ENOSPC
;
if
(
test_bit
(
AS_EIO
,
&
file
->
f_mapping
->
flags
)
&&
test_and_clear_bit
(
AS_EIO
,
&
file
->
f_mapping
->
flags
))
err
=
-
EIO
;
if
(
err
)
if
(
err
)
return
err
;
return
err
;
...
@@ -477,12 +472,7 @@ int fuse_fsync_common(struct file *file, loff_t start, loff_t end,
...
@@ -477,12 +472,7 @@ int fuse_fsync_common(struct file *file, loff_t start, loff_t end,
* filemap_write_and_wait_range() does not catch errors.
* filemap_write_and_wait_range() does not catch errors.
* We have to do this directly after fuse_sync_writes()
* We have to do this directly after fuse_sync_writes()
*/
*/
if
(
test_bit
(
AS_ENOSPC
,
&
file
->
f_mapping
->
flags
)
&&
err
=
filemap_check_errors
(
file
->
f_mapping
);
test_and_clear_bit
(
AS_ENOSPC
,
&
file
->
f_mapping
->
flags
))
err
=
-
ENOSPC
;
if
(
test_bit
(
AS_EIO
,
&
file
->
f_mapping
->
flags
)
&&
test_and_clear_bit
(
AS_EIO
,
&
file
->
f_mapping
->
flags
))
err
=
-
EIO
;
if
(
err
)
if
(
err
)
goto
out
;
goto
out
;
...
...
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