From 03d569d3e8ee6f405b8e8489eaaf325c774b822d Mon Sep 17 00:00:00 2001 From: fche Date: Wed, 22 Feb 2006 15:05:50 +0000 Subject: 2006-02-22 Frank Ch. Eigler PR 2293. * tapsets.cxx (emit_probe_epilogue): Emit early local_irq_save(). (emit_probe_epilogue): ... and matching _restore(). * main.cxx (main): Emit a "hello, I'm starting" message before pass 5 in verbose mode. --- tapsets.cxx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'tapsets.cxx') diff --git a/tapsets.cxx b/tapsets.cxx index 5919d241..31b2515a 100644 --- a/tapsets.cxx +++ b/tapsets.cxx @@ -91,8 +91,10 @@ void derived_probe::emit_probe_prologue (translator_output* o, const std::string& statereq) { - o->newline() << "struct context* c = per_cpu_ptr " - << "(contexts, smp_processor_id());"; + o->newline() << "struct context* c;"; + o->newline() << "unsigned long flags;"; + o->newline() << "local_irq_save (flags);"; + o->newline() << "c = per_cpu_ptr (contexts, smp_processor_id());"; o->newline() << "if (atomic_read (&session_state) != " << statereq << ")"; o->newline(1) << "goto probe_epilogue;"; @@ -136,7 +138,7 @@ derived_probe::emit_probe_epilogue (translator_output* o) o->newline() << "atomic_dec (&c->busy);"; o->newline(-1) << "probe_epilogue: ;"; - o->indent(1); + o->newline(1) << "local_irq_restore (flags);"; } -- cgit