* [PATCH] x86: call stop_machine_text_poke() on all CPUs
@ 2011-10-27 7:54 Rabin Vincent
2011-10-28 2:28 ` Masami Hiramatsu
2011-11-18 23:35 ` [tip:x86/urgent] x86: Call " tip-bot for Rabin Vincent
0 siblings, 2 replies; 5+ messages in thread
From: Rabin Vincent @ 2011-10-27 7:54 UTC (permalink / raw)
To: x86
Cc: linux-kernel, Rabin Vincent, Mathieu Desnoyers, Masami Hiramatsu,
Jason Baron, Peter Zijlstra
It appears that stop_machine_text_poke() wants to be called on all CPUs,
like it's done from text_poke_smp(). Fix text_poke_smp_batch() to do
this.
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Cc: Jason Baron <jbaron@redhat.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Rabin Vincent <rabin@rab.in>
---
arch/x86/kernel/alternative.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative.c
index c638228..1f84794 100644
--- a/arch/x86/kernel/alternative.c
+++ b/arch/x86/kernel/alternative.c
@@ -738,5 +738,5 @@ void __kprobes text_poke_smp_batch(struct text_poke_param *params, int n)
atomic_set(&stop_machine_first, 1);
wrote_text = 0;
- __stop_machine(stop_machine_text_poke, (void *)&tpp, NULL);
+ __stop_machine(stop_machine_text_poke, (void *)&tpp, cpu_online_mask);
}
--
1.7.7
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] x86: call stop_machine_text_poke() on all CPUs
2011-10-27 7:54 [PATCH] x86: call stop_machine_text_poke() on all CPUs Rabin Vincent
@ 2011-10-28 2:28 ` Masami Hiramatsu
2011-10-28 12:30 ` Rabin Vincent
2011-11-18 23:35 ` [tip:x86/urgent] x86: Call " tip-bot for Rabin Vincent
1 sibling, 1 reply; 5+ messages in thread
From: Masami Hiramatsu @ 2011-10-28 2:28 UTC (permalink / raw)
To: Rabin Vincent
Cc: x86, linux-kernel, Mathieu Desnoyers, Jason Baron, Peter Zijlstra
(2011/10/27 16:54), Rabin Vincent wrote:
> It appears that stop_machine_text_poke() wants to be called on all CPUs,
> like it's done from text_poke_smp(). Fix text_poke_smp_batch() to do
> this.
cpu_mask==NULL finally falls back to cpu_online_mask, but even though
it should be specified correctly.
Acked-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Thank you!
>
> Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
> Cc: Jason Baron <jbaron@redhat.com>
> Cc: Peter Zijlstra <peterz@infradead.org>
> Signed-off-by: Rabin Vincent <rabin@rab.in>
> ---
> arch/x86/kernel/alternative.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative.c
> index c638228..1f84794 100644
> --- a/arch/x86/kernel/alternative.c
> +++ b/arch/x86/kernel/alternative.c
> @@ -738,5 +738,5 @@ void __kprobes text_poke_smp_batch(struct text_poke_param *params, int n)
>
> atomic_set(&stop_machine_first, 1);
> wrote_text = 0;
> - __stop_machine(stop_machine_text_poke, (void *)&tpp, NULL);
> + __stop_machine(stop_machine_text_poke, (void *)&tpp, cpu_online_mask);
> }
--
Masami HIRAMATSU
Software Platform Research Dept. Linux Technology Center
Hitachi, Ltd., Yokohama Research Laboratory
E-mail: masami.hiramatsu.pt@hitachi.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] x86: call stop_machine_text_poke() on all CPUs
2011-10-28 2:28 ` Masami Hiramatsu
@ 2011-10-28 12:30 ` Rabin Vincent
2011-11-01 12:04 ` Masami Hiramatsu
0 siblings, 1 reply; 5+ messages in thread
From: Rabin Vincent @ 2011-10-28 12:30 UTC (permalink / raw)
To: Masami Hiramatsu
Cc: x86, linux-kernel, Mathieu Desnoyers, Jason Baron, Peter Zijlstra
On Fri, Oct 28, 2011 at 11:28:39AM +0900, Masami Hiramatsu wrote:
> (2011/10/27 16:54), Rabin Vincent wrote:
> > It appears that stop_machine_text_poke() wants to be called on all CPUs,
> > like it's done from text_poke_smp(). Fix text_poke_smp_batch() to do
> > this.
>
> cpu_mask==NULL finally falls back to cpu_online_mask, but even though
> it should be specified correctly.
Not quite. Passing NULL to __stop_machine means that the function will
be called on any one CPU only, while passing cpu_online_mask means that
the function will be called on all CPUs. So this patch is a behaviour
change/bug fix, not just a clarification.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] x86: call stop_machine_text_poke() on all CPUs
2011-10-28 12:30 ` Rabin Vincent
@ 2011-11-01 12:04 ` Masami Hiramatsu
0 siblings, 0 replies; 5+ messages in thread
From: Masami Hiramatsu @ 2011-11-01 12:04 UTC (permalink / raw)
To: Rabin Vincent
Cc: x86, linux-kernel, Mathieu Desnoyers, Jason Baron, Peter Zijlstra
(2011/10/28 21:30), Rabin Vincent wrote:
> On Fri, Oct 28, 2011 at 11:28:39AM +0900, Masami Hiramatsu wrote:
>> (2011/10/27 16:54), Rabin Vincent wrote:
>>> It appears that stop_machine_text_poke() wants to be called on all CPUs,
>>> like it's done from text_poke_smp(). Fix text_poke_smp_batch() to do
>>> this.
>>
>> cpu_mask==NULL finally falls back to cpu_online_mask, but even though
>> it should be specified correctly.
>
> Not quite. Passing NULL to __stop_machine means that the function will
> be called on any one CPU only, while passing cpu_online_mask means that
> the function will be called on all CPUs. So this patch is a behaviour
> change/bug fix, not just a clarification.
Aah, Right! I just misunderstood.
Then this must be a bugfix!
Thanks!
--
Masami HIRAMATSU
Software Platform Research Dept. Linux Technology Center
Hitachi, Ltd., Yokohama Research Laboratory
E-mail: masami.hiramatsu.pt@hitachi.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* [tip:x86/urgent] x86: Call stop_machine_text_poke() on all CPUs
2011-10-27 7:54 [PATCH] x86: call stop_machine_text_poke() on all CPUs Rabin Vincent
2011-10-28 2:28 ` Masami Hiramatsu
@ 2011-11-18 23:35 ` tip-bot for Rabin Vincent
1 sibling, 0 replies; 5+ messages in thread
From: tip-bot for Rabin Vincent @ 2011-11-18 23:35 UTC (permalink / raw)
To: linux-tip-commits
Cc: linux-kernel, hpa, mingo, mathieu.desnoyers, rabin, a.p.zijlstra,
masami.hiramatsu.pt, tglx, jbaron, mingo
Commit-ID: 78345d2edc25e001558f3b7c85906f645d38d23c
Gitweb: http://git.kernel.org/tip/78345d2edc25e001558f3b7c85906f645d38d23c
Author: Rabin Vincent <rabin@rab.in>
AuthorDate: Thu, 27 Oct 2011 13:24:32 +0530
Committer: Ingo Molnar <mingo@elte.hu>
CommitDate: Mon, 14 Nov 2011 13:05:15 +0100
x86: Call stop_machine_text_poke() on all CPUs
It appears that stop_machine_text_poke() wants to be called on all CPUs,
like it's done from text_poke_smp(). Fix text_poke_smp_batch() to do
this.
Signed-off-by: Rabin Vincent <rabin@rab.in>
Acked-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: Jason Baron <jbaron@redhat.com>
Link: http://lkml.kernel.org/r/1319702072-32676-1-git-send-email-rabin@rab.in
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
arch/x86/kernel/alternative.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative.c
index c638228..1f84794 100644
--- a/arch/x86/kernel/alternative.c
+++ b/arch/x86/kernel/alternative.c
@@ -738,5 +738,5 @@ void __kprobes text_poke_smp_batch(struct text_poke_param *params, int n)
atomic_set(&stop_machine_first, 1);
wrote_text = 0;
- __stop_machine(stop_machine_text_poke, (void *)&tpp, NULL);
+ __stop_machine(stop_machine_text_poke, (void *)&tpp, cpu_online_mask);
}
^ permalink raw reply related [flat|nested] 5+ messages in thread
end of thread, other threads:[~2011-11-18 23:35 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-27 7:54 [PATCH] x86: call stop_machine_text_poke() on all CPUs Rabin Vincent
2011-10-28 2:28 ` Masami Hiramatsu
2011-10-28 12:30 ` Rabin Vincent
2011-11-01 12:04 ` Masami Hiramatsu
2011-11-18 23:35 ` [tip:x86/urgent] x86: Call " tip-bot for Rabin Vincent
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).