* [Adeos-main] [pull request] noarch: fix ftrace code patching
@ 2009-12-14 17:20 Jan Kiszka
0 siblings, 0 replies; only message in thread
From: Jan Kiszka @ 2009-12-14 17:20 UTC (permalink / raw)
To: Philippe Gerum; +Cc: adeos-main
The following changes since commit 779cfc6a68bcc9c4acb1eec3922c25eb43b08a2f:
Jan Kiszka (1):
Set oops_in_progress on failing context check
are available in the git repository at:
git://git.kiszka.org/ipipe-2.6 queues/2.6.31-noarch
Jan Kiszka (1):
Disable both real and virtual interrupts during ftrace code changes
kernel/trace/ftrace.c | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
------
Disable both real and virtual interrupts during ftrace code changes
This is required as the call stack contains some further local_irq_save/
restore which would otherwise reenable real interrupts spuriously.
Signed-off-by: Jan Kiszka <jan.kiszka@domain.hid>
---
kernel/trace/ftrace.c | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 5c007b6..9ca1e65 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -2802,9 +2802,11 @@ static int ftrace_convert_nops(struct module *mod,
}
/* disable interrupts to prevent kstop machine */
- local_irq_save_hw_notrace(flags);
+ local_irq_save(flags);
+ local_irq_disable_hw();
ftrace_update_code(mod);
- local_irq_restore_hw_notrace(flags);
+ local_irq_enable_hw();
+ local_irq_restore(flags);
mutex_unlock(&ftrace_lock);
return 0;
@@ -2887,9 +2889,11 @@ void __init ftrace_init(void)
/* Keep the ftrace pointer to the stub */
addr = (unsigned long)ftrace_stub;
- local_irq_save_hw_notrace(flags);
+ local_irq_save(flags);
+ local_irq_disable_hw();
ftrace_dyn_arch_init(&addr);
- local_irq_restore_hw_notrace(flags);
+ local_irq_enable_hw();
+ local_irq_restore(flags);
/* ftrace_dyn_arch_init places the return code in addr */
if (addr)
--
1.6.0.2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2009-12-14 17:20 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-14 17:20 [Adeos-main] [pull request] noarch: fix ftrace code patching Jan Kiszka
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.