* [PATCH] blk-cgroup: remove redundant __GFP_NOWARN
@ 2025-08-09 14:13 Qianfeng Rong
2025-08-09 18:04 ` Tejun Heo
2025-08-11 14:01 ` Jens Axboe
0 siblings, 2 replies; 3+ messages in thread
From: Qianfeng Rong @ 2025-08-09 14:13 UTC (permalink / raw)
To: Tejun Heo, Josef Bacik, Jens Axboe, cgroups, linux-block,
linux-kernel
Cc: Qianfeng Rong
Commit 16f5dfbc851b ("gfp: include __GFP_NOWARN in GFP_NOWAIT") made
GFP_NOWAIT implicitly include __GFP_NOWARN.
Therefore, explicit __GFP_NOWARN combined with GFP_NOWAIT (e.g.,
`GFP_NOWAIT | __GFP_NOWARN`) is now redundant. Let's clean up these
redundant flags across subsystems.
Signed-off-by: Qianfeng Rong <rongqianfeng@vivo.com>
---
block/blk-cgroup.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/block/blk-cgroup.c b/block/blk-cgroup.c
index 5936db7f8475..fe9ebd6a2e14 100644
--- a/block/blk-cgroup.c
+++ b/block/blk-cgroup.c
@@ -394,7 +394,7 @@ static struct blkcg_gq *blkg_create(struct blkcg *blkcg, struct gendisk *disk,
/* allocate */
if (!new_blkg) {
- new_blkg = blkg_alloc(blkcg, disk, GFP_NOWAIT | __GFP_NOWARN);
+ new_blkg = blkg_alloc(blkcg, disk, GFP_NOWAIT);
if (unlikely(!new_blkg)) {
ret = -ENOMEM;
goto err_put_css;
@@ -1467,7 +1467,7 @@ blkcg_css_alloc(struct cgroup_subsys_state *parent_css)
spin_lock_init(&blkcg->lock);
refcount_set(&blkcg->online_pin, 1);
- INIT_RADIX_TREE(&blkcg->blkg_tree, GFP_NOWAIT | __GFP_NOWARN);
+ INIT_RADIX_TREE(&blkcg->blkg_tree, GFP_NOWAIT);
INIT_HLIST_HEAD(&blkcg->blkg_list);
#ifdef CONFIG_CGROUP_WRITEBACK
INIT_LIST_HEAD(&blkcg->cgwb_list);
@@ -1630,7 +1630,7 @@ int blkcg_activate_policy(struct gendisk *disk, const struct blkcg_policy *pol)
pd_prealloc = NULL;
} else {
pd = pol->pd_alloc_fn(disk, blkg->blkcg,
- GFP_NOWAIT | __GFP_NOWARN);
+ GFP_NOWAIT);
}
if (!pd) {
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] blk-cgroup: remove redundant __GFP_NOWARN
2025-08-09 14:13 [PATCH] blk-cgroup: remove redundant __GFP_NOWARN Qianfeng Rong
@ 2025-08-09 18:04 ` Tejun Heo
2025-08-11 14:01 ` Jens Axboe
1 sibling, 0 replies; 3+ messages in thread
From: Tejun Heo @ 2025-08-09 18:04 UTC (permalink / raw)
To: Qianfeng Rong; +Cc: Josef Bacik, Jens Axboe, cgroups, linux-block, linux-kernel
On Sat, Aug 09, 2025 at 10:13:58PM +0800, Qianfeng Rong wrote:
> Commit 16f5dfbc851b ("gfp: include __GFP_NOWARN in GFP_NOWAIT") made
> GFP_NOWAIT implicitly include __GFP_NOWARN.
>
> Therefore, explicit __GFP_NOWARN combined with GFP_NOWAIT (e.g.,
> `GFP_NOWAIT | __GFP_NOWARN`) is now redundant. Let's clean up these
> redundant flags across subsystems.
>
> Signed-off-by: Qianfeng Rong <rongqianfeng@vivo.com>
Acked-by: Tejun Heo <tj@kernel.org>
Thanks.
--
tejun
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] blk-cgroup: remove redundant __GFP_NOWARN
2025-08-09 14:13 [PATCH] blk-cgroup: remove redundant __GFP_NOWARN Qianfeng Rong
2025-08-09 18:04 ` Tejun Heo
@ 2025-08-11 14:01 ` Jens Axboe
1 sibling, 0 replies; 3+ messages in thread
From: Jens Axboe @ 2025-08-11 14:01 UTC (permalink / raw)
To: Tejun Heo, Josef Bacik, cgroups, linux-block, linux-kernel,
Qianfeng Rong
On Sat, 09 Aug 2025 22:13:58 +0800, Qianfeng Rong wrote:
> Commit 16f5dfbc851b ("gfp: include __GFP_NOWARN in GFP_NOWAIT") made
> GFP_NOWAIT implicitly include __GFP_NOWARN.
>
> Therefore, explicit __GFP_NOWARN combined with GFP_NOWAIT (e.g.,
> `GFP_NOWAIT | __GFP_NOWARN`) is now redundant. Let's clean up these
> redundant flags across subsystems.
>
> [...]
Applied, thanks!
[1/1] blk-cgroup: remove redundant __GFP_NOWARN
commit: 196447c712dd486f4315356c572a1d13dd743f08
Best regards,
--
Jens Axboe
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-08-11 14:01 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-09 14:13 [PATCH] blk-cgroup: remove redundant __GFP_NOWARN Qianfeng Rong
2025-08-09 18:04 ` Tejun Heo
2025-08-11 14:01 ` Jens Axboe
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).