From: Chao Yu Date: Tue, 12 Sep 2017 06:25:35 +0000 (+0800) Subject: f2fs: fix to show correct discard_granularity in sysfs X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=80647e5f4c728ecea7d9190c6e7163755ff6835c;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git f2fs: fix to show correct discard_granularity in sysfs Fix below incorrect display when reading discard_granularity sysfs node. $ cat /sys/fs/f2fs//discard_granularity $ 16 $ echo 32 > /sys/fs/f2fs//discard_granularity $ cat /sys/fs/f2fs//discard_granularity $ 16 Signed-off-by: Chao Yu Signed-off-by: Jaegeuk Kim --- diff --git a/fs/f2fs/sysfs.c b/fs/f2fs/sysfs.c index 962735dc9c63..e2c258f717cd 100644 --- a/fs/f2fs/sysfs.c +++ b/fs/f2fs/sysfs.c @@ -170,6 +170,8 @@ static ssize_t f2fs_sbi_store(struct f2fs_attr *a, dcc->pend_list_tag[i] &= (~P_ACTIVE); } mutex_unlock(&dcc->cmd_lock); + + *ui = t; return count; }