f2fs: fix incorrect free inode count in ->statfs
authorChao Yu <yuchao0@huawei.com>
Fri, 18 Nov 2016 14:27:41 +0000 (22:27 +0800)
committerJaegeuk Kim <jaegeuk@google.com>
Mon, 25 Sep 2017 22:36:59 +0000 (15:36 -0700)
commita680707a3f4161761e35effaedbdba02ee7ee069
tree3581dc241b232c51715ae528c4496f35d018f116
parent23eb5177568d70646669871d2268106947630990
f2fs: fix incorrect free inode count in ->statfs

commit b08b12d2ddc85b977a0531470cf6a7158289aaaf upstream.

While calculating inode count that we can create at most in the left space,
we should consider space which data/node blocks occupied, since we create
data/node mixly in main area. So fix the wrong calculation in ->statfs.

Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/super.c