mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-05 06:08:22 +00:00
f2fs: do not skip any writes under memory pressure
Under memory pressure, let's avoid skipping data writes. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
parent
2f97c326bf
commit
510184c89f
1 changed files with 3 additions and 0 deletions
|
@ -711,6 +711,9 @@ static inline unsigned int max_hw_blocks(struct f2fs_sb_info *sbi)
|
|||
*/
|
||||
static inline int nr_pages_to_skip(struct f2fs_sb_info *sbi, int type)
|
||||
{
|
||||
if (sbi->sb->s_bdi->dirty_exceeded)
|
||||
return 0;
|
||||
|
||||
if (type == DATA)
|
||||
return sbi->blocks_per_seg;
|
||||
else if (type == NODE)
|
||||
|
|
Loading…
Add table
Reference in a new issue