[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20220118034802.98403-1-chao@kernel.org>
Date: Tue, 18 Jan 2022 11:48:02 +0800
From: Chao Yu <chao@...nel.org>
To: jaegeuk@...nel.org
Cc: linux-f2fs-devel@...ts.sourceforge.net,
linux-kernel@...r.kernel.org, Chao Yu <chao@...nel.org>,
Zhipeng Tan <tanzhipeng@...t.edu.cn>,
Jicheng Shao <shaojicheng@...t.edu.cn>
Subject: [PATCH] f2fs: fix to enable ATGC correctly via gc_idle sysfs interface
It needs to assign sbi->gc_mode with GC_IDLE_AT rather than GC_AT when
user tries to enable ATGC via gc_idle sysfs interface, fix it.
Fixes: 093749e296e2 ("f2fs: support age threshold based garbage collection")
Cc: Zhipeng Tan <tanzhipeng@...t.edu.cn>
Signed-off-by: Jicheng Shao <shaojicheng@...t.edu.cn>
Signed-off-by: Chao Yu <chao@...nel.org>
---
fs/f2fs/sysfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/f2fs/sysfs.c b/fs/f2fs/sysfs.c
index f8a14b1e2ef7..699f97610e8a 100644
--- a/fs/f2fs/sysfs.c
+++ b/fs/f2fs/sysfs.c
@@ -482,7 +482,7 @@ static ssize_t __sbi_store(struct f2fs_attr *a,
} else if (t == GC_IDLE_AT) {
if (!sbi->am.atgc_enabled)
return -EINVAL;
- sbi->gc_mode = GC_AT;
+ sbi->gc_mode = GC_IDLE_AT;
} else {
sbi->gc_mode = GC_NORMAL;
}
--
2.25.1
Powered by blists - more mailing lists