btrfs: Simplify conditions about compress while mapping btrfs flags to inode flags
PATCH 1/1 btrfs: Simplify conditions about compress while mapping btrfs flags to inode flags
Signed-off-by Satoru Takeuchi <[email protected]>
---
This patch can be applied to 4.5
--- fs/btrfs/ioctl.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
fs/btrfs/ioctl.c +3 -3
@@ -123,10 +123,10 @@ static unsigned int btrfs_flags_to_ioctl(unsigned int flags)if (flags &BTRFS_INODE_NODATACOW ) iflags |=FS_NOCOW_FL ; -if ((flags &BTRFS_INODE_COMPRESS ) && !(flags &BTRFS_INODE_NOCOMPRESS )) - iflags |=FS_COMPR_FL ; -else if (flags &BTRFS_INODE_NOCOMPRESS ) +if (flags &BTRFS_INODE_NOCOMPRESS ) iflags |=FS_NOCOMP_FL ; +else if (flags &BTRFS_INODE_COMPRESS ) + iflags |=FS_COMPR_FL ;return iflags; }
Signature · 1 line
2.5.0
Quoted 1 line · Satoru Takeuchi
Signed-off-by Satoru Takeuchi <[email protected]>
Reviewed-by David Sterba <[email protected]>