summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pfinet/asm/system.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/pfinet/asm/system.h b/pfinet/asm/system.h
index 4dfc74e7..bb51a6fb 100644
--- a/pfinet/asm/system.h
+++ b/pfinet/asm/system.h
@@ -46,4 +46,24 @@ sti ()
mutex_unlock (&global_interrupt_lock);
}
+/* In threads set aside to be interrupt threads, they call this
+ before doing any real work, thus putting us into "interrupt"
+ mode. */
+extern inline void
+begin_interrupt ()
+{
+ mutex_lock (&global_interrupt_lock);
+ /* Should we suspend the current "user thread"? */
+}
+
+/* And then this, at the end of the real work. */
+extern inline void
+end_interrupt ()
+{
+ mutex_unlock (&global_interrupt_lock);
+ /* Likewise a resumption? */
+}
+
+
+
#endif