[PATCH 16/41] bsps/irq: bsp_interrupt_vector_disable()

Sebastian Huber sebastian.huber at embedded-brains.de
Mon Jul 12 12:49:38 UTC 2021


Return a status code for bsp_interrupt_vector_disable().

Update #3269.
---
 bsps/arm/beagle/irq/irq.c                 |  3 ++-
 bsps/arm/csb336/irq/irq.c                 |  4 +++-
 bsps/arm/csb337/irq/irq.c                 |  3 ++-
 bsps/arm/edb7312/irq/irq.c                |  4 +++-
 bsps/arm/gumstix/irq/irq.c                |  3 ++-
 bsps/arm/lpc24xx/irq/irq.c                |  3 ++-
 bsps/arm/lpc32xx/irq/irq.c                |  4 +++-
 bsps/arm/raspberrypi/irq/irq.c            |  3 ++-
 bsps/arm/rtl22xx/irq/irq.c                |  3 ++-
 bsps/arm/shared/irq/irq-armv7m.c          |  3 ++-
 bsps/arm/smdk2410/irq/irq.c               |  3 ++-
 bsps/arm/tms570/irq/irq.c                 |  3 ++-
 bsps/i386/shared/irq/irq.c                |  3 ++-
 bsps/include/bsp/irq-generic.h            | 16 ++++++++++------
 bsps/lm32/shared/irq/irq.c                |  3 ++-
 bsps/m68k/genmcf548x/irq/irq.c            |  4 +++-
 bsps/mips/shared/irq/irq.c                |  3 ++-
 bsps/powerpc/gen5200/irq/irq.c            |  4 +++-
 bsps/powerpc/gen83xx/irq/irq.c            |  4 +++-
 bsps/powerpc/mpc55xxevb/start/irq.c       |  3 ++-
 bsps/powerpc/mpc8260ads/irq/irq.c         |  4 +++-
 bsps/powerpc/psim/irq/irq_init.c          |  3 ++-
 bsps/powerpc/qemuppc/irq/irq_init.c       |  3 ++-
 bsps/powerpc/qoriq/irq/irq.c              |  5 +++--
 bsps/powerpc/shared/irq/ppc-irq-generic.c |  3 ++-
 bsps/powerpc/t32mppc/irq/irq.c            |  3 ++-
 bsps/powerpc/tqm8xx/irq/irq.c             |  4 +++-
 bsps/powerpc/virtex/irq/irq_init.c        |  4 +++-
 bsps/riscv/griscv/irq/irq.c               |  3 ++-
 bsps/riscv/riscv/irq/irq.c                |  4 +++-
 bsps/shared/dev/irq/arm-gicv2.c           |  3 ++-
 bsps/shared/dev/irq/arm-gicv3.c           |  4 +++-
 bsps/shared/irq/irq-default.c             |  3 ++-
 bsps/shared/irq/irq-enable-disable.c      |  4 +---
 bsps/sparc/leon3/start/eirq.c             |  3 ++-
 bsps/sparc/shared/irq/irq-shared.c        |  3 ++-
 bsps/x86_64/amd64/interrupts/idt.c        |  3 ++-
 37 files changed, 93 insertions(+), 45 deletions(-)

diff --git a/bsps/arm/beagle/irq/irq.c b/bsps/arm/beagle/irq/irq.c
index 7953a2fe1f..7db3428499 100644
--- a/bsps/arm/beagle/irq/irq.c
+++ b/bsps/arm/beagle/irq/irq.c
@@ -150,7 +150,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   uint32_t mask, cur;
   uint32_t mir_reg = omap_get_mir_reg(vector, &mask);
@@ -160,6 +160,7 @@ void bsp_interrupt_vector_disable(rtems_vector_number vector)
   cur = mmio_read(omap_intr.base + mir_reg);
   mmio_write(omap_intr.base + mir_reg, cur | mask);
   flush_data_cache();
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/csb336/irq/irq.c b/bsps/arm/csb336/irq/irq.c
index d47f0362e8..2cf142100a 100644
--- a/bsps/arm/csb336/irq/irq.c
+++ b/bsps/arm/csb336/irq/irq.c
@@ -78,12 +78,14 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 
   if (vector < MC9328MXL_NUM_INTS)
     MC9328MXL_AITC_INTDISNUM = vector;
