projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d0b040f
)
ext4: remove redundant check buffer_uptodate()
author
Joseph Qi
<joseph.qi@linux.alibaba.com>
Mon, 26 Apr 2021 06:29:47 +0000
(14:29 +0800)
committer
Theodore Ts'o
<tytso@mit.edu>
Thu, 17 Jun 2021 14:53:19 +0000
(10:53 -0400)
Now set_buffer_uptodate() will test first and then set, so we don't have
to check buffer_uptodate() first, remove it to simplify code.
Reviewed-by: Ritesh Harjani <riteshh@linux.ibm.com>
Signed-off-by: Joseph Qi <joseph.qi@linux.alibaba.com>
Link:
https://lore.kernel.org/r/1619418587-5580-1-git-send-email-joseph.qi@linux.alibaba.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/ext4.h
patch
|
blob
|
history
diff --git
a/fs/ext4/ext4.h
b/fs/ext4/ext4.h
index 37002663d521284341275ac4e4cce0dc5f406d48..639ab5405d6a6823505e090d66f67ab326c58783 100644
(file)
--- a/
fs/ext4/ext4.h
+++ b/
fs/ext4/ext4.h
@@
-3784,7
+3784,7
@@
static inline int ext4_buffer_uptodate(struct buffer_head *bh)
* have to read the block because we may read the old data
* successfully.
*/
- if (
!buffer_uptodate(bh) &&
buffer_write_io_error(bh))
+ if (buffer_write_io_error(bh))
set_buffer_uptodate(bh);
return buffer_uptodate(bh);
}