From: Srivatsa Vaddagiri <vatsa@in.ibm.com>
To: rusty@au1.ibm.com, Ingo Molnar <mingo@elte.hu>,
Nick Piggin <nickpiggin@yahoo.com.au>
Cc: akpm@osdl.org, linux-kernel@vger.kernel.org,
lhcs-devel@lists.sourceforge.net
Subject: CPU Hotplug broken -mm5 onwards
Date: Sun, 18 Apr 2004 22:36:13 +0530 [thread overview]
Message-ID: <20040418170613.GA21769@in.ibm.com> (raw)
Hi,
I found that I can't boot with CONFIG_HOTPLUG_CPU defined in both
mm5 and mm6. Debugging this revealed it to be because exec path can now require
cpu hotplug sem (sched_migrate_task) and this has lead to a deadlock between
flush_workqueue and __call_usermodehelper.
flush_workqueue takes cpu hotplug sem and blocks until workqueue is flushed.
__call_usermodehelper, one of the queued work function, blocks because it
also needs cpu hotplug sem during exec. As of result of this, exec does not
progress and system does not boot.
I feel we can fix this by converting cpucontrol to a reader-writer semaphore or
big-reader-lock(?). One problem with reader-writer semaphore is there does not
seem to be any down_write_interruptible, which is needed by cpu_down/up.
Comments?
BTW, I think a cpu_is_offline check is needed in sched_migrate_task, since
dest_cpu could have been downed by the time it has acquired the semaphore.
In which case, we could end up adding the task to dead cpu's runqueue?
An alternate solution would be to put the same check in __migrate_task.
--
Thanks and Regards,
Srivatsa Vaddagiri,
Linux Technology Center,
IBM Software Labs,
Bangalore, INDIA - 560017
next reply other threads:[~2004-04-18 17:05 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-04-18 17:06 Srivatsa Vaddagiri [this message]
2004-04-19 3:34 ` CPU Hotplug broken -mm5 onwards Nick Piggin
2004-04-19 12:58 ` [lhcs-devel] " Srivatsa Vaddagiri
2004-04-19 22:55 ` Nick Piggin
2004-04-19 23:07 ` Rusty Russell
[not found] ` <20040421023650.24b9f85a.akpm@osdl.org>
[not found] ` <20040421095939.GB10767@in.ibm.com>
2004-04-21 16:44 ` Srivatsa Vaddagiri
2004-04-22 7:03 ` Andrew Morton
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20040418170613.GA21769@in.ibm.com \
--to=vatsa@in.ibm.com \
--cc=akpm@osdl.org \
--cc=lhcs-devel@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=nickpiggin@yahoo.com.au \
--cc=rusty@au1.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox