summaryrefslogtreecommitdiffstats
path: root/bsps/include/bsp/irq-generic.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2021-07-05 13:28:02 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2021-07-26 17:08:42 +0200
commitdeb5afb2f201d26cc618c2d56cd75de179341120 (patch)
treed377beba75dae8e28302cea3fb983ce47c3147df /bsps/include/bsp/irq-generic.h
parentbsps/irq: Add rtems_interrupt_get_attributes() (diff)
downloadrtems-deb5afb2f201d26cc618c2d56cd75de179341120.tar.bz2
bsps/irq: Add rtems_interrupt_is_pending()
Add a default implementation which just returns RTEMS_UNSATISFIED. Update #3269.
Diffstat (limited to 'bsps/include/bsp/irq-generic.h')
-rw-r--r--bsps/include/bsp/irq-generic.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/bsps/include/bsp/irq-generic.h b/bsps/include/bsp/irq-generic.h
index cdd269a3af..c7888b5be4 100644
--- a/bsps/include/bsp/irq-generic.h
+++ b/bsps/include/bsp/irq-generic.h
@@ -291,6 +291,32 @@ void bsp_interrupt_vector_enable(rtems_vector_number vector);
void bsp_interrupt_vector_disable(rtems_vector_number vector);
/**
+ * @brief Checks if the interrupt is pending.
+ *
+ * The function checks if the interrupt associated with the interrupt vector
+ * specified by ``vector`` was pending for the processor executing the function
+ * call at some time point during the call.
+ *
+ * @param vector is the interrupt vector number. It shall be valid.
+ *
+ * @param[out] pending is the pointer to a ``bool`` object. It shall not be
+ * ``NULL``. When the function call is successful, the pending status of
+ * the interrupt associated with the interrupt vector specified by ``vector``
+ * will be stored in this object. When the interrupt was pending for the
+ * processor executing the function call at some time point during the call,
+ * the object will be set to true, otherwise to false.
+ *
+ * @retval ::RTEMS_SUCCESSFUL The requested operation was successful.
+ *
+ * @retval ::RTEMS_UNSATISFIED The request to get the pending status has not
+ * been satisfied.
+ */
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+);
+
+/**
* @brief Causes the interrupt vector.
*
* @param vector is the number of the interrupt vector to cause. It shall be