|
@@ -670,12 +670,12 @@ static int create_snapshot(struct btrfs_root *root, struct inode *dir,
|
|
if (!test_bit(BTRFS_ROOT_REF_COWS, &root->state))
|
|
if (!test_bit(BTRFS_ROOT_REF_COWS, &root->state))
|
|
return -EINVAL;
|
|
return -EINVAL;
|
|
|
|
|
|
- pending_snapshot = kzalloc(sizeof(*pending_snapshot), GFP_NOFS);
|
|
|
|
|
|
+ pending_snapshot = kzalloc(sizeof(*pending_snapshot), GFP_KERNEL);
|
|
if (!pending_snapshot)
|
|
if (!pending_snapshot)
|
|
return -ENOMEM;
|
|
return -ENOMEM;
|
|
|
|
|
|
pending_snapshot->root_item = kzalloc(sizeof(struct btrfs_root_item),
|
|
pending_snapshot->root_item = kzalloc(sizeof(struct btrfs_root_item),
|
|
- GFP_NOFS);
|
|
|
|
|
|
+ GFP_KERNEL);
|
|
pending_snapshot->path = btrfs_alloc_path();
|
|
pending_snapshot->path = btrfs_alloc_path();
|
|
if (!pending_snapshot->root_item || !pending_snapshot->path) {
|
|
if (!pending_snapshot->root_item || !pending_snapshot->path) {
|
|
ret = -ENOMEM;
|
|
ret = -ENOMEM;
|