aboutsummaryrefslogtreecommitdiffstats
path: root/os/rt/ports/e200/chcore.h
diff options
context:
space:
mode:
authorGiovanni Di Sirio <gdisirio@gmail.com>2015-06-12 08:52:52 +0000
committerGiovanni Di Sirio <gdisirio@gmail.com>2015-06-12 08:52:52 +0000
commit37a6ee0c67b2780f651e0d0a02fb048f55f5cf97 (patch)
treeaa74b4dc519272e126c97b22a0a3f642b2617ff4 /os/rt/ports/e200/chcore.h
parentbc9dcab2c8863fd1c3b09d2db164606b2e21a70d (diff)
downloadChibiOS-37a6ee0c67b2780f651e0d0a02fb048f55f5cf97.tar.gz
ChibiOS-37a6ee0c67b2780f651e0d0a02fb048f55f5cf97.tar.bz2
ChibiOS-37a6ee0c67b2780f651e0d0a02fb048f55f5cf97.zip
Fixed bug #600.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@8017 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/rt/ports/e200/chcore.h')
-rw-r--r--os/rt/ports/e200/chcore.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/os/rt/ports/e200/chcore.h b/os/rt/ports/e200/chcore.h
index f1485b81a..c0b96e2df 100644
--- a/os/rt/ports/e200/chcore.h
+++ b/os/rt/ports/e200/chcore.h
@@ -331,6 +331,18 @@ struct context {
#define PORT_FAST_IRQ_HANDLER(id) void id(void)
/**
+ * @brief Priority level verification macro.
+ */
+#define PORT_IRQ_IS_VALID_PRIORITY(n) \
+ (((n) >= 0U) && ((n) < INTC_PRIORITY_LEVELS))
+
+/**
+ * @brief Priority level verification macro.
+ */
+#define PORT_IRQ_IS_VALID_KERNEL_PRIORITY(n) \
+ (((n) >= 0U) && ((n) < INTC_PRIORITY_LEVELS))
+
+/**
* @brief Performs a context switch between two threads.
* @details This is the most critical code in any port, this function
* is responsible for the context switch between 2 threads.