summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2021-11-24 09:22:03 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2021-12-08 17:25:15 +0100
commit82c469e405a32efdf176fd2f94e690d597c73f61 (patch)
tree3768dcf5239154a60adb37faddcb57c7c9fece53
parent10824c52cd8676fac52063d86ab9785d8fcaeb7b (diff)
tx-support
-rw-r--r--testsuites/validation/tx-support.c11
-rw-r--r--testsuites/validation/tx-support.h2
2 files changed, 13 insertions, 0 deletions
diff --git a/testsuites/validation/tx-support.c b/testsuites/validation/tx-support.c
index fded29d429..ecdcb8a413 100644
--- a/testsuites/validation/tx-support.c
+++ b/testsuites/validation/tx-support.c
@@ -607,6 +607,17 @@ void WaitForIntendToBlock( rtems_id task_id )
#endif
}
+void WaitForHeir( uint32_t cpu_index, rtems_id task_id )
+{
+ Per_CPU_Control *cpu;
+
+ cpu = _Per_CPU_Get_by_index( cpu_index );
+
+ while ( cpu->heir->Object.id != task_id ) {
+ RTEMS_COMPILER_MEMORY_BARRIER();
+ }
+}
+
void GetTaskTimerInfo( rtems_id id, TaskTimerInfo *info )
{
GetTaskTimerInfoByThread( GetThread( id ), info );
diff --git a/testsuites/validation/tx-support.h b/testsuites/validation/tx-support.h
index 010fae2180..a41109ec70 100644
--- a/testsuites/validation/tx-support.h
+++ b/testsuites/validation/tx-support.h
@@ -238,6 +238,8 @@ void WaitForExecutionStop( rtems_id task_id );
void WaitForIntendToBlock( rtems_id task_id );
+void WaitForHeir( uint32_t cpu_index, rtems_id task_id );
+
typedef enum {
TASK_TIMER_INVALID,
TASK_TIMER_INACTIVE,