* [PATCH 1/1] kthread: Reduce stack pressure in create_kthread and kthreadd
@ 2008-07-08 22:55 Mike Travis
2008-07-18 16:47 ` Ingo Molnar
0 siblings, 1 reply; 2+ messages in thread
From: Mike Travis @ 2008-07-08 22:55 UTC (permalink / raw)
To: Ingo Molnar, Andrew Morton; +Cc: LKML
Subject: [PATCH 1/1] kthread: Reduce stack pressure in create_kthread and kthreadd
* Replace:
set_cpus_allowed(..., CPU_MASK_ALL)
with:
set_cpus_allowed_ptr(..., CPU_MASK_ALL_PTR)
to remove excessive stack requirements when NR_CPUS=4096.
Based on linux-2.6.tip/master
Signed-off-by: Mike Travis <travis@sgi.com>
---
kernel/kthread.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- linux-2.6.tip.orig/kernel/kthread.c
+++ linux-2.6.tip/kernel/kthread.c
@@ -107,7 +107,7 @@ static void create_kthread(struct kthrea
*/
sched_setscheduler(create->result, SCHED_NORMAL, ¶m);
set_user_nice(create->result, KTHREAD_NICE_LEVEL);
- set_cpus_allowed(create->result, CPU_MASK_ALL);
+ set_cpus_allowed_ptr(create->result, CPU_MASK_ALL_PTR);
}
complete(&create->done);
}
@@ -238,7 +238,7 @@ int kthreadd(void *unused)
set_task_comm(tsk, "kthreadd");
ignore_signals(tsk);
set_user_nice(tsk, KTHREAD_NICE_LEVEL);
- set_cpus_allowed(tsk, CPU_MASK_ALL);
+ set_cpus_allowed_ptr(tsk, CPU_MASK_ALL_PTR);
current->flags |= PF_NOFREEZE;
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] kthread: Reduce stack pressure in create_kthread and kthreadd
2008-07-08 22:55 [PATCH 1/1] kthread: Reduce stack pressure in create_kthread and kthreadd Mike Travis
@ 2008-07-18 16:47 ` Ingo Molnar
0 siblings, 0 replies; 2+ messages in thread
From: Ingo Molnar @ 2008-07-18 16:47 UTC (permalink / raw)
To: Mike Travis; +Cc: Andrew Morton, LKML
* Mike Travis <travis@sgi.com> wrote:
> Subject: [PATCH 1/1] kthread: Reduce stack pressure in create_kthread and kthreadd
>
> * Replace:
>
> set_cpus_allowed(..., CPU_MASK_ALL)
>
> with:
>
> set_cpus_allowed_ptr(..., CPU_MASK_ALL_PTR)
>
> to remove excessive stack requirements when NR_CPUS=4096.
>
> Based on linux-2.6.tip/master
applied to tip/core/urgent, thanks Mike.
Ingo
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-07-18 16:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-08 22:55 [PATCH 1/1] kthread: Reduce stack pressure in create_kthread and kthreadd Mike Travis
2008-07-18 16:47 ` Ingo Molnar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox