forked from Imagelibrary/rtems
@@ -43,6 +43,32 @@
|
||||
#include <rtems/irq-extension.h>
|
||||
#include <rtems/test.h>
|
||||
|
||||
#include <bsp/irq-generic.h>
|
||||
|
||||
rtems_vector_number GetValidInterruptVectorNumber(
|
||||
const rtems_interrupt_attributes *required
|
||||
)
|
||||
{
|
||||
rtems_vector_number vector;
|
||||
|
||||
for ( vector = 0; vector < BSP_INTERRUPT_VECTOR_COUNT; ++vector ) {
|
||||
rtems_status_code sc;
|
||||
rtems_interrupt_attributes attr;
|
||||
|
||||
sc = rtems_interrupt_get_attributes( vector, &attr );
|
||||
|
||||
if (
|
||||
sc == RTEMS_SUCCESSFUL &&
|
||||
( required == NULL ||
|
||||
!required->can_get_affinity || attr.can_get_affinity )
|
||||
) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return vector;
|
||||
}
|
||||
|
||||
static void HasInstalled(
|
||||
void *arg,
|
||||
const char *info,
|
||||
|
||||
@@ -38,6 +38,7 @@
|
||||
#define _TX_SUPPORT_H
|
||||
|
||||
#include <rtems.h>
|
||||
#include <rtems/irq-extension.h>
|
||||
#include <rtems/score/atomic.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
@@ -113,6 +114,10 @@ void CallWithinISRSubmit( CallWithinISRRequest *request );
|
||||
|
||||
void CallWithinISRWait( const CallWithinISRRequest *request );
|
||||
|
||||
rtems_vector_number GetValidInterruptVectorNumber(
|
||||
const rtems_interrupt_attributes *required
|
||||
);
|
||||
|
||||
bool HasInterruptVectorEntriesInstalled( rtems_vector_number vector );
|
||||
|
||||
/** @} */
|
||||
|
||||
Reference in New Issue
Block a user