提交 61dd5ae6 编写于 作者: D David Sterba

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: NDavid Sterba <dsterba@suse.com>
上级 8d2db785
...@@ -97,7 +97,7 @@ static struct __btrfs_workqueue * ...@@ -97,7 +97,7 @@ static struct __btrfs_workqueue *
__btrfs_alloc_workqueue(const char *name, unsigned int flags, int limit_active, __btrfs_alloc_workqueue(const char *name, unsigned int flags, int limit_active,
int thresh) int thresh)
{ {
struct __btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_NOFS); struct __btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_KERNEL);
if (!ret) if (!ret)
return NULL; return NULL;
...@@ -148,7 +148,7 @@ struct btrfs_workqueue *btrfs_alloc_workqueue(const char *name, ...@@ -148,7 +148,7 @@ struct btrfs_workqueue *btrfs_alloc_workqueue(const char *name,
int limit_active, int limit_active,
int thresh) int thresh)
{ {
struct btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_NOFS); struct btrfs_workqueue *ret = kzalloc(sizeof(*ret), GFP_KERNEL);
if (!ret) if (!ret)
return NULL; return NULL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册