[PATCH v3 14/42] bsps/irq: Add rtems_interrupt_is_pending()
Sebastian Huber
sebastian.huber at embedded-brains.de
Fri Jul 23 13:56:22 UTC 2021
Add a default implementation which just returns RTEMS_UNSATISFIED.
Update #3269.
---
bsps/arm/beagle/irq/irq.c | 11 ++++++++++
bsps/arm/csb336/irq/irq.c | 11 ++++++++++
bsps/arm/csb337/irq/irq.c | 11 ++++++++++
bsps/arm/edb7312/irq/irq.c | 11 ++++++++++
bsps/arm/gumstix/irq/irq.c | 11 ++++++++++
bsps/arm/lpc24xx/irq/irq.c | 11 ++++++++++
bsps/arm/lpc32xx/irq/irq.c | 11 ++++++++++
bsps/arm/raspberrypi/irq/irq.c | 11 ++++++++++
bsps/arm/rtl22xx/irq/irq.c | 11 ++++++++++
bsps/arm/shared/irq/irq-armv7m.c | 11 ++++++++++
bsps/arm/smdk2410/irq/irq.c | 11 ++++++++++
bsps/arm/tms570/irq/irq.c | 11 ++++++++++
bsps/i386/shared/irq/irq.c | 11 ++++++++++
bsps/include/bsp/irq-generic.h | 26 +++++++++++++++++++++++
bsps/lm32/shared/irq/irq.c | 11 ++++++++++
bsps/m68k/genmcf548x/irq/irq.c | 11 ++++++++++
bsps/mips/shared/irq/irq.c | 11 ++++++++++
bsps/powerpc/gen5200/irq/irq.c | 11 ++++++++++
bsps/powerpc/gen83xx/irq/irq.c | 11 ++++++++++
bsps/powerpc/mpc55xxevb/start/irq.c | 11 ++++++++++
bsps/powerpc/mpc8260ads/irq/irq.c | 11 ++++++++++
bsps/powerpc/psim/irq/irq_init.c | 11 ++++++++++
bsps/powerpc/qemuppc/irq/irq_init.c | 11 ++++++++++
bsps/powerpc/qoriq/irq/irq.c | 22 +++++++++++++++++++
bsps/powerpc/shared/irq/ppc-irq-generic.c | 11 ++++++++++
bsps/powerpc/t32mppc/irq/irq.c | 11 ++++++++++
bsps/powerpc/tqm8xx/irq/irq.c | 11 ++++++++++
bsps/powerpc/virtex/irq/irq_init.c | 11 ++++++++++
bsps/riscv/griscv/irq/irq.c | 11 ++++++++++
bsps/riscv/riscv/irq/irq.c | 11 ++++++++++
bsps/shared/dev/irq/arm-gicv2.c | 11 ++++++++++
bsps/shared/dev/irq/arm-gicv3.c | 11 ++++++++++
bsps/shared/irq/irq-default.c | 11 ++++++++++
bsps/shared/irq/irq-raise-clear.c | 17 ++++++++++++++-
bsps/sparc/leon3/start/eirq.c | 11 ++++++++++
bsps/sparc/shared/irq/irq-shared.c | 11 ++++++++++
bsps/x86_64/amd64/interrupts/idt.c | 11 ++++++++++
37 files changed, 438 insertions(+), 1 deletion(-)
diff --git a/bsps/arm/beagle/irq/irq.c b/bsps/arm/beagle/irq/irq.c
index 0285e46442..b0b7f77011 100644
--- a/bsps/arm/beagle/irq/irq.c
+++ b/bsps/arm/beagle/irq/irq.c
@@ -103,6 +103,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/csb336/irq/irq.c b/bsps/arm/csb336/irq/irq.c
index 85137195ef..c16a6d8773 100644
--- a/bsps/arm/csb336/irq/irq.c
+++ b/bsps/arm/csb336/irq/irq.c
@@ -34,6 +34,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/csb337/irq/irq.c b/bsps/arm/csb337/irq/irq.c
index e06c9f20b6..98d775ce28 100644
--- a/bsps/arm/csb337/irq/irq.c
+++ b/bsps/arm/csb337/irq/irq.c
@@ -35,6 +35,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/edb7312/irq/irq.c b/bsps/arm/edb7312/irq/irq.c
index c1d166049b..9a64e069d0 100644
--- a/bsps/arm/edb7312/irq/irq.c
+++ b/bsps/arm/edb7312/irq/irq.c
@@ -35,6 +35,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/gumstix/irq/irq.c b/bsps/arm/gumstix/irq/irq.c
index 8d66edaaf6..ff465c0308 100644
--- a/bsps/arm/gumstix/irq/irq.c
+++ b/bsps/arm/gumstix/irq/irq.c
@@ -32,6 +32,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/lpc24xx/irq/irq.c b/bsps/arm/lpc24xx/irq/irq.c
index 6260f2206f..0475bb2cc7 100644
--- a/bsps/arm/lpc24xx/irq/irq.c
+++ b/bsps/arm/lpc24xx/irq/irq.c
@@ -72,6 +72,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/lpc32xx/irq/irq.c b/bsps/arm/lpc32xx/irq/irq.c
index 20a1dffcee..73c91defb5 100644
--- a/bsps/arm/lpc32xx/irq/irq.c
+++ b/bsps/arm/lpc32xx/irq/irq.c
@@ -268,6 +268,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/raspberrypi/irq/irq.c b/bsps/arm/raspberrypi/irq/irq.c
index c49f8300dd..96a7d6d42d 100644
--- a/bsps/arm/raspberrypi/irq/irq.c
+++ b/bsps/arm/raspberrypi/irq/irq.c
@@ -151,6 +151,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/rtl22xx/irq/irq.c b/bsps/arm/rtl22xx/irq/irq.c
index af4e0bffaa..1600745d19 100644
--- a/bsps/arm/rtl22xx/irq/irq.c
+++ b/bsps/arm/rtl22xx/irq/irq.c
@@ -34,6 +34,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/shared/irq/irq-armv7m.c b/bsps/arm/shared/irq/irq-armv7m.c
index 07db0e714c..6b11fc88ca 100644
--- a/bsps/arm/shared/irq/irq-armv7m.c
+++ b/bsps/arm/shared/irq/irq-armv7m.c
@@ -46,6 +46,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/smdk2410/irq/irq.c b/bsps/arm/smdk2410/irq/irq.c
index 9b134445b0..ac9067299f 100644
--- a/bsps/arm/smdk2410/irq/irq.c
+++ b/bsps/arm/smdk2410/irq/irq.c
@@ -35,6 +35,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/arm/tms570/irq/irq.c b/bsps/arm/tms570/irq/irq.c
index 78c5b31038..ec088d9b6b 100644
--- a/bsps/arm/tms570/irq/irq.c
+++ b/bsps/arm/tms570/irq/irq.c
@@ -104,6 +104,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/i386/shared/irq/irq.c b/bsps/i386/shared/irq/irq.c
index 7c9c84140f..b1bf04dd1b 100644
--- a/bsps/i386/shared/irq/irq.c
+++ b/bsps/i386/shared/irq/irq.c
@@ -278,6 +278,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
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
@@ -290,6 +290,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.
*
diff --git a/bsps/lm32/shared/irq/irq.c b/bsps/lm32/shared/irq/irq.c
index e89dd1f4d6..7a1d10db92 100644
--- a/bsps/lm32/shared/irq/irq.c
+++ b/bsps/lm32/shared/irq/irq.c
@@ -25,6 +25,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/m68k/genmcf548x/irq/irq.c b/bsps/m68k/genmcf548x/irq/irq.c
index a51cf83c47..81dbf08fa4 100644
--- a/bsps/m68k/genmcf548x/irq/irq.c
+++ b/bsps/m68k/genmcf548x/irq/irq.c
@@ -67,6 +67,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/mips/shared/irq/irq.c b/bsps/mips/shared/irq/irq.c
index daeb368e5c..b78ea7a2a0 100644
--- a/bsps/mips/shared/irq/irq.c
+++ b/bsps/mips/shared/irq/irq.c
@@ -75,6 +75,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/gen5200/irq/irq.c b/bsps/powerpc/gen5200/irq/irq.c
index bbe409227f..07b080a335 100644
--- a/bsps/powerpc/gen5200/irq/irq.c
+++ b/bsps/powerpc/gen5200/irq/irq.c
@@ -365,6 +365,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/gen83xx/irq/irq.c b/bsps/powerpc/gen83xx/irq/irq.c
index ab8e13f70e..918e398e9b 100644
--- a/bsps/powerpc/gen83xx/irq/irq.c
+++ b/bsps/powerpc/gen83xx/irq/irq.c
@@ -382,6 +382,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/mpc55xxevb/start/irq.c b/bsps/powerpc/mpc55xxevb/start/irq.c
index dac0efa5e6..246dfb11a5 100644
--- a/bsps/powerpc/mpc55xxevb/start/irq.c
+++ b/bsps/powerpc/mpc55xxevb/start/irq.c
@@ -160,6 +160,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/mpc8260ads/irq/irq.c b/bsps/powerpc/mpc8260ads/irq/irq.c
index ce8642c2b0..7b536aa73b 100644
--- a/bsps/powerpc/mpc8260ads/irq/irq.c
+++ b/bsps/powerpc/mpc8260ads/irq/irq.c
@@ -336,6 +336,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/psim/irq/irq_init.c b/bsps/powerpc/psim/irq/irq_init.c
index 9a4898fa17..a278e2c3bd 100644
--- a/bsps/powerpc/psim/irq/irq_init.c
+++ b/bsps/powerpc/psim/irq/irq_init.c
@@ -110,6 +110,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/qemuppc/irq/irq_init.c b/bsps/powerpc/qemuppc/irq/irq_init.c
index 3665785fb9..bf7cb4e77d 100644
--- a/bsps/powerpc/qemuppc/irq/irq_init.c
+++ b/bsps/powerpc/qemuppc/irq/irq_init.c
@@ -41,6 +41,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/qoriq/irq/irq.c b/bsps/powerpc/qoriq/irq/irq.c
index 7175e6a201..141a2a85fc 100644
--- a/bsps/powerpc/qoriq/irq/irq.c
+++ b/bsps/powerpc/qoriq/irq/irq.c
@@ -85,6 +85,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
@@ -340,6 +351,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/shared/irq/ppc-irq-generic.c b/bsps/powerpc/shared/irq/ppc-irq-generic.c
index 5f54523014..60d9ad476e 100644
--- a/bsps/powerpc/shared/irq/ppc-irq-generic.c
+++ b/bsps/powerpc/shared/irq/ppc-irq-generic.c
@@ -103,6 +103,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/t32mppc/irq/irq.c b/bsps/powerpc/t32mppc/irq/irq.c
index f5edbf5691..27afe14f29 100644
--- a/bsps/powerpc/t32mppc/irq/irq.c
+++ b/bsps/powerpc/t32mppc/irq/irq.c
@@ -24,6 +24,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/tqm8xx/irq/irq.c b/bsps/powerpc/tqm8xx/irq/irq.c
index b4a66aecba..479e7ca705 100644
--- a/bsps/powerpc/tqm8xx/irq/irq.c
+++ b/bsps/powerpc/tqm8xx/irq/irq.c
@@ -69,6 +69,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/powerpc/virtex/irq/irq_init.c b/bsps/powerpc/virtex/irq/irq_init.c
index 5adc78b2c4..0f1d6e7d6f 100644
--- a/bsps/powerpc/virtex/irq/irq_init.c
+++ b/bsps/powerpc/virtex/irq/irq_init.c
@@ -138,6 +138,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/riscv/griscv/irq/irq.c b/bsps/riscv/griscv/irq/irq.c
index c20afdd8cc..ae2aedf8bc 100644
--- a/bsps/riscv/griscv/irq/irq.c
+++ b/bsps/riscv/griscv/irq/irq.c
@@ -95,6 +95,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/riscv/riscv/irq/irq.c b/bsps/riscv/riscv/irq/irq.c
index b655825a8e..1f74169579 100644
--- a/bsps/riscv/riscv/irq/irq.c
+++ b/bsps/riscv/riscv/irq/irq.c
@@ -234,6 +234,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/shared/dev/irq/arm-gicv2.c b/bsps/shared/dev/irq/arm-gicv2.c
index 509449c47d..f53137c17b 100644
--- a/bsps/shared/dev/irq/arm-gicv2.c
+++ b/bsps/shared/dev/irq/arm-gicv2.c
@@ -72,6 +72,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/shared/dev/irq/arm-gicv3.c b/bsps/shared/dev/irq/arm-gicv3.c
index 7223ec1039..fc48f4349d 100644
--- a/bsps/shared/dev/irq/arm-gicv3.c
+++ b/bsps/shared/dev/irq/arm-gicv3.c
@@ -172,6 +172,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/shared/irq/irq-default.c b/bsps/shared/irq/irq-default.c
index 745e1eb139..09e0cec052 100644
--- a/bsps/shared/irq/irq-default.c
+++ b/bsps/shared/irq/irq-default.c
@@ -45,6 +45,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/shared/irq/irq-raise-clear.c b/bsps/shared/irq/irq-raise-clear.c
index a0569f5948..93e414b2d1 100644
--- a/bsps/shared/irq/irq-raise-clear.c
+++ b/bsps/shared/irq/irq-raise-clear.c
@@ -6,7 +6,6 @@
* @ingroup bsp_interrupt
*
* @brief This source file contains the implementation of
- * rtems_interrupt_raise(), rtems_interrupt_raise_on() and
* rtems_interrupt_clear().
*/
@@ -41,6 +40,22 @@
#include <rtems/score/smpimpl.h>
#include <rtems/config.h>
+rtems_status_code rtems_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ if ( pending == NULL ) {
+ return RTEMS_INVALID_ADDRESS;
+ }
+
+ if ( !bsp_interrupt_is_valid_vector( vector ) ) {
+ return RTEMS_INVALID_ID;
+ }
+
+ return bsp_interrupt_is_pending( vector, pending );
+}
+
rtems_status_code rtems_interrupt_raise( rtems_vector_number vector )
{
if ( !bsp_interrupt_is_valid_vector( vector ) ) {
diff --git a/bsps/sparc/leon3/start/eirq.c b/bsps/sparc/leon3/start/eirq.c
index 60f87fafa8..8527cdb645 100644
--- a/bsps/sparc/leon3/start/eirq.c
+++ b/bsps/sparc/leon3/start/eirq.c
@@ -69,6 +69,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/sparc/shared/irq/irq-shared.c b/bsps/sparc/shared/irq/irq-shared.c
index ab08a920a4..9f85d9298a 100644
--- a/bsps/sparc/shared/irq/irq-shared.c
+++ b/bsps/sparc/shared/irq/irq-shared.c
@@ -40,6 +40,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
diff --git a/bsps/x86_64/amd64/interrupts/idt.c b/bsps/x86_64/amd64/interrupts/idt.c
index 897fd906b1..4cb71a6c66 100644
--- a/bsps/x86_64/amd64/interrupts/idt.c
+++ b/bsps/x86_64/amd64/interrupts/idt.c
@@ -154,6 +154,17 @@ rtems_status_code bsp_interrupt_get_attributes(
return RTEMS_SUCCESSFUL;
}
+rtems_status_code bsp_interrupt_is_pending(
+ rtems_vector_number vector,
+ bool *pending
+)
+{
+ bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+ bsp_interrupt_assert(pending != NULL);
+ *pending = false;
+ return RTEMS_UNSATISFIED;
+}
+
rtems_status_code bsp_interrupt_raise(rtems_vector_number vector)
{
bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
--
2.26.2
More information about the devel
mailing list