提交 84812217 编写于 作者: J Jeff Dike 提交者: Linus Torvalds

uml: use get_free_pages to allocate kernel stacks

For some reason, I was using kmalloc instead of get_free_pages for kernel
stacks.
Signed-off-by: NJeff Dike <jdike@linux.intel.com>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 0a6d3a2a
...@@ -54,8 +54,10 @@ static inline struct thread_info *current_thread_info(void) ...@@ -54,8 +54,10 @@ static inline struct thread_info *current_thread_info(void)
/* thread information allocation */ /* thread information allocation */
#define alloc_thread_info(tsk) \ #define alloc_thread_info(tsk) \
((struct thread_info *) kmalloc(THREAD_SIZE, GFP_KERNEL)) ((struct thread_info *) __get_free_pages(GFP_KERNEL, \
#define free_thread_info(ti) kfree(ti) CONFIG_KERNEL_STACK_ORDER))
#define free_thread_info(ti) \
free_pages((unsigned long)(ti),CONFIG_KERNEL_STACK_ORDER)
#endif #endif
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册