btrfs: Simplify conditions about compress while mapping btrfs flags to inode flags
Signed-off-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
c5f4ccb2f7
commit
13f48dc909
@ -125,10 +125,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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user