diff options
| -rw-r--r-- | fs/btrfs/ioctl.c | 2 | ||||
| -rw-r--r-- | fs/btrfs/xattr.c | 6 |
2 files changed, 3 insertions, 5 deletions
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c index 6dafa857bbb9..2a1be0d1a698 100644 --- a/fs/btrfs/ioctl.c +++ b/fs/btrfs/ioctl.c | |||
| @@ -312,8 +312,6 @@ static int btrfs_ioctl_setflags(struct file *file, void __user *arg) | |||
| 312 | btrfs_abort_transaction(trans, ret); | 312 | btrfs_abort_transaction(trans, ret); |
| 313 | goto out_end_trans; | 313 | goto out_end_trans; |
| 314 | } | 314 | } |
| 315 | set_bit(BTRFS_INODE_COPY_EVERYTHING, | ||
| 316 | &BTRFS_I(inode)->runtime_flags); | ||
| 317 | } else { | 315 | } else { |
| 318 | ret = btrfs_set_prop(trans, inode, "btrfs.compression", NULL, | 316 | ret = btrfs_set_prop(trans, inode, "btrfs.compression", NULL, |
| 319 | 0, 0); | 317 | 0, 0); |
diff --git a/fs/btrfs/xattr.c b/fs/btrfs/xattr.c index 78b6ba2029e8..95d9aebff2c4 100644 --- a/fs/btrfs/xattr.c +++ b/fs/btrfs/xattr.c | |||
| @@ -213,6 +213,9 @@ int btrfs_setxattr(struct btrfs_trans_handle *trans, struct inode *inode, | |||
| 213 | } | 213 | } |
| 214 | out: | 214 | out: |
| 215 | btrfs_free_path(path); | 215 | btrfs_free_path(path); |
| 216 | if (!ret) | ||
| 217 | set_bit(BTRFS_INODE_COPY_EVERYTHING, | ||
| 218 | &BTRFS_I(inode)->runtime_flags); | ||
| 216 | return ret; | 219 | return ret; |
| 217 | } | 220 | } |
| 218 | 221 | ||
| @@ -236,7 +239,6 @@ int btrfs_setxattr_trans(struct inode *inode, const char *name, | |||
| 236 | 239 | ||
| 237 | inode_inc_iversion(inode); | 240 | inode_inc_iversion(inode); |
| 238 | inode->i_ctime = current_time(inode); | 241 | inode->i_ctime = current_time(inode); |
| 239 | set_bit(BTRFS_INODE_COPY_EVERYTHING, &BTRFS_I(inode)->runtime_flags); | ||
| 240 | ret = btrfs_update_inode(trans, root, inode); | 242 | ret = btrfs_update_inode(trans, root, inode); |
| 241 | BUG_ON(ret); | 243 | BUG_ON(ret); |
| 242 | out: | 244 | out: |
| @@ -388,8 +390,6 @@ static int btrfs_xattr_handler_set_prop(const struct xattr_handler *handler, | |||
| 388 | if (!ret) { | 390 | if (!ret) { |
| 389 | inode_inc_iversion(inode); | 391 | inode_inc_iversion(inode); |
| 390 | inode->i_ctime = current_time(inode); | 392 | inode->i_ctime = current_time(inode); |
| 391 | set_bit(BTRFS_INODE_COPY_EVERYTHING, | ||
| 392 | &BTRFS_I(inode)->runtime_flags); | ||
| 393 | ret = btrfs_update_inode(trans, root, inode); | 393 | ret = btrfs_update_inode(trans, root, inode); |
| 394 | BUG_ON(ret); | 394 | BUG_ON(ret); |
| 395 | } | 395 | } |
