Skip to content

Commit

Permalink
f2fs: should update REQ_TIME for direct write
Browse files Browse the repository at this point in the history
The sending interval of discard and GC should also
consider direct write requests; filesystem is not
idle if there is direct write.

Signed-off-by: Zhiguo Niu <[email protected]>
Reviewed-by: Chao Yu <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
  • Loading branch information
Zhiguo Niu authored and Jaegeuk Kim committed Aug 14, 2023
1 parent 624bb99 commit e5997e9
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fs/f2fs/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -4568,6 +4568,7 @@ static int f2fs_dio_write_end_io(struct kiocb *iocb, ssize_t size, int error,
dec_page_count(sbi, F2FS_DIO_WRITE);
if (error)
return error;
f2fs_update_time(sbi, REQ_TIME);
f2fs_update_iostat(sbi, NULL, APP_DIRECT_IO, size);
return 0;
}
Expand Down

0 comments on commit e5997e9

Please sign in to comment.