[f2fs-dev] [RFC PATCH 1/3] ext4: show prjquota info on statfs for a file
Currently we replace filesystem statistics using prjquota info on statfs when specified directory has project id inherit flag. However, statfs on a file(accurately non-dir) which is under the project quota dir(with inherit flag) still shows whole filesystem statistics. In container use case, it will give container user inconsistent experience and cause confusion about available free space. Detail info like below: We use project quota to limit disk space usage for a container and run df command inside container. Run df on a directory: [root /]# df -h /etc/ Filesystem Size Used Avail Use% Mounted on kataShared 1.0G 13M 1012M 2% / Run df on a file: [root /]# df -h /etc/exports Filesystem Size Used Avail Use% Mounted on kataShared 1.5T 778M 1.5T 1% / Signed-off-by: Chengguang Xu --- fs/ext4/super.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/ext4/super.c b/fs/ext4/super.c index dd654e53ba3d..3fba22b54f5c 100644 --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -5607,7 +5607,8 @@ static int ext4_statfs(struct dentry *dentry, struct kstatfs *buf) buf->f_fsid.val[1] = (fsid >> 32) & 0xUL; #ifdef CONFIG_QUOTA - if (ext4_test_inode_flag(dentry->d_inode, EXT4_INODE_PROJINHERIT) && + if ((ext4_test_inode_flag(dentry->d_inode, EXT4_INODE_PROJINHERIT) || +!S_ISDIR(dentry->d_inode->i_mode)) && sb_has_quota_limits_enabled(sb, PRJQUOTA)) ext4_statfs_project(sb, EXT4_I(dentry->d_inode)->i_projid, buf); #endif -- 2.20.1 ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
[f2fs-dev] [RFC PATCH 2/3] f2fs: show prjquota info on statfs for a file
Currently we replace filesystem statistics using prjquota info on statfs when specified directory has project id inherit flag. However, statfs on a file(accurately non-dir) which is under the project quota dir(with inherit flag) still shows whole filesystem statistics. In container use case, it will give container user inconsistent experience and cause confusion about available free space. Detail info like below: We use project quota to limit disk space usage for a container and run df command inside container. Run df on a directory: [root /]# df -h /etc/ Filesystem Size Used Avail Use% Mounted on kataShared 1.0G 13M 1012M 2% / Run df on a file: [root /]# df -h /etc/exports Filesystem Size Used Avail Use% Mounted on kataShared 1.5T 778M 1.5T 1% / Signed-off-by: Chengguang Xu --- fs/f2fs/super.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index 1443cee15863..c5b9a92d606b 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -1287,8 +1287,9 @@ static int f2fs_statfs(struct dentry *dentry, struct kstatfs *buf) buf->f_fsid.val[1] = (u32)(id >> 32); #ifdef CONFIG_QUOTA - if (is_inode_flag_set(dentry->d_inode, FI_PROJ_INHERIT) && - sb_has_quota_limits_enabled(sb, PRJQUOTA)) { + if ((is_inode_flag_set(dentry->d_inode, FI_PROJ_INHERIT) || +!S_ISDIR(dentry->d_inode->i_mode)) && + sb_has_quota_limits_enabled(sb, PRJQUOTA)) { f2fs_statfs_project(sb, F2FS_I(dentry->d_inode)->i_projid, buf); } #endif -- 2.20.1 ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
[f2fs-dev] [RFC PATCH 3/3] xfs: show prjquota info on statfs for a file
Currently we replace filesystem statistics using prjquota info on statfs when specified directory has project id inherit flag. However, statfs on a file(accurately non-dir) which is under the project quota dir(with inherit flag) still shows whole filesystem statistics. In container use case, it will give container user inconsistent experience and cause confusion about available free space. Detail info like below: We use project quota to limit disk space usage for a container and run df command inside container. Run df on a directory: [root /]# df -h /etc/ Filesystem Size Used Avail Use% Mounted on kataShared 1.0G 13M 1012M 2% / Run df on a file: [root /]# df -h /etc/exports Filesystem Size Used Avail Use% Mounted on kataShared 1.5T 778M 1.5T 1% / Signed-off-by: Chengguang Xu --- fs/xfs/xfs_super.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c index 8d1df9f8be07..9f4d9e86572a 100644 --- a/fs/xfs/xfs_super.c +++ b/fs/xfs/xfs_super.c @@ -1125,7 +1125,8 @@ xfs_fs_statfs( statp->f_ffree = max_t(int64_t, ffree, 0); - if ((ip->i_d.di_flags & XFS_DIFLAG_PROJINHERIT) && + if (((ip->i_d.di_flags & XFS_DIFLAG_PROJINHERIT) || +!S_ISDIR(dentry->d_inode->i_mode)) && ((mp->m_qflags & (XFS_PQUOTA_ACCT|XFS_PQUOTA_ENFD))) == (XFS_PQUOTA_ACCT|XFS_PQUOTA_ENFD)) xfs_qm_statvfs(ip, statp); -- 2.20.1 ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
Re: [f2fs-dev] [PATCH] fscrypt: support passing a keyring key to FS_IOC_ADD_ENCRYPTION_KEY
On Fri, Nov 15, 2019 at 07:01:39PM -0500, Theodore Y. Ts'o wrote: > On Sat, Nov 16, 2019 at 12:53:19AM +0200, Jarkko Sakkinen wrote: > > > I'm working on an xfstest for this: > > > > > > > > > https://git.kernel.org/pub/scm/linux/kernel/git/ebiggers/xfstests-dev.git/commit/?h=fscrypt-provisioning=24ab6abb7cf6a80be44b7c72b73f0519ccaa5a97 > > > > > > It's not quite ready, though. I'll post it for review when it is. > > > > > > Someone is also planning to update Android userspace to use this. So if > > > there > > > are any issues from that, I'll hear about it. > > > > Cool. Can you combine this patch and matching test (once it is done) to > > a patch set? > > That's generally not done since the test goes to a different repo > (xfstests.git) which has a different review process from the kernel > change. FWIW I generally send one series per git tree (kernel, *progs, fstests) one right after another so that they'll all land more or less together in everybody's inboxes. --D > - Ted ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
[f2fs-dev] Investment opportunity
Greetings, Find attached email very confidential. reply for more details Thanks. Peter Wong This email was sent by the shareware version of Postman Professional. ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel