[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200810081127.05311.rusty@rustcorp.com.au>
Date: Wed, 8 Oct 2008 10:27:04 +1000
From: Rusty Russell <rusty@...tcorp.com.au>
To: Heiko Carstens <heiko.carstens@...ibm.com>
Cc: jens.axboe@...cle.com, schwidefsky@...ibm.com,
linux-kernel@...r.kernel.org, Ingo Molnar <mingo@...e.hu>
Subject: Re: [PATCH/RFC 0/4] Add stop_machine_get/put_threads to stop_machine infrastructrue.
On Wednesday 08 October 2008 02:38:54 Heiko Carstens wrote:
> On Tue, Oct 07, 2008 at 11:39:58AM +1000, Rusty Russell wrote:
> > That's exactly my idea. We kmalloc already because NR_CPUS might be too
> > big for the stack. This version would just kmalloc a struct containing
> > everything we need.
>
> Ok, I did that but the resulting code is astonishingly ugly, so I thought I
> should share it :)
Yeah, the diffstat tells the story.
> Another thing that comes to mind is cpu hotplug: if somebody issued
> stop_machine_prepare() and then a cpu hotplug operation gets started we
> need to create or kill a kstop thread. For that we need the "sm" so we can
> save/find the task_struct pointer of the thread.
Erk, good point. Suckage.
OK, idea #2. Let's just always have a kstopmachine thread running on every
online cpu. Is there a sane way to reuse the workqueue threads for this?
Thanks,
Rusty.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists