linux-xfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fs/xfs: fix f_ffree value for statfs when project quota is set
@ 2018-11-22 13:28 dbyin(尹烨)
  2018-11-22 17:58 ` Darrick J. Wong
  0 siblings, 1 reply; 3+ messages in thread
From: dbyin(尹烨) @ 2018-11-22 13:28 UTC (permalink / raw)
  To: darrick.wong@oracle.com
  Cc: linux-xfs@vger.kernel.org, linux-kernel@vger.kernel.org,
	dbyin(尹烨)

When project is set, we should use inode limit minus the used count

Signed-off-by: Ye Yin <dbyin@tencent.com>
---
 fs/xfs/xfs_qm_bhv.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/xfs/xfs_qm_bhv.c b/fs/xfs/xfs_qm_bhv.c
index 73a1d77ec187..3091e4bc04ef 100644
--- a/fs/xfs/xfs_qm_bhv.c
+++ b/fs/xfs/xfs_qm_bhv.c
@@ -40,7 +40,7 @@ xfs_fill_statvfs_from_dquot(
                statp->f_files = limit;
                statp->f_ffree =
                        (statp->f_files > dqp->q_res_icount) ?
-                        (statp->f_ffree - dqp->q_res_icount) : 0;
+                        (statp->f_files - dqp->q_res_icount) : 0;
        }
 }
 
-- 
2.16.2

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-11-23 12:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-22 13:28 [PATCH] fs/xfs: fix f_ffree value for statfs when project quota is set dbyin(尹烨)
2018-11-22 17:58 ` Darrick J. Wong
2018-11-23  2:10   ` 答复: [PATCH] fs/xfs: fix f_ffree value for statfs when project quota is set(Internet mail) dbyin(尹烨)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).