RTEMS 6.1-rc5
|
This header file provides the support functions for the validation test cases. More...
#include <rtems.h>
#include <rtems/irq-extension.h>
#include <rtems/score/atomic.h>
#include <rtems/score/threadq.h>
Go to the source code of this file.
Data Structures | |
struct | TaskTimerInfo |
struct | MemoryContext |
struct | CallWithinISRRequest |
struct | WrapThreadQueueContext |
struct | Timer_Scheduling_Data |
This structure provides data used by RTEMS to schedule a timer service routine. More... | |
struct | ExtensionCalls |
Macros | |
#define | PRIO_DEFAULT 1 |
This constants represents the default priority of the runner task. | |
#define | PRIO_INVALID 0xfffffffe |
This constants represents an invalid RTEMS task priority value. | |
#define | PRIO_NEARLY_IDLE 126 |
This constants represents a priority which is close to the priority of the idle thread. | |
#define | PRIO_FLEXIBLE 64 |
This constants represents a priority with a wider range of higher and lower priorities around it. | |
#define | INVALID_ID 0xfffffffd |
This constants represents an invalid RTEMS object identifier. | |
#define | OBJECT_NAME rtems_build_name( 'T', 'E', 'S', 'T' ) |
This constants represents an object name for tests. | |
#define | CreateTask(name, priority) |
#define | SCHEDULER_A_ID 0xf010001 |
#define | SCHEDULER_B_ID 0xf010002 |
#define | SCHEDULER_C_ID 0xf010003 |
#define | SCHEDULER_D_ID 0xf010004 |
#define | SOFTWARE_TIMECOUNTER_FREQUENCY 1000000 |
This constant represents the fake frequency of the software timecounter. | |
Typedefs | |
typedef uint32_t(* | GetTimecountHandler) (void) |
typedef void(* | FatalHandler) (rtems_fatal_source source, rtems_fatal_code code, void *arg) |
Enumerations | |
enum | Priority { PRIO_PSEUDO_ISR , PRIO_VERY_ULTRA_HIGH , PRIO_ULTRA_HIGH , PRIO_VERY_HIGH , PRIO_HIGH , PRIO_NORMAL , PRIO_LOW , PRIO_VERY_LOW , PRIO_ULTRA_LOW } |
enum | TaskTimerState { TASK_TIMER_INVALID , TASK_TIMER_INACTIVE , TASK_TIMER_TICKS , TASK_TIMER_REALTIME , TASK_TIMER_MONOTONIC } |
enum | Timer_States { TIMER_INVALID , TIMER_INACTIVE , TIMER_SCHEDULED , TIMER_PENDING } |
The various states of a timer. | |
Functions | |
rtems_id | DoCreateTask (rtems_name name, rtems_task_priority priority) |
void | StartTask (rtems_id id, rtems_task_entry entry, void *arg) |
void | DeleteTask (rtems_id id) |
void | SuspendTask (rtems_id id) |
void | SuspendSelf (void) |
void | ResumeTask (rtems_id id) |
bool | IsTaskSuspended (rtems_id id) |
rtems_event_set | QueryPendingEvents (void) |
rtems_event_set | PollAnyEvents (void) |
rtems_event_set | ReceiveAnyEvents (void) |
rtems_event_set | ReceiveAnyEventsTimed (rtems_interval ticks) |
void | ReceiveAllEvents (rtems_event_set events) |
void | SendEvents (rtems_id id, rtems_event_set events) |
rtems_mode | GetMode (void) |
rtems_mode | SetMode (rtems_mode set, rtems_mode mask) |
rtems_task_priority | GetPriority (rtems_id id) |
rtems_task_priority | GetPriorityByScheduler (rtems_id task_id, rtems_id scheduler_id) |
rtems_task_priority | SetPriority (rtems_id id, rtems_task_priority priority) |
rtems_task_priority | GetSelfPriority (void) |
rtems_task_priority | SetSelfPriority (rtems_task_priority priority) |
rtems_task_priority | SetSelfPriorityNoYield (rtems_task_priority priority) |
rtems_id | GetScheduler (rtems_id id) |
rtems_id | GetSelfScheduler (void) |
void | SetScheduler (rtems_id task_id, rtems_id scheduler_id, rtems_task_priority priority) |
void | SetSelfScheduler (rtems_id scheduler_id, rtems_task_priority priority) |
void | GetAffinity (rtems_id id, cpu_set_t *set) |
void | GetSelfAffinity (cpu_set_t *set) |
void | SetAffinity (rtems_id id, const cpu_set_t *set) |
void | SetSelfAffinity (const cpu_set_t *set) |
void | SetAffinityOne (rtems_id id, uint32_t cpu_index) |
void | SetSelfAffinityOne (uint32_t cpu_index) |
void | SetAffinityAll (rtems_id id) |
void | SetSelfAffinityAll (void) |
void | Yield (void) |
void | YieldTask (rtems_id id) |
void | AddProcessor (rtems_id scheduler_id, uint32_t cpu_index) |
void | RemoveProcessor (rtems_id scheduler_id, uint32_t cpu_index) |
rtems_id | CreateMutex (void) |
rtems_id | CreateMutexNoProtocol (void) |
rtems_id | CreateMutexFIFO (void) |
bool | IsMutexOwner (rtems_id id) |
void | DeleteMutex (rtems_id id) |
void | ObtainMutex (rtems_id id) |
void | ObtainMutexTimed (rtems_id id, rtems_interval ticks) |
void | ObtainMutexDeadlock (rtems_id id) |
void | ReleaseMutex (rtems_id id) |
struct Thread_queue_Queue * | GetMutexThreadQueue (rtems_id id) |
void | RestoreRunnerASR (void) |
void | RestoreRunnerMode (void) |
void | RestoreRunnerPriority (void) |
void | RestoreRunnerScheduler (void) |
struct _Thread_Control * | GetThread (rtems_id id) |
struct _Thread_Control * | GetExecuting (void) |
void | KillZombies (void) |
void | WaitForExecutionStop (rtems_id task_id) |
void | WaitForIntendToBlock (rtems_id task_id) |
void | WaitForHeir (uint32_t cpu_index, rtems_id task_id) |
void | WaitForNextTask (uint32_t cpu_index, rtems_id task_id) |
void | GetTaskTimerInfo (rtems_id id, TaskTimerInfo *info) |
void | GetTaskTimerInfoByThread (struct _Thread_Control *thread, TaskTimerInfo *info) |
void | ClockTick (void) |
void | FinalClockTick (void) |
Simulates a clock tick with the final expire time point of UINT64_MAX for all clocks. | |
void | TimecounterTick (void) |
Simulates a single clock tick using the software timecounter. | |
GetTimecountHandler | SetGetTimecountHandler (GetTimecountHandler handler) |
Sets the get timecount handler. | |
uint32_t | GetTimecountCounter (void) |
Gets the software timecount counter value. | |
uint32_t | SetTimecountCounter (uint32_t counter) |
Sets and gets the software timecount counter value. | |
rtems_id | GetTimerServerTaskId (void) |
Return the task id of the timer server task. | |
bool | DeleteTimerServer (void) |
Undo the effects of rtems_timer_initiate_server() | |
void | MemorySave (MemoryContext *ctx) |
void | MemoryRestore (const MemoryContext *ctx) |
void | MemoryAllocationFailWhen (uint32_t counter) |
Fails a dynamic memory allocation when the counter reaches zero. | |
void | CallWithinISR (void(*handler)(void *), void *arg) |
void | CallWithinISRSubmit (CallWithinISRRequest *request) |
void | CallWithinISRWait (const CallWithinISRRequest *request) |
void | CallWithinISRRaise (void) |
void | CallWithinISRClear (void) |
rtems_vector_number | CallWithinISRGetVector (void) |
rtems_vector_number | GetSoftwareInterruptVector (void) |
void | WrapThreadQueueInitialize (WrapThreadQueueContext *ctx, void(*handler)(void *), void *arg) |
void | WrapThreadQueueExtract (WrapThreadQueueContext *ctx, struct _Thread_Control *thread) |
void | WrapThreadQueueExtractDirect (WrapThreadQueueContext *ctx, Thread_Control *thread) |
void | WrapThreadQueueDestroy (WrapThreadQueueContext *ctx) |
void | SetPreemptionIntervention (struct Per_CPU_Control *cpu, void(*handler)(void *), void *arg) |
rtems_vector_number | GetValidInterruptVectorNumber (const rtems_interrupt_attributes *required) |
rtems_vector_number | GetTestableInterruptVector (const rtems_interrupt_attributes *required) |
rtems_status_code | RaiseSoftwareInterrupt (rtems_vector_number vector) |
rtems_status_code | ClearSoftwareInterrupt (rtems_vector_number vector) |
bool | HasInterruptVectorEntriesInstalled (rtems_vector_number vector) |
Timer_Classes | GetTimerClass (rtems_id id) |
Get the clock and context of a timer from RTEMS internal data. | |
void | GetTimerSchedulingData (rtems_id id, Timer_Scheduling_Data *data) |
Get data related to scheduling a timer service routine from RTEMS internal structures. | |
Timer_States | GetTimerState (rtems_id id) |
Get the state of a timer from RTEMS internal data. | |
void | UnsetClock (void) |
Mark the realtime clock as never set. | |
void | FatalInitialExtension (rtems_fatal_source source, bool always_set_to_false, rtems_fatal_code code) |
void | SetFatalHandler (FatalHandler fatal, void *arg) |
void | SetTaskSwitchExtension (rtems_task_switch_extension task_switch) |
void | ClearExtensionCalls (ExtensionCalls *calls) |
void | CopyExtensionCalls (const ExtensionCalls *from, ExtensionCalls *to) |
void | SetIORelaxHandler (void(*handler)(void *), void *arg) |
void | StartDelayThreadDispatch (uint32_t cpu_index) |
void | StopDelayThreadDispatch (uint32_t cpu_index) |
bool | AreInterruptsEnabled (void) |
bool | IsWhiteSpaceOnly (const char *s) |
bool | IsEqualIgnoreWhiteSpace (const char *a, const char *b) |
void * | IdleBody (uintptr_t ignored) |
Variables | |
const rtems_task_config | DefaultTaskConfig |
This task configurations may be used to construct a task during tests. | |
This header file provides the support functions for the validation test cases.