forked from Imagelibrary/rtems
rtems: Add get/set interrupt priorities
Add directives to get and set the priority of an interrupt vector. Implement the directives for the following BSP families: * arm/lpc24xx * arm/lpc32xx * powerpc/mpc55xxevb * powerpc/qoriq Implement the directives for the following interrupt controllers: * GICv2 and GICv3 (arm and aarch64) * NVIC (arm) * PLIC (riscv) Update #5002.
This commit is contained in:
committed by
Kinsey Moore
parent
89ccc65d1a
commit
ab8817ca03
@@ -71,16 +71,6 @@ extern "C" {
|
||||
|
||||
#define ARM_GIC_DIST ((volatile gic_dist *) BSP_ARM_GIC_DIST_BASE)
|
||||
|
||||
rtems_status_code arm_gic_irq_set_priority(
|
||||
rtems_vector_number vector,
|
||||
uint8_t priority
|
||||
);
|
||||
|
||||
rtems_status_code arm_gic_irq_get_priority(
|
||||
rtems_vector_number vector,
|
||||
uint8_t *priority
|
||||
);
|
||||
|
||||
rtems_status_code arm_gic_irq_set_group(
|
||||
rtems_vector_number vector,
|
||||
gic_group group
|
||||
|
||||
@@ -81,7 +81,7 @@ static inline void Install_tm27_vector( rtems_interrupt_handler handler )
|
||||
);
|
||||
_Assert_Unused_variable_equals( sc, RTEMS_SUCCESSFUL );
|
||||
|
||||
sc = arm_gic_irq_set_priority(
|
||||
sc = rtems_interrupt_set_priority(
|
||||
ARM_GIC_TM27_IRQ_LOW,
|
||||
ARM_GIC_TM27_PRIO_LOW
|
||||
);
|
||||
@@ -100,7 +100,7 @@ static inline void Install_tm27_vector( rtems_interrupt_handler handler )
|
||||
);
|
||||
_Assert_Unused_variable_equals( sc, RTEMS_SUCCESSFUL );
|
||||
|
||||
sc = arm_gic_irq_set_priority(
|
||||
sc = rtems_interrupt_set_priority(
|
||||
ARM_GIC_TM27_IRQ_HIGH,
|
||||
ARM_GIC_TM27_PRIO_HIGH
|
||||
);
|
||||
|
||||
@@ -371,6 +371,9 @@ static inline void gicv3_get_attributes(
|
||||
attributes->maybe_enable = true;
|
||||
attributes->maybe_disable = true;
|
||||
attributes->can_raise = true;
|
||||
attributes->can_get_priority = true;
|
||||
attributes->can_set_priority = true;
|
||||
attributes->maximum_priority = 255;
|
||||
|
||||
if ( vector <= ARM_GIC_IRQ_SGI_LAST ) {
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user