+
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/csb337/irq/irq.c b/bsps/arm/csb337/irq/irq.c
index a4bfb1f83b..b999841751 100644
--- a/bsps/arm/csb337/irq/irq.c
+++ b/bsps/arm/csb337/irq/irq.c
@@ -76,10 +76,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   AIC_CTL_REG(AIC_IDCR) = 1 << vector;
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/edb7312/irq/irq.c b/bsps/arm/edb7312/irq/irq.c
index 3cff5bfff2..ec50443775 100644
--- a/bsps/arm/edb7312/irq/irq.c
+++ b/bsps/arm/edb7312/irq/irq.c
@@ -97,7 +97,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
     return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
     bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 
@@ -121,6 +121,8 @@ void bsp_interrupt_vector_disable(rtems_vector_number vector)
         /* interrupt managed by INTMR3 and INTSR3 */
         *EP7312_INTMR3 &= ~(1 << (vector - 21));
     }
+
+    return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/gumstix/irq/irq.c b/bsps/arm/gumstix/irq/irq.c
index bba91f1d08..c590c74ca3 100644
--- a/bsps/arm/gumstix/irq/irq.c
+++ b/bsps/arm/gumstix/irq/irq.c
@@ -73,10 +73,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   XSCALE_INT_ICMR  &= ~(1 << vector);
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/lpc24xx/irq/irq.c b/bsps/arm/lpc24xx/irq/irq.c
index 2b266a0822..691c324739 100644
--- a/bsps/arm/lpc24xx/irq/irq.c
+++ b/bsps/arm/lpc24xx/irq/irq.c
@@ -113,10 +113,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   VICIntEnClear = 1U << vector;
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/lpc32xx/irq/irq.c b/bsps/arm/lpc32xx/irq/irq.c
index 5e8c93909f..67d7bb8b3e 100644
--- a/bsps/arm/lpc32xx/irq/irq.c
+++ b/bsps/arm/lpc32xx/irq/irq.c
@@ -316,7 +316,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   rtems_interrupt_level level;
 
@@ -326,6 +326,8 @@ void bsp_interrupt_vector_disable(rtems_vector_number vector)
   lpc32xx_irq_clear_bit_in_field(vector, &lpc32xx_irq_enable);
   lpc32xx_irq_clear_bit_in_register(vector, LPC32XX_IRQ_OFFSET_ER);
   rtems_interrupt_enable(level);
+
+  return RTEMS_SUCCESSFUL;
 }
 
 void lpc32xx_set_exception_handler(
diff --git a/bsps/arm/raspberrypi/irq/irq.c b/bsps/arm/raspberrypi/irq/irq.c
index 763ad30692..75fe2f3844 100644
--- a/bsps/arm/raspberrypi/irq/irq.c
+++ b/bsps/arm/raspberrypi/irq/irq.c
@@ -204,11 +204,12 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   BCM2835_REG(bsp_vector_to_reg(vector)->disable_reg_addr) =
               bsp_vector_to_mask(vector);
+  return RTEMS_SUCCESSFUL;
 }
 
 void bsp_interrupt_handler_default(rtems_vector_number vector)
diff --git a/bsps/arm/rtl22xx/irq/irq.c b/bsps/arm/rtl22xx/irq/irq.c
index 9fc8f1b3e8..c8810f3a4a 100644
--- a/bsps/arm/rtl22xx/irq/irq.c
+++ b/bsps/arm/rtl22xx/irq/irq.c
@@ -75,10 +75,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   VICIntEnClr = 1 << vector;
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/shared/irq/irq-armv7m.c b/bsps/arm/shared/irq/irq-armv7m.c
index a242071be5..b2bff9ce35 100644
--- a/bsps/arm/shared/irq/irq-armv7m.c
+++ b/bsps/arm/shared/irq/irq-armv7m.c
@@ -87,10 +87,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   _ARMV7M_NVIC_Clear_enable((int) vector);
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/smdk2410/irq/irq.c b/bsps/arm/smdk2410/irq/irq.c
index 95be366525..a6371767a8 100644
--- a/bsps/arm/smdk2410/irq/irq.c
+++ b/bsps/arm/smdk2410/irq/irq.c
@@ -75,9 +75,10 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/arm/tms570/irq/irq.c b/bsps/arm/tms570/irq/irq.c
index ef38ac32db..1d73a9b5a1 100644
--- a/bsps/arm/tms570/irq/irq.c
+++ b/bsps/arm/tms570/irq/irq.c
@@ -156,12 +156,13 @@ rtems_status_code bsp_interrupt_vector_enable(
  * @retval RTEMS_INVALID_ID vector is invalid.
  * @retval RTEMS_SUCCESSFUL interrupt source disabled.
  */
-void bsp_interrupt_vector_disable(
+rtems_status_code bsp_interrupt_vector_disable(
   rtems_vector_number vector
 )
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   TMS570_VIM.REQENACLR[vector >> 5] = 1 << (vector & 0x1f);
+  return RTEMS_SUCCESSFUL;
 }
 
 /**
diff --git a/bsps/i386/shared/irq/irq.c b/bsps/i386/shared/irq/irq.c
index ad278e6224..9aab9d27f2 100644
--- a/bsps/i386/shared/irq/irq.c
+++ b/bsps/i386/shared/irq/irq.c
@@ -319,10 +319,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   BSP_irq_disable_at_i8259a(vector);
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/include/bsp/irq-generic.h b/bsps/include/bsp/irq-generic.h
index 54b8501f96..68332d20b9 100644
--- a/bsps/include/bsp/irq-generic.h
+++ b/bsps/include/bsp/irq-generic.h
@@ -278,7 +278,7 @@ rtems_status_code bsp_interrupt_vector_is_enabled(
 rtems_status_code bsp_interrupt_vector_enable( rtems_vector_number vector );
 
 /**
- * @brief Disables the interrupt vector with number @a vector.
+ * @brief Disables the interrupt vector.
  *
  * This function shall disable the vector at the corresponding facility (in
  * most cases the interrupt controller).  It will be called then the last
@@ -286,13 +286,17 @@ rtems_status_code bsp_interrupt_vector_enable( rtems_vector_number vector );
  * example.
  *
  * @note The implementation should use
- * bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector)) to valdiate the
- * vector number.
+ * bsp_interrupt_assert( bsp_interrupt_is_valid_vector( vector ) ) to valdiate
+ * the vector number in ::RTEMS_DEBUG configurations.
+ *
+ * @param vector is the interrupt vector number.
  *
- * @note You must not install or remove an interrupt handler in this function.
- * This may result in a deadlock.
+ * @retval ::RTEMS_SUCCESSFUL The requested operation was successful.
+ *
+ * @retval ::RTEMS_UNSATISFIED The request to disable the interrupt vector has
+ *   not been satisfied.
  */
-void bsp_interrupt_vector_disable(rtems_vector_number vector);
+rtems_status_code bsp_interrupt_vector_disable( rtems_vector_number vector );
 
 /**
  * @brief Checks if the interrupt is pending.
diff --git a/bsps/lm32/shared/irq/irq.c b/bsps/lm32/shared/irq/irq.c
index 6ba09e9e27..d7898b1b68 100644
--- a/bsps/lm32/shared/irq/irq.c
+++ b/bsps/lm32/shared/irq/irq.c
@@ -66,8 +66,9 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   lm32_interrupt_mask(1 << vector);
+  return RTEMS_SUCCESSFUL;
 }
diff --git a/bsps/m68k/genmcf548x/irq/irq.c b/bsps/m68k/genmcf548x/irq/irq.c
index 372208e6ca..9d483918e4 100644
--- a/bsps/m68k/genmcf548x/irq/irq.c
+++ b/bsps/m68k/genmcf548x/irq/irq.c
@@ -116,7 +116,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   volatile uint32_t *imr = vector_to_imr(vector);
   uint32_t bit = vector_to_bit(vector);
@@ -127,6 +127,8 @@ void bsp_interrupt_vector_disable(rtems_vector_number vector)
   rtems_interrupt_disable(level);
   *imr |= bit;
   rtems_interrupt_enable(level);
+
+  return RTEMS_SUCCESSFUL;
 }
 
 static void_func get_exception_handler(rtems_vector_number vector)
diff --git a/bsps/mips/shared/irq/irq.c b/bsps/mips/shared/irq/irq.c
index 3e144d876b..96d3c14a2e 100644
--- a/bsps/mips/shared/irq/irq.c
+++ b/bsps/mips/shared/irq/irq.c
@@ -115,9 +115,10 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/powerpc/gen5200/irq/irq.c b/bsps/powerpc/gen5200/irq/irq.c
index e79067da6d..9ccae2182b 100644
--- a/bsps/powerpc/gen5200/irq/irq.c
+++ b/bsps/powerpc/gen5200/irq/irq.c
@@ -436,7 +436,7 @@ rtems_status_code bsp_interrupt_vector_enable( rtems_vector_number vector)
 /*
  * This function disables a given siu interrupt
  */
-void bsp_interrupt_vector_disable( rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable( rtems_vector_number vector)
 {
   int base_index = get_siu_irq_base_index( vector);
 
@@ -464,6 +464,8 @@ void bsp_interrupt_vector_disable( rtems_vector_number vector)
 
     rtems_interrupt_enable( level);
   }
+
+  return RTEMS_SUCCESSFUL;
 }
 
 #if (BENCHMARK_IRQ_PROCESSING == 0)
diff --git a/bsps/powerpc/gen83xx/irq/irq.c b/bsps/powerpc/gen83xx/irq/irq.c
index ec035e14c3..9edd7f2dac 100644
--- a/bsps/powerpc/gen83xx/irq/irq.c
+++ b/bsps/powerpc/gen83xx/irq/irq.c
@@ -440,7 +440,7 @@ rtems_status_code bsp_interrupt_vector_enable( rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable( rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable( rtems_vector_number vector)
 {
   rtems_vector_number vecnum = vector - BSP_IPIC_IRQ_LOWEST_OFFSET;
   const BSP_isrc_rsc_t *rsc_ptr;
@@ -458,6 +458,8 @@ void bsp_interrupt_vector_disable( rtems_vector_number vector)
       rtems_interrupt_enable(level);
     }
   }
+
+  return RTEMS_SUCCESSFUL;
 }
 
 /*
diff --git a/bsps/powerpc/mpc55xxevb/start/irq.c b/bsps/powerpc/mpc55xxevb/start/irq.c
index f0a04c0398..d738681590 100644
--- a/bsps/powerpc/mpc55xxevb/start/irq.c
+++ b/bsps/powerpc/mpc55xxevb/start/irq.c
@@ -201,8 +201,9 @@ rtems_status_code bsp_interrupt_vector_enable( rtems_vector_number vector)
 	return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable( rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable( rtems_vector_number vector)
 {
 	bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 	mpc55xx_intc_set_priority( vector, MPC55XX_INTC_DISABLED_PRIORITY);
+	return RTEMS_SUCCESSFUL;
 }
diff --git a/bsps/powerpc/mpc8260ads/irq/irq.c b/bsps/powerpc/mpc8260ads/irq/irq.c
index 6fdf83e3b6..6cb21f683b 100644
--- a/bsps/powerpc/mpc8260ads/irq/irq.c
+++ b/bsps/powerpc/mpc8260ads/irq/irq.c
@@ -384,7 +384,7 @@ rtems_status_code bsp_interrupt_vector_enable( rtems_vector_number irqnum)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable( rtems_vector_number irqnum)
+rtems_status_code bsp_interrupt_vector_disable( rtems_vector_number irqnum)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(irqnum));
 
@@ -394,6 +394,8 @@ void bsp_interrupt_vector_disable( rtems_vector_number irqnum)
      */
     BSP_irq_disable_at_cpm (irqnum);
   }
+
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize()
diff --git a/bsps/powerpc/psim/irq/irq_init.c b/bsps/powerpc/psim/irq/irq_init.c
index 48783a6056..d765bfe9c1 100644
--- a/bsps/powerpc/psim/irq/irq_init.c
+++ b/bsps/powerpc/psim/irq/irq_init.c
@@ -151,10 +151,11 @@ rtems_status_code bsp_interrupt_vector_enable( rtems_vector_number irqnum)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable( rtems_vector_number irqnum)
+rtems_status_code bsp_interrupt_vector_disable( rtems_vector_number irqnum)
 {
   /* FIXME: do something */
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(irqnum));
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/powerpc/qemuppc/irq/irq_init.c b/bsps/powerpc/qemuppc/irq/irq_init.c
index 419fc66ce1..6ae88eea8a 100644
--- a/bsps/powerpc/qemuppc/irq/irq_init.c
+++ b/bsps/powerpc/qemuppc/irq/irq_init.c
@@ -87,10 +87,11 @@ rtems_status_code bsp_interrupt_vector_enable( rtems_vector_number irqnum)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable( rtems_vector_number irqnum)
+rtems_status_code bsp_interrupt_vector_disable( rtems_vector_number irqnum)
 {
   /* FIXME: do something */
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(irqnum));
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/powerpc/qoriq/irq/irq.c b/bsps/powerpc/qoriq/irq/irq.c
index 98d4ef1a42..f1b50a7dd8 100644
--- a/bsps/powerpc/qoriq/irq/irq.c
+++ b/bsps/powerpc/qoriq/irq/irq.c
@@ -137,10 +137,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
 	return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
 	bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 	ev_int_set_mask(vector, 1);
+	return RTEMS_SUCCESSFUL;
 }
 
 void bsp_interrupt_dispatch(uintptr_t exception_number)
@@ -402,7 +403,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
 	pic_vector_enable(vector, 0);
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
 	pic_vector_enable(vector, VPR_MSK);
 }
diff --git a/bsps/powerpc/shared/irq/ppc-irq-generic.c b/bsps/powerpc/shared/irq/ppc-irq-generic.c
index 14c1f7c8c7..12ae54e51a 100644
--- a/bsps/powerpc/shared/irq/ppc-irq-generic.c
+++ b/bsps/powerpc/shared/irq/ppc-irq-generic.c
@@ -144,10 +144,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   BSP_disable_irq_at_pic(vector);
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/powerpc/t32mppc/irq/irq.c b/bsps/powerpc/t32mppc/irq/irq.c
index 0c0bb8f1e8..33ec4f9117 100644
--- a/bsps/powerpc/t32mppc/irq/irq.c
+++ b/bsps/powerpc/t32mppc/irq/irq.c
@@ -73,9 +73,10 @@ void bsp_interrupt_dispatch(uintptr_t exception_number)
 	}
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
 	bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
+	return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/powerpc/tqm8xx/irq/irq.c b/bsps/powerpc/tqm8xx/irq/irq.c
index 4903ef7696..50ed43128e 100644
--- a/bsps/powerpc/tqm8xx/irq/irq.c
+++ b/bsps/powerpc/tqm8xx/irq/irq.c
@@ -118,7 +118,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 
@@ -127,6 +127,8 @@ void bsp_interrupt_vector_disable(rtems_vector_number vector)
   } else if (BSP_IS_SIU_IRQ(vector)) {
     bsp_irq_disable_at_SIU(vector);
   }
+
+  return RTEMS_SUCCESSFUL;
 }
 
 /*
diff --git a/bsps/powerpc/virtex/irq/irq_init.c b/bsps/powerpc/virtex/irq/irq_init.c
index 9a9f4eacb4..e133001317 100644
--- a/bsps/powerpc/virtex/irq/irq_init.c
+++ b/bsps/powerpc/virtex/irq/irq_init.c
@@ -185,13 +185,15 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 
   if (BSP_IS_OPBINTC_IRQ(vector)) {
     BSP_irq_disable_at_opbintc(vector);
   }
+
+  return RTEMS_SUCCESSFUL;
 }
 
 static int C_dispatch_irq_handler(BSP_Exception_frame *frame, unsigned int excNum)
diff --git a/bsps/riscv/griscv/irq/irq.c b/bsps/riscv/griscv/irq/irq.c
index 1b58f86fc4..f5b493bd02 100644
--- a/bsps/riscv/griscv/irq/irq.c
+++ b/bsps/riscv/griscv/irq/irq.c
@@ -148,11 +148,12 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   int irq = (int)vector;
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   GRLIB_Cpu_Mask_interrupt(irq, bsp_irq_cpu(irq));
+  return RTEMS_SUCCESSFUL;
 }
 
 void bsp_interrupt_get_affinity(
diff --git a/bsps/riscv/riscv/irq/irq.c b/bsps/riscv/riscv/irq/irq.c
index e651c828d5..52b14ee9e6 100644
--- a/bsps/riscv/riscv/irq/irq.c
+++ b/bsps/riscv/riscv/irq/irq.c
@@ -323,7 +323,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 
@@ -363,6 +363,8 @@ void bsp_interrupt_vector_disable(rtems_vector_number vector)
 
     rtems_interrupt_lock_release(&riscv_plic_lock, &lock_context);
   }
+
+  return RTEMS_SUCCESSFUL;
 }
 
 void bsp_interrupt_set_affinity(
diff --git a/bsps/shared/dev/irq/arm-gicv2.c b/bsps/shared/dev/irq/arm-gicv2.c
index 85cb543945..fd7ca49458 100644
--- a/bsps/shared/dev/irq/arm-gicv2.c
+++ b/bsps/shared/dev/irq/arm-gicv2.c
@@ -127,13 +127,14 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   volatile gic_dist *dist = ARM_GIC_DIST;
 
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 
   gic_id_disable(dist, vector);
+  return RTEMS_SUCCESSFUL;
 }
 
 static inline uint32_t get_id_count(volatile gic_dist *dist)
diff --git a/bsps/shared/dev/irq/arm-gicv3.c b/bsps/shared/dev/irq/arm-gicv3.c
index 89cac60901..12e0aa3534 100644
--- a/bsps/shared/dev/irq/arm-gicv3.c
+++ b/bsps/shared/dev/irq/arm-gicv3.c
@@ -243,7 +243,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
 
@@ -255,6 +255,8 @@ void bsp_interrupt_vector_disable(rtems_vector_number vector)
       gicv3_get_sgi_ppi(_SMP_Get_current_processor());
     sgi_ppi->icspicer[0] = 1 << (vector % 32);
   }
+
+  return RTEMS_SUCCESSFUL;
 }
 
 static inline uint32_t get_id_count(volatile gic_dist *dist)
diff --git a/bsps/shared/irq/irq-default.c b/bsps/shared/irq/irq-default.c
index a8f6de21d9..231da67501 100644
--- a/bsps/shared/irq/irq-default.c
+++ b/bsps/shared/irq/irq-default.c
@@ -86,10 +86,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_UNSATISFIED;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   (void)vector;
+  return RTEMS_UNSATISFIED;
 }
 
 rtems_status_code bsp_interrupt_facility_initialize(void)
diff --git a/bsps/shared/irq/irq-enable-disable.c b/bsps/shared/irq/irq-enable-disable.c
index 6f2793c3e1..a42a2e756e 100644
--- a/bsps/shared/irq/irq-enable-disable.c
+++ b/bsps/shared/irq/irq-enable-disable.c
@@ -97,7 +97,5 @@ rtems_status_code rtems_interrupt_vector_disable( rtems_vector_number vector )
     return RTEMS_INVALID_ID;
   }
 
-  bsp_interrupt_vector_disable( vector );
-
-  return RTEMS_SUCCESSFUL;
+  return bsp_interrupt_vector_disable( vector );
 }
diff --git a/bsps/sparc/leon3/start/eirq.c b/bsps/sparc/leon3/start/eirq.c
index a9abaa3304..822b49959a 100644
--- a/bsps/sparc/leon3/start/eirq.c
+++ b/bsps/sparc/leon3/start/eirq.c
@@ -167,7 +167,7 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
 #if defined(RTEMS_SMP)
   rtems_interrupt_lock_context lock_context;
@@ -192,6 +192,7 @@ void bsp_interrupt_vector_disable(rtems_vector_number vector)
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   BSP_Cpu_Mask_interrupt(vector, _LEON3_Get_current_processor());
 #endif
+  return RTEMS_SUCCESSFUL;
 }
 
 #if defined(RTEMS_SMP)
diff --git a/bsps/sparc/shared/irq/irq-shared.c b/bsps/sparc/shared/irq/irq-shared.c
index 9315d6dadf..976c9256cc 100644
--- a/bsps/sparc/shared/irq/irq-shared.c
+++ b/bsps/sparc/shared/irq/irq-shared.c
@@ -92,10 +92,11 @@ rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
   BSP_Cpu_Mask_interrupt(vector, 0);
+  return RTEMS_SUCCESSFUL;
 }
 #endif
 
diff --git a/bsps/x86_64/amd64/interrupts/idt.c b/bsps/x86_64/amd64/interrupts/idt.c
index 39c941b3e1..e5dce3e615 100644
--- a/bsps/x86_64/amd64/interrupts/idt.c
+++ b/bsps/x86_64/amd64/interrupts/idt.c
@@ -141,9 +141,10 @@ rtems_status_code bsp_interrupt_facility_initialize(void)
   return RTEMS_SUCCESSFUL;
 }
 
-void bsp_interrupt_vector_disable(rtems_vector_number vector)
+rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
 {
   /* XXX */
+  return RTEMS_SUCCESSFUL;
 }
 
 rtems_status_code bsp_interrupt_get_attributes(
-- 
2.26.2



More information about the devel mailing list