summaryrefslogtreecommitdiffstats
path: root/pk/kernel/pk_bh_core.c
diff options
context:
space:
mode:
authorGlenn Miles <milesg@us.ibm.com>2015-04-06 16:47:35 -0500
committerDerk Rembold <rembold@de.ibm.com>2015-04-21 09:37:29 -0500
commit43733c105f4cf5866e04502fe9506f375a5e6edb (patch)
tree8e66fd3fd1e4baf5be70f00fab4cc1b32011d40e /pk/kernel/pk_bh_core.c
parent7f2c101774507059eeedbe7744da4ad923c53405 (diff)
downloadtalos-sbe-43733c105f4cf5866e04502fe9506f375a5e6edb.tar.gz
talos-sbe-43733c105f4cf5866e04502fe9506f375a5e6edb.zip
Minor changes to kernel API
-Removed support for fast irq handlers -Removed sleep_absolute interface -Removed pk_timer_create_nonpreemptible interface -Removed pk_interrupt_preemption_enable/disable interfaces -Removed references to critical/noncritical irqs -Added application context interfaces -Added bottom-half support -Moved timer handler from interrupt to bottom-half -Moved thread utility functions into a separate file Change-Id: Ie39fe0363ef52b195a808a8390cc12c2c7478674 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/16898 Reviewed-by: Glenn R. Miles <milesg@us.ibm.com> Reviewed-by: Thi N. Tran <thi@us.ibm.com> Reviewed-by: Richard J. Knight <rjknight@us.ibm.com> Reviewed-by: Gregory S. Still <stillgs@us.ibm.com> Reviewed-by: Derk Rembold <rembold@de.ibm.com> Tested-by: Derk Rembold <rembold@de.ibm.com>
Diffstat (limited to 'pk/kernel/pk_bh_core.c')
-rw-r--r--pk/kernel/pk_bh_core.c29
1 files changed, 29 insertions, 0 deletions
diff --git a/pk/kernel/pk_bh_core.c b/pk/kernel/pk_bh_core.c
new file mode 100644
index 00000000..8a6181cb
--- /dev/null
+++ b/pk/kernel/pk_bh_core.c
@@ -0,0 +1,29 @@
+//-----------------------------------------------------------------------------
+// *! (C) Copyright International Business Machines Corp. 2015
+// *! All Rights Reserved -- Property of IBM
+// *! *** IBM Confidential ***
+//-----------------------------------------------------------------------------
+
+/// \file pk_bh_core.c
+/// \brief PK bottom half APIs
+///
+/// The entry points in this file are considered 'core' routines that will
+/// always be present at runtime in any PK application.
+
+#include "pk.h"
+
+/// Statically initialize the bottom half queue
+PK_DEQUE_SENTINEL_STATIC_CREATE(_pk_bh_queue);
+
+void _pk_process_bh(void)
+{
+ PkBottomHalf *bh;
+ while((bh = (PkBottomHalf*)pk_deque_pop_front(&_pk_bh_queue)) != 0)
+ {
+ bh->bh_handler(bh->arg);
+ }
+ return;
+}
+
+
+#undef __PK_THREAD_CORE_C__
OpenPOWER on IntegriCloud