mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
mm: NUMA aware alloc_task_struct_node()
All kthreads being created from a single helper task, they all use memory from a single node for their kernel stack and task struct. This patch suite creates kthread_create_on_cpu(), adding a 'cpu' parameter to parameters already used by kthread_create(). This parameter serves in allocating memory for the new kthread on its memory node if available. Users of this new function are : ksoftirqd, kworker, migration, pktgend... This patch: Add a node parameter to alloc_task_struct(), and change its name to alloc_task_struct_node() This change is needed to allow NUMA aware kthread_create_on_cpu() Signed-off-by: Eric Dumazet <[email protected]> Acked-by: David S. Miller <[email protected]> Reviewed-by: Andi Kleen <[email protected]> Acked-by: Rusty Russell <[email protected]> Cc: Tejun Heo <[email protected]> Cc: Tony Luck <[email protected]> Cc: Fenghua Yu <[email protected]> Cc: David Howells <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
9d502c1c8d
commit
504f52b543
5 changed files with 19 additions and 9 deletions
|
|
@ -66,7 +66,7 @@ struct thread_struct {
|
|||
.request = { 0 } \
|
||||
}
|
||||
|
||||
extern struct task_struct *alloc_task_struct(void);
|
||||
extern struct task_struct *alloc_task_struct_node(int node);
|
||||
|
||||
static inline void release_thread(struct task_struct *task)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue