aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/fork.c
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2012-05-05 11:05:41 -0400
committerThomas Gleixner <tglx@linutronix.de>2012-05-08 07:55:20 -0400
commit2889f60814e15dea644782597d897cdba943564f (patch)
tree0dab94d2c8136dc86241a7e85e5c881b03677c92 /kernel/fork.c
parent6c0a9fa62feb7e9fdefa9720bcc03040c9b0b311 (diff)
fork: Move thread info gfp flags to header
These flags can be useful for extra allocations outside of the core code. Add __GFP_NOTRACK to them, so the archs which have kmemcheck do not have to provide extra allocators just for that reason. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20120505150141.428211694@linutronix.de
Diffstat (limited to 'kernel/fork.c')
-rw-r--r--kernel/fork.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/kernel/fork.c b/kernel/fork.c
index a79b36e2e912..5d22b9b8cf7b 100644
--- a/kernel/fork.c
+++ b/kernel/fork.c
@@ -123,12 +123,8 @@ static struct kmem_cache *task_struct_cachep;
123static struct thread_info *alloc_thread_info_node(struct task_struct *tsk, 123static struct thread_info *alloc_thread_info_node(struct task_struct *tsk,
124 int node) 124 int node)
125{ 125{
126#ifdef CONFIG_DEBUG_STACK_USAGE 126 struct page *page = alloc_pages_node(node, THREADINFO_GFP,
127 gfp_t mask = GFP_KERNEL | __GFP_ZERO; 127 THREAD_SIZE_ORDER);
128#else
129 gfp_t mask = GFP_KERNEL;
130#endif
131 struct page *page = alloc_pages_node(node, mask, THREAD_SIZE_ORDER);
132 128
133 return page ? page_address(page) : NULL; 129 return page ? page_address(page) : NULL;
134} 130}