projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4a66a82
)
x86: ftrace - simplify wait_for_nmi
author
Cyrill Gorcunov
<gorcunov@gmail.com>
Mon, 26 Jan 2009 15:28:02 +0000
(18:28 +0300)
committer
Ingo Molnar
<mingo@elte.hu>
Tue, 27 Jan 2009 13:31:17 +0000
(14:31 +0100)
Get rid of 'waited' stack variable.
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/kernel/ftrace.c
patch
|
blob
|
blame
|
history
diff --git
a/arch/x86/kernel/ftrace.c
b/arch/x86/kernel/ftrace.c
index 1b43086b097a8489a85adcd41a3336fb0cde4f88..4d33224c055f71bcd40f089eb5f439fdd8370492 100644
(file)
--- a/
arch/x86/kernel/ftrace.c
+++ b/
arch/x86/kernel/ftrace.c
@@
-133,15
+133,14
@@
void ftrace_nmi_exit(void)
static void wait_for_nmi(void)
{
- int waited = 0;
+ if (!atomic_read(&in_nmi))
+ return;
- while (atomic_read(&in_nmi)) {
- waited = 1;
+ do {
cpu_relax();
- }
+ }
while(atomic_read(&in_nmi));
- if (waited)
- nmi_wait_count++;
+ nmi_wait_count++;
}
static int