summaryrefslogtreecommitdiffstats
path: root/cpukit/include/rtems/irq-extension.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2021-06-27 10:39:37 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2021-07-26 07:54:25 +0200
commit01e7c36b39f439c9dc600cc529178b3fbd09d6c9 (patch)
treee3fab0b6cb6c2aa24ecad1d1c0d2a103636f2b27 /cpukit/include/rtems/irq-extension.h
parent96265c87a3122e0bef52fb343a730408e747035a (diff)
downloadrtems-01e7c36b39f439c9dc600cc529178b3fbd09d6c9.tar.bz2
rtems: Add rtems_interrupt_vector_is_enabled()
Update #3269.
Diffstat (limited to '')
-rw-r--r--cpukit/include/rtems/irq-extension.h50
1 files changed, 50 insertions, 0 deletions
diff --git a/cpukit/include/rtems/irq-extension.h b/cpukit/include/rtems/irq-extension.h
index e0d63c9dcb..f538297b3c 100644
--- a/cpukit/include/rtems/irq-extension.h
+++ b/cpukit/include/rtems/irq-extension.h
@@ -315,6 +315,56 @@ rtems_status_code rtems_interrupt_handler_remove(
void *arg
);
+/* Generated from spec:/rtems/intr/if/vector-is-enabled */
+
+/**
+ * @ingroup RTEMSAPIClassicIntr
+ *
+ * @brief Checks if the interrupt vector is enabled.
+ *
+ * @param vector is the interrupt vector number.
+ *
+ * @param[out] enabled is the pointer to a ``bool`` object. When the directive
+ * call is successful, the enabled status of the interrupt associated with
+ * the interrupt vector specified by ``vector`` will be stored in this
+ * object. When the interrupt was enabled for the processor executing the
+ * directive call at some time point during the call, the object value will
+ * be set to true, otherwise to false.
+ *
+ * The directive checks if the interrupt associated with the interrupt vector
+ * specified by ``vector`` was enabled for the processor executing the
+ * directive call at some time point during the call.
+ *
+ * @retval ::RTEMS_SUCCESSFUL The requested operation was successful.
+ *
+ * @retval ::RTEMS_INVALID_ADDRESS The ``enabled`` parameter was NULL.
+ *
+ * @retval ::RTEMS_INVALID_ID There was no interrupt vector associated with the
+ * number specified by ``vector``.
+ *
+ * @par Notes
+ * Interrupt vectors may be enabled by rtems_interrupt_vector_enable() and
+ * disabled by rtems_interrupt_vector_disable().
+ *
+ * @par Constraints
+ * @parblock
+ * The following constraints apply to this directive:
+ *
+ * * The directive may be called from within interrupt context.
+ *
+ * * The directive may be called from within device driver initialization
+ * context.
+ *
+ * * The directive may be called from within task context.
+ *
+ * * The directive will not cause the calling task to be preempted.
+ * @endparblock
+ */
+rtems_status_code rtems_interrupt_vector_is_enabled(
+ rtems_vector_number vector,
+ bool *enabled
+);
+
/* Generated from spec:/rtems/intr/if/vector-enable */
/**