Skip to content

Commit 61dd5ae

Browse files
committed
btrfs: use GFP_KERNEL for allocations of workqueues
We don't have to use GFP_NOFS to allocate workqueue structures, this is done from mount context or potentially scrub start context, safe to fail in both cases. Signed-off-by: David Sterba <dsterba@suse.com>
1 parent 8d2db78 commit 61dd5ae

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎fs/btrfs/async-thread.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ static struct __btrfs_workqueue *
9797
__btrfs_alloc_workqueue(const char *name, unsigned int flags, int limit_active,
9898
int thresh)
9999
{
100-
struct __btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_NOFS);
100+
struct __btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_KERNEL);
101101

102102
if (!ret)
103103
return NULL;
@@ -148,7 +148,7 @@ struct btrfs_workqueue *btrfs_alloc_workqueue(const char *name,
148148
int limit_active,
149149
int thresh)
150150
{
151-
struct btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_NOFS);
151+
struct btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_KERNEL);
152152

153153
if (!ret)
154154
return NULL;

0 commit comments

Comments
 (0)