From: Avi Kivity <avi@qumranet.com>
To: Manfred Spraul <manfred@colorfullife.com>
Cc: linux-kernel@vger.kernel.org, paulmck@linux.vnet.ibm.com,
Ingo Molnar <mingo@elte.hu>,
akpm@linux-foundation.org
Subject: Re: [PATCH] kernel/cpu.c: Move the CPU_DYING notifiers
Date: Sat, 13 Sep 2008 09:36:06 +0300 [thread overview]
Message-ID: <48CB5F56.5050001@qumranet.com> (raw)
In-Reply-To: <200808311809.m7VI9whf014532@mail.q-ag.de>
Manfred Spraul wrote:
> When a cpu is taken offline, the CPU_DYING notifiers are called on the
> dying cpu. According to <linux/notifiers.h>, the cpu should be "not
> running any task, not handling interrupts, soon dead".
>
> For the current implementation, this is not true:
> - __cpu_disable can fail. If it fails, then the cpu will remain alive
> and happy.
> - At least on x86, __cpu_disable() briefly enables the local interrupts
> to handle any outstanding interrupts.
>
> What about moving CPU_DYING down a few lines, behind the __cpu_disable()
> line?
> There are only two CPU_DYING handlers in the kernel right now: one in
> kvm, one in the scheduler. Both should work with the patch applied
> [and: I'm not sure if either one handles a failing __cpu_disable()]
>
> The patch survives simple offlining a cpu. kvm untested due to lack
> of a test setup.
>
>
kvm should work with this patch.
--
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.
prev parent reply other threads:[~2008-09-13 6:36 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-31 17:58 [PATCH] kernel/cpu.c: Move the CPU_DYING notifiers Manfred Spraul
2008-08-31 19:17 ` Paul E. McKenney
2008-08-31 19:23 ` Paul E. McKenney
2008-09-06 16:49 ` Ingo Molnar
2008-09-06 17:08 ` Manfred Spraul
2008-09-06 17:13 ` Ingo Molnar
2008-09-13 6:36 ` Avi Kivity [this message]
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=48CB5F56.5050001@qumranet.com \
--to=avi@qumranet.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=manfred@colorfullife.com \
--cc=mingo@elte.hu \
--cc=paulmck@linux.vnet.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