From 37a6ee0c67b2780f651e0d0a02fb048f55f5cf97 Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Fri, 12 Jun 2015 08:52:52 +0000 Subject: Fixed bug #600. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@8017 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/nil/ports/e200/nilcore.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'os/nil/ports/e200') diff --git a/os/nil/ports/e200/nilcore.h b/os/nil/ports/e200/nilcore.h index 9da268038..3405a9bc5 100644 --- a/os/nil/ports/e200/nilcore.h +++ b/os/nil/ports/e200/nilcore.h @@ -289,6 +289,18 @@ struct port_intctx { */ #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 -- cgit v1.2.3