diff options
author | Jaegeuk Kim <jaegeuk@kernel.org> | 2020-04-02 09:32:35 -0700 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2020-04-16 14:41:52 -0700 |
commit | da9953b729c12ece6d35fd15d236457eee679228 (patch) | |
tree | 22e0d5fad2f8ce942171705537e3bf5185f8b802 /fs/f2fs/sysfs.c | |
parent | 63bef48fd6c9d3f1ba4f0e23b4da1e007db6a3c0 (diff) | |
download | linux-da9953b729c12ece6d35fd15d236457eee679228.tar.gz linux-da9953b729c12ece6d35fd15d236457eee679228.tar.bz2 linux-da9953b729c12ece6d35fd15d236457eee679228.zip |
f2fs: introduce sysfs/data_io_flag to attach REQ_META/FUA
This patch introduces a way to attach REQ_META/FUA explicitly
to all the data writes given temperature.
-> attach REQ_FUA to Hot Data writes
-> attach REQ_FUA to Hot|Warm Data writes
-> attach REQ_FUA to Hot|Warm|Cold Data writes
-> attach REQ_FUA to Hot|Warm|Cold Data writes as well as
REQ_META to Hot Data writes
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/sysfs.c')
-rw-r--r-- | fs/f2fs/sysfs.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/f2fs/sysfs.c b/fs/f2fs/sysfs.c index e3bbbef9b4f0..aeebfb5024a2 100644 --- a/fs/f2fs/sysfs.c +++ b/fs/f2fs/sysfs.c @@ -372,7 +372,6 @@ out: return count; } - if (!strcmp(a->attr.name, "iostat_enable")) { sbi->iostat_enable = !!t; if (!sbi->iostat_enable) @@ -543,6 +542,7 @@ F2FS_RW_ATTR(F2FS_SBI, f2fs_super_block, extension_list, extension_list); F2FS_RW_ATTR(FAULT_INFO_RATE, f2fs_fault_info, inject_rate, inject_rate); F2FS_RW_ATTR(FAULT_INFO_TYPE, f2fs_fault_info, inject_type, inject_type); #endif +F2FS_RW_ATTR(F2FS_SBI, f2fs_sb_info, data_io_flag, data_io_flag); F2FS_GENERAL_RO_ATTR(dirty_segments); F2FS_GENERAL_RO_ATTR(free_segments); F2FS_GENERAL_RO_ATTR(lifetime_write_kbytes); @@ -622,6 +622,7 @@ static struct attribute *f2fs_attrs[] = { ATTR_LIST(inject_rate), ATTR_LIST(inject_type), #endif + ATTR_LIST(data_io_flag), ATTR_LIST(dirty_segments), ATTR_LIST(free_segments), ATTR_LIST(unusable), |