diff options
| author | Uladzislau Rezki (Sony) <[email protected]> | 2025-03-17 16:36:14 +0000 |
|---|---|---|
| committer | Andrew Morton <[email protected]> | 2025-03-22 05:03:14 +0000 |
| commit | b25bcabb6cefaa394fa03087c41d5cb82c23163d (patch) | |
| tree | 362a556a816173045a97669c15e583b06cad3ea1 | |
| parent | docs/mm: Physical Memory: Populate the "Zones" section (diff) | |
| download | kernel-b25bcabb6cefaa394fa03087c41d5cb82c23163d.tar.gz kernel-b25bcabb6cefaa394fa03087c41d5cb82c23163d.zip | |
fork: use __vmalloc_node() for stack allocation
Replace __vmalloc_node_range() by __vmalloc_node(). The last variant
requires less parameters and it uses exactly the same arguments which are
partly now hidden inside __vmalloc_node().
This change does not change any functionality. It makes the code a bit
simpler.
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Uladzislau Rezki (Sony) <[email protected]>
Acked-by: Michal Hocko <[email protected]>
Cc: Christian Brauner <[email protected]>
Cc: Oleg Nesterov <[email protected]>
Cc: Tejun Heo <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
| -rw-r--r-- | kernel/fork.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/kernel/fork.c b/kernel/fork.c index f9cf0f056eb6..83cb82643817 100644 --- a/kernel/fork.c +++ b/kernel/fork.c @@ -311,11 +311,9 @@ static int alloc_thread_stack_node(struct task_struct *tsk, int node) * so memcg accounting is performed manually on assigning/releasing * stacks to tasks. Drop __GFP_ACCOUNT. */ - stack = __vmalloc_node_range(THREAD_SIZE, THREAD_ALIGN, - VMALLOC_START, VMALLOC_END, + stack = __vmalloc_node(THREAD_SIZE, THREAD_ALIGN, THREADINFO_GFP & ~__GFP_ACCOUNT, - PAGE_KERNEL, - 0, node, __builtin_return_address(0)); + node, __builtin_return_address(0)); if (!stack) return -ENOMEM; |
