From: 심재선 <jason.sim@samsung.com>
To: "liam.howlett@oracle.com" <liam.howlett@oracle.com>
Cc: "surenb@google.com" <surenb@google.com>,
"linux-mm@kvack.org" <linux-mm@kvack.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"jaewon31.kim@gmail.com" <jaewon31.kim@gmail.com>,
"maple-tree@lists.infradead.org" <maple-tree@lists.infradead.org>
Subject: [PATCH] maple_tree: use GFP_KERNEL on mas_node_count
Date: Thu, 07 Sep 2023 12:39:14 +0900 [thread overview]
Message-ID: <20230907033914epcms1p61c5eed4d34d5c4212436c201f33292b3@epcms1p6> (raw)
In-Reply-To: <CGME20230907033914epcms1p61c5eed4d34d5c4212436c201f33292b3@epcms1p6>
Use GFP_KERNEL on mas_node_count instead of GFP_NOWAIT | __GFP_NOWARN
in order to allow memory reclaim.
Currently, fork errors occur on low free memory as follows:
Zygote : Failed to fork child process: Out of memory (12)
-ENOMEM was returned as following path:
mas_node_count
mas_expected_entries
dup_mmap
dup_mm
copy_mm
copy_process
Signed-off-by: jason.sim <jason.sim@samsung.com>
---
lib/maple_tree.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/maple_tree.c b/lib/maple_tree.c
index ee1ff0c59fd7..076798f83baa 100644
--- a/lib/maple_tree.c
+++ b/lib/maple_tree.c
@@ -1336,11 +1336,11 @@ static void mas_node_count_gfp(struct ma_state *mas, int count, gfp_t gfp)
* @mas: The maple state
* @count: The number of nodes needed
*
- * Note: Uses GFP_NOWAIT | __GFP_NOWARN for gfp flags.
+ * Note: Uses GFP_KERNEL for gfp flags.
*/
static void mas_node_count(struct ma_state *mas, int count)
{
- return mas_node_count_gfp(mas, count, GFP_NOWAIT | __GFP_NOWARN);
+ return mas_node_count_gfp(mas, count, GFP_KERNEL);
}
/*
--
2.17.1
next parent reply other threads:[~2023-09-07 3:39 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20230907033914epcms1p61c5eed4d34d5c4212436c201f33292b3@epcms1p6>
2023-09-07 3:39 ` 심재선 [this message]
2023-09-07 3:49 ` Matthew Wilcox
2023-09-07 4:02 ` Peng Zhang
2023-09-07 4:10 ` Matthew Wilcox
[not found] ` <CGME20230907033914epcms1p61c5eed4d34d5c4212436c201f33292b3@epcms1p3>
2023-09-07 4:41 ` Jaeseon Sim
2023-09-07 14:49 ` Liam R. Howlett
[not found] ` <CGME20230907033914epcms1p61c5eed4d34d5c4212436c201f33292b3@epcms1p2>
2023-09-14 2:49 ` Jaeseon Sim
2023-09-14 15:31 ` Liam R. Howlett
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230907033914epcms1p61c5eed4d34d5c4212436c201f33292b3@epcms1p6 \
--to=jason.sim@samsung.com \
--cc=jaewon31.kim@gmail.com \
--cc=liam.howlett@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=maple-tree@lists.infradead.org \
--cc=surenb@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox