Ignore:
Timestamp:
Jun 19, 2017, 12:09:28 PM (3 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
ae3e6af8
Parents:
b361cb6c
git-author:
Sebastian Huber <sebastian.huber@…> (06/19/17 12:09:28)
git-committer:
Sebastian Huber <sebastian.huber@…> (06/20/17 05:42:25)
Message:

bsps: Improve interrupt vector enable/disable API

Change bsp_interrupt_vector_enable() and bsp_interrupt_vector_disable()
to not return a status code. Add bsp_interrupt_assert() and use it to
validate the vector number in the vector enable/disable implementations.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/i386/shared/irq/irq.c

    rb361cb6c rc6810c8  
    271271}
    272272
    273 rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
    274 {
    275   if (bsp_interrupt_vector_is_valid(vector))
    276     BSP_irq_enable_at_i8259a(vector);
    277   return RTEMS_SUCCESSFUL;
    278 }
    279 
    280 rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
    281 {
    282   if (bsp_interrupt_vector_is_valid(vector))
    283     BSP_irq_disable_at_i8259a(vector);
    284   return RTEMS_SUCCESSFUL;
     273void bsp_interrupt_vector_enable(rtems_vector_number vector)
     274{
     275  bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
     276  BSP_irq_enable_at_i8259a(vector);
     277}
     278
     279void bsp_interrupt_vector_disable(rtems_vector_number vector)
     280{
     281  bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector));
     282  BSP_irq_disable_at_i8259a(vector);
    285283}
    286284
Note: See TracChangeset for help on using the changeset viewer.