Skip to content

Commit

Permalink
btrfs: use GFP_KERNEL for allocations of workqueues
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
David Sterba committed Dec 3, 2015
1 parent 8d2db78 commit 61dd5ae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fs/btrfs/async-thread.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ static struct __btrfs_workqueue *
__btrfs_alloc_workqueue(const char *name, unsigned int flags, int limit_active,
int thresh)
{
struct __btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_NOFS);
struct __btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_KERNEL);

if (!ret)
return NULL;
Expand Down Expand Up @@ -148,7 +148,7 @@ struct btrfs_workqueue *btrfs_alloc_workqueue(const char *name,
int limit_active,
int thresh)
{
struct btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_NOFS);
struct btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_KERNEL);

if (!ret)
return NULL;
Expand Down

0 comments on commit 61dd5ae

Please sign in to comment.