RTEMS 4.11Annotated Report
Thu Jan 27 18:17:15 2011
a000f2e0 <TOD_MICROSECONDS_TO_TICKS>:
uint32_t TOD_MICROSECONDS_TO_TICKS(
uint32_t microseconds
)
{
return (microseconds / rtems_configuration_get_microseconds_per_tick());
a000f2e0: e59f300c ldr r3, [pc, #12] ; a000f2f4 <TOD_MICROSECONDS_TO_TICKS+0x14><== NOT EXECUTED
#include <rtems/score/tod.h>
uint32_t TOD_MICROSECONDS_TO_TICKS(
uint32_t microseconds
)
{
a000f2e4: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
return (microseconds / rtems_configuration_get_microseconds_per_tick());
a000f2e8: e593100c ldr r1, [r3, #12] <== NOT EXECUTED
a000f2ec: eb005025 bl a0023388 <__aeabi_uidiv> <== NOT EXECUTED
}
a000f2f0: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a000c52c <_CORE_RWLock_Initialize>:
CORE_RWLock_Control *the_rwlock,
CORE_RWLock_Attributes *the_rwlock_attributes
)
{
the_rwlock->Attributes = *the_rwlock_attributes;
a000c52c: e5912000 ldr r2, [r1] <== NOT EXECUTED
the_rwlock->number_of_waiting_threads = 0;
*/
the_rwlock->number_of_readers = 0;
the_rwlock->current_state = CORE_RWLOCK_UNLOCKED;
_Thread_queue_Initialize(
a000c530: e3a03003 mov r3, #3 <== NOT EXECUTED
the_rwlock->Attributes = *the_rwlock_attributes;
/*
the_rwlock->number_of_waiting_threads = 0;
*/
the_rwlock->number_of_readers = 0;
a000c534: e3a01000 mov r1, #0 <== NOT EXECUTED
CORE_RWLock_Control *the_rwlock,
CORE_RWLock_Attributes *the_rwlock_attributes
)
{
the_rwlock->Attributes = *the_rwlock_attributes;
a000c538: e5802040 str r2, [r0, #64] ; 0x40 <== NOT EXECUTED
the_rwlock->number_of_waiting_threads = 0;
*/
the_rwlock->number_of_readers = 0;
the_rwlock->current_state = CORE_RWLOCK_UNLOCKED;
_Thread_queue_Initialize(
a000c53c: e3a02802 mov r2, #131072 ; 0x20000 <== NOT EXECUTED
the_rwlock->Attributes = *the_rwlock_attributes;
/*
the_rwlock->number_of_waiting_threads = 0;
*/
the_rwlock->number_of_readers = 0;
a000c540: e5801048 str r1, [r0, #72] ; 0x48 <== NOT EXECUTED
the_rwlock->current_state = CORE_RWLOCK_UNLOCKED;
a000c544: e5801044 str r1, [r0, #68] ; 0x44 <== NOT EXECUTED
_Thread_queue_Initialize(
a000c548: ea000817 b a000e5ac <_Thread_queue_Initialize> <== NOT EXECUTED
a000c54c <_CORE_RWLock_Obtain_for_reading>:
Objects_Id id,
bool wait,
Watchdog_Interval timeout,
CORE_RWLock_API_mp_support_callout api_rwlock_mp_support
)
{
a000c54c: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} <== NOT EXECUTED
a000c550: e1a08003 mov r8, r3 <== NOT EXECUTED
ISR_Level level;
Thread_Control *executing = _Thread_Executing;
a000c554: e59f30b8 ldr r3, [pc, #184] ; a000c614 <_CORE_RWLock_Obtain_for_reading+0xc8><== NOT EXECUTED
Objects_Id id,
bool wait,
Watchdog_Interval timeout,
CORE_RWLock_API_mp_support_callout api_rwlock_mp_support
)
{
a000c558: e1a04000 mov r4, r0 <== NOT EXECUTED
a000c55c: e1a05001 mov r5, r1 <== NOT EXECUTED
ISR_Level level;
Thread_Control *executing = _Thread_Executing;
a000c560: e5936004 ldr r6, [r3, #4] <== NOT EXECUTED
Objects_Id id,
bool wait,
Watchdog_Interval timeout,
CORE_RWLock_API_mp_support_callout api_rwlock_mp_support
)
{
a000c564: e202a0ff and sl, r2, #255 ; 0xff <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000c568: e10f7000 mrs r7, CPSR <== NOT EXECUTED
a000c56c: e3873080 orr r3, r7, #128 ; 0x80 <== NOT EXECUTED
a000c570: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
* If locked for reading and no waiters, then OK to read.
* If any thread is waiting, then we wait.
*/
_ISR_Disable( level );
switch ( the_rwlock->current_state ) {
a000c574: e590c044 ldr ip, [r0, #68] ; 0x44 <== NOT EXECUTED
a000c578: e35c0000 cmp ip, #0 <== NOT EXECUTED
a000c57c: 0a000002 beq a000c58c <_CORE_RWLock_Obtain_for_reading+0x40><== NOT EXECUTED
a000c580: e35c0001 cmp ip, #1 <== NOT EXECUTED
a000c584: 1a000010 bne a000c5cc <_CORE_RWLock_Obtain_for_reading+0x80><== NOT EXECUTED
a000c588: ea000005 b a000c5a4 <_CORE_RWLock_Obtain_for_reading+0x58> <== NOT EXECUTED
case CORE_RWLOCK_UNLOCKED:
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING;
a000c58c: e3a03001 mov r3, #1 <== NOT EXECUTED
a000c590: e5803044 str r3, [r0, #68] ; 0x44 <== NOT EXECUTED
the_rwlock->number_of_readers += 1;
a000c594: e5903048 ldr r3, [r0, #72] ; 0x48 <== NOT EXECUTED
a000c598: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000c59c: e5803048 str r3, [r0, #72] ; 0x48 <== NOT EXECUTED
_ISR_Enable( level );
a000c5a0: ea000005 b a000c5bc <_CORE_RWLock_Obtain_for_reading+0x70> <== NOT EXECUTED
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
return;
case CORE_RWLOCK_LOCKED_FOR_READING: {
Thread_Control *waiter;
waiter = _Thread_queue_First( &the_rwlock->Wait_queue );
a000c5a4: eb0007da bl a000e514 <_Thread_queue_First> <== NOT EXECUTED
if ( !waiter ) {
a000c5a8: e3500000 cmp r0, #0 <== NOT EXECUTED
a000c5ac: 1a000006 bne a000c5cc <_CORE_RWLock_Obtain_for_reading+0x80><== NOT EXECUTED
the_rwlock->number_of_readers += 1;
a000c5b0: e5943048 ldr r3, [r4, #72] ; 0x48 <== NOT EXECUTED
a000c5b4: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000c5b8: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000c5bc: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED
_ISR_Enable( level );
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
a000c5c0: e3a03000 mov r3, #0 <== NOT EXECUTED
a000c5c4: e5863034 str r3, [r6, #52] ; 0x34 <== NOT EXECUTED
return;
a000c5c8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
/*
* If the thread is not willing to wait, then return immediately.
*/
if ( !wait ) {
a000c5cc: e35a0000 cmp sl, #0 <== NOT EXECUTED
a000c5d0: 1a000002 bne a000c5e0 <_CORE_RWLock_Obtain_for_reading+0x94><== NOT EXECUTED
a000c5d4: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED
_ISR_Enable( level );
executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;
a000c5d8: e3a03002 mov r3, #2 <== NOT EXECUTED
a000c5dc: eafffff8 b a000c5c4 <_CORE_RWLock_Obtain_for_reading+0x78> <== NOT EXECUTED
a000c5e0: e3a03001 mov r3, #1 <== NOT EXECUTED
a000c5e4: e5843030 str r3, [r4, #48] ; 0x30 <== NOT EXECUTED
*/
_Thread_queue_Enter_critical_section( &the_rwlock->Wait_queue );
executing->Wait.queue = &the_rwlock->Wait_queue;
executing->Wait.id = id;
executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_READ;
a000c5e8: e3a03000 mov r3, #0 <== NOT EXECUTED
/*
* We need to wait to enter this critical section
*/
_Thread_queue_Enter_critical_section( &the_rwlock->Wait_queue );
executing->Wait.queue = &the_rwlock->Wait_queue;
a000c5ec: e5864044 str r4, [r6, #68] ; 0x44 <== NOT EXECUTED
executing->Wait.id = id;
a000c5f0: e5865020 str r5, [r6, #32] <== NOT EXECUTED
executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_READ;
a000c5f4: e5863030 str r3, [r6, #48] ; 0x30 <== NOT EXECUTED
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
a000c5f8: e5863034 str r3, [r6, #52] ; 0x34 <== NOT EXECUTED
a000c5fc: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED
_ISR_Enable( level );
_Thread_queue_Enqueue_with_handler(
a000c600: e59f2010 ldr r2, [pc, #16] ; a000c618 <_CORE_RWLock_Obtain_for_reading+0xcc><== NOT EXECUTED
a000c604: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c608: e1a01008 mov r1, r8 <== NOT EXECUTED
timeout,
_CORE_RWLock_Timeout
);
/* return to API level so it can dispatch and we block */
}
a000c60c: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr} <== NOT EXECUTED
executing->Wait.id = id;
executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_READ;
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
_ISR_Enable( level );
_Thread_queue_Enqueue_with_handler(
a000c610: ea0006e9 b a000e1bc <_Thread_queue_Enqueue_with_handler> <== NOT EXECUTED
a000c61c <_CORE_RWLock_Obtain_for_writing>:
Watchdog_Interval timeout,
CORE_RWLock_API_mp_support_callout api_rwlock_mp_support
)
{
ISR_Level level;
Thread_Control *executing = _Thread_Executing;
a000c61c: e59fc07c ldr ip, [pc, #124] ; a000c6a0 <_CORE_RWLock_Obtain_for_writing+0x84><== NOT EXECUTED
Objects_Id id,
bool wait,
Watchdog_Interval timeout,
CORE_RWLock_API_mp_support_callout api_rwlock_mp_support
)
{
a000c620: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
ISR_Level level;
Thread_Control *executing = _Thread_Executing;
a000c624: e59cc004 ldr ip, [ip, #4] <== NOT EXECUTED
Objects_Id id,
bool wait,
Watchdog_Interval timeout,
CORE_RWLock_API_mp_support_callout api_rwlock_mp_support
)
{
a000c628: e20220ff and r2, r2, #255 ; 0xff <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000c62c: e10f4000 mrs r4, CPSR <== NOT EXECUTED
a000c630: e3845080 orr r5, r4, #128 ; 0x80 <== NOT EXECUTED
a000c634: e129f005 msr CPSR_fc, r5 <== NOT EXECUTED
* If locked for reading and no waiters, then OK to read.
* If any thread is waiting, then we wait.
*/
_ISR_Disable( level );
switch ( the_rwlock->current_state ) {
a000c638: e5905044 ldr r5, [r0, #68] ; 0x44 <== NOT EXECUTED
a000c63c: e3550000 cmp r5, #0 <== NOT EXECUTED
a000c640: 1a000004 bne a000c658 <_CORE_RWLock_Obtain_for_writing+0x3c><== NOT EXECUTED
case CORE_RWLOCK_UNLOCKED:
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_WRITING;
a000c644: e3a03002 mov r3, #2 <== NOT EXECUTED
a000c648: e5803044 str r3, [r0, #68] ; 0x44 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000c64c: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
_ISR_Enable( level );
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
a000c650: e3a03000 mov r3, #0 <== NOT EXECUTED
a000c654: ea000003 b a000c668 <_CORE_RWLock_Obtain_for_writing+0x4c> <== NOT EXECUTED
/*
* If the thread is not willing to wait, then return immediately.
*/
if ( !wait ) {
a000c658: e3520000 cmp r2, #0 <== NOT EXECUTED
a000c65c: 1a000003 bne a000c670 <_CORE_RWLock_Obtain_for_writing+0x54><== NOT EXECUTED
a000c660: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
_ISR_Enable( level );
executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;
a000c664: e3a03002 mov r3, #2 <== NOT EXECUTED
a000c668: e58c3034 str r3, [ip, #52] ; 0x34 <== NOT EXECUTED
a000c66c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000c670: e3a02001 mov r2, #1 <== NOT EXECUTED
a000c674: e5802030 str r2, [r0, #48] ; 0x30 <== NOT EXECUTED
*/
_Thread_queue_Enter_critical_section( &the_rwlock->Wait_queue );
executing->Wait.queue = &the_rwlock->Wait_queue;
executing->Wait.id = id;
executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_WRITE;
a000c678: e58c2030 str r2, [ip, #48] ; 0x30 <== NOT EXECUTED
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
a000c67c: e3a02000 mov r2, #0 <== NOT EXECUTED
/*
* We need to wait to enter this critical section
*/
_Thread_queue_Enter_critical_section( &the_rwlock->Wait_queue );
executing->Wait.queue = &the_rwlock->Wait_queue;
a000c680: e58c0044 str r0, [ip, #68] ; 0x44 <== NOT EXECUTED
executing->Wait.id = id;
a000c684: e58c1020 str r1, [ip, #32] <== NOT EXECUTED
executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_WRITE;
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
a000c688: e58c2034 str r2, [ip, #52] ; 0x34 <== NOT EXECUTED
a000c68c: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
_ISR_Enable( level );
_Thread_queue_Enqueue_with_handler(
a000c690: e59f200c ldr r2, [pc, #12] ; a000c6a4 <_CORE_RWLock_Obtain_for_writing+0x88><== NOT EXECUTED
a000c694: e1a01003 mov r1, r3 <== NOT EXECUTED
_CORE_RWLock_Timeout
);
/* return to API level so it can dispatch and we block */
}
a000c698: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
executing->Wait.id = id;
executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_WRITE;
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
_ISR_Enable( level );
_Thread_queue_Enqueue_with_handler(
a000c69c: ea0006c6 b a000e1bc <_Thread_queue_Enqueue_with_handler> <== NOT EXECUTED
a000c6a8 <_CORE_RWLock_Release>:
CORE_RWLock_Status _CORE_RWLock_Release(
CORE_RWLock_Control *the_rwlock
)
{
ISR_Level level;
Thread_Control *executing = _Thread_Executing;
a000c6a8: e59f30d8 ldr r3, [pc, #216] ; a000c788 <_CORE_RWLock_Release+0xe0><== NOT EXECUTED
*/
CORE_RWLock_Status _CORE_RWLock_Release(
CORE_RWLock_Control *the_rwlock
)
{
a000c6ac: e92d4010 push {r4, lr} <== NOT EXECUTED
ISR_Level level;
Thread_Control *executing = _Thread_Executing;
a000c6b0: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED
*/
CORE_RWLock_Status _CORE_RWLock_Release(
CORE_RWLock_Control *the_rwlock
)
{
a000c6b4: e1a04000 mov r4, r0 <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000c6b8: e10f3000 mrs r3, CPSR <== NOT EXECUTED
a000c6bc: e3831080 orr r1, r3, #128 ; 0x80 <== NOT EXECUTED
a000c6c0: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED
* If locked for reading and no waiters, then OK to read.
* If any thread is waiting, then we wait.
*/
_ISR_Disable( level );
if ( the_rwlock->current_state == CORE_RWLOCK_UNLOCKED){
a000c6c4: e5901044 ldr r1, [r0, #68] ; 0x44 <== NOT EXECUTED
a000c6c8: e3510000 cmp r1, #0 <== NOT EXECUTED
a000c6cc: 1a000003 bne a000c6e0 <_CORE_RWLock_Release+0x38> <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000c6d0: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
_ISR_Enable( level );
executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;
a000c6d4: e3a03002 mov r3, #2 <== NOT EXECUTED
a000c6d8: e5823034 str r3, [r2, #52] ; 0x34 <== NOT EXECUTED
return CORE_RWLOCK_SUCCESSFUL;
a000c6dc: ea000027 b a000c780 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED
}
if ( the_rwlock->current_state == CORE_RWLOCK_LOCKED_FOR_READING ) {
a000c6e0: e3510001 cmp r1, #1 <== NOT EXECUTED
a000c6e4: 1a000006 bne a000c704 <_CORE_RWLock_Release+0x5c> <== NOT EXECUTED
the_rwlock->number_of_readers -= 1;
a000c6e8: e5901048 ldr r1, [r0, #72] ; 0x48 <== NOT EXECUTED
a000c6ec: e2411001 sub r1, r1, #1 <== NOT EXECUTED
if ( the_rwlock->number_of_readers != 0 ) {
a000c6f0: e3510000 cmp r1, #0 <== NOT EXECUTED
_ISR_Enable( level );
executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;
return CORE_RWLOCK_SUCCESSFUL;
}
if ( the_rwlock->current_state == CORE_RWLOCK_LOCKED_FOR_READING ) {
the_rwlock->number_of_readers -= 1;
a000c6f4: e5801048 str r1, [r0, #72] ; 0x48 <== NOT EXECUTED
if ( the_rwlock->number_of_readers != 0 ) {
a000c6f8: 0a000001 beq a000c704 <_CORE_RWLock_Release+0x5c> <== NOT EXECUTED
a000c6fc: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
/* must be unlocked again */
_ISR_Enable( level );
return CORE_RWLOCK_SUCCESSFUL;
a000c700: ea00001e b a000c780 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED
}
}
/* CORE_RWLOCK_LOCKED_FOR_WRITING or READING with readers */
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
a000c704: e3a01000 mov r1, #0 <== NOT EXECUTED
a000c708: e5821034 str r1, [r2, #52] ; 0x34 <== NOT EXECUTED
/*
* Implicitly transition to "unlocked" and find another thread interested
* in obtaining this rwlock.
*/
the_rwlock->current_state = CORE_RWLOCK_UNLOCKED;
a000c70c: e5841044 str r1, [r4, #68] ; 0x44 <== NOT EXECUTED
a000c710: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
_ISR_Enable( level );
next = _Thread_queue_Dequeue( &the_rwlock->Wait_queue );
a000c714: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c718: eb00064d bl a000e054 <_Thread_queue_Dequeue> <== NOT EXECUTED
if ( next ) {
a000c71c: e3500000 cmp r0, #0 <== NOT EXECUTED
a000c720: 0a000016 beq a000c780 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED
if ( next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE ) {
a000c724: e5903030 ldr r3, [r0, #48] ; 0x30 <== NOT EXECUTED
a000c728: e3530001 cmp r3, #1 <== NOT EXECUTED
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_WRITING;
a000c72c: 02833001 addeq r3, r3, #1 <== NOT EXECUTED
a000c730: 05843044 streq r3, [r4, #68] ; 0x44 <== NOT EXECUTED
_ISR_Enable( level );
next = _Thread_queue_Dequeue( &the_rwlock->Wait_queue );
if ( next ) {
if ( next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE ) {
a000c734: 0a000011 beq a000c780 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED
}
/*
* Must be CORE_RWLOCK_THREAD_WAITING_FOR_READING
*/
the_rwlock->number_of_readers += 1;
a000c738: e5943048 ldr r3, [r4, #72] ; 0x48 <== NOT EXECUTED
a000c73c: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000c740: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING;
a000c744: e3a03001 mov r3, #1 <== NOT EXECUTED
a000c748: e5843044 str r3, [r4, #68] ; 0x44 <== NOT EXECUTED
/*
* Now see if more readers can be let go.
*/
while ( 1 ) {
next = _Thread_queue_First( &the_rwlock->Wait_queue );
a000c74c: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c750: eb00076f bl a000e514 <_Thread_queue_First> <== NOT EXECUTED
if ( !next ||
a000c754: e2501000 subs r1, r0, #0 <== NOT EXECUTED
a000c758: 0a000008 beq a000c780 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED
a000c75c: e5913030 ldr r3, [r1, #48] ; 0x30 <== NOT EXECUTED
a000c760: e3530001 cmp r3, #1 <== NOT EXECUTED
a000c764: 0a000005 beq a000c780 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED
next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE )
return CORE_RWLOCK_SUCCESSFUL;
the_rwlock->number_of_readers += 1;
a000c768: e5943048 ldr r3, [r4, #72] ; 0x48 <== NOT EXECUTED
_Thread_queue_Extract( &the_rwlock->Wait_queue, next );
a000c76c: e1a00004 mov r0, r4 <== NOT EXECUTED
while ( 1 ) {
next = _Thread_queue_First( &the_rwlock->Wait_queue );
if ( !next ||
next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE )
return CORE_RWLOCK_SUCCESSFUL;
the_rwlock->number_of_readers += 1;
a000c770: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000c774: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED
_Thread_queue_Extract( &the_rwlock->Wait_queue, next );
a000c778: eb00071d bl a000e3f4 <_Thread_queue_Extract> <== NOT EXECUTED
}
a000c77c: eafffff2 b a000c74c <_CORE_RWLock_Release+0xa4> <== NOT EXECUTED
}
/* indentation is to match _ISR_Disable at top */
return CORE_RWLOCK_SUCCESSFUL;
}
a000c780: e3a00000 mov r0, #0 <== NOT EXECUTED
a000c784: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000c78c <_CORE_RWLock_Timeout>:
void _CORE_RWLock_Timeout(
Objects_Id id,
void *ignored
)
{
a000c78c: e92d4001 push {r0, lr} <== NOT EXECUTED
Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
a000c790: e1a0100d mov r1, sp <== NOT EXECUTED
a000c794: eb000568 bl a000dd3c <_Thread_Get> <== NOT EXECUTED
switch ( location ) {
a000c798: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a000c79c: e3530000 cmp r3, #0 <== NOT EXECUTED
a000c7a0: 1a000004 bne a000c7b8 <_CORE_RWLock_Timeout+0x2c> <== NOT EXECUTED
#if defined(RTEMS_MULTIPROCESSING)
case OBJECTS_REMOTE: /* impossible */
#endif
break;
case OBJECTS_LOCAL:
_Thread_queue_Process_timeout( the_thread );
a000c7a4: eb00079a bl a000e614 <_Thread_queue_Process_timeout> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
a000c7a8: e59f300c ldr r3, [pc, #12] ; a000c7bc <_CORE_RWLock_Timeout+0x30><== NOT EXECUTED
a000c7ac: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000c7b0: e2422001 sub r2, r2, #1 <== NOT EXECUTED
a000c7b4: e5832000 str r2, [r3] <== NOT EXECUTED
_Thread_Unnest_dispatch();
break;
}
}
a000c7b8: e8bd8008 pop {r3, pc} <== NOT EXECUTED
a001910c <_CORE_message_queue_Broadcast>:
{
Thread_Control *the_thread;
uint32_t number_broadcasted;
Thread_Wait_information *waitp;
if ( size > the_message_queue->maximum_message_size ) {
a001910c: e590304c ldr r3, [r0, #76] ; 0x4c
Objects_Id id __attribute__((unused)),
CORE_message_queue_API_mp_support_callout api_message_queue_mp_support __attribute__((unused)),
#endif
uint32_t *count
)
{
a0019110: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr}
Thread_Control *the_thread;
uint32_t number_broadcasted;
Thread_Wait_information *waitp;
if ( size > the_message_queue->maximum_message_size ) {
a0019114: e1520003 cmp r2, r3
Objects_Id id __attribute__((unused)),
CORE_message_queue_API_mp_support_callout api_message_queue_mp_support __attribute__((unused)),
#endif
uint32_t *count
)
{
a0019118: e1a06000 mov r6, r0
a001911c: e1a0a001 mov sl, r1
a0019120: e1a07002 mov r7, r2
a0019124: e59d8020 ldr r8, [sp, #32]
Thread_Control *the_thread;
uint32_t number_broadcasted;
Thread_Wait_information *waitp;
if ( size > the_message_queue->maximum_message_size ) {
a0019128: 8a000013 bhi a001917c <_CORE_message_queue_Broadcast+0x70>
* NOTE: This check is critical because threads can block on
* send and receive and this ensures that we are broadcasting
* the message to threads waiting to receive -- not to send.
*/
if ( the_message_queue->number_of_pending_messages != 0 ) {
a001912c: e5905048 ldr r5, [r0, #72] ; 0x48
a0019130: e3550000 cmp r5, #0
a0019134: 0a000009 beq a0019160 <_CORE_message_queue_Broadcast+0x54>
*count = 0;
a0019138: e3a00000 mov r0, #0
a001913c: e5880000 str r0, [r8]
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
a0019140: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
const void *source,
void *destination,
size_t size
)
{
memcpy(destination, source, size);
a0019144: e594002c ldr r0, [r4, #44] ; 0x2c
a0019148: e1a0100a mov r1, sl
a001914c: e1a02007 mov r2, r7
a0019150: eb002248 bl a0021a78 <memcpy>
buffer,
waitp->return_argument_second.mutable_object,
size
);
*(size_t *) the_thread->Wait.return_argument = size;
a0019154: e5943028 ldr r3, [r4, #40] ; 0x28
*/
number_broadcasted = 0;
while ((the_thread =
_Thread_queue_Dequeue(&the_message_queue->Wait_queue))) {
waitp = &the_thread->Wait;
number_broadcasted += 1;
a0019158: e2855001 add r5, r5, #1
buffer,
waitp->return_argument_second.mutable_object,
size
);
*(size_t *) the_thread->Wait.return_argument = size;
a001915c: e5837000 str r7, [r3]
/*
* There must be no pending messages if there is a thread waiting to
* receive a message.
*/
number_broadcasted = 0;
while ((the_thread =
a0019160: e1a00006 mov r0, r6
a0019164: eb000a9a bl a001bbd4 <_Thread_queue_Dequeue>
a0019168: e2504000 subs r4, r0, #0
a001916c: 1afffff4 bne a0019144 <_CORE_message_queue_Broadcast+0x38>
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
(*api_message_queue_mp_support) ( the_thread, id );
#endif
}
*count = number_broadcasted;
a0019170: e5885000 str r5, [r8]
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
a0019174: e1a00004 mov r0, r4
a0019178: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
Thread_Control *the_thread;
uint32_t number_broadcasted;
Thread_Wait_information *waitp;
if ( size > the_message_queue->maximum_message_size ) {
return CORE_MESSAGE_QUEUE_STATUS_INVALID_SIZE;
a001917c: e3a00001 mov r0, #1 <== NOT EXECUTED
#endif
}
*count = number_broadcasted;
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
}
a0019180: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
a00121d8 <_CORE_message_queue_Initialize>:
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Attributes *the_message_queue_attributes,
uint32_t maximum_pending_messages,
size_t maximum_message_size
)
{
a00121d8: e92d40f0 push {r4, r5, r6, r7, lr}
/*
* Round size up to multiple of a pointer for chain init and
* check for overflow on adding overhead to each message.
*/
allocated_message_size = maximum_message_size;
if (allocated_message_size & (sizeof(uint32_t) - 1)) {
a00121dc: e3130003 tst r3, #3
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Attributes *the_message_queue_attributes,
uint32_t maximum_pending_messages,
size_t maximum_message_size
)
{
a00121e0: e1a04000 mov r4, r0
size_t message_buffering_required;
size_t allocated_message_size;
the_message_queue->maximum_pending_messages = maximum_pending_messages;
the_message_queue->number_of_pending_messages = 0;
a00121e4: e3a00000 mov r0, #0
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Attributes *the_message_queue_attributes,
uint32_t maximum_pending_messages,
size_t maximum_message_size
)
{
a00121e8: e1a06002 mov r6, r2
size_t message_buffering_required;
size_t allocated_message_size;
the_message_queue->maximum_pending_messages = maximum_pending_messages;
a00121ec: e5842044 str r2, [r4, #68] ; 0x44
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Attributes *the_message_queue_attributes,
uint32_t maximum_pending_messages,
size_t maximum_message_size
)
{
a00121f0: e1a05001 mov r5, r1
size_t message_buffering_required;
size_t allocated_message_size;
the_message_queue->maximum_pending_messages = maximum_pending_messages;
the_message_queue->number_of_pending_messages = 0;
a00121f4: e5840048 str r0, [r4, #72] ; 0x48
the_message_queue->maximum_message_size = maximum_message_size;
a00121f8: e584304c str r3, [r4, #76] ; 0x4c
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Notify_Handler the_handler,
void *the_argument
)
{
the_message_queue->notify_handler = the_handler;
a00121fc: e5840060 str r0, [r4, #96] ; 0x60
the_message_queue->notify_argument = the_argument;
a0012200: e5840064 str r0, [r4, #100] ; 0x64
/*
* Round size up to multiple of a pointer for chain init and
* check for overflow on adding overhead to each message.
*/
allocated_message_size = maximum_message_size;
if (allocated_message_size & (sizeof(uint32_t) - 1)) {
a0012204: 01a02003 moveq r2, r3
a0012208: 0a000003 beq a001221c <_CORE_message_queue_Initialize+0x44>
allocated_message_size += sizeof(uint32_t);
a001220c: e2832004 add r2, r3, #4
allocated_message_size &= ~(sizeof(uint32_t) - 1);
a0012210: e3c22003 bic r2, r2, #3
}
if (allocated_message_size < maximum_message_size)
a0012214: e1520003 cmp r2, r3
a0012218: 3a00001e bcc a0012298 <_CORE_message_queue_Initialize+0xc0>
/*
* Calculate how much total memory is required for message buffering and
* check for overflow on the multiplication.
*/
message_buffering_required = (size_t) maximum_pending_messages *
(allocated_message_size + sizeof(CORE_message_queue_Buffer_control));
a001221c: e2827014 add r7, r2, #20
/*
* Calculate how much total memory is required for message buffering and
* check for overflow on the multiplication.
*/
message_buffering_required = (size_t) maximum_pending_messages *
a0012220: e0000796 mul r0, r6, r7
(allocated_message_size + sizeof(CORE_message_queue_Buffer_control));
if (message_buffering_required < allocated_message_size)
a0012224: e1500002 cmp r0, r2
a0012228: 3a000018 bcc a0012290 <_CORE_message_queue_Initialize+0xb8>
/*
* Attempt to allocate the message memory
*/
the_message_queue->message_buffers = (CORE_message_queue_Buffer *)
_Workspace_Allocate( message_buffering_required );
a001222c: eb000b53 bl a0014f80 <_Workspace_Allocate>
if (the_message_queue->message_buffers == 0)
a0012230: e3500000 cmp r0, #0
/*
* Attempt to allocate the message memory
*/
the_message_queue->message_buffers = (CORE_message_queue_Buffer *)
_Workspace_Allocate( message_buffering_required );
a0012234: e1a01000 mov r1, r0
return false;
/*
* Attempt to allocate the message memory
*/
the_message_queue->message_buffers = (CORE_message_queue_Buffer *)
a0012238: e584005c str r0, [r4, #92] ; 0x5c
_Workspace_Allocate( message_buffering_required );
if (the_message_queue->message_buffers == 0)
a001223c: 0a000015 beq a0012298 <_CORE_message_queue_Initialize+0xc0>
/*
* Initialize the pool of inactive messages, pending messages,
* and set of waiting threads.
*/
_Chain_Initialize (
a0012240: e2840068 add r0, r4, #104 ; 0x68
a0012244: e1a02006 mov r2, r6
a0012248: e1a03007 mov r3, r7
a001224c: eb0014ce bl a001758c <_Chain_Initialize>
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *tail = _Chain_Tail( the_chain );
a0012250: e2843054 add r3, r4, #84 ; 0x54
head->next = tail;
a0012254: e5843050 str r3, [r4, #80] ; 0x50
head->previous = NULL;
a0012258: e3a03000 mov r3, #0
a001225c: e5843054 str r3, [r4, #84] ; 0x54
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
Chain_Node *head = _Chain_Head( the_chain );
a0012260: e2843050 add r3, r4, #80 ; 0x50
Chain_Node *tail = _Chain_Tail( the_chain );
head->next = tail;
head->previous = NULL;
tail->previous = head;
a0012264: e5843058 str r3, [r4, #88] ; 0x58
allocated_message_size + sizeof( CORE_message_queue_Buffer_control )
);
_Chain_Initialize_empty( &the_message_queue->Pending_messages );
_Thread_queue_Initialize(
a0012268: e5951000 ldr r1, [r5]
a001226c: e1a00004 mov r0, r4
a0012270: e3a02080 mov r2, #128 ; 0x80
a0012274: e3510001 cmp r1, #1
a0012278: 13a01000 movne r1, #0
a001227c: 03a01001 moveq r1, #1
a0012280: e3a03006 mov r3, #6
a0012284: eb0008c4 bl a001459c <_Thread_queue_Initialize>
THREAD_QUEUE_DISCIPLINE_PRIORITY : THREAD_QUEUE_DISCIPLINE_FIFO,
STATES_WAITING_FOR_MESSAGE,
CORE_MESSAGE_QUEUE_STATUS_TIMEOUT
);
return true;
a0012288: e3a00001 mov r0, #1
a001228c: e8bd80f0 pop {r4, r5, r6, r7, pc}
*/
message_buffering_required = (size_t) maximum_pending_messages *
(allocated_message_size + sizeof(CORE_message_queue_Buffer_control));
if (message_buffering_required < allocated_message_size)
return false;
a0012290: e3a00000 mov r0, #0 <== NOT EXECUTED
a0012294: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
STATES_WAITING_FOR_MESSAGE,
CORE_MESSAGE_QUEUE_STATUS_TIMEOUT
);
return true;
}
a0012298: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
a00175dc <_CORE_message_queue_Insert_message>:
_CORE_message_queue_Append_unprotected(the_message_queue, the_message);
else
_CORE_message_queue_Prepend_unprotected(the_message_queue, the_message);
_ISR_Enable( level );
#else
if ( submit_type == CORE_MESSAGE_QUEUE_SEND_REQUEST ) {
a00175dc: e3720106 cmn r2, #-2147483647 ; 0x80000001
void _CORE_message_queue_Insert_message(
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Buffer_control *the_message,
CORE_message_queue_Submit_types submit_type
)
{
a00175e0: e92d4070 push {r4, r5, r6, lr}
a00175e4: e1a04000 mov r4, r0
a00175e8: e1a05001 mov r5, r1
a00175ec: e5812008 str r2, [r1, #8]
_CORE_message_queue_Append_unprotected(the_message_queue, the_message);
else
_CORE_message_queue_Prepend_unprotected(the_message_queue, the_message);
_ISR_Enable( level );
#else
if ( submit_type == CORE_MESSAGE_QUEUE_SEND_REQUEST ) {
a00175f0: 1a00000c bne a0017628 <_CORE_message_queue_Insert_message+0x4c>
_ISR_Disable( level );
a00175f4: ebfffff4 bl a00175cc <arm_interrupt_disable>
SET_NOTIFY();
a00175f8: e5942048 ldr r2, [r4, #72] ; 0x48
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
Chain_Node *tail = _Chain_Tail( the_chain );
a00175fc: e2841054 add r1, r4, #84 ; 0x54
*
* INTERRUPT LATENCY:
* insert
*/
void _CORE_message_queue_Insert_message(
a0017600: e2723001 rsbs r3, r2, #1
a0017604: 33a03000 movcc r3, #0
_ISR_Enable( level );
#else
if ( submit_type == CORE_MESSAGE_QUEUE_SEND_REQUEST ) {
_ISR_Disable( level );
SET_NOTIFY();
the_message_queue->number_of_pending_messages++;
a0017608: e2822001 add r2, r2, #1
a001760c: e5842048 str r2, [r4, #72] ; 0x48
Chain_Node *old_last = tail->previous;
a0017610: e5942058 ldr r2, [r4, #88] ; 0x58
the_node->next = tail;
a0017614: e5851000 str r1, [r5]
tail->previous = the_node;
a0017618: e5845058 str r5, [r4, #88] ; 0x58
old_last->next = the_node;
a001761c: e5825000 str r5, [r2]
the_node->previous = old_last;
a0017620: e5852004 str r2, [r5, #4]
_CORE_message_queue_Append_unprotected(the_message_queue, the_message);
_ISR_Enable( level );
a0017624: ea000022 b a00176b4 <_CORE_message_queue_Insert_message+0xd8>
} else if ( submit_type == CORE_MESSAGE_QUEUE_URGENT_REQUEST ) {
a0017628: e3520102 cmp r2, #-2147483648 ; 0x80000000
* the message is actually in the queue at this point.
*/
if ( notify && the_message_queue->notify_handler )
(*the_message_queue->notify_handler)(the_message_queue->notify_argument);
#endif
}
a001762c: 15906050 ldrne r6, [r0, #80] ; 0x50
RTEMS_INLINE_ROUTINE bool _Chain_Is_tail(
Chain_Control *the_chain,
const Chain_Node *the_node
)
{
return (the_node == _Chain_Tail(the_chain));
a0017630: 12803054 addne r3, r0, #84 ; 0x54
_ISR_Disable( level );
SET_NOTIFY();
the_message_queue->number_of_pending_messages++;
_CORE_message_queue_Append_unprotected(the_message_queue, the_message);
_ISR_Enable( level );
} else if ( submit_type == CORE_MESSAGE_QUEUE_URGENT_REQUEST ) {
a0017634: 1a000010 bne a001767c <_CORE_message_queue_Insert_message+0xa0>
_ISR_Disable( level );
a0017638: ebffffe3 bl a00175cc <arm_interrupt_disable>
SET_NOTIFY();
a001763c: e5942048 ldr r2, [r4, #72] ; 0x48
*
* INTERRUPT LATENCY:
* insert
*/
void _CORE_message_queue_Insert_message(
a0017640: e2723001 rsbs r3, r2, #1
a0017644: 33a03000 movcc r3, #0
_CORE_message_queue_Append_unprotected(the_message_queue, the_message);
_ISR_Enable( level );
} else if ( submit_type == CORE_MESSAGE_QUEUE_URGENT_REQUEST ) {
_ISR_Disable( level );
SET_NOTIFY();
the_message_queue->number_of_pending_messages++;
a0017648: e2822001 add r2, r2, #1
a001764c: e5842048 str r2, [r4, #72] ; 0x48
RTEMS_INLINE_ROUTINE void _Chain_Prepend_unprotected(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
_Chain_Insert_unprotected(_Chain_Head(the_chain), the_node);
a0017650: e2842050 add r2, r4, #80 ; 0x50
Chain_Node *the_node
)
{
Chain_Node *before_node;
the_node->previous = after_node;
a0017654: e5852004 str r2, [r5, #4]
before_node = after_node->next;
a0017658: e5942050 ldr r2, [r4, #80] ; 0x50
after_node->next = the_node;
a001765c: e5845050 str r5, [r4, #80] ; 0x50
the_node->next = before_node;
before_node->previous = the_node;
a0017660: e5825004 str r5, [r2, #4]
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
after_node->next = the_node;
the_node->next = before_node;
a0017664: e5852000 str r2, [r5]
_CORE_message_queue_Prepend_unprotected(the_message_queue, the_message);
_ISR_Enable( level );
a0017668: ea000011 b a00176b4 <_CORE_message_queue_Insert_message+0xd8>
this_message = (CORE_message_queue_Buffer_control *) the_node;
this_priority = _CORE_message_queue_Get_message_priority(this_message);
if ( this_priority <= the_priority ) {
a001766c: e5961008 ldr r1, [r6, #8] <== NOT EXECUTED
a0017670: e1510002 cmp r1, r2 <== NOT EXECUTED
a0017674: ca000002 bgt a0017684 <_CORE_message_queue_Insert_message+0xa8><== NOT EXECUTED
the_node = the_node->next;
a0017678: e5966000 ldr r6, [r6] <== NOT EXECUTED
int the_priority;
the_priority = _CORE_message_queue_Get_message_priority(the_message);
the_header = &the_message_queue->Pending_messages;
the_node = _Chain_First( the_header );
while ( !_Chain_Is_tail( the_header, the_node ) ) {
a001767c: e1560003 cmp r6, r3
a0017680: 1afffff9 bne a001766c <_CORE_message_queue_Insert_message+0x90>
the_node = the_node->next;
continue;
}
break;
}
_ISR_Disable( level );
a0017684: ebffffd0 bl a00175cc <arm_interrupt_disable>
SET_NOTIFY();
a0017688: e5942048 ldr r2, [r4, #72] ; 0x48
*
* INTERRUPT LATENCY:
* insert
*/
void _CORE_message_queue_Insert_message(
a001768c: e2723001 rsbs r3, r2, #1
a0017690: 33a03000 movcc r3, #0
}
break;
}
_ISR_Disable( level );
SET_NOTIFY();
the_message_queue->number_of_pending_messages++;
a0017694: e2822001 add r2, r2, #1
a0017698: e5842048 str r2, [r4, #72] ; 0x48
_Chain_Insert_unprotected( the_node->previous, &the_message->Node );
a001769c: e5962004 ldr r2, [r6, #4]
)
{
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
a00176a0: e5921000 ldr r1, [r2]
Chain_Node *the_node
)
{
Chain_Node *before_node;
the_node->previous = after_node;
a00176a4: e5852004 str r2, [r5, #4]
before_node = after_node->next;
after_node->next = the_node;
a00176a8: e5825000 str r5, [r2]
the_node->next = before_node;
before_node->previous = the_node;
a00176ac: e5815004 str r5, [r1, #4]
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
after_node->next = the_node;
the_node->next = before_node;
a00176b0: e5851000 str r1, [r5]
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a00176b4: e129f000 msr CPSR_fc, r0
/*
* According to POSIX, does this happen before or after the message
* is actually enqueued. It is logical to think afterwards, because
* the message is actually in the queue at this point.
*/
if ( notify && the_message_queue->notify_handler )
a00176b8: e3530000 cmp r3, #0
a00176bc: 0a000004 beq a00176d4 <_CORE_message_queue_Insert_message+0xf8>
a00176c0: e5943060 ldr r3, [r4, #96] ; 0x60
a00176c4: e3530000 cmp r3, #0
a00176c8: 0a000001 beq a00176d4 <_CORE_message_queue_Insert_message+0xf8>
(*the_message_queue->notify_handler)(the_message_queue->notify_argument);
a00176cc: e5940064 ldr r0, [r4, #100] ; 0x64 <== NOT EXECUTED
a00176d0: e12fff33 blx r3 <== NOT EXECUTED
a00176d4: e8bd8070 pop {r4, r5, r6, pc}
a001229c <_CORE_message_queue_Seize>:
void *buffer,
size_t *size_p,
bool wait,
Watchdog_Interval timeout
)
{
a001229c: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr}
a00122a0: e1a04000 mov r4, r0
ISR_Level level;
CORE_message_queue_Buffer_control *the_message;
Thread_Control *executing;
executing = _Thread_Executing;
a00122a4: e59f0118 ldr r0, [pc, #280] ; a00123c4 <_CORE_message_queue_Seize+0x128>
executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
a00122a8: e3a05000 mov r5, #0
void *buffer,
size_t *size_p,
bool wait,
Watchdog_Interval timeout
)
{
a00122ac: e59dc020 ldr ip, [sp, #32]
ISR_Level level;
CORE_message_queue_Buffer_control *the_message;
Thread_Control *executing;
executing = _Thread_Executing;
a00122b0: e5900004 ldr r0, [r0, #4]
void *buffer,
size_t *size_p,
bool wait,
Watchdog_Interval timeout
)
{
a00122b4: e5dda01c ldrb sl, [sp, #28]
ISR_Level level;
CORE_message_queue_Buffer_control *the_message;
Thread_Control *executing;
executing = _Thread_Executing;
executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
a00122b8: e5805034 str r5, [r0, #52] ; 0x34
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a00122bc: e10f6000 mrs r6, CPSR
a00122c0: e3865080 orr r5, r6, #128 ; 0x80
a00122c4: e129f005 msr CPSR_fc, r5
executing->Wait.return_argument = size_p;
/* Wait.count will be filled in with the message priority */
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout );
}
a00122c8: e5945050 ldr r5, [r4, #80] ; 0x50
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a00122cc: e2847054 add r7, r4, #84 ; 0x54
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(
Chain_Control *the_chain
)
{
if ( !_Chain_Is_empty(the_chain))
a00122d0: e1550007 cmp r5, r7
a00122d4: 0a000028 beq a001237c <_CORE_message_queue_Seize+0xe0>
Chain_Control *the_chain
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *old_first = head->next;
Chain_Node *new_first = old_first->next;
a00122d8: e5958000 ldr r8, [r5]
head->next = new_first;
a00122dc: e1a07004 mov r7, r4
executing = _Thread_Executing;
executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
_ISR_Disable( level );
the_message = _CORE_message_queue_Get_pending_message( the_message_queue );
if ( the_message != NULL ) {
a00122e0: e3550000 cmp r5, #0
a00122e4: e5a78050 str r8, [r7, #80]! ; 0x50
new_first->previous = head;
a00122e8: e5887004 str r7, [r8, #4]
a00122ec: 0a000022 beq a001237c <_CORE_message_queue_Seize+0xe0>
the_message_queue->number_of_pending_messages -= 1;
a00122f0: e5941048 ldr r1, [r4, #72] ; 0x48
a00122f4: e2411001 sub r1, r1, #1
a00122f8: e5841048 str r1, [r4, #72] ; 0x48
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a00122fc: e129f006 msr CPSR_fc, r6
_ISR_Enable( level );
*size_p = the_message->Contents.size;
a0012300: e595100c ldr r1, [r5, #12]
_Thread_Executing->Wait.count =
a0012304: e5950008 ldr r0, [r5, #8]
_CORE_message_queue_Get_message_priority( the_message );
_CORE_message_queue_Copy_buffer(
the_message->Contents.buffer,
a0012308: e2856010 add r6, r5, #16
the_message = _CORE_message_queue_Get_pending_message( the_message_queue );
if ( the_message != NULL ) {
the_message_queue->number_of_pending_messages -= 1;
_ISR_Enable( level );
*size_p = the_message->Contents.size;
a001230c: e5831000 str r1, [r3]
_Thread_Executing->Wait.count =
a0012310: e59f10ac ldr r1, [pc, #172] ; a00123c4 <_CORE_message_queue_Seize+0x128>
a0012314: e5911004 ldr r1, [r1, #4]
a0012318: e5810024 str r0, [r1, #36] ; 0x24
const void *source,
void *destination,
size_t size
)
{
memcpy(destination, source, size);
a001231c: e1a00002 mov r0, r2
a0012320: e1a01006 mov r1, r6
a0012324: e5932000 ldr r2, [r3]
a0012328: eb001fd2 bl a001a278 <memcpy>
* is not, then we can go ahead and free the buffer.
*
* NOTE: If we note that the queue was not full before this receive,
* then we can avoid this dequeue.
*/
the_thread = _Thread_queue_Dequeue( &the_message_queue->Wait_queue );
a001232c: e1a00004 mov r0, r4
a0012330: eb00079b bl a00141a4 <_Thread_queue_Dequeue>
if ( !the_thread ) {
a0012334: e2503000 subs r3, r0, #0
a0012338: 1a000003 bne a001234c <_CORE_message_queue_Seize+0xb0>
RTEMS_INLINE_ROUTINE void _CORE_message_queue_Free_message_buffer (
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Buffer_control *the_message
)
{
_Chain_Append( &the_message_queue->Inactive_messages, &the_message->Node );
a001233c: e2840068 add r0, r4, #104 ; 0x68
a0012340: e1a01005 mov r1, r5
executing->Wait.return_argument = size_p;
/* Wait.count will be filled in with the message priority */
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout );
}
a0012344: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr}
a0012348: eaffff78 b a0012130 <_Chain_Append>
CORE_message_queue_Buffer_control *the_message,
int priority
)
{
#if defined(RTEMS_SCORE_COREMSG_ENABLE_MESSAGE_PRIORITY)
the_message->priority = priority;
a001234c: e5932024 ldr r2, [r3, #36] ; 0x24 <== NOT EXECUTED
const void *source,
void *destination,
size_t size
)
{
memcpy(destination, source, size);
a0012350: e593102c ldr r1, [r3, #44] ; 0x2c <== NOT EXECUTED
a0012354: e1a00006 mov r0, r6 <== NOT EXECUTED
CORE_message_queue_Buffer_control *the_message,
int priority
)
{
#if defined(RTEMS_SCORE_COREMSG_ENABLE_MESSAGE_PRIORITY)
the_message->priority = priority;
a0012358: e5852008 str r2, [r5, #8] <== NOT EXECUTED
*/
_CORE_message_queue_Set_message_priority(
the_message,
the_thread->Wait.count
);
the_message->Contents.size = (size_t) the_thread->Wait.option;
a001235c: e5932030 ldr r2, [r3, #48] ; 0x30 <== NOT EXECUTED
a0012360: e585200c str r2, [r5, #12] <== NOT EXECUTED
const void *source,
void *destination,
size_t size
)
{
memcpy(destination, source, size);
a0012364: eb001fc3 bl a001a278 <memcpy> <== NOT EXECUTED
the_thread->Wait.return_argument_second.immutable_object,
the_message->Contents.buffer,
the_message->Contents.size
);
_CORE_message_queue_Insert_message(
a0012368: e5952008 ldr r2, [r5, #8] <== NOT EXECUTED
a001236c: e1a00004 mov r0, r4 <== NOT EXECUTED
a0012370: e1a01005 mov r1, r5 <== NOT EXECUTED
executing->Wait.return_argument = size_p;
/* Wait.count will be filled in with the message priority */
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout );
}
a0012374: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr} <== NOT EXECUTED
the_thread->Wait.return_argument_second.immutable_object,
the_message->Contents.buffer,
the_message->Contents.size
);
_CORE_message_queue_Insert_message(
a0012378: ea001497 b a00175dc <_CORE_message_queue_Insert_message> <== NOT EXECUTED
return;
}
#endif
}
if ( !wait ) {
a001237c: e35a0000 cmp sl, #0
a0012380: 1a000003 bne a0012394 <_CORE_message_queue_Seize+0xf8>
a0012384: e129f006 msr CPSR_fc, r6
_ISR_Enable( level );
executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_NOWAIT;
a0012388: e3a03004 mov r3, #4
a001238c: e5803034 str r3, [r0, #52] ; 0x34
executing->Wait.return_argument = size_p;
/* Wait.count will be filled in with the message priority */
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout );
}
a0012390: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a0012394: e3a05001 mov r5, #1
a0012398: e5845030 str r5, [r4, #48] ; 0x30
executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_NOWAIT;
return;
}
_Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue );
executing->Wait.queue = &the_message_queue->Wait_queue;
a001239c: e5804044 str r4, [r0, #68] ; 0x44
executing->Wait.id = id;
a00123a0: e5801020 str r1, [r0, #32]
executing->Wait.return_argument_second.mutable_object = buffer;
a00123a4: e580202c str r2, [r0, #44] ; 0x2c
executing->Wait.return_argument = size_p;
a00123a8: e5803028 str r3, [r0, #40] ; 0x28
a00123ac: e129f006 msr CPSR_fc, r6
/* Wait.count will be filled in with the message priority */
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout );
a00123b0: e59f2010 ldr r2, [pc, #16] ; a00123c8 <_CORE_message_queue_Seize+0x12c>
a00123b4: e1a00004 mov r0, r4
a00123b8: e1a0100c mov r1, ip
}
a00123bc: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr}
executing->Wait.return_argument_second.mutable_object = buffer;
executing->Wait.return_argument = size_p;
/* Wait.count will be filled in with the message priority */
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout );
a00123c0: ea0007d1 b a001430c <_Thread_queue_Enqueue_with_handler>
a00123cc <_CORE_message_queue_Submit>:
#endif
CORE_message_queue_Submit_types submit_type,
bool wait,
Watchdog_Interval timeout
)
{
a00123cc: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
a00123d0: e1a09003 mov r9, r3
CORE_message_queue_Buffer_control *the_message;
Thread_Control *the_thread;
if ( size > the_message_queue->maximum_message_size ) {
a00123d4: e590304c ldr r3, [r0, #76] ; 0x4c
#endif
CORE_message_queue_Submit_types submit_type,
bool wait,
Watchdog_Interval timeout
)
{
a00123d8: e1a04000 mov r4, r0
a00123dc: e1a08001 mov r8, r1
CORE_message_queue_Buffer_control *the_message;
Thread_Control *the_thread;
if ( size > the_message_queue->maximum_message_size ) {
a00123e0: e1520003 cmp r2, r3
#endif
CORE_message_queue_Submit_types submit_type,
bool wait,
Watchdog_Interval timeout
)
{
a00123e4: e1a05002 mov r5, r2
a00123e8: e59d6028 ldr r6, [sp, #40] ; 0x28
a00123ec: e5ddb02c ldrb fp, [sp, #44] ; 0x2c
CORE_message_queue_Buffer_control *the_message;
Thread_Control *the_thread;
if ( size > the_message_queue->maximum_message_size ) {
a00123f0: 8a000039 bhi a00124dc <_CORE_message_queue_Submit+0x110>
}
/*
* Is there a thread currently waiting on this message queue?
*/
if ( the_message_queue->number_of_pending_messages == 0 ) {
a00123f4: e590a048 ldr sl, [r0, #72] ; 0x48
a00123f8: e35a0000 cmp sl, #0
a00123fc: 1a00000b bne a0012430 <_CORE_message_queue_Submit+0x64>
the_thread = _Thread_queue_Dequeue( &the_message_queue->Wait_queue );
a0012400: eb000767 bl a00141a4 <_Thread_queue_Dequeue>
if ( the_thread ) {
a0012404: e2507000 subs r7, r0, #0
a0012408: 0a000008 beq a0012430 <_CORE_message_queue_Submit+0x64>
a001240c: e597002c ldr r0, [r7, #44] ; 0x2c
a0012410: e1a01008 mov r1, r8
a0012414: e1a02005 mov r2, r5
a0012418: eb001f96 bl a001a278 <memcpy>
_CORE_message_queue_Copy_buffer(
buffer,
the_thread->Wait.return_argument_second.mutable_object,
size
);
*(size_t *) the_thread->Wait.return_argument = size;
a001241c: e5973028 ldr r3, [r7, #40] ; 0x28
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
(*api_message_queue_mp_support) ( the_thread, id );
#endif
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
a0012420: e1a0000a mov r0, sl
_CORE_message_queue_Copy_buffer(
buffer,
the_thread->Wait.return_argument_second.mutable_object,
size
);
*(size_t *) the_thread->Wait.return_argument = size;
a0012424: e5835000 str r5, [r3]
the_thread->Wait.count = (uint32_t) submit_type;
a0012428: e5876024 str r6, [r7, #36] ; 0x24
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
(*api_message_queue_mp_support) ( the_thread, id );
#endif
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
a001242c: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
/*
* No one waiting on the message queue at this time, so attempt to
* queue the message up for a future receive.
*/
if ( the_message_queue->number_of_pending_messages <
a0012430: e5942048 ldr r2, [r4, #72] ; 0x48
a0012434: e5943044 ldr r3, [r4, #68] ; 0x44
a0012438: e1520003 cmp r2, r3
a001243c: 2a00000e bcs a001247c <_CORE_message_queue_Submit+0xb0>
_CORE_message_queue_Allocate_message_buffer (
CORE_message_queue_Control *the_message_queue
)
{
return (CORE_message_queue_Buffer_control *)
_Chain_Get( &the_message_queue->Inactive_messages );
a0012440: e2840068 add r0, r4, #104 ; 0x68
a0012444: ebffff4c bl a001217c <_Chain_Get>
const void *source,
void *destination,
size_t size
)
{
memcpy(destination, source, size);
a0012448: e1a01008 mov r1, r8
_CORE_message_queue_Allocate_message_buffer (
CORE_message_queue_Control *the_message_queue
)
{
return (CORE_message_queue_Buffer_control *)
_Chain_Get( &the_message_queue->Inactive_messages );
a001244c: e1a07000 mov r7, r0
const void *source,
void *destination,
size_t size
)
{
memcpy(destination, source, size);
a0012450: e1a02005 mov r2, r5
a0012454: e2800010 add r0, r0, #16
a0012458: eb001f86 bl a001a278 <memcpy>
size
);
the_message->Contents.size = size;
_CORE_message_queue_Set_message_priority( the_message, submit_type );
_CORE_message_queue_Insert_message(
a001245c: e1a00004 mov r0, r4
_CORE_message_queue_Copy_buffer(
buffer,
the_message->Contents.buffer,
size
);
the_message->Contents.size = size;
a0012460: e587500c str r5, [r7, #12]
CORE_message_queue_Buffer_control *the_message,
int priority
)
{
#if defined(RTEMS_SCORE_COREMSG_ENABLE_MESSAGE_PRIORITY)
the_message->priority = priority;
a0012464: e5876008 str r6, [r7, #8]
_CORE_message_queue_Set_message_priority( the_message, submit_type );
_CORE_message_queue_Insert_message(
a0012468: e1a01007 mov r1, r7
a001246c: e1a02006 mov r2, r6
a0012470: eb001459 bl a00175dc <_CORE_message_queue_Insert_message>
the_message_queue,
the_message,
submit_type
);
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
a0012474: e3a00000 mov r0, #0
a0012478: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
/*
* No message buffers were available so we may need to return an
* overflow error or block the sender until the message is placed
* on the queue.
*/
if ( !wait ) {
a001247c: e35b0000 cmp fp, #0 <== NOT EXECUTED
a0012480: 0a000017 beq a00124e4 <_CORE_message_queue_Submit+0x118> <== NOT EXECUTED
/*
* Do NOT block on a send if the caller is in an ISR. It is
* deadly to block in an ISR.
*/
if ( _ISR_Is_in_progress() ) {
a0012484: e59f3068 ldr r3, [pc, #104] ; a00124f4 <_CORE_message_queue_Submit+0x128><== NOT EXECUTED
a0012488: e5932000 ldr r2, [r3] <== NOT EXECUTED
a001248c: e3520000 cmp r2, #0 <== NOT EXECUTED
a0012490: 1a000015 bne a00124ec <_CORE_message_queue_Submit+0x120> <== NOT EXECUTED
* Thus the unusual choice to open a new scope and declare
* it as a variable. Doing this emphasizes how dangerous it
* would be to use this variable prior to here.
*/
{
Thread_Control *executing = _Thread_Executing;
a0012494: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0012498: e10f2000 mrs r2, CPSR <== NOT EXECUTED
a001249c: e3821080 orr r1, r2, #128 ; 0x80 <== NOT EXECUTED
a00124a0: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED
a00124a4: e3a01001 mov r1, #1 <== NOT EXECUTED
a00124a8: e5841030 str r1, [r4, #48] ; 0x30 <== NOT EXECUTED
ISR_Level level;
_ISR_Disable( level );
_Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue );
executing->Wait.queue = &the_message_queue->Wait_queue;
a00124ac: e5834044 str r4, [r3, #68] ; 0x44 <== NOT EXECUTED
executing->Wait.id = id;
a00124b0: e5839020 str r9, [r3, #32] <== NOT EXECUTED
executing->Wait.return_argument_second.immutable_object = buffer;
a00124b4: e583802c str r8, [r3, #44] ; 0x2c <== NOT EXECUTED
executing->Wait.option = (uint32_t) size;
a00124b8: e5835030 str r5, [r3, #48] ; 0x30 <== NOT EXECUTED
executing->Wait.count = submit_type;
a00124bc: e5836024 str r6, [r3, #36] ; 0x24 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a00124c0: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout );
a00124c4: e59f202c ldr r2, [pc, #44] ; a00124f8 <_CORE_message_queue_Submit+0x12c><== NOT EXECUTED
a00124c8: e1a00004 mov r0, r4 <== NOT EXECUTED
a00124cc: e59d1030 ldr r1, [sp, #48] ; 0x30 <== NOT EXECUTED
a00124d0: eb00078d bl a001430c <_Thread_queue_Enqueue_with_handler> <== NOT EXECUTED
}
return CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT;
a00124d4: e3a00007 mov r0, #7 <== NOT EXECUTED
a00124d8: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
{
CORE_message_queue_Buffer_control *the_message;
Thread_Control *the_thread;
if ( size > the_message_queue->maximum_message_size ) {
return CORE_MESSAGE_QUEUE_STATUS_INVALID_SIZE;
a00124dc: e3a00001 mov r0, #1 <== NOT EXECUTED
a00124e0: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
* No message buffers were available so we may need to return an
* overflow error or block the sender until the message is placed
* on the queue.
*/
if ( !wait ) {
return CORE_MESSAGE_QUEUE_STATUS_TOO_MANY;
a00124e4: e3a00002 mov r0, #2 <== NOT EXECUTED
a00124e8: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
/*
* Do NOT block on a send if the caller is in an ISR. It is
* deadly to block in an ISR.
*/
if ( _ISR_Is_in_progress() ) {
return CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED;
a00124ec: e3a00003 mov r0, #3 <== NOT EXECUTED
_Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout );
}
return CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT;
#endif
}
a00124f0: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
a000edf0 <_CORE_mutex_Seize_interrupt_trylock>:
{
Thread_Control *executing;
/* disabled when you get here */
executing = _Thread_Executing;
a000edf0: e59f212c ldr r2, [pc, #300] ; a000ef24 <_CORE_mutex_Seize_interrupt_trylock+0x134>
#if defined(__RTEMS_DO_NOT_INLINE_CORE_MUTEX_SEIZE__)
int _CORE_mutex_Seize_interrupt_trylock(
CORE_mutex_Control *the_mutex,
ISR_Level *level_p
)
{
a000edf4: e1a03000 mov r3, r0
executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL;
if ( !_CORE_mutex_Is_locked( the_mutex ) ) {
a000edf8: e593c050 ldr ip, [r3, #80] ; 0x50
{
Thread_Control *executing;
/* disabled when you get here */
executing = _Thread_Executing;
a000edfc: e5922004 ldr r2, [r2, #4]
executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL;
a000ee00: e3a00000 mov r0, #0
if ( !_CORE_mutex_Is_locked( the_mutex ) ) {
a000ee04: e15c0000 cmp ip, r0
a000ee08: e92d4010 push {r4, lr}
Thread_Control *executing;
/* disabled when you get here */
executing = _Thread_Executing;
executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL;
a000ee0c: e5820034 str r0, [r2, #52] ; 0x34
if ( !_CORE_mutex_Is_locked( the_mutex ) ) {
a000ee10: 0a00002c beq a000eec8 <_CORE_mutex_Seize_interrupt_trylock+0xd8>
the_mutex->lock = CORE_MUTEX_LOCKED;
a000ee14: e5830050 str r0, [r3, #80] ; 0x50
the_mutex->holder = executing;
the_mutex->holder_id = executing->Object.id;
a000ee18: e5920008 ldr r0, [r2, #8]
executing = _Thread_Executing;
executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL;
if ( !_CORE_mutex_Is_locked( the_mutex ) ) {
the_mutex->lock = CORE_MUTEX_LOCKED;
the_mutex->holder = executing;
a000ee1c: e583205c str r2, [r3, #92] ; 0x5c
the_mutex->holder_id = executing->Object.id;
a000ee20: e5830060 str r0, [r3, #96] ; 0x60
the_mutex->nest_count = 1;
a000ee24: e3a00001 mov r0, #1
a000ee28: e5830054 str r0, [r3, #84] ; 0x54
return _CORE_mutex_Seize_interrupt_trylock_body( the_mutex, level_p );
}
a000ee2c: e5930048 ldr r0, [r3, #72] ; 0x48
if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) ||
a000ee30: e3500002 cmp r0, #2
a000ee34: 0a000001 beq a000ee40 <_CORE_mutex_Seize_interrupt_trylock+0x50>
a000ee38: e3500003 cmp r0, #3
a000ee3c: 1a000004 bne a000ee54 <_CORE_mutex_Seize_interrupt_trylock+0x64>
_Chain_Prepend_unprotected( &executing->lock_mutex,
&the_mutex->queue.lock_queue );
the_mutex->queue.priority_before = executing->current_priority;
#endif
executing->resource_count++;
a000ee40: e592c01c ldr ip, [r2, #28]
}
if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) {
a000ee44: e3500003 cmp r0, #3
_Chain_Prepend_unprotected( &executing->lock_mutex,
&the_mutex->queue.lock_queue );
the_mutex->queue.priority_before = executing->current_priority;
#endif
executing->resource_count++;
a000ee48: e28c4001 add r4, ip, #1
a000ee4c: e582401c str r4, [r2, #28]
}
if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) {
a000ee50: 0a000000 beq a000ee58 <_CORE_mutex_Seize_interrupt_trylock+0x68>
_ISR_Enable( *level_p );
a000ee54: ea00002a b a000ef04 <_CORE_mutex_Seize_interrupt_trylock+0x114>
*/
{
Priority_Control ceiling;
Priority_Control current;
ceiling = the_mutex->Attributes.priority_ceiling;
a000ee58: e593004c ldr r0, [r3, #76] ; 0x4c
current = executing->current_priority;
a000ee5c: e5924014 ldr r4, [r2, #20]
if ( current == ceiling ) {
a000ee60: e1540000 cmp r4, r0
a000ee64: 1a000000 bne a000ee6c <_CORE_mutex_Seize_interrupt_trylock+0x7c>
_ISR_Enable( *level_p );
a000ee68: ea000025 b a000ef04 <_CORE_mutex_Seize_interrupt_trylock+0x114>
return 0;
}
if ( current > ceiling ) {
a000ee6c: 9a00000b bls a000eea0 <_CORE_mutex_Seize_interrupt_trylock+0xb0>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000ee70: e59f20b0 ldr r2, [pc, #176] ; a000ef28 <_CORE_mutex_Seize_interrupt_trylock+0x138>
a000ee74: e5920000 ldr r0, [r2]
a000ee78: e2800001 add r0, r0, #1
a000ee7c: e5820000 str r0, [r2]
a000ee80: e5912000 ldr r2, [r1]
a000ee84: e129f002 msr CPSR_fc, r2
_Thread_Disable_dispatch();
_ISR_Enable( *level_p );
_Thread_Change_priority(
a000ee88: e3a02000 mov r2, #0
a000ee8c: e593005c ldr r0, [r3, #92] ; 0x5c
a000ee90: e593104c ldr r1, [r3, #76] ; 0x4c
a000ee94: ebfff0d9 bl a000b200 <_Thread_Change_priority>
the_mutex->holder,
the_mutex->Attributes.priority_ceiling,
false
);
_Thread_Enable_dispatch();
a000ee98: ebfff1fe bl a000b698 <_Thread_Enable_dispatch>
a000ee9c: ea00001a b a000ef0c <_CORE_mutex_Seize_interrupt_trylock+0x11c>
return 0;
}
/* if ( current < ceiling ) */ {
executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED;
a000eea0: e3a00006 mov r0, #6
a000eea4: e5820034 str r0, [r2, #52] ; 0x34
the_mutex->lock = CORE_MUTEX_UNLOCKED;
a000eea8: e3a00001 mov r0, #1
a000eeac: e5830050 str r0, [r3, #80] ; 0x50
the_mutex->nest_count = 0; /* undo locking above */
a000eeb0: e3a00000 mov r0, #0
a000eeb4: e5830054 str r0, [r3, #84] ; 0x54
executing->resource_count--; /* undo locking above */
a000eeb8: e582c01c str ip, [r2, #28]
a000eebc: e5913000 ldr r3, [r1]
a000eec0: e129f003 msr CPSR_fc, r3
a000eec4: e8bd8010 pop {r4, pc}
/*
* At this point, we know the mutex was not available. If this thread
* is the thread that has locked the mutex, let's see if we are allowed
* to nest access.
*/
if ( _Thread_Is_executing( the_mutex->holder ) ) {
a000eec8: e593005c ldr r0, [r3, #92] ; 0x5c
a000eecc: e1500002 cmp r0, r2
a000eed0: 1a00000f bne a000ef14 <_CORE_mutex_Seize_interrupt_trylock+0x124>
switch ( the_mutex->Attributes.lock_nesting_behavior ) {
a000eed4: e5932040 ldr r2, [r3, #64] ; 0x40
a000eed8: e3520000 cmp r2, #0
a000eedc: 0a000002 beq a000eeec <_CORE_mutex_Seize_interrupt_trylock+0xfc>
a000eee0: e3520001 cmp r2, #1
a000eee4: 1a00000c bne a000ef1c <_CORE_mutex_Seize_interrupt_trylock+0x12c>
a000eee8: ea000003 b a000eefc <_CORE_mutex_Seize_interrupt_trylock+0x10c><== NOT EXECUTED
case CORE_MUTEX_NESTING_ACQUIRES:
the_mutex->nest_count++;
a000eeec: e5932054 ldr r2, [r3, #84] ; 0x54
a000eef0: e2822001 add r2, r2, #1
a000eef4: e5832054 str r2, [r3, #84] ; 0x54
_ISR_Enable( *level_p );
a000eef8: ea000001 b a000ef04 <_CORE_mutex_Seize_interrupt_trylock+0x114>
return 0;
case CORE_MUTEX_NESTING_IS_ERROR:
executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED;
a000eefc: e3a03002 mov r3, #2 <== NOT EXECUTED
a000ef00: e5803034 str r3, [r0, #52] ; 0x34 <== NOT EXECUTED
a000ef04: e5913000 ldr r3, [r1]
a000ef08: e129f003 msr CPSR_fc, r3
_ISR_Enable( *level_p );
return 0;
a000ef0c: e3a00000 mov r0, #0
a000ef10: e8bd8010 pop {r4, pc}
/*
* The mutex is not available and the caller must deal with the possibility
* of blocking.
*/
return 1;
a000ef14: e3a00001 mov r0, #1
a000ef18: e8bd8010 pop {r4, pc}
a000ef1c: e3a00001 mov r0, #1
a000ef20: e8bd8010 pop {r4, pc}
a0009fb4 <_CORE_mutex_Surrender>:
#else
Objects_Id id __attribute__((unused)),
CORE_mutex_API_mp_support_callout api_mutex_mp_support __attribute__((unused))
#endif
)
{
a0009fb4: e92d4030 push {r4, r5, lr}
a0009fb8: e1a04000 mov r4, r0
* allowed when the mutex in quetion is FIFO or simple Priority
* discipline. But Priority Ceiling or Priority Inheritance mutexes
* must be released by the thread which acquired them.
*/
if ( the_mutex->Attributes.only_owner_release ) {
a0009fbc: e5d43044 ldrb r3, [r4, #68] ; 0x44
)
{
Thread_Control *the_thread;
Thread_Control *holder;
holder = the_mutex->holder;
a0009fc0: e590005c ldr r0, [r0, #92] ; 0x5c
* allowed when the mutex in quetion is FIFO or simple Priority
* discipline. But Priority Ceiling or Priority Inheritance mutexes
* must be released by the thread which acquired them.
*/
if ( the_mutex->Attributes.only_owner_release ) {
a0009fc4: e3530000 cmp r3, #0
a0009fc8: 0a000004 beq a0009fe0 <_CORE_mutex_Surrender+0x2c>
RTEMS_INLINE_ROUTINE bool _Thread_Is_executing (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Executing );
a0009fcc: e59f30f4 ldr r3, [pc, #244] ; a000a0c8 <_CORE_mutex_Surrender+0x114>
if ( !_Thread_Is_executing( holder ) )
a0009fd0: e5933004 ldr r3, [r3, #4]
a0009fd4: e1500003 cmp r0, r3
return CORE_MUTEX_STATUS_NOT_OWNER_OF_RESOURCE;
a0009fd8: 13a05003 movne r5, #3
* discipline. But Priority Ceiling or Priority Inheritance mutexes
* must be released by the thread which acquired them.
*/
if ( the_mutex->Attributes.only_owner_release ) {
if ( !_Thread_Is_executing( holder ) )
a0009fdc: 1a000037 bne a000a0c0 <_CORE_mutex_Surrender+0x10c>
return CORE_MUTEX_STATUS_NOT_OWNER_OF_RESOURCE;
}
/* XXX already unlocked -- not right status */
if ( !the_mutex->nest_count )
a0009fe0: e5945054 ldr r5, [r4, #84] ; 0x54
a0009fe4: e3550000 cmp r5, #0
a0009fe8: 0a000034 beq a000a0c0 <_CORE_mutex_Surrender+0x10c>
return CORE_MUTEX_STATUS_SUCCESSFUL;
the_mutex->nest_count--;
a0009fec: e2455001 sub r5, r5, #1
if ( the_mutex->nest_count != 0 ) {
a0009ff0: e3550000 cmp r5, #0
/* XXX already unlocked -- not right status */
if ( !the_mutex->nest_count )
return CORE_MUTEX_STATUS_SUCCESSFUL;
the_mutex->nest_count--;
a0009ff4: e5845054 str r5, [r4, #84] ; 0x54
/* Currently no API exercises this behavior. */
break;
}
#else
/* must be CORE_MUTEX_NESTING_ACQUIRES or we wouldn't be here */
return CORE_MUTEX_STATUS_SUCCESSFUL;
a0009ff8: 13a05000 movne r5, #0
if ( !the_mutex->nest_count )
return CORE_MUTEX_STATUS_SUCCESSFUL;
the_mutex->nest_count--;
if ( the_mutex->nest_count != 0 ) {
a0009ffc: 1a00002f bne a000a0c0 <_CORE_mutex_Surrender+0x10c>
}
} else
the_mutex->lock = CORE_MUTEX_UNLOCKED;
return CORE_MUTEX_STATUS_SUCCESSFUL;
}
a000a000: e5943048 ldr r3, [r4, #72] ; 0x48
/*
* Formally release the mutex before possibly transferring it to a
* blocked thread.
*/
if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) ||
a000a004: e3530002 cmp r3, #2
a000a008: 0a000001 beq a000a014 <_CORE_mutex_Surrender+0x60>
a000a00c: e3530003 cmp r3, #3
a000a010: 1a00000a bne a000a040 <_CORE_mutex_Surrender+0x8c>
_CORE_mutex_Pop_priority( the_mutex, holder );
if ( pop_status != CORE_MUTEX_STATUS_SUCCESSFUL )
return pop_status;
holder->resource_count--;
a000a014: e590301c ldr r3, [r0, #28]
a000a018: e2433001 sub r3, r3, #1
/*
* Whether or not someone is waiting for the mutex, an
* inherited priority must be lowered if this is the last
* mutex (i.e. resource) this task has.
*/
if ( holder->resource_count == 0 &&
a000a01c: e3530000 cmp r3, #0
_CORE_mutex_Pop_priority( the_mutex, holder );
if ( pop_status != CORE_MUTEX_STATUS_SUCCESSFUL )
return pop_status;
holder->resource_count--;
a000a020: e580301c str r3, [r0, #28]
/*
* Whether or not someone is waiting for the mutex, an
* inherited priority must be lowered if this is the last
* mutex (i.e. resource) this task has.
*/
if ( holder->resource_count == 0 &&
a000a024: 1a000005 bne a000a040 <_CORE_mutex_Surrender+0x8c>
holder->real_priority != holder->current_priority ) {
a000a028: e5901018 ldr r1, [r0, #24]
/*
* Whether or not someone is waiting for the mutex, an
* inherited priority must be lowered if this is the last
* mutex (i.e. resource) this task has.
*/
if ( holder->resource_count == 0 &&
a000a02c: e5903014 ldr r3, [r0, #20]
a000a030: e1510003 cmp r1, r3
a000a034: 0a000001 beq a000a040 <_CORE_mutex_Surrender+0x8c>
holder->real_priority != holder->current_priority ) {
_Thread_Change_priority( holder, holder->real_priority, true );
a000a038: e3a02001 mov r2, #1
a000a03c: eb00046f bl a000b200 <_Thread_Change_priority>
}
}
the_mutex->holder = NULL;
a000a040: e3a05000 mov r5, #0
a000a044: e584505c str r5, [r4, #92] ; 0x5c
the_mutex->holder_id = 0;
a000a048: e5845060 str r5, [r4, #96] ; 0x60
/*
* Now we check if another thread was waiting for this mutex. If so,
* transfer the mutex to that thread.
*/
if ( ( the_thread = _Thread_queue_Dequeue( &the_mutex->Wait_queue ) ) ) {
a000a04c: e1a00004 mov r0, r4
a000a050: eb00065f bl a000b9d4 <_Thread_queue_Dequeue>
a000a054: e2503000 subs r3, r0, #0
}
break;
}
}
} else
the_mutex->lock = CORE_MUTEX_UNLOCKED;
a000a058: 03a02001 moveq r2, #1
a000a05c: 05842050 streq r2, [r4, #80] ; 0x50
return CORE_MUTEX_STATUS_SUCCESSFUL;
a000a060: 01a05003 moveq r5, r3
/*
* Now we check if another thread was waiting for this mutex. If so,
* transfer the mutex to that thread.
*/
if ( ( the_thread = _Thread_queue_Dequeue( &the_mutex->Wait_queue ) ) ) {
a000a064: 0a000015 beq a000a0c0 <_CORE_mutex_Surrender+0x10c>
} else
#endif
{
the_mutex->holder = the_thread;
the_mutex->holder_id = the_thread->Object.id;
a000a068: e5932008 ldr r2, [r3, #8]
} else
#endif
{
the_mutex->holder = the_thread;
a000a06c: e584305c str r3, [r4, #92] ; 0x5c
the_mutex->holder_id = the_thread->Object.id;
a000a070: e5842060 str r2, [r4, #96] ; 0x60
the_mutex->nest_count = 1;
a000a074: e3a02001 mov r2, #1
a000a078: e5842054 str r2, [r4, #84] ; 0x54
switch ( the_mutex->Attributes.discipline ) {
a000a07c: e5942048 ldr r2, [r4, #72] ; 0x48
a000a080: e3520002 cmp r2, #2
case CORE_MUTEX_DISCIPLINES_FIFO:
case CORE_MUTEX_DISCIPLINES_PRIORITY:
break;
case CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT:
_CORE_mutex_Push_priority( the_mutex, the_thread );
the_thread->resource_count++;
a000a084: 0593201c ldreq r2, [r3, #28]
a000a088: 02822001 addeq r2, r2, #1
a000a08c: 0583201c streq r2, [r3, #28]
the_mutex->holder = the_thread;
the_mutex->holder_id = the_thread->Object.id;
the_mutex->nest_count = 1;
switch ( the_mutex->Attributes.discipline ) {
a000a090: 0a00000a beq a000a0c0 <_CORE_mutex_Surrender+0x10c>
a000a094: e3520003 cmp r2, #3 <== NOT EXECUTED
a000a098: 1a000008 bne a000a0c0 <_CORE_mutex_Surrender+0x10c> <== NOT EXECUTED
_CORE_mutex_Push_priority( the_mutex, the_thread );
the_thread->resource_count++;
break;
case CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING:
_CORE_mutex_Push_priority( the_mutex, the_thread );
the_thread->resource_count++;
a000a09c: e593201c ldr r2, [r3, #28] <== NOT EXECUTED
if (the_mutex->Attributes.priority_ceiling <
a000a0a0: e594104c ldr r1, [r4, #76] ; 0x4c <== NOT EXECUTED
_CORE_mutex_Push_priority( the_mutex, the_thread );
the_thread->resource_count++;
break;
case CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING:
_CORE_mutex_Push_priority( the_mutex, the_thread );
the_thread->resource_count++;
a000a0a4: e2822001 add r2, r2, #1 <== NOT EXECUTED
a000a0a8: e583201c str r2, [r3, #28] <== NOT EXECUTED
if (the_mutex->Attributes.priority_ceiling <
a000a0ac: e5933014 ldr r3, [r3, #20] <== NOT EXECUTED
a000a0b0: e1510003 cmp r1, r3 <== NOT EXECUTED
a000a0b4: 2a000001 bcs a000a0c0 <_CORE_mutex_Surrender+0x10c> <== NOT EXECUTED
the_thread->current_priority){
_Thread_Change_priority(
a000a0b8: e1a02005 mov r2, r5 <== NOT EXECUTED
a000a0bc: eb00044f bl a000b200 <_Thread_Change_priority> <== NOT EXECUTED
}
} else
the_mutex->lock = CORE_MUTEX_UNLOCKED;
return CORE_MUTEX_STATUS_SUCCESSFUL;
}
a000a0c0: e1a00005 mov r0, r5
a000a0c4: e8bd8030 pop {r4, r5, pc}
a0012d28 <_CORE_semaphore_Seize>:
)
{
Thread_Control *executing;
ISR_Level level;
executing = _Thread_Executing;
a0012d28: e59fc074 ldr ip, [pc, #116] ; a0012da4 <_CORE_semaphore_Seize+0x7c><== NOT EXECUTED
CORE_semaphore_Control *the_semaphore,
Objects_Id id,
bool wait,
Watchdog_Interval timeout
)
{
a0012d2c: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
Thread_Control *executing;
ISR_Level level;
executing = _Thread_Executing;
a0012d30: e59cc004 ldr ip, [ip, #4] <== NOT EXECUTED
executing->Wait.return_code = CORE_SEMAPHORE_STATUS_SUCCESSFUL;
a0012d34: e3a04000 mov r4, #0 <== NOT EXECUTED
CORE_semaphore_Control *the_semaphore,
Objects_Id id,
bool wait,
Watchdog_Interval timeout
)
{
a0012d38: e20220ff and r2, r2, #255 ; 0xff <== NOT EXECUTED
Thread_Control *executing;
ISR_Level level;
executing = _Thread_Executing;
executing->Wait.return_code = CORE_SEMAPHORE_STATUS_SUCCESSFUL;
a0012d3c: e58c4034 str r4, [ip, #52] ; 0x34 <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0012d40: e10f4000 mrs r4, CPSR <== NOT EXECUTED
a0012d44: e3845080 orr r5, r4, #128 ; 0x80 <== NOT EXECUTED
a0012d48: e129f005 msr CPSR_fc, r5 <== NOT EXECUTED
_ISR_Disable( level );
if ( the_semaphore->count != 0 ) {
a0012d4c: e5905048 ldr r5, [r0, #72] ; 0x48 <== NOT EXECUTED
a0012d50: e3550000 cmp r5, #0 <== NOT EXECUTED
a0012d54: 0a000003 beq a0012d68 <_CORE_semaphore_Seize+0x40> <== NOT EXECUTED
the_semaphore->count -= 1;
a0012d58: e2455001 sub r5, r5, #1 <== NOT EXECUTED
a0012d5c: e5805048 str r5, [r0, #72] ; 0x48 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0012d60: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
a0012d64: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
/*
* If the semaphore was not available and the caller was not willing
* to block, then return immediately with a status indicating that
* the semaphore was not available and the caller never blocked.
*/
if ( !wait ) {
a0012d68: e3520000 cmp r2, #0 <== NOT EXECUTED
a0012d6c: 1a000003 bne a0012d80 <_CORE_semaphore_Seize+0x58> <== NOT EXECUTED
a0012d70: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
_ISR_Enable( level );
executing->Wait.return_code = CORE_SEMAPHORE_STATUS_UNSATISFIED_NOWAIT;
a0012d74: e3a03001 mov r3, #1 <== NOT EXECUTED
a0012d78: e58c3034 str r3, [ip, #52] ; 0x34 <== NOT EXECUTED
a0012d7c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a0012d80: e3a02001 mov r2, #1 <== NOT EXECUTED
a0012d84: e5802030 str r2, [r0, #48] ; 0x30 <== NOT EXECUTED
/*
* If the semaphore is not available and the caller is willing to
* block, then we now block the caller with optional timeout.
*/
_Thread_queue_Enter_critical_section( &the_semaphore->Wait_queue );
executing->Wait.queue = &the_semaphore->Wait_queue;
a0012d88: e58c0044 str r0, [ip, #68] ; 0x44 <== NOT EXECUTED
executing->Wait.id = id;
a0012d8c: e58c1020 str r1, [ip, #32] <== NOT EXECUTED
a0012d90: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_semaphore->Wait_queue, timeout );
a0012d94: e59f200c ldr r2, [pc, #12] ; a0012da8 <_CORE_semaphore_Seize+0x80><== NOT EXECUTED
a0012d98: e1a01003 mov r1, r3 <== NOT EXECUTED
}
a0012d9c: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
*/
_Thread_queue_Enter_critical_section( &the_semaphore->Wait_queue );
executing->Wait.queue = &the_semaphore->Wait_queue;
executing->Wait.id = id;
_ISR_Enable( level );
_Thread_queue_Enqueue( &the_semaphore->Wait_queue, timeout );
a0012da0: eafff175 b a000f37c <_Thread_queue_Enqueue_with_handler> <== NOT EXECUTED
a000ac54 <_CORE_spinlock_Release>:
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000ac54: e10f3000 mrs r3, CPSR
a000ac58: e3832080 orr r2, r3, #128 ; 0x80
a000ac5c: e129f002 msr CPSR_fc, r2
_ISR_Disable( level );
/*
* It must locked before it can be unlocked.
*/
if ( the_spinlock->lock == CORE_SPINLOCK_UNLOCKED ) {
a000ac60: e5902004 ldr r2, [r0, #4]
a000ac64: e3520000 cmp r2, #0
a000ac68: 1a000002 bne a000ac78 <_CORE_spinlock_Release+0x24>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000ac6c: e129f003 msr CPSR_fc, r3
_ISR_Enable( level );
return CORE_SPINLOCK_NOT_LOCKED;
a000ac70: e3a00006 mov r0, #6 <== NOT EXECUTED
a000ac74: e12fff1e bx lr <== NOT EXECUTED
}
/*
* It must locked by the current thread before it can be unlocked.
*/
if ( the_spinlock->holder != _Thread_Executing->Object.id ) {
a000ac78: e59f2040 ldr r2, [pc, #64] ; a000acc0 <_CORE_spinlock_Release+0x6c>
a000ac7c: e590100c ldr r1, [r0, #12]
a000ac80: e5922004 ldr r2, [r2, #4]
a000ac84: e5922008 ldr r2, [r2, #8]
a000ac88: e1510002 cmp r1, r2
a000ac8c: 0a000002 beq a000ac9c <_CORE_spinlock_Release+0x48>
a000ac90: e129f003 msr CPSR_fc, r3
_ISR_Enable( level );
return CORE_SPINLOCK_NOT_HOLDER;
a000ac94: e3a00002 mov r0, #2
a000ac98: e12fff1e bx lr
}
/*
* Let it be unlocked.
*/
the_spinlock->users -= 1;
a000ac9c: e5902008 ldr r2, [r0, #8]
a000aca0: e2422001 sub r2, r2, #1 <== NOT EXECUTED
a000aca4: e5802008 str r2, [r0, #8] <== NOT EXECUTED
the_spinlock->lock = CORE_SPINLOCK_UNLOCKED;
a000aca8: e3a02000 mov r2, #0 <== NOT EXECUTED
a000acac: e5802004 str r2, [r0, #4] <== NOT EXECUTED
the_spinlock->holder = 0;
a000acb0: e580200c str r2, [r0, #12] <== NOT EXECUTED
a000acb4: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
_ISR_Enable( level );
return CORE_SPINLOCK_SUCCESSFUL;
a000acb8: e3a00000 mov r0, #0 <== NOT EXECUTED
}
a000acbc: e12fff1e bx lr <== NOT EXECUTED
a000acc4 <_CORE_spinlock_Wait>:
CORE_spinlock_Status _CORE_spinlock_Wait(
CORE_spinlock_Control *the_spinlock,
bool wait,
Watchdog_Interval timeout
)
{
a000acc4: e92d4070 push {r4, r5, r6, lr}
a000acc8: e1a04000 mov r4, r0
a000accc: e20160ff and r6, r1, #255 ; 0xff
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000acd0: e10f3000 mrs r3, CPSR
a000acd4: e3832080 orr r2, r3, #128 ; 0x80
a000acd8: e129f002 msr CPSR_fc, r2
#if defined(FUNCTIONALITY_NOT_CURRENTLY_USED_BY_ANY_API)
Watchdog_Interval limit = _Watchdog_Ticks_since_boot + timeout;
#endif
_ISR_Disable( level );
if ( (the_spinlock->lock == CORE_SPINLOCK_LOCKED) &&
a000acdc: e5902004 ldr r2, [r0, #4]
a000ace0: e3520001 cmp r2, #1
a000ace4: 1a000008 bne a000ad0c <_CORE_spinlock_Wait+0x48>
(the_spinlock->holder == _Thread_Executing->Object.id) ) {
a000ace8: e59f20a0 ldr r2, [pc, #160] ; a000ad90 <_CORE_spinlock_Wait+0xcc>
a000acec: e590100c ldr r1, [r0, #12]
a000acf0: e5922004 ldr r2, [r2, #4]
#if defined(FUNCTIONALITY_NOT_CURRENTLY_USED_BY_ANY_API)
Watchdog_Interval limit = _Watchdog_Ticks_since_boot + timeout;
#endif
_ISR_Disable( level );
if ( (the_spinlock->lock == CORE_SPINLOCK_LOCKED) &&
a000acf4: e5922008 ldr r2, [r2, #8]
a000acf8: e1510002 cmp r1, r2
a000acfc: 1a000002 bne a000ad0c <_CORE_spinlock_Wait+0x48>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000ad00: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
(the_spinlock->holder == _Thread_Executing->Object.id) ) {
_ISR_Enable( level );
return CORE_SPINLOCK_HOLDER_RELOCKING;
a000ad04: e3a00001 mov r0, #1 <== NOT EXECUTED
a000ad08: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
}
the_spinlock->users += 1;
a000ad0c: e5942008 ldr r2, [r4, #8]
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000ad10: e59f507c ldr r5, [pc, #124] ; a000ad94 <_CORE_spinlock_Wait+0xd0>
a000ad14: e2822001 add r2, r2, #1
a000ad18: e5842008 str r2, [r4, #8]
for ( ;; ) {
if ( the_spinlock->lock == CORE_SPINLOCK_UNLOCKED ) {
a000ad1c: e5942004 ldr r2, [r4, #4]
a000ad20: e3520000 cmp r2, #0
a000ad24: 1a000008 bne a000ad4c <_CORE_spinlock_Wait+0x88>
the_spinlock->lock = CORE_SPINLOCK_LOCKED;
a000ad28: e2822001 add r2, r2, #1
a000ad2c: e5842004 str r2, [r4, #4]
the_spinlock->holder = _Thread_Executing->Object.id;
a000ad30: e59f2058 ldr r2, [pc, #88] ; a000ad90 <_CORE_spinlock_Wait+0xcc>
a000ad34: e5922004 ldr r2, [r2, #4]
a000ad38: e5922008 ldr r2, [r2, #8]
a000ad3c: e584200c str r2, [r4, #12]
a000ad40: e129f003 msr CPSR_fc, r3
_ISR_Enable( level );
return CORE_SPINLOCK_SUCCESSFUL;
a000ad44: e3a00000 mov r0, #0
a000ad48: e8bd8070 pop {r4, r5, r6, pc}
}
/*
* Spinlock is unavailable. If not willing to wait, return.
*/
if ( !wait ) {
a000ad4c: e3560000 cmp r6, #0
a000ad50: 1a000005 bne a000ad6c <_CORE_spinlock_Wait+0xa8>
the_spinlock->users -= 1;
a000ad54: e5942008 ldr r2, [r4, #8]
a000ad58: e2422001 sub r2, r2, #1
a000ad5c: e5842008 str r2, [r4, #8]
a000ad60: e129f003 msr CPSR_fc, r3
_ISR_Enable( level );
return CORE_SPINLOCK_UNAVAILABLE;
a000ad64: e3a00005 mov r0, #5
a000ad68: e8bd8070 pop {r4, r5, r6, pc}
a000ad6c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
*/
_ISR_Enable( level );
/* An ISR could occur here */
_Thread_Enable_dispatch();
a000ad70: eb000537 bl a000c254 <_Thread_Enable_dispatch> <== NOT EXECUTED
a000ad74: e5953000 ldr r3, [r5] <== NOT EXECUTED
a000ad78: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000ad7c: e5853000 str r3, [r5] <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000ad80: e10f3000 mrs r3, CPSR <== NOT EXECUTED
a000ad84: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED
a000ad88: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
/* Reenter the critical sections so we can attempt the lock again. */
_Thread_Disable_dispatch();
_ISR_Disable( level );
}
a000ad8c: eaffffe2 b a000ad1c <_CORE_spinlock_Wait+0x58> <== NOT EXECUTED
a0008e88 <_Event_Seize>:
rtems_event_set pending_events;
ISR_Level level;
RTEMS_API_Control *api;
Thread_blocking_operation_States sync_state;
executing = _Thread_Executing;
a0008e88: e59fc0f8 ldr ip, [pc, #248] ; a0008f88 <_Event_Seize+0x100>
rtems_event_set event_in,
rtems_option option_set,
rtems_interval ticks,
rtems_event_set *event_out
)
{
a0008e8c: e92d40f0 push {r4, r5, r6, r7, lr}
rtems_event_set pending_events;
ISR_Level level;
RTEMS_API_Control *api;
Thread_blocking_operation_States sync_state;
executing = _Thread_Executing;
a0008e90: e59c4004 ldr r4, [ip, #4]
executing->Wait.return_code = RTEMS_SUCCESSFUL;
a0008e94: e3a0c000 mov ip, #0
a0008e98: e584c034 str ip, [r4, #52] ; 0x34
api = executing->API_Extensions[ THREAD_API_RTEMS ];
a0008e9c: e59470f8 ldr r7, [r4, #248] ; 0xf8
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0008ea0: e10f5000 mrs r5, CPSR
a0008ea4: e385c080 orr ip, r5, #128 ; 0x80
a0008ea8: e129f00c msr CPSR_fc, ip
_ISR_Disable( level );
pending_events = api->pending_events;
a0008eac: e5976000 ldr r6, [r7]
seized_events = _Event_sets_Get( pending_events, event_in );
if ( !_Event_sets_Is_empty( seized_events ) &&
a0008eb0: e010c006 ands ip, r0, r6
a0008eb4: 0a000007 beq a0008ed8 <_Event_Seize+0x50>
a0008eb8: e15c0000 cmp ip, r0
a0008ebc: 0a000001 beq a0008ec8 <_Event_Seize+0x40>
(seized_events == event_in || _Options_Is_any( option_set )) ) {
a0008ec0: e3110002 tst r1, #2 <== NOT EXECUTED
a0008ec4: 0a000003 beq a0008ed8 <_Event_Seize+0x50> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE rtems_event_set _Event_sets_Clear(
rtems_event_set the_event_set,
rtems_event_set the_mask
)
{
return ( the_event_set & ~(the_mask) );
a0008ec8: e1c6600c bic r6, r6, ip
api->pending_events =
a0008ecc: e5876000 str r6, [r7]
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0008ed0: e129f005 msr CPSR_fc, r5
a0008ed4: ea000004 b a0008eec <_Event_Seize+0x64>
_ISR_Enable( level );
*event_out = seized_events;
return;
}
if ( _Options_Is_no_wait( option_set ) ) {
a0008ed8: e3110001 tst r1, #1
a0008edc: 0a000004 beq a0008ef4 <_Event_Seize+0x6c>
a0008ee0: e129f005 msr CPSR_fc, r5
_ISR_Enable( level );
executing->Wait.return_code = RTEMS_UNSATISFIED;
a0008ee4: e3a0200d mov r2, #13
a0008ee8: e5842034 str r2, [r4, #52] ; 0x34
*event_out = seized_events;
a0008eec: e583c000 str ip, [r3]
return;
a0008ef0: e8bd80f0 pop {r4, r5, r6, r7, pc}
* NOTE: Since interrupts are disabled, this isn't that much of an
* issue but better safe than sorry.
*/
executing->Wait.option = (uint32_t) option_set;
executing->Wait.count = (uint32_t) event_in;
executing->Wait.return_argument = event_out;
a0008ef4: e5843028 str r3, [r4, #40] ; 0x28
_Event_Sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a0008ef8: e59f308c ldr r3, [pc, #140] ; a0008f8c <_Event_Seize+0x104>
* set properly when we are marked as in the event critical section.
*
* NOTE: Since interrupts are disabled, this isn't that much of an
* issue but better safe than sorry.
*/
executing->Wait.option = (uint32_t) option_set;
a0008efc: e5841030 str r1, [r4, #48] ; 0x30
executing->Wait.count = (uint32_t) event_in;
executing->Wait.return_argument = event_out;
_Event_Sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a0008f00: e3a01001 mov r1, #1
*
* NOTE: Since interrupts are disabled, this isn't that much of an
* issue but better safe than sorry.
*/
executing->Wait.option = (uint32_t) option_set;
executing->Wait.count = (uint32_t) event_in;
a0008f04: e5840024 str r0, [r4, #36] ; 0x24
executing->Wait.return_argument = event_out;
_Event_Sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a0008f08: e5831000 str r1, [r3]
a0008f0c: e129f005 msr CPSR_fc, r5
_ISR_Enable( level );
if ( ticks ) {
a0008f10: e3520000 cmp r2, #0
a0008f14: 0a00000a beq a0008f44 <_Event_Seize+0xbc>
_Watchdog_Initialize(
a0008f18: e5941008 ldr r1, [r4, #8]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a0008f1c: e59f006c ldr r0, [pc, #108] ; a0008f90 <_Event_Seize+0x108>
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a0008f20: e3a03000 mov r3, #0
the_watchdog->routine = routine;
the_watchdog->id = id;
a0008f24: e5841068 str r1, [r4, #104] ; 0x68
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a0008f28: e5840064 str r0, [r4, #100] ; 0x64
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a0008f2c: e5843050 str r3, [r4, #80] ; 0x50
the_watchdog->routine = routine;
the_watchdog->id = id;
the_watchdog->user_data = user_data;
a0008f30: e584306c str r3, [r4, #108] ; 0x6c
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a0008f34: e5842054 str r2, [r4, #84] ; 0x54
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a0008f38: e59f0054 ldr r0, [pc, #84] ; a0008f94 <_Event_Seize+0x10c>
a0008f3c: e2841048 add r1, r4, #72 ; 0x48
a0008f40: eb000d5c bl a000c4b8 <_Watchdog_Insert>
NULL
);
_Watchdog_Insert_ticks( &executing->Timer, ticks );
}
_Thread_Set_state( executing, STATES_WAITING_FOR_EVENT );
a0008f44: e1a00004 mov r0, r4
a0008f48: e3a01c01 mov r1, #256 ; 0x100
a0008f4c: eb000be6 bl a000beec <_Thread_Set_state>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0008f50: e10f2000 mrs r2, CPSR
a0008f54: e3823080 orr r3, r2, #128 ; 0x80
a0008f58: e129f003 msr CPSR_fc, r3
_ISR_Disable( level );
sync_state = _Event_Sync_state;
a0008f5c: e59f3028 ldr r3, [pc, #40] ; a0008f8c <_Event_Seize+0x104>
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
a0008f60: e3a01000 mov r1, #0
_Thread_Set_state( executing, STATES_WAITING_FOR_EVENT );
_ISR_Disable( level );
sync_state = _Event_Sync_state;
a0008f64: e5930000 ldr r0, [r3]
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
a0008f68: e5831000 str r1, [r3]
if ( sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) {
a0008f6c: e3500001 cmp r0, #1
a0008f70: 1a000001 bne a0008f7c <_Event_Seize+0xf4>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0008f74: e129f002 msr CPSR_fc, r2
a0008f78: e8bd80f0 pop {r4, r5, r6, r7, pc}
* An interrupt completed the thread's blocking request.
* The blocking thread was satisfied by an ISR or timed out.
*
* WARNING! Returning with interrupts disabled!
*/
_Thread_blocking_operation_Cancel( sync_state, executing, level );
a0008f7c: e1a01004 mov r1, r4 <== NOT EXECUTED
}
a0008f80: e8bd40f0 pop {r4, r5, r6, r7, lr} <== NOT EXECUTED
* An interrupt completed the thread's blocking request.
* The blocking thread was satisfied by an ISR or timed out.
*
* WARNING! Returning with interrupts disabled!
*/
_Thread_blocking_operation_Cancel( sync_state, executing, level );
a0008f84: ea00088a b a000b1b4 <_Thread_blocking_operation_Cancel> <== NOT EXECUTED
a0008fe8 <_Event_Surrender>:
*/
void _Event_Surrender(
Thread_Control *the_thread
)
{
a0008fe8: e92d40f0 push {r4, r5, r6, r7, lr}
rtems_event_set event_condition;
rtems_event_set seized_events;
rtems_option option_set;
RTEMS_API_Control *api;
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
a0008fec: e590c0f8 ldr ip, [r0, #248] ; 0xf8
option_set = (rtems_option) the_thread->Wait.option;
a0008ff0: e5905030 ldr r5, [r0, #48] ; 0x30
*/
void _Event_Surrender(
Thread_Control *the_thread
)
{
a0008ff4: e1a04000 mov r4, r0
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0008ff8: e10f3000 mrs r3, CPSR
a0008ffc: e3832080 orr r2, r3, #128 ; 0x80
a0009000: e129f002 msr CPSR_fc, r2
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
option_set = (rtems_option) the_thread->Wait.option;
_ISR_Disable( level );
pending_events = api->pending_events;
a0009004: e59c1000 ldr r1, [ip]
event_condition = (rtems_event_set) the_thread->Wait.count;
a0009008: e5900024 ldr r0, [r0, #36] ; 0x24
seized_events = _Event_sets_Get( pending_events, event_condition );
/*
* No events were seized in this operation
*/
if ( _Event_sets_Is_empty( seized_events ) ) {
a000900c: e0102001 ands r2, r0, r1
a0009010: 1a000000 bne a0009018 <_Event_Surrender+0x30>
_ISR_Enable( level );
a0009014: ea000039 b a0009100 <_Event_Surrender+0x118>
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
a0009018: e59f60e8 ldr r6, [pc, #232] ; a0009108 <_Event_Surrender+0x120>
a000901c: e5967000 ldr r7, [r6]
a0009020: e3570000 cmp r7, #0
a0009024: 0a000017 beq a0009088 <_Event_Surrender+0xa0>
a0009028: e5966004 ldr r6, [r6, #4] <== NOT EXECUTED
a000902c: e1540006 cmp r4, r6 <== NOT EXECUTED
a0009030: 1a000014 bne a0009088 <_Event_Surrender+0xa0> <== NOT EXECUTED
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
a0009034: e59f60d0 ldr r6, [pc, #208] ; a000910c <_Event_Surrender+0x124><== NOT EXECUTED
a0009038: e5967000 ldr r7, [r6] <== NOT EXECUTED
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
_Thread_Is_executing( the_thread ) &&
a000903c: e3570002 cmp r7, #2 <== NOT EXECUTED
a0009040: 0a000002 beq a0009050 <_Event_Surrender+0x68> <== NOT EXECUTED
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
(_Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) {
a0009044: e5966000 ldr r6, [r6] <== NOT EXECUTED
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
a0009048: e3560001 cmp r6, #1 <== NOT EXECUTED
a000904c: 1a00000d bne a0009088 <_Event_Surrender+0xa0> <== NOT EXECUTED
(_Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) {
if ( seized_events == event_condition || _Options_Is_any(option_set) ) {
a0009050: e1520000 cmp r2, r0 <== NOT EXECUTED
a0009054: 0a000001 beq a0009060 <_Event_Surrender+0x78> <== NOT EXECUTED
a0009058: e3150002 tst r5, #2 <== NOT EXECUTED
a000905c: 0a000008 beq a0009084 <_Event_Surrender+0x9c> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE rtems_event_set _Event_sets_Clear(
rtems_event_set the_event_set,
rtems_event_set the_mask
)
{
return ( the_event_set & ~(the_mask) );
a0009060: e1c11002 bic r1, r1, r2 <== NOT EXECUTED
api->pending_events = _Event_sets_Clear( pending_events,seized_events );
a0009064: e58c1000 str r1, [ip] <== NOT EXECUTED
the_thread->Wait.count = 0;
a0009068: e3a01000 mov r1, #0 <== NOT EXECUTED
a000906c: e5841024 str r1, [r4, #36] ; 0x24 <== NOT EXECUTED
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
a0009070: e5941028 ldr r1, [r4, #40] ; 0x28 <== NOT EXECUTED
a0009074: e5812000 str r2, [r1] <== NOT EXECUTED
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SATISFIED;
a0009078: e59f208c ldr r2, [pc, #140] ; a000910c <_Event_Surrender+0x124><== NOT EXECUTED
a000907c: e3a01003 mov r1, #3 <== NOT EXECUTED
a0009080: e5821000 str r1, [r2] <== NOT EXECUTED
}
_ISR_Enable( level );
a0009084: ea00001d b a0009100 <_Event_Surrender+0x118> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE bool _States_Is_waiting_for_event (
States_Control the_states
)
{
return (the_states & STATES_WAITING_FOR_EVENT);
a0009088: e5946010 ldr r6, [r4, #16]
}
/*
* Otherwise, this is a normal send to another thread
*/
if ( _States_Is_waiting_for_event( the_thread->current_state ) ) {
a000908c: e3160c01 tst r6, #256 ; 0x100
a0009090: 0a00001a beq a0009100 <_Event_Surrender+0x118>
if ( seized_events == event_condition || _Options_Is_any( option_set ) ) {
a0009094: e1520000 cmp r2, r0
a0009098: 0a000001 beq a00090a4 <_Event_Surrender+0xbc>
a000909c: e3150002 tst r5, #2 <== NOT EXECUTED
a00090a0: 0a000016 beq a0009100 <_Event_Surrender+0x118> <== NOT EXECUTED
a00090a4: e1c11002 bic r1, r1, r2
api->pending_events = _Event_sets_Clear( pending_events, seized_events );
a00090a8: e58c1000 str r1, [ip]
the_thread->Wait.count = 0;
a00090ac: e3a01000 mov r1, #0
a00090b0: e5841024 str r1, [r4, #36] ; 0x24
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
a00090b4: e5941028 ldr r1, [r4, #40] ; 0x28
a00090b8: e5812000 str r2, [r1]
static inline void arm_interrupt_flash( uint32_t level )
{
uint32_t arm_switch_reg;
asm volatile (
a00090bc: e10f2000 mrs r2, CPSR
a00090c0: e129f003 msr CPSR_fc, r3
a00090c4: e129f002 msr CPSR_fc, r2
_ISR_Flash( level );
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
a00090c8: e5942050 ldr r2, [r4, #80] ; 0x50
a00090cc: e3520002 cmp r2, #2
a00090d0: 0a000001 beq a00090dc <_Event_Surrender+0xf4>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a00090d4: e129f003 msr CPSR_fc, r3
a00090d8: ea000004 b a00090f0 <_Event_Surrender+0x108>
RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate(
Watchdog_Control *the_watchdog
)
{
the_watchdog->state = WATCHDOG_REMOVE_IT;
a00090dc: e3a02003 mov r2, #3
a00090e0: e5842050 str r2, [r4, #80] ; 0x50
a00090e4: e129f003 msr CPSR_fc, r3
_ISR_Enable( level );
_Thread_Unblock( the_thread );
} else {
_Watchdog_Deactivate( &the_thread->Timer );
_ISR_Enable( level );
(void) _Watchdog_Remove( &the_thread->Timer );
a00090e8: e2840048 add r0, r4, #72 ; 0x48
a00090ec: eb000d49 bl a000c618 <_Watchdog_Remove>
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
a00090f0: e59f1018 ldr r1, [pc, #24] ; a0009110 <_Event_Surrender+0x128>
a00090f4: e1a00004 mov r0, r4
}
return;
}
}
_ISR_Enable( level );
}
a00090f8: e8bd40f0 pop {r4, r5, r6, r7, lr}
a00090fc: ea00089a b a000b36c <_Thread_Clear_state>
a0009100: e129f003 msr CPSR_fc, r3
a0009104: e8bd80f0 pop {r4, r5, r6, r7, pc}
a0009114 <_Event_Timeout>:
void _Event_Timeout(
Objects_Id id,
void *ignored
)
{
a0009114: e92d4001 push {r0, lr} <== NOT EXECUTED
Thread_Control *the_thread;
Objects_Locations location;
ISR_Level level;
the_thread = _Thread_Get( id, &location );
a0009118: e1a0100d mov r1, sp <== NOT EXECUTED
a000911c: eb000966 bl a000b6bc <_Thread_Get> <== NOT EXECUTED
switch ( location ) {
a0009120: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a0009124: e3530000 cmp r3, #0 <== NOT EXECUTED
a0009128: 1a000015 bne a0009184 <_Event_Timeout+0x70> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000912c: e10f2000 mrs r2, CPSR <== NOT EXECUTED
a0009130: e3821080 orr r1, r2, #128 ; 0x80 <== NOT EXECUTED
a0009134: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED
_ISR_Enable( level );
return;
}
#endif
the_thread->Wait.count = 0;
a0009138: e5803024 str r3, [r0, #36] ; 0x24 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool _Thread_Is_executing (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Executing );
a000913c: e59f3044 ldr r3, [pc, #68] ; a0009188 <_Event_Timeout+0x74><== NOT EXECUTED
if ( _Thread_Is_executing( the_thread ) ) {
a0009140: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
a0009144: e1500003 cmp r0, r3 <== NOT EXECUTED
a0009148: 1a000004 bne a0009160 <_Event_Timeout+0x4c> <== NOT EXECUTED
if ( _Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
a000914c: e59f3038 ldr r3, [pc, #56] ; a000918c <_Event_Timeout+0x78><== NOT EXECUTED
a0009150: e5931000 ldr r1, [r3] <== NOT EXECUTED
a0009154: e3510001 cmp r1, #1 <== NOT EXECUTED
_Event_Sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT;
a0009158: 02811001 addeq r1, r1, #1 <== NOT EXECUTED
a000915c: 05831000 streq r1, [r3] <== NOT EXECUTED
}
the_thread->Wait.return_code = RTEMS_TIMEOUT;
a0009160: e3a03006 mov r3, #6 <== NOT EXECUTED
a0009164: e5803034 str r3, [r0, #52] ; 0x34 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0009168: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
a000916c: e59f101c ldr r1, [pc, #28] ; a0009190 <_Event_Timeout+0x7c><== NOT EXECUTED
a0009170: eb00087d bl a000b36c <_Thread_Clear_state> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
a0009174: e59f3018 ldr r3, [pc, #24] ; a0009194 <_Event_Timeout+0x80><== NOT EXECUTED
a0009178: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000917c: e2422001 sub r2, r2, #1 <== NOT EXECUTED
a0009180: e5832000 str r2, [r3] <== NOT EXECUTED
case OBJECTS_REMOTE: /* impossible */
#endif
case OBJECTS_ERROR:
break;
}
}
a0009184: e8bd8008 pop {r3, pc} <== NOT EXECUTED
a000ef88 <_Heap_Allocate_aligned_with_boundary>:
Heap_Control *heap,
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
a000ef88: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
a000ef8c: e1a08002 mov r8, r2
Heap_Statistics *const stats = &heap->stats;
uintptr_t const block_size_floor = alloc_size + HEAP_BLOCK_HEADER_SIZE
- HEAP_ALLOC_BONUS;
uintptr_t const page_size = heap->page_size;
a000ef90: e5902010 ldr r2, [r0, #16]
Heap_Control *heap,
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
a000ef94: e24dd01c sub sp, sp, #28
a000ef98: e1a0b003 mov fp, r3
Heap_Block *block = NULL;
uintptr_t alloc_begin = 0;
uint32_t search_count = 0;
bool search_again = false;
if ( block_size_floor < alloc_size ) {
a000ef9c: e2913004 adds r3, r1, #4
Heap_Control *heap,
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
a000efa0: e1a05000 mov r5, r0
a000efa4: e1a06001 mov r6, r1
Heap_Statistics *const stats = &heap->stats;
uintptr_t const block_size_floor = alloc_size + HEAP_BLOCK_HEADER_SIZE
- HEAP_ALLOC_BONUS;
uintptr_t const page_size = heap->page_size;
a000efa8: e58d2000 str r2, [sp]
Heap_Block *block = NULL;
uintptr_t alloc_begin = 0;
uint32_t search_count = 0;
bool search_again = false;
if ( block_size_floor < alloc_size ) {
a000efac: e58d300c str r3, [sp, #12]
a000efb0: 2a00006a bcs a000f160 <_Heap_Allocate_aligned_with_boundary+0x1d8>
/* Integer overflow occured */
return NULL;
}
if ( boundary != 0 ) {
a000efb4: e35b0000 cmp fp, #0
a000efb8: 0a000003 beq a000efcc <_Heap_Allocate_aligned_with_boundary+0x44>
if ( boundary < alloc_size ) {
a000efbc: e15b0001 cmp fp, r1 <== NOT EXECUTED
a000efc0: 3a000066 bcc a000f160 <_Heap_Allocate_aligned_with_boundary+0x1d8><== NOT EXECUTED
return NULL;
}
if ( alignment == 0 ) {
alignment = page_size;
a000efc4: e3580000 cmp r8, #0 <== NOT EXECUTED
a000efc8: 01a08002 moveq r8, r2 <== NOT EXECUTED
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
a000efcc: e59d2000 ldr r2, [sp]
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_ALLOC_BONUS;
a000efd0: e2663004 rsb r3, r6, #4
if ( stats->max_search < search_count ) {
stats->max_search = search_count;
}
return (void *) alloc_begin;
}
a000efd4: e595a008 ldr sl, [r5, #8]
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
a000efd8: e2822007 add r2, r2, #7
do {
Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
block = _Heap_Free_list_first( heap );
while ( block != free_list_tail ) {
a000efdc: e3a07000 mov r7, #0
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
a000efe0: e58d2014 str r2, [sp, #20]
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_ALLOC_BONUS;
a000efe4: e58d3018 str r3, [sp, #24]
do {
Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
block = _Heap_Free_list_first( heap );
while ( block != free_list_tail ) {
a000efe8: ea000048 b a000f110 <_Heap_Allocate_aligned_with_boundary+0x188>
/*
* The HEAP_PREV_BLOCK_USED flag is always set in the block size_and_flag
* field. Thus the value is about one unit larger than the real block
* size. The greater than operator takes this into account.
*/
if ( block->size_and_flag > block_size_floor ) {
a000efec: e59a4004 ldr r4, [sl, #4]
a000eff0: e59d200c ldr r2, [sp, #12]
a000eff4: e1540002 cmp r4, r2
a000eff8: 9a00003f bls a000f0fc <_Heap_Allocate_aligned_with_boundary+0x174>
a000effc: e28a3008 add r3, sl, #8
if ( alignment == 0 ) {
a000f000: e3580000 cmp r8, #0
a000f004: e58d3008 str r3, [sp, #8]
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Alloc_area_of_block(
const Heap_Block *block
)
{
return (uintptr_t) block + HEAP_BLOCK_HEADER_SIZE;
a000f008: 01a04003 moveq r4, r3
a000f00c: 0a00003b beq a000f100 <_Heap_Allocate_aligned_with_boundary+0x178>
uintptr_t alignment,
uintptr_t boundary
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
a000f010: e5952014 ldr r2, [r5, #20]
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
a000f014: e59d3014 ldr r3, [sp, #20]
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000f018: e3c44001 bic r4, r4, #1
uintptr_t alignment,
uintptr_t boundary
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
a000f01c: e58d2004 str r2, [sp, #4]
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
a000f020: e0629003 rsb r9, r2, r3
uintptr_t alloc_end = block_end + HEAP_ALLOC_BONUS;
uintptr_t alloc_begin = alloc_end - alloc_size;
a000f024: e59d2018 ldr r2, [sp, #24]
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
a000f028: e08a4004 add r4, sl, r4
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
a000f02c: e0899004 add r9, r9, r4
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_ALLOC_BONUS;
uintptr_t alloc_begin = alloc_end - alloc_size;
a000f030: e0824004 add r4, r2, r4
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
a000f034: e1a00004 mov r0, r4
a000f038: e1a01008 mov r1, r8
a000f03c: eb001682 bl a0014a4c <__umodsi3>
a000f040: e0604004 rsb r4, r0, r4
alloc_begin = _Heap_Align_down( alloc_begin, alignment );
/* Ensure that the we have a valid new block at the end */
if ( alloc_begin > alloc_begin_ceiling ) {
a000f044: e1540009 cmp r4, r9
a000f048: 9a000003 bls a000f05c <_Heap_Allocate_aligned_with_boundary+0xd4>
a000f04c: e1a00009 mov r0, r9
a000f050: e1a01008 mov r1, r8
a000f054: eb00167c bl a0014a4c <__umodsi3>
a000f058: e0604009 rsb r4, r0, r9
}
alloc_end = alloc_begin + alloc_size;
/* Ensure boundary constaint */
if ( boundary != 0 ) {
a000f05c: e35b0000 cmp fp, #0
a000f060: 0a000014 beq a000f0b8 <_Heap_Allocate_aligned_with_boundary+0x130>
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
a000f064: e59d3008 ldr r3, [sp, #8] <== NOT EXECUTED
/* Ensure that the we have a valid new block at the end */
if ( alloc_begin > alloc_begin_ceiling ) {
alloc_begin = _Heap_Align_down( alloc_begin_ceiling, alignment );
}
alloc_end = alloc_begin + alloc_size;
a000f068: e0849006 add r9, r4, r6 <== NOT EXECUTED
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
a000f06c: e0833006 add r3, r3, r6 <== NOT EXECUTED
a000f070: e58d3010 str r3, [sp, #16] <== NOT EXECUTED
a000f074: ea000008 b a000f09c <_Heap_Allocate_aligned_with_boundary+0x114><== NOT EXECUTED
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
if ( boundary_line < boundary_floor ) {
a000f078: e59d2010 ldr r2, [sp, #16] <== NOT EXECUTED
a000f07c: e1500002 cmp r0, r2 <== NOT EXECUTED
a000f080: 3a00001d bcc a000f0fc <_Heap_Allocate_aligned_with_boundary+0x174><== NOT EXECUTED
return 0;
}
alloc_begin = boundary_line - alloc_size;
a000f084: e0664000 rsb r4, r6, r0 <== NOT EXECUTED
a000f088: e1a00004 mov r0, r4 <== NOT EXECUTED
a000f08c: e1a01008 mov r1, r8 <== NOT EXECUTED
a000f090: eb00166d bl a0014a4c <__umodsi3> <== NOT EXECUTED
a000f094: e0604004 rsb r4, r0, r4 <== NOT EXECUTED
alloc_begin = _Heap_Align_down( alloc_begin, alignment );
alloc_end = alloc_begin + alloc_size;
a000f098: e0849006 add r9, r4, r6 <== NOT EXECUTED
a000f09c: e1a00009 mov r0, r9 <== NOT EXECUTED
a000f0a0: e1a0100b mov r1, fp <== NOT EXECUTED
a000f0a4: eb001668 bl a0014a4c <__umodsi3> <== NOT EXECUTED
a000f0a8: e0600009 rsb r0, r0, r9 <== NOT EXECUTED
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
a000f0ac: e1500009 cmp r0, r9 <== NOT EXECUTED
a000f0b0: 31540000 cmpcc r4, r0 <== NOT EXECUTED
a000f0b4: 3affffef bcc a000f078 <_Heap_Allocate_aligned_with_boundary+0xf0><== NOT EXECUTED
boundary_line = _Heap_Align_down( alloc_end, boundary );
}
}
/* Ensure that the we have a valid new block at the beginning */
if ( alloc_begin >= alloc_begin_floor ) {
a000f0b8: e59d3008 ldr r3, [sp, #8]
a000f0bc: e1540003 cmp r4, r3
a000f0c0: 3a00000d bcc a000f0fc <_Heap_Allocate_aligned_with_boundary+0x174>
a000f0c4: e1a00004 mov r0, r4
a000f0c8: e59d1000 ldr r1, [sp]
a000f0cc: eb00165e bl a0014a4c <__umodsi3>
a000f0d0: e3e09007 mvn r9, #7
a000f0d4: e06a9009 rsb r9, sl, r9
if ( free_size >= min_block_size || free_size == 0 ) {
return alloc_begin;
}
}
return 0;
a000f0d8: e59d2004 ldr r2, [sp, #4]
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
- HEAP_BLOCK_HEADER_SIZE);
a000f0dc: e0899004 add r9, r9, r4
if ( alloc_begin >= alloc_begin_floor ) {
uintptr_t const alloc_block_begin =
(uintptr_t) _Heap_Block_of_alloc_area( alloc_begin, page_size );
uintptr_t const free_size = alloc_block_begin - block_begin;
if ( free_size >= min_block_size || free_size == 0 ) {
a000f0e0: e0603009 rsb r3, r0, r9
return alloc_begin;
}
}
return 0;
a000f0e4: e1590000 cmp r9, r0
a000f0e8: 11530002 cmpne r3, r2
a000f0ec: 33a09000 movcc r9, #0
a000f0f0: 23a09001 movcs r9, #1
a000f0f4: 31a04009 movcc r4, r9
a000f0f8: ea000000 b a000f100 <_Heap_Allocate_aligned_with_boundary+0x178>
a000f0fc: e3a04000 mov r4, #0
}
/* Statistics */
++search_count;
if ( alloc_begin != 0 ) {
a000f100: e3540000 cmp r4, #0
);
}
}
/* Statistics */
++search_count;
a000f104: e2877001 add r7, r7, #1
if ( alloc_begin != 0 ) {
a000f108: 1a000004 bne a000f120 <_Heap_Allocate_aligned_with_boundary+0x198>
break;
}
block = block->next;
a000f10c: e59aa008 ldr sl, [sl, #8]
do {
Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
block = _Heap_Free_list_first( heap );
while ( block != free_list_tail ) {
a000f110: e15a0005 cmp sl, r5
a000f114: 1affffb4 bne a000efec <_Heap_Allocate_aligned_with_boundary+0x64>
a000f118: e3a04000 mov r4, #0
a000f11c: ea00000a b a000f14c <_Heap_Allocate_aligned_with_boundary+0x1c4>
search_again = _Heap_Protection_free_delayed_blocks( heap, alloc_begin );
} while ( search_again );
if ( alloc_begin != 0 ) {
/* Statistics */
++stats->allocs;
a000f120: e5953048 ldr r3, [r5, #72] ; 0x48
stats->searches += search_count;
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
a000f124: e1a00005 mov r0, r5
a000f128: e1a0100a mov r1, sl
search_again = _Heap_Protection_free_delayed_blocks( heap, alloc_begin );
} while ( search_again );
if ( alloc_begin != 0 ) {
/* Statistics */
++stats->allocs;
a000f12c: e2833001 add r3, r3, #1
a000f130: e5853048 str r3, [r5, #72] ; 0x48
stats->searches += search_count;
a000f134: e595304c ldr r3, [r5, #76] ; 0x4c
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
a000f138: e1a02004 mov r2, r4
} while ( search_again );
if ( alloc_begin != 0 ) {
/* Statistics */
++stats->allocs;
stats->searches += search_count;
a000f13c: e0833007 add r3, r3, r7
a000f140: e585304c str r3, [r5, #76] ; 0x4c
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
a000f144: e1a03006 mov r3, r6
a000f148: ebffecf3 bl a000a51c <_Heap_Block_allocate>
boundary
);
}
/* Statistics */
if ( stats->max_search < search_count ) {
a000f14c: e5953044 ldr r3, [r5, #68] ; 0x44
stats->max_search = search_count;
}
return (void *) alloc_begin;
a000f150: e1a00004 mov r0, r4
boundary
);
}
/* Statistics */
if ( stats->max_search < search_count ) {
a000f154: e1530007 cmp r3, r7
stats->max_search = search_count;
a000f158: 35857044 strcc r7, [r5, #68] ; 0x44
}
return (void *) alloc_begin;
a000f15c: ea000000 b a000f164 <_Heap_Allocate_aligned_with_boundary+0x1dc>
return NULL;
}
if ( boundary != 0 ) {
if ( boundary < alloc_size ) {
return NULL;
a000f160: e3a00000 mov r0, #0
if ( stats->max_search < search_count ) {
stats->max_search = search_count;
}
return (void *) alloc_begin;
}
a000f164: e28dd01c add sp, sp, #28
a000f168: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
a000a51c <_Heap_Block_allocate>:
Heap_Control *heap,
Heap_Block *block,
uintptr_t alloc_begin,
uintptr_t alloc_size
)
{
a000a51c: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr}
}
_Heap_Protection_block_initialize( heap, block );
return block;
}
a000a520: e591a004 ldr sl, [r1, #4]
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Alloc_area_of_block(
const Heap_Block *block
)
{
return (uintptr_t) block + HEAP_BLOCK_HEADER_SIZE;
a000a524: e2426008 sub r6, r2, #8
Heap_Control *heap,
Heap_Block *block,
uintptr_t alloc_begin,
uintptr_t alloc_size
)
{
a000a528: e1a04001 mov r4, r1
a000a52c: e1a07003 mov r7, r3
Heap_Statistics *const stats = &heap->stats;
uintptr_t const alloc_area_begin = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_area_offset = alloc_begin - alloc_area_begin;
a000a530: e0613006 rsb r3, r1, r6
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000a534: e3ca1001 bic r1, sl, #1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a000a538: e0849001 add r9, r4, r1
Heap_Control *heap,
Heap_Block *block,
uintptr_t alloc_begin,
uintptr_t alloc_size
)
{
a000a53c: e1a05000 mov r5, r0
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000a540: e5990004 ldr r0, [r9, #4]
Heap_Block *free_list_anchor = NULL;
_HAssert( alloc_area_begin <= alloc_begin );
if ( _Heap_Is_free( block ) ) {
a000a544: e3100001 tst r0, #1
/* Statistics */
--stats->free_blocks;
++stats->used_blocks;
stats->free_size -= _Heap_Block_size( block );
} else {
free_list_anchor = _Heap_Free_list_head( heap );
a000a548: 11a08005 movne r8, r5
Heap_Block *free_list_anchor = NULL;
_HAssert( alloc_area_begin <= alloc_begin );
if ( _Heap_Is_free( block ) ) {
a000a54c: 1a00000c bne a000a584 <_Heap_Block_allocate+0x68>
return _Heap_Free_list_tail(heap)->prev;
}
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
a000a550: e5940008 ldr r0, [r4, #8]
free_list_anchor = block->prev;
a000a554: e594800c ldr r8, [r4, #12]
Heap_Block *prev = block->prev;
prev->next = next;
a000a558: e5880008 str r0, [r8, #8]
next->prev = prev;
a000a55c: e580800c str r8, [r0, #12]
_Heap_Free_list_remove( block );
/* Statistics */
--stats->free_blocks;
a000a560: e5950038 ldr r0, [r5, #56] ; 0x38
a000a564: e2400001 sub r0, r0, #1
a000a568: e5850038 str r0, [r5, #56] ; 0x38
++stats->used_blocks;
a000a56c: e5950040 ldr r0, [r5, #64] ; 0x40
a000a570: e2800001 add r0, r0, #1
a000a574: e5850040 str r0, [r5, #64] ; 0x40
stats->free_size -= _Heap_Block_size( block );
a000a578: e5950030 ldr r0, [r5, #48] ; 0x30
a000a57c: e0611000 rsb r1, r1, r0
a000a580: e5851030 str r1, [r5, #48] ; 0x30
} else {
free_list_anchor = _Heap_Free_list_head( heap );
}
if ( alloc_area_offset < heap->page_size ) {
a000a584: e5951010 ldr r1, [r5, #16]
a000a588: e1530001 cmp r3, r1
a000a58c: 2a000005 bcs a000a5a8 <_Heap_Block_allocate+0x8c>
Heap_Block *block,
Heap_Block *free_list_anchor,
uintptr_t alloc_size
)
{
_Heap_Block_split( heap, block, free_list_anchor, alloc_size );
a000a590: e1a00005 mov r0, r5
a000a594: e1a01004 mov r1, r4
a000a598: e1a02008 mov r2, r8
a000a59c: e0833007 add r3, r3, r7
a000a5a0: ebffff2e bl a000a260 <_Heap_Block_split>
a000a5a4: ea000021 b a000a630 <_Heap_Block_allocate+0x114>
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
a000a5a8: e1a00002 mov r0, r2
a000a5ac: eb002926 bl a0014a4c <__umodsi3>
_HAssert( block_size >= heap->min_block_size );
_HAssert( new_block_size >= heap->min_block_size );
/* Statistics */
stats->free_size += block_size;
a000a5b0: e5952030 ldr r2, [r5, #48] ; 0x30
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
- HEAP_BLOCK_HEADER_SIZE);
a000a5b4: e0606006 rsb r6, r0, r6
_Heap_Block_of_alloc_area( alloc_begin, heap->page_size );
uintptr_t const new_block_begin = (uintptr_t) new_block;
uintptr_t const new_block_size = block_end - new_block_begin;
block_end = new_block_begin;
block_size = block_end - block_begin;
a000a5b8: e0643006 rsb r3, r4, r6
_HAssert( block_size >= heap->min_block_size );
_HAssert( new_block_size >= heap->min_block_size );
/* Statistics */
stats->free_size += block_size;
a000a5bc: e0822003 add r2, r2, r3
if ( _Heap_Is_prev_used( block ) ) {
a000a5c0: e31a0001 tst sl, #1
uintptr_t block_end = block_begin + block_size;
Heap_Block *const new_block =
_Heap_Block_of_alloc_area( alloc_begin, heap->page_size );
uintptr_t const new_block_begin = (uintptr_t) new_block;
uintptr_t const new_block_size = block_end - new_block_begin;
a000a5c4: e0669009 rsb r9, r6, r9
_HAssert( block_size >= heap->min_block_size );
_HAssert( new_block_size >= heap->min_block_size );
/* Statistics */
stats->free_size += block_size;
a000a5c8: e5852030 str r2, [r5, #48] ; 0x30
if ( _Heap_Is_prev_used( block ) ) {
a000a5cc: 0a000009 beq a000a5f8 <_Heap_Block_allocate+0xdc>
RTEMS_INLINE_ROUTINE void _Heap_Free_list_insert_after(
Heap_Block *block_before,
Heap_Block *new_block
)
{
Heap_Block *next = block_before->next;
a000a5d0: e5982008 ldr r2, [r8, #8]
new_block->next = next;
new_block->prev = block_before;
a000a5d4: e584800c str r8, [r4, #12]
Heap_Block *new_block
)
{
Heap_Block *next = block_before->next;
new_block->next = next;
a000a5d8: e5842008 str r2, [r4, #8]
new_block->prev = block_before;
block_before->next = new_block;
next->prev = new_block;
a000a5dc: e582400c str r4, [r2, #12]
_Heap_Free_list_insert_after( free_list_anchor, block );
free_list_anchor = block;
/* Statistics */
++stats->free_blocks;
a000a5e0: e5952038 ldr r2, [r5, #56] ; 0x38
{
Heap_Block *next = block_before->next;
new_block->next = next;
new_block->prev = block_before;
block_before->next = new_block;
a000a5e4: e5884008 str r4, [r8, #8]
a000a5e8: e2822001 add r2, r2, #1
a000a5ec: e5852038 str r2, [r5, #56] ; 0x38
a000a5f0: e1a02004 mov r2, r4
a000a5f4: ea000005 b a000a610 <_Heap_Block_allocate+0xf4>
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Prev_block(
const Heap_Block *block
)
{
return (Heap_Block *) ((uintptr_t) block - block->prev_size);
a000a5f8: e5942000 ldr r2, [r4] <== NOT EXECUTED
a000a5fc: e0624004 rsb r4, r2, r4 <== NOT EXECUTED
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000a600: e5942004 ldr r2, [r4, #4] <== NOT EXECUTED
a000a604: e3c22001 bic r2, r2, #1 <== NOT EXECUTED
} else {
Heap_Block *const prev_block = _Heap_Prev_block( block );
uintptr_t const prev_block_size = _Heap_Block_size( prev_block );
block = prev_block;
block_size += prev_block_size;
a000a608: e0833002 add r3, r3, r2 <== NOT EXECUTED
a000a60c: e1a02008 mov r2, r8 <== NOT EXECUTED
}
block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED;
a000a610: e3831001 orr r1, r3, #1
a000a614: e5841004 str r1, [r4, #4]
new_block->prev_size = block_size;
a000a618: e8860208 stm r6, {r3, r9}
new_block->size_and_flag = new_block_size;
_Heap_Block_split( heap, new_block, free_list_anchor, alloc_size );
a000a61c: e1a00005 mov r0, r5
a000a620: e1a01006 mov r1, r6
a000a624: e1a03007 mov r3, r7
a000a628: ebffff0c bl a000a260 <_Heap_Block_split>
a000a62c: e1a04006 mov r4, r6
alloc_size
);
}
/* Statistics */
if ( stats->min_free_size > stats->free_size ) {
a000a630: e5953030 ldr r3, [r5, #48] ; 0x30
a000a634: e5952034 ldr r2, [r5, #52] ; 0x34
}
_Heap_Protection_block_initialize( heap, block );
return block;
}
a000a638: e1a00004 mov r0, r4
alloc_size
);
}
/* Statistics */
if ( stats->min_free_size > stats->free_size ) {
a000a63c: e1520003 cmp r2, r3
stats->min_free_size = stats->free_size;
a000a640: 85853034 strhi r3, [r5, #52] ; 0x34
}
_Heap_Protection_block_initialize( heap, block );
return block;
}
a000a644: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc}
a000a260 <_Heap_Block_split>:
Heap_Control *heap,
Heap_Block *block,
Heap_Block *free_list_anchor,
uintptr_t alloc_size
)
{
a000a260: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
Heap_Statistics *const stats = &heap->stats;
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
a000a264: e5908014 ldr r8, [r0, #20]
uintptr_t alloc_size
)
{
Heap_Statistics *const stats = &heap->stats;
uintptr_t const page_size = heap->page_size;
a000a268: e590a010 ldr sl, [r0, #16]
Heap_Control *heap,
Heap_Block *block,
Heap_Block *free_list_anchor,
uintptr_t alloc_size
)
{
a000a26c: e1a05001 mov r5, r1
Heap_Statistics *const stats = &heap->stats;
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
uintptr_t const min_alloc_size = min_block_size - HEAP_BLOCK_HEADER_SIZE;
a000a270: e248b008 sub fp, r8, #8
return heap->stats.size;
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Max( uintptr_t a, uintptr_t b )
{
return a > b ? a : b;
a000a274: e153000b cmp r3, fp
a000a278: 21a0b003 movcs fp, r3
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const used_size =
a000a27c: e28bb008 add fp, fp, #8
}
_Heap_Protection_block_initialize( heap, block );
return block;
}
a000a280: e5919004 ldr r9, [r1, #4]
Heap_Control *heap,
Heap_Block *block,
Heap_Block *free_list_anchor,
uintptr_t alloc_size
)
{
a000a284: e1a04000 mov r4, r0
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_up(
uintptr_t value,
uintptr_t alignment
)
{
uintptr_t remainder = value % alignment;
a000a288: e1a0100a mov r1, sl
a000a28c: e1a0000b mov r0, fp
a000a290: e1a06002 mov r6, r2
a000a294: eb0029ec bl a0014a4c <__umodsi3>
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000a298: e3c97001 bic r7, r9, #1
uintptr_t alignment
)
{
uintptr_t remainder = value % alignment;
if ( remainder != 0 ) {
a000a29c: e3500000 cmp r0, #0
uintptr_t const used_size =
_Heap_Max( alloc_size, min_alloc_size ) + HEAP_BLOCK_HEADER_SIZE;
uintptr_t const used_block_size = _Heap_Align_up( used_size, page_size );
uintptr_t const free_size = block_size + HEAP_ALLOC_BONUS - used_size;
a000a2a0: e2872004 add r2, r7, #4
return value - remainder + alignment;
a000a2a4: 108ba00a addne sl, fp, sl
} else {
return value;
a000a2a8: 01a0a00b moveq sl, fp
uintptr_t const free_size_limit = min_block_size + HEAP_ALLOC_BONUS;
a000a2ac: e2888004 add r8, r8, #4
uintptr_t const used_size =
_Heap_Max( alloc_size, min_alloc_size ) + HEAP_BLOCK_HEADER_SIZE;
uintptr_t const used_block_size = _Heap_Align_up( used_size, page_size );
uintptr_t const free_size = block_size + HEAP_ALLOC_BONUS - used_size;
a000a2b0: e06bb002 rsb fp, fp, r2
)
{
uintptr_t remainder = value % alignment;
if ( remainder != 0 ) {
return value - remainder + alignment;
a000a2b4: 1060a00a rsbne sl, r0, sl
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a000a2b8: e0853007 add r3, r5, r7
Heap_Block *next_block = _Heap_Block_at( block, block_size );
_HAssert( used_size <= block_size + HEAP_ALLOC_BONUS );
_HAssert( used_size + free_size == block_size + HEAP_ALLOC_BONUS );
if ( free_size >= free_size_limit ) {
a000a2bc: e15b0008 cmp fp, r8
next_block->prev_size = free_block_size;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
_Heap_Protection_block_initialize( heap, free_block );
} else {
next_block->size_and_flag |= HEAP_PREV_BLOCK_USED;
a000a2c0: 35932004 ldrcc r2, [r3, #4]
a000a2c4: 33822001 orrcc r2, r2, #1
Heap_Block *next_block = _Heap_Block_at( block, block_size );
_HAssert( used_size <= block_size + HEAP_ALLOC_BONUS );
_HAssert( used_size + free_size == block_size + HEAP_ALLOC_BONUS );
if ( free_size >= free_size_limit ) {
a000a2c8: 3a000023 bcc a000a35c <_Heap_Block_split+0xfc>
_HAssert( used_block_size + free_block_size == block_size );
_Heap_Block_set_size( block, used_block_size );
/* Statistics */
stats->free_size += free_block_size;
a000a2cc: e5941030 ldr r1, [r4, #48] ; 0x30
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(
Heap_Block *block,
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000a2d0: e2099001 and r9, r9, #1
_HAssert( used_size <= block_size + HEAP_ALLOC_BONUS );
_HAssert( used_size + free_size == block_size + HEAP_ALLOC_BONUS );
if ( free_size >= free_size_limit ) {
Heap_Block *const free_block = _Heap_Block_at( block, used_block_size );
uintptr_t free_block_size = block_size - used_block_size;
a000a2d4: e06a7007 rsb r7, sl, r7
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a000a2d8: e08a2005 add r2, sl, r5
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
block->size_and_flag = size | flag;
a000a2dc: e18aa009 orr sl, sl, r9
a000a2e0: e585a004 str sl, [r5, #4]
_HAssert( used_block_size + free_block_size == block_size );
_Heap_Block_set_size( block, used_block_size );
/* Statistics */
stats->free_size += free_block_size;
a000a2e4: e0811007 add r1, r1, r7
a000a2e8: e5841030 str r1, [r4, #48] ; 0x30
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000a2ec: e5931004 ldr r1, [r3, #4]
a000a2f0: e3c11001 bic r1, r1, #1
}
_Heap_Protection_block_initialize( heap, block );
return block;
}
a000a2f4: e0830001 add r0, r3, r1
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000a2f8: e5900004 ldr r0, [r0, #4]
_Heap_Block_set_size( block, used_block_size );
/* Statistics */
stats->free_size += free_block_size;
if ( _Heap_Is_used( next_block ) ) {
a000a2fc: e3100001 tst r0, #1
a000a300: 0a000008 beq a000a328 <_Heap_Block_split+0xc8>
RTEMS_INLINE_ROUTINE void _Heap_Free_list_insert_after(
Heap_Block *block_before,
Heap_Block *new_block
)
{
Heap_Block *next = block_before->next;
a000a304: e5961008 ldr r1, [r6, #8]
new_block->next = next;
new_block->prev = block_before;
a000a308: e582600c str r6, [r2, #12]
Heap_Block *new_block
)
{
Heap_Block *next = block_before->next;
new_block->next = next;
a000a30c: e5821008 str r1, [r2, #8]
new_block->prev = block_before;
block_before->next = new_block;
next->prev = new_block;
a000a310: e581200c str r2, [r1, #12]
_Heap_Free_list_insert_after( free_list_anchor, free_block );
/* Statistics */
++stats->free_blocks;
a000a314: e5941038 ldr r1, [r4, #56] ; 0x38
{
Heap_Block *next = block_before->next;
new_block->next = next;
new_block->prev = block_before;
block_before->next = new_block;
a000a318: e5862008 str r2, [r6, #8]
a000a31c: e2811001 add r1, r1, #1
a000a320: e5841038 str r1, [r4, #56] ; 0x38
a000a324: ea000007 b a000a348 <_Heap_Block_split+0xe8>
RTEMS_INLINE_ROUTINE void _Heap_Free_list_replace(
Heap_Block *old_block,
Heap_Block *new_block
)
{
Heap_Block *next = old_block->next;
a000a328: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED
Heap_Block *prev = old_block->prev;
a000a32c: e593300c ldr r3, [r3, #12] <== NOT EXECUTED
} else {
uintptr_t const next_block_size = _Heap_Block_size( next_block );
_Heap_Free_list_replace( next_block, free_block );
free_block_size += next_block_size;
a000a330: e0877001 add r7, r7, r1 <== NOT EXECUTED
new_block->next = next;
a000a334: e5820008 str r0, [r2, #8] <== NOT EXECUTED
new_block->prev = prev;
a000a338: e582300c str r3, [r2, #12] <== NOT EXECUTED
next->prev = new_block;
prev->next = new_block;
a000a33c: e5832008 str r2, [r3, #8] <== NOT EXECUTED
Heap_Block *prev = old_block->prev;
new_block->next = next;
new_block->prev = prev;
next->prev = new_block;
a000a340: e580200c str r2, [r0, #12] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a000a344: e0873002 add r3, r7, r2 <== NOT EXECUTED
next_block = _Heap_Block_at( free_block, free_block_size );
}
free_block->size_and_flag = free_block_size | HEAP_PREV_BLOCK_USED;
a000a348: e3871001 orr r1, r7, #1
a000a34c: e5821004 str r1, [r2, #4]
next_block->prev_size = free_block_size;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
a000a350: e5932004 ldr r2, [r3, #4]
next_block = _Heap_Block_at( free_block, free_block_size );
}
free_block->size_and_flag = free_block_size | HEAP_PREV_BLOCK_USED;
next_block->prev_size = free_block_size;
a000a354: e5837000 str r7, [r3]
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
a000a358: e3c22001 bic r2, r2, #1
_Heap_Protection_block_initialize( heap, free_block );
} else {
next_block->size_and_flag |= HEAP_PREV_BLOCK_USED;
a000a35c: e5832004 str r2, [r3, #4]
a000a360: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
a000f4a4 <_Heap_Extend>:
Heap_Control *heap,
void *extend_area_begin_ptr,
uintptr_t extend_area_size,
uintptr_t *extended_size_ptr
)
{
a000f4a4: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
a000f4a8: e1a05001 mov r5, r1
Heap_Statistics *const stats = &heap->stats;
Heap_Block *const first_block = heap->first_block;
a000f4ac: e5901020 ldr r1, [r0, #32]
Heap_Control *heap,
void *extend_area_begin_ptr,
uintptr_t extend_area_size,
uintptr_t *extended_size_ptr
)
{
a000f4b0: e24dd028 sub sp, sp, #40 ; 0x28
a000f4b4: e58d3018 str r3, [sp, #24]
Heap_Statistics *const stats = &heap->stats;
Heap_Block *const first_block = heap->first_block;
a000f4b8: e58d1010 str r1, [sp, #16]
Heap_Block *merge_above_block = NULL;
Heap_Block *link_below_block = NULL;
Heap_Block *link_above_block = NULL;
Heap_Block *extend_first_block = NULL;
Heap_Block *extend_last_block = NULL;
uintptr_t const page_size = heap->page_size;
a000f4bc: e5903010 ldr r3, [r0, #16]
uintptr_t const min_block_size = heap->min_block_size;
uintptr_t const extend_area_begin = (uintptr_t) extend_area_begin_ptr;
uintptr_t const extend_area_end = extend_area_begin + extend_area_size;
uintptr_t const free_size = stats->free_size;
a000f4c0: e5901030 ldr r1, [r0, #48] ; 0x30
Heap_Block *start_block = first_block;
Heap_Block *merge_below_block = NULL;
Heap_Block *merge_above_block = NULL;
Heap_Block *link_below_block = NULL;
Heap_Block *link_above_block = NULL;
Heap_Block *extend_first_block = NULL;
a000f4c4: e3a08000 mov r8, #0
uintptr_t const free_size = stats->free_size;
uintptr_t extend_first_block_size = 0;
uintptr_t extended_size = 0;
bool extend_area_ok = false;
if ( extend_area_end < extend_area_begin ) {
a000f4c8: e0956002 adds r6, r5, r2
Heap_Control *heap,
void *extend_area_begin_ptr,
uintptr_t extend_area_size,
uintptr_t *extended_size_ptr
)
{
a000f4cc: e1a04000 mov r4, r0
Heap_Block *merge_above_block = NULL;
Heap_Block *link_below_block = NULL;
Heap_Block *link_above_block = NULL;
Heap_Block *extend_first_block = NULL;
Heap_Block *extend_last_block = NULL;
uintptr_t const page_size = heap->page_size;
a000f4d0: e58d3014 str r3, [sp, #20]
Heap_Block *start_block = first_block;
Heap_Block *merge_below_block = NULL;
Heap_Block *merge_above_block = NULL;
Heap_Block *link_below_block = NULL;
Heap_Block *link_above_block = NULL;
Heap_Block *extend_first_block = NULL;
a000f4d4: e58d8024 str r8, [sp, #36] ; 0x24
Heap_Block *extend_last_block = NULL;
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
a000f4d8: e5903014 ldr r3, [r0, #20]
Heap_Block *merge_below_block = NULL;
Heap_Block *merge_above_block = NULL;
Heap_Block *link_below_block = NULL;
Heap_Block *link_above_block = NULL;
Heap_Block *extend_first_block = NULL;
Heap_Block *extend_last_block = NULL;
a000f4dc: e58d8020 str r8, [sp, #32]
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
uintptr_t const extend_area_begin = (uintptr_t) extend_area_begin_ptr;
uintptr_t const extend_area_end = extend_area_begin + extend_area_size;
uintptr_t const free_size = stats->free_size;
a000f4e0: e58d101c str r1, [sp, #28]
uintptr_t extend_first_block_size = 0;
uintptr_t extended_size = 0;
bool extend_area_ok = false;
if ( extend_area_end < extend_area_begin ) {
return false;
a000f4e4: 21a00008 movcs r0, r8
uintptr_t const free_size = stats->free_size;
uintptr_t extend_first_block_size = 0;
uintptr_t extended_size = 0;
bool extend_area_ok = false;
if ( extend_area_end < extend_area_begin ) {
a000f4e8: 2a00009e bcs a000f768 <_Heap_Extend+0x2c4>
return false;
}
extend_area_ok = _Heap_Get_first_and_last_block(
a000f4ec: e28d1024 add r1, sp, #36 ; 0x24
a000f4f0: e58d1000 str r1, [sp]
a000f4f4: e28d1020 add r1, sp, #32
a000f4f8: e58d1004 str r1, [sp, #4]
a000f4fc: e1a00005 mov r0, r5
a000f500: e1a01002 mov r1, r2
a000f504: e59d2014 ldr r2, [sp, #20]
a000f508: ebffec6d bl a000a6c4 <_Heap_Get_first_and_last_block>
page_size,
min_block_size,
&extend_first_block,
&extend_last_block
);
if (!extend_area_ok ) {
a000f50c: e3500000 cmp r0, #0
a000f510: 0a000094 beq a000f768 <_Heap_Extend+0x2c4>
a000f514: e59da010 ldr sl, [sp, #16]
a000f518: e1a07008 mov r7, r8
a000f51c: e1a09008 mov r9, r8
return false;
}
do {
uintptr_t const sub_area_begin = (start_block != first_block) ?
(uintptr_t) start_block : heap->area_begin;
a000f520: e5941018 ldr r1, [r4, #24]
a000f524: e1a03008 mov r3, r8
a000f528: e1a0c004 mov ip, r4
a000f52c: ea000000 b a000f534 <_Heap_Extend+0x90>
a000f530: e1a0100a mov r1, sl <== NOT EXECUTED
uintptr_t const sub_area_end = start_block->prev_size;
a000f534: e59a4000 ldr r4, [sl]
Heap_Block *const end_block =
_Heap_Block_of_alloc_area( sub_area_end, page_size );
if (
a000f538: e1560001 cmp r6, r1
a000f53c: 93a00000 movls r0, #0
a000f540: 83a00001 movhi r0, #1
a000f544: e1550004 cmp r5, r4
a000f548: 23a00000 movcs r0, #0
a000f54c: e3500000 cmp r0, #0
a000f550: 1a000083 bne a000f764 <_Heap_Extend+0x2c0>
sub_area_end > extend_area_begin && extend_area_end > sub_area_begin
) {
return false;
}
if ( extend_area_end == sub_area_begin ) {
a000f554: e1560001 cmp r6, r1
a000f558: 01a0300a moveq r3, sl
a000f55c: 0a000001 beq a000f568 <_Heap_Extend+0xc4>
merge_below_block = start_block;
} else if ( extend_area_end < sub_area_end ) {
a000f560: e1560004 cmp r6, r4
a000f564: 31a0900a movcc r9, sl
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
a000f568: e1a00004 mov r0, r4
a000f56c: e59d1014 ldr r1, [sp, #20]
a000f570: e58d300c str r3, [sp, #12]
a000f574: e58dc008 str ip, [sp, #8]
a000f578: eb001689 bl a0014fa4 <__umodsi3>
a000f57c: e244b008 sub fp, r4, #8
link_below_block = start_block;
}
if ( sub_area_end == extend_area_begin ) {
a000f580: e1540005 cmp r4, r5
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
- HEAP_BLOCK_HEADER_SIZE);
a000f584: e060000b rsb r0, r0, fp
a000f588: e59d300c ldr r3, [sp, #12]
a000f58c: e59dc008 ldr ip, [sp, #8]
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
a000f590: 01a07000 moveq r7, r0
start_block->prev_size = extend_area_end;
a000f594: 058a6000 streq r6, [sl]
merge_below_block = start_block;
} else if ( extend_area_end < sub_area_end ) {
link_below_block = start_block;
}
if ( sub_area_end == extend_area_begin ) {
a000f598: 0a000000 beq a000f5a0 <_Heap_Extend+0xfc>
a000f59c: 31a08000 movcc r8, r0
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000f5a0: e590a004 ldr sl, [r0, #4]
} else if ( sub_area_end < extend_area_begin ) {
link_above_block = end_block;
}
start_block = _Heap_Block_at( end_block, _Heap_Block_size( end_block ) );
} while ( start_block != first_block );
a000f5a4: e59d2010 ldr r2, [sp, #16]
a000f5a8: e3caa001 bic sl, sl, #1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a000f5ac: e080a00a add sl, r0, sl
a000f5b0: e15a0002 cmp sl, r2
a000f5b4: 1affffdd bne a000f530 <_Heap_Extend+0x8c>
a000f5b8: e1a02009 mov r2, r9
a000f5bc: e1a09003 mov r9, r3
if ( extend_area_begin < heap->area_begin ) {
a000f5c0: e59c3018 ldr r3, [ip, #24]
a000f5c4: e1a0400c mov r4, ip
a000f5c8: e1550003 cmp r5, r3
heap->area_begin = extend_area_begin;
a000f5cc: 358c5018 strcc r5, [ip, #24]
}
start_block = _Heap_Block_at( end_block, _Heap_Block_size( end_block ) );
} while ( start_block != first_block );
if ( extend_area_begin < heap->area_begin ) {
a000f5d0: 3a000002 bcc a000f5e0 <_Heap_Extend+0x13c>
heap->area_begin = extend_area_begin;
} else if ( heap->area_end < extend_area_end ) {
a000f5d4: e59c301c ldr r3, [ip, #28] <== NOT EXECUTED
a000f5d8: e1530006 cmp r3, r6 <== NOT EXECUTED
heap->area_end = extend_area_end;
a000f5dc: 358c601c strcc r6, [ip, #28] <== NOT EXECUTED
}
extend_first_block_size =
(uintptr_t) extend_last_block - (uintptr_t) extend_first_block;
a000f5e0: e59d1024 ldr r1, [sp, #36] ; 0x24
a000f5e4: e59d3020 ldr r3, [sp, #32]
extend_first_block->prev_size = extend_area_end;
a000f5e8: e5816000 str r6, [r1]
heap->area_begin = extend_area_begin;
} else if ( heap->area_end < extend_area_end ) {
heap->area_end = extend_area_end;
}
extend_first_block_size =
a000f5ec: e0610003 rsb r0, r1, r3
(uintptr_t) extend_last_block - (uintptr_t) extend_first_block;
extend_first_block->prev_size = extend_area_end;
extend_first_block->size_and_flag =
extend_first_block_size | HEAP_PREV_BLOCK_USED;
a000f5f0: e380c001 orr ip, r0, #1
_Heap_Protection_block_initialize( heap, extend_first_block );
extend_last_block->prev_size = extend_first_block_size;
a000f5f4: e5830000 str r0, [r3]
extend_last_block->size_and_flag = 0;
a000f5f8: e3a00000 mov r0, #0
extend_first_block_size =
(uintptr_t) extend_last_block - (uintptr_t) extend_first_block;
extend_first_block->prev_size = extend_area_end;
extend_first_block->size_and_flag =
a000f5fc: e581c004 str ip, [r1, #4]
extend_first_block_size | HEAP_PREV_BLOCK_USED;
_Heap_Protection_block_initialize( heap, extend_first_block );
extend_last_block->prev_size = extend_first_block_size;
extend_last_block->size_and_flag = 0;
a000f600: e5830004 str r0, [r3, #4]
_Heap_Protection_block_initialize( heap, extend_last_block );
if ( (uintptr_t) extend_first_block < (uintptr_t) heap->first_block ) {
a000f604: e5940020 ldr r0, [r4, #32]
a000f608: e1500001 cmp r0, r1
heap->first_block = extend_first_block;
a000f60c: 85841020 strhi r1, [r4, #32]
extend_last_block->prev_size = extend_first_block_size;
extend_last_block->size_and_flag = 0;
_Heap_Protection_block_initialize( heap, extend_last_block );
if ( (uintptr_t) extend_first_block < (uintptr_t) heap->first_block ) {
a000f610: 8a000002 bhi a000f620 <_Heap_Extend+0x17c>
heap->first_block = extend_first_block;
} else if ( (uintptr_t) extend_last_block > (uintptr_t) heap->last_block ) {
a000f614: e5941024 ldr r1, [r4, #36] ; 0x24 <== NOT EXECUTED
a000f618: e1510003 cmp r1, r3 <== NOT EXECUTED
heap->last_block = extend_last_block;
a000f61c: 35843024 strcc r3, [r4, #36] ; 0x24 <== NOT EXECUTED
}
if ( merge_below_block != NULL ) {
a000f620: e3590000 cmp r9, #0
a000f624: 0a000010 beq a000f66c <_Heap_Extend+0x1c8>
Heap_Control *heap,
uintptr_t extend_area_begin,
Heap_Block *first_block
)
{
uintptr_t const page_size = heap->page_size;
a000f628: e594a010 ldr sl, [r4, #16] <== NOT EXECUTED
uintptr_t const new_first_block_alloc_begin =
_Heap_Align_up( extend_area_begin + HEAP_BLOCK_HEADER_SIZE, page_size );
a000f62c: e2855008 add r5, r5, #8 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_up(
uintptr_t value,
uintptr_t alignment
)
{
uintptr_t remainder = value % alignment;
a000f630: e1a00005 mov r0, r5 <== NOT EXECUTED
a000f634: e1a0100a mov r1, sl <== NOT EXECUTED
a000f638: eb001659 bl a0014fa4 <__umodsi3> <== NOT EXECUTED
if ( remainder != 0 ) {
a000f63c: e3500000 cmp r0, #0 <== NOT EXECUTED
return value - remainder + alignment;
a000f640: 1085500a addne r5, r5, sl <== NOT EXECUTED
uintptr_t const first_block_begin = (uintptr_t) first_block;
uintptr_t const new_first_block_size =
first_block_begin - new_first_block_begin;
Heap_Block *const new_first_block = (Heap_Block *) new_first_block_begin;
new_first_block->prev_size = first_block->prev_size;
a000f644: e5993000 ldr r3, [r9] <== NOT EXECUTED
a000f648: 10605005 rsbne r5, r0, r5 <== NOT EXECUTED
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const new_first_block_alloc_begin =
_Heap_Align_up( extend_area_begin + HEAP_BLOCK_HEADER_SIZE, page_size );
uintptr_t const new_first_block_begin =
a000f64c: e2451008 sub r1, r5, #8 <== NOT EXECUTED
uintptr_t const first_block_begin = (uintptr_t) first_block;
uintptr_t const new_first_block_size =
first_block_begin - new_first_block_begin;
Heap_Block *const new_first_block = (Heap_Block *) new_first_block_begin;
new_first_block->prev_size = first_block->prev_size;
a000f650: e5053008 str r3, [r5, #-8] <== NOT EXECUTED
uintptr_t const new_first_block_alloc_begin =
_Heap_Align_up( extend_area_begin + HEAP_BLOCK_HEADER_SIZE, page_size );
uintptr_t const new_first_block_begin =
new_first_block_alloc_begin - HEAP_BLOCK_HEADER_SIZE;
uintptr_t const first_block_begin = (uintptr_t) first_block;
uintptr_t const new_first_block_size =
a000f654: e0613009 rsb r3, r1, r9 <== NOT EXECUTED
first_block_begin - new_first_block_begin;
Heap_Block *const new_first_block = (Heap_Block *) new_first_block_begin;
new_first_block->prev_size = first_block->prev_size;
new_first_block->size_and_flag = new_first_block_size | HEAP_PREV_BLOCK_USED;
a000f658: e3833001 orr r3, r3, #1 <== NOT EXECUTED
a000f65c: e5053004 str r3, [r5, #-4] <== NOT EXECUTED
_Heap_Free_block( heap, new_first_block );
a000f660: e1a00004 mov r0, r4 <== NOT EXECUTED
a000f664: ebffff86 bl a000f484 <_Heap_Free_block> <== NOT EXECUTED
a000f668: ea000004 b a000f680 <_Heap_Extend+0x1dc> <== NOT EXECUTED
heap->last_block = extend_last_block;
}
if ( merge_below_block != NULL ) {
_Heap_Merge_below( heap, extend_area_begin, merge_below_block );
} else if ( link_below_block != NULL ) {
a000f66c: e3520000 cmp r2, #0
_Heap_Link_below(
a000f670: 159d3020 ldrne r3, [sp, #32]
{
uintptr_t const last_block_begin = (uintptr_t) last_block;
uintptr_t const link_begin = (uintptr_t) link;
last_block->size_and_flag =
(link_begin - last_block_begin) | HEAP_PREV_BLOCK_USED;
a000f674: 10632002 rsbne r2, r3, r2
a000f678: 13822001 orrne r2, r2, #1
)
{
uintptr_t const last_block_begin = (uintptr_t) last_block;
uintptr_t const link_begin = (uintptr_t) link;
last_block->size_and_flag =
a000f67c: 15832004 strne r2, [r3, #4]
link_below_block,
extend_last_block
);
}
if ( merge_above_block != NULL ) {
a000f680: e3570000 cmp r7, #0
a000f684: 0a000012 beq a000f6d4 <_Heap_Extend+0x230>
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const last_block_begin = (uintptr_t) last_block;
uintptr_t const last_block_new_size = _Heap_Align_down(
extend_area_end - last_block_begin - HEAP_BLOCK_HEADER_SIZE,
a000f688: e2466008 sub r6, r6, #8 <== NOT EXECUTED
uintptr_t extend_area_end
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const last_block_begin = (uintptr_t) last_block;
uintptr_t const last_block_new_size = _Heap_Align_down(
a000f68c: e0676006 rsb r6, r7, r6 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
a000f690: e5941010 ldr r1, [r4, #16] <== NOT EXECUTED
a000f694: e1a00006 mov r0, r6 <== NOT EXECUTED
a000f698: eb001641 bl a0014fa4 <__umodsi3> <== NOT EXECUTED
);
Heap_Block *const new_last_block =
_Heap_Block_at( last_block, last_block_new_size );
new_last_block->size_and_flag =
(last_block->size_and_flag - last_block_new_size)
a000f69c: e5972004 ldr r2, [r7, #4] <== NOT EXECUTED
a000f6a0: e0606006 rsb r6, r0, r6 <== NOT EXECUTED
page_size
);
Heap_Block *const new_last_block =
_Heap_Block_at( last_block, last_block_new_size );
new_last_block->size_and_flag =
a000f6a4: e0863007 add r3, r6, r7 <== NOT EXECUTED
(last_block->size_and_flag - last_block_new_size)
a000f6a8: e0662002 rsb r2, r6, r2 <== NOT EXECUTED
| HEAP_PREV_BLOCK_USED;
a000f6ac: e3822001 orr r2, r2, #1 <== NOT EXECUTED
page_size
);
Heap_Block *const new_last_block =
_Heap_Block_at( last_block, last_block_new_size );
new_last_block->size_and_flag =
a000f6b0: e5832004 str r2, [r3, #4] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(
Heap_Block *block,
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000f6b4: e5973004 ldr r3, [r7, #4] <== NOT EXECUTED
(last_block->size_and_flag - last_block_new_size)
| HEAP_PREV_BLOCK_USED;
_Heap_Block_set_size( last_block, last_block_new_size );
_Heap_Free_block( heap, last_block );
a000f6b8: e1a00004 mov r0, r4 <== NOT EXECUTED
a000f6bc: e1a01007 mov r1, r7 <== NOT EXECUTED
a000f6c0: e2033001 and r3, r3, #1 <== NOT EXECUTED
block->size_and_flag = size | flag;
a000f6c4: e1866003 orr r6, r6, r3 <== NOT EXECUTED
a000f6c8: e5876004 str r6, [r7, #4] <== NOT EXECUTED
a000f6cc: ebffff6c bl a000f484 <_Heap_Free_block> <== NOT EXECUTED
a000f6d0: ea00000b b a000f704 <_Heap_Extend+0x260> <== NOT EXECUTED
);
}
if ( merge_above_block != NULL ) {
_Heap_Merge_above( heap, merge_above_block, extend_area_end );
} else if ( link_above_block != NULL ) {
a000f6d4: e3580000 cmp r8, #0
a000f6d8: 0a000009 beq a000f704 <_Heap_Extend+0x260>
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(
Heap_Block *block,
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000f6dc: e5982004 ldr r2, [r8, #4] <== NOT EXECUTED
)
{
uintptr_t const link_begin = (uintptr_t) link;
uintptr_t const first_block_begin = (uintptr_t) first_block;
_Heap_Block_set_size( link, first_block_begin - link_begin );
a000f6e0: e59d1024 ldr r1, [sp, #36] ; 0x24 <== NOT EXECUTED
}
if ( merge_above_block != NULL ) {
_Heap_Merge_above( heap, merge_above_block, extend_area_end );
} else if ( link_above_block != NULL ) {
_Heap_Link_above(
a000f6e4: e59d3020 ldr r3, [sp, #32] <== NOT EXECUTED
a000f6e8: e2022001 and r2, r2, #1 <== NOT EXECUTED
)
{
uintptr_t const link_begin = (uintptr_t) link;
uintptr_t const first_block_begin = (uintptr_t) first_block;
_Heap_Block_set_size( link, first_block_begin - link_begin );
a000f6ec: e0681001 rsb r1, r8, r1 <== NOT EXECUTED
block->size_and_flag = size | flag;
a000f6f0: e1812002 orr r2, r1, r2 <== NOT EXECUTED
a000f6f4: e5882004 str r2, [r8, #4] <== NOT EXECUTED
last_block->size_and_flag |= HEAP_PREV_BLOCK_USED;
a000f6f8: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED
a000f6fc: e3822001 orr r2, r2, #1 <== NOT EXECUTED
a000f700: e5832004 str r2, [r3, #4] <== NOT EXECUTED
extend_first_block,
extend_last_block
);
}
if ( merge_below_block == NULL && merge_above_block == NULL ) {
a000f704: e3570000 cmp r7, #0
a000f708: 03590000 cmpeq r9, #0
a000f70c: 1a000002 bne a000f71c <_Heap_Extend+0x278>
_Heap_Free_block( heap, extend_first_block );
a000f710: e1a00004 mov r0, r4
a000f714: e59d1024 ldr r1, [sp, #36] ; 0x24
a000f718: ebffff59 bl a000f484 <_Heap_Free_block>
*/
RTEMS_INLINE_ROUTINE void _Heap_Set_last_block_size( Heap_Control *heap )
{
_Heap_Block_set_size(
heap->last_block,
(uintptr_t) heap->first_block - (uintptr_t) heap->last_block
a000f71c: e5943024 ldr r3, [r4, #36] ; 0x24
* This feature will be used to terminate the scattered heap area list. See
* also _Heap_Extend().
*/
RTEMS_INLINE_ROUTINE void _Heap_Set_last_block_size( Heap_Control *heap )
{
_Heap_Block_set_size(
a000f720: e5941020 ldr r1, [r4, #32]
stats->size += extended_size;
if ( extended_size_ptr != NULL )
*extended_size_ptr = extended_size;
return true;
a000f724: e3a00001 mov r0, #1
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(
Heap_Block *block,
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000f728: e5932004 ldr r2, [r3, #4]
* This feature will be used to terminate the scattered heap area list. See
* also _Heap_Extend().
*/
RTEMS_INLINE_ROUTINE void _Heap_Set_last_block_size( Heap_Control *heap )
{
_Heap_Block_set_size(
a000f72c: e0631001 rsb r1, r3, r1
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(
Heap_Block *block,
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000f730: e2022001 and r2, r2, #1
block->size_and_flag = size | flag;
a000f734: e1812002 orr r2, r1, r2
a000f738: e5832004 str r2, [r3, #4]
_Heap_Free_block( heap, extend_first_block );
}
_Heap_Set_last_block_size( heap );
extended_size = stats->free_size - free_size;
a000f73c: e59d101c ldr r1, [sp, #28]
a000f740: e5943030 ldr r3, [r4, #48] ; 0x30
/* Statistics */
stats->size += extended_size;
a000f744: e594202c ldr r2, [r4, #44] ; 0x2c
_Heap_Free_block( heap, extend_first_block );
}
_Heap_Set_last_block_size( heap );
extended_size = stats->free_size - free_size;
a000f748: e0613003 rsb r3, r1, r3
/* Statistics */
stats->size += extended_size;
a000f74c: e0822003 add r2, r2, r3
a000f750: e584202c str r2, [r4, #44] ; 0x2c
if ( extended_size_ptr != NULL )
a000f754: e59d2018 ldr r2, [sp, #24]
a000f758: e3520000 cmp r2, #0
*extended_size_ptr = extended_size;
a000f75c: 15823000 strne r3, [r2]
a000f760: ea000000 b a000f768 <_Heap_Extend+0x2c4>
_Heap_Block_of_alloc_area( sub_area_end, page_size );
if (
sub_area_end > extend_area_begin && extend_area_end > sub_area_begin
) {
return false;
a000f764: e3a00000 mov r0, #0 <== NOT EXECUTED
if ( extended_size_ptr != NULL )
*extended_size_ptr = extended_size;
return true;
}
a000f768: e28dd028 add sp, sp, #40 ; 0x28
a000f76c: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
a0016504 <_Heap_Resize_block>:
void *alloc_begin_ptr,
uintptr_t new_alloc_size,
uintptr_t *old_size,
uintptr_t *new_size
)
{
a0016504: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr}
a0016508: e1a04000 mov r4, r0
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
a001650c: e241a008 sub sl, r1, #8
a0016510: e1a00001 mov r0, r1
a0016514: e1a05001 mov r5, r1
a0016518: e5941010 ldr r1, [r4, #16]
a001651c: e1a08003 mov r8, r3
a0016520: e1a07002 mov r7, r2
a0016524: ebfff948 bl a0014a4c <__umodsi3>
a0016528: e59d601c ldr r6, [sp, #28]
uintptr_t const alloc_begin = (uintptr_t) alloc_begin_ptr;
Heap_Block *const block = _Heap_Block_of_alloc_area( alloc_begin, page_size );
*old_size = 0;
a001652c: e3a03000 mov r3, #0
a0016530: e5883000 str r3, [r8]
*new_size = 0;
a0016534: e5863000 str r3, [r6]
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
a0016538: e5943020 ldr r3, [r4, #32]
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
- HEAP_BLOCK_HEADER_SIZE);
a001653c: e060100a rsb r1, r0, sl
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
a0016540: e1530001 cmp r3, r1
a0016544: 8a000039 bhi a0016630 <_Heap_Resize_block+0x12c>
a0016548: e5943024 ldr r3, [r4, #36] ; 0x24
a001654c: e1530001 cmp r3, r1
a0016550: 3a000038 bcc a0016638 <_Heap_Resize_block+0x134>
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a0016554: e5913004 ldr r3, [r1, #4]
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t block_size = _Heap_Block_size( block );
uintptr_t block_end = block_begin + block_size;
uintptr_t alloc_size = block_end - alloc_begin + HEAP_ALLOC_BONUS;
a0016558: e265c004 rsb ip, r5, #4
a001655c: e3c33001 bic r3, r3, #1
{
Heap_Statistics *const stats = &heap->stats;
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t block_size = _Heap_Block_size( block );
uintptr_t block_end = block_begin + block_size;
a0016560: e0812003 add r2, r1, r3
a0016564: e5920004 ldr r0, [r2, #4]
uintptr_t alloc_size = block_end - alloc_begin + HEAP_ALLOC_BONUS;
a0016568: e08cc002 add ip, ip, r2
a001656c: e3c00001 bic r0, r0, #1
new_size
);
} else {
return HEAP_RESIZE_FATAL_ERROR;
}
}
a0016570: e082a000 add sl, r2, r0
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
a0016574: e59aa004 ldr sl, [sl, #4]
bool next_block_is_free = _Heap_Is_free( next_block );;
_HAssert( _Heap_Is_block_in_heap( heap, next_block ) );
_HAssert( _Heap_Is_prev_used( next_block ) );
*old_size = alloc_size;
a0016578: e588c000 str ip, [r8]
RTEMS_INLINE_ROUTINE bool _Heap_Is_free(
const Heap_Block *block
)
{
return !_Heap_Is_used( block );
a001657c: e31a0001 tst sl, #1
a0016580: 13a0a000 movne sl, #0
a0016584: 03a0a001 moveq sl, #1
if ( next_block_is_free ) {
a0016588: e35a0000 cmp sl, #0
block_size += next_block_size;
alloc_size += next_block_size;
a001658c: 108cc000 addne ip, ip, r0
_HAssert( _Heap_Is_prev_used( next_block ) );
*old_size = alloc_size;
if ( next_block_is_free ) {
block_size += next_block_size;
a0016590: 10833000 addne r3, r3, r0
alloc_size += next_block_size;
}
if ( new_alloc_size > alloc_size ) {
a0016594: e157000c cmp r7, ip
a0016598: 8a000022 bhi a0016628 <_Heap_Resize_block+0x124>
return HEAP_RESIZE_UNSATISFIED;
}
if ( next_block_is_free ) {
a001659c: e35a0000 cmp sl, #0
a00165a0: 0a000011 beq a00165ec <_Heap_Resize_block+0xe8>
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(
Heap_Block *block,
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
a00165a4: e591c004 ldr ip, [r1, #4] <== NOT EXECUTED
a00165a8: e20cc001 and ip, ip, #1 <== NOT EXECUTED
block->size_and_flag = size | flag;
a00165ac: e183c00c orr ip, r3, ip <== NOT EXECUTED
a00165b0: e581c004 str ip, [r1, #4] <== NOT EXECUTED
return _Heap_Free_list_tail(heap)->prev;
}
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
a00165b4: e592c008 ldr ip, [r2, #8] <== NOT EXECUTED
Heap_Block *prev = block->prev;
a00165b8: e592200c ldr r2, [r2, #12] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a00165bc: e0833001 add r3, r3, r1 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
Heap_Block *prev = block->prev;
prev->next = next;
a00165c0: e582c008 str ip, [r2, #8] <== NOT EXECUTED
next->prev = prev;
a00165c4: e58c200c str r2, [ip, #12] <== NOT EXECUTED
_Heap_Block_set_size( block, block_size );
_Heap_Free_list_remove( next_block );
next_block = _Heap_Block_at( block, block_size );
next_block->size_and_flag |= HEAP_PREV_BLOCK_USED;
a00165c8: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED
a00165cc: e3822001 orr r2, r2, #1 <== NOT EXECUTED
a00165d0: e5832004 str r2, [r3, #4] <== NOT EXECUTED
/* Statistics */
--stats->free_blocks;
a00165d4: e5943038 ldr r3, [r4, #56] ; 0x38 <== NOT EXECUTED
a00165d8: e2433001 sub r3, r3, #1 <== NOT EXECUTED
a00165dc: e5843038 str r3, [r4, #56] ; 0x38 <== NOT EXECUTED
stats->free_size -= next_block_size;
a00165e0: e5943030 ldr r3, [r4, #48] ; 0x30 <== NOT EXECUTED
a00165e4: e0600003 rsb r0, r0, r3 <== NOT EXECUTED
a00165e8: e5840030 str r0, [r4, #48] ; 0x30 <== NOT EXECUTED
}
block = _Heap_Block_allocate( heap, block, alloc_begin, new_alloc_size );
a00165ec: e1a02005 mov r2, r5
a00165f0: e1a03007 mov r3, r7
a00165f4: e1a00004 mov r0, r4
a00165f8: ebffcfc7 bl a000a51c <_Heap_Block_allocate>
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a00165fc: e5903004 ldr r3, [r0, #4]
a0016600: e3c33001 bic r3, r3, #1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a0016604: e2833004 add r3, r3, #4
block_size = _Heap_Block_size( block );
next_block = _Heap_Block_at( block, block_size );
*new_size = (uintptr_t) next_block - alloc_begin + HEAP_ALLOC_BONUS;
a0016608: e0655003 rsb r5, r5, r3
a001660c: e0800005 add r0, r0, r5
a0016610: e5860000 str r0, [r6]
/* Statistics */
++stats->resizes;
a0016614: e5943054 ldr r3, [r4, #84] ; 0x54
return HEAP_RESIZE_SUCCESSFUL;
a0016618: e3a00000 mov r0, #0
block_size = _Heap_Block_size( block );
next_block = _Heap_Block_at( block, block_size );
*new_size = (uintptr_t) next_block - alloc_begin + HEAP_ALLOC_BONUS;
/* Statistics */
++stats->resizes;
a001661c: e2833001 add r3, r3, #1
a0016620: e5843054 str r3, [r4, #84] ; 0x54
a0016624: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
block_size += next_block_size;
alloc_size += next_block_size;
}
if ( new_alloc_size > alloc_size ) {
return HEAP_RESIZE_UNSATISFIED;
a0016628: e3a00001 mov r0, #1
*new_size = 0;
_Heap_Protection_block_check( heap, block );
if ( _Heap_Is_block_in_heap( heap, block ) ) {
return _Heap_Resize_block_checked(
a001662c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
new_alloc_size,
old_size,
new_size
);
} else {
return HEAP_RESIZE_FATAL_ERROR;
a0016630: e3a00002 mov r0, #2 <== NOT EXECUTED
a0016634: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
a0016638: e3a00002 mov r0, #2 <== NOT EXECUTED
}
}
a001663c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
a000b228 <_Heap_Walk>:
bool _Heap_Walk(
Heap_Control *heap,
int source,
bool dump
)
{
a000b228: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
a000b22c: e5903014 ldr r3, [r0, #20]
bool _Heap_Walk(
Heap_Control *heap,
int source,
bool dump
)
{
a000b230: e24dd030 sub sp, sp, #48 ; 0x30
uintptr_t const min_block_size = heap->min_block_size;
Heap_Block *const first_block = heap->first_block;
Heap_Block *const last_block = heap->last_block;
Heap_Block *block = first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
a000b234: e59f44c8 ldr r4, [pc, #1224] ; a000b704 <_Heap_Walk+0x4dc>
int source,
bool dump
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
a000b238: e58d3024 str r3, [sp, #36] ; 0x24
Heap_Block *const first_block = heap->first_block;
Heap_Block *const last_block = heap->last_block;
a000b23c: e5903024 ldr r3, [r0, #36] ; 0x24
Heap_Block *block = first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
a000b240: e31200ff tst r2, #255 ; 0xff
bool dump
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
Heap_Block *const first_block = heap->first_block;
a000b244: e590c020 ldr ip, [r0, #32]
Heap_Block *const last_block = heap->last_block;
a000b248: e58d3028 str r3, [sp, #40] ; 0x28
Heap_Block *block = first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
a000b24c: e59f34b4 ldr r3, [pc, #1204] ; a000b708 <_Heap_Walk+0x4e0>
bool _Heap_Walk(
Heap_Control *heap,
int source,
bool dump
)
{
a000b250: e1a06000 mov r6, r0
a000b254: e1a05001 mov r5, r1
uintptr_t const min_block_size = heap->min_block_size;
Heap_Block *const first_block = heap->first_block;
Heap_Block *const last_block = heap->last_block;
Heap_Block *block = first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
a000b258: 11a04003 movne r4, r3
if ( !_System_state_Is_up( _System_state_Get() ) ) {
a000b25c: e59f34a8 ldr r3, [pc, #1192] ; a000b70c <_Heap_Walk+0x4e4>
Heap_Control *heap,
int source,
bool dump
)
{
uintptr_t const page_size = heap->page_size;
a000b260: e5909010 ldr r9, [r0, #16]
uintptr_t const min_block_size = heap->min_block_size;
Heap_Block *const first_block = heap->first_block;
a000b264: e58dc020 str ip, [sp, #32]
Heap_Block *const last_block = heap->last_block;
Heap_Block *block = first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
if ( !_System_state_Is_up( _System_state_Get() ) ) {
a000b268: e5933000 ldr r3, [r3]
a000b26c: e3530003 cmp r3, #3
a000b270: 1a000118 bne a000b6d8 <_Heap_Walk+0x4b0>
Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
Heap_Block *const first_block = heap->first_block;
Heap_Block *const last_block = heap->last_block;
(*printer)(
a000b274: e59dc024 ldr ip, [sp, #36] ; 0x24
a000b278: e59d2020 ldr r2, [sp, #32]
a000b27c: e58dc000 str ip, [sp]
a000b280: e5903018 ldr r3, [r0, #24]
a000b284: e58d3004 str r3, [sp, #4]
a000b288: e590301c ldr r3, [r0, #28]
a000b28c: e58d200c str r2, [sp, #12]
a000b290: e59f2478 ldr r2, [pc, #1144] ; a000b710 <_Heap_Walk+0x4e8>
a000b294: e58d3008 str r3, [sp, #8]
a000b298: e59d3028 ldr r3, [sp, #40] ; 0x28
a000b29c: e58d3010 str r3, [sp, #16]
a000b2a0: e5903008 ldr r3, [r0, #8]
a000b2a4: e58d3014 str r3, [sp, #20]
a000b2a8: e590300c ldr r3, [r0, #12]
a000b2ac: e1a00001 mov r0, r1
a000b2b0: e3a01000 mov r1, #0
a000b2b4: e58d3018 str r3, [sp, #24]
a000b2b8: e1a03009 mov r3, r9
a000b2bc: e12fff34 blx r4
heap->area_begin, heap->area_end,
first_block, last_block,
first_free_block, last_free_block
);
if ( page_size == 0 ) {
a000b2c0: e3590000 cmp r9, #0
a000b2c4: 1a000005 bne a000b2e0 <_Heap_Walk+0xb8>
(*printer)( source, true, "page size is zero\n" );
a000b2c8: e1a00005 mov r0, r5
a000b2cc: e3a01001 mov r1, #1
a000b2d0: e59f243c ldr r2, [pc, #1084] ; a000b714 <_Heap_Walk+0x4ec>
a000b2d4: e12fff34 blx r4
if ( !_System_state_Is_up( _System_state_Get() ) ) {
return true;
}
if ( !_Heap_Walk_check_control( source, printer, heap ) ) {
return false;
a000b2d8: e1a08009 mov r8, r9
a000b2dc: ea0000fe b a000b6dc <_Heap_Walk+0x4b4>
(*printer)( source, true, "page size is zero\n" );
return false;
}
if ( !_Addresses_Is_aligned( (void *) page_size ) ) {
a000b2e0: e2198007 ands r8, r9, #7
(*printer)(
a000b2e4: 11a00005 movne r0, r5
a000b2e8: 13a01001 movne r1, #1
a000b2ec: 159f2424 ldrne r2, [pc, #1060] ; a000b718 <_Heap_Walk+0x4f0>
a000b2f0: 11a03009 movne r3, r9
a000b2f4: 1a0000ff bne a000b6f8 <_Heap_Walk+0x4d0>
RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned(
uintptr_t value,
uintptr_t alignment
)
{
return (value % alignment) == 0;
a000b2f8: e59d0024 ldr r0, [sp, #36] ; 0x24
a000b2fc: e1a01009 mov r1, r9
a000b300: ebffe743 bl a0005014 <__umodsi3>
);
return false;
}
if ( !_Heap_Is_aligned( min_block_size, page_size ) ) {
a000b304: e250b000 subs fp, r0, #0
a000b308: 0a000005 beq a000b324 <_Heap_Walk+0xfc>
(*printer)(
a000b30c: e1a00005 mov r0, r5
a000b310: e3a01001 mov r1, #1
a000b314: e59f2400 ldr r2, [pc, #1024] ; a000b71c <_Heap_Walk+0x4f4>
a000b318: e59d3024 ldr r3, [sp, #36] ; 0x24
a000b31c: e12fff34 blx r4
a000b320: ea0000ed b a000b6dc <_Heap_Walk+0x4b4>
a000b324: e59dc020 ldr ip, [sp, #32]
a000b328: e1a01009 mov r1, r9
a000b32c: e28c0008 add r0, ip, #8
a000b330: ebffe737 bl a0005014 <__umodsi3>
);
return false;
}
if (
a000b334: e250a000 subs sl, r0, #0
!_Heap_Is_aligned( _Heap_Alloc_area_of_block( first_block ), page_size )
) {
(*printer)(
a000b338: 11a00005 movne r0, r5
a000b33c: 13a01001 movne r1, #1
a000b340: 159f23d8 ldrne r2, [pc, #984] ; a000b720 <_Heap_Walk+0x4f8>
a000b344: 159d3020 ldrne r3, [sp, #32]
a000b348: 1a0000c3 bne a000b65c <_Heap_Walk+0x434>
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000b34c: e59d2020 ldr r2, [sp, #32]
a000b350: e5928004 ldr r8, [r2, #4]
);
return false;
}
if ( !_Heap_Is_prev_used( first_block ) ) {
a000b354: e2188001 ands r8, r8, #1
(*printer)(
a000b358: 01a00005 moveq r0, r5
a000b35c: 03a01001 moveq r1, #1
a000b360: 059f23bc ldreq r2, [pc, #956] ; a000b724 <_Heap_Walk+0x4fc>
a000b364: 0a000009 beq a000b390 <_Heap_Walk+0x168>
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000b368: e59d3028 ldr r3, [sp, #40] ; 0x28
a000b36c: e5937004 ldr r7, [r3, #4]
a000b370: e3c77001 bic r7, r7, #1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a000b374: e0837007 add r7, r3, r7
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000b378: e5978004 ldr r8, [r7, #4]
);
return false;
}
if ( _Heap_Is_free( last_block ) ) {
a000b37c: e2188001 ands r8, r8, #1
a000b380: 1a000004 bne a000b398 <_Heap_Walk+0x170>
(*printer)(
a000b384: e59f239c ldr r2, [pc, #924] ; a000b728 <_Heap_Walk+0x500> <== NOT EXECUTED
a000b388: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b38c: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b390: e12fff34 blx r4 <== NOT EXECUTED
a000b394: ea0000d0 b a000b6dc <_Heap_Walk+0x4b4> <== NOT EXECUTED
);
return false;
}
if (
a000b398: e59dc020 ldr ip, [sp, #32]
a000b39c: e157000c cmp r7, ip
a000b3a0: 0a000005 beq a000b3bc <_Heap_Walk+0x194>
_Heap_Block_at( last_block, _Heap_Block_size( last_block ) ) != first_block
) {
(*printer)(
a000b3a4: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b3a8: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b3ac: e59f2378 ldr r2, [pc, #888] ; a000b72c <_Heap_Walk+0x504> <== NOT EXECUTED
a000b3b0: e12fff34 blx r4 <== NOT EXECUTED
if ( !_System_state_Is_up( _System_state_Get() ) ) {
return true;
}
if ( !_Heap_Walk_check_control( source, printer, heap ) ) {
return false;
a000b3b4: e1a0800a mov r8, sl <== NOT EXECUTED
a000b3b8: ea0000c7 b a000b6dc <_Heap_Walk+0x4b4> <== NOT EXECUTED
int source,
Heap_Walk_printer printer,
Heap_Control *heap
)
{
uintptr_t const page_size = heap->page_size;
a000b3bc: e596b010 ldr fp, [r6, #16]
block = next_block;
} while ( block != first_block );
return true;
}
a000b3c0: e5968008 ldr r8, [r6, #8]
Heap_Walk_printer printer,
Heap_Control *heap
)
{
uintptr_t const page_size = heap->page_size;
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
a000b3c4: e1a0a006 mov sl, r6
a000b3c8: ea000032 b a000b498 <_Heap_Walk+0x270>
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
a000b3cc: e5963020 ldr r3, [r6, #32]
a000b3d0: e1530008 cmp r3, r8
a000b3d4: 83a0c000 movhi ip, #0
a000b3d8: 8a000003 bhi a000b3ec <_Heap_Walk+0x1c4>
a000b3dc: e596c024 ldr ip, [r6, #36] ; 0x24
a000b3e0: e15c0008 cmp ip, r8
a000b3e4: 33a0c000 movcc ip, #0
a000b3e8: 23a0c001 movcs ip, #1
const Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
const Heap_Block *prev_block = free_list_tail;
const Heap_Block *free_block = first_free_block;
while ( free_block != free_list_tail ) {
if ( !_Heap_Is_block_in_heap( heap, free_block ) ) {
a000b3ec: e21cc0ff ands ip, ip, #255 ; 0xff
(*printer)(
a000b3f0: 01a00005 moveq r0, r5
a000b3f4: 03a01001 moveq r1, #1
a000b3f8: 059f2330 ldreq r2, [pc, #816] ; a000b730 <_Heap_Walk+0x508>
a000b3fc: 0a000012 beq a000b44c <_Heap_Walk+0x224>
RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned(
uintptr_t value,
uintptr_t alignment
)
{
return (value % alignment) == 0;
a000b400: e2880008 add r0, r8, #8
a000b404: e1a0100b mov r1, fp
a000b408: ebffe701 bl a0005014 <__umodsi3>
);
return false;
}
if (
a000b40c: e250c000 subs ip, r0, #0
!_Heap_Is_aligned( _Heap_Alloc_area_of_block( free_block ), page_size )
) {
(*printer)(
a000b410: 11a00005 movne r0, r5
a000b414: 13a01001 movne r1, #1
a000b418: 159f2314 ldrne r2, [pc, #788] ; a000b734 <_Heap_Walk+0x50c>
a000b41c: 11a03008 movne r3, r8
a000b420: 1a0000b4 bne a000b6f8 <_Heap_Walk+0x4d0>
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000b424: e5983004 ldr r3, [r8, #4]
a000b428: e3c33001 bic r3, r3, #1
block = next_block;
} while ( block != first_block );
return true;
}
a000b42c: e0883003 add r3, r8, r3
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000b430: e5933004 ldr r3, [r3, #4]
);
return false;
}
if ( _Heap_Is_used( free_block ) ) {
a000b434: e2133001 ands r3, r3, #1
a000b438: e58d302c str r3, [sp, #44] ; 0x2c
a000b43c: 0a000008 beq a000b464 <_Heap_Walk+0x23c>
(*printer)(
a000b440: e59f22f0 ldr r2, [pc, #752] ; a000b738 <_Heap_Walk+0x510> <== NOT EXECUTED
a000b444: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b448: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b44c: e1a03008 mov r3, r8 <== NOT EXECUTED
a000b450: e58dc01c str ip, [sp, #28] <== NOT EXECUTED
a000b454: e12fff34 blx r4 <== NOT EXECUTED
if ( !_System_state_Is_up( _System_state_Get() ) ) {
return true;
}
if ( !_Heap_Walk_check_control( source, printer, heap ) ) {
return false;
a000b458: e59dc01c ldr ip, [sp, #28] <== NOT EXECUTED
a000b45c: e1a0800c mov r8, ip <== NOT EXECUTED
a000b460: ea00009d b a000b6dc <_Heap_Walk+0x4b4> <== NOT EXECUTED
);
return false;
}
if ( free_block->prev != prev_block ) {
a000b464: e598300c ldr r3, [r8, #12]
a000b468: e153000a cmp r3, sl
a000b46c: 0a000007 beq a000b490 <_Heap_Walk+0x268>
(*printer)(
a000b470: e58d3000 str r3, [sp] <== NOT EXECUTED
a000b474: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b478: e1a03008 mov r3, r8 <== NOT EXECUTED
a000b47c: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b480: e59f22b4 ldr r2, [pc, #692] ; a000b73c <_Heap_Walk+0x514> <== NOT EXECUTED
a000b484: e12fff34 blx r4 <== NOT EXECUTED
if ( !_System_state_Is_up( _System_state_Get() ) ) {
return true;
}
if ( !_Heap_Walk_check_control( source, printer, heap ) ) {
return false;
a000b488: e59d802c ldr r8, [sp, #44] ; 0x2c <== NOT EXECUTED
a000b48c: ea000092 b a000b6dc <_Heap_Walk+0x4b4> <== NOT EXECUTED
return false;
}
prev_block = free_block;
free_block = free_block->next;
a000b490: e1a0a008 mov sl, r8
a000b494: e5988008 ldr r8, [r8, #8]
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
const Heap_Block *prev_block = free_list_tail;
const Heap_Block *free_block = first_free_block;
while ( free_block != free_list_tail ) {
a000b498: e1580006 cmp r8, r6
a000b49c: 1affffca bne a000b3cc <_Heap_Walk+0x1a4>
a000b4a0: ea000000 b a000b4a8 <_Heap_Walk+0x280>
block->prev_size
);
}
block = next_block;
} while ( block != first_block );
a000b4a4: e1a07008 mov r7, r8
return true;
}
a000b4a8: e5973004 ldr r3, [r7, #4]
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
a000b4ac: e5962020 ldr r2, [r6, #32]
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
a000b4b0: e3c3a001 bic sl, r3, #1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
a000b4b4: e087800a add r8, r7, sl
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
a000b4b8: e1520008 cmp r2, r8
a000b4bc: 83a0b000 movhi fp, #0
a000b4c0: 8a000003 bhi a000b4d4 <_Heap_Walk+0x2ac>
a000b4c4: e596b024 ldr fp, [r6, #36] ; 0x24
a000b4c8: e15b0008 cmp fp, r8
a000b4cc: 33a0b000 movcc fp, #0
a000b4d0: 23a0b001 movcs fp, #1
bool const prev_used = _Heap_Is_prev_used( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
uintptr_t const next_block_begin = (uintptr_t) next_block;
bool const is_not_last_block = block != last_block;
if ( !_Heap_Is_block_in_heap( heap, next_block ) ) {
a000b4d4: e21bb0ff ands fp, fp, #255 ; 0xff
a000b4d8: 1a000006 bne a000b4f8 <_Heap_Walk+0x2d0>
(*printer)(
a000b4dc: e58d8000 str r8, [sp] <== NOT EXECUTED
a000b4e0: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b4e4: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b4e8: e59f2250 ldr r2, [pc, #592] ; a000b740 <_Heap_Walk+0x518> <== NOT EXECUTED
a000b4ec: e1a03007 mov r3, r7 <== NOT EXECUTED
a000b4f0: e12fff34 blx r4 <== NOT EXECUTED
a000b4f4: ea000059 b a000b660 <_Heap_Walk+0x438> <== NOT EXECUTED
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t const block_size = _Heap_Block_size( block );
bool const prev_used = _Heap_Is_prev_used( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
uintptr_t const next_block_begin = (uintptr_t) next_block;
bool const is_not_last_block = block != last_block;
a000b4f8: e59d2028 ldr r2, [sp, #40] ; 0x28
RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned(
uintptr_t value,
uintptr_t alignment
)
{
return (value % alignment) == 0;
a000b4fc: e1a0000a mov r0, sl
a000b500: e1a01009 mov r1, r9
a000b504: e057b002 subs fp, r7, r2
a000b508: 13a0b001 movne fp, #1
a000b50c: e58d301c str r3, [sp, #28]
a000b510: ebffe6bf bl a0005014 <__umodsi3>
);
return false;
}
if ( !_Heap_Is_aligned( block_size, page_size ) && is_not_last_block ) {
a000b514: e3500000 cmp r0, #0
a000b518: e59d301c ldr r3, [sp, #28]
a000b51c: 0a000005 beq a000b538 <_Heap_Walk+0x310>
a000b520: e35b0000 cmp fp, #0 <== NOT EXECUTED
(*printer)(
a000b524: 158da000 strne sl, [sp] <== NOT EXECUTED
a000b528: 11a00005 movne r0, r5 <== NOT EXECUTED
a000b52c: 13a01001 movne r1, #1 <== NOT EXECUTED
a000b530: 159f220c ldrne r2, [pc, #524] ; a000b744 <_Heap_Walk+0x51c><== NOT EXECUTED
a000b534: 1a000013 bne a000b588 <_Heap_Walk+0x360> <== NOT EXECUTED
);
return false;
}
if ( block_size < min_block_size && is_not_last_block ) {
a000b538: e59dc024 ldr ip, [sp, #36] ; 0x24
a000b53c: e15a000c cmp sl, ip
a000b540: 2a000008 bcs a000b568 <_Heap_Walk+0x340>
a000b544: e35b0000 cmp fp, #0 <== NOT EXECUTED
a000b548: 0a000006 beq a000b568 <_Heap_Walk+0x340> <== NOT EXECUTED
(*printer)(
a000b54c: e88d1400 stm sp, {sl, ip} <== NOT EXECUTED
a000b550: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b554: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b558: e59f21e8 ldr r2, [pc, #488] ; a000b748 <_Heap_Walk+0x520> <== NOT EXECUTED
a000b55c: e1a03007 mov r3, r7 <== NOT EXECUTED
a000b560: e12fff34 blx r4 <== NOT EXECUTED
a000b564: ea000064 b a000b6fc <_Heap_Walk+0x4d4> <== NOT EXECUTED
);
return false;
}
if ( next_block_begin <= block_begin && is_not_last_block ) {
a000b568: e1580007 cmp r8, r7
a000b56c: 8a000008 bhi a000b594 <_Heap_Walk+0x36c>
a000b570: e35b0000 cmp fp, #0
a000b574: 0a000006 beq a000b594 <_Heap_Walk+0x36c>
(*printer)(
a000b578: e59f21cc ldr r2, [pc, #460] ; a000b74c <_Heap_Walk+0x524> <== NOT EXECUTED
a000b57c: e58d8000 str r8, [sp] <== NOT EXECUTED
a000b580: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b584: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b588: e1a03007 mov r3, r7 <== NOT EXECUTED
a000b58c: e12fff34 blx r4 <== NOT EXECUTED
a000b590: ea000059 b a000b6fc <_Heap_Walk+0x4d4> <== NOT EXECUTED
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
a000b594: e203b001 and fp, r3, #1
a000b598: e5983004 ldr r3, [r8, #4]
);
return false;
}
if ( !_Heap_Is_prev_used( next_block ) ) {
a000b59c: e3130001 tst r3, #1
a000b5a0: 1a000038 bne a000b688 <_Heap_Walk+0x460>
false,
"block 0x%08x: size %u, prev 0x%08x%s, next 0x%08x%s\n",
block,
block_size,
block->prev,
block->prev == first_free_block ?
a000b5a4: e597200c ldr r2, [r7, #12]
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
a000b5a8: e5963008 ldr r3, [r6, #8]
block = next_block;
} while ( block != first_block );
return true;
}
a000b5ac: e596100c ldr r1, [r6, #12]
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
a000b5b0: e1520003 cmp r2, r3
a000b5b4: 059f0194 ldreq r0, [pc, #404] ; a000b750 <_Heap_Walk+0x528>
a000b5b8: 0a000003 beq a000b5cc <_Heap_Walk+0x3a4>
block,
block_size,
block->prev,
block->prev == first_free_block ?
" (= first free)"
: (block->prev == free_list_head ? " (= head)" : ""),
a000b5bc: e59f3190 ldr r3, [pc, #400] ; a000b754 <_Heap_Walk+0x52c>
a000b5c0: e1520006 cmp r2, r6
a000b5c4: e59f018c ldr r0, [pc, #396] ; a000b758 <_Heap_Walk+0x530>
a000b5c8: 01a00003 moveq r0, r3
block->next,
block->next == last_free_block ?
a000b5cc: e5973008 ldr r3, [r7, #8]
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
a000b5d0: e1530001 cmp r3, r1
a000b5d4: 059f1180 ldreq r1, [pc, #384] ; a000b75c <_Heap_Walk+0x534>
a000b5d8: 0a000003 beq a000b5ec <_Heap_Walk+0x3c4>
" (= first free)"
: (block->prev == free_list_head ? " (= head)" : ""),
block->next,
block->next == last_free_block ?
" (= last free)"
: (block->next == free_list_tail ? " (= tail)" : "")
a000b5dc: e59fc17c ldr ip, [pc, #380] ; a000b760 <_Heap_Walk+0x538>
a000b5e0: e1530006 cmp r3, r6
a000b5e4: e59f116c ldr r1, [pc, #364] ; a000b758 <_Heap_Walk+0x530>
a000b5e8: 01a0100c moveq r1, ip
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
a000b5ec: e58d2004 str r2, [sp, #4]
a000b5f0: e58d0008 str r0, [sp, #8]
a000b5f4: e58d300c str r3, [sp, #12]
a000b5f8: e58d1010 str r1, [sp, #16]
a000b5fc: e1a03007 mov r3, r7
a000b600: e58da000 str sl, [sp]
a000b604: e1a00005 mov r0, r5
a000b608: e3a01000 mov r1, #0
a000b60c: e59f2150 ldr r2, [pc, #336] ; a000b764 <_Heap_Walk+0x53c>
a000b610: e12fff34 blx r4
block->next == last_free_block ?
" (= last free)"
: (block->next == free_list_tail ? " (= tail)" : "")
);
if ( block_size != next_block->prev_size ) {
a000b614: e5983000 ldr r3, [r8]
a000b618: e15a0003 cmp sl, r3
a000b61c: 0a000008 beq a000b644 <_Heap_Walk+0x41c>
(*printer)(
a000b620: e58d3004 str r3, [sp, #4] <== NOT EXECUTED
a000b624: e58da000 str sl, [sp] <== NOT EXECUTED
a000b628: e58d8008 str r8, [sp, #8] <== NOT EXECUTED
a000b62c: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b630: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b634: e59f212c ldr r2, [pc, #300] ; a000b768 <_Heap_Walk+0x540> <== NOT EXECUTED
a000b638: e1a03007 mov r3, r7 <== NOT EXECUTED
a000b63c: e12fff34 blx r4 <== NOT EXECUTED
a000b640: ea00002d b a000b6fc <_Heap_Walk+0x4d4> <== NOT EXECUTED
);
return false;
}
if ( !prev_used ) {
a000b644: e35b0000 cmp fp, #0
a000b648: 1a000006 bne a000b668 <_Heap_Walk+0x440>
(*printer)(
a000b64c: e59f2118 ldr r2, [pc, #280] ; a000b76c <_Heap_Walk+0x544> <== NOT EXECUTED
a000b650: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b654: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b658: e1a03007 mov r3, r7 <== NOT EXECUTED
a000b65c: e12fff34 blx r4 <== NOT EXECUTED
return false;
}
if ( !_Heap_Is_prev_used( next_block ) ) {
if ( !_Heap_Walk_check_free_block( source, printer, heap, block ) ) {
return false;
a000b660: e1a0800b mov r8, fp <== NOT EXECUTED
a000b664: ea00001c b a000b6dc <_Heap_Walk+0x4b4> <== NOT EXECUTED
block = next_block;
} while ( block != first_block );
return true;
}
a000b668: e5963008 ldr r3, [r6, #8]
a000b66c: ea000002 b a000b67c <_Heap_Walk+0x454>
{
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *free_block = _Heap_Free_list_first( heap );
while ( free_block != free_list_tail ) {
if ( free_block == block ) {
a000b670: e1530007 cmp r3, r7
a000b674: 0a000014 beq a000b6cc <_Heap_Walk+0x4a4>
return true;
}
free_block = free_block->next;
a000b678: e5933008 ldr r3, [r3, #8]
)
{
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *free_block = _Heap_Free_list_first( heap );
while ( free_block != free_list_tail ) {
a000b67c: e1530006 cmp r3, r6
a000b680: 1afffffa bne a000b670 <_Heap_Walk+0x448>
a000b684: ea000017 b a000b6e8 <_Heap_Walk+0x4c0> <== NOT EXECUTED
if ( !_Heap_Is_prev_used( next_block ) ) {
if ( !_Heap_Walk_check_free_block( source, printer, heap, block ) ) {
return false;
}
} else if (prev_used) {
a000b688: e35b0000 cmp fp, #0
a000b68c: 0a000006 beq a000b6ac <_Heap_Walk+0x484>
(*printer)(
a000b690: e58da000 str sl, [sp]
a000b694: e1a00005 mov r0, r5
a000b698: e3a01000 mov r1, #0
a000b69c: e59f20cc ldr r2, [pc, #204] ; a000b770 <_Heap_Walk+0x548>
a000b6a0: e1a03007 mov r3, r7
a000b6a4: e12fff34 blx r4
a000b6a8: ea000007 b a000b6cc <_Heap_Walk+0x4a4>
"block 0x%08x: size %u\n",
block,
block_size
);
} else {
(*printer)(
a000b6ac: e58da000 str sl, [sp]
a000b6b0: e5973000 ldr r3, [r7]
a000b6b4: e1a00005 mov r0, r5
a000b6b8: e1a0100b mov r1, fp
a000b6bc: e58d3004 str r3, [sp, #4]
a000b6c0: e59f20ac ldr r2, [pc, #172] ; a000b774 <_Heap_Walk+0x54c>
a000b6c4: e1a03007 mov r3, r7
a000b6c8: e12fff34 blx r4
block->prev_size
);
}
block = next_block;
} while ( block != first_block );
a000b6cc: e59d2020 ldr r2, [sp, #32]
a000b6d0: e1580002 cmp r8, r2
a000b6d4: 1affff72 bne a000b4a4 <_Heap_Walk+0x27c>
Heap_Block *block = first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
if ( !_System_state_Is_up( _System_state_Get() ) ) {
return true;
a000b6d8: e3a08001 mov r8, #1
block = next_block;
} while ( block != first_block );
return true;
}
a000b6dc: e1a00008 mov r0, r8
a000b6e0: e28dd030 add sp, sp, #48 ; 0x30
a000b6e4: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
return false;
}
if ( !_Heap_Walk_is_in_free_list( heap, block ) ) {
(*printer)(
a000b6e8: e59f2088 ldr r2, [pc, #136] ; a000b778 <_Heap_Walk+0x550> <== NOT EXECUTED
a000b6ec: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b6f0: e3a01001 mov r1, #1 <== NOT EXECUTED
a000b6f4: e1a03007 mov r3, r7 <== NOT EXECUTED
a000b6f8: e12fff34 blx r4
return false;
}
if ( !_Heap_Is_prev_used( next_block ) ) {
if ( !_Heap_Walk_check_free_block( source, printer, heap, block ) ) {
return false;
a000b6fc: e3a08000 mov r8, #0
a000b700: eafffff5 b a000b6dc <_Heap_Walk+0x4b4>
a000b1e4 <_Heap_Walk_print>:
static void _Heap_Walk_print( int source, bool error, const char *fmt, ... )
{
a000b1e4: e92d000c push {r2, r3} <== NOT EXECUTED
a000b1e8: e92d4001 push {r0, lr} <== NOT EXECUTED
a000b1ec: e1a03000 mov r3, r0 <== NOT EXECUTED
va_list ap;
if ( error ) {
a000b1f0: e31100ff tst r1, #255 ; 0xff <== NOT EXECUTED
printk( "FAIL[%d]: ", source );
a000b1f4: 159f0024 ldrne r0, [pc, #36] ; a000b220 <_Heap_Walk_print+0x3c><== NOT EXECUTED
} else {
printk( "PASS[%d]: ", source );
a000b1f8: 059f0024 ldreq r0, [pc, #36] ; a000b224 <_Heap_Walk_print+0x40><== NOT EXECUTED
a000b1fc: e1a01003 mov r1, r3 <== NOT EXECUTED
a000b200: ebfff166 bl a00077a0 <printk> <== NOT EXECUTED
}
va_start( ap, fmt );
a000b204: e28d100c add r1, sp, #12 <== NOT EXECUTED
vprintk( fmt, ap );
a000b208: e59d0008 ldr r0, [sp, #8] <== NOT EXECUTED
printk( "FAIL[%d]: ", source );
} else {
printk( "PASS[%d]: ", source );
}
va_start( ap, fmt );
a000b20c: e58d1000 str r1, [sp] <== NOT EXECUTED
vprintk( fmt, ap );
a000b210: ebfff82f bl a00092d4 <vprintk> <== NOT EXECUTED
va_end( ap );
}
a000b214: e8bd4008 pop {r3, lr} <== NOT EXECUTED
a000b218: e28dd008 add sp, sp, #8 <== NOT EXECUTED
a000b21c: e12fff1e bx lr <== NOT EXECUTED
a000a648 <_Internal_error_Occurred>:
bool is_internal,
Internal_errors_t the_error
)
{
_Internal_errors_What_happened.the_source = the_source;
a000a648: e59f3038 ldr r3, [pc, #56] ; a000a688 <_Internal_error_Occurred+0x40>
void _Internal_error_Occurred(
Internal_errors_Source the_source,
bool is_internal,
Internal_errors_t the_error
)
{
a000a64c: e20110ff and r1, r1, #255 ; 0xff
a000a650: e52de004 push {lr} ; (str lr, [sp, #-4]!)
_Internal_errors_What_happened.the_source = the_source;
a000a654: e5830000 str r0, [r3]
_Internal_errors_What_happened.is_internal = is_internal;
a000a658: e5c31004 strb r1, [r3, #4]
_Internal_errors_What_happened.the_error = the_error;
a000a65c: e5832008 str r2, [r3, #8]
void _Internal_error_Occurred(
Internal_errors_Source the_source,
bool is_internal,
Internal_errors_t the_error
)
{
a000a660: e1a04002 mov r4, r2
_Internal_errors_What_happened.the_source = the_source;
_Internal_errors_What_happened.is_internal = is_internal;
_Internal_errors_What_happened.the_error = the_error;
_User_extensions_Fatal( the_source, is_internal, the_error );
a000a664: eb000738 bl a000c34c <_User_extensions_Fatal>
RTEMS_INLINE_ROUTINE void _System_state_Set (
System_state_Codes state
)
{
_System_state_Current = state;
a000a668: e59f301c ldr r3, [pc, #28] ; a000a68c <_Internal_error_Occurred+0x44><== NOT EXECUTED
a000a66c: e3a02005 mov r2, #5 <== NOT EXECUTED
a000a670: e5832000 str r2, [r3] <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000a674: e10f2000 mrs r2, CPSR <== NOT EXECUTED
a000a678: e3823080 orr r3, r2, #128 ; 0x80 <== NOT EXECUTED
a000a67c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
_System_state_Set( SYSTEM_STATE_FAILED );
_CPU_Fatal_halt( the_error );
a000a680: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a684: eafffffe b a000a684 <_Internal_error_Occurred+0x3c> <== NOT EXECUTED
a000aa54 <_Objects_Get_information>:
Objects_Information *_Objects_Get_information(
Objects_APIs the_api,
uint16_t the_class
)
{
a000aa54: e1a01801 lsl r1, r1, #16
a000aa58: e92d4030 push {r4, r5, lr}
Objects_Information *info;
int the_class_api_maximum;
if ( !the_class )
a000aa5c: e1b05821 lsrs r5, r1, #16
Objects_Information *_Objects_Get_information(
Objects_APIs the_api,
uint16_t the_class
)
{
a000aa60: e1a04000 mov r4, r0
Objects_Information *info;
int the_class_api_maximum;
if ( !the_class )
a000aa64: 0a000010 beq a000aaac <_Objects_Get_information+0x58>
/*
* This call implicitly validates the_api so we do not call
* _Objects_Is_api_valid above here.
*/
the_class_api_maximum = _Objects_API_maximum_class( the_api );
a000aa68: eb001238 bl a000f350 <_Objects_API_maximum_class>
if ( the_class_api_maximum == 0 )
a000aa6c: e3500000 cmp r0, #0
a000aa70: 0a00000f beq a000aab4 <_Objects_Get_information+0x60>
return NULL;
if ( the_class > (uint32_t) the_class_api_maximum )
a000aa74: e1550000 cmp r5, r0
return NULL;
a000aa78: 83a00000 movhi r0, #0
*/
the_class_api_maximum = _Objects_API_maximum_class( the_api );
if ( the_class_api_maximum == 0 )
return NULL;
if ( the_class > (uint32_t) the_class_api_maximum )
a000aa7c: 8a00000c bhi a000aab4 <_Objects_Get_information+0x60>
return NULL;
if ( !_Objects_Information_table[ the_api ] )
a000aa80: e59f3030 ldr r3, [pc, #48] ; a000aab8 <_Objects_Get_information+0x64>
a000aa84: e7930104 ldr r0, [r3, r4, lsl #2]
a000aa88: e3500000 cmp r0, #0
a000aa8c: 0a000008 beq a000aab4 <_Objects_Get_information+0x60>
return NULL;
info = _Objects_Information_table[ the_api ][ the_class ];
a000aa90: e7900105 ldr r0, [r0, r5, lsl #2]
if ( !info )
a000aa94: e3500000 cmp r0, #0
a000aa98: 0a000005 beq a000aab4 <_Objects_Get_information+0x60>
* In a multprocessing configuration, we may access remote objects.
* Thus we may have 0 local instances and still have a valid object
* pointer.
*/
#if !defined(RTEMS_MULTIPROCESSING)
if ( info->maximum == 0 )
a000aa9c: e1d031b0 ldrh r3, [r0, #16]
return NULL;
a000aaa0: e3530000 cmp r3, #0
a000aaa4: 03a00000 moveq r0, #0
a000aaa8: e8bd8030 pop {r4, r5, pc}
{
Objects_Information *info;
int the_class_api_maximum;
if ( !the_class )
return NULL;
a000aaac: e1a00005 mov r0, r5 <== NOT EXECUTED
a000aab0: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
if ( info->maximum == 0 )
return NULL;
#endif
return info;
}
a000aab4: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000aabc <_Objects_Get_isr_disable>:
{
Objects_Control *the_object;
uint32_t index;
ISR_Level level;
index = id - information->minimum_id + 1;
a000aabc: e590c008 ldr ip, [r0, #8]
Objects_Information *information,
Objects_Id id,
Objects_Locations *location,
ISR_Level *level_p
)
{
a000aac0: e92d4010 push {r4, lr}
Objects_Control *the_object;
uint32_t index;
ISR_Level level;
index = id - information->minimum_id + 1;
a000aac4: e26cc001 rsb ip, ip, #1
a000aac8: e08c1001 add r1, ip, r1
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000aacc: e10f4000 mrs r4, CPSR
a000aad0: e384c080 orr ip, r4, #128 ; 0x80
a000aad4: e129f00c msr CPSR_fc, ip
_ISR_Disable( level );
if ( information->maximum >= index ) {
a000aad8: e1d0c1b0 ldrh ip, [r0, #16]
a000aadc: e15c0001 cmp ip, r1
a000aae0: 3a00000b bcc a000ab14 <_Objects_Get_isr_disable+0x58>
if ( (the_object = information->local_table[ index ]) != NULL ) {
a000aae4: e590001c ldr r0, [r0, #28]
a000aae8: e7900101 ldr r0, [r0, r1, lsl #2]
a000aaec: e3500000 cmp r0, #0
a000aaf0: 0a000003 beq a000ab04 <_Objects_Get_isr_disable+0x48>
*location = OBJECTS_LOCAL;
a000aaf4: e3a01000 mov r1, #0
a000aaf8: e5821000 str r1, [r2]
*level_p = level;
a000aafc: e5834000 str r4, [r3]
return the_object;
a000ab00: e8bd8010 pop {r4, pc}
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000ab04: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
}
_ISR_Enable( level );
*location = OBJECTS_ERROR;
a000ab08: e3a03001 mov r3, #1 <== NOT EXECUTED
a000ab0c: e5823000 str r3, [r2] <== NOT EXECUTED
return NULL;
a000ab10: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000ab14: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
}
_ISR_Enable( level );
*location = OBJECTS_ERROR;
a000ab18: e3a03001 mov r3, #1 <== NOT EXECUTED
a000ab1c: e5823000 str r3, [r2] <== NOT EXECUTED
#if defined(RTEMS_MULTIPROCESSING)
_Objects_MP_Is_remote( information, id, location, &the_object );
return the_object;
#else
return NULL;
a000ab20: e3a00000 mov r0, #0 <== NOT EXECUTED
#endif
}
a000ab24: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000c554 <_Objects_Get_name_as_string>:
char *_Objects_Get_name_as_string(
Objects_Id id,
size_t length,
char *name
)
{
a000c554: e92d40f7 push {r0, r1, r2, r4, r5, r6, r7, lr}
char lname[5];
Objects_Control *the_object;
Objects_Locations location;
Objects_Id tmpId;
if ( length == 0 )
a000c558: e2516000 subs r6, r1, #0
char *_Objects_Get_name_as_string(
Objects_Id id,
size_t length,
char *name
)
{
a000c55c: e1a04002 mov r4, r2
Objects_Control *the_object;
Objects_Locations location;
Objects_Id tmpId;
if ( length == 0 )
return NULL;
a000c560: 01a04006 moveq r4, r6
char lname[5];
Objects_Control *the_object;
Objects_Locations location;
Objects_Id tmpId;
if ( length == 0 )
a000c564: 0a000038 beq a000c64c <_Objects_Get_name_as_string+0xf8>
return NULL;
if ( name == NULL )
a000c568: e3540000 cmp r4, #0
a000c56c: 0a000036 beq a000c64c <_Objects_Get_name_as_string+0xf8>
return NULL;
tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id;
a000c570: e3500000 cmp r0, #0
a000c574: 059f30d8 ldreq r3, [pc, #216] ; a000c654 <_Objects_Get_name_as_string+0x100>
a000c578: 11a07000 movne r7, r0
a000c57c: 05933004 ldreq r3, [r3, #4]
a000c580: 05937008 ldreq r7, [r3, #8]
information = _Objects_Get_information_id( tmpId );
a000c584: e1a00007 mov r0, r7
a000c588: ebffffb7 bl a000c46c <_Objects_Get_information_id>
if ( !information )
a000c58c: e2505000 subs r5, r0, #0
return NULL;
a000c590: 01a04005 moveq r4, r5
return NULL;
tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id;
information = _Objects_Get_information_id( tmpId );
if ( !information )
a000c594: 0a00002c beq a000c64c <_Objects_Get_name_as_string+0xf8>
return NULL;
the_object = _Objects_Get( information, tmpId, &location );
a000c598: e1a01007 mov r1, r7
a000c59c: e28d2008 add r2, sp, #8
a000c5a0: eb00002d bl a000c65c <_Objects_Get>
switch ( location ) {
a000c5a4: e59d3008 ldr r3, [sp, #8]
a000c5a8: e3530000 cmp r3, #0
#if defined(RTEMS_MULTIPROCESSING)
case OBJECTS_REMOTE:
/* not supported */
#endif
case OBJECTS_ERROR:
return NULL;
a000c5ac: 13a04000 movne r4, #0
information = _Objects_Get_information_id( tmpId );
if ( !information )
return NULL;
the_object = _Objects_Get( information, tmpId, &location );
switch ( location ) {
a000c5b0: 1a000025 bne a000c64c <_Objects_Get_name_as_string+0xf8>
return NULL;
case OBJECTS_LOCAL:
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string ) {
a000c5b4: e5d52038 ldrb r2, [r5, #56] ; 0x38
a000c5b8: e3520000 cmp r2, #0
a000c5bc: 0a000004 beq a000c5d4 <_Objects_Get_name_as_string+0x80>
s = the_object->name.name_p;
a000c5c0: e590100c ldr r1, [r0, #12]
lname[ 4 ] = '\0';
s = lname;
}
d = name;
if ( s ) {
a000c5c4: e3510000 cmp r1, #0
a000c5c8: 01a03004 moveq r3, r4
a000c5cc: 1a00000a bne a000c5fc <_Objects_Get_name_as_string+0xa8>
a000c5d0: ea00001a b a000c640 <_Objects_Get_name_as_string+0xec>
if ( information->is_string ) {
s = the_object->name.name_p;
} else
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
a000c5d4: e590300c ldr r3, [r0, #12]
lname[ 0 ] = (u32_name >> 24) & 0xff;
lname[ 1 ] = (u32_name >> 16) & 0xff;
lname[ 2 ] = (u32_name >> 8) & 0xff;
lname[ 3 ] = (u32_name >> 0) & 0xff;
lname[ 4 ] = '\0';
a000c5d8: e5cd2004 strb r2, [sp, #4]
} else
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
lname[ 0 ] = (u32_name >> 24) & 0xff;
a000c5dc: e1a01c23 lsr r1, r3, #24
a000c5e0: e5cd1000 strb r1, [sp]
lname[ 1 ] = (u32_name >> 16) & 0xff;
a000c5e4: e1a01823 lsr r1, r3, #16
a000c5e8: e5cd1001 strb r1, [sp, #1]
lname[ 2 ] = (u32_name >> 8) & 0xff;
a000c5ec: e1a01423 lsr r1, r3, #8
a000c5f0: e5cd1002 strb r1, [sp, #2] <== NOT EXECUTED
lname[ 3 ] = (u32_name >> 0) & 0xff;
a000c5f4: e5cd3003 strb r3, [sp, #3] <== NOT EXECUTED
lname[ 4 ] = '\0';
s = lname;
a000c5f8: e1a0100d mov r1, sp <== NOT EXECUTED
}
d = name;
if ( s ) {
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
*d = (isprint((unsigned char)*s)) ? *s : '*';
a000c5fc: e1a03004 mov r3, r4
a000c600: e3a02000 mov r2, #0
s = lname;
}
d = name;
if ( s ) {
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
a000c604: e2466001 sub r6, r6, #1
*d = (isprint((unsigned char)*s)) ? *s : '*';
a000c608: e59fc048 ldr ip, [pc, #72] ; a000c658 <_Objects_Get_name_as_string+0x104>
a000c60c: ea000006 b a000c62c <_Objects_Get_name_as_string+0xd8>
a000c610: e59ce000 ldr lr, [ip]
s = lname;
}
d = name;
if ( s ) {
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
a000c614: e2822001 add r2, r2, #1
*d = (isprint((unsigned char)*s)) ? *s : '*';
a000c618: e08ee000 add lr, lr, r0
a000c61c: e5dee001 ldrb lr, [lr, #1]
a000c620: e31e0097 tst lr, #151 ; 0x97
a000c624: 03a0002a moveq r0, #42 ; 0x2a
a000c628: e4c30001 strb r0, [r3], #1
s = lname;
}
d = name;
if ( s ) {
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
a000c62c: e1520006 cmp r2, r6
a000c630: 2a000002 bcs a000c640 <_Objects_Get_name_as_string+0xec>
a000c634: e7d10002 ldrb r0, [r1, r2]
a000c638: e3500000 cmp r0, #0
a000c63c: 1afffff3 bne a000c610 <_Objects_Get_name_as_string+0xbc>
*d = (isprint((unsigned char)*s)) ? *s : '*';
}
}
*d = '\0';
a000c640: e3a02000 mov r2, #0
a000c644: e5c32000 strb r2, [r3]
_Thread_Enable_dispatch();
a000c648: eb0002bb bl a000d13c <_Thread_Enable_dispatch>
return name;
}
return NULL; /* unreachable path */
}
a000c64c: e1a00004 mov r0, r4
a000c650: e8bd80fe pop {r1, r2, r3, r4, r5, r6, r7, pc}
a001ace8 <_Objects_Get_no_protection>:
/*
* You can't just extract the index portion or you can get tricked
* by a value between 1 and maximum.
*/
index = id - information->minimum_id + 1;
a001ace8: e5903008 ldr r3, [r0, #8]
a001acec: e2633001 rsb r3, r3, #1
a001acf0: e0833001 add r3, r3, r1
if ( information->maximum >= index ) {
a001acf4: e1d011b0 ldrh r1, [r0, #16]
a001acf8: e1510003 cmp r1, r3
a001acfc: 3a000005 bcc a001ad18 <_Objects_Get_no_protection+0x30>
if ( (the_object = information->local_table[ index ]) != NULL ) {
a001ad00: e590101c ldr r1, [r0, #28]
a001ad04: e7910103 ldr r0, [r1, r3, lsl #2]
a001ad08: e3500000 cmp r0, #0
*location = OBJECTS_LOCAL;
a001ad0c: 13a03000 movne r3, #0
a001ad10: 15823000 strne r3, [r2]
* by a value between 1 and maximum.
*/
index = id - information->minimum_id + 1;
if ( information->maximum >= index ) {
if ( (the_object = information->local_table[ index ]) != NULL ) {
a001ad14: 112fff1e bxne lr
/*
* This isn't supported or required yet for Global objects so
* if it isn't local, we don't find it.
*/
*location = OBJECTS_ERROR;
a001ad18: e3a03001 mov r3, #1
a001ad1c: e5823000 str r3, [r2]
return NULL;
a001ad20: e3a00000 mov r0, #0
}
a001ad24: e12fff1e bx lr <== NOT EXECUTED
a000c08c <_Objects_Id_to_name>:
*/
Objects_Name_or_id_lookup_errors _Objects_Id_to_name (
Objects_Id id,
Objects_Name *name
)
{
a000c08c: e92d4031 push {r0, r4, r5, lr}
a000c090: e1a05001 mov r5, r1
/*
* Caller is trusted for name != NULL.
*/
tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id;
a000c094: e2501000 subs r1, r0, #0
a000c098: 059f3078 ldreq r3, [pc, #120] ; a000c118 <_Objects_Id_to_name+0x8c>
a000c09c: 05933004 ldreq r3, [r3, #4]
a000c0a0: 05931008 ldreq r1, [r3, #8]
a000c0a4: e1a03c21 lsr r3, r1, #24
a000c0a8: e2033007 and r3, r3, #7
*/
RTEMS_INLINE_ROUTINE bool _Objects_Is_api_valid(
uint32_t the_api
)
{
if ( !the_api || the_api > OBJECTS_APIS_LAST )
a000c0ac: e2432001 sub r2, r3, #1
a000c0b0: e3520002 cmp r2, #2
a000c0b4: 8a000010 bhi a000c0fc <_Objects_Id_to_name+0x70>
a000c0b8: ea000011 b a000c104 <_Objects_Id_to_name+0x78>
*/
RTEMS_INLINE_ROUTINE uint32_t _Objects_Get_class(
Objects_Id id
)
{
return (uint32_t)
a000c0bc: e1a02da1 lsr r2, r1, #27
if ( !_Objects_Information_table[ the_api ] )
return OBJECTS_INVALID_ID;
the_class = _Objects_Get_class( tmpId );
information = _Objects_Information_table[ the_api ][ the_class ];
a000c0c0: e7930102 ldr r0, [r3, r2, lsl #2]
if ( !information )
a000c0c4: e3500000 cmp r0, #0
a000c0c8: 0a00000b beq a000c0fc <_Objects_Id_to_name+0x70>
return OBJECTS_INVALID_ID;
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string )
a000c0cc: e5d04038 ldrb r4, [r0, #56] ; 0x38
a000c0d0: e3540000 cmp r4, #0
a000c0d4: 1a000008 bne a000c0fc <_Objects_Id_to_name+0x70>
return OBJECTS_INVALID_ID;
#endif
the_object = _Objects_Get( information, tmpId, &ignored_location );
a000c0d8: e1a0200d mov r2, sp
a000c0dc: ebffffd0 bl a000c024 <_Objects_Get>
if ( !the_object )
a000c0e0: e3500000 cmp r0, #0
a000c0e4: 0a000004 beq a000c0fc <_Objects_Id_to_name+0x70>
return OBJECTS_INVALID_ID;
*name = the_object->name;
a000c0e8: e590300c ldr r3, [r0, #12]
a000c0ec: e5853000 str r3, [r5]
_Thread_Enable_dispatch();
a000c0f0: eb0002cc bl a000cc28 <_Thread_Enable_dispatch> <== NOT EXECUTED
return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL;
a000c0f4: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c0f8: ea000000 b a000c100 <_Objects_Id_to_name+0x74> <== NOT EXECUTED
the_api = _Objects_Get_API( tmpId );
if ( !_Objects_Is_api_valid( the_api ) )
return OBJECTS_INVALID_ID;
if ( !_Objects_Information_table[ the_api ] )
return OBJECTS_INVALID_ID;
a000c0fc: e3a00003 mov r0, #3
return OBJECTS_INVALID_ID;
*name = the_object->name;
_Thread_Enable_dispatch();
return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL;
}
a000c100: e8bd8038 pop {r3, r4, r5, pc}
the_api = _Objects_Get_API( tmpId );
if ( !_Objects_Is_api_valid( the_api ) )
return OBJECTS_INVALID_ID;
if ( !_Objects_Information_table[ the_api ] )
a000c104: e59f2010 ldr r2, [pc, #16] ; a000c11c <_Objects_Id_to_name+0x90>
a000c108: e7923103 ldr r3, [r2, r3, lsl #2]
a000c10c: e3530000 cmp r3, #0
a000c110: 1affffe9 bne a000c0bc <_Objects_Id_to_name+0x30>
a000c114: eafffff8 b a000c0fc <_Objects_Id_to_name+0x70>
a000aca0 <_Objects_Name_to_id_u32>:
Objects_Name name_for_mp;
#endif
/* ASSERT: information->is_string == false */
if ( !id )
a000aca0: e3530000 cmp r3, #0
Objects_Information *information,
uint32_t name,
uint32_t node,
Objects_Id *id
)
{
a000aca4: e92d4030 push {r4, r5, lr}
Objects_Name name_for_mp;
#endif
/* ASSERT: information->is_string == false */
if ( !id )
a000aca8: 0a00001a beq a000ad18 <_Objects_Name_to_id_u32+0x78>
return OBJECTS_INVALID_ADDRESS;
if ( name == 0 )
a000acac: e3510000 cmp r1, #0
a000acb0: 0a00001a beq a000ad20 <_Objects_Name_to_id_u32+0x80>
return OBJECTS_INVALID_NAME;
search_local_node = false;
if ( information->maximum != 0 &&
a000acb4: e1d041b0 ldrh r4, [r0, #16]
a000acb8: e3540000 cmp r4, #0
a000acbc: 0a000019 beq a000ad28 <_Objects_Name_to_id_u32+0x88>
a000acc0: e3720106 cmn r2, #-2147483647 ; 0x80000001
a000acc4: 13520000 cmpne r2, #0
a000acc8: 03a02001 moveq r2, #1
a000accc: 0a00000e beq a000ad0c <_Objects_Name_to_id_u32+0x6c>
(node == OBJECTS_SEARCH_ALL_NODES ||
node == OBJECTS_SEARCH_LOCAL_NODE ||
a000acd0: e3520001 cmp r2, #1
a000acd4: 1a000011 bne a000ad20 <_Objects_Name_to_id_u32+0x80>
a000acd8: ea00000b b a000ad0c <_Objects_Name_to_id_u32+0x6c>
))
search_local_node = true;
if ( search_local_node ) {
for ( index = 1; index <= information->maximum; index++ ) {
the_object = information->local_table[ index ];
a000acdc: e590c01c ldr ip, [r0, #28]
a000ace0: e79cc102 ldr ip, [ip, r2, lsl #2]
if ( !the_object )
a000ace4: e35c0000 cmp ip, #0
a000ace8: 0a000006 beq a000ad08 <_Objects_Name_to_id_u32+0x68>
continue;
if ( name == the_object->name.name_u32 ) {
a000acec: e59c500c ldr r5, [ip, #12]
a000acf0: e1510005 cmp r1, r5
a000acf4: 1a000003 bne a000ad08 <_Objects_Name_to_id_u32+0x68>
*id = the_object->id;
a000acf8: e59c2008 ldr r2, [ip, #8]
return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL;
a000acfc: e3a00000 mov r0, #0
the_object = information->local_table[ index ];
if ( !the_object )
continue;
if ( name == the_object->name.name_u32 ) {
*id = the_object->id;
a000ad00: e5832000 str r2, [r3]
return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL;
a000ad04: e8bd8030 pop {r4, r5, pc}
_Objects_Is_local_node( node )
))
search_local_node = true;
if ( search_local_node ) {
for ( index = 1; index <= information->maximum; index++ ) {
a000ad08: e2822001 add r2, r2, #1
a000ad0c: e1520004 cmp r2, r4
a000ad10: 9afffff1 bls a000acdc <_Objects_Name_to_id_u32+0x3c>
a000ad14: ea000001 b a000ad20 <_Objects_Name_to_id_u32+0x80> <== NOT EXECUTED
#endif
/* ASSERT: information->is_string == false */
if ( !id )
return OBJECTS_INVALID_ADDRESS;
a000ad18: e3a00002 mov r0, #2 <== NOT EXECUTED
a000ad1c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
if ( name == 0 )
return OBJECTS_INVALID_NAME;
a000ad20: e3a00001 mov r0, #1 <== NOT EXECUTED
a000ad24: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
return OBJECTS_INVALID_NAME;
name_for_mp.name_u32 = name;
return _Objects_MP_Global_name_search( information, name_for_mp, node, id );
#else
return OBJECTS_INVALID_NAME;
a000ad28: e3a00001 mov r0, #1 <== NOT EXECUTED
#endif
}
a000ad2c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000b390 <_Objects_Set_name>:
bool _Objects_Set_name(
Objects_Information *information,
Objects_Control *the_object,
const char *name
)
{
a000b390: e92d40f0 push {r4, r5, r6, r7, lr}
a000b394: e1a05000 mov r5, r0
a000b398: e1a06001 mov r6, r1
size_t length;
const char *s;
s = name;
length = strnlen( name, information->name_length );
a000b39c: e1a00002 mov r0, r2
a000b3a0: e1d513ba ldrh r1, [r5, #58] ; 0x3a
bool _Objects_Set_name(
Objects_Information *information,
Objects_Control *the_object,
const char *name
)
{
a000b3a4: e1a07002 mov r7, r2
size_t length;
const char *s;
s = name;
length = strnlen( name, information->name_length );
a000b3a8: eb00205c bl a0013520 <strnlen>
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string ) {
a000b3ac: e5d53038 ldrb r3, [r5, #56] ; 0x38
{
size_t length;
const char *s;
s = name;
length = strnlen( name, information->name_length );
a000b3b0: e1a04000 mov r4, r0
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string ) {
a000b3b4: e3530000 cmp r3, #0
a000b3b8: 0a000011 beq a000b404 <_Objects_Set_name+0x74>
char *d;
d = _Workspace_Allocate( length + 1 );
a000b3bc: e2800001 add r0, r0, #1
a000b3c0: eb0006c4 bl a000ced8 <_Workspace_Allocate>
if ( !d )
a000b3c4: e2505000 subs r5, r0, #0
a000b3c8: 0a000020 beq a000b450 <_Objects_Set_name+0xc0>
return false;
if ( the_object->name.name_p ) {
a000b3cc: e596000c ldr r0, [r6, #12]
a000b3d0: e3500000 cmp r0, #0
a000b3d4: 0a000002 beq a000b3e4 <_Objects_Set_name+0x54>
_Workspace_Free( (void *)the_object->name.name_p );
a000b3d8: eb0006c4 bl a000cef0 <_Workspace_Free>
the_object->name.name_p = NULL;
a000b3dc: e3a03000 mov r3, #0
a000b3e0: e586300c str r3, [r6, #12]
}
strncpy( d, name, length );
a000b3e4: e1a00005 mov r0, r5
a000b3e8: e1a01007 mov r1, r7
a000b3ec: e1a02004 mov r2, r4
a000b3f0: eb00200f bl a0013434 <strncpy>
d[length] = '\0';
a000b3f4: e3a03000 mov r3, #0
a000b3f8: e7c53004 strb r3, [r5, r4]
the_object->name.name_p = d;
a000b3fc: e586500c str r5, [r6, #12]
a000b400: ea000010 b a000b448 <_Objects_Set_name+0xb8>
} else
#endif
{
the_object->name.name_u32 = _Objects_Build_name(
a000b404: e3500001 cmp r0, #1 <== NOT EXECUTED
a000b408: 85d73001 ldrbhi r3, [r7, #1] <== NOT EXECUTED
a000b40c: e5d72000 ldrb r2, [r7] <== NOT EXECUTED
a000b410: 93a03602 movls r3, #2097152 ; 0x200000 <== NOT EXECUTED
a000b414: 81a03803 lslhi r3, r3, #16 <== NOT EXECUTED
a000b418: e1a02c02 lsl r2, r2, #24 <== NOT EXECUTED
a000b41c: e3500002 cmp r0, #2 <== NOT EXECUTED
a000b420: e1832002 orr r2, r3, r2 <== NOT EXECUTED
a000b424: 85d73002 ldrbhi r3, [r7, #2] <== NOT EXECUTED
a000b428: 93a03a02 movls r3, #8192 ; 0x2000 <== NOT EXECUTED
a000b42c: 81a03403 lslhi r3, r3, #8 <== NOT EXECUTED
a000b430: e3500003 cmp r0, #3 <== NOT EXECUTED
a000b434: e1822003 orr r2, r2, r3 <== NOT EXECUTED
a000b438: 85d73003 ldrbhi r3, [r7, #3] <== NOT EXECUTED
a000b43c: 93a03020 movls r3, #32 <== NOT EXECUTED
a000b440: e1823003 orr r3, r2, r3 <== NOT EXECUTED
a000b444: e586300c str r3, [r6, #12] <== NOT EXECUTED
((3 < length) ? s[ 3 ] : ' ')
);
}
return true;
a000b448: e3a00001 mov r0, #1
a000b44c: e8bd80f0 pop {r4, r5, r6, r7, pc}
if ( information->is_string ) {
char *d;
d = _Workspace_Allocate( length + 1 );
if ( !d )
return false;
a000b450: e1a00005 mov r0, r5
);
}
return true;
}
a000b454: e8bd80f0 pop {r4, r5, r6, r7, pc}
a000ba78 <_POSIX_Absolute_timeout_to_ticks>:
*/
POSIX_Absolute_timeout_conversion_results_t _POSIX_Absolute_timeout_to_ticks(
const struct timespec *abstime,
Watchdog_Interval *ticks_out
)
{
a000ba78: e92d40ff push {r0, r1, r2, r3, r4, r5, r6, r7, lr} <== NOT EXECUTED
/*
* Make sure there is always a value returned.
*/
*ticks_out = 0;
a000ba7c: e3a03000 mov r3, #0 <== NOT EXECUTED
a000ba80: e5813000 str r3, [r1] <== NOT EXECUTED
*/
POSIX_Absolute_timeout_conversion_results_t _POSIX_Absolute_timeout_to_ticks(
const struct timespec *abstime,
Watchdog_Interval *ticks_out
)
{
a000ba84: e1a07000 mov r7, r0 <== NOT EXECUTED
a000ba88: e1a04001 mov r4, r1 <== NOT EXECUTED
*ticks_out = 0;
/*
* Is the absolute time even valid?
*/
if ( !_Timespec_Is_valid(abstime) )
a000ba8c: eb000f07 bl a000f6b0 <_Timespec_Is_valid> <== NOT EXECUTED
a000ba90: e3500000 cmp r0, #0 <== NOT EXECUTED
a000ba94: 0a000013 beq a000bae8 <_POSIX_Absolute_timeout_to_ticks+0x70><== NOT EXECUTED
return POSIX_ABSOLUTE_TIMEOUT_INVALID;
/*
* Is the absolute time in the past?
*/
_TOD_Get( ¤t_time );
a000ba98: e28d6008 add r6, sp, #8 <== NOT EXECUTED
a000ba9c: e1a00006 mov r0, r6 <== NOT EXECUTED
a000baa0: eb0006e0 bl a000d628 <_TOD_Get> <== NOT EXECUTED
if ( _Timespec_Less_than( abstime, ¤t_time ) )
a000baa4: e1a00007 mov r0, r7 <== NOT EXECUTED
a000baa8: e1a01006 mov r1, r6 <== NOT EXECUTED
a000baac: eb000f10 bl a000f6f4 <_Timespec_Less_than> <== NOT EXECUTED
a000bab0: e3500000 cmp r0, #0 <== NOT EXECUTED
return POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST;
a000bab4: 13a00001 movne r0, #1 <== NOT EXECUTED
/*
* Is the absolute time in the past?
*/
_TOD_Get( ¤t_time );
if ( _Timespec_Less_than( abstime, ¤t_time ) )
a000bab8: 1a00000a bne a000bae8 <_POSIX_Absolute_timeout_to_ticks+0x70><== NOT EXECUTED
return POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST;
/*
* How long until the requested absolute time?
*/
_Timespec_Subtract( ¤t_time, abstime, &difference );
a000babc: e1a00006 mov r0, r6 <== NOT EXECUTED
a000bac0: e1a01007 mov r1, r7 <== NOT EXECUTED
a000bac4: e1a0200d mov r2, sp <== NOT EXECUTED
a000bac8: eb000f17 bl a000f72c <_Timespec_Subtract> <== NOT EXECUTED
/*
* Internally the SuperCore uses ticks, so convert to them.
*/
*ticks_out = _Timespec_To_ticks( &difference );
a000bacc: e1a0000d mov r0, sp <== NOT EXECUTED
a000bad0: eb000f27 bl a000f774 <_Timespec_To_ticks> <== NOT EXECUTED
/*
* If the difference was 0, then the future is now. It is so bright
* we better wear shades.
*/
if ( !*ticks_out )
return POSIX_ABSOLUTE_TIMEOUT_IS_NOW;
a000bad4: e3500000 cmp r0, #0 <== NOT EXECUTED
_Timespec_Subtract( ¤t_time, abstime, &difference );
/*
* Internally the SuperCore uses ticks, so convert to them.
*/
*ticks_out = _Timespec_To_ticks( &difference );
a000bad8: e5840000 str r0, [r4] <== NOT EXECUTED
return POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST;
/*
* How long until the requested absolute time?
*/
_Timespec_Subtract( ¤t_time, abstime, &difference );
a000badc: e1a0500d mov r5, sp <== NOT EXECUTED
/*
* If the difference was 0, then the future is now. It is so bright
* we better wear shades.
*/
if ( !*ticks_out )
return POSIX_ABSOLUTE_TIMEOUT_IS_NOW;
a000bae0: 13a00003 movne r0, #3 <== NOT EXECUTED
a000bae4: 03a00002 moveq r0, #2 <== NOT EXECUTED
/*
* This is the case we were expecting and it took this long to
* get here.
*/
return POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE;
}
a000bae8: e28dd010 add sp, sp, #16 <== NOT EXECUTED
a000baec: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
a000f5ec <_POSIX_Barrier_Translate_core_barrier_return_code>:
#if defined(RTEMS_DEBUG)
if ( the_barrier_status > CORE_BARRIER_STATUS_LAST )
return EINVAL;
#endif
return _POSIX_Barrier_Return_codes[the_barrier_status];
}
a000f5ec: e59f3004 ldr r3, [pc, #4] ; a000f5f8 <_POSIX_Barrier_Translate_core_barrier_return_code+0xc><== NOT EXECUTED
a000f5f0: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED
a000f5f4: e12fff1e bx lr <== NOT EXECUTED
a000a250 <_POSIX_Condition_variables_Get>:
POSIX_Condition_variables_Control *_POSIX_Condition_variables_Get (
pthread_cond_t *cond,
Objects_Locations *location
)
{
a000a250: e92d4030 push {r4, r5, lr}
int status;
if ( !cond ) {
a000a254: e2505000 subs r5, r0, #0
POSIX_Condition_variables_Control *_POSIX_Condition_variables_Get (
pthread_cond_t *cond,
Objects_Locations *location
)
{
a000a258: e1a04001 mov r4, r1
int status;
if ( !cond ) {
a000a25c: 1a000003 bne a000a270 <_POSIX_Condition_variables_Get+0x20>
*location = OBJECTS_ERROR;
a000a260: e3a03001 mov r3, #1 <== NOT EXECUTED
a000a264: e5813000 str r3, [r1] <== NOT EXECUTED
return (POSIX_Condition_variables_Control *) 0;
a000a268: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a26c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
}
if ( *cond == PTHREAD_COND_INITIALIZER ) {
a000a270: e5953000 ldr r3, [r5]
a000a274: e3730001 cmn r3, #1
a000a278: 1a000007 bne a000a29c <_POSIX_Condition_variables_Get+0x4c>
/*
* Do an "auto-create" here.
*/
status = pthread_cond_init( cond, 0 );
a000a27c: e3a01000 mov r1, #0
a000a280: eb00000b bl a000a2b4 <pthread_cond_init>
if ( status ) {
a000a284: e3500000 cmp r0, #0
a000a288: 0a000003 beq a000a29c <_POSIX_Condition_variables_Get+0x4c>
*location = OBJECTS_ERROR;
a000a28c: e3a03001 mov r3, #1
a000a290: e5843000 str r3, [r4]
return (POSIX_Condition_variables_Control *) 0;
a000a294: e3a00000 mov r0, #0
a000a298: e8bd8030 pop {r4, r5, pc}
}
/*
* Now call Objects_Get()
*/
return (POSIX_Condition_variables_Control *)_Objects_Get(
a000a29c: e59f000c ldr r0, [pc, #12] ; a000a2b0 <_POSIX_Condition_variables_Get+0x60>
a000a2a0: e5951000 ldr r1, [r5]
a000a2a4: e1a02004 mov r2, r4
&_POSIX_Condition_variables_Information,
(Objects_Id) *cond,
location
);
}
a000a2a8: e8bd4030 pop {r4, r5, lr}
}
/*
* Now call Objects_Get()
*/
return (POSIX_Condition_variables_Control *)_Objects_Get(
a000a2ac: ea000a61 b a000cc38 <_Objects_Get>
a000a428 <_POSIX_Condition_variables_Wait_support>:
pthread_cond_t *cond,
pthread_mutex_t *mutex,
Watchdog_Interval timeout,
bool already_timedout
)
{
a000a428: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr}
a000a42c: e1a05000 mov r5, r0
a000a430: e1a04001 mov r4, r1
register POSIX_Condition_variables_Control *the_cond;
Objects_Locations location;
int status;
int mutex_status;
if ( !_POSIX_Mutex_Get( mutex, &location ) ) {
a000a434: e1a00001 mov r0, r1
a000a438: e1a0100d mov r1, sp
pthread_cond_t *cond,
pthread_mutex_t *mutex,
Watchdog_Interval timeout,
bool already_timedout
)
{
a000a43c: e1a07002 mov r7, r2
a000a440: e20380ff and r8, r3, #255 ; 0xff
register POSIX_Condition_variables_Control *the_cond;
Objects_Locations location;
int status;
int mutex_status;
if ( !_POSIX_Mutex_Get( mutex, &location ) ) {
a000a444: eb000056 bl a000a5a4 <_POSIX_Mutex_Get>
a000a448: e3500000 cmp r0, #0
a000a44c: e1a0600d mov r6, sp
a000a450: 0a000031 beq a000a51c <_POSIX_Condition_variables_Wait_support+0xf4>
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
a000a454: e59f30cc ldr r3, [pc, #204] ; a000a528 <_POSIX_Condition_variables_Wait_support+0x100>
return EINVAL;
}
_Thread_Unnest_dispatch();
the_cond = _POSIX_Condition_variables_Get( cond, &location );
a000a458: e1a00005 mov r0, r5
a000a45c: e1a0100d mov r1, sp
a000a460: e5932000 ldr r2, [r3]
a000a464: e2422001 sub r2, r2, #1
a000a468: e5832000 str r2, [r3]
a000a46c: ebffff77 bl a000a250 <_POSIX_Condition_variables_Get>
switch ( location ) {
a000a470: e59d3000 ldr r3, [sp]
return EINVAL;
}
_Thread_Unnest_dispatch();
the_cond = _POSIX_Condition_variables_Get( cond, &location );
a000a474: e1a0a000 mov sl, r0
switch ( location ) {
a000a478: e3530000 cmp r3, #0
a000a47c: 1a000026 bne a000a51c <_POSIX_Condition_variables_Wait_support+0xf4>
case OBJECTS_LOCAL:
if ( the_cond->Mutex && ( the_cond->Mutex != *mutex ) ) {
a000a480: e5903014 ldr r3, [r0, #20]
a000a484: e3530000 cmp r3, #0
a000a488: 0a000004 beq a000a4a0 <_POSIX_Condition_variables_Wait_support+0x78>
a000a48c: e5942000 ldr r2, [r4] <== NOT EXECUTED
a000a490: e1530002 cmp r3, r2 <== NOT EXECUTED
a000a494: 0a000001 beq a000a4a0 <_POSIX_Condition_variables_Wait_support+0x78><== NOT EXECUTED
_Thread_Enable_dispatch();
a000a498: eb000c9e bl a000d718 <_Thread_Enable_dispatch> <== NOT EXECUTED
a000a49c: ea00001e b a000a51c <_POSIX_Condition_variables_Wait_support+0xf4><== NOT EXECUTED
return EINVAL;
}
(void) pthread_mutex_unlock( mutex );
a000a4a0: e1a00004 mov r0, r4
a000a4a4: eb0000e4 bl a000a83c <pthread_mutex_unlock>
_Thread_Enable_dispatch();
return EINVAL;
}
*/
if ( !already_timedout ) {
a000a4a8: e3580000 cmp r8, #0
a000a4ac: 1a000013 bne a000a500 <_POSIX_Condition_variables_Wait_support+0xd8>
the_cond->Mutex = *mutex;
a000a4b0: e5943000 ldr r3, [r4]
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue );
_Thread_Executing->Wait.return_code = 0;
a000a4b4: e59f6070 ldr r6, [pc, #112] ; a000a52c <_POSIX_Condition_variables_Wait_support+0x104>
_Thread_Executing->Wait.queue = &the_cond->Wait_queue;
a000a4b8: e28a0018 add r0, sl, #24
return EINVAL;
}
*/
if ( !already_timedout ) {
the_cond->Mutex = *mutex;
a000a4bc: e58a3014 str r3, [sl, #20]
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a000a4c0: e3a03001 mov r3, #1
a000a4c4: e58a3048 str r3, [sl, #72] ; 0x48
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue );
_Thread_Executing->Wait.return_code = 0;
a000a4c8: e5963004 ldr r3, [r6, #4]
_Thread_Executing->Wait.queue = &the_cond->Wait_queue;
_Thread_Executing->Wait.id = *cond;
_Thread_queue_Enqueue( &the_cond->Wait_queue, timeout );
a000a4cc: e1a01007 mov r1, r7
if ( !already_timedout ) {
the_cond->Mutex = *mutex;
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue );
_Thread_Executing->Wait.return_code = 0;
a000a4d0: e5838034 str r8, [r3, #52] ; 0x34
_Thread_Executing->Wait.queue = &the_cond->Wait_queue;
_Thread_Executing->Wait.id = *cond;
a000a4d4: e5952000 ldr r2, [r5]
if ( !already_timedout ) {
the_cond->Mutex = *mutex;
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue );
_Thread_Executing->Wait.return_code = 0;
_Thread_Executing->Wait.queue = &the_cond->Wait_queue;
a000a4d8: e5830044 str r0, [r3, #68] ; 0x44
_Thread_Executing->Wait.id = *cond;
a000a4dc: e5832020 str r2, [r3, #32]
_Thread_queue_Enqueue( &the_cond->Wait_queue, timeout );
a000a4e0: e59f2048 ldr r2, [pc, #72] ; a000a530 <_POSIX_Condition_variables_Wait_support+0x108>
a000a4e4: eb000db4 bl a000dbbc <_Thread_queue_Enqueue_with_handler>
_Thread_Enable_dispatch();
a000a4e8: eb000c8a bl a000d718 <_Thread_Enable_dispatch>
* a POSIX signal, then pthread_cond_wait returns spuriously,
* according to the POSIX standard. It means that pthread_cond_wait
* returns a success status, except for the fact that it was not
* woken up a pthread_cond_signal or a pthread_cond_broadcast.
*/
status = _Thread_Executing->Wait.return_code;
a000a4ec: e5963004 ldr r3, [r6, #4] <== NOT EXECUTED
a000a4f0: e5935034 ldr r5, [r3, #52] ; 0x34 <== NOT EXECUTED
if ( status == EINTR )
status = 0;
a000a4f4: e3550004 cmp r5, #4 <== NOT EXECUTED
a000a4f8: 03a05000 moveq r5, #0 <== NOT EXECUTED
a000a4fc: ea000001 b a000a508 <_POSIX_Condition_variables_Wait_support+0xe0><== NOT EXECUTED
} else {
_Thread_Enable_dispatch();
a000a500: eb000c84 bl a000d718 <_Thread_Enable_dispatch> <== NOT EXECUTED
status = ETIMEDOUT;
a000a504: e3a05074 mov r5, #116 ; 0x74 <== NOT EXECUTED
/*
* When we get here the dispatch disable level is 0.
*/
mutex_status = pthread_mutex_lock( mutex );
a000a508: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a50c: eb0000ab bl a000a7c0 <pthread_mutex_lock> <== NOT EXECUTED
if ( mutex_status )
return EINVAL;
a000a510: e3500000 cmp r0, #0 <== NOT EXECUTED
a000a514: 13a05016 movne r5, #22 <== NOT EXECUTED
a000a518: ea000000 b a000a520 <_POSIX_Condition_variables_Wait_support+0xf8><== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000a51c: e3a05016 mov r5, #22 <== NOT EXECUTED
}
a000a520: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a524: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
a00108d4 <_POSIX_Keys_Run_destructors>:
*/
void _POSIX_Keys_Run_destructors(
Thread_Control *thread
)
{
a00108d4: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr}
Objects_Maximum thread_index = _Objects_Get_index( thread->Object.id );
a00108d8: e5907008 ldr r7, [r0, #8]
*
* Reference: 17.1.1.2 P1003.1c/Draft 10, p. 163, line 99.
*/
while ( !done ) {
Objects_Maximum index = 0;
Objects_Maximum max = _POSIX_Keys_Information.maximum;
a00108dc: e59f607c ldr r6, [pc, #124] ; a0010960 <_POSIX_Keys_Run_destructors+0x8c>
if ( key != NULL && key->destructor != NULL ) {
void *value = key->Values [ thread_api ][ thread_index ];
if ( value != NULL ) {
key->Values [ thread_api ][ thread_index ] = NULL;
a00108e0: e3a05000 mov r5, #0
a00108e4: e1a08c27 lsr r8, r7, #24
for ( index = 1 ; index <= max ; ++index ) {
POSIX_Keys_Control *key = (POSIX_Keys_Control *)
_POSIX_Keys_Information.local_table [ index ];
if ( key != NULL && key->destructor != NULL ) {
void *value = key->Values [ thread_api ][ thread_index ];
a00108e8: e1a07807 lsl r7, r7, #16
a00108ec: e2088007 and r8, r8, #7
a00108f0: e1a07727 lsr r7, r7, #14
Objects_Maximum index = 0;
Objects_Maximum max = _POSIX_Keys_Information.maximum;
done = true;
for ( index = 1 ; index <= max ; ++index ) {
a00108f4: e3a04001 mov r4, #1
*
* Reference: 17.1.1.2 P1003.1c/Draft 10, p. 163, line 99.
*/
while ( !done ) {
Objects_Maximum index = 0;
Objects_Maximum max = _POSIX_Keys_Information.maximum;
a00108f8: e1d6a1b0 ldrh sl, [r6, #16]
done = true;
a00108fc: e1a01004 mov r1, r4
for ( index = 1 ; index <= max ; ++index ) {
a0010900: ea000011 b a001094c <_POSIX_Keys_Run_destructors+0x78>
POSIX_Keys_Control *key = (POSIX_Keys_Control *)
_POSIX_Keys_Information.local_table [ index ];
a0010904: e596301c ldr r3, [r6, #28]
Objects_Maximum max = _POSIX_Keys_Information.maximum;
done = true;
for ( index = 1 ; index <= max ; ++index ) {
POSIX_Keys_Control *key = (POSIX_Keys_Control *)
a0010908: e7932104 ldr r2, [r3, r4, lsl #2]
_POSIX_Keys_Information.local_table [ index ];
if ( key != NULL && key->destructor != NULL ) {
a001090c: e3520000 cmp r2, #0
a0010910: 0a00000a beq a0010940 <_POSIX_Keys_Run_destructors+0x6c>
a0010914: e5923010 ldr r3, [r2, #16]
a0010918: e3530000 cmp r3, #0
a001091c: 0a000007 beq a0010940 <_POSIX_Keys_Run_destructors+0x6c>
void *value = key->Values [ thread_api ][ thread_index ];
a0010920: e2880005 add r0, r8, #5 <== NOT EXECUTED
a0010924: e7922100 ldr r2, [r2, r0, lsl #2] <== NOT EXECUTED
a0010928: e7920007 ldr r0, [r2, r7] <== NOT EXECUTED
if ( value != NULL ) {
a001092c: e3500000 cmp r0, #0 <== NOT EXECUTED
a0010930: 0a000002 beq a0010940 <_POSIX_Keys_Run_destructors+0x6c> <== NOT EXECUTED
key->Values [ thread_api ][ thread_index ] = NULL;
a0010934: e7825007 str r5, [r2, r7] <== NOT EXECUTED
(*key->destructor)( value );
a0010938: e12fff33 blx r3 <== NOT EXECUTED
done = false;
a001093c: e1a01005 mov r1, r5 <== NOT EXECUTED
Objects_Maximum index = 0;
Objects_Maximum max = _POSIX_Keys_Information.maximum;
done = true;
for ( index = 1 ; index <= max ; ++index ) {
a0010940: e2844001 add r4, r4, #1
a0010944: e1a04804 lsl r4, r4, #16
a0010948: e1a04824 lsr r4, r4, #16
a001094c: e154000a cmp r4, sl
a0010950: 9affffeb bls a0010904 <_POSIX_Keys_Run_destructors+0x30>
* number of iterations. An infinite loop may happen if destructors set
* thread specific data. This can be considered dubious.
*
* Reference: 17.1.1.2 P1003.1c/Draft 10, p. 163, line 99.
*/
while ( !done ) {
a0010954: e3510000 cmp r1, #0
a0010958: 0affffe5 beq a00108f4 <_POSIX_Keys_Run_destructors+0x20>
done = false;
}
}
}
}
}
a001095c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
a0014fcc <_POSIX_Message_queue_Create_support>:
const char *name_arg,
int pshared,
struct mq_attr *attr_ptr,
POSIX_Message_queue_Control **message_queue
)
{
a0014fcc: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
a0014fd0: e1a06001 mov r6, r1
CORE_message_queue_Attributes *the_mq_attr;
struct mq_attr attr;
char *name;
size_t n;
n = strnlen( name_arg, NAME_MAX );
a0014fd4: e3a010ff mov r1, #255 ; 0xff
const char *name_arg,
int pshared,
struct mq_attr *attr_ptr,
POSIX_Message_queue_Control **message_queue
)
{
a0014fd8: e1a04002 mov r4, r2
a0014fdc: e1a0b003 mov fp, r3
a0014fe0: e1a09000 mov r9, r0
CORE_message_queue_Attributes *the_mq_attr;
struct mq_attr attr;
char *name;
size_t n;
n = strnlen( name_arg, NAME_MAX );
a0014fe4: eb0015ce bl a001a724 <strnlen>
a0014fe8: e59f3128 ldr r3, [pc, #296] ; a0015118 <_POSIX_Message_queue_Create_support+0x14c>
a0014fec: e1a07000 mov r7, r0
a0014ff0: e5932000 ldr r2, [r3]
a0014ff4: e2822001 add r2, r2, #1
a0014ff8: e5832000 str r2, [r3]
* There is no real basis for the default values. They will work
* but were not compared against any existing implementation for
* compatibility. See README.mqueue for an example program we
* think will print out the defaults. Report anything you find with it.
*/
if ( attr_ptr == NULL ) {
a0014ffc: e3540000 cmp r4, #0
a0015000: 0a000009 beq a001502c <_POSIX_Message_queue_Create_support+0x60>
attr.mq_maxmsg = 10;
attr.mq_msgsize = 16;
} else {
if ( attr_ptr->mq_maxmsg <= 0 ){
a0015004: e594a004 ldr sl, [r4, #4]
a0015008: e35a0000 cmp sl, #0
a001500c: da000002 ble a001501c <_POSIX_Message_queue_Create_support+0x50>
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( EINVAL );
}
if ( attr_ptr->mq_msgsize <= 0 ){
a0015010: e5948008 ldr r8, [r4, #8]
a0015014: e3580000 cmp r8, #0
a0015018: ca000005 bgt a0015034 <_POSIX_Message_queue_Create_support+0x68>
_Thread_Enable_dispatch();
a001501c: ebfff4e9 bl a00123c8 <_Thread_Enable_dispatch>
rtems_set_errno_and_return_minus_one( EINVAL );
a0015020: eb000daa bl a00186d0 <__errno>
a0015024: e3a03016 mov r3, #22
a0015028: ea00002f b a00150ec <_POSIX_Message_queue_Create_support+0x120>
* compatibility. See README.mqueue for an example program we
* think will print out the defaults. Report anything you find with it.
*/
if ( attr_ptr == NULL ) {
attr.mq_maxmsg = 10;
attr.mq_msgsize = 16;
a001502c: e3a08010 mov r8, #16 <== NOT EXECUTED
* but were not compared against any existing implementation for
* compatibility. See README.mqueue for an example program we
* think will print out the defaults. Report anything you find with it.
*/
if ( attr_ptr == NULL ) {
attr.mq_maxmsg = 10;
a0015030: e3a0a00a mov sl, #10 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE
POSIX_Message_queue_Control *_POSIX_Message_queue_Allocate( void )
{
return (POSIX_Message_queue_Control *)
_Objects_Allocate( &_POSIX_Message_queue_Information );
a0015034: e59f50e0 ldr r5, [pc, #224] ; a001511c <_POSIX_Message_queue_Create_support+0x150>
a0015038: e1a00005 mov r0, r5
a001503c: ebfff0e5 bl a00113d8 <_Objects_Allocate>
attr = *attr_ptr;
}
the_mq = _POSIX_Message_queue_Allocate();
if ( !the_mq ) {
a0015040: e2504000 subs r4, r0, #0
a0015044: 1a000003 bne a0015058 <_POSIX_Message_queue_Create_support+0x8c>
_Thread_Enable_dispatch();
a0015048: ebfff4de bl a00123c8 <_Thread_Enable_dispatch>
rtems_set_errno_and_return_minus_one( ENFILE );
a001504c: eb000d9f bl a00186d0 <__errno>
a0015050: e3a03017 mov r3, #23
a0015054: ea000024 b a00150ec <_POSIX_Message_queue_Create_support+0x120>
}
the_mq->process_shared = pshared;
the_mq->named = true;
a0015058: e3a03001 mov r3, #1
if ( !the_mq ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( ENFILE );
}
the_mq->process_shared = pshared;
a001505c: e5846010 str r6, [r4, #16]
/*
* Make a copy of the user's string for name just in case it was
* dynamically constructed.
*/
name = _Workspace_Allocate(n+1);
a0015060: e0876003 add r6, r7, r3
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( ENFILE );
}
the_mq->process_shared = pshared;
the_mq->named = true;
a0015064: e5c43014 strb r3, [r4, #20]
the_mq->open_count = 1;
a0015068: e5843018 str r3, [r4, #24]
the_mq->linked = true;
a001506c: e5c43015 strb r3, [r4, #21]
/*
* Make a copy of the user's string for name just in case it was
* dynamically constructed.
*/
name = _Workspace_Allocate(n+1);
a0015070: e1a00006 mov r0, r6
a0015074: ebfff95c bl a00135ec <_Workspace_Allocate>
if (!name) {
a0015078: e2507000 subs r7, r0, #0
a001507c: 1a000006 bne a001509c <_POSIX_Message_queue_Create_support+0xd0>
RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Free (
POSIX_Message_queue_Control *the_mq
)
{
_Objects_Free( &_POSIX_Message_queue_Information, &the_mq->Object );
a0015080: e1a00005 mov r0, r5
a0015084: e1a01004 mov r1, r4
a0015088: ebfff19b bl a00116fc <_Objects_Free>
_POSIX_Message_queue_Free( the_mq );
_Thread_Enable_dispatch();
a001508c: ebfff4cd bl a00123c8 <_Thread_Enable_dispatch>
rtems_set_errno_and_return_minus_one( ENOMEM );
a0015090: eb000d8e bl a00186d0 <__errno>
a0015094: e3a0300c mov r3, #12
a0015098: ea000013 b a00150ec <_POSIX_Message_queue_Create_support+0x120>
}
strncpy( name, name_arg, n+1 );
a001509c: e1a02006 mov r2, r6
a00150a0: e1a01009 mov r1, r9
*
* Joel: Cite POSIX or OpenGroup on above statement so we can determine
* if it is a real requirement.
*/
the_mq_attr = &the_mq->Message_queue.Attributes;
the_mq_attr->discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_FIFO;
a00150a4: e3a06000 mov r6, #0
if (!name) {
_POSIX_Message_queue_Free( the_mq );
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( ENOMEM );
}
strncpy( name, name_arg, n+1 );
a00150a8: eb001562 bl a001a638 <strncpy>
*
* Joel: Cite POSIX or OpenGroup on above statement so we can determine
* if it is a real requirement.
*/
the_mq_attr = &the_mq->Message_queue.Attributes;
the_mq_attr->discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_FIFO;
a00150ac: e584605c str r6, [r4, #92] ; 0x5c
if ( !_CORE_message_queue_Initialize(
a00150b0: e284001c add r0, r4, #28
a00150b4: e284105c add r1, r4, #92 ; 0x5c
a00150b8: e1a0200a mov r2, sl
a00150bc: e1a03008 mov r3, r8
a00150c0: eb0003d0 bl a0016008 <_CORE_message_queue_Initialize>
a00150c4: e1500006 cmp r0, r6
a00150c8: 1a00000a bne a00150f8 <_POSIX_Message_queue_Create_support+0x12c>
a00150cc: e1a01004 mov r1, r4 <== NOT EXECUTED
a00150d0: e1a00005 mov r0, r5 <== NOT EXECUTED
a00150d4: ebfff188 bl a00116fc <_Objects_Free> <== NOT EXECUTED
attr.mq_maxmsg,
attr.mq_msgsize
) ) {
_POSIX_Message_queue_Free( the_mq );
_Workspace_Free(name);
a00150d8: e1a00007 mov r0, r7 <== NOT EXECUTED
a00150dc: ebfff948 bl a0013604 <_Workspace_Free> <== NOT EXECUTED
_Thread_Enable_dispatch();
a00150e0: ebfff4b8 bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSPC );
a00150e4: eb000d79 bl a00186d0 <__errno> <== NOT EXECUTED
a00150e8: e3a0301c mov r3, #28 <== NOT EXECUTED
a00150ec: e5803000 str r3, [r0]
a00150f0: e3e00000 mvn r0, #0
a00150f4: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a00150f8: e595301c ldr r3, [r5, #28]
Objects_Information *information,
Objects_Control *the_object,
const char *name
)
{
_Objects_Set_local_object(
a00150fc: e1d420b8 ldrh r2, [r4, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0015100: e7834102 str r4, [r3, r2, lsl #2]
the_object
);
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
/* ASSERT: information->is_string */
the_object->name.name_p = name;
a0015104: e584700c str r7, [r4, #12]
&_POSIX_Message_queue_Information,
&the_mq->Object,
name
);
*message_queue = the_mq;
a0015108: e58b4000 str r4, [fp]
_Thread_Enable_dispatch();
a001510c: ebfff4ad bl a00123c8 <_Thread_Enable_dispatch>
return 0;
a0015110: e1a00006 mov r0, r6
}
a0015114: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
a0015120 <_POSIX_Message_queue_Name_to_id>:
*/
int _POSIX_Message_queue_Name_to_id(
const char *name,
Objects_Id *id
)
{
a0015120: e92d4031 push {r0, r4, r5, lr}
Objects_Name_or_id_lookup_errors status;
Objects_Id the_id;
if ( !name )
a0015124: e2505000 subs r5, r0, #0
*/
int _POSIX_Message_queue_Name_to_id(
const char *name,
Objects_Id *id
)
{
a0015128: e1a04001 mov r4, r1
Objects_Name_or_id_lookup_errors status;
Objects_Id the_id;
if ( !name )
a001512c: 0a000011 beq a0015178 <_POSIX_Message_queue_Name_to_id+0x58>
return EINVAL;
if ( !name[0] )
a0015130: e5d53000 ldrb r3, [r5]
a0015134: e3530000 cmp r3, #0
a0015138: 0a00000e beq a0015178 <_POSIX_Message_queue_Name_to_id+0x58>
return EINVAL;
if ( strnlen( name, NAME_MAX ) >= NAME_MAX )
a001513c: e3a010ff mov r1, #255 ; 0xff
a0015140: eb001577 bl a001a724 <strnlen>
a0015144: e35000fe cmp r0, #254 ; 0xfe
return ENAMETOOLONG;
a0015148: 83a0005b movhi r0, #91 ; 0x5b
return EINVAL;
if ( !name[0] )
return EINVAL;
if ( strnlen( name, NAME_MAX ) >= NAME_MAX )
a001514c: 8a00000a bhi a001517c <_POSIX_Message_queue_Name_to_id+0x5c>
return ENAMETOOLONG;
status = _Objects_Name_to_id_string(
a0015150: e59f0028 ldr r0, [pc, #40] ; a0015180 <_POSIX_Message_queue_Name_to_id+0x60>
a0015154: e1a01005 mov r1, r5
a0015158: e1a0200d mov r2, sp
a001515c: eb000571 bl a0016728 <_Objects_Name_to_id_string>
&_POSIX_Message_queue_Information,
name,
&the_id
);
*id = the_id;
a0015160: e59d3000 ldr r3, [sp]
if ( status == OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL )
return 0;
a0015164: e3500000 cmp r0, #0
a0015168: 13a00002 movne r0, #2
status = _Objects_Name_to_id_string(
&_POSIX_Message_queue_Information,
name,
&the_id
);
*id = the_id;
a001516c: e5843000 str r3, [r4]
if ( status == OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL )
return 0;
a0015170: 03a00000 moveq r0, #0
a0015174: ea000000 b a001517c <_POSIX_Message_queue_Name_to_id+0x5c>
if ( !name )
return EINVAL;
if ( !name[0] )
return EINVAL;
a0015178: e3a00016 mov r0, #22 <== NOT EXECUTED
if ( status == OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL )
return 0;
return ENOENT;
}
a001517c: e8bd8038 pop {r3, r4, r5, pc}
a000e6c4 <_POSIX_Message_queue_Notify_handler>:
*/
void _POSIX_Message_queue_Notify_handler(
void *user_data
)
{
a000e6c4: e92d4010 push {r4, lr} <== NOT EXECUTED
a000e6c8: e1a04000 mov r4, r0 <== NOT EXECUTED
POSIX_Message_queue_Control *the_mq;
the_mq = user_data;
kill( getpid(), the_mq->notification.sigev_signo );
a000e6cc: eb0018a1 bl a0014958 <getpid> <== NOT EXECUTED
a000e6d0: e5941094 ldr r1, [r4, #148] ; 0x94 <== NOT EXECUTED
a000e6d4: eb001a3a bl a0014fc4 <kill> <== NOT EXECUTED
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Notify_Handler the_handler,
void *the_argument
)
{
the_message_queue->notify_handler = the_handler;
a000e6d8: e3a03000 mov r3, #0 <== NOT EXECUTED
a000e6dc: e584307c str r3, [r4, #124] ; 0x7c <== NOT EXECUTED
the_message_queue->notify_argument = the_argument;
a000e6e0: e5843080 str r3, [r4, #128] ; 0x80 <== NOT EXECUTED
_CORE_message_queue_Set_notify( &the_mq->Message_queue, NULL, NULL );
}
a000e6e4: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000e92c <_POSIX_Message_queue_Receive_support>:
size_t msg_len,
unsigned int *msg_prio,
bool wait,
Watchdog_Interval timeout
)
{
a000e92c: e92d41ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, lr} <== NOT EXECUTED
a000e930: e1a04000 mov r4, r0 <== NOT EXECUTED
a000e934: e1a06001 mov r6, r1 <== NOT EXECUTED
a000e938: e1a07002 mov r7, r2 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *_POSIX_Message_queue_Get_fd (
mqd_t id,
Objects_Locations *location
)
{
return (POSIX_Message_queue_Control_fd *) _Objects_Get(
a000e93c: e59f00f0 ldr r0, [pc, #240] ; a000ea34 <_POSIX_Message_queue_Receive_support+0x108><== NOT EXECUTED
a000e940: e1a01004 mov r1, r4 <== NOT EXECUTED
a000e944: e28d200c add r2, sp, #12 <== NOT EXECUTED
a000e948: e1a05003 mov r5, r3 <== NOT EXECUTED
a000e94c: e5dd8028 ldrb r8, [sp, #40] ; 0x28 <== NOT EXECUTED
a000e950: eb000bc1 bl a001185c <_Objects_Get> <== NOT EXECUTED
Objects_Locations location;
size_t length_out;
bool do_wait;
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
a000e954: e59d300c ldr r3, [sp, #12] <== NOT EXECUTED
a000e958: e3530000 cmp r3, #0 <== NOT EXECUTED
a000e95c: 1a00002e bne a000ea1c <_POSIX_Message_queue_Receive_support+0xf0><== NOT EXECUTED
case OBJECTS_LOCAL:
if ( (the_mq_fd->oflag & O_ACCMODE) == O_WRONLY ) {
a000e960: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED
a000e964: e2032003 and r2, r3, #3 <== NOT EXECUTED
a000e968: e3520001 cmp r2, #1 <== NOT EXECUTED
a000e96c: 1a000001 bne a000e978 <_POSIX_Message_queue_Receive_support+0x4c><== NOT EXECUTED
_Thread_Enable_dispatch();
a000e970: eb000e94 bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
a000e974: ea000028 b a000ea1c <_POSIX_Message_queue_Receive_support+0xf0><== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EBADF );
}
the_mq = the_mq_fd->Queue;
a000e978: e5900010 ldr r0, [r0, #16] <== NOT EXECUTED
if ( msg_len < the_mq->Message_queue.maximum_message_size ) {
a000e97c: e5902068 ldr r2, [r0, #104] ; 0x68 <== NOT EXECUTED
a000e980: e1570002 cmp r7, r2 <== NOT EXECUTED
a000e984: 2a000003 bcs a000e998 <_POSIX_Message_queue_Receive_support+0x6c><== NOT EXECUTED
_Thread_Enable_dispatch();
a000e988: eb000e8e bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EMSGSIZE );
a000e98c: eb00274f bl a00186d0 <__errno> <== NOT EXECUTED
a000e990: e3a0307a mov r3, #122 ; 0x7a <== NOT EXECUTED
a000e994: ea000022 b a000ea24 <_POSIX_Message_queue_Receive_support+0xf8><== NOT EXECUTED
/*
* Now if something goes wrong, we return a "length" of -1
* to indicate an error.
*/
length_out = -1;
a000e998: e3e02000 mvn r2, #0 <== NOT EXECUTED
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
a000e99c: e3580000 cmp r8, #0 <== NOT EXECUTED
/*
* Now if something goes wrong, we return a "length" of -1
* to indicate an error.
*/
length_out = -1;
a000e9a0: e58d2008 str r2, [sp, #8] <== NOT EXECUTED
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
a000e9a4: 0a000002 beq a000e9b4 <_POSIX_Message_queue_Receive_support+0x88><== NOT EXECUTED
do_wait = (the_mq_fd->oflag & O_NONBLOCK) ? false : true;
a000e9a8: e3130901 tst r3, #16384 ; 0x4000 <== NOT EXECUTED
a000e9ac: 13a08000 movne r8, #0 <== NOT EXECUTED
a000e9b0: 03a08001 moveq r8, #1 <== NOT EXECUTED
do_wait = wait;
/*
* Now perform the actual message receive
*/
_CORE_message_queue_Seize(
a000e9b4: e59d302c ldr r3, [sp, #44] ; 0x2c <== NOT EXECUTED
a000e9b8: e1a01004 mov r1, r4 <== NOT EXECUTED
timeout
);
_Thread_Enable_dispatch();
*msg_prio =
_POSIX_Message_queue_Priority_from_core(_Thread_Executing->Wait.count);
a000e9bc: e59f4074 ldr r4, [pc, #116] ; a000ea38 <_POSIX_Message_queue_Receive_support+0x10c><== NOT EXECUTED
do_wait = wait;
/*
* Now perform the actual message receive
*/
_CORE_message_queue_Seize(
a000e9c0: e280001c add r0, r0, #28 <== NOT EXECUTED
a000e9c4: e1a02006 mov r2, r6 <== NOT EXECUTED
a000e9c8: e58d3004 str r3, [sp, #4] <== NOT EXECUTED
a000e9cc: e28d3008 add r3, sp, #8 <== NOT EXECUTED
a000e9d0: e58d8000 str r8, [sp] <== NOT EXECUTED
a000e9d4: eb0007a8 bl a001087c <_CORE_message_queue_Seize> <== NOT EXECUTED
&length_out,
do_wait,
timeout
);
_Thread_Enable_dispatch();
a000e9d8: eb000e7a bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
*msg_prio =
_POSIX_Message_queue_Priority_from_core(_Thread_Executing->Wait.count);
a000e9dc: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE unsigned int _POSIX_Message_queue_Priority_from_core(
CORE_message_queue_Submit_types priority
)
{
/* absolute value without a library dependency */
return ((priority >= 0) ? priority : -priority);
a000e9e0: e5932024 ldr r2, [r3, #36] ; 0x24 <== NOT EXECUTED
if ( !_Thread_Executing->Wait.return_code )
a000e9e4: e5933034 ldr r3, [r3, #52] ; 0x34 <== NOT EXECUTED
a000e9e8: e3520000 cmp r2, #0 <== NOT EXECUTED
a000e9ec: b2622000 rsblt r2, r2, #0 <== NOT EXECUTED
a000e9f0: e3530000 cmp r3, #0 <== NOT EXECUTED
do_wait,
timeout
);
_Thread_Enable_dispatch();
*msg_prio =
a000e9f4: e5852000 str r2, [r5] <== NOT EXECUTED
_POSIX_Message_queue_Priority_from_core(_Thread_Executing->Wait.count);
if ( !_Thread_Executing->Wait.return_code )
return length_out;
a000e9f8: 059d0008 ldreq r0, [sp, #8] <== NOT EXECUTED
_Thread_Enable_dispatch();
*msg_prio =
_POSIX_Message_queue_Priority_from_core(_Thread_Executing->Wait.count);
if ( !_Thread_Executing->Wait.return_code )
a000e9fc: 0a00000a beq a000ea2c <_POSIX_Message_queue_Receive_support+0x100><== NOT EXECUTED
return length_out;
rtems_set_errno_and_return_minus_one(
a000ea00: eb002732 bl a00186d0 <__errno> <== NOT EXECUTED
a000ea04: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED
a000ea08: e1a05000 mov r5, r0 <== NOT EXECUTED
a000ea0c: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a000ea10: eb00009b bl a000ec84 <_POSIX_Message_queue_Translate_core_message_queue_return_code><== NOT EXECUTED
a000ea14: e5850000 str r0, [r5] <== NOT EXECUTED
a000ea18: ea000002 b a000ea28 <_POSIX_Message_queue_Receive_support+0xfc><== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EBADF );
a000ea1c: eb00272b bl a00186d0 <__errno> <== NOT EXECUTED
a000ea20: e3a03009 mov r3, #9 <== NOT EXECUTED
a000ea24: e5803000 str r3, [r0] <== NOT EXECUTED
a000ea28: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000ea2c: e28dd010 add sp, sp, #16 <== NOT EXECUTED
a000ea30: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
a000ea58 <_POSIX_Message_queue_Send_support>:
size_t msg_len,
uint32_t msg_prio,
bool wait,
Watchdog_Interval timeout
)
{
a000ea58: e92d41f0 push {r4, r5, r6, r7, r8, lr}
/*
* Validate the priority.
* XXX - Do not validate msg_prio is not less than 0.
*/
if ( msg_prio > MQ_PRIO_MAX )
a000ea5c: e3530020 cmp r3, #32
size_t msg_len,
uint32_t msg_prio,
bool wait,
Watchdog_Interval timeout
)
{
a000ea60: e24dd014 sub sp, sp, #20
a000ea64: e1a04000 mov r4, r0
a000ea68: e1a06001 mov r6, r1
a000ea6c: e1a05002 mov r5, r2
a000ea70: e1a07003 mov r7, r3
a000ea74: e5dd802c ldrb r8, [sp, #44] ; 0x2c
/*
* Validate the priority.
* XXX - Do not validate msg_prio is not less than 0.
*/
if ( msg_prio > MQ_PRIO_MAX )
a000ea78: 9a000002 bls a000ea88 <_POSIX_Message_queue_Send_support+0x30>
rtems_set_errno_and_return_minus_one( EINVAL );
a000ea7c: eb002713 bl a00186d0 <__errno> <== NOT EXECUTED
a000ea80: e3a03016 mov r3, #22 <== NOT EXECUTED
a000ea84: ea00002d b a000eb40 <_POSIX_Message_queue_Send_support+0xe8><== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *_POSIX_Message_queue_Get_fd (
mqd_t id,
Objects_Locations *location
)
{
return (POSIX_Message_queue_Control_fd *) _Objects_Get(
a000ea88: e59f00c0 ldr r0, [pc, #192] ; a000eb50 <_POSIX_Message_queue_Send_support+0xf8>
a000ea8c: e1a01004 mov r1, r4
a000ea90: e28d2010 add r2, sp, #16
a000ea94: eb000b70 bl a001185c <_Objects_Get>
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
a000ea98: e59d3010 ldr r3, [sp, #16]
a000ea9c: e3530000 cmp r3, #0
a000eaa0: 1a000024 bne a000eb38 <_POSIX_Message_queue_Send_support+0xe0>
case OBJECTS_LOCAL:
if ( (the_mq_fd->oflag & O_ACCMODE) == O_RDONLY ) {
a000eaa4: e5903014 ldr r3, [r0, #20]
a000eaa8: e3130003 tst r3, #3
a000eaac: 1a000001 bne a000eab8 <_POSIX_Message_queue_Send_support+0x60>
_Thread_Enable_dispatch();
a000eab0: eb000e44 bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
a000eab4: ea00001f b a000eb38 <_POSIX_Message_queue_Send_support+0xe0><== NOT EXECUTED
the_mq = the_mq_fd->Queue;
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
a000eab8: e3580000 cmp r8, #0
if ( (the_mq_fd->oflag & O_ACCMODE) == O_RDONLY ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( EBADF );
}
the_mq = the_mq_fd->Queue;
a000eabc: e5900010 ldr r0, [r0, #16]
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
a000eac0: 0a000002 beq a000ead0 <_POSIX_Message_queue_Send_support+0x78>
do_wait = (the_mq_fd->oflag & O_NONBLOCK) ? false : true;
a000eac4: e3130901 tst r3, #16384 ; 0x4000
a000eac8: 13a08000 movne r8, #0
a000eacc: 03a08001 moveq r8, #1
do_wait = wait;
/*
* Now perform the actual message receive
*/
msg_status = _CORE_message_queue_Submit(
a000ead0: e3a03000 mov r3, #0
a000ead4: e58d3000 str r3, [sp]
a000ead8: e59d3030 ldr r3, [sp, #48] ; 0x30
a000eadc: e1a01006 mov r1, r6
a000eae0: e1a02005 mov r2, r5
a000eae4: e58d300c str r3, [sp, #12]
RTEMS_INLINE_ROUTINE CORE_message_queue_Submit_types _POSIX_Message_queue_Priority_to_core(
unsigned int priority
)
{
return priority * -1;
a000eae8: e2677000 rsb r7, r7, #0
a000eaec: e1a03004 mov r3, r4
a000eaf0: e280001c add r0, r0, #28
a000eaf4: e98d0180 stmib sp, {r7, r8}
a000eaf8: eb0007ab bl a00109ac <_CORE_message_queue_Submit>
a000eafc: e1a04000 mov r4, r0
_POSIX_Message_queue_Priority_to_core( msg_prio ),
do_wait,
timeout /* no timeout */
);
_Thread_Enable_dispatch();
a000eb00: eb000e30 bl a00123c8 <_Thread_Enable_dispatch>
* after it wakes up. The returned status is correct for
* non-blocking operations but if we blocked, then we need
* to look at the status in our TCB.
*/
if ( msg_status == CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT )
a000eb04: e3540007 cmp r4, #7
msg_status = _Thread_Executing->Wait.return_code;
a000eb08: 059f3044 ldreq r3, [pc, #68] ; a000eb54 <_POSIX_Message_queue_Send_support+0xfc>
a000eb0c: 05933004 ldreq r3, [r3, #4]
a000eb10: 05934034 ldreq r4, [r3, #52] ; 0x34
if ( !msg_status )
a000eb14: e3540000 cmp r4, #0
return msg_status;
a000eb18: 01a00004 moveq r0, r4
*/
if ( msg_status == CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT )
msg_status = _Thread_Executing->Wait.return_code;
if ( !msg_status )
a000eb1c: 0a000009 beq a000eb48 <_POSIX_Message_queue_Send_support+0xf0>
return msg_status;
rtems_set_errno_and_return_minus_one(
a000eb20: eb0026ea bl a00186d0 <__errno> <== NOT EXECUTED
a000eb24: e1a05000 mov r5, r0 <== NOT EXECUTED
a000eb28: e1a00004 mov r0, r4 <== NOT EXECUTED
a000eb2c: eb000054 bl a000ec84 <_POSIX_Message_queue_Translate_core_message_queue_return_code><== NOT EXECUTED
a000eb30: e5850000 str r0, [r5] <== NOT EXECUTED
a000eb34: ea000002 b a000eb44 <_POSIX_Message_queue_Send_support+0xec><== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EBADF );
a000eb38: eb0026e4 bl a00186d0 <__errno> <== NOT EXECUTED
a000eb3c: e3a03009 mov r3, #9 <== NOT EXECUTED
a000eb40: e5803000 str r3, [r0] <== NOT EXECUTED
a000eb44: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000eb48: e28dd014 add sp, sp, #20
a000eb4c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a000ec84 <_POSIX_Message_queue_Translate_core_message_queue_return_code>:
#if defined(RTEMS_DEBUG)
if ( the_message_queue_status > CORE_MESSAGE_QUEUE_STATUS_LAST )
return EINVAL;
#endif
return _POSIX_Message_queue_Return_codes[the_message_queue_status];
}
a000ec84: e59f3004 ldr r3, [pc, #4] ; a000ec90 <_POSIX_Message_queue_Translate_core_message_queue_return_code+0xc><== NOT EXECUTED
a000ec88: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED
a000ec8c: e12fff1e bx lr <== NOT EXECUTED
a000b654 <_POSIX_Mutex_Get>:
POSIX_Mutex_Control *_POSIX_Mutex_Get (
pthread_mutex_t *mutex,
Objects_Locations *location
)
{
a000b654: e92d4030 push {r4, r5, lr}
___POSIX_Mutex_Get_support_error_check( mutex, location );
a000b658: e2505000 subs r5, r0, #0
POSIX_Mutex_Control *_POSIX_Mutex_Get (
pthread_mutex_t *mutex,
Objects_Locations *location
)
{
a000b65c: e1a04001 mov r4, r1
___POSIX_Mutex_Get_support_error_check( mutex, location );
a000b660: 1a000003 bne a000b674 <_POSIX_Mutex_Get+0x20>
a000b664: e3a03001 mov r3, #1 <== NOT EXECUTED
a000b668: e5813000 str r3, [r1] <== NOT EXECUTED
a000b66c: e1a00005 mov r0, r5 <== NOT EXECUTED
a000b670: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
___POSIX_Mutex_Get_support_auto_initialization( mutex, location );
a000b674: e5953000 ldr r3, [r5]
a000b678: e3730001 cmn r3, #1
a000b67c: 1a000007 bne a000b6a0 <_POSIX_Mutex_Get+0x4c>
a000b680: e3a01000 mov r1, #0
a000b684: eb000039 bl a000b770 <pthread_mutex_init>
a000b688: e3500000 cmp r0, #0
a000b68c: 0a000003 beq a000b6a0 <_POSIX_Mutex_Get+0x4c>
a000b690: e3a03001 mov r3, #1
a000b694: e5843000 str r3, [r4]
a000b698: e3a00000 mov r0, #0
a000b69c: e8bd8030 pop {r4, r5, pc}
return (POSIX_Mutex_Control *)
_Objects_Get( &_POSIX_Mutex_Information, (Objects_Id) *mutex, location );
a000b6a0: e59f000c ldr r0, [pc, #12] ; a000b6b4 <_POSIX_Mutex_Get+0x60>
a000b6a4: e5951000 ldr r1, [r5]
a000b6a8: e1a02004 mov r2, r4
}
a000b6ac: e8bd4030 pop {r4, r5, lr}
___POSIX_Mutex_Get_support_error_check( mutex, location );
___POSIX_Mutex_Get_support_auto_initialization( mutex, location );
return (POSIX_Mutex_Control *)
_Objects_Get( &_POSIX_Mutex_Information, (Objects_Id) *mutex, location );
a000b6b0: ea000a72 b a000e080 <_Objects_Get>
a000b6b8 <_POSIX_Mutex_Get_interrupt_disable>:
POSIX_Mutex_Control *_POSIX_Mutex_Get_interrupt_disable (
pthread_mutex_t *mutex,
Objects_Locations *location,
ISR_Level *level
)
{
a000b6b8: e92d4070 push {r4, r5, r6, lr}
___POSIX_Mutex_Get_support_error_check( mutex, location );
a000b6bc: e2506000 subs r6, r0, #0
POSIX_Mutex_Control *_POSIX_Mutex_Get_interrupt_disable (
pthread_mutex_t *mutex,
Objects_Locations *location,
ISR_Level *level
)
{
a000b6c0: e1a04001 mov r4, r1
a000b6c4: e1a05002 mov r5, r2
___POSIX_Mutex_Get_support_error_check( mutex, location );
a000b6c8: 1a000003 bne a000b6dc <_POSIX_Mutex_Get_interrupt_disable+0x24>
a000b6cc: e3a03001 mov r3, #1 <== NOT EXECUTED
a000b6d0: e5813000 str r3, [r1] <== NOT EXECUTED
a000b6d4: e1a00006 mov r0, r6 <== NOT EXECUTED
a000b6d8: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
___POSIX_Mutex_Get_support_auto_initialization( mutex, location );
a000b6dc: e5963000 ldr r3, [r6]
a000b6e0: e3730001 cmn r3, #1
a000b6e4: 1a000007 bne a000b708 <_POSIX_Mutex_Get_interrupt_disable+0x50>
a000b6e8: e3a01000 mov r1, #0
a000b6ec: eb00001f bl a000b770 <pthread_mutex_init>
a000b6f0: e3500000 cmp r0, #0
a000b6f4: 0a000003 beq a000b708 <_POSIX_Mutex_Get_interrupt_disable+0x50>
a000b6f8: e3a03001 mov r3, #1
a000b6fc: e5843000 str r3, [r4]
a000b700: e3a00000 mov r0, #0
a000b704: e8bd8070 pop {r4, r5, r6, pc}
return (POSIX_Mutex_Control *) _Objects_Get_isr_disable(
a000b708: e59f0010 ldr r0, [pc, #16] ; a000b720 <_POSIX_Mutex_Get_interrupt_disable+0x68>
a000b70c: e5961000 ldr r1, [r6]
a000b710: e1a02004 mov r2, r4
a000b714: e1a03005 mov r3, r5
&_POSIX_Mutex_Information,
(Objects_Id) *mutex,
location,
level
);
}
a000b718: e8bd4070 pop {r4, r5, r6, lr}
{
___POSIX_Mutex_Get_support_error_check( mutex, location );
___POSIX_Mutex_Get_support_auto_initialization( mutex, location );
return (POSIX_Mutex_Control *) _Objects_Get_isr_disable(
a000b71c: ea000a3c b a000e014 <_Objects_Get_isr_disable>
a000f7e4 <_POSIX_Priority_Is_valid>:
bool _POSIX_Priority_Is_valid(
int priority
)
{
return ((priority >= POSIX_SCHEDULER_MINIMUM_PRIORITY) &&
a000f7e4: e3500000 cmp r0, #0
a000f7e8: da000005 ble a000f804 <_POSIX_Priority_Is_valid+0x20>
(priority <= POSIX_SCHEDULER_MAXIMUM_PRIORITY));
a000f7ec: e59f3018 ldr r3, [pc, #24] ; a000f80c <_POSIX_Priority_Is_valid+0x28>
a000f7f0: e5d33000 ldrb r3, [r3]
#endif
#include <rtems/system.h>
#include <rtems/posix/priority.h>
bool _POSIX_Priority_Is_valid(
a000f7f4: e1530000 cmp r3, r0
a000f7f8: d3a00000 movle r0, #0
a000f7fc: c3a00001 movgt r0, #1
a000f800: e12fff1e bx lr
int priority
)
{
return ((priority >= POSIX_SCHEDULER_MINIMUM_PRIORITY) &&
a000f804: e3a00000 mov r0, #0
(priority <= POSIX_SCHEDULER_MAXIMUM_PRIORITY));
}
a000f808: e12fff1e bx lr
a000ab08 <_POSIX_RWLock_Translate_core_RWLock_return_code>:
#if defined(RTEMS_DEBUG)
if ( the_rwlock_status > CORE_RWLOCK_STATUS_LAST )
return EINVAL;
#endif
return _POSIX_RWLock_Return_codes[the_rwlock_status];
}
a000ab08: e59f3004 ldr r3, [pc, #4] ; a000ab14 <_POSIX_RWLock_Translate_core_RWLock_return_code+0xc><== NOT EXECUTED
a000ab0c: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED
a000ab10: e12fff1e bx lr <== NOT EXECUTED
a00123d8 <_POSIX_Semaphore_Create_support>:
POSIX_Semaphore_Control *the_semaphore;
CORE_semaphore_Attributes *the_sem_attr;
char *name_p = (char *)name;
/* Sharing semaphores among processes is not currently supported */
if (pshared != 0)
a00123d8: e3510000 cmp r1, #0
const char *name,
int pshared,
unsigned int value,
POSIX_Semaphore_Control **the_sem
)
{
a00123dc: e92d41f0 push {r4, r5, r6, r7, r8, lr}
a00123e0: e1a04000 mov r4, r0
a00123e4: e1a08002 mov r8, r2
a00123e8: e1a07003 mov r7, r3
POSIX_Semaphore_Control *the_semaphore;
CORE_semaphore_Attributes *the_sem_attr;
char *name_p = (char *)name;
/* Sharing semaphores among processes is not currently supported */
if (pshared != 0)
a00123ec: 0a000002 beq a00123fc <_POSIX_Semaphore_Create_support+0x24>
rtems_set_errno_and_return_minus_one( ENOSYS );
a00123f0: eb000b99 bl a001525c <__errno>
a00123f4: e3a03058 mov r3, #88 ; 0x58
a00123f8: ea000013 b a001244c <_POSIX_Semaphore_Create_support+0x74>
if ( name ) {
a00123fc: e3500000 cmp r0, #0
a0012400: 0a000006 beq a0012420 <_POSIX_Semaphore_Create_support+0x48>
if ( strnlen( name, NAME_MAX ) >= NAME_MAX )
a0012404: e3a010ff mov r1, #255 ; 0xff
a0012408: eb0011ce bl a0016b48 <strnlen> <== NOT EXECUTED
a001240c: e35000fe cmp r0, #254 ; 0xfe <== NOT EXECUTED
a0012410: 9a000002 bls a0012420 <_POSIX_Semaphore_Create_support+0x48><== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENAMETOOLONG );
a0012414: eb000b90 bl a001525c <__errno> <== NOT EXECUTED
a0012418: e3a0305b mov r3, #91 ; 0x5b <== NOT EXECUTED
a001241c: ea00000a b a001244c <_POSIX_Semaphore_Create_support+0x74> <== NOT EXECUTED
a0012420: e59f309c ldr r3, [pc, #156] ; a00124c4 <_POSIX_Semaphore_Create_support+0xec>
a0012424: e5932000 ldr r2, [r3]
a0012428: e2822001 add r2, r2, #1
a001242c: e5832000 str r2, [r3]
*/
RTEMS_INLINE_ROUTINE POSIX_Semaphore_Control *_POSIX_Semaphore_Allocate( void )
{
return (POSIX_Semaphore_Control *)
_Objects_Allocate( &_POSIX_Semaphore_Information );
a0012430: e59f0090 ldr r0, [pc, #144] ; a00124c8 <_POSIX_Semaphore_Create_support+0xf0>
a0012434: ebffeeab bl a000dee8 <_Objects_Allocate>
_Thread_Disable_dispatch();
the_semaphore = _POSIX_Semaphore_Allocate();
if ( !the_semaphore ) {
a0012438: e2505000 subs r5, r0, #0
a001243c: 1a000005 bne a0012458 <_POSIX_Semaphore_Create_support+0x80>
_Thread_Enable_dispatch();
a0012440: ebfff2a4 bl a000eed8 <_Thread_Enable_dispatch>
rtems_set_errno_and_return_minus_one( ENOSPC );
a0012444: eb000b84 bl a001525c <__errno>
a0012448: e3a0301c mov r3, #28
a001244c: e5803000 str r3, [r0]
a0012450: e3e00000 mvn r0, #0
a0012454: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
}
the_semaphore->process_shared = pshared;
a0012458: e3a03000 mov r3, #0
if ( name ) {
a001245c: e1540003 cmp r4, r3
if ( !the_semaphore ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( ENOSPC );
}
the_semaphore->process_shared = pshared;
a0012460: e5853010 str r3, [r5, #16]
if ( name ) {
the_semaphore->named = true;
a0012464: 12833001 addne r3, r3, #1
a0012468: 15c53014 strbne r3, [r5, #20]
the_semaphore->open_count = 1;
a001246c: 15853018 strne r3, [r5, #24]
the_semaphore->linked = true;
a0012470: 15c53015 strbne r3, [r5, #21]
* blocking tasks on this semaphore should be. It could somehow
* be derived from the current scheduling policy. One
* thing is certain, no matter what we decide, it won't be
* the same as all other POSIX implementations. :)
*/
the_sem_attr->discipline = CORE_SEMAPHORE_DISCIPLINES_FIFO;
a0012474: e3a06000 mov r6, #0
/*
* This effectively disables limit checking.
*/
the_sem_attr->maximum_count = 0xFFFFFFFF;
a0012478: e3e03000 mvn r3, #0
_CORE_semaphore_Initialize( &the_semaphore->Semaphore, the_sem_attr, value );
a001247c: e285001c add r0, r5, #28
if ( name ) {
the_semaphore->named = true;
the_semaphore->open_count = 1;
the_semaphore->linked = true;
} else {
the_semaphore->named = false;
a0012480: 05c54014 strbeq r4, [r5, #20]
the_semaphore->open_count = 0;
a0012484: 05854018 streq r4, [r5, #24]
the_semaphore->linked = false;
a0012488: 05c54015 strbeq r4, [r5, #21]
the_sem_attr->discipline = CORE_SEMAPHORE_DISCIPLINES_FIFO;
/*
* This effectively disables limit checking.
*/
the_sem_attr->maximum_count = 0xFFFFFFFF;
a001248c: e585305c str r3, [r5, #92] ; 0x5c
_CORE_semaphore_Initialize( &the_semaphore->Semaphore, the_sem_attr, value );
a0012490: e285105c add r1, r5, #92 ; 0x5c
a0012494: e1a02008 mov r2, r8
* blocking tasks on this semaphore should be. It could somehow
* be derived from the current scheduling policy. One
* thing is certain, no matter what we decide, it won't be
* the same as all other POSIX implementations. :)
*/
the_sem_attr->discipline = CORE_SEMAPHORE_DISCIPLINES_FIFO;
a0012498: e5856060 str r6, [r5, #96] ; 0x60
/*
* This effectively disables limit checking.
*/
the_sem_attr->maximum_count = 0xFFFFFFFF;
_CORE_semaphore_Initialize( &the_semaphore->Semaphore, the_sem_attr, value );
a001249c: ebffed1c bl a000d914 <_CORE_semaphore_Initialize>
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a00124a0: e59f3020 ldr r3, [pc, #32] ; a00124c8 <_POSIX_Semaphore_Create_support+0xf0>
Objects_Information *information,
Objects_Control *the_object,
const char *name
)
{
_Objects_Set_local_object(
a00124a4: e1d520b8 ldrh r2, [r5, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a00124a8: e593301c ldr r3, [r3, #28]
a00124ac: e7835102 str r5, [r3, r2, lsl #2]
the_object
);
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
/* ASSERT: information->is_string */
the_object->name.name_p = name;
a00124b0: e585400c str r4, [r5, #12]
&_POSIX_Semaphore_Information,
&the_semaphore->Object,
name_p
);
*the_sem = the_semaphore;
a00124b4: e5875000 str r5, [r7]
_Thread_Enable_dispatch();
a00124b8: ebfff286 bl a000eed8 <_Thread_Enable_dispatch>
return 0;
a00124bc: e1a00006 mov r0, r6
}
a00124c0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a00124cc <_POSIX_Semaphore_Delete>:
void _POSIX_Semaphore_Delete(
POSIX_Semaphore_Control *the_semaphore
)
{
if ( !the_semaphore->linked && !the_semaphore->open_count ) {
a00124cc: e5d03015 ldrb r3, [r0, #21] <== NOT EXECUTED
*/
void _POSIX_Semaphore_Delete(
POSIX_Semaphore_Control *the_semaphore
)
{
a00124d0: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
if ( !the_semaphore->linked && !the_semaphore->open_count ) {
a00124d4: e3530000 cmp r3, #0 <== NOT EXECUTED
*/
void _POSIX_Semaphore_Delete(
POSIX_Semaphore_Control *the_semaphore
)
{
a00124d8: e1a04000 mov r4, r0 <== NOT EXECUTED
if ( !the_semaphore->linked && !the_semaphore->open_count ) {
a00124dc: 1a00000d bne a0012518 <_POSIX_Semaphore_Delete+0x4c> <== NOT EXECUTED
a00124e0: e5905018 ldr r5, [r0, #24] <== NOT EXECUTED
a00124e4: e3550000 cmp r5, #0 <== NOT EXECUTED
a00124e8: 1a00000a bne a0012518 <_POSIX_Semaphore_Delete+0x4c> <== NOT EXECUTED
_Objects_Close( &_POSIX_Semaphore_Information, &the_semaphore->Object );
a00124ec: e1a01004 mov r1, r4 <== NOT EXECUTED
a00124f0: e59f0024 ldr r0, [pc, #36] ; a001251c <_POSIX_Semaphore_Delete+0x50><== NOT EXECUTED
a00124f4: ebffee9d bl a000df70 <_Objects_Close> <== NOT EXECUTED
_CORE_semaphore_Flush(
a00124f8: e284001c add r0, r4, #28 <== NOT EXECUTED
a00124fc: e1a01005 mov r1, r5 <== NOT EXECUTED
a0012500: e3e02000 mvn r2, #0 <== NOT EXECUTED
a0012504: ebffed01 bl a000d910 <_CORE_semaphore_Flush> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _POSIX_Semaphore_Free (
POSIX_Semaphore_Control *the_semaphore
)
{
_Objects_Free( &_POSIX_Semaphore_Information, &the_semaphore->Object );
a0012508: e59f000c ldr r0, [pc, #12] ; a001251c <_POSIX_Semaphore_Delete+0x50><== NOT EXECUTED
a001250c: e1a01004 mov r1, r4 <== NOT EXECUTED
-1
);
_POSIX_Semaphore_Free( the_semaphore );
}
}
a0012510: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
a0012514: eaffef3c b a000e20c <_Objects_Free> <== NOT EXECUTED
a0012518: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a0012520 <_POSIX_Semaphore_Name_to_id>:
int _POSIX_Semaphore_Name_to_id(
const char *name,
sem_t *id
)
{
a0012520: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
a0012524: e1a04001 mov r4, r1 <== NOT EXECUTED
Objects_Name_or_id_lookup_errors status;
Objects_Id the_id;
if ( !name )
a0012528: e2501000 subs r1, r0, #0 <== NOT EXECUTED
a001252c: 0a00000b beq a0012560 <_POSIX_Semaphore_Name_to_id+0x40> <== NOT EXECUTED
return EINVAL;
if ( !name[0] )
a0012530: e5d13000 ldrb r3, [r1] <== NOT EXECUTED
a0012534: e3530000 cmp r3, #0 <== NOT EXECUTED
a0012538: 0a000008 beq a0012560 <_POSIX_Semaphore_Name_to_id+0x40> <== NOT EXECUTED
return EINVAL;
status = _Objects_Name_to_id_string(
a001253c: e59f0024 ldr r0, [pc, #36] ; a0012568 <_POSIX_Semaphore_Name_to_id+0x48><== NOT EXECUTED
a0012540: e1a0200d mov r2, sp <== NOT EXECUTED
a0012544: eb000358 bl a00132ac <_Objects_Name_to_id_string> <== NOT EXECUTED
&_POSIX_Semaphore_Information,
name,
&the_id
);
*id = the_id;
a0012548: e59d3000 ldr r3, [sp] <== NOT EXECUTED
if ( status == OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL )
return 0;
a001254c: e3500000 cmp r0, #0 <== NOT EXECUTED
a0012550: 13a00002 movne r0, #2 <== NOT EXECUTED
status = _Objects_Name_to_id_string(
&_POSIX_Semaphore_Information,
name,
&the_id
);
*id = the_id;
a0012554: e5843000 str r3, [r4] <== NOT EXECUTED
if ( status == OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL )
return 0;
a0012558: 03a00000 moveq r0, #0 <== NOT EXECUTED
a001255c: ea000000 b a0012564 <_POSIX_Semaphore_Name_to_id+0x44> <== NOT EXECUTED
if ( !name )
return EINVAL;
if ( !name[0] )
return EINVAL;
a0012560: e3a00016 mov r0, #22 <== NOT EXECUTED
if ( status == OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL )
return 0;
return ENOENT;
}
a0012564: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a0014d64 <_POSIX_Semaphore_Translate_core_semaphore_return_code>:
#if defined(RTEMS_DEBUG)
if ( the_semaphore_status > CORE_SEMAPHORE_STATUS_LAST )
return EINVAL;
#endif
return _POSIX_Semaphore_Return_codes[the_semaphore_status];
}
a0014d64: e59f3004 ldr r3, [pc, #4] ; a0014d70 <_POSIX_Semaphore_Translate_core_semaphore_return_code+0xc><== NOT EXECUTED
a0014d68: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED
a0014d6c: e12fff1e bx lr <== NOT EXECUTED
a00125ac <_POSIX_Semaphore_Wait_support>:
int _POSIX_Semaphore_Wait_support(
sem_t *sem,
bool blocking,
Watchdog_Interval timeout
)
{
a00125ac: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
a00125b0: e1a03000 mov r3, r0 <== NOT EXECUTED
a00125b4: e1a04002 mov r4, r2 <== NOT EXECUTED
a00125b8: e20150ff and r5, r1, #255 ; 0xff <== NOT EXECUTED
sem_t *id,
Objects_Locations *location
)
{
return (POSIX_Semaphore_Control *)
_Objects_Get( &_POSIX_Semaphore_Information, (Objects_Id)*id, location );
a00125bc: e1a0200d mov r2, sp <== NOT EXECUTED
a00125c0: e5931000 ldr r1, [r3] <== NOT EXECUTED
a00125c4: e59f006c ldr r0, [pc, #108] ; a0012638 <_POSIX_Semaphore_Wait_support+0x8c><== NOT EXECUTED
a00125c8: ebffef67 bl a000e36c <_Objects_Get> <== NOT EXECUTED
POSIX_Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _POSIX_Semaphore_Get( sem, &location );
switch ( location ) {
a00125cc: e59d2000 ldr r2, [sp] <== NOT EXECUTED
a00125d0: e1a03000 mov r3, r0 <== NOT EXECUTED
a00125d4: e3520000 cmp r2, #0 <== NOT EXECUTED
a00125d8: 1a000011 bne a0012624 <_POSIX_Semaphore_Wait_support+0x78> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_semaphore_Seize(
a00125dc: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED
a00125e0: e1a03004 mov r3, r4 <== NOT EXECUTED
blocking,
timeout
);
_Thread_Enable_dispatch();
if ( !_Thread_Executing->Wait.return_code )
a00125e4: e59f4050 ldr r4, [pc, #80] ; a001263c <_POSIX_Semaphore_Wait_support+0x90><== NOT EXECUTED
the_semaphore = _POSIX_Semaphore_Get( sem, &location );
switch ( location ) {
case OBJECTS_LOCAL:
_CORE_semaphore_Seize(
a00125e8: e280001c add r0, r0, #28 <== NOT EXECUTED
a00125ec: e1a02005 mov r2, r5 <== NOT EXECUTED
a00125f0: eb0001cc bl a0012d28 <_CORE_semaphore_Seize> <== NOT EXECUTED
&the_semaphore->Semaphore,
the_semaphore->Object.id,
blocking,
timeout
);
_Thread_Enable_dispatch();
a00125f4: ebfff237 bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
if ( !_Thread_Executing->Wait.return_code )
a00125f8: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED
a00125fc: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a0012600: e3500000 cmp r0, #0 <== NOT EXECUTED
a0012604: 0a00000a beq a0012634 <_POSIX_Semaphore_Wait_support+0x88> <== NOT EXECUTED
return 0;
rtems_set_errno_and_return_minus_one(
a0012608: eb000b13 bl a001525c <__errno> <== NOT EXECUTED
a001260c: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED
a0012610: e1a05000 mov r5, r0 <== NOT EXECUTED
a0012614: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a0012618: eb0009d1 bl a0014d64 <_POSIX_Semaphore_Translate_core_semaphore_return_code><== NOT EXECUTED
a001261c: e5850000 str r0, [r5] <== NOT EXECUTED
a0012620: ea000002 b a0012630 <_POSIX_Semaphore_Wait_support+0x84> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a0012624: eb000b0c bl a001525c <__errno> <== NOT EXECUTED
a0012628: e3a03016 mov r3, #22 <== NOT EXECUTED
a001262c: e5803000 str r3, [r0] <== NOT EXECUTED
a0012630: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a0012634: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a000e3e0 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch>:
Thread_Control *the_thread
)
{
POSIX_API_Control *thread_support;
thread_support = the_thread->API_Extensions[ THREAD_API_POSIX ];
a000e3e0: e59030fc ldr r3, [r0, #252] ; 0xfc
if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE &&
a000e3e4: e59320d8 ldr r2, [r3, #216] ; 0xd8
a000e3e8: e3520000 cmp r2, #0
a000e3ec: 1a00000b bne a000e420 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x40>
a000e3f0: e59320dc ldr r2, [r3, #220] ; 0xdc
a000e3f4: e3520001 cmp r2, #1
a000e3f8: 1a000008 bne a000e420 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x40>
thread_support->cancelability_type == PTHREAD_CANCEL_ASYNCHRONOUS &&
a000e3fc: e59330e0 ldr r3, [r3, #224] ; 0xe0
a000e400: e3530000 cmp r3, #0
a000e404: 0a000005 beq a000e420 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x40>
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
a000e408: e59f3014 ldr r3, [pc, #20] ; a000e424 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x44>
thread_support->cancelation_requested ) {
_Thread_Unnest_dispatch();
_POSIX_Thread_Exit( the_thread, PTHREAD_CANCELED );
a000e40c: e3e01000 mvn r1, #0
a000e410: e5932000 ldr r2, [r3]
a000e414: e2422001 sub r2, r2, #1
a000e418: e5832000 str r2, [r3]
a000e41c: ea000204 b a000ec34 <_POSIX_Thread_Exit>
} else
_Thread_Enable_dispatch();
a000e420: eafff591 b a000ba6c <_Thread_Enable_dispatch>
a000f810 <_POSIX_Thread_Translate_sched_param>:
int policy,
struct sched_param *param,
Thread_CPU_budget_algorithms *budget_algorithm,
Thread_CPU_budget_algorithm_callout *budget_callout
)
{
a000f810: e92d40f0 push {r4, r5, r6, r7, lr}
a000f814: e1a04000 mov r4, r0
if ( !_POSIX_Priority_Is_valid( param->sched_priority ) )
a000f818: e5910000 ldr r0, [r1]
int policy,
struct sched_param *param,
Thread_CPU_budget_algorithms *budget_algorithm,
Thread_CPU_budget_algorithm_callout *budget_callout
)
{
a000f81c: e1a05001 mov r5, r1
a000f820: e1a06002 mov r6, r2
a000f824: e1a07003 mov r7, r3
if ( !_POSIX_Priority_Is_valid( param->sched_priority ) )
a000f828: ebffffed bl a000f7e4 <_POSIX_Priority_Is_valid>
a000f82c: e3500000 cmp r0, #0
a000f830: 0a00002d beq a000f8ec <_POSIX_Thread_Translate_sched_param+0xdc>
return EINVAL;
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
a000f834: e3a00000 mov r0, #0
*budget_callout = NULL;
if ( policy == SCHED_OTHER ) {
a000f838: e1540000 cmp r4, r0
)
{
if ( !_POSIX_Priority_Is_valid( param->sched_priority ) )
return EINVAL;
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
a000f83c: e5860000 str r0, [r6]
*budget_callout = NULL;
a000f840: e5870000 str r0, [r7]
if ( policy == SCHED_OTHER ) {
a000f844: 1a000003 bne a000f858 <_POSIX_Thread_Translate_sched_param+0x48>
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
a000f848: e3a03001 mov r3, #1
a000f84c: e5863000 str r3, [r6]
return 0;
a000f850: e1a00004 mov r0, r4
a000f854: e8bd80f0 pop {r4, r5, r6, r7, pc}
}
if ( policy == SCHED_FIFO ) {
a000f858: e3540001 cmp r4, #1
a000f85c: 0a000025 beq a000f8f8 <_POSIX_Thread_Translate_sched_param+0xe8>
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
return 0;
}
if ( policy == SCHED_RR ) {
a000f860: e3540002 cmp r4, #2
a000f864: 1a000001 bne a000f870 <_POSIX_Thread_Translate_sched_param+0x60>
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE;
a000f868: e5864000 str r4, [r6]
return 0;
a000f86c: e8bd80f0 pop {r4, r5, r6, r7, pc}
}
if ( policy == SCHED_SPORADIC ) {
a000f870: e3540004 cmp r4, #4
a000f874: 1a00001c bne a000f8ec <_POSIX_Thread_Translate_sched_param+0xdc>
if ( (param->sched_ss_repl_period.tv_sec == 0) &&
a000f878: e5953008 ldr r3, [r5, #8]
a000f87c: e3530000 cmp r3, #0
a000f880: 1a000002 bne a000f890 <_POSIX_Thread_Translate_sched_param+0x80>
a000f884: e595300c ldr r3, [r5, #12]
a000f888: e3530000 cmp r3, #0
a000f88c: 0a000016 beq a000f8ec <_POSIX_Thread_Translate_sched_param+0xdc>
(param->sched_ss_repl_period.tv_nsec == 0) )
return EINVAL;
if ( (param->sched_ss_init_budget.tv_sec == 0) &&
a000f890: e5953010 ldr r3, [r5, #16]
a000f894: e3530000 cmp r3, #0
a000f898: 1a000002 bne a000f8a8 <_POSIX_Thread_Translate_sched_param+0x98>
a000f89c: e5953014 ldr r3, [r5, #20]
a000f8a0: e3530000 cmp r3, #0
a000f8a4: 0a000010 beq a000f8ec <_POSIX_Thread_Translate_sched_param+0xdc>
(param->sched_ss_init_budget.tv_nsec == 0) )
return EINVAL;
if ( _Timespec_To_ticks( ¶m->sched_ss_repl_period ) <
a000f8a8: e2850008 add r0, r5, #8
a000f8ac: ebfff6ba bl a000d39c <_Timespec_To_ticks>
a000f8b0: e1a04000 mov r4, r0
_Timespec_To_ticks( ¶m->sched_ss_init_budget ) )
a000f8b4: e2850010 add r0, r5, #16
a000f8b8: ebfff6b7 bl a000d39c <_Timespec_To_ticks>
if ( (param->sched_ss_init_budget.tv_sec == 0) &&
(param->sched_ss_init_budget.tv_nsec == 0) )
return EINVAL;
if ( _Timespec_To_ticks( ¶m->sched_ss_repl_period ) <
a000f8bc: e1540000 cmp r4, r0
a000f8c0: 3a000009 bcc a000f8ec <_POSIX_Thread_Translate_sched_param+0xdc>
_Timespec_To_ticks( ¶m->sched_ss_init_budget ) )
return EINVAL;
if ( !_POSIX_Priority_Is_valid( param->sched_ss_low_priority ) )
a000f8c4: e5950004 ldr r0, [r5, #4]
a000f8c8: ebffffc5 bl a000f7e4 <_POSIX_Priority_Is_valid>
a000f8cc: e3500000 cmp r0, #0
a000f8d0: 0a000007 beq a000f8f4 <_POSIX_Thread_Translate_sched_param+0xe4>
return EINVAL;
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_CALLOUT;
a000f8d4: e3a03003 mov r3, #3
a000f8d8: e5863000 str r3, [r6]
*budget_callout = _POSIX_Threads_Sporadic_budget_callout;
a000f8dc: e59f3018 ldr r3, [pc, #24] ; a000f8fc <_POSIX_Thread_Translate_sched_param+0xec>
return 0;
a000f8e0: e3a00000 mov r0, #0
if ( !_POSIX_Priority_Is_valid( param->sched_ss_low_priority ) )
return EINVAL;
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_CALLOUT;
*budget_callout = _POSIX_Threads_Sporadic_budget_callout;
a000f8e4: e5873000 str r3, [r7]
return 0;
a000f8e8: e8bd80f0 pop {r4, r5, r6, r7, pc}
(param->sched_ss_init_budget.tv_nsec == 0) )
return EINVAL;
if ( _Timespec_To_ticks( ¶m->sched_ss_repl_period ) <
_Timespec_To_ticks( ¶m->sched_ss_init_budget ) )
return EINVAL;
a000f8ec: e3a00016 mov r0, #22
a000f8f0: e8bd80f0 pop {r4, r5, r6, r7, pc}
if ( !_POSIX_Priority_Is_valid( param->sched_ss_low_priority ) )
return EINVAL;
a000f8f4: e3a00016 mov r0, #22 <== NOT EXECUTED
*budget_callout = _POSIX_Threads_Sporadic_budget_callout;
return 0;
}
return EINVAL;
}
a000f8f8: e8bd80f0 pop {r4, r5, r6, r7, pc}
a000e534 <_POSIX_Threads_Delete_extension>:
*/
void _POSIX_Threads_Delete_extension(
Thread_Control *executing __attribute__((unused)),
Thread_Control *deleted
)
{
a000e534: e92d40f0 push {r4, r5, r6, r7, lr}
Thread_Control *the_thread;
POSIX_API_Control *api;
void **value_ptr;
api = deleted->API_Extensions[ THREAD_API_POSIX ];
a000e538: e59150fc ldr r5, [r1, #252] ; 0xfc
*/
void _POSIX_Threads_Delete_extension(
Thread_Control *executing __attribute__((unused)),
Thread_Control *deleted
)
{
a000e53c: e1a04001 mov r4, r1
api = deleted->API_Extensions[ THREAD_API_POSIX ];
/*
* Run the POSIX cancellation handlers
*/
_POSIX_Threads_cancel_run( deleted );
a000e540: e1a00001 mov r0, r1
a000e544: eb0008cb bl a0010878 <_POSIX_Threads_cancel_run>
/*
* Run all the key destructors
*/
_POSIX_Keys_Run_destructors( deleted );
a000e548: e1a00004 mov r0, r4
a000e54c: eb0008e0 bl a00108d4 <_POSIX_Keys_Run_destructors>
/*
* Wakeup all the tasks which joined with this one
*/
value_ptr = (void **) deleted->Wait.return_argument;
while ( (the_thread = _Thread_queue_Dequeue( &api->Join_List )) )
a000e550: e2856044 add r6, r5, #68 ; 0x44
_POSIX_Keys_Run_destructors( deleted );
/*
* Wakeup all the tasks which joined with this one
*/
value_ptr = (void **) deleted->Wait.return_argument;
a000e554: e5947028 ldr r7, [r4, #40] ; 0x28
while ( (the_thread = _Thread_queue_Dequeue( &api->Join_List )) )
a000e558: ea000001 b a000e564 <_POSIX_Threads_Delete_extension+0x30>
*(void **)the_thread->Wait.return_argument = value_ptr;
a000e55c: e5903028 ldr r3, [r0, #40] ; 0x28
a000e560: e5837000 str r7, [r3]
/*
* Wakeup all the tasks which joined with this one
*/
value_ptr = (void **) deleted->Wait.return_argument;
while ( (the_thread = _Thread_queue_Dequeue( &api->Join_List )) )
a000e564: e1a00006 mov r0, r6
a000e568: ebfff519 bl a000b9d4 <_Thread_queue_Dequeue>
a000e56c: e3500000 cmp r0, #0
a000e570: 1afffff9 bne a000e55c <_POSIX_Threads_Delete_extension+0x28>
*(void **)the_thread->Wait.return_argument = value_ptr;
if ( api->schedpolicy == SCHED_SPORADIC )
a000e574: e5953084 ldr r3, [r5, #132] ; 0x84
a000e578: e3530004 cmp r3, #4
a000e57c: 1a000001 bne a000e588 <_POSIX_Threads_Delete_extension+0x54>
(void) _Watchdog_Remove( &api->Sporadic_timer );
a000e580: e28500a8 add r0, r5, #168 ; 0xa8 <== NOT EXECUTED
a000e584: ebfff823 bl a000c618 <_Watchdog_Remove> <== NOT EXECUTED
deleted->API_Extensions[ THREAD_API_POSIX ] = NULL;
a000e588: e3a03000 mov r3, #0
(void) _Workspace_Free( api );
a000e58c: e1a00005 mov r0, r5
*(void **)the_thread->Wait.return_argument = value_ptr;
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
deleted->API_Extensions[ THREAD_API_POSIX ] = NULL;
a000e590: e58430fc str r3, [r4, #252] ; 0xfc
(void) _Workspace_Free( api );
}
a000e594: e8bd40f0 pop {r4, r5, r6, r7, lr}
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
deleted->API_Extensions[ THREAD_API_POSIX ] = NULL;
(void) _Workspace_Free( api );
a000e598: eafff88a b a000c7c8 <_Workspace_Free>
a000e728 <_POSIX_Threads_Sporadic_budget_callout>:
/*
* This will prevent the thread from consuming its entire "budget"
* while at low priority.
*/
the_thread->cpu_time_budget = 0xFFFFFFFF; /* XXX should be based on MAX_U32 */
a000e728: e3e01000 mvn r1, #0 <== NOT EXECUTED
)
{
POSIX_API_Control *api;
uint32_t new_priority;
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
a000e72c: e59020fc ldr r2, [r0, #252] ; 0xfc <== NOT EXECUTED
/*
* This will prevent the thread from consuming its entire "budget"
* while at low priority.
*/
the_thread->cpu_time_budget = 0xFFFFFFFF; /* XXX should be based on MAX_U32 */
a000e730: e5801078 str r1, [r0, #120] ; 0x78 <== NOT EXECUTED
a000e734: e59f102c ldr r1, [pc, #44] ; a000e768 <_POSIX_Threads_Sporadic_budget_callout+0x40><== NOT EXECUTED
a000e738: e592208c ldr r2, [r2, #140] ; 0x8c <== NOT EXECUTED
a000e73c: e5d11000 ldrb r1, [r1] <== NOT EXECUTED
a000e740: e0621001 rsb r1, r2, r1 <== NOT EXECUTED
*/
#if 0
printk( "callout %d %d %d\n", the_thread->resource_count,
the_thread->current_priority, new_priority );
#endif
if ( the_thread->resource_count == 0 ) {
a000e744: e590201c ldr r2, [r0, #28] <== NOT EXECUTED
* while at low priority.
*/
the_thread->cpu_time_budget = 0xFFFFFFFF; /* XXX should be based on MAX_U32 */
new_priority = _POSIX_Priority_To_core(api->schedparam.sched_ss_low_priority);
the_thread->real_priority = new_priority;
a000e748: e5801018 str r1, [r0, #24] <== NOT EXECUTED
*/
#if 0
printk( "callout %d %d %d\n", the_thread->resource_count,
the_thread->current_priority, new_priority );
#endif
if ( the_thread->resource_count == 0 ) {
a000e74c: e3520000 cmp r2, #0 <== NOT EXECUTED
a000e750: 112fff1e bxne lr <== NOT EXECUTED
/*
* Make sure we are actually lowering it. If they have lowered it
* to logically lower than sched_ss_low_priority, then we do not want to
* change it.
*/
if ( the_thread->current_priority < new_priority ) {
a000e754: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED
a000e758: e1530001 cmp r3, r1 <== NOT EXECUTED
a000e75c: 212fff1e bxcs lr <== NOT EXECUTED
_Thread_Change_priority( the_thread, new_priority, true );
a000e760: e2822001 add r2, r2, #1 <== NOT EXECUTED
a000e764: eafff2a5 b a000b200 <_Thread_Change_priority> <== NOT EXECUTED
a0010878 <_POSIX_Threads_cancel_run>:
#include <rtems/posix/threadsup.h>
void _POSIX_Threads_cancel_run(
Thread_Control *the_thread
)
{
a0010878: e92d4070 push {r4, r5, r6, lr}
POSIX_Cancel_Handler_control *handler;
Chain_Control *handler_stack;
POSIX_API_Control *thread_support;
ISR_Level level;
thread_support = the_thread->API_Extensions[ THREAD_API_POSIX ];
a001087c: e59050fc ldr r5, [r0, #252] ; 0xfc
handler_stack = &thread_support->Cancellation_Handlers;
thread_support->cancelability_state = PTHREAD_CANCEL_DISABLE;
a0010880: e3a03001 mov r3, #1
a0010884: e58530d8 str r3, [r5, #216] ; 0xd8
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a0010888: e28560e8 add r6, r5, #232 ; 0xe8
while ( !_Chain_Is_empty( handler_stack ) ) {
a001088c: ea00000c b a00108c4 <_POSIX_Threads_cancel_run+0x4c>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0010890: e10f1000 mrs r1, CPSR <== NOT EXECUTED
a0010894: e3813080 orr r3, r1, #128 ; 0x80 <== NOT EXECUTED
a0010898: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
_ISR_Disable( level );
handler = (POSIX_Cancel_Handler_control *)
a001089c: e59540ec ldr r4, [r5, #236] ; 0xec <== NOT EXECUTED
)
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
a00108a0: e894000c ldm r4, {r2, r3} <== NOT EXECUTED
previous = the_node->previous;
next->previous = previous;
a00108a4: e5823004 str r3, [r2, #4] <== NOT EXECUTED
previous->next = next;
a00108a8: e5832000 str r2, [r3] <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a00108ac: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED
_Chain_Tail( handler_stack )->previous;
_Chain_Extract_unprotected( &handler->Node );
_ISR_Enable( level );
(*handler->routine)( handler->arg );
a00108b0: e594000c ldr r0, [r4, #12] <== NOT EXECUTED
a00108b4: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED
a00108b8: e12fff33 blx r3 <== NOT EXECUTED
_Workspace_Free( handler );
a00108bc: e1a00004 mov r0, r4 <== NOT EXECUTED
a00108c0: ebffefc0 bl a000c7c8 <_Workspace_Free> <== NOT EXECUTED
handler_stack = &thread_support->Cancellation_Handlers;
thread_support->cancelability_state = PTHREAD_CANCEL_DISABLE;
while ( !_Chain_Is_empty( handler_stack ) ) {
a00108c4: e59530e4 ldr r3, [r5, #228] ; 0xe4
a00108c8: e1530006 cmp r3, r6
a00108cc: 1affffef bne a0010890 <_POSIX_Threads_cancel_run+0x18>
(*handler->routine)( handler->arg );
_Workspace_Free( handler );
}
}
a00108d0: e8bd8070 pop {r4, r5, r6, pc}
a000f430 <_POSIX_Timer_Insert_helper>:
Watchdog_Interval ticks,
Objects_Id id,
Watchdog_Service_routine_entry TSR,
void *arg
)
{
a000f430: e92d41f0 push {r4, r5, r6, r7, r8, lr}
a000f434: e1a04000 mov r4, r0
a000f438: e1a05001 mov r5, r1
a000f43c: e1a07002 mov r7, r2
a000f440: e1a08003 mov r8, r3
ISR_Level level;
(void) _Watchdog_Remove( timer );
a000f444: ebfff70c bl a000d07c <_Watchdog_Remove>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000f448: e10f6000 mrs r6, CPSR
a000f44c: e3863080 orr r3, r6, #128 ; 0x80
a000f450: e129f003 msr CPSR_fc, r3
/*
* Check to see if the watchdog has just been inserted by a
* higher priority interrupt. If so, abandon this insert.
*/
if ( timer->state != WATCHDOG_INACTIVE ) {
a000f454: e5943008 ldr r3, [r4, #8]
a000f458: e3530000 cmp r3, #0
a000f45c: 0a000002 beq a000f46c <_POSIX_Timer_Insert_helper+0x3c>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000f460: e129f006 msr CPSR_fc, r6
_ISR_Enable( level );
return false;
a000f464: e3a00000 mov r0, #0 <== NOT EXECUTED
a000f468: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a000f46c: e5843008 str r3, [r4, #8]
the_watchdog->routine = routine;
the_watchdog->id = id;
the_watchdog->user_data = user_data;
a000f470: e59d3018 ldr r3, [sp, #24]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a000f474: e584801c str r8, [r4, #28]
the_watchdog->id = id;
a000f478: e5847020 str r7, [r4, #32]
the_watchdog->user_data = user_data;
a000f47c: e5843024 str r3, [r4, #36] ; 0x24
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000f480: e584500c str r5, [r4, #12]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a000f484: e59f0010 ldr r0, [pc, #16] ; a000f49c <_POSIX_Timer_Insert_helper+0x6c>
a000f488: e1a01004 mov r1, r4
a000f48c: ebfff6a2 bl a000cf1c <_Watchdog_Insert>
a000f490: e129f006 msr CPSR_fc, r6
* so we can atomically initialize it as in use.
*/
_Watchdog_Initialize( timer, TSR, id, arg );
_Watchdog_Insert_ticks( timer, ticks );
_ISR_Enable( level );
return true;
a000f494: e3a00001 mov r0, #1
}
a000f498: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a00095f8 <_POSIX_Timer_TSR>:
bool activated;
ptimer = (POSIX_Timer_Control *)data;
/* Increment the number of expirations. */
ptimer->overrun = ptimer->overrun + 1;
a00095f8: e5913068 ldr r3, [r1, #104] ; 0x68 <== NOT EXECUTED
* This is the operation that is run when a timer expires
*/
void _POSIX_Timer_TSR(
Objects_Id timer __attribute__((unused)),
void *data)
{
a00095fc: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
bool activated;
ptimer = (POSIX_Timer_Control *)data;
/* Increment the number of expirations. */
ptimer->overrun = ptimer->overrun + 1;
a0009600: e2833001 add r3, r3, #1 <== NOT EXECUTED
a0009604: e5813068 str r3, [r1, #104] ; 0x68 <== NOT EXECUTED
/* The timer must be reprogrammed */
if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) ||
a0009608: e5913054 ldr r3, [r1, #84] ; 0x54 <== NOT EXECUTED
* This is the operation that is run when a timer expires
*/
void _POSIX_Timer_TSR(
Objects_Id timer __attribute__((unused)),
void *data)
{
a000960c: e1a04001 mov r4, r1 <== NOT EXECUTED
/* Increment the number of expirations. */
ptimer->overrun = ptimer->overrun + 1;
/* The timer must be reprogrammed */
if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) ||
a0009610: e3530000 cmp r3, #0 <== NOT EXECUTED
a0009614: 1a000003 bne a0009628 <_POSIX_Timer_TSR+0x30> <== NOT EXECUTED
a0009618: e5913058 ldr r3, [r1, #88] ; 0x58 <== NOT EXECUTED
a000961c: e3530000 cmp r3, #0 <== NOT EXECUTED
/* The state really did not change but just to be safe */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
} else {
/* Indicates that the timer is stopped */
ptimer->state = POSIX_TIMER_STATE_CREATE_STOP;
a0009620: 03a03004 moveq r3, #4 <== NOT EXECUTED
/* Increment the number of expirations. */
ptimer->overrun = ptimer->overrun + 1;
/* The timer must be reprogrammed */
if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) ||
a0009624: 0a00000a beq a0009654 <_POSIX_Timer_TSR+0x5c> <== NOT EXECUTED
( ptimer->timer_data.it_interval.tv_nsec != 0 ) ) {
activated = _POSIX_Timer_Insert_helper(
a0009628: e2840010 add r0, r4, #16 <== NOT EXECUTED
a000962c: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED
a0009630: e5942008 ldr r2, [r4, #8] <== NOT EXECUTED
a0009634: e59f3034 ldr r3, [pc, #52] ; a0009670 <_POSIX_Timer_TSR+0x78><== NOT EXECUTED
a0009638: e58d4000 str r4, [sp] <== NOT EXECUTED
a000963c: eb00177b bl a000f430 <_POSIX_Timer_Insert_helper> <== NOT EXECUTED
ptimer->ticks,
ptimer->Object.id,
_POSIX_Timer_TSR,
ptimer
);
if ( !activated )
a0009640: e3500000 cmp r0, #0 <== NOT EXECUTED
a0009644: 0a000008 beq a000966c <_POSIX_Timer_TSR+0x74> <== NOT EXECUTED
return;
/* Store the time when the timer was started again */
_TOD_Get( &ptimer->time );
a0009648: e284006c add r0, r4, #108 ; 0x6c <== NOT EXECUTED
a000964c: eb000548 bl a000ab74 <_TOD_Get> <== NOT EXECUTED
/* The state really did not change but just to be safe */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
a0009650: e3a03003 mov r3, #3 <== NOT EXECUTED
} else {
/* Indicates that the timer is stopped */
ptimer->state = POSIX_TIMER_STATE_CREATE_STOP;
a0009654: e5c4303c strb r3, [r4, #60] ; 0x3c <== NOT EXECUTED
/*
* The sending of the signal to the process running the handling function
* specified for that signal is simulated
*/
if ( pthread_kill ( ptimer->thread_id, ptimer->inf.sigev_signo ) ) {
a0009658: e5940038 ldr r0, [r4, #56] ; 0x38 <== NOT EXECUTED
a000965c: e5941044 ldr r1, [r4, #68] ; 0x44 <== NOT EXECUTED
a0009660: eb001660 bl a000efe8 <pthread_kill> <== NOT EXECUTED
}
/* After the signal handler returns, the count of expirations of the
* timer must be set to 0.
*/
ptimer->overrun = 0;
a0009664: e3a03000 mov r3, #0 <== NOT EXECUTED
a0009668: e5843068 str r3, [r4, #104] ; 0x68 <== NOT EXECUTED
}
a000966c: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000e1e8 <_POSIX_signals_Abnormal_termination_handler>:
sigset_t _POSIX_signals_Pending;
void _POSIX_signals_Abnormal_termination_handler(
int signo __attribute__((unused)) )
{
a000e1e8: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
exit( 1 );
a000e1ec: e3a00001 mov r0, #1 <== NOT EXECUTED
a000e1f0: eb000bbe bl a00110f0 <exit> <== NOT EXECUTED
a000b25c <_POSIX_signals_Alarm_TSR>:
void _POSIX_signals_Alarm_TSR(
Objects_Id id __attribute__((unused)),
void *argument __attribute__((unused))
)
{
a000b25c: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
int status;
status = kill( getpid(), SIGALRM );
a000b260: ebfff53d bl a000875c <getpid> <== NOT EXECUTED
a000b264: e3a0100e mov r1, #14 <== NOT EXECUTED
/* XXX can't print from an ISR, should this be fatal? */
}
a000b268: e49de004 pop {lr} ; (ldr lr, [sp], #4) <== NOT EXECUTED
void *argument __attribute__((unused))
)
{
int status;
status = kill( getpid(), SIGALRM );
a000b26c: ea00004a b a000b39c <kill> <== NOT EXECUTED
a0010964 <_POSIX_signals_Check_signal>:
bool _POSIX_signals_Check_signal(
POSIX_API_Control *api,
int signo,
bool is_global
)
{
a0010964: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr}
a0010968: e24dd038 sub sp, sp, #56 ; 0x38
a001096c: e20230ff and r3, r2, #255 ; 0xff
siginfo_t siginfo_struct;
sigset_t saved_signals_blocked;
Thread_Wait_information stored_thread_wait_information;
if ( ! _POSIX_signals_Clear_signals( api, signo, &siginfo_struct,
a0010970: e28da02c add sl, sp, #44 ; 0x2c
a0010974: e3a02001 mov r2, #1
a0010978: e58d2000 str r2, [sp]
a001097c: e1a0200a mov r2, sl
bool _POSIX_signals_Check_signal(
POSIX_API_Control *api,
int signo,
bool is_global
)
{
a0010980: e1a04000 mov r4, r0
a0010984: e1a05001 mov r5, r1
siginfo_t siginfo_struct;
sigset_t saved_signals_blocked;
Thread_Wait_information stored_thread_wait_information;
if ( ! _POSIX_signals_Clear_signals( api, signo, &siginfo_struct,
a0010988: eb000031 bl a0010a54 <_POSIX_signals_Clear_signals>
a001098c: e3500000 cmp r0, #0
a0010990: 0a00002b beq a0010a44 <_POSIX_signals_Check_signal+0xe0>
#endif
/*
* Just to prevent sending a signal which is currently being ignored.
*/
if ( _POSIX_signals_Vectors[ signo ].sa_handler == SIG_IGN )
a0010994: e3a0800c mov r8, #12
a0010998: e59f60ac ldr r6, [pc, #172] ; a0010a4c <_POSIX_signals_Check_signal+0xe8>
a001099c: e0080895 mul r8, r5, r8
a00109a0: e0863008 add r3, r6, r8
a00109a4: e593c008 ldr ip, [r3, #8]
a00109a8: e35c0001 cmp ip, #1
return false;
a00109ac: 03a00000 moveq r0, #0
#endif
/*
* Just to prevent sending a signal which is currently being ignored.
*/
if ( _POSIX_signals_Vectors[ signo ].sa_handler == SIG_IGN )
a00109b0: 0a000023 beq a0010a44 <_POSIX_signals_Check_signal+0xe0>
return false;
/*
* Block the signals requested in sa_mask
*/
saved_signals_blocked = api->signals_blocked;
a00109b4: e59490d0 ldr r9, [r4, #208] ; 0xd0
api->signals_blocked |= _POSIX_signals_Vectors[ signo ].sa_mask;
a00109b8: e5933004 ldr r3, [r3, #4]
/*
* We have to save the blocking information of the current wait queue
* because the signal handler may subsequently go on and put the thread
* on a wait queue, for its own purposes.
*/
memcpy( &stored_thread_wait_information, &_Thread_Executing->Wait,
a00109bc: e28de004 add lr, sp, #4
/*
* Block the signals requested in sa_mask
*/
saved_signals_blocked = api->signals_blocked;
api->signals_blocked |= _POSIX_signals_Vectors[ signo ].sa_mask;
a00109c0: e1833009 orr r3, r3, r9
a00109c4: e58430d0 str r3, [r4, #208] ; 0xd0
/*
* We have to save the blocking information of the current wait queue
* because the signal handler may subsequently go on and put the thread
* on a wait queue, for its own purposes.
*/
memcpy( &stored_thread_wait_information, &_Thread_Executing->Wait,
a00109c8: e59f3080 ldr r3, [pc, #128] ; a0010a50 <_POSIX_signals_Check_signal+0xec>
a00109cc: e5937004 ldr r7, [r3, #4]
a00109d0: e2877020 add r7, r7, #32
a00109d4: e8b7000f ldm r7!, {r0, r1, r2, r3}
a00109d8: e8ae000f stmia lr!, {r0, r1, r2, r3}
a00109dc: e8b7000f ldm r7!, {r0, r1, r2, r3}
a00109e0: e8ae000f stmia lr!, {r0, r1, r2, r3}
a00109e4: e8970003 ldm r7, {r0, r1}
sizeof( Thread_Wait_information ));
/*
* Here, the signal handler function executes
*/
switch ( _POSIX_signals_Vectors[ signo ].sa_flags ) {
a00109e8: e7963008 ldr r3, [r6, r8]
/*
* We have to save the blocking information of the current wait queue
* because the signal handler may subsequently go on and put the thread
* on a wait queue, for its own purposes.
*/
memcpy( &stored_thread_wait_information, &_Thread_Executing->Wait,
a00109ec: e88e0003 stm lr, {r0, r1}
sizeof( Thread_Wait_information ));
/*
* Here, the signal handler function executes
*/
switch ( _POSIX_signals_Vectors[ signo ].sa_flags ) {
a00109f0: e3530002 cmp r3, #2
a00109f4: 1a000004 bne a0010a0c <_POSIX_signals_Check_signal+0xa8>
case SA_SIGINFO:
(*_POSIX_signals_Vectors[ signo ].sa_sigaction)(
a00109f8: e1a00005 mov r0, r5 <== NOT EXECUTED
a00109fc: e1a0100a mov r1, sl <== NOT EXECUTED
a0010a00: e3a02000 mov r2, #0 <== NOT EXECUTED
a0010a04: e12fff3c blx ip <== NOT EXECUTED
signo,
&siginfo_struct,
NULL /* context is undefined per 1003.1b-1993, p. 66 */
);
break;
a0010a08: ea000001 b a0010a14 <_POSIX_signals_Check_signal+0xb0> <== NOT EXECUTED
default:
(*_POSIX_signals_Vectors[ signo ].sa_handler)( signo );
a0010a0c: e1a00005 mov r0, r5
a0010a10: e12fff3c blx ip
}
/*
* Restore the blocking information
*/
memcpy( &_Thread_Executing->Wait, &stored_thread_wait_information,
a0010a14: e59f3034 ldr r3, [pc, #52] ; a0010a50 <_POSIX_signals_Check_signal+0xec>
a0010a18: e28d5004 add r5, sp, #4
a0010a1c: e593c004 ldr ip, [r3, #4]
a0010a20: e8b5000f ldm r5!, {r0, r1, r2, r3}
a0010a24: e28cc020 add ip, ip, #32
a0010a28: e8ac000f stmia ip!, {r0, r1, r2, r3}
a0010a2c: e8b5000f ldm r5!, {r0, r1, r2, r3}
a0010a30: e8ac000f stmia ip!, {r0, r1, r2, r3}
a0010a34: e8950003 ldm r5, {r0, r1}
a0010a38: e88c0003 stm ip, {r0, r1}
sizeof( Thread_Wait_information ));
/*
* Restore the previous set of blocked signals
*/
api->signals_blocked = saved_signals_blocked;
a0010a3c: e58490d0 str r9, [r4, #208] ; 0xd0
return true;
a0010a40: e3a00001 mov r0, #1
}
a0010a44: e28dd038 add sp, sp, #56 ; 0x38
a0010a48: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc}
a0010a54 <_POSIX_signals_Clear_signals>:
int signo,
siginfo_t *info,
bool is_global,
bool check_blocked
)
{
a0010a54: e92d40f0 push {r4, r5, r6, r7, lr}
a0010a58: e5ddc014 ldrb ip, [sp, #20]
a0010a5c: e1a04001 mov r4, r1
a0010a60: e1a05002 mov r5, r2
/* set blocked signals based on if checking for them, SIGNAL_ALL_MASK
* insures that no signals are blocked and all are checked.
*/
if ( check_blocked )
a0010a64: e35c0000 cmp ip, #0
static inline sigset_t signo_to_mask(
uint32_t sig
)
{
return 1u << (sig - 1);
a0010a68: e2412001 sub r2, r1, #1
a0010a6c: e3a01001 mov r1, #1
a0010a70: e1a01211 lsl r1, r1, r2
signals_blocked = ~api->signals_blocked;
a0010a74: 159020d0 ldrne r2, [r0, #208] ; 0xd0
int signo,
siginfo_t *info,
bool is_global,
bool check_blocked
)
{
a0010a78: e20330ff and r3, r3, #255 ; 0xff
*/
if ( check_blocked )
signals_blocked = ~api->signals_blocked;
else
signals_blocked = SIGNAL_ALL_MASK;
a0010a7c: 03e02000 mvneq r2, #0
/* set blocked signals based on if checking for them, SIGNAL_ALL_MASK
* insures that no signals are blocked and all are checked.
*/
if ( check_blocked )
signals_blocked = ~api->signals_blocked;
a0010a80: 11e02002 mvnne r2, r2
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0010a84: e10f7000 mrs r7, CPSR
a0010a88: e387c080 orr ip, r7, #128 ; 0x80
a0010a8c: e129f00c msr CPSR_fc, ip
/* XXX is this right for siginfo type signals? */
/* XXX are we sure they can be cleared the same way? */
_ISR_Disable( level );
if ( is_global ) {
a0010a90: e3530000 cmp r3, #0
a0010a94: 0a000029 beq a0010b40 <_POSIX_signals_Clear_signals+0xec>
if ( mask & (_POSIX_signals_Pending & signals_blocked) ) {
a0010a98: e59f30c8 ldr r3, [pc, #200] ; a0010b68 <_POSIX_signals_Clear_signals+0x114>
a0010a9c: e5930000 ldr r0, [r3]
a0010aa0: e0011000 and r1, r1, r0
a0010aa4: e0110002 ands r0, r1, r2
a0010aa8: 0a00002c beq a0010b60 <_POSIX_signals_Clear_signals+0x10c>
if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) {
a0010aac: e3a0300c mov r3, #12
a0010ab0: e0030394 mul r3, r4, r3
a0010ab4: e59f20b0 ldr r2, [pc, #176] ; a0010b6c <_POSIX_signals_Clear_signals+0x118>
a0010ab8: e7922003 ldr r2, [r2, r3]
a0010abc: e3520002 cmp r2, #2
a0010ac0: 1a00001b bne a0010b34 <_POSIX_signals_Clear_signals+0xe0>
do_callout = true;
}
}
_ISR_Enable( level );
return do_callout;
}
a0010ac4: e59f20a4 ldr r2, [pc, #164] ; a0010b70 <_POSIX_signals_Clear_signals+0x11c>
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a0010ac8: e2831004 add r1, r3, #4
a0010acc: e7926003 ldr r6, [r2, r3]
a0010ad0: e0811002 add r1, r1, r2
a0010ad4: e0820003 add r0, r2, r3
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(
Chain_Control *the_chain
)
{
if ( !_Chain_Is_empty(the_chain))
a0010ad8: e1560001 cmp r6, r1
Chain_Control *the_chain
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *old_first = head->next;
Chain_Node *new_first = old_first->next;
a0010adc: 15961000 ldrne r1, [r6]
)
{
if ( !_Chain_Is_empty(the_chain))
return _Chain_Get_first_unprotected(the_chain);
else
return NULL;
a0010ae0: 03a06000 moveq r6, #0
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *old_first = head->next;
Chain_Node *new_first = old_first->next;
head->next = new_first;
new_first->previous = head;
a0010ae4: 15810004 strne r0, [r1, #4]
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *old_first = head->next;
Chain_Node *new_first = old_first->next;
head->next = new_first;
a0010ae8: 17821003 strne r1, [r2, r3]
if ( is_global ) {
if ( mask & (_POSIX_signals_Pending & signals_blocked) ) {
if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) {
psiginfo = (POSIX_signals_Siginfo_node *)
_Chain_Get_unprotected( &_POSIX_signals_Siginfo[ signo ] );
_POSIX_signals_Clear_process_signals( signo );
a0010aec: e1a00004 mov r0, r4
a0010af0: eb00015b bl a0011064 <_POSIX_signals_Clear_process_signals>
/*
* It may be impossible to get here with an empty chain
* BUT until that is proven we need to be defensive and
* protect against it.
*/
if ( psiginfo ) {
a0010af4: e3560000 cmp r6, #0
a0010af8: 0a00000d beq a0010b34 <_POSIX_signals_Clear_signals+0xe0>
*info = psiginfo->Info;
a0010afc: e5962008 ldr r2, [r6, #8] <== NOT EXECUTED
a0010b00: e1a03005 mov r3, r5 <== NOT EXECUTED
a0010b04: e4832004 str r2, [r3], #4 <== NOT EXECUTED
a0010b08: e596200c ldr r2, [r6, #12] <== NOT EXECUTED
a0010b0c: e5852004 str r2, [r5, #4] <== NOT EXECUTED
a0010b10: e5962010 ldr r2, [r6, #16] <== NOT EXECUTED
a0010b14: e5832004 str r2, [r3, #4] <== NOT EXECUTED
Chain_Control *the_chain,
Chain_Node *the_node
)
{
Chain_Node *tail = _Chain_Tail( the_chain );
Chain_Node *old_last = tail->previous;
a0010b18: e59f3054 ldr r3, [pc, #84] ; a0010b74 <_POSIX_signals_Clear_signals+0x120><== NOT EXECUTED
a0010b1c: e5932008 ldr r2, [r3, #8] <== NOT EXECUTED
the_node->next = tail;
a0010b20: e2831004 add r1, r3, #4 <== NOT EXECUTED
a0010b24: e5861000 str r1, [r6] <== NOT EXECUTED
tail->previous = the_node;
a0010b28: e5836008 str r6, [r3, #8] <== NOT EXECUTED
old_last->next = the_node;
a0010b2c: e5826000 str r6, [r2] <== NOT EXECUTED
the_node->previous = old_last;
a0010b30: e5862004 str r2, [r6, #4] <== NOT EXECUTED
&psiginfo->Node
);
} else
do_callout = false;
}
_POSIX_signals_Clear_process_signals( signo );
a0010b34: e1a00004 mov r0, r4
a0010b38: eb000149 bl a0011064 <_POSIX_signals_Clear_process_signals>
a0010b3c: ea000006 b a0010b5c <_POSIX_signals_Clear_signals+0x108>
do_callout = true;
}
} else {
if ( mask & (api->signals_pending & signals_blocked) ) {
a0010b40: e590c0d4 ldr ip, [r0, #212] ; 0xd4
a0010b44: e001400c and r4, r1, ip
a0010b48: e1140002 tst r4, r2
bool do_callout;
POSIX_signals_Siginfo_node *psiginfo;
mask = signo_to_mask( signo );
do_callout = false;
a0010b4c: 01a00003 moveq r0, r3
}
_POSIX_signals_Clear_process_signals( signo );
do_callout = true;
}
} else {
if ( mask & (api->signals_pending & signals_blocked) ) {
a0010b50: 0a000002 beq a0010b60 <_POSIX_signals_Clear_signals+0x10c>
api->signals_pending &= ~mask;
a0010b54: e1cc1001 bic r1, ip, r1
a0010b58: e58010d4 str r1, [r0, #212] ; 0xd4
do_callout = true;
a0010b5c: e3a00001 mov r0, #1
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0010b60: e129f007 msr CPSR_fc, r7
}
}
_ISR_Enable( level );
return do_callout;
}
a0010b64: e8bd80f0 pop {r4, r5, r6, r7, pc}
a000a134 <_POSIX_signals_Get_lowest>:
sigset_t set
)
{
int signo;
for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {
a000a134: e3a0301b mov r3, #27 <== NOT EXECUTED
static inline sigset_t signo_to_mask(
uint32_t sig
)
{
return 1u << (sig - 1);
a000a138: e3a02001 mov r2, #1 <== NOT EXECUTED
#include <rtems/posix/psignal.h>
#include <rtems/seterr.h>
#include <rtems/posix/time.h>
#include <rtems/score/isr.h>
int _POSIX_signals_Get_lowest(
a000a13c: e2431001 sub r1, r3, #1 <== NOT EXECUTED
)
{
int signo;
for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {
if ( set & signo_to_mask( signo ) ) {
a000a140: e0101112 ands r1, r0, r2, lsl r1 <== NOT EXECUTED
a000a144: 1a00000a bne a000a174 <_POSIX_signals_Get_lowest+0x40> <== NOT EXECUTED
sigset_t set
)
{
int signo;
for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {
a000a148: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000a14c: e3530020 cmp r3, #32 <== NOT EXECUTED
a000a150: 1afffff9 bne a000a13c <_POSIX_signals_Get_lowest+0x8> <== NOT EXECUTED
a000a154: e3a03001 mov r3, #1 <== NOT EXECUTED
a000a158: e1a02003 mov r2, r3 <== NOT EXECUTED
#include <rtems/posix/psignal.h>
#include <rtems/seterr.h>
#include <rtems/posix/time.h>
#include <rtems/score/isr.h>
int _POSIX_signals_Get_lowest(
a000a15c: e2431001 sub r1, r3, #1 <== NOT EXECUTED
#if (SIGHUP != 1)
#error "Assumption that SIGHUP==1 violated!!"
#endif
for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) {
if ( set & signo_to_mask( signo ) ) {
a000a160: e0101112 ands r1, r0, r2, lsl r1 <== NOT EXECUTED
a000a164: 1a000002 bne a000a174 <_POSIX_signals_Get_lowest+0x40> <== NOT EXECUTED
*/
#if (SIGHUP != 1)
#error "Assumption that SIGHUP==1 violated!!"
#endif
for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) {
a000a168: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000a16c: e353001b cmp r3, #27 <== NOT EXECUTED
a000a170: 1afffff9 bne a000a15c <_POSIX_signals_Get_lowest+0x28> <== NOT EXECUTED
* a return 0. This routine will NOT be called unless a signal
* is pending in the set passed in.
*/
found_it:
return signo;
}
a000a174: e1a00003 mov r0, r3 <== NOT EXECUTED
a000a178: e12fff1e bx lr <== NOT EXECUTED
a0009294 <_POSIX_signals_Ualarm_TSR>:
void _POSIX_signals_Ualarm_TSR(
Objects_Id id __attribute__((unused)),
void *argument __attribute__((unused))
)
{
a0009294: e92d4010 push {r4, lr} <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Watchdog_Reset(
Watchdog_Control *the_watchdog
)
{
(void) _Watchdog_Remove( the_watchdog );
a0009298: e59f4020 ldr r4, [pc, #32] ; a00092c0 <_POSIX_signals_Ualarm_TSR+0x2c><== NOT EXECUTED
/*
* Send a SIGALRM but if there is a problem, ignore it.
* It's OK, there isn't a way this should fail.
*/
(void) kill( getpid(), SIGALRM );
a000929c: ebfff48a bl a00064cc <getpid> <== NOT EXECUTED
a00092a0: e3a0100e mov r1, #14 <== NOT EXECUTED
a00092a4: ebffff6d bl a0009060 <kill> <== NOT EXECUTED
a00092a8: e1a00004 mov r0, r4 <== NOT EXECUTED
a00092ac: eb000e73 bl a000cc80 <_Watchdog_Remove> <== NOT EXECUTED
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a00092b0: e59f000c ldr r0, [pc, #12] ; a00092c4 <_POSIX_signals_Ualarm_TSR+0x30><== NOT EXECUTED
a00092b4: e1a01004 mov r1, r4 <== NOT EXECUTED
/*
* If the reset interval is non-zero, reschedule ourselves.
*/
_Watchdog_Reset( &_POSIX_signals_Ualarm_timer );
}
a00092b8: e8bd4010 pop {r4, lr} <== NOT EXECUTED
a00092bc: ea000e17 b a000cb20 <_Watchdog_Insert> <== NOT EXECUTED
a0025acc <_POSIX_signals_Unblock_thread>:
bool _POSIX_signals_Unblock_thread(
Thread_Control *the_thread,
int signo,
siginfo_t *info
)
{
a0025acc: e92d41f0 push {r4, r5, r6, r7, r8, lr}
/*
* Is the thread is specifically waiting for a signal?
*/
if ( _States_Is_interruptible_signal( the_thread->current_state ) ) {
a0025ad0: e5903010 ldr r3, [r0, #16]
a0025ad4: e59f5110 ldr r5, [pc, #272] ; a0025bec <_POSIX_signals_Unblock_thread+0x120>
a0025ad8: e59f810c ldr r8, [pc, #268] ; a0025bec <_POSIX_signals_Unblock_thread+0x120>
a0025adc: e241c001 sub ip, r1, #1
a0025ae0: e0035005 and r5, r3, r5
a0025ae4: e3a06001 mov r6, #1
a0025ae8: e1550008 cmp r5, r8
bool _POSIX_signals_Unblock_thread(
Thread_Control *the_thread,
int signo,
siginfo_t *info
)
{
a0025aec: e1a04000 mov r4, r0
POSIX_API_Control *api;
sigset_t mask;
siginfo_t *the_info = NULL;
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
a0025af0: e59070fc ldr r7, [r0, #252] ; 0xfc
a0025af4: e1a0cc16 lsl ip, r6, ip
/*
* Is the thread is specifically waiting for a signal?
*/
if ( _States_Is_interruptible_signal( the_thread->current_state ) ) {
a0025af8: 1a000019 bne a0025b64 <_POSIX_signals_Unblock_thread+0x98>
if ( (the_thread->Wait.option & mask) || (~api->signals_blocked & mask) ) {
a0025afc: e5903030 ldr r3, [r0, #48] ; 0x30 <== NOT EXECUTED
a0025b00: e11c0003 tst ip, r3 <== NOT EXECUTED
a0025b04: 1a000002 bne a0025b14 <_POSIX_signals_Unblock_thread+0x48> <== NOT EXECUTED
a0025b08: e59750d0 ldr r5, [r7, #208] ; 0xd0 <== NOT EXECUTED
a0025b0c: e1dc5005 bics r5, ip, r5 <== NOT EXECUTED
a0025b10: 0a000033 beq a0025be4 <_POSIX_signals_Unblock_thread+0x118><== NOT EXECUTED
the_thread->Wait.return_code = EINTR;
a0025b14: e3a03004 mov r3, #4 <== NOT EXECUTED
the_info = (siginfo_t *) the_thread->Wait.return_argument;
if ( !info ) {
a0025b18: e3520000 cmp r2, #0 <== NOT EXECUTED
*/
if ( _States_Is_interruptible_signal( the_thread->current_state ) ) {
if ( (the_thread->Wait.option & mask) || (~api->signals_blocked & mask) ) {
the_thread->Wait.return_code = EINTR;
a0025b1c: e5843034 str r3, [r4, #52] ; 0x34 <== NOT EXECUTED
the_info = (siginfo_t *) the_thread->Wait.return_argument;
a0025b20: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED
if ( !info ) {
the_info->si_signo = signo;
a0025b24: 05831000 streq r1, [r3] <== NOT EXECUTED
the_info->si_code = SI_USER;
a0025b28: 03a01001 moveq r1, #1 <== NOT EXECUTED
a0025b2c: 09830006 stmibeq r3, {r1, r2} <== NOT EXECUTED
a0025b30: 0a000007 beq a0025b54 <_POSIX_signals_Unblock_thread+0x88> <== NOT EXECUTED
the_info->si_value.sival_int = 0;
} else {
*the_info = *info;
a0025b34: e1a00002 mov r0, r2 <== NOT EXECUTED
a0025b38: e490c004 ldr ip, [r0], #4 <== NOT EXECUTED
a0025b3c: e1a01003 mov r1, r3 <== NOT EXECUTED
a0025b40: e481c004 str ip, [r1], #4 <== NOT EXECUTED
a0025b44: e5922004 ldr r2, [r2, #4] <== NOT EXECUTED
a0025b48: e5832004 str r2, [r3, #4] <== NOT EXECUTED
a0025b4c: e5903004 ldr r3, [r0, #4] <== NOT EXECUTED
a0025b50: e5813004 str r3, [r1, #4] <== NOT EXECUTED
}
_Thread_queue_Extract_with_proxy( the_thread );
a0025b54: e1a00004 mov r0, r4 <== NOT EXECUTED
a0025b58: ebffacad bl a0010e14 <_Thread_queue_Extract_with_proxy> <== NOT EXECUTED
return true;
a0025b5c: e3a05001 mov r5, #1 <== NOT EXECUTED
a0025b60: ea00001f b a0025be4 <_POSIX_signals_Unblock_thread+0x118> <== NOT EXECUTED
}
/*
* Thread is not waiting due to a sigwait.
*/
if ( ~api->signals_blocked & mask ) {
a0025b64: e59750d0 ldr r5, [r7, #208] ; 0xd0
a0025b68: e1dc5005 bics r5, ip, r5
a0025b6c: 0a00001c beq a0025be4 <_POSIX_signals_Unblock_thread+0x118>
* it is not blocked, THEN
* we need to dispatch at the end of this ISR.
* + Any other combination, do nothing.
*/
if ( _States_Is_interruptible_by_signal( the_thread->current_state ) ) {
a0025b70: e2135201 ands r5, r3, #268435456 ; 0x10000000 <== NOT EXECUTED
a0025b74: 0a000010 beq a0025bbc <_POSIX_signals_Unblock_thread+0xf0> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE bool _States_Is_waiting_on_thread_queue (
States_Control the_states
)
{
return (the_states & STATES_WAITING_ON_THREAD_QUEUE);
a0025b78: e59f5070 ldr r5, [pc, #112] ; a0025bf0 <_POSIX_signals_Unblock_thread+0x124><== NOT EXECUTED
the_thread->Wait.return_code = EINTR;
a0025b7c: e3a02004 mov r2, #4 <== NOT EXECUTED
a0025b80: e5802034 str r2, [r0, #52] ; 0x34 <== NOT EXECUTED
a0025b84: e0035005 and r5, r3, r5 <== NOT EXECUTED
/*
* In pthread_cond_wait, a thread will be blocking on a thread
* queue, but is also interruptible by a POSIX signal.
*/
if ( _States_Is_waiting_on_thread_queue(the_thread->current_state) )
a0025b88: e3550000 cmp r5, #0 <== NOT EXECUTED
a0025b8c: 0a000002 beq a0025b9c <_POSIX_signals_Unblock_thread+0xd0> <== NOT EXECUTED
_Thread_queue_Extract_with_proxy( the_thread );
a0025b90: ebffac9f bl a0010e14 <_Thread_queue_Extract_with_proxy> <== NOT EXECUTED
} else if ( the_thread->current_state == STATES_READY ) {
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
_Thread_Dispatch_necessary = true;
}
}
return false;
a0025b94: e3a05000 mov r5, #0 <== NOT EXECUTED
a0025b98: ea000011 b a0025be4 <_POSIX_signals_Unblock_thread+0x118> <== NOT EXECUTED
* In pthread_cond_wait, a thread will be blocking on a thread
* queue, but is also interruptible by a POSIX signal.
*/
if ( _States_Is_waiting_on_thread_queue(the_thread->current_state) )
_Thread_queue_Extract_with_proxy( the_thread );
else if ( _States_Is_delaying(the_thread->current_state) ) {
a0025b9c: e2133008 ands r3, r3, #8 <== NOT EXECUTED
a0025ba0: 0a00000e beq a0025be0 <_POSIX_signals_Unblock_thread+0x114><== NOT EXECUTED
(void) _Watchdog_Remove( &the_thread->Timer );
a0025ba4: e2800048 add r0, r0, #72 ; 0x48 <== NOT EXECUTED
a0025ba8: ebffaec2 bl a00116b8 <_Watchdog_Remove> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
a0025bac: e1a00004 mov r0, r4 <== NOT EXECUTED
a0025bb0: e59f103c ldr r1, [pc, #60] ; a0025bf4 <_POSIX_signals_Unblock_thread+0x128><== NOT EXECUTED
a0025bb4: ebffaa14 bl a001040c <_Thread_Clear_state> <== NOT EXECUTED
a0025bb8: ea000009 b a0025be4 <_POSIX_signals_Unblock_thread+0x118> <== NOT EXECUTED
_Thread_Unblock( the_thread );
}
} else if ( the_thread->current_state == STATES_READY ) {
a0025bbc: e3530000 cmp r3, #0 <== NOT EXECUTED
a0025bc0: 1a000007 bne a0025be4 <_POSIX_signals_Unblock_thread+0x118><== NOT EXECUTED
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
a0025bc4: e59f202c ldr r2, [pc, #44] ; a0025bf8 <_POSIX_signals_Unblock_thread+0x12c><== NOT EXECUTED
a0025bc8: e5925000 ldr r5, [r2] <== NOT EXECUTED
a0025bcc: e3550000 cmp r5, #0 <== NOT EXECUTED
a0025bd0: 0a000003 beq a0025be4 <_POSIX_signals_Unblock_thread+0x118><== NOT EXECUTED
a0025bd4: e5921004 ldr r1, [r2, #4] <== NOT EXECUTED
a0025bd8: e1500001 cmp r0, r1 <== NOT EXECUTED
_Thread_Dispatch_necessary = true;
a0025bdc: 05c26010 strbeq r6, [r2, #16] <== NOT EXECUTED
}
}
return false;
a0025be0: e1a05003 mov r5, r3 <== NOT EXECUTED
}
a0025be4: e1a00005 mov r0, r5
a0025be8: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a000b508 <_Protected_heap_Get_information>:
bool _Protected_heap_Get_information(
Heap_Control *the_heap,
Heap_Information_block *the_info
)
{
a000b508: e92d4070 push {r4, r5, r6, lr}
if ( !the_heap )
a000b50c: e2506000 subs r6, r0, #0
bool _Protected_heap_Get_information(
Heap_Control *the_heap,
Heap_Information_block *the_info
)
{
a000b510: e1a05001 mov r5, r1
if ( !the_heap )
a000b514: 0a00000b beq a000b548 <_Protected_heap_Get_information+0x40>
return false;
if ( !the_info )
a000b518: e3510000 cmp r1, #0
a000b51c: 0a00000b beq a000b550 <_Protected_heap_Get_information+0x48>
return false;
_RTEMS_Lock_allocator();
a000b520: e59f4030 ldr r4, [pc, #48] ; a000b558 <_Protected_heap_Get_information+0x50>
a000b524: e5940000 ldr r0, [r4]
a000b528: ebfffba9 bl a000a3d4 <_API_Mutex_Lock>
_Heap_Get_information( the_heap, the_info );
a000b52c: e1a00006 mov r0, r6
a000b530: e1a01005 mov r1, r5
a000b534: eb0011fb bl a000fd28 <_Heap_Get_information>
_RTEMS_Unlock_allocator();
a000b538: e5940000 ldr r0, [r4]
a000b53c: ebfffbbd bl a000a438 <_API_Mutex_Unlock>
return true;
a000b540: e3a00001 mov r0, #1
a000b544: e8bd8070 pop {r4, r5, r6, pc}
Heap_Control *the_heap,
Heap_Information_block *the_info
)
{
if ( !the_heap )
return false;
a000b548: e1a00006 mov r0, r6
a000b54c: e8bd8070 pop {r4, r5, r6, pc}
if ( !the_info )
return false;
a000b550: e1a00001 mov r0, r1
_RTEMS_Lock_allocator();
_Heap_Get_information( the_heap, the_info );
_RTEMS_Unlock_allocator();
return true;
}
a000b554: e8bd8070 pop {r4, r5, r6, pc}
a000ff78 <_Protected_heap_Walk>:
* then it is forbidden to lock a mutex. But since we are inside
* a critical section, it should be safe to walk it unlocked.
*
* NOTE: Dispatching is also disabled during initialization.
*/
if ( !_Thread_Dispatch_disable_level ) {
a000ff78: e59f3054 ldr r3, [pc, #84] ; a000ffd4 <_Protected_heap_Walk+0x5c><== NOT EXECUTED
bool _Protected_heap_Walk(
Heap_Control *the_heap,
int source,
bool do_dump
)
{
a000ff7c: e92d40f0 push {r4, r5, r6, r7, lr} <== NOT EXECUTED
* then it is forbidden to lock a mutex. But since we are inside
* a critical section, it should be safe to walk it unlocked.
*
* NOTE: Dispatching is also disabled during initialization.
*/
if ( !_Thread_Dispatch_disable_level ) {
a000ff80: e5933000 ldr r3, [r3] <== NOT EXECUTED
bool _Protected_heap_Walk(
Heap_Control *the_heap,
int source,
bool do_dump
)
{
a000ff84: e1a06000 mov r6, r0 <== NOT EXECUTED
a000ff88: e1a05001 mov r5, r1 <== NOT EXECUTED
* then it is forbidden to lock a mutex. But since we are inside
* a critical section, it should be safe to walk it unlocked.
*
* NOTE: Dispatching is also disabled during initialization.
*/
if ( !_Thread_Dispatch_disable_level ) {
a000ff8c: e3530000 cmp r3, #0 <== NOT EXECUTED
bool _Protected_heap_Walk(
Heap_Control *the_heap,
int source,
bool do_dump
)
{
a000ff90: e20270ff and r7, r2, #255 ; 0xff <== NOT EXECUTED
* then it is forbidden to lock a mutex. But since we are inside
* a critical section, it should be safe to walk it unlocked.
*
* NOTE: Dispatching is also disabled during initialization.
*/
if ( !_Thread_Dispatch_disable_level ) {
a000ff94: 1a00000b bne a000ffc8 <_Protected_heap_Walk+0x50> <== NOT EXECUTED
_RTEMS_Lock_allocator();
a000ff98: e59f4038 ldr r4, [pc, #56] ; a000ffd8 <_Protected_heap_Walk+0x60><== NOT EXECUTED
a000ff9c: e5940000 ldr r0, [r4] <== NOT EXECUTED
a000ffa0: ebfff85d bl a000e11c <_API_Mutex_Lock> <== NOT EXECUTED
status = _Heap_Walk( the_heap, source, do_dump );
a000ffa4: e1a01005 mov r1, r5 <== NOT EXECUTED
a000ffa8: e1a02007 mov r2, r7 <== NOT EXECUTED
a000ffac: e1a00006 mov r0, r6 <== NOT EXECUTED
a000ffb0: ebfffc34 bl a000f088 <_Heap_Walk> <== NOT EXECUTED
a000ffb4: e1a05000 mov r5, r0 <== NOT EXECUTED
_RTEMS_Unlock_allocator();
a000ffb8: e5940000 ldr r0, [r4] <== NOT EXECUTED
a000ffbc: ebfff86f bl a000e180 <_API_Mutex_Unlock> <== NOT EXECUTED
} else {
status = _Heap_Walk( the_heap, source, do_dump );
}
return status;
}
a000ffc0: e1a00005 mov r0, r5 <== NOT EXECUTED
a000ffc4: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
if ( !_Thread_Dispatch_disable_level ) {
_RTEMS_Lock_allocator();
status = _Heap_Walk( the_heap, source, do_dump );
_RTEMS_Unlock_allocator();
} else {
status = _Heap_Walk( the_heap, source, do_dump );
a000ffc8: e1a02007 mov r2, r7 <== NOT EXECUTED
}
return status;
}
a000ffcc: e8bd40f0 pop {r4, r5, r6, r7, lr} <== NOT EXECUTED
if ( !_Thread_Dispatch_disable_level ) {
_RTEMS_Lock_allocator();
status = _Heap_Walk( the_heap, source, do_dump );
_RTEMS_Unlock_allocator();
} else {
status = _Heap_Walk( the_heap, source, do_dump );
a000ffd0: eafffc2c b a000f088 <_Heap_Walk> <== NOT EXECUTED
a000ecc0 <_RTEMS_Tasks_Invoke_task_variable_dtor>:
RTEMS_INLINE_ROUTINE bool _Thread_Is_executing (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Executing );
a000ecc0: e59f203c ldr r2, [pc, #60] ; a000ed04 <_RTEMS_Tasks_Invoke_task_variable_dtor+0x44><== NOT EXECUTED
)
{
void (*dtor)(void *);
void *value;
dtor = tvp->dtor;
a000ecc4: e5913010 ldr r3, [r1, #16] <== NOT EXECUTED
void _RTEMS_Tasks_Invoke_task_variable_dtor(
Thread_Control *the_thread,
rtems_task_variable_t *tvp
)
{
a000ecc8: e92d4010 push {r4, lr} <== NOT EXECUTED
void (*dtor)(void *);
void *value;
dtor = tvp->dtor;
if (_Thread_Is_executing(the_thread)) {
a000eccc: e5922004 ldr r2, [r2, #4] <== NOT EXECUTED
void _RTEMS_Tasks_Invoke_task_variable_dtor(
Thread_Control *the_thread,
rtems_task_variable_t *tvp
)
{
a000ecd0: e1a04001 mov r4, r1 <== NOT EXECUTED
void (*dtor)(void *);
void *value;
dtor = tvp->dtor;
if (_Thread_Is_executing(the_thread)) {
a000ecd4: e1520000 cmp r2, r0 <== NOT EXECUTED
value = *tvp->ptr;
a000ecd8: 05912004 ldreq r2, [r1, #4] <== NOT EXECUTED
*tvp->ptr = tvp->gval;
a000ecdc: 05911008 ldreq r1, [r1, #8] <== NOT EXECUTED
} else {
value = tvp->tval;
a000ece0: 1594000c ldrne r0, [r4, #12] <== NOT EXECUTED
void (*dtor)(void *);
void *value;
dtor = tvp->dtor;
if (_Thread_Is_executing(the_thread)) {
value = *tvp->ptr;
a000ece4: 05920000 ldreq r0, [r2] <== NOT EXECUTED
*tvp->ptr = tvp->gval;
a000ece8: 05821000 streq r1, [r2] <== NOT EXECUTED
} else {
value = tvp->tval;
}
if ( dtor )
a000ecec: e3530000 cmp r3, #0 <== NOT EXECUTED
a000ecf0: 0a000000 beq a000ecf8 <_RTEMS_Tasks_Invoke_task_variable_dtor+0x38><== NOT EXECUTED
(*dtor)(value);
a000ecf4: e12fff33 blx r3 <== NOT EXECUTED
_Workspace_Free(tvp);
a000ecf8: e1a00004 mov r0, r4 <== NOT EXECUTED
}
a000ecfc: e8bd4010 pop {r4, lr} <== NOT EXECUTED
}
if ( dtor )
(*dtor)(value);
_Workspace_Free(tvp);
a000ed00: eafff6b0 b a000c7c8 <_Workspace_Free> <== NOT EXECUTED
a000eb98 <_RTEMS_tasks_Delete_extension>:
/*
* Free per task variable memory
*/
tvp = deleted->task_variables;
deleted->task_variables = NULL;
a000eb98: e3a03000 mov r3, #0
void _RTEMS_tasks_Delete_extension(
Thread_Control *executing,
Thread_Control *deleted
)
{
a000eb9c: e92d4070 push {r4, r5, r6, lr}
/*
* Free per task variable memory
*/
tvp = deleted->task_variables;
a000eba0: e5916104 ldr r6, [r1, #260] ; 0x104
void _RTEMS_tasks_Delete_extension(
Thread_Control *executing,
Thread_Control *deleted
)
{
a000eba4: e1a04001 mov r4, r1
/*
* Free per task variable memory
*/
tvp = deleted->task_variables;
deleted->task_variables = NULL;
a000eba8: e5813104 str r3, [r1, #260] ; 0x104
while (tvp) {
a000ebac: ea000004 b a000ebc4 <_RTEMS_tasks_Delete_extension+0x2c>
next = (rtems_task_variable_t *)tvp->next;
_RTEMS_Tasks_Invoke_task_variable_dtor( deleted, tvp );
a000ebb0: e1a01006 mov r1, r6 <== NOT EXECUTED
a000ebb4: e1a00004 mov r0, r4 <== NOT EXECUTED
*/
tvp = deleted->task_variables;
deleted->task_variables = NULL;
while (tvp) {
next = (rtems_task_variable_t *)tvp->next;
a000ebb8: e5965000 ldr r5, [r6] <== NOT EXECUTED
_RTEMS_Tasks_Invoke_task_variable_dtor( deleted, tvp );
a000ebbc: eb00003f bl a000ecc0 <_RTEMS_Tasks_Invoke_task_variable_dtor><== NOT EXECUTED
tvp = next;
a000ebc0: e1a06005 mov r6, r5 <== NOT EXECUTED
* Free per task variable memory
*/
tvp = deleted->task_variables;
deleted->task_variables = NULL;
while (tvp) {
a000ebc4: e3560000 cmp r6, #0
a000ebc8: 1afffff8 bne a000ebb0 <_RTEMS_tasks_Delete_extension+0x18>
/*
* Free API specific memory
*/
(void) _Workspace_Free( deleted->API_Extensions[ THREAD_API_RTEMS ] );
a000ebcc: e59400f8 ldr r0, [r4, #248] ; 0xf8
a000ebd0: ebfff6fc bl a000c7c8 <_Workspace_Free>
deleted->API_Extensions[ THREAD_API_RTEMS ] = NULL;
a000ebd4: e58460f8 str r6, [r4, #248] ; 0xf8
}
a000ebd8: e8bd8070 pop {r4, r5, r6, pc}
a000eaa0 <_RTEMS_tasks_Switch_extension>:
/*
* Per Task Variables
*/
tvp = executing->task_variables;
a000eaa0: e5903104 ldr r3, [r0, #260] ; 0x104
while (tvp) {
a000eaa4: ea000005 b a000eac0 <_RTEMS_tasks_Switch_extension+0x20>
tvp->tval = *tvp->ptr;
a000eaa8: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED
a000eaac: e5920000 ldr r0, [r2] <== NOT EXECUTED
a000eab0: e583000c str r0, [r3, #12] <== NOT EXECUTED
*tvp->ptr = tvp->gval;
a000eab4: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED
tvp = (rtems_task_variable_t *)tvp->next;
a000eab8: e5933000 ldr r3, [r3] <== NOT EXECUTED
*/
tvp = executing->task_variables;
while (tvp) {
tvp->tval = *tvp->ptr;
*tvp->ptr = tvp->gval;
a000eabc: e5820000 str r0, [r2] <== NOT EXECUTED
/*
* Per Task Variables
*/
tvp = executing->task_variables;
while (tvp) {
a000eac0: e3530000 cmp r3, #0
a000eac4: 1afffff7 bne a000eaa8 <_RTEMS_tasks_Switch_extension+0x8>
tvp->tval = *tvp->ptr;
*tvp->ptr = tvp->gval;
tvp = (rtems_task_variable_t *)tvp->next;
}
tvp = heir->task_variables;
a000eac8: e5913104 ldr r3, [r1, #260] ; 0x104
while (tvp) {
a000eacc: ea000005 b a000eae8 <_RTEMS_tasks_Switch_extension+0x48>
tvp->gval = *tvp->ptr;
a000ead0: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED
a000ead4: e5921000 ldr r1, [r2] <== NOT EXECUTED
a000ead8: e5831008 str r1, [r3, #8] <== NOT EXECUTED
*tvp->ptr = tvp->tval;
a000eadc: e593100c ldr r1, [r3, #12] <== NOT EXECUTED
tvp = (rtems_task_variable_t *)tvp->next;
a000eae0: e5933000 ldr r3, [r3] <== NOT EXECUTED
}
tvp = heir->task_variables;
while (tvp) {
tvp->gval = *tvp->ptr;
*tvp->ptr = tvp->tval;
a000eae4: e5821000 str r1, [r2] <== NOT EXECUTED
*tvp->ptr = tvp->gval;
tvp = (rtems_task_variable_t *)tvp->next;
}
tvp = heir->task_variables;
while (tvp) {
a000eae8: e3530000 cmp r3, #0
a000eaec: 1afffff7 bne a000ead0 <_RTEMS_tasks_Switch_extension+0x30>
tvp->gval = *tvp->ptr;
*tvp->ptr = tvp->tval;
tvp = (rtems_task_variable_t *)tvp->next;
}
}
a000eaf0: e12fff1e bx lr
a000a8b8 <_Rate_monotonic_Timeout>:
void _Rate_monotonic_Timeout(
Objects_Id id,
void *ignored
)
{
a000a8b8: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
a000a8bc: e1a01000 mov r1, r0 <== NOT EXECUTED
a000a8c0: e1a0200d mov r2, sp <== NOT EXECUTED
a000a8c4: e59f0088 ldr r0, [pc, #136] ; a000a954 <_Rate_monotonic_Timeout+0x9c><== NOT EXECUTED
a000a8c8: eb000747 bl a000c5ec <_Objects_Get> <== NOT EXECUTED
/*
* When we get here, the Timer is already off the chain so we do not
* have to worry about that -- hence no _Watchdog_Remove().
*/
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a000a8cc: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a000a8d0: e1a04000 mov r4, r0 <== NOT EXECUTED
a000a8d4: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a8d8: 1a00001c bne a000a950 <_Rate_monotonic_Timeout+0x98> <== NOT EXECUTED
case OBJECTS_LOCAL:
the_thread = the_period->owner;
a000a8dc: e5900040 ldr r0, [r0, #64] ; 0x40 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE bool _States_Is_waiting_for_period (
States_Control the_states
)
{
return (the_states & STATES_WAITING_FOR_PERIOD);
a000a8e0: e5903010 ldr r3, [r0, #16] <== NOT EXECUTED
if ( _States_Is_waiting_for_period( the_thread->current_state ) &&
a000a8e4: e3130901 tst r3, #16384 ; 0x4000 <== NOT EXECUTED
a000a8e8: 0a000006 beq a000a908 <_Rate_monotonic_Timeout+0x50> <== NOT EXECUTED
a000a8ec: e5902020 ldr r2, [r0, #32] <== NOT EXECUTED
a000a8f0: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED
a000a8f4: e1520003 cmp r2, r3 <== NOT EXECUTED
a000a8f8: 1a000002 bne a000a908 <_Rate_monotonic_Timeout+0x50> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
a000a8fc: e59f1054 ldr r1, [pc, #84] ; a000a958 <_Rate_monotonic_Timeout+0xa0><== NOT EXECUTED
a000a900: eb00094a bl a000ce30 <_Thread_Clear_state> <== NOT EXECUTED
a000a904: ea000006 b a000a924 <_Rate_monotonic_Timeout+0x6c> <== NOT EXECUTED
_Thread_Unblock( the_thread );
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) {
a000a908: e5943038 ldr r3, [r4, #56] ; 0x38 <== NOT EXECUTED
a000a90c: e3530001 cmp r3, #1 <== NOT EXECUTED
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else
the_period->state = RATE_MONOTONIC_EXPIRED;
a000a910: 13a03004 movne r3, #4 <== NOT EXECUTED
a000a914: 15843038 strne r3, [r4, #56] ; 0x38 <== NOT EXECUTED
_Thread_Unblock( the_thread );
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) {
a000a918: 1a000008 bne a000a940 <_Rate_monotonic_Timeout+0x88> <== NOT EXECUTED
the_period->state = RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING;
a000a91c: e2833002 add r3, r3, #2 <== NOT EXECUTED
a000a920: e5843038 str r3, [r4, #56] ; 0x38 <== NOT EXECUTED
_Rate_monotonic_Initiate_statistics( the_period );
a000a924: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a928: ebfffe82 bl a000a338 <_Rate_monotonic_Initiate_statistics> <== NOT EXECUTED
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000a92c: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a000a930: e59f0024 ldr r0, [pc, #36] ; a000a95c <_Rate_monotonic_Timeout+0xa4><== NOT EXECUTED
a000a934: e2841010 add r1, r4, #16 <== NOT EXECUTED
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000a938: e584301c str r3, [r4, #28] <== NOT EXECUTED
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a000a93c: eb000ddc bl a000e0b4 <_Watchdog_Insert> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
a000a940: e59f3018 ldr r3, [pc, #24] ; a000a960 <_Rate_monotonic_Timeout+0xa8><== NOT EXECUTED
a000a944: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000a948: e2422001 sub r2, r2, #1 <== NOT EXECUTED
a000a94c: e5832000 str r2, [r3] <== NOT EXECUTED
case OBJECTS_REMOTE: /* impossible */
#endif
case OBJECTS_ERROR:
break;
}
}
a000a950: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000a568 <_TOD_Get_uptime_as_timespec>:
*/
void _TOD_Get_uptime_as_timespec(
struct timespec *uptime
)
{
a000a568: e92d4013 push {r0, r1, r4, lr} <== NOT EXECUTED
a000a56c: e1a04000 mov r4, r0 <== NOT EXECUTED
Timestamp_Control uptime_ts;
/* assume time checked for NULL by caller */
_TOD_Get_uptime( &uptime_ts );
a000a570: e1a0000d mov r0, sp <== NOT EXECUTED
a000a574: eb001386 bl a000f394 <_TOD_Get_uptime> <== NOT EXECUTED
_Timestamp_To_timespec( &uptime_ts, uptime );
a000a578: e89d000c ldm sp, {r2, r3} <== NOT EXECUTED
a000a57c: e884000c stm r4, {r2, r3} <== NOT EXECUTED
}
a000a580: e8bd801c pop {r2, r3, r4, pc} <== NOT EXECUTED
a000a1e4 <_TOD_Tickle_ticks>:
*
* Output parameters: NONE
*/
void _TOD_Tickle_ticks( void )
{
a000a1e4: e92d4013 push {r0, r1, r4, lr}
Timestamp_Control tick;
uint32_t seconds;
/* Convert the tick quantum to a timestamp */
_Timestamp_Set( &tick, 0, rtems_configuration_get_nanoseconds_per_tick() );
a000a1e8: e3a03000 mov r3, #0
a000a1ec: e58d3000 str r3, [sp]
a000a1f0: e59f3054 ldr r3, [pc, #84] ; a000a24c <_TOD_Tickle_ticks+0x68>
a000a1f4: e3a02ffa mov r2, #1000 ; 0x3e8
/* Update the counter of ticks since boot */
_Watchdog_Ticks_since_boot += 1;
/* Update the timespec format uptime */
_Timestamp_Add_to( &_TOD_Uptime, &tick );
a000a1f8: e1a0100d mov r1, sp
{
Timestamp_Control tick;
uint32_t seconds;
/* Convert the tick quantum to a timestamp */
_Timestamp_Set( &tick, 0, rtems_configuration_get_nanoseconds_per_tick() );
a000a1fc: e593300c ldr r3, [r3, #12]
/* Update the counter of ticks since boot */
_Watchdog_Ticks_since_boot += 1;
/* Update the timespec format uptime */
_Timestamp_Add_to( &_TOD_Uptime, &tick );
a000a200: e59f0048 ldr r0, [pc, #72] ; a000a250 <_TOD_Tickle_ticks+0x6c>
{
Timestamp_Control tick;
uint32_t seconds;
/* Convert the tick quantum to a timestamp */
_Timestamp_Set( &tick, 0, rtems_configuration_get_nanoseconds_per_tick() );
a000a204: e0030392 mul r3, r2, r3
a000a208: e58d3004 str r3, [sp, #4]
/* Update the counter of ticks since boot */
_Watchdog_Ticks_since_boot += 1;
a000a20c: e59f3040 ldr r3, [pc, #64] ; a000a254 <_TOD_Tickle_ticks+0x70>
a000a210: e5932000 ldr r2, [r3]
a000a214: e2822001 add r2, r2, #1
a000a218: e5832000 str r2, [r3]
/* Update the timespec format uptime */
_Timestamp_Add_to( &_TOD_Uptime, &tick );
a000a21c: eb0007d9 bl a000c188 <_Timespec_Add_to>
/* we do not care how much the uptime changed */
/* Update the timespec format TOD */
seconds = _Timestamp_Add_to_at_tick( &_TOD_Now, &tick );
a000a220: e59f0030 ldr r0, [pc, #48] ; a000a258 <_TOD_Tickle_ticks+0x74>
a000a224: e1a0100d mov r1, sp
a000a228: eb0007d6 bl a000c188 <_Timespec_Add_to>
a000a22c: e1a04000 mov r4, r0
while ( seconds ) {
a000a230: ea000002 b a000a240 <_TOD_Tickle_ticks+0x5c>
*/
RTEMS_INLINE_ROUTINE void _Watchdog_Tickle_seconds( void )
{
_Watchdog_Tickle( &_Watchdog_Seconds_chain );
a000a234: e59f0020 ldr r0, [pc, #32] ; a000a25c <_TOD_Tickle_ticks+0x78><== NOT EXECUTED
a000a238: eb00091f bl a000c6bc <_Watchdog_Tickle> <== NOT EXECUTED
_Watchdog_Tickle_seconds();
seconds--;
a000a23c: e2444001 sub r4, r4, #1 <== NOT EXECUTED
_Timestamp_Add_to( &_TOD_Uptime, &tick );
/* we do not care how much the uptime changed */
/* Update the timespec format TOD */
seconds = _Timestamp_Add_to_at_tick( &_TOD_Now, &tick );
while ( seconds ) {
a000a240: e3540000 cmp r4, #0
a000a244: 1afffffa bne a000a234 <_TOD_Tickle_ticks+0x50>
_Watchdog_Tickle_seconds();
seconds--;
}
}
a000a248: e8bd801c pop {r2, r3, r4, pc}
a000a3c8 <_TOD_Validate>:
{
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
a000a3c8: e59f30b4 ldr r3, [pc, #180] ; a000a484 <_TOD_Validate+0xbc>
*/
bool _TOD_Validate(
const rtems_time_of_day *the_tod
)
{
a000a3cc: e92d4010 push {r4, lr}
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
a000a3d0: e2504000 subs r4, r0, #0
{
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
a000a3d4: e593100c ldr r1, [r3, #12]
if ((!the_tod) ||
a000a3d8: 0a000021 beq a000a464 <_TOD_Validate+0x9c>
)
{
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
a000a3dc: e59f00a4 ldr r0, [pc, #164] ; a000a488 <_TOD_Validate+0xc0>
a000a3e0: eb004815 bl a001c43c <__aeabi_uidiv>
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
a000a3e4: e5943018 ldr r3, [r4, #24]
a000a3e8: e1530000 cmp r3, r0
a000a3ec: 2a000020 bcs a000a474 <_TOD_Validate+0xac>
(the_tod->ticks >= ticks_per_second) ||
a000a3f0: e5943014 ldr r3, [r4, #20]
a000a3f4: e353003b cmp r3, #59 ; 0x3b
a000a3f8: 8a00001d bhi a000a474 <_TOD_Validate+0xac>
(the_tod->second >= TOD_SECONDS_PER_MINUTE) ||
a000a3fc: e5943010 ldr r3, [r4, #16]
a000a400: e353003b cmp r3, #59 ; 0x3b
a000a404: 8a00001a bhi a000a474 <_TOD_Validate+0xac>
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
a000a408: e594300c ldr r3, [r4, #12]
a000a40c: e3530017 cmp r3, #23
a000a410: 8a000017 bhi a000a474 <_TOD_Validate+0xac>
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
(the_tod->month == 0) ||
a000a414: e5943004 ldr r3, [r4, #4]
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
(the_tod->ticks >= ticks_per_second) ||
(the_tod->second >= TOD_SECONDS_PER_MINUTE) ||
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
a000a418: e3530000 cmp r3, #0
a000a41c: 0a000012 beq a000a46c <_TOD_Validate+0xa4>
(the_tod->month == 0) ||
a000a420: e353000c cmp r3, #12
a000a424: 8a000012 bhi a000a474 <_TOD_Validate+0xac>
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
a000a428: e5942000 ldr r2, [r4]
(the_tod->ticks >= ticks_per_second) ||
(the_tod->second >= TOD_SECONDS_PER_MINUTE) ||
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
(the_tod->month == 0) ||
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
a000a42c: e59f1058 ldr r1, [pc, #88] ; a000a48c <_TOD_Validate+0xc4>
a000a430: e1520001 cmp r2, r1
a000a434: 9a000010 bls a000a47c <_TOD_Validate+0xb4>
(the_tod->year < TOD_BASE_YEAR) ||
(the_tod->day == 0) )
a000a438: e5940008 ldr r0, [r4, #8]
(the_tod->second >= TOD_SECONDS_PER_MINUTE) ||
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
(the_tod->month == 0) ||
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
a000a43c: e3500000 cmp r0, #0
a000a440: 0a00000e beq a000a480 <_TOD_Validate+0xb8>
(the_tod->day == 0) )
return false;
if ( (the_tod->year % 4) == 0 )
a000a444: e3120003 tst r2, #3
a000a448: e59f2040 ldr r2, [pc, #64] ; a000a490 <_TOD_Validate+0xc8>
days_in_month = _TOD_Days_per_month[ 1 ][ the_tod->month ];
a000a44c: 0283300d addeq r3, r3, #13
else
days_in_month = _TOD_Days_per_month[ 0 ][ the_tod->month ];
a000a450: e7924103 ldr r4, [r2, r3, lsl #2]
* false - if the the_tod is invalid
*
* NOTE: This routine only works for leap-years through 2099.
*/
bool _TOD_Validate(
a000a454: e1500004 cmp r0, r4
a000a458: 83a00000 movhi r0, #0
a000a45c: 93a00001 movls r0, #1
a000a460: e8bd8010 pop {r4, pc}
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
(the_tod->month == 0) ||
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
(the_tod->day == 0) )
return false;
a000a464: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a468: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000a46c: e1a00003 mov r0, r3 <== NOT EXECUTED
a000a470: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000a474: e3a00000 mov r0, #0 <== NOT EXECUTED
a000a478: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000a47c: e3a00000 mov r0, #0 <== NOT EXECUTED
if ( the_tod->day > days_in_month )
return false;
return true;
}
a000a480: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000b3b8 <_Thread_Close>:
RTEMS_INLINE_ROUTINE void _Objects_Invalidate_Id(
Objects_Information *information,
Objects_Control *the_object
)
{
_Objects_Set_local_object(
a000b3b8: e1d120b8 ldrh r2, [r1, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000b3bc: e590301c ldr r3, [r0, #28]
void _Thread_Close(
Objects_Information *information,
Thread_Control *the_thread
)
{
a000b3c0: e92d4070 push {r4, r5, r6, lr}
a000b3c4: e1a04001 mov r4, r1
a000b3c8: e3a01000 mov r1, #0
a000b3cc: e7831102 str r1, [r3, r2, lsl #2]
a000b3d0: e1a05000 mov r5, r0
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
a000b3d4: e59f6094 ldr r6, [pc, #148] ; a000b470 <_Thread_Close+0xb8>
* disappear and set a transient state on it. So we temporarily
* unnest dispatching.
*/
_Thread_Unnest_dispatch();
_User_extensions_Thread_delete( the_thread );
a000b3d8: e1a00004 mov r0, r4
a000b3dc: e5963000 ldr r3, [r6]
a000b3e0: e2433001 sub r3, r3, #1
a000b3e4: e5863000 str r3, [r6]
a000b3e8: eb0003ff bl a000c3ec <_User_extensions_Thread_delete>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000b3ec: e5963000 ldr r3, [r6]
a000b3f0: e2833001 add r3, r3, #1
a000b3f4: e5863000 str r3, [r6]
/*
* Now we are in a dispatching critical section again and we
* can take the thread OUT of the published set. It is invalid
* to use this thread's Id OR name after this call.
*/
_Objects_Close( information, &the_thread->Object );
a000b3f8: e1a00005 mov r0, r5
a000b3fc: e1a01004 mov r1, r4
a000b400: ebfffcc9 bl a000a72c <_Objects_Close>
/*
* By setting the dormant state, the thread will not be considered
* for scheduling when we remove any blocking states.
*/
_Thread_Set_state( the_thread, STATES_DORMANT );
a000b404: e1a00004 mov r0, r4
a000b408: e3a01001 mov r1, #1
a000b40c: eb0002b6 bl a000beec <_Thread_Set_state>
if ( !_Thread_queue_Extract_with_proxy( the_thread ) ) {
a000b410: e1a00004 mov r0, r4
a000b414: eb000256 bl a000bd74 <_Thread_queue_Extract_with_proxy>
a000b418: e3500000 cmp r0, #0
a000b41c: 1a000004 bne a000b434 <_Thread_Close+0x7c>
if ( _Watchdog_Is_active( &the_thread->Timer ) )
a000b420: e5943050 ldr r3, [r4, #80] ; 0x50
a000b424: e3530002 cmp r3, #2
a000b428: 1a000001 bne a000b434 <_Thread_Close+0x7c>
(void) _Watchdog_Remove( &the_thread->Timer );
a000b42c: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED
a000b430: eb000478 bl a000c618 <_Watchdog_Remove> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Scheduler_Thread_scheduler_free(
Scheduler_Control *the_scheduler,
Thread_Control *the_thread
)
{
return the_scheduler->Operations.scheduler_free( the_scheduler, the_thread );
a000b434: e59f0038 ldr r0, [pc, #56] ; a000b474 <_Thread_Close+0xbc>
a000b438: e1a01004 mov r1, r4
a000b43c: e5903018 ldr r3, [r0, #24]
a000b440: e12fff33 blx r3
/*
* Free the rest of the memory associated with this task
* and set the associated pointers to NULL for safety.
*/
_Thread_Stack_Free( the_thread );
a000b444: e1a00004 mov r0, r4
a000b448: eb0002f5 bl a000c024 <_Thread_Stack_Free>
the_thread->Start.stack = NULL;
if ( the_thread->extensions )
a000b44c: e5940100 ldr r0, [r4, #256] ; 0x100
/*
* Free the rest of the memory associated with this task
* and set the associated pointers to NULL for safety.
*/
_Thread_Stack_Free( the_thread );
the_thread->Start.stack = NULL;
a000b450: e3a03000 mov r3, #0
a000b454: e58430c0 str r3, [r4, #192] ; 0xc0
if ( the_thread->extensions )
a000b458: e1500003 cmp r0, r3
a000b45c: 0a000000 beq a000b464 <_Thread_Close+0xac>
(void) _Workspace_Free( the_thread->extensions );
a000b460: eb0004d8 bl a000c7c8 <_Workspace_Free>
the_thread->extensions = NULL;
a000b464: e3a03000 mov r3, #0
a000b468: e5843100 str r3, [r4, #256] ; 0x100
}
a000b46c: e8bd8070 pop {r4, r5, r6, pc}
a000b6bc <_Thread_Get>:
*/
Thread_Control *_Thread_Get (
Objects_Id id,
Objects_Locations *location
)
{
a000b6bc: e1a02001 mov r2, r1
uint32_t the_class;
Objects_Information **api_information;
Objects_Information *information;
Thread_Control *tp = (Thread_Control *) 0;
if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) {
a000b6c0: e2501000 subs r1, r0, #0
a000b6c4: 1a000007 bne a000b6e8 <_Thread_Get+0x2c>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000b6c8: e59f3068 ldr r3, [pc, #104] ; a000b738 <_Thread_Get+0x7c>
a000b6cc: e5930000 ldr r0, [r3]
a000b6d0: e2800001 add r0, r0, #1
a000b6d4: e5830000 str r0, [r3]
_Thread_Disable_dispatch();
*location = OBJECTS_LOCAL;
tp = _Thread_Executing;
a000b6d8: e59f305c ldr r3, [pc, #92] ; a000b73c <_Thread_Get+0x80>
Objects_Information *information;
Thread_Control *tp = (Thread_Control *) 0;
if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) {
_Thread_Disable_dispatch();
*location = OBJECTS_LOCAL;
a000b6dc: e5821000 str r1, [r2]
tp = _Thread_Executing;
a000b6e0: e5930004 ldr r0, [r3, #4]
goto done;
a000b6e4: e12fff1e bx lr
*/
RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API(
Objects_Id id
)
{
return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS);
a000b6e8: e1a00c21 lsr r0, r1, #24
a000b6ec: e2000007 and r0, r0, #7
*/
RTEMS_INLINE_ROUTINE bool _Objects_Is_api_valid(
uint32_t the_api
)
{
if ( !the_api || the_api > OBJECTS_APIS_LAST )
a000b6f0: e2403001 sub r3, r0, #1
a000b6f4: e3530002 cmp r3, #2
a000b6f8: 9a00000a bls a000b728 <_Thread_Get+0x6c>
goto done;
}
the_class = _Objects_Get_class( id );
if ( the_class != 1 ) { /* threads are always first class :) */
*location = OBJECTS_ERROR;
a000b6fc: e3a03001 mov r3, #1
a000b700: e5823000 str r3, [r2]
{
uint32_t the_api;
uint32_t the_class;
Objects_Information **api_information;
Objects_Information *information;
Thread_Control *tp = (Thread_Control *) 0;
a000b704: e3a00000 mov r0, #0
}
the_class = _Objects_Get_class( id );
if ( the_class != 1 ) { /* threads are always first class :) */
*location = OBJECTS_ERROR;
goto done;
a000b708: e12fff1e bx lr
}
api_information = _Objects_Information_table[ the_api ];
a000b70c: e59fc02c ldr ip, [pc, #44] ; a000b740 <_Thread_Get+0x84>
*location = OBJECTS_ERROR;
goto done;
}
#endif
information = api_information[ the_class ];
a000b710: e79c0100 ldr r0, [ip, r0, lsl #2]
a000b714: e5900004 ldr r0, [r0, #4]
if ( !information ) {
a000b718: e3500000 cmp r0, #0
*location = OBJECTS_ERROR;
a000b71c: 05823000 streq r3, [r2]
goto done;
}
#endif
information = api_information[ the_class ];
if ( !information ) {
a000b720: 012fff1e bxeq lr
*location = OBJECTS_ERROR;
goto done;
}
tp = (Thread_Control *) _Objects_Get( information, id, location );
a000b724: eafffcff b a000ab28 <_Objects_Get>
*/
RTEMS_INLINE_ROUTINE uint32_t _Objects_Get_class(
Objects_Id id
)
{
return (uint32_t)
a000b728: e1a03da1 lsr r3, r1, #27
*location = OBJECTS_ERROR;
goto done;
}
the_class = _Objects_Get_class( id );
if ( the_class != 1 ) { /* threads are always first class :) */
a000b72c: e3530001 cmp r3, #1
a000b730: 0afffff5 beq a000b70c <_Thread_Get+0x50>
a000b734: eafffff0 b a000b6fc <_Thread_Get+0x40> <== NOT EXECUTED
a0010504 <_Thread_Reset>:
Thread_Control *the_thread,
void *pointer_argument,
Thread_Entry_numeric_type numeric_argument
)
{
the_thread->resource_count = 0;
a0010504: e3a03000 mov r3, #0
void _Thread_Reset(
Thread_Control *the_thread,
void *pointer_argument,
Thread_Entry_numeric_type numeric_argument
)
{
a0010508: e92d4010 push {r4, lr}
the_thread->resource_count = 0;
a001050c: e580301c str r3, [r0, #28]
the_thread->is_preemptible = the_thread->Start.is_preemptible;
a0010510: e5d030a0 ldrb r3, [r0, #160] ; 0xa0
the_thread->budget_algorithm = the_thread->Start.budget_algorithm;
the_thread->budget_callout = the_thread->Start.budget_callout;
the_thread->Start.pointer_argument = pointer_argument;
a0010514: e5801098 str r1, [r0, #152] ; 0x98
the_thread->Start.numeric_argument = numeric_argument;
a0010518: e580209c str r2, [r0, #156] ; 0x9c
void *pointer_argument,
Thread_Entry_numeric_type numeric_argument
)
{
the_thread->resource_count = 0;
the_thread->is_preemptible = the_thread->Start.is_preemptible;
a001051c: e5c03074 strb r3, [r0, #116] ; 0x74
the_thread->budget_algorithm = the_thread->Start.budget_algorithm;
a0010520: e59030a4 ldr r3, [r0, #164] ; 0xa4
void _Thread_Reset(
Thread_Control *the_thread,
void *pointer_argument,
Thread_Entry_numeric_type numeric_argument
)
{
a0010524: e1a04000 mov r4, r0
the_thread->resource_count = 0;
the_thread->is_preemptible = the_thread->Start.is_preemptible;
the_thread->budget_algorithm = the_thread->Start.budget_algorithm;
a0010528: e580307c str r3, [r0, #124] ; 0x7c
the_thread->budget_callout = the_thread->Start.budget_callout;
a001052c: e59030a8 ldr r3, [r0, #168] ; 0xa8
a0010530: e5803080 str r3, [r0, #128] ; 0x80
the_thread->Start.pointer_argument = pointer_argument;
the_thread->Start.numeric_argument = numeric_argument;
if ( !_Thread_queue_Extract_with_proxy( the_thread ) ) {
a0010534: ebfff13a bl a000ca24 <_Thread_queue_Extract_with_proxy>
a0010538: e3500000 cmp r0, #0
a001053c: 1a000004 bne a0010554 <_Thread_Reset+0x50>
if ( _Watchdog_Is_active( &the_thread->Timer ) )
a0010540: e5943050 ldr r3, [r4, #80] ; 0x50
a0010544: e3530002 cmp r3, #2
a0010548: 1a000001 bne a0010554 <_Thread_Reset+0x50>
(void) _Watchdog_Remove( &the_thread->Timer );
a001054c: e2840048 add r0, r4, #72 ; 0x48
a0010550: ebfff38b bl a000d384 <_Watchdog_Remove>
}
if ( the_thread->current_priority != the_thread->Start.initial_priority ) {
a0010554: e59410b0 ldr r1, [r4, #176] ; 0xb0
a0010558: e5943014 ldr r3, [r4, #20]
a001055c: e1530001 cmp r3, r1
a0010560: 0a000003 beq a0010574 <_Thread_Reset+0x70>
the_thread->real_priority = the_thread->Start.initial_priority;
_Thread_Set_priority( the_thread, the_thread->Start.initial_priority );
a0010564: e1a00004 mov r0, r4
if ( _Watchdog_Is_active( &the_thread->Timer ) )
(void) _Watchdog_Remove( &the_thread->Timer );
}
if ( the_thread->current_priority != the_thread->Start.initial_priority ) {
the_thread->real_priority = the_thread->Start.initial_priority;
a0010568: e5841018 str r1, [r4, #24]
_Thread_Set_priority( the_thread, the_thread->Start.initial_priority );
}
}
a001056c: e8bd4010 pop {r4, lr}
(void) _Watchdog_Remove( &the_thread->Timer );
}
if ( the_thread->current_priority != the_thread->Start.initial_priority ) {
the_thread->real_priority = the_thread->Start.initial_priority;
_Thread_Set_priority( the_thread, the_thread->Start.initial_priority );
a0010570: eafff19d b a000cbec <_Thread_Set_priority>
a0010574: e8bd8010 pop {r4, pc}
a000c098 <_Thread_Start>:
*/
RTEMS_INLINE_ROUTINE bool _States_Is_dormant (
States_Control the_states
)
{
return (the_states & STATES_DORMANT);
a000c098: e590c010 ldr ip, [r0, #16]
Thread_Start_types the_prototype,
void *entry_point,
void *pointer_argument,
Thread_Entry_numeric_type numeric_argument
)
{
a000c09c: e92d4010 push {r4, lr}
if ( _States_Is_dormant( the_thread->current_state ) ) {
a000c0a0: e21cc001 ands ip, ip, #1
Thread_Start_types the_prototype,
void *entry_point,
void *pointer_argument,
Thread_Entry_numeric_type numeric_argument
)
{
a000c0a4: e1a04000 mov r4, r0
if ( _States_Is_dormant( the_thread->current_state ) ) {
a000c0a8: 0a00000b beq a000c0dc <_Thread_Start+0x44>
the_thread->Start.entry_point = (Thread_Entry) entry_point;
the_thread->Start.prototype = the_prototype;
the_thread->Start.pointer_argument = pointer_argument;
a000c0ac: e5803098 str r3, [r0, #152] ; 0x98
the_thread->Start.numeric_argument = numeric_argument;
a000c0b0: e59d3008 ldr r3, [sp, #8]
Thread_Entry_numeric_type numeric_argument
)
{
if ( _States_Is_dormant( the_thread->current_state ) ) {
the_thread->Start.entry_point = (Thread_Entry) entry_point;
a000c0b4: e5802090 str r2, [r0, #144] ; 0x90
the_thread->Start.prototype = the_prototype;
a000c0b8: e5801094 str r1, [r0, #148] ; 0x94
the_thread->Start.pointer_argument = pointer_argument;
the_thread->Start.numeric_argument = numeric_argument;
a000c0bc: e580309c str r3, [r0, #156] ; 0x9c
_Thread_Load_environment( the_thread );
a000c0c0: eb000ced bl a000f47c <_Thread_Load_environment>
_Thread_Ready( the_thread );
a000c0c4: e1a00004 mov r0, r4
a000c0c8: eb000d83 bl a000f6dc <_Thread_Ready>
_User_extensions_Thread_start( the_thread );
a000c0cc: e1a00004 mov r0, r4
a000c0d0: eb0000d7 bl a000c434 <_User_extensions_Thread_start>
return true;
a000c0d4: e3a00001 mov r0, #1
a000c0d8: e8bd8010 pop {r4, pc}
}
return false;
a000c0dc: e1a0000c mov r0, ip <== NOT EXECUTED
}
a000c0e0: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000f3c4 <_Thread_Suspend>:
*/
void _Thread_Suspend(
Thread_Control *the_thread
)
{
a000f3c4: e92d4010 push {r4, lr}
a000f3c8: e1a01000 mov r1, r0
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000f3cc: e10f4000 mrs r4, CPSR
a000f3d0: e3843080 orr r3, r4, #128 ; 0x80
a000f3d4: e129f003 msr CPSR_fc, r3
ISR_Level level;
_ISR_Disable( level );
if ( !_States_Is_ready( the_thread->current_state ) ) {
a000f3d8: e5903010 ldr r3, [r0, #16]
a000f3dc: e3530000 cmp r3, #0
a000f3e0: 0a000002 beq a000f3f0 <_Thread_Suspend+0x2c>
RTEMS_INLINE_ROUTINE States_Control _States_Set (
States_Control states_to_set,
States_Control current_state
)
{
return (current_state | states_to_set);
a000f3e4: e3833002 orr r3, r3, #2 <== NOT EXECUTED
the_thread->current_state =
a000f3e8: e5803010 str r3, [r0, #16] <== NOT EXECUTED
_States_Set( STATES_SUSPENDED, the_thread->current_state );
_ISR_Enable( level );
a000f3ec: ea000004 b a000f404 <_Thread_Suspend+0x40> <== NOT EXECUTED
return;
}
the_thread->current_state = STATES_SUSPENDED;
a000f3f0: e3a03002 mov r3, #2
a000f3f4: e5803010 str r3, [r0, #16]
a000f3f8: e59f000c ldr r0, [pc, #12] ; a000f40c <_Thread_Suspend+0x48>
a000f3fc: e590300c ldr r3, [r0, #12]
a000f400: e12fff33 blx r3
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000f404: e129f004 msr CPSR_fc, r4
a000f408: e8bd8010 pop {r4, pc}
a000c0e4 <_Thread_Tickle_timeslice>:
void _Thread_Tickle_timeslice( void )
{
Thread_Control *executing;
executing = _Thread_Executing;
a000c0e4: e59f3090 ldr r3, [pc, #144] ; a000c17c <_Thread_Tickle_timeslice+0x98>
*
* Output parameters: NONE
*/
void _Thread_Tickle_timeslice( void )
{
a000c0e8: e92d4010 push {r4, lr}
Thread_Control *executing;
executing = _Thread_Executing;
a000c0ec: e5934004 ldr r4, [r3, #4]
/*
* If the thread is not preemptible or is not ready, then
* just return.
*/
if ( !executing->is_preemptible )
a000c0f0: e5d43074 ldrb r3, [r4, #116] ; 0x74
a000c0f4: e3530000 cmp r3, #0
a000c0f8: 0a00001e beq a000c178 <_Thread_Tickle_timeslice+0x94>
return;
if ( !_States_Is_ready( executing->current_state ) )
a000c0fc: e5943010 ldr r3, [r4, #16]
a000c100: e3530000 cmp r3, #0
a000c104: 1a00001b bne a000c178 <_Thread_Tickle_timeslice+0x94>
/*
* The cpu budget algorithm determines what happens next.
*/
switch ( executing->budget_algorithm ) {
a000c108: e594307c ldr r3, [r4, #124] ; 0x7c
a000c10c: e3530001 cmp r3, #1
a000c110: 3a000018 bcc a000c178 <_Thread_Tickle_timeslice+0x94>
a000c114: e3530002 cmp r3, #2 <== NOT EXECUTED
a000c118: 9a000002 bls a000c128 <_Thread_Tickle_timeslice+0x44> <== NOT EXECUTED
a000c11c: e3530003 cmp r3, #3 <== NOT EXECUTED
a000c120: 1a000014 bne a000c178 <_Thread_Tickle_timeslice+0x94> <== NOT EXECUTED
a000c124: ea00000b b a000c158 <_Thread_Tickle_timeslice+0x74> <== NOT EXECUTED
case THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE:
#if defined(RTEMS_SCORE_THREAD_ENABLE_EXHAUST_TIMESLICE)
case THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE:
#endif
if ( (int)(--executing->cpu_time_budget) <= 0 ) {
a000c128: e5943078 ldr r3, [r4, #120] ; 0x78 <== NOT EXECUTED
a000c12c: e2433001 sub r3, r3, #1 <== NOT EXECUTED
a000c130: e3530000 cmp r3, #0 <== NOT EXECUTED
a000c134: e5843078 str r3, [r4, #120] ; 0x78 <== NOT EXECUTED
a000c138: ca00000e bgt a000c178 <_Thread_Tickle_timeslice+0x94> <== NOT EXECUTED
* always operates on the scheduler that 'owns' the currently executing
* thread.
*/
RTEMS_INLINE_ROUTINE void _Scheduler_Yield( void )
{
_Scheduler.Operations.yield( &_Scheduler );
a000c13c: e59f003c ldr r0, [pc, #60] ; a000c180 <_Thread_Tickle_timeslice+0x9c><== NOT EXECUTED
a000c140: e5903008 ldr r3, [r0, #8] <== NOT EXECUTED
a000c144: e12fff33 blx r3 <== NOT EXECUTED
* executing thread's timeslice is reset. Otherwise, the
* currently executing thread is placed at the rear of the
* FIFO for this priority and a new heir is selected.
*/
_Scheduler_Yield( );
executing->cpu_time_budget = _Thread_Ticks_per_timeslice;
a000c148: e59f3034 ldr r3, [pc, #52] ; a000c184 <_Thread_Tickle_timeslice+0xa0><== NOT EXECUTED
a000c14c: e5933000 ldr r3, [r3] <== NOT EXECUTED
a000c150: e5843078 str r3, [r4, #120] ; 0x78 <== NOT EXECUTED
a000c154: e8bd8010 pop {r4, pc} <== NOT EXECUTED
}
break;
#if defined(RTEMS_SCORE_THREAD_ENABLE_SCHEDULER_CALLOUT)
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT:
if ( --executing->cpu_time_budget == 0 )
a000c158: e5943078 ldr r3, [r4, #120] ; 0x78 <== NOT EXECUTED
a000c15c: e2433001 sub r3, r3, #1 <== NOT EXECUTED
a000c160: e3530000 cmp r3, #0 <== NOT EXECUTED
a000c164: e5843078 str r3, [r4, #120] ; 0x78 <== NOT EXECUTED
a000c168: 1a000002 bne a000c178 <_Thread_Tickle_timeslice+0x94> <== NOT EXECUTED
(*executing->budget_callout)( executing );
a000c16c: e5943080 ldr r3, [r4, #128] ; 0x80 <== NOT EXECUTED
a000c170: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c174: e12fff33 blx r3 <== NOT EXECUTED
a000c178: e8bd8010 pop {r4, pc}
a000b1b4 <_Thread_blocking_operation_Cancel>:
#endif
/*
* The thread is not waiting on anything after this completes.
*/
the_thread->Wait.queue = NULL;
a000b1b4: e3a03000 mov r3, #0 <== NOT EXECUTED
Thread_blocking_operation_States sync_state __attribute__((unused)),
#endif
Thread_Control *the_thread,
ISR_Level level
)
{
a000b1b8: e92d4010 push {r4, lr} <== NOT EXECUTED
#endif
/*
* The thread is not waiting on anything after this completes.
*/
the_thread->Wait.queue = NULL;
a000b1bc: e5813044 str r3, [r1, #68] ; 0x44 <== NOT EXECUTED
/*
* If the sync state is timed out, this is very likely not needed.
* But better safe than sorry when it comes to critical sections.
*/
if ( _Watchdog_Is_active( &the_thread->Timer ) ) {
a000b1c0: e5913050 ldr r3, [r1, #80] ; 0x50 <== NOT EXECUTED
Thread_blocking_operation_States sync_state __attribute__((unused)),
#endif
Thread_Control *the_thread,
ISR_Level level
)
{
a000b1c4: e1a04001 mov r4, r1 <== NOT EXECUTED
/*
* If the sync state is timed out, this is very likely not needed.
* But better safe than sorry when it comes to critical sections.
*/
if ( _Watchdog_Is_active( &the_thread->Timer ) ) {
a000b1c8: e3530002 cmp r3, #2 <== NOT EXECUTED
a000b1cc: 1a000005 bne a000b1e8 <_Thread_blocking_operation_Cancel+0x34><== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate(
Watchdog_Control *the_watchdog
)
{
the_watchdog->state = WATCHDOG_REMOVE_IT;
a000b1d0: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000b1d4: e5813050 str r3, [r1, #80] ; 0x50 <== NOT EXECUTED
a000b1d8: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
_Watchdog_Deactivate( &the_thread->Timer );
_ISR_Enable( level );
(void) _Watchdog_Remove( &the_thread->Timer );
a000b1dc: e2810048 add r0, r1, #72 ; 0x48 <== NOT EXECUTED
a000b1e0: eb00050c bl a000c618 <_Watchdog_Remove> <== NOT EXECUTED
a000b1e4: ea000000 b a000b1ec <_Thread_blocking_operation_Cancel+0x38><== NOT EXECUTED
a000b1e8: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
a000b1ec: e59f1008 ldr r1, [pc, #8] ; a000b1fc <_Thread_blocking_operation_Cancel+0x48><== NOT EXECUTED
a000b1f0: e1a00004 mov r0, r4 <== NOT EXECUTED
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
}
a000b1f4: e8bd4010 pop {r4, lr} <== NOT EXECUTED
a000b1f8: ea00005b b a000b36c <_Thread_Clear_state> <== NOT EXECUTED
a000f4c8 <_Thread_queue_Dequeue_fifo>:
*/
Thread_Control *_Thread_queue_Dequeue_fifo(
Thread_queue_Control *the_thread_queue
)
{
a000f4c8: e92d4030 push {r4, r5, lr}
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000f4cc: e10f3000 mrs r3, CPSR
a000f4d0: e3832080 orr r2, r3, #128 ; 0x80
a000f4d4: e129f002 msr CPSR_fc, r2
return the_thread;
}
_ISR_Enable( level );
return NULL;
}
a000f4d8: e1a02000 mov r2, r0
a000f4dc: e4925004 ldr r5, [r2], #4
{
ISR_Level level;
Thread_Control *the_thread;
_ISR_Disable( level );
if ( !_Chain_Is_empty( &the_thread_queue->Queues.Fifo ) ) {
a000f4e0: e1550002 cmp r5, r2
a000f4e4: 0a000013 beq a000f538 <_Thread_queue_Dequeue_fifo+0x70>
Chain_Control *the_chain
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *old_first = head->next;
Chain_Node *new_first = old_first->next;
a000f4e8: e5952000 ldr r2, [r5]
the_thread = (Thread_Control *)
a000f4ec: e1a04005 mov r4, r5
head->next = new_first;
a000f4f0: e5802000 str r2, [r0]
new_first->previous = head;
a000f4f4: e5820004 str r0, [r2, #4]
_Chain_Get_first_unprotected( &the_thread_queue->Queues.Fifo );
the_thread->Wait.queue = NULL;
a000f4f8: e3a02000 mov r2, #0
a000f4fc: e5852044 str r2, [r5, #68] ; 0x44
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
a000f500: e5952050 ldr r2, [r5, #80] ; 0x50
a000f504: e3520002 cmp r2, #2
a000f508: 0a000001 beq a000f514 <_Thread_queue_Dequeue_fifo+0x4c>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000f50c: e129f003 msr CPSR_fc, r3
a000f510: ea000004 b a000f528 <_Thread_queue_Dequeue_fifo+0x60>
RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate(
Watchdog_Control *the_watchdog
)
{
the_watchdog->state = WATCHDOG_REMOVE_IT;
a000f514: e3a02003 mov r2, #3 <== NOT EXECUTED
a000f518: e5852050 str r2, [r5, #80] ; 0x50 <== NOT EXECUTED
a000f51c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
_ISR_Enable( level );
_Thread_Unblock( the_thread );
} else {
_Watchdog_Deactivate( &the_thread->Timer );
_ISR_Enable( level );
(void) _Watchdog_Remove( &the_thread->Timer );
a000f520: e2850048 add r0, r5, #72 ; 0x48 <== NOT EXECUTED
a000f524: ebfff43b bl a000c618 <_Watchdog_Remove> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
a000f528: e1a00005 mov r0, r5
a000f52c: e59f1014 ldr r1, [pc, #20] ; a000f548 <_Thread_queue_Dequeue_fifo+0x80>
a000f530: ebffef8d bl a000b36c <_Thread_Clear_state>
a000f534: ea000001 b a000f540 <_Thread_queue_Dequeue_fifo+0x78>
a000f538: e129f003 msr CPSR_fc, r3
return the_thread;
}
_ISR_Enable( level );
return NULL;
a000f53c: e3a04000 mov r4, #0
}
a000f540: e1a00004 mov r0, r4
a000f544: e8bd8030 pop {r4, r5, pc}
a000ba38 <_Thread_queue_Dequeue_priority>:
*/
Thread_Control *_Thread_queue_Dequeue_priority(
Thread_queue_Control *the_thread_queue
)
{
a000ba38: e92d4030 push {r4, r5, lr}
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000ba3c: e10f1000 mrs r1, CPSR
a000ba40: e3813080 orr r3, r1, #128 ; 0x80
a000ba44: e129f003 msr CPSR_fc, r3
Chain_Node *new_second_node;
Chain_Node *last_node;
Chain_Node *next_node;
Chain_Node *previous_node;
_ISR_Disable( level );
a000ba48: e3a02000 mov r2, #0
for( index=0 ;
a000ba4c: e1a03002 mov r3, r2
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a000ba50: e3a0c00c mov ip, #12
a000ba54: e004039c mul r4, ip, r3
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
return( the_thread );
}
a000ba58: e7905002 ldr r5, [r0, r2]
a000ba5c: e2844004 add r4, r4, #4
a000ba60: e0804004 add r4, r0, r4
_ISR_Disable( level );
for( index=0 ;
index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ;
index++ ) {
if ( !_Chain_Is_empty( &the_thread_queue->Queues.Priority[ index ] ) ) {
a000ba64: e1550004 cmp r5, r4
a000ba68: 0a000009 beq a000ba94 <_Thread_queue_Dequeue_priority+0x5c>
*/
_ISR_Enable( level );
return NULL;
dequeue:
the_thread->Wait.queue = NULL;
a000ba6c: e3a03000 mov r3, #0
a000ba70: e5853044 str r3, [r5, #68] ; 0x44
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
return( the_thread );
}
a000ba74: e5953038 ldr r3, [r5, #56] ; 0x38
a000ba78: e285c03c add ip, r5, #60 ; 0x3c
_ISR_Disable( level );
for( index=0 ;
index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ;
index++ ) {
if ( !_Chain_Is_empty( &the_thread_queue->Queues.Priority[ index ] ) ) {
the_thread = (Thread_Control *) _Chain_First(
a000ba7c: e1a04005 mov r4, r5
new_first_node = _Chain_First( &the_thread->Wait.Block2n );
new_first_thread = (Thread_Control *) new_first_node;
next_node = the_thread->Object.Node.next;
previous_node = the_thread->Object.Node.previous;
if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) {
a000ba80: e153000c cmp r3, ip
dequeue:
the_thread->Wait.queue = NULL;
new_first_node = _Chain_First( &the_thread->Wait.Block2n );
new_first_thread = (Thread_Control *) new_first_node;
next_node = the_thread->Object.Node.next;
a000ba84: e5952000 ldr r2, [r5]
previous_node = the_thread->Object.Node.previous;
a000ba88: e5950004 ldr r0, [r5, #4]
if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) {
a000ba8c: 1a000007 bne a000bab0 <_Thread_queue_Dequeue_priority+0x78>
a000ba90: ea000017 b a000baf4 <_Thread_queue_Dequeue_priority+0xbc>
Chain_Node *previous_node;
_ISR_Disable( level );
for( index=0 ;
index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ;
index++ ) {
a000ba94: e2833001 add r3, r3, #1
Chain_Node *last_node;
Chain_Node *next_node;
Chain_Node *previous_node;
_ISR_Disable( level );
for( index=0 ;
a000ba98: e3530004 cmp r3, #4
index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ;
index++ ) {
a000ba9c: e282200c add r2, r2, #12
Chain_Node *last_node;
Chain_Node *next_node;
Chain_Node *previous_node;
_ISR_Disable( level );
for( index=0 ;
a000baa0: 1affffeb bne a000ba54 <_Thread_queue_Dequeue_priority+0x1c>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000baa4: e129f001 msr CPSR_fc, r1
/*
* We did not find a thread to unblock.
*/
_ISR_Enable( level );
return NULL;
a000baa8: e3a04000 mov r4, #0
a000baac: ea00001f b a000bb30 <_Thread_queue_Dequeue_priority+0xf8>
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
return( the_thread );
}
a000bab0: e595c040 ldr ip, [r5, #64] ; 0x40 <== NOT EXECUTED
next_node = the_thread->Object.Node.next;
previous_node = the_thread->Object.Node.previous;
if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) {
last_node = _Chain_Last( &the_thread->Wait.Block2n );
new_second_node = new_first_node->next;
a000bab4: e593e000 ldr lr, [r3] <== NOT EXECUTED
previous_node->next = new_first_node;
next_node->previous = new_first_node;
a000bab8: e5823004 str r3, [r2, #4] <== NOT EXECUTED
if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) {
last_node = _Chain_Last( &the_thread->Wait.Block2n );
new_second_node = new_first_node->next;
previous_node->next = new_first_node;
a000babc: e5803000 str r3, [r0] <== NOT EXECUTED
next_node->previous = new_first_node;
new_first_node->next = next_node;
new_first_node->previous = previous_node;
a000bac0: e5830004 str r0, [r3, #4] <== NOT EXECUTED
last_node = _Chain_Last( &the_thread->Wait.Block2n );
new_second_node = new_first_node->next;
previous_node->next = new_first_node;
next_node->previous = new_first_node;
new_first_node->next = next_node;
a000bac4: e5832000 str r2, [r3] <== NOT EXECUTED
new_first_node->previous = previous_node;
if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) {
a000bac8: e5950038 ldr r0, [r5, #56] ; 0x38 <== NOT EXECUTED
a000bacc: e5952040 ldr r2, [r5, #64] ; 0x40 <== NOT EXECUTED
a000bad0: e1500002 cmp r0, r2 <== NOT EXECUTED
a000bad4: 0a000008 beq a000bafc <_Thread_queue_Dequeue_priority+0xc4><== NOT EXECUTED
/* > two threads on 2-n */
head = _Chain_Head( &new_first_thread->Wait.Block2n );
a000bad8: e2832038 add r2, r3, #56 ; 0x38 <== NOT EXECUTED
tail = _Chain_Tail( &new_first_thread->Wait.Block2n );
new_second_node->previous = head;
head->next = new_second_node;
a000badc: e583e038 str lr, [r3, #56] ; 0x38 <== NOT EXECUTED
if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) {
/* > two threads on 2-n */
head = _Chain_Head( &new_first_thread->Wait.Block2n );
tail = _Chain_Tail( &new_first_thread->Wait.Block2n );
new_second_node->previous = head;
a000bae0: e58e2004 str r2, [lr, #4] <== NOT EXECUTED
head->next = new_second_node;
tail->previous = last_node;
a000bae4: e583c040 str ip, [r3, #64] ; 0x40 <== NOT EXECUTED
new_first_node->previous = previous_node;
if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) {
/* > two threads on 2-n */
head = _Chain_Head( &new_first_thread->Wait.Block2n );
tail = _Chain_Tail( &new_first_thread->Wait.Block2n );
a000bae8: e283303c add r3, r3, #60 ; 0x3c <== NOT EXECUTED
new_second_node->previous = head;
head->next = new_second_node;
tail->previous = last_node;
last_node->next = tail;
a000baec: e58c3000 str r3, [ip] <== NOT EXECUTED
a000baf0: ea000001 b a000bafc <_Thread_queue_Dequeue_priority+0xc4> <== NOT EXECUTED
}
} else {
previous_node->next = next_node;
a000baf4: e5802000 str r2, [r0]
next_node->previous = previous_node;
a000baf8: e5820004 str r0, [r2, #4]
}
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
a000bafc: e5953050 ldr r3, [r5, #80] ; 0x50
a000bb00: e3530002 cmp r3, #2
a000bb04: 0a000001 beq a000bb10 <_Thread_queue_Dequeue_priority+0xd8>
a000bb08: e129f001 msr CPSR_fc, r1
a000bb0c: ea000004 b a000bb24 <_Thread_queue_Dequeue_priority+0xec>
RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate(
Watchdog_Control *the_watchdog
)
{
the_watchdog->state = WATCHDOG_REMOVE_IT;
a000bb10: e3a03003 mov r3, #3 <== NOT EXECUTED
a000bb14: e5853050 str r3, [r5, #80] ; 0x50 <== NOT EXECUTED
a000bb18: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED
_ISR_Enable( level );
_Thread_Unblock( the_thread );
} else {
_Watchdog_Deactivate( &the_thread->Timer );
_ISR_Enable( level );
(void) _Watchdog_Remove( &the_thread->Timer );
a000bb1c: e2850048 add r0, r5, #72 ; 0x48 <== NOT EXECUTED
a000bb20: eb0002bc bl a000c618 <_Watchdog_Remove> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
a000bb24: e1a00005 mov r0, r5
a000bb28: e59f1008 ldr r1, [pc, #8] ; a000bb38 <_Thread_queue_Dequeue_priority+0x100>
a000bb2c: ebfffe0e bl a000b36c <_Thread_Clear_state>
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
return( the_thread );
}
a000bb30: e1a00004 mov r0, r4
a000bb34: e8bd8030 pop {r4, r5, pc}
a000f54c <_Thread_queue_Enqueue_fifo>:
Thread_blocking_operation_States _Thread_queue_Enqueue_fifo (
Thread_queue_Control *the_thread_queue,
Thread_Control *the_thread,
ISR_Level *level_p
)
{
a000f54c: e92d4010 push {r4, lr}
a000f550: e1a03000 mov r3, r0
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000f554: e10fc000 mrs ip, CPSR
a000f558: e38c0080 orr r0, ip, #128 ; 0x80
a000f55c: e129f000 msr CPSR_fc, r0
Thread_blocking_operation_States sync_state;
ISR_Level level;
_ISR_Disable( level );
sync_state = the_thread_queue->sync_state;
a000f560: e5930030 ldr r0, [r3, #48] ; 0x30
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
a000f564: e3a04000 mov r4, #0
a000f568: e5834030 str r4, [r3, #48] ; 0x30
if (sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED) {
a000f56c: e3500001 cmp r0, #1
a000f570: 1a000008 bne a000f598 <_Thread_queue_Enqueue_fifo+0x4c>
Chain_Control *the_chain,
Chain_Node *the_node
)
{
Chain_Node *tail = _Chain_Tail( the_chain );
Chain_Node *old_last = tail->previous;
a000f574: e5932008 ldr r2, [r3, #8]
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
Chain_Node *tail = _Chain_Tail( the_chain );
a000f578: e2834004 add r4, r3, #4
Chain_Node *old_last = tail->previous;
the_node->next = tail;
tail->previous = the_node;
a000f57c: e5831008 str r1, [r3, #8]
)
{
Chain_Node *tail = _Chain_Tail( the_chain );
Chain_Node *old_last = tail->previous;
the_node->next = tail;
a000f580: e5814000 str r4, [r1]
tail->previous = the_node;
old_last->next = the_node;
the_node->previous = old_last;
a000f584: e5812004 str r2, [r1, #4]
Chain_Node *tail = _Chain_Tail( the_chain );
Chain_Node *old_last = tail->previous;
the_node->next = tail;
tail->previous = the_node;
old_last->next = the_node;
a000f588: e5821000 str r1, [r2]
_Chain_Append_unprotected(
&the_thread_queue->Queues.Fifo,
&the_thread->Object.Node
);
the_thread->Wait.queue = the_thread_queue;
a000f58c: e5813044 str r3, [r1, #68] ; 0x44
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000f590: e129f00c msr CPSR_fc, ip
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
_ISR_Enable( level );
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a000f594: e8bd8010 pop {r4, pc}
* For example, the blocking thread could have been given
* the mutex by an ISR or timed out.
*
* WARNING! Returning with interrupts disabled!
*/
*level_p = level;
a000f598: e582c000 str ip, [r2] <== NOT EXECUTED
return sync_state;
}
a000f59c: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000bbdc <_Thread_queue_Enqueue_priority>:
Priority_Control priority;
States_Control block_state;
_Chain_Initialize_empty( &the_thread->Wait.Block2n );
priority = the_thread->current_priority;
a000bbdc: e591c014 ldr ip, [r1, #20]
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *tail = _Chain_Tail( the_chain );
a000bbe0: e281303c add r3, r1, #60 ; 0x3c
head->next = tail;
a000bbe4: e5813038 str r3, [r1, #56] ; 0x38
head->previous = NULL;
a000bbe8: e3a03000 mov r3, #0
a000bbec: e581303c str r3, [r1, #60] ; 0x3c
header_index = _Thread_queue_Header_number( priority );
header = &the_thread_queue->Queues.Priority[ header_index ];
block_state = the_thread_queue->state;
if ( _Thread_queue_Is_reverse_search( priority ) )
a000bbf0: e31c0020 tst ip, #32
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
Chain_Node *head = _Chain_Head( the_chain );
a000bbf4: e2813038 add r3, r1, #56 ; 0x38
Thread_blocking_operation_States _Thread_queue_Enqueue_priority (
Thread_queue_Control *the_thread_queue,
Thread_Control *the_thread,
ISR_Level *level_p
)
{
a000bbf8: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr}
Chain_Node *tail = _Chain_Tail( the_chain );
head->next = tail;
head->previous = NULL;
tail->previous = head;
a000bbfc: e5813040 str r3, [r1, #64] ; 0x40
_Chain_Initialize_empty( &the_thread->Wait.Block2n );
priority = the_thread->current_priority;
header_index = _Thread_queue_Header_number( priority );
header = &the_thread_queue->Queues.Priority[ header_index ];
block_state = the_thread_queue->state;
a000bc00: e5907038 ldr r7, [r0, #56] ; 0x38
RTEMS_INLINE_ROUTINE uint32_t _Thread_queue_Header_number (
Priority_Control the_priority
)
{
return (the_priority / TASK_QUEUE_DATA_PRIORITIES_PER_HEADER);
a000bc04: e1a0332c lsr r3, ip, #6
if ( _Thread_queue_Is_reverse_search( priority ) )
a000bc08: 1a000026 bne a000bca8 <_Thread_queue_Enqueue_priority+0xcc>
*
* WARNING! Returning with interrupts disabled!
*/
*level_p = level;
return the_thread_queue->sync_state;
}
a000bc0c: e3a0600c mov r6, #12
a000bc10: e0030396 mul r3, r6, r3
a000bc14: e0808003 add r8, r0, r3
RTEMS_INLINE_ROUTINE bool _Chain_Is_tail(
Chain_Control *the_chain,
const Chain_Node *the_node
)
{
return (the_node == _Chain_Tail(the_chain));
a000bc18: e2833004 add r3, r3, #4
a000bc1c: e0806003 add r6, r0, r3
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000bc20: e10f4000 mrs r4, CPSR
a000bc24: e3843080 orr r3, r4, #128 ; 0x80
a000bc28: e129f003 msr CPSR_fc, r3
if ( _Thread_queue_Is_reverse_search( priority ) )
goto restart_reverse_search;
restart_forward_search:
search_priority = PRIORITY_MINIMUM - 1;
a000bc2c: e3e05000 mvn r5, #0
_ISR_Disable( level );
search_thread = (Thread_Control *) _Chain_First( header );
a000bc30: e5983000 ldr r3, [r8]
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
a000bc34: ea00000b b a000bc68 <_Thread_queue_Enqueue_priority+0x8c>
search_priority = search_thread->current_priority;
a000bc38: e5935014 ldr r5, [r3, #20]
if ( priority <= search_priority )
a000bc3c: e15c0005 cmp ip, r5
a000bc40: 9a00000a bls a000bc70 <_Thread_queue_Enqueue_priority+0x94>
static inline void arm_interrupt_flash( uint32_t level )
{
uint32_t arm_switch_reg;
asm volatile (
a000bc44: e10fa000 mrs sl, CPSR
a000bc48: e129f004 msr CPSR_fc, r4
a000bc4c: e129f00a msr CPSR_fc, sl
RTEMS_INLINE_ROUTINE bool _States_Are_set (
States_Control the_states,
States_Control mask
)
{
return ( (the_states & mask) != STATES_READY);
a000bc50: e593a010 ldr sl, [r3, #16]
search_priority = search_thread->current_priority;
if ( priority <= search_priority )
break;
#endif
_ISR_Flash( level );
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
a000bc54: e117000a tst r7, sl
a000bc58: 1a000001 bne a000bc64 <_Thread_queue_Enqueue_priority+0x88>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000bc5c: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
a000bc60: eaffffee b a000bc20 <_Thread_queue_Enqueue_priority+0x44> <== NOT EXECUTED
_ISR_Enable( level );
goto restart_forward_search;
}
search_thread =
(Thread_Control *)search_thread->Object.Node.next;
a000bc64: e5933000 ldr r3, [r3]
restart_forward_search:
search_priority = PRIORITY_MINIMUM - 1;
_ISR_Disable( level );
search_thread = (Thread_Control *) _Chain_First( header );
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
a000bc68: e1530006 cmp r3, r6
a000bc6c: 1afffff1 bne a000bc38 <_Thread_queue_Enqueue_priority+0x5c>
}
search_thread =
(Thread_Control *)search_thread->Object.Node.next;
}
if ( the_thread_queue->sync_state !=
a000bc70: e5906030 ldr r6, [r0, #48] ; 0x30
a000bc74: e3560001 cmp r6, #1
a000bc78: 1a000039 bne a000bd64 <_Thread_queue_Enqueue_priority+0x188>
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
goto synchronize;
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
a000bc7c: e3a02000 mov r2, #0
if ( priority == search_priority )
a000bc80: e15c0005 cmp ip, r5
if ( the_thread_queue->sync_state !=
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
goto synchronize;
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
a000bc84: e5802030 str r2, [r0, #48] ; 0x30
if ( priority == search_priority )
a000bc88: 0a00002b beq a000bd3c <_Thread_queue_Enqueue_priority+0x160>
goto equal_priority;
search_node = (Chain_Node *) search_thread;
previous_node = search_node->previous;
a000bc8c: e5932004 ldr r2, [r3, #4]
the_node = (Chain_Node *) the_thread;
the_node->next = search_node;
a000bc90: e5813000 str r3, [r1]
the_node->previous = previous_node;
a000bc94: e5812004 str r2, [r1, #4]
previous_node->next = the_node;
a000bc98: e5821000 str r1, [r2]
search_node->previous = the_node;
a000bc9c: e5831004 str r1, [r3, #4]
the_thread->Wait.queue = the_thread_queue;
a000bca0: e5810044 str r0, [r1, #68] ; 0x44
_ISR_Enable( level );
a000bca4: ea00002b b a000bd58 <_Thread_queue_Enqueue_priority+0x17c>
*
* WARNING! Returning with interrupts disabled!
*/
*level_p = level;
return the_thread_queue->sync_state;
}
a000bca8: e3a0600c mov r6, #12
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
restart_reverse_search:
search_priority = PRIORITY_MAXIMUM + 1;
a000bcac: e59f80bc ldr r8, [pc, #188] ; a000bd70 <_Thread_queue_Enqueue_priority+0x194>
*
* WARNING! Returning with interrupts disabled!
*/
*level_p = level;
return the_thread_queue->sync_state;
}
a000bcb0: e0260693 mla r6, r3, r6, r0
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
restart_reverse_search:
search_priority = PRIORITY_MAXIMUM + 1;
a000bcb4: e5d85000 ldrb r5, [r8]
a000bcb8: e2855001 add r5, r5, #1
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000bcbc: e10f4000 mrs r4, CPSR
a000bcc0: e3843080 orr r3, r4, #128 ; 0x80
a000bcc4: e129f003 msr CPSR_fc, r3
_ISR_Disable( level );
search_thread = (Thread_Control *) _Chain_Last( header );
a000bcc8: e5963008 ldr r3, [r6, #8]
while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) {
a000bccc: ea00000b b a000bd00 <_Thread_queue_Enqueue_priority+0x124>
search_priority = search_thread->current_priority;
a000bcd0: e5935014 ldr r5, [r3, #20]
if ( priority >= search_priority )
a000bcd4: e15c0005 cmp ip, r5
a000bcd8: 2a00000a bcs a000bd08 <_Thread_queue_Enqueue_priority+0x12c>
static inline void arm_interrupt_flash( uint32_t level )
{
uint32_t arm_switch_reg;
asm volatile (
a000bcdc: e10fa000 mrs sl, CPSR <== NOT EXECUTED
a000bce0: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
a000bce4: e129f00a msr CPSR_fc, sl <== NOT EXECUTED
a000bce8: e593a010 ldr sl, [r3, #16] <== NOT EXECUTED
search_priority = search_thread->current_priority;
if ( priority >= search_priority )
break;
#endif
_ISR_Flash( level );
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
a000bcec: e117000a tst r7, sl <== NOT EXECUTED
a000bcf0: 1a000001 bne a000bcfc <_Thread_queue_Enqueue_priority+0x120><== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000bcf4: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
a000bcf8: eaffffed b a000bcb4 <_Thread_queue_Enqueue_priority+0xd8> <== NOT EXECUTED
_ISR_Enable( level );
goto restart_reverse_search;
}
search_thread = (Thread_Control *)
search_thread->Object.Node.previous;
a000bcfc: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
restart_reverse_search:
search_priority = PRIORITY_MAXIMUM + 1;
_ISR_Disable( level );
search_thread = (Thread_Control *) _Chain_Last( header );
while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) {
a000bd00: e1530006 cmp r3, r6
a000bd04: 1afffff1 bne a000bcd0 <_Thread_queue_Enqueue_priority+0xf4>
}
search_thread = (Thread_Control *)
search_thread->Object.Node.previous;
}
if ( the_thread_queue->sync_state !=
a000bd08: e5906030 ldr r6, [r0, #48] ; 0x30
a000bd0c: e3560001 cmp r6, #1
a000bd10: 1a000013 bne a000bd64 <_Thread_queue_Enqueue_priority+0x188>
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
goto synchronize;
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
a000bd14: e3a02000 mov r2, #0
if ( priority == search_priority )
a000bd18: e15c0005 cmp ip, r5
if ( the_thread_queue->sync_state !=
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
goto synchronize;
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
a000bd1c: e5802030 str r2, [r0, #48] ; 0x30
if ( priority == search_priority )
a000bd20: 0a000005 beq a000bd3c <_Thread_queue_Enqueue_priority+0x160>
goto equal_priority;
search_node = (Chain_Node *) search_thread;
next_node = search_node->next;
a000bd24: e5932000 ldr r2, [r3]
the_node = (Chain_Node *) the_thread;
the_node->next = next_node;
the_node->previous = search_node;
a000bd28: e881000c stm r1, {r2, r3}
search_node->next = the_node;
next_node->previous = the_node;
a000bd2c: e5821004 str r1, [r2, #4]
next_node = search_node->next;
the_node = (Chain_Node *) the_thread;
the_node->next = next_node;
the_node->previous = search_node;
search_node->next = the_node;
a000bd30: e5831000 str r1, [r3]
next_node->previous = the_node;
the_thread->Wait.queue = the_thread_queue;
a000bd34: e5810044 str r0, [r1, #68] ; 0x44
_ISR_Enable( level );
a000bd38: ea000006 b a000bd58 <_Thread_queue_Enqueue_priority+0x17c>
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
equal_priority: /* add at end of priority group */
search_node = _Chain_Tail( &search_thread->Wait.Block2n );
previous_node = search_node->previous;
a000bd3c: e5932040 ldr r2, [r3, #64] ; 0x40 <== NOT EXECUTED
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
equal_priority: /* add at end of priority group */
search_node = _Chain_Tail( &search_thread->Wait.Block2n );
a000bd40: e283c03c add ip, r3, #60 ; 0x3c <== NOT EXECUTED
previous_node = search_node->previous;
the_node = (Chain_Node *) the_thread;
the_node->next = search_node;
a000bd44: e581c000 str ip, [r1] <== NOT EXECUTED
the_node->previous = previous_node;
a000bd48: e5812004 str r2, [r1, #4] <== NOT EXECUTED
previous_node->next = the_node;
a000bd4c: e5821000 str r1, [r2] <== NOT EXECUTED
search_node->previous = the_node;
a000bd50: e5831040 str r1, [r3, #64] ; 0x40 <== NOT EXECUTED
the_thread->Wait.queue = the_thread_queue;
a000bd54: e5810044 str r0, [r1, #68] ; 0x44 <== NOT EXECUTED
a000bd58: e129f004 msr CPSR_fc, r4
_ISR_Enable( level );
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a000bd5c: e3a00001 mov r0, #1
a000bd60: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
* For example, the blocking thread could have been given
* the mutex by an ISR or timed out.
*
* WARNING! Returning with interrupts disabled!
*/
*level_p = level;
a000bd64: e5824000 str r4, [r2] <== NOT EXECUTED
return the_thread_queue->sync_state;
a000bd68: e5900030 ldr r0, [r0, #48] ; 0x30 <== NOT EXECUTED
}
a000bd6c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
a000bb3c <_Thread_queue_Enqueue_with_handler>:
Thread_queue_Control *,
Thread_Control *,
ISR_Level *
);
the_thread = _Thread_Executing;
a000bb3c: e59f3088 ldr r3, [pc, #136] ; a000bbcc <_Thread_queue_Enqueue_with_handler+0x90>
void _Thread_queue_Enqueue_with_handler(
Thread_queue_Control *the_thread_queue,
Watchdog_Interval timeout,
Thread_queue_Timeout_callout handler
)
{
a000bb40: e92d40f1 push {r0, r4, r5, r6, r7, lr}
Thread_queue_Control *,
Thread_Control *,
ISR_Level *
);
the_thread = _Thread_Executing;
a000bb44: e5934004 ldr r4, [r3, #4]
void _Thread_queue_Enqueue_with_handler(
Thread_queue_Control *the_thread_queue,
Watchdog_Interval timeout,
Thread_queue_Timeout_callout handler
)
{
a000bb48: e1a05000 mov r5, r0
a000bb4c: e1a06001 mov r6, r1
else
#endif
/*
* Set the blocking state for this thread queue in the thread.
*/
_Thread_Set_state( the_thread, the_thread_queue->state );
a000bb50: e1a00004 mov r0, r4
a000bb54: e5951038 ldr r1, [r5, #56] ; 0x38
void _Thread_queue_Enqueue_with_handler(
Thread_queue_Control *the_thread_queue,
Watchdog_Interval timeout,
Thread_queue_Timeout_callout handler
)
{
a000bb58: e1a07002 mov r7, r2
else
#endif
/*
* Set the blocking state for this thread queue in the thread.
*/
_Thread_Set_state( the_thread, the_thread_queue->state );
a000bb5c: eb0000e2 bl a000beec <_Thread_Set_state>
/*
* If the thread wants to timeout, then schedule its timer.
*/
if ( timeout ) {
a000bb60: e3560000 cmp r6, #0
a000bb64: 0a000009 beq a000bb90 <_Thread_queue_Enqueue_with_handler+0x54>
_Watchdog_Initialize(
a000bb68: e5942008 ldr r2, [r4, #8]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a000bb6c: e3a03000 mov r3, #0
a000bb70: e5843050 str r3, [r4, #80] ; 0x50
the_watchdog->routine = routine;
a000bb74: e5847064 str r7, [r4, #100] ; 0x64
the_watchdog->id = id;
a000bb78: e5842068 str r2, [r4, #104] ; 0x68
the_watchdog->user_data = user_data;
a000bb7c: e584306c str r3, [r4, #108] ; 0x6c
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000bb80: e5846054 str r6, [r4, #84] ; 0x54
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a000bb84: e59f0044 ldr r0, [pc, #68] ; a000bbd0 <_Thread_queue_Enqueue_with_handler+0x94>
a000bb88: e2841048 add r1, r4, #72 ; 0x48
a000bb8c: eb000249 bl a000c4b8 <_Watchdog_Insert>
}
/*
* Now enqueue the thread per the discipline for this thread queue.
*/
if ( the_thread_queue->discipline == THREAD_QUEUE_DISCIPLINE_PRIORITY )
a000bb90: e5951034 ldr r1, [r5, #52] ; 0x34
enqueue_p = _Thread_queue_Enqueue_priority;
a000bb94: e59f2038 ldr r2, [pc, #56] ; a000bbd4 <_Thread_queue_Enqueue_with_handler+0x98>
a000bb98: e59f3038 ldr r3, [pc, #56] ; a000bbd8 <_Thread_queue_Enqueue_with_handler+0x9c>
a000bb9c: e3510001 cmp r1, #1
a000bba0: 01a03002 moveq r3, r2
else /* must be THREAD_QUEUE_DISCIPLINE_FIFO */
enqueue_p = _Thread_queue_Enqueue_fifo;
sync_state = (*enqueue_p)( the_thread_queue, the_thread, &level );
a000bba4: e1a00005 mov r0, r5
a000bba8: e1a01004 mov r1, r4
a000bbac: e1a0200d mov r2, sp
a000bbb0: e12fff33 blx r3
if ( sync_state != THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
a000bbb4: e3500001 cmp r0, #1
a000bbb8: 0a000002 beq a000bbc8 <_Thread_queue_Enqueue_with_handler+0x8c>
_Thread_blocking_operation_Cancel( sync_state, the_thread, level );
a000bbbc: e1a01004 mov r1, r4 <== NOT EXECUTED
a000bbc0: e59d2000 ldr r2, [sp] <== NOT EXECUTED
a000bbc4: ebfffd7a bl a000b1b4 <_Thread_blocking_operation_Cancel> <== NOT EXECUTED
}
a000bbc8: e8bd80f8 pop {r3, r4, r5, r6, r7, pc}
a0010fb0 <_Thread_queue_Extract_fifo>:
void _Thread_queue_Extract_fifo(
Thread_queue_Control *the_thread_queue __attribute__((unused)),
Thread_Control *the_thread
)
{
a0010fb0: e92d4010 push {r4, lr}
a0010fb4: e1a04001 mov r4, r1
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0010fb8: e10f3000 mrs r3, CPSR
a0010fbc: e3832080 orr r2, r3, #128 ; 0x80
a0010fc0: e129f002 msr CPSR_fc, r2
a0010fc4: e59f2060 ldr r2, [pc, #96] ; a001102c <_Thread_queue_Extract_fifo+0x7c>
a0010fc8: e5911010 ldr r1, [r1, #16]
a0010fcc: e0012002 and r2, r1, r2
ISR_Level level;
_ISR_Disable( level );
if ( !_States_Is_waiting_on_thread_queue( the_thread->current_state ) ) {
a0010fd0: e3520000 cmp r2, #0
a0010fd4: 1a000001 bne a0010fe0 <_Thread_queue_Extract_fifo+0x30>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0010fd8: e129f003 msr CPSR_fc, r3
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
}
a0010fdc: e8bd8010 pop {r4, pc}
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
a0010fe0: e8940006 ldm r4, {r1, r2}
next->previous = previous;
a0010fe4: e5812004 str r2, [r1, #4]
previous->next = next;
a0010fe8: e5821000 str r1, [r2]
return;
}
_Chain_Extract_unprotected( &the_thread->Object.Node );
the_thread->Wait.queue = NULL;
a0010fec: e3a02000 mov r2, #0
a0010ff0: e5842044 str r2, [r4, #68] ; 0x44
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
a0010ff4: e5942050 ldr r2, [r4, #80] ; 0x50
a0010ff8: e3520002 cmp r2, #2
a0010ffc: 0a000001 beq a0011008 <_Thread_queue_Extract_fifo+0x58>
a0011000: e129f003 msr CPSR_fc, r3
a0011004: ea000004 b a001101c <_Thread_queue_Extract_fifo+0x6c>
a0011008: e3a02003 mov r2, #3 <== NOT EXECUTED
a001100c: e5842050 str r2, [r4, #80] ; 0x50 <== NOT EXECUTED
a0011010: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
_ISR_Enable( level );
} else {
_Watchdog_Deactivate( &the_thread->Timer );
_ISR_Enable( level );
(void) _Watchdog_Remove( &the_thread->Timer );
a0011014: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED
a0011018: ebffed7e bl a000c618 <_Watchdog_Remove> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
a001101c: e59f100c ldr r1, [pc, #12] ; a0011030 <_Thread_queue_Extract_fifo+0x80>
a0011020: e1a00004 mov r0, r4
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
}
a0011024: e8bd4010 pop {r4, lr}
a0011028: eaffe8cf b a000b36c <_Thread_Clear_state>
a000f5b8 <_Thread_queue_Extract_priority_helper>:
void _Thread_queue_Extract_priority_helper(
Thread_queue_Control *the_thread_queue __attribute__((unused)),
Thread_Control *the_thread,
bool requeuing
)
{
a000f5b8: e92d4070 push {r4, r5, r6, lr}
a000f5bc: e20220ff and r2, r2, #255 ; 0xff
a000f5c0: e1a04001 mov r4, r1
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000f5c4: e10f1000 mrs r1, CPSR
a000f5c8: e3813080 orr r3, r1, #128 ; 0x80
a000f5cc: e129f003 msr CPSR_fc, r3
*/
RTEMS_INLINE_ROUTINE bool _States_Is_waiting_on_thread_queue (
States_Control the_states
)
{
return (the_states & STATES_WAITING_ON_THREAD_QUEUE);
a000f5d0: e59f30b0 ldr r3, [pc, #176] ; a000f688 <_Thread_queue_Extract_priority_helper+0xd0>
a000f5d4: e5940010 ldr r0, [r4, #16]
a000f5d8: e0003003 and r3, r0, r3
Chain_Node *new_second_node;
Chain_Node *last_node;
the_node = (Chain_Node *) the_thread;
_ISR_Disable( level );
if ( !_States_Is_waiting_on_thread_queue( the_thread->current_state ) ) {
a000f5dc: e3530000 cmp r3, #0
a000f5e0: 1a000000 bne a000f5e8 <_Thread_queue_Extract_priority_helper+0x30>
_ISR_Enable( level );
a000f5e4: ea000017 b a000f648 <_Thread_queue_Extract_priority_helper+0x90>
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
}
a000f5e8: e5943038 ldr r3, [r4, #56] ; 0x38
/*
* The thread was actually waiting on a thread queue so let's remove it.
*/
next_node = the_node->next;
a000f5ec: e8941001 ldm r4, {r0, ip}
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a000f5f0: e284503c add r5, r4, #60 ; 0x3c
previous_node = the_node->previous;
if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) {
a000f5f4: e1530005 cmp r3, r5
head->next = new_second_node;
tail->previous = last_node;
last_node->next = tail;
}
} else {
previous_node->next = next_node;
a000f5f8: 058c0000 streq r0, [ip]
next_node->previous = previous_node;
a000f5fc: 0580c004 streq ip, [r0, #4]
*/
next_node = the_node->next;
previous_node = the_node->previous;
if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) {
a000f600: 0a00000e beq a000f640 <_Thread_queue_Extract_priority_helper+0x88>
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
}
a000f604: e5945040 ldr r5, [r4, #64] ; 0x40 <== NOT EXECUTED
if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) {
new_first_node = _Chain_First( &the_thread->Wait.Block2n );
new_first_thread = (Thread_Control *) new_first_node;
last_node = _Chain_Last( &the_thread->Wait.Block2n );
new_second_node = new_first_node->next;
a000f608: e5936000 ldr r6, [r3] <== NOT EXECUTED
previous_node->next = new_first_node;
next_node->previous = new_first_node;
a000f60c: e5803004 str r3, [r0, #4] <== NOT EXECUTED
new_first_node = _Chain_First( &the_thread->Wait.Block2n );
new_first_thread = (Thread_Control *) new_first_node;
last_node = _Chain_Last( &the_thread->Wait.Block2n );
new_second_node = new_first_node->next;
previous_node->next = new_first_node;
a000f610: e58c3000 str r3, [ip] <== NOT EXECUTED
next_node->previous = new_first_node;
new_first_node->next = next_node;
new_first_node->previous = previous_node;
a000f614: e8831001 stm r3, {r0, ip} <== NOT EXECUTED
if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) {
a000f618: e594c038 ldr ip, [r4, #56] ; 0x38 <== NOT EXECUTED
a000f61c: e5940040 ldr r0, [r4, #64] ; 0x40 <== NOT EXECUTED
a000f620: e15c0000 cmp ip, r0 <== NOT EXECUTED
a000f624: 0a000005 beq a000f640 <_Thread_queue_Extract_priority_helper+0x88><== NOT EXECUTED
/* > two threads on 2-n */
head = _Chain_Head( &new_first_thread->Wait.Block2n );
a000f628: e2830038 add r0, r3, #56 ; 0x38 <== NOT EXECUTED
tail = _Chain_Tail( &new_first_thread->Wait.Block2n );
new_second_node->previous = head;
head->next = new_second_node;
a000f62c: e5836038 str r6, [r3, #56] ; 0x38 <== NOT EXECUTED
if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) {
/* > two threads on 2-n */
head = _Chain_Head( &new_first_thread->Wait.Block2n );
tail = _Chain_Tail( &new_first_thread->Wait.Block2n );
new_second_node->previous = head;
a000f630: e5860004 str r0, [r6, #4] <== NOT EXECUTED
head->next = new_second_node;
tail->previous = last_node;
a000f634: e5835040 str r5, [r3, #64] ; 0x40 <== NOT EXECUTED
new_first_node->previous = previous_node;
if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) {
/* > two threads on 2-n */
head = _Chain_Head( &new_first_thread->Wait.Block2n );
tail = _Chain_Tail( &new_first_thread->Wait.Block2n );
a000f638: e283303c add r3, r3, #60 ; 0x3c <== NOT EXECUTED
new_second_node->previous = head;
head->next = new_second_node;
tail->previous = last_node;
last_node->next = tail;
a000f63c: e5853000 str r3, [r5] <== NOT EXECUTED
/*
* If we are not supposed to touch timers or the thread's state, return.
*/
if ( requeuing ) {
a000f640: e3520000 cmp r2, #0
a000f644: 0a000001 beq a000f650 <_Thread_queue_Extract_priority_helper+0x98>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000f648: e129f001 msr CPSR_fc, r1
a000f64c: e8bd8070 pop {r4, r5, r6, pc}
_ISR_Enable( level );
return;
}
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
a000f650: e5943050 ldr r3, [r4, #80] ; 0x50 <== NOT EXECUTED
a000f654: e3530002 cmp r3, #2 <== NOT EXECUTED
a000f658: 0a000001 beq a000f664 <_Thread_queue_Extract_priority_helper+0xac><== NOT EXECUTED
a000f65c: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED
a000f660: ea000004 b a000f678 <_Thread_queue_Extract_priority_helper+0xc0><== NOT EXECUTED
a000f664: e3a03003 mov r3, #3 <== NOT EXECUTED
a000f668: e5843050 str r3, [r4, #80] ; 0x50 <== NOT EXECUTED
a000f66c: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED
_ISR_Enable( level );
} else {
_Watchdog_Deactivate( &the_thread->Timer );
_ISR_Enable( level );
(void) _Watchdog_Remove( &the_thread->Timer );
a000f670: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED
a000f674: ebfff3e7 bl a000c618 <_Watchdog_Remove> <== NOT EXECUTED
a000f678: e59f100c ldr r1, [pc, #12] ; a000f68c <_Thread_queue_Extract_priority_helper+0xd4><== NOT EXECUTED
a000f67c: e1a00004 mov r0, r4 <== NOT EXECUTED
#if defined(RTEMS_MULTIPROCESSING)
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
_Thread_MP_Free_proxy( the_thread );
#endif
}
a000f680: e8bd4070 pop {r4, r5, r6, lr} <== NOT EXECUTED
a000f684: eaffef38 b a000b36c <_Thread_Clear_state> <== NOT EXECUTED
a000de4c <_Thread_queue_First_priority>:
*/
Thread_Control *_Thread_queue_First_priority (
Thread_queue_Control *the_thread_queue
)
{
a000de4c: e92d4010 push {r4, lr} <== NOT EXECUTED
a000de50: e3a02000 mov r2, #0 <== NOT EXECUTED
uint32_t index;
for( index=0 ;
a000de54: e1a03002 mov r3, r2 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a000de58: e3a0c00c mov ip, #12 <== NOT EXECUTED
a000de5c: e004039c mul r4, ip, r3 <== NOT EXECUTED
return (Thread_Control *) _Chain_First(
&the_thread_queue->Queues.Priority[ index ]
);
}
return NULL;
}
a000de60: e7901002 ldr r1, [r0, r2] <== NOT EXECUTED
a000de64: e2844004 add r4, r4, #4 <== NOT EXECUTED
a000de68: e0804004 add r4, r0, r4 <== NOT EXECUTED
uint32_t index;
for( index=0 ;
index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ;
index++ ) {
if ( !_Chain_Is_empty( &the_thread_queue->Queues.Priority[ index ] ) )
a000de6c: e1510004 cmp r1, r4 <== NOT EXECUTED
a000de70: 0a000001 beq a000de7c <_Thread_queue_First_priority+0x30> <== NOT EXECUTED
return (Thread_Control *) _Chain_First(
a000de74: e1a00001 mov r0, r1 <== NOT EXECUTED
a000de78: e8bd8010 pop {r4, pc} <== NOT EXECUTED
{
uint32_t index;
for( index=0 ;
index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ;
index++ ) {
a000de7c: e2833001 add r3, r3, #1 <== NOT EXECUTED
Thread_queue_Control *the_thread_queue
)
{
uint32_t index;
for( index=0 ;
a000de80: e3530004 cmp r3, #4 <== NOT EXECUTED
index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ;
index++ ) {
a000de84: e282200c add r2, r2, #12 <== NOT EXECUTED
Thread_queue_Control *the_thread_queue
)
{
uint32_t index;
for( index=0 ;
a000de88: 1afffff3 bne a000de5c <_Thread_queue_First_priority+0x10> <== NOT EXECUTED
if ( !_Chain_Is_empty( &the_thread_queue->Queues.Priority[ index ] ) )
return (Thread_Control *) _Chain_First(
&the_thread_queue->Queues.Priority[ index ]
);
}
return NULL;
a000de8c: e3a00000 mov r0, #0 <== NOT EXECUTED
}
a000de90: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000f690 <_Thread_queue_Process_timeout>:
#include <rtems/score/tqdata.h>
void _Thread_queue_Process_timeout(
Thread_Control *the_thread
)
{
a000f690: e1a01000 mov r1, r0 <== NOT EXECUTED
Thread_queue_Control *the_thread_queue = the_thread->Wait.queue;
a000f694: e5900044 ldr r0, [r0, #68] ; 0x44 <== NOT EXECUTED
* If it is not satisfied, then it is "nothing happened" and
* this is the "timeout" transition. After a request is satisfied,
* a timeout is not allowed to occur.
*/
if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_SYNCHRONIZED &&
a000f698: e5903030 ldr r3, [r0, #48] ; 0x30 <== NOT EXECUTED
a000f69c: e3530000 cmp r3, #0 <== NOT EXECUTED
a000f6a0: 0a000009 beq a000f6cc <_Thread_queue_Process_timeout+0x3c> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool _Thread_Is_executing (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Executing );
a000f6a4: e59f202c ldr r2, [pc, #44] ; a000f6d8 <_Thread_queue_Process_timeout+0x48><== NOT EXECUTED
a000f6a8: e5922004 ldr r2, [r2, #4] <== NOT EXECUTED
a000f6ac: e1510002 cmp r1, r2 <== NOT EXECUTED
a000f6b0: 1a000005 bne a000f6cc <_Thread_queue_Process_timeout+0x3c> <== NOT EXECUTED
_Thread_Is_executing( the_thread ) ) {
if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_SATISFIED ) {
a000f6b4: e3530003 cmp r3, #3 <== NOT EXECUTED
the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status;
a000f6b8: 1590303c ldrne r3, [r0, #60] ; 0x3c <== NOT EXECUTED
a000f6bc: 15813034 strne r3, [r1, #52] ; 0x34 <== NOT EXECUTED
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT;
a000f6c0: 13a03002 movne r3, #2 <== NOT EXECUTED
a000f6c4: 15803030 strne r3, [r0, #48] ; 0x30 <== NOT EXECUTED
a000f6c8: e12fff1e bx lr <== NOT EXECUTED
}
} else {
the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status;
a000f6cc: e590303c ldr r3, [r0, #60] ; 0x3c <== NOT EXECUTED
a000f6d0: e5813034 str r3, [r1, #52] ; 0x34 <== NOT EXECUTED
_Thread_queue_Extract( the_thread->Wait.queue, the_thread );
a000f6d4: eaffffb1 b a000f5a0 <_Thread_queue_Extract> <== NOT EXECUTED
a000be94 <_Thread_queue_Timeout>:
void _Thread_queue_Timeout(
Objects_Id id,
void *ignored __attribute__((unused))
)
{
a000be94: e92d4001 push {r0, lr} <== NOT EXECUTED
Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
a000be98: e1a0100d mov r1, sp <== NOT EXECUTED
a000be9c: ebfffe06 bl a000b6bc <_Thread_Get> <== NOT EXECUTED
switch ( location ) {
a000bea0: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a000bea4: e3530000 cmp r3, #0 <== NOT EXECUTED
a000bea8: 1a000004 bne a000bec0 <_Thread_queue_Timeout+0x2c> <== NOT EXECUTED
#if defined(RTEMS_MULTIPROCESSING)
case OBJECTS_REMOTE: /* impossible */
#endif
break;
case OBJECTS_LOCAL:
_Thread_queue_Process_timeout( the_thread );
a000beac: eb000df7 bl a000f690 <_Thread_queue_Process_timeout> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
a000beb0: e59f300c ldr r3, [pc, #12] ; a000bec4 <_Thread_queue_Timeout+0x30><== NOT EXECUTED
a000beb4: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000beb8: e2422001 sub r2, r2, #1 <== NOT EXECUTED
a000bebc: e5832000 str r2, [r3] <== NOT EXECUTED
_Thread_Unnest_dispatch();
break;
}
}
a000bec0: e8bd8008 pop {r3, pc} <== NOT EXECUTED
a0018574 <_Timer_server_Body>:
* @a arg points to the corresponding timer server control block.
*/
static rtems_task _Timer_server_Body(
rtems_task_argument arg
)
{
a0018574: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
a0018578: e24dd01c sub sp, sp, #28
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *tail = _Chain_Tail( the_chain );
head->next = tail;
a001857c: e28db010 add fp, sp, #16
a0018580: e28d6004 add r6, sp, #4
a0018584: e28b2004 add r2, fp, #4
head->previous = NULL;
a0018588: e3a03000 mov r3, #0
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *tail = _Chain_Tail( the_chain );
head->next = tail;
a001858c: e2868004 add r8, r6, #4
a0018590: e1a04000 mov r4, r0
a0018594: e58d2010 str r2, [sp, #16]
head->previous = NULL;
a0018598: e58d3014 str r3, [sp, #20]
tail->previous = head;
a001859c: e58db018 str fp, [sp, #24]
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *tail = _Chain_Tail( the_chain );
head->next = tail;
a00185a0: e58d8004 str r8, [sp, #4]
head->previous = NULL;
a00185a4: e58d3008 str r3, [sp, #8]
tail->previous = head;
a00185a8: e58d600c str r6, [sp, #12]
*/
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_tail(
const Chain_Control *the_chain
)
{
return &the_chain->Tail.Node;
a00185ac: e58d2000 str r2, [sp]
static void _Timer_server_Process_tod_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
a00185b0: e59f9160 ldr r9, [pc, #352] ; a0018718 <_Timer_server_Body+0x1a4>
Chain_Control *tmp;
/*
* Afterwards all timer inserts are directed to this chain and the interval
* and TOD chains will be no more modified by other parties.
*/
ts->insert_chain = insert_chain;
a00185b4: e584b078 str fp, [r4, #120] ; 0x78
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
a00185b8: e284a030 add sl, r4, #48 ; 0x30
/*
* The current TOD is before the last TOD which indicates that
* TOD has been set backwards.
*/
delta = last_snapshot - snapshot;
_Watchdog_Adjust( &watchdogs->Chain, WATCHDOG_BACKWARD, delta );
a00185bc: e2847068 add r7, r4, #104 ; 0x68
static void _Timer_server_Process_interval_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
a00185c0: e59f2154 ldr r2, [pc, #340] ; a001871c <_Timer_server_Body+0x1a8>
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
a00185c4: e1a0000a mov r0, sl
static void _Timer_server_Process_interval_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
a00185c8: e5923000 ldr r3, [r2]
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
a00185cc: e594103c ldr r1, [r4, #60] ; 0x3c
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
a00185d0: e1a02006 mov r2, r6
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
a00185d4: e584303c str r3, [r4, #60] ; 0x3c
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
a00185d8: e0611003 rsb r1, r1, r3
a00185dc: eb0010cd bl a001c918 <_Watchdog_Adjust_to_chain>
static void _Timer_server_Process_tod_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
a00185e0: e5995000 ldr r5, [r9]
Watchdog_Interval last_snapshot = watchdogs->last_snapshot;
a00185e4: e5942074 ldr r2, [r4, #116] ; 0x74
/*
* Process the seconds chain. Start by checking that the Time
* of Day (TOD) has not been set backwards. If it has then
* we want to adjust the watchdogs->Chain to indicate this.
*/
if ( snapshot > last_snapshot ) {
a00185e8: e1550002 cmp r5, r2
a00185ec: 9a000004 bls a0018604 <_Timer_server_Body+0x90>
/*
* This path is for normal forward movement and cases where the
* TOD has been set forward.
*/
delta = snapshot - last_snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
a00185f0: e0621005 rsb r1, r2, r5
a00185f4: e1a00007 mov r0, r7
a00185f8: e1a02006 mov r2, r6
a00185fc: eb0010c5 bl a001c918 <_Watchdog_Adjust_to_chain>
a0018600: ea000004 b a0018618 <_Timer_server_Body+0xa4>
} else if ( snapshot < last_snapshot ) {
a0018604: 2a000003 bcs a0018618 <_Timer_server_Body+0xa4>
/*
* The current TOD is before the last TOD which indicates that
* TOD has been set backwards.
*/
delta = last_snapshot - snapshot;
_Watchdog_Adjust( &watchdogs->Chain, WATCHDOG_BACKWARD, delta );
a0018608: e1a00007 mov r0, r7 <== NOT EXECUTED
a001860c: e3a01001 mov r1, #1 <== NOT EXECUTED
a0018610: e0652002 rsb r2, r5, r2 <== NOT EXECUTED
a0018614: eb001097 bl a001c878 <_Watchdog_Adjust> <== NOT EXECUTED
}
watchdogs->last_snapshot = snapshot;
a0018618: e5845074 str r5, [r4, #116] ; 0x74
}
static void _Timer_server_Process_insertions( Timer_server_Control *ts )
{
while ( true ) {
Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain );
a001861c: e5940078 ldr r0, [r4, #120] ; 0x78
a0018620: eb00029c bl a0019098 <_Chain_Get>
if ( timer == NULL ) {
a0018624: e2505000 subs r5, r0, #0
a0018628: 0a000009 beq a0018654 <_Timer_server_Body+0xe0>
static void _Timer_server_Insert_timer(
Timer_server_Control *ts,
Timer_Control *timer
)
{
if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {
a001862c: e5953038 ldr r3, [r5, #56] ; 0x38 <== NOT EXECUTED
a0018630: e3530001 cmp r3, #1 <== NOT EXECUTED
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
a0018634: 01a0000a moveq r0, sl <== NOT EXECUTED
static void _Timer_server_Insert_timer(
Timer_server_Control *ts,
Timer_Control *timer
)
{
if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {
a0018638: 0a000002 beq a0018648 <_Timer_server_Body+0xd4> <== NOT EXECUTED
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
} else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) {
a001863c: e3530003 cmp r3, #3 <== NOT EXECUTED
a0018640: 1afffff5 bne a001861c <_Timer_server_Body+0xa8> <== NOT EXECUTED
_Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );
a0018644: e1a00007 mov r0, r7 <== NOT EXECUTED
a0018648: e2851010 add r1, r5, #16 <== NOT EXECUTED
a001864c: eb0010dc bl a001c9c4 <_Watchdog_Insert> <== NOT EXECUTED
a0018650: eafffff1 b a001861c <_Timer_server_Body+0xa8> <== NOT EXECUTED
* of zero it will be processed in the next iteration of the timer server
* body loop.
*/
_Timer_server_Process_insertions( ts );
_ISR_Disable( level );
a0018654: ebffff94 bl a00184ac <arm_interrupt_disable>
tmp = ts->insert_chain;
a0018658: e5943078 ldr r3, [r4, #120] ; 0x78
if ( _Chain_Is_empty( insert_chain ) ) {
a001865c: e59d2000 ldr r2, [sp]
a0018660: e59d3010 ldr r3, [sp, #16]
a0018664: e1530002 cmp r3, r2
ts->insert_chain = NULL;
a0018668: 05845078 streq r5, [r4, #120] ; 0x78
*/
_Timer_server_Process_insertions( ts );
_ISR_Disable( level );
tmp = ts->insert_chain;
if ( _Chain_Is_empty( insert_chain ) ) {
a001866c: 13a05001 movne r5, #1
a0018670: e129f000 msr CPSR_fc, r0
* Afterwards all timer inserts are directed to this chain and the interval
* and TOD chains will be no more modified by other parties.
*/
ts->insert_chain = insert_chain;
while ( do_loop ) {
a0018674: e3550000 cmp r5, #0
a0018678: 1affffd0 bne a00185c0 <_Timer_server_Body+0x4c>
_Chain_Initialize_empty( &fire_chain );
while ( true ) {
_Timer_server_Get_watchdogs_that_fire_now( ts, &insert_chain, &fire_chain );
if ( !_Chain_Is_empty( &fire_chain ) ) {
a001867c: e59d3004 ldr r3, [sp, #4]
a0018680: e1530008 cmp r3, r8
a0018684: 0a000012 beq a00186d4 <_Timer_server_Body+0x160>
/*
* It is essential that interrupts are disable here since an interrupt
* service routine may remove a watchdog from the chain.
*/
_ISR_Disable( level );
a0018688: ebffff87 bl a00184ac <arm_interrupt_disable>
initialized = false;
}
#endif
return status;
}
a001868c: e59d2004 ldr r2, [sp, #4]
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(
Chain_Control *the_chain
)
{
if ( !_Chain_Is_empty(the_chain))
a0018690: e1520008 cmp r2, r8
a0018694: 0a00000c beq a00186cc <_Timer_server_Body+0x158>
Chain_Control *the_chain
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *old_first = head->next;
Chain_Node *new_first = old_first->next;
a0018698: e5923000 ldr r3, [r2]
* It is essential that interrupts are disable here since an interrupt
* service routine may remove a watchdog from the chain.
*/
_ISR_Disable( level );
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain );
if ( watchdog != NULL ) {
a001869c: e3520000 cmp r2, #0
head->next = new_first;
a00186a0: e58d3004 str r3, [sp, #4]
new_first->previous = head;
a00186a4: e5836004 str r6, [r3, #4]
a00186a8: 0a000007 beq a00186cc <_Timer_server_Body+0x158>
watchdog->state = WATCHDOG_INACTIVE;
a00186ac: e3a03000 mov r3, #0
a00186b0: e5823008 str r3, [r2, #8]
a00186b4: e129f000 msr CPSR_fc, r0
/*
* The timer server may block here and wait for resources or time.
* The system watchdogs are inactive and will remain inactive since
* the active flag of the timer server is true.
*/
(*watchdog->routine)( watchdog->id, watchdog->user_data );
a00186b8: e592301c ldr r3, [r2, #28]
a00186bc: e5920020 ldr r0, [r2, #32]
a00186c0: e5921024 ldr r1, [r2, #36] ; 0x24
a00186c4: e12fff33 blx r3
}
a00186c8: eaffffee b a0018688 <_Timer_server_Body+0x114>
a00186cc: e129f000 msr CPSR_fc, r0
a00186d0: eaffffb6 b a00185b0 <_Timer_server_Body+0x3c>
} else {
ts->active = false;
a00186d4: e5c4507c strb r5, [r4, #124] ; 0x7c
/*
* Block until there is something to do.
*/
_Thread_Disable_dispatch();
a00186d8: ebffff77 bl a00184bc <_Thread_Disable_dispatch>
_Thread_Set_state( ts->thread, STATES_DELAYING );
a00186dc: e3a01008 mov r1, #8
a00186e0: e5940000 ldr r0, [r4]
a00186e4: eb000eaf bl a001c1a8 <_Thread_Set_state>
_Timer_server_Reset_interval_system_watchdog( ts );
a00186e8: e1a00004 mov r0, r4
a00186ec: ebffff78 bl a00184d4 <_Timer_server_Reset_interval_system_watchdog>
_Timer_server_Reset_tod_system_watchdog( ts );
a00186f0: e1a00004 mov r0, r4
a00186f4: ebffff8a bl a0018524 <_Timer_server_Reset_tod_system_watchdog>
_Thread_Enable_dispatch();
a00186f8: eb000c66 bl a001b898 <_Thread_Enable_dispatch>
ts->active = true;
a00186fc: e3a03001 mov r3, #1
a0018700: e5c4307c strb r3, [r4, #124] ; 0x7c
static void _Timer_server_Stop_interval_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
a0018704: e2840008 add r0, r4, #8
a0018708: eb001105 bl a001cb24 <_Watchdog_Remove>
static void _Timer_server_Stop_tod_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
a001870c: e2840040 add r0, r4, #64 ; 0x40
a0018710: eb001103 bl a001cb24 <_Watchdog_Remove>
a0018714: eaffffa5 b a00185b0 <_Timer_server_Body+0x3c>
a0018720 <_Timer_server_Schedule_operation_method>:
static void _Timer_server_Schedule_operation_method(
Timer_server_Control *ts,
Timer_Control *timer
)
{
a0018720: e92d4070 push {r4, r5, r6, lr}
if ( ts->insert_chain == NULL ) {
a0018724: e5906078 ldr r6, [r0, #120] ; 0x78
static void _Timer_server_Schedule_operation_method(
Timer_server_Control *ts,
Timer_Control *timer
)
{
a0018728: e1a04000 mov r4, r0
a001872c: e1a05001 mov r5, r1
if ( ts->insert_chain == NULL ) {
a0018730: e3560000 cmp r6, #0
a0018734: 1a00003a bne a0018824 <_Timer_server_Schedule_operation_method+0x104>
* is the reference point for the delta chain. Thus if we do not update the
* reference point we have to add DT to the initial delta of the watchdog
* being inserted. This could result in an integer overflow.
*/
_Thread_Disable_dispatch();
a0018738: ebffff5f bl a00184bc <_Thread_Disable_dispatch>
if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {
a001873c: e5953038 ldr r3, [r5, #56] ; 0x38
a0018740: e3530001 cmp r3, #1
a0018744: 1a000017 bne a00187a8 <_Timer_server_Schedule_operation_method+0x88>
/*
* We have to advance the last known ticks value of the server and update
* the watchdog chain accordingly.
*/
_ISR_Disable( level );
a0018748: ebffff57 bl a00184ac <arm_interrupt_disable>
snapshot = _Watchdog_Ticks_since_boot;
a001874c: e59f30dc ldr r3, [pc, #220] ; a0018830 <_Timer_server_Schedule_operation_method+0x110>
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a0018750: e284c034 add ip, r4, #52 ; 0x34
a0018754: e5932000 ldr r2, [r3]
initialized = false;
}
#endif
return status;
}
a0018758: e5943030 ldr r3, [r4, #48] ; 0x30
* We have to advance the last known ticks value of the server and update
* the watchdog chain accordingly.
*/
_ISR_Disable( level );
snapshot = _Watchdog_Ticks_since_boot;
last_snapshot = ts->Interval_watchdogs.last_snapshot;
a001875c: e594103c ldr r1, [r4, #60] ; 0x3c
if ( !_Chain_Is_empty( &ts->Interval_watchdogs.Chain ) ) {
a0018760: e153000c cmp r3, ip
a0018764: 0a000004 beq a001877c <_Timer_server_Schedule_operation_method+0x5c>
/*
* We assume adequate unsigned arithmetic here.
*/
delta = snapshot - last_snapshot;
delta_interval = first_watchdog->delta_interval;
a0018768: e593c010 ldr ip, [r3, #16]
first_watchdog = _Watchdog_First( &ts->Interval_watchdogs.Chain );
/*
* We assume adequate unsigned arithmetic here.
*/
delta = snapshot - last_snapshot;
a001876c: e0611002 rsb r1, r1, r2
delta_interval = first_watchdog->delta_interval;
if (delta_interval > delta) {
a0018770: e15c0001 cmp ip, r1
delta_interval -= delta;
a0018774: 8061600c rsbhi r6, r1, ip
} else {
delta_interval = 0;
}
first_watchdog->delta_interval = delta_interval;
a0018778: e5836010 str r6, [r3, #16]
}
ts->Interval_watchdogs.last_snapshot = snapshot;
a001877c: e584203c str r2, [r4, #60] ; 0x3c
a0018780: e129f000 msr CPSR_fc, r0
_ISR_Enable( level );
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
a0018784: e2840030 add r0, r4, #48 ; 0x30
a0018788: e2851010 add r1, r5, #16
a001878c: eb00108c bl a001c9c4 <_Watchdog_Insert>
if ( !ts->active ) {
a0018790: e5d4307c ldrb r3, [r4, #124] ; 0x7c
a0018794: e3530000 cmp r3, #0
a0018798: 1a00001f bne a001881c <_Timer_server_Schedule_operation_method+0xfc>
_Timer_server_Reset_interval_system_watchdog( ts );
a001879c: e1a00004 mov r0, r4
a00187a0: ebffff4b bl a00184d4 <_Timer_server_Reset_interval_system_watchdog>
a00187a4: ea00001c b a001881c <_Timer_server_Schedule_operation_method+0xfc>
}
} else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) {
a00187a8: e3530003 cmp r3, #3
a00187ac: 1a00001a bne a001881c <_Timer_server_Schedule_operation_method+0xfc>
/*
* We have to advance the last known seconds value of the server and update
* the watchdog chain accordingly.
*/
_ISR_Disable( level );
a00187b0: ebffff3d bl a00184ac <arm_interrupt_disable>
initialized = false;
}
#endif
return status;
}
a00187b4: e5942068 ldr r2, [r4, #104] ; 0x68
/*
* We have to advance the last known seconds value of the server and update
* the watchdog chain accordingly.
*/
_ISR_Disable( level );
snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
a00187b8: e59f3074 ldr r3, [pc, #116] ; a0018834 <_Timer_server_Schedule_operation_method+0x114>
a00187bc: e284c06c add ip, r4, #108 ; 0x6c
last_snapshot = ts->TOD_watchdogs.last_snapshot;
if ( !_Chain_Is_empty( &ts->TOD_watchdogs.Chain ) ) {
a00187c0: e152000c cmp r2, ip
/*
* We have to advance the last known seconds value of the server and update
* the watchdog chain accordingly.
*/
_ISR_Disable( level );
snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
a00187c4: e5933000 ldr r3, [r3]
last_snapshot = ts->TOD_watchdogs.last_snapshot;
a00187c8: e5941074 ldr r1, [r4, #116] ; 0x74
if ( !_Chain_Is_empty( &ts->TOD_watchdogs.Chain ) ) {
a00187cc: 0a000008 beq a00187f4 <_Timer_server_Schedule_operation_method+0xd4>
first_watchdog = _Watchdog_First( &ts->TOD_watchdogs.Chain );
delta_interval = first_watchdog->delta_interval;
a00187d0: e592c010 ldr ip, [r2, #16] <== NOT EXECUTED
if ( snapshot > last_snapshot ) {
a00187d4: e1530001 cmp r3, r1 <== NOT EXECUTED
}
} else {
/*
* Someone put us in the past.
*/
delta = last_snapshot - snapshot;
a00187d8: 908c6001 addls r6, ip, r1 <== NOT EXECUTED
delta_interval += delta;
a00187dc: 90636006 rsbls r6, r3, r6 <== NOT EXECUTED
snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
last_snapshot = ts->TOD_watchdogs.last_snapshot;
if ( !_Chain_Is_empty( &ts->TOD_watchdogs.Chain ) ) {
first_watchdog = _Watchdog_First( &ts->TOD_watchdogs.Chain );
delta_interval = first_watchdog->delta_interval;
if ( snapshot > last_snapshot ) {
a00187e0: 9a000002 bls a00187f0 <_Timer_server_Schedule_operation_method+0xd0><== NOT EXECUTED
/*
* We advanced in time.
*/
delta = snapshot - last_snapshot;
a00187e4: e0611003 rsb r1, r1, r3 <== NOT EXECUTED
if (delta_interval > delta) {
a00187e8: e15c0001 cmp ip, r1 <== NOT EXECUTED
delta_interval -= delta;
a00187ec: 8061600c rsbhi r6, r1, ip <== NOT EXECUTED
* Someone put us in the past.
*/
delta = last_snapshot - snapshot;
delta_interval += delta;
}
first_watchdog->delta_interval = delta_interval;
a00187f0: e5826010 str r6, [r2, #16] <== NOT EXECUTED
}
ts->TOD_watchdogs.last_snapshot = snapshot;
a00187f4: e5843074 str r3, [r4, #116] ; 0x74
a00187f8: e129f000 msr CPSR_fc, r0
_ISR_Enable( level );
_Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );
a00187fc: e2840068 add r0, r4, #104 ; 0x68
a0018800: e2851010 add r1, r5, #16
a0018804: eb00106e bl a001c9c4 <_Watchdog_Insert>
if ( !ts->active ) {
a0018808: e5d4307c ldrb r3, [r4, #124] ; 0x7c
a001880c: e3530000 cmp r3, #0
a0018810: 1a000001 bne a001881c <_Timer_server_Schedule_operation_method+0xfc>
_Timer_server_Reset_tod_system_watchdog( ts );
a0018814: e1a00004 mov r0, r4
a0018818: ebffff41 bl a0018524 <_Timer_server_Reset_tod_system_watchdog>
* critical section. We have to use the protected chain methods because
* we may be interrupted by a higher priority interrupt.
*/
_Chain_Append( ts->insert_chain, &timer->Object.Node );
}
}
a001881c: e8bd4070 pop {r4, r5, r6, lr}
if ( !ts->active ) {
_Timer_server_Reset_tod_system_watchdog( ts );
}
}
_Thread_Enable_dispatch();
a0018820: ea000c1c b a001b898 <_Thread_Enable_dispatch>
* server is not preemptible, so we must be in interrupt context here. No
* thread dispatch will happen until the timer server finishes its
* critical section. We have to use the protected chain methods because
* we may be interrupted by a higher priority interrupt.
*/
_Chain_Append( ts->insert_chain, &timer->Object.Node );
a0018824: e5900078 ldr r0, [r0, #120] ; 0x78 <== NOT EXECUTED
}
}
a0018828: e8bd4070 pop {r4, r5, r6, lr} <== NOT EXECUTED
* server is not preemptible, so we must be in interrupt context here. No
* thread dispatch will happen until the timer server finishes its
* critical section. We have to use the protected chain methods because
* we may be interrupted by a higher priority interrupt.
*/
_Chain_Append( ts->insert_chain, &timer->Object.Node );
a001882c: ea000206 b a001904c <_Chain_Append> <== NOT EXECUTED
a000c188 <_Timespec_Add_to>:
uint32_t _Timespec_Add_to(
struct timespec *time,
const struct timespec *add
)
{
a000c188: e1a03000 mov r3, r0
uint32_t seconds = add->tv_sec;
/* Add the basics */
time->tv_sec += add->tv_sec;
a000c18c: e5932000 ldr r2, [r3]
uint32_t _Timespec_Add_to(
struct timespec *time,
const struct timespec *add
)
{
uint32_t seconds = add->tv_sec;
a000c190: e5910000 ldr r0, [r1]
/* Add the basics */
time->tv_sec += add->tv_sec;
time->tv_nsec += add->tv_nsec;
a000c194: e593c004 ldr ip, [r3, #4]
)
{
uint32_t seconds = add->tv_sec;
/* Add the basics */
time->tv_sec += add->tv_sec;
a000c198: e0822000 add r2, r2, r0
a000c19c: e5832000 str r2, [r3]
time->tv_nsec += add->tv_nsec;
a000c1a0: e5912004 ldr r2, [r1, #4]
a000c1a4: e08c2002 add r2, ip, r2
a000c1a8: e5832004 str r2, [r3, #4]
/* Now adjust it so nanoseconds is in range */
while ( time->tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
a000c1ac: e59fc02c ldr ip, [pc, #44] ; a000c1e0 <_Timespec_Add_to+0x58>
a000c1b0: ea000006 b a000c1d0 <_Timespec_Add_to+0x48>
time->tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
a000c1b4: e59f2028 ldr r2, [pc, #40] ; a000c1e4 <_Timespec_Add_to+0x5c><== NOT EXECUTED
time->tv_sec++;
seconds++;
a000c1b8: e2800001 add r0, r0, #1 <== NOT EXECUTED
time->tv_sec += add->tv_sec;
time->tv_nsec += add->tv_nsec;
/* Now adjust it so nanoseconds is in range */
while ( time->tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
time->tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
a000c1bc: e0812002 add r2, r1, r2 <== NOT EXECUTED
a000c1c0: e5832004 str r2, [r3, #4] <== NOT EXECUTED
time->tv_sec++;
a000c1c4: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000c1c8: e2822001 add r2, r2, #1 <== NOT EXECUTED
a000c1cc: e5832000 str r2, [r3] <== NOT EXECUTED
/* Add the basics */
time->tv_sec += add->tv_sec;
time->tv_nsec += add->tv_nsec;
/* Now adjust it so nanoseconds is in range */
while ( time->tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
a000c1d0: e5931004 ldr r1, [r3, #4]
a000c1d4: e151000c cmp r1, ip
a000c1d8: 8afffff5 bhi a000c1b4 <_Timespec_Add_to+0x2c>
time->tv_sec++;
seconds++;
}
return seconds;
}
a000c1dc: e12fff1e bx lr
a000dd20 <_Timespec_Divide>:
const struct timespec *lhs,
const struct timespec *rhs,
uint32_t *ival_percentage,
uint32_t *fval_percentage
)
{
a000dd20: e92d40f0 push {r4, r5, r6, r7, lr}
a000dd24: e1a05002 mov r5, r2
* in a 64-bit integer.
*/
left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
left += lhs->tv_nsec;
right = rhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
right += rhs->tv_nsec;
a000dd28: e5912004 ldr r2, [r1, #4]
* For math simplicity just convert the timespec to nanoseconds
* in a 64-bit integer.
*/
left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
left += lhs->tv_nsec;
right = rhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
a000dd2c: e5917000 ldr r7, [r1]
/*
* For math simplicity just convert the timespec to nanoseconds
* in a 64-bit integer.
*/
left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
a000dd30: e590c000 ldr ip, [r0]
left += lhs->tv_nsec;
a000dd34: e5906004 ldr r6, [r0, #4]
right = rhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
a000dd38: e59f0068 ldr r0, [pc, #104] ; a000dda8 <_Timespec_Divide+0x88>
const struct timespec *lhs,
const struct timespec *rhs,
uint32_t *ival_percentage,
uint32_t *fval_percentage
)
{
a000dd3c: e1a04003 mov r4, r3
* in a 64-bit integer.
*/
left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
left += lhs->tv_nsec;
right = rhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
right += rhs->tv_nsec;
a000dd40: e1a03fc2 asr r3, r2, #31
a000dd44: e0e32790 smlal r2, r3, r0, r7
if ( right == 0 ) {
a000dd48: e1921003 orrs r1, r2, r3
a000dd4c: 1a000002 bne a000dd5c <_Timespec_Divide+0x3c>
*ival_percentage = 0;
a000dd50: e5851000 str r1, [r5]
*fval_percentage = 0;
a000dd54: e5841000 str r1, [r4]
return;
a000dd58: e8bd80f0 pop {r4, r5, r6, r7, pc}
/*
* For math simplicity just convert the timespec to nanoseconds
* in a 64-bit integer.
*/
left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND;
left += lhs->tv_nsec;
a000dd5c: e1a07fc6 asr r7, r6, #31 <== NOT EXECUTED
a000dd60: e0e76c90 smlal r6, r7, r0, ip <== NOT EXECUTED
* Put it back in the timespec result.
*
* TODO: Rounding on the last digit of the fval.
*/
answer = (left * 100000) / right;
a000dd64: e59fc040 ldr ip, [pc, #64] ; a000ddac <_Timespec_Divide+0x8c><== NOT EXECUTED
a000dd68: e0810c96 umull r0, r1, r6, ip <== NOT EXECUTED
a000dd6c: e021179c mla r1, ip, r7, r1 <== NOT EXECUTED
a000dd70: eb003fa0 bl a001dbf8 <__udivdi3> <== NOT EXECUTED
*ival_percentage = answer / 1000;
a000dd74: e3a02ffa mov r2, #1000 ; 0x3e8 <== NOT EXECUTED
a000dd78: e3a03000 mov r3, #0 <== NOT EXECUTED
* Put it back in the timespec result.
*
* TODO: Rounding on the last digit of the fval.
*/
answer = (left * 100000) / right;
a000dd7c: e1a07000 mov r7, r0 <== NOT EXECUTED
a000dd80: e1a06001 mov r6, r1 <== NOT EXECUTED
*ival_percentage = answer / 1000;
a000dd84: eb003f9b bl a001dbf8 <__udivdi3> <== NOT EXECUTED
*fval_percentage = answer % 1000;
a000dd88: e1a01006 mov r1, r6 <== NOT EXECUTED
* TODO: Rounding on the last digit of the fval.
*/
answer = (left * 100000) / right;
*ival_percentage = answer / 1000;
a000dd8c: e5850000 str r0, [r5] <== NOT EXECUTED
*fval_percentage = answer % 1000;
a000dd90: e3a02ffa mov r2, #1000 ; 0x3e8 <== NOT EXECUTED
a000dd94: e1a00007 mov r0, r7 <== NOT EXECUTED
a000dd98: e3a03000 mov r3, #0 <== NOT EXECUTED
a000dd9c: eb0040a7 bl a001e040 <__umoddi3> <== NOT EXECUTED
a000dda0: e5840000 str r0, [r4] <== NOT EXECUTED
a000dda4: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
a000dcf8 <_Timespec_Divide_by_integer>:
void _Timespec_Divide_by_integer(
const struct timespec *time,
uint32_t iterations,
struct timespec *result
)
{
a000dcf8: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED
/*
* For math simplicity just convert the timespec to nanoseconds
* in a 64-bit integer.
*/
t = time->tv_sec;
t *= TOD_NANOSECONDS_PER_SECOND;
a000dcfc: e59fc06c ldr ip, [pc, #108] ; a000dd70 <_Timespec_Divide_by_integer+0x78><== NOT EXECUTED
/*
* For math simplicity just convert the timespec to nanoseconds
* in a 64-bit integer.
*/
t = time->tv_sec;
a000dd00: e590e000 ldr lr, [r0] <== NOT EXECUTED
void _Timespec_Divide_by_integer(
const struct timespec *time,
uint32_t iterations,
struct timespec *result
)
{
a000dd04: e1a03001 mov r3, r1 <== NOT EXECUTED
a000dd08: e1a04002 mov r4, r2 <== NOT EXECUTED
/*
* For math simplicity just convert the timespec to nanoseconds
* in a 64-bit integer.
*/
t = time->tv_sec;
t *= TOD_NANOSECONDS_PER_SECOND;
a000dd0c: e0821c9e umull r1, r2, lr, ip <== NOT EXECUTED
/*
* For math simplicity just convert the timespec to nanoseconds
* in a 64-bit integer.
*/
t = time->tv_sec;
a000dd10: e1a0500e mov r5, lr <== NOT EXECUTED
a000dd14: e1a06fc5 asr r6, r5, #31 <== NOT EXECUTED
t *= TOD_NANOSECONDS_PER_SECOND;
t += time->tv_nsec;
a000dd18: e5900004 ldr r0, [r0, #4] <== NOT EXECUTED
/*
* For math simplicity just convert the timespec to nanoseconds
* in a 64-bit integer.
*/
t = time->tv_sec;
t *= TOD_NANOSECONDS_PER_SECOND;
a000dd1c: e022269c mla r2, ip, r6, r2 <== NOT EXECUTED
/*
* Divide to get nanoseconds per iteration
*/
t /= iterations;
a000dd20: e0915000 adds r5, r1, r0 <== NOT EXECUTED
a000dd24: e0a26fc0 adc r6, r2, r0, asr #31 <== NOT EXECUTED
a000dd28: e1a01006 mov r1, r6 <== NOT EXECUTED
a000dd2c: e1a02003 mov r2, r3 <== NOT EXECUTED
a000dd30: e1a00005 mov r0, r5 <== NOT EXECUTED
a000dd34: e3a03000 mov r3, #0 <== NOT EXECUTED
a000dd38: eb003ddf bl a001d4bc <__udivdi3> <== NOT EXECUTED
/*
* Put it back in the timespec result
*/
result->tv_sec = t / TOD_NANOSECONDS_PER_SECOND;
a000dd3c: e59f202c ldr r2, [pc, #44] ; a000dd70 <_Timespec_Divide_by_integer+0x78><== NOT EXECUTED
a000dd40: e3a03000 mov r3, #0 <== NOT EXECUTED
/*
* Divide to get nanoseconds per iteration
*/
t /= iterations;
a000dd44: e1a06000 mov r6, r0 <== NOT EXECUTED
a000dd48: e1a05001 mov r5, r1 <== NOT EXECUTED
/*
* Put it back in the timespec result
*/
result->tv_sec = t / TOD_NANOSECONDS_PER_SECOND;
a000dd4c: eb003dda bl a001d4bc <__udivdi3> <== NOT EXECUTED
result->tv_nsec = t % TOD_NANOSECONDS_PER_SECOND;
a000dd50: e1a01005 mov r1, r5 <== NOT EXECUTED
/*
* Put it back in the timespec result
*/
result->tv_sec = t / TOD_NANOSECONDS_PER_SECOND;
a000dd54: e5840000 str r0, [r4] <== NOT EXECUTED
result->tv_nsec = t % TOD_NANOSECONDS_PER_SECOND;
a000dd58: e59f2010 ldr r2, [pc, #16] ; a000dd70 <_Timespec_Divide_by_integer+0x78><== NOT EXECUTED
a000dd5c: e1a00006 mov r0, r6 <== NOT EXECUTED
a000dd60: e3a03000 mov r3, #0 <== NOT EXECUTED
a000dd64: eb003ee6 bl a001d904 <__umoddi3> <== NOT EXECUTED
a000dd68: e5840004 str r0, [r4, #4] <== NOT EXECUTED
}
a000dd6c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
a001dfa4 <_Timespec_From_ticks>:
struct timespec *time
)
{
uint32_t usecs;
usecs = ticks * rtems_configuration_get_microseconds_per_tick();
a001dfa4: e59f3038 ldr r3, [pc, #56] ; a001dfe4 <_Timespec_From_ticks+0x40><== NOT EXECUTED
void _Timespec_From_ticks(
uint32_t ticks,
struct timespec *time
)
{
a001dfa8: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
uint32_t usecs;
usecs = ticks * rtems_configuration_get_microseconds_per_tick();
a001dfac: e593500c ldr r5, [r3, #12] <== NOT EXECUTED
void _Timespec_From_ticks(
uint32_t ticks,
struct timespec *time
)
{
a001dfb0: e1a04001 mov r4, r1 <== NOT EXECUTED
uint32_t usecs;
usecs = ticks * rtems_configuration_get_microseconds_per_tick();
time->tv_sec = usecs / TOD_MICROSECONDS_PER_SECOND;
a001dfb4: e59f102c ldr r1, [pc, #44] ; a001dfe8 <_Timespec_From_ticks+0x44><== NOT EXECUTED
struct timespec *time
)
{
uint32_t usecs;
usecs = ticks * rtems_configuration_get_microseconds_per_tick();
a001dfb8: e0050590 mul r5, r0, r5 <== NOT EXECUTED
time->tv_sec = usecs / TOD_MICROSECONDS_PER_SECOND;
a001dfbc: e1a00005 mov r0, r5 <== NOT EXECUTED
a001dfc0: ebfff650 bl a001b908 <__aeabi_uidiv> <== NOT EXECUTED
time->tv_nsec = (usecs % TOD_MICROSECONDS_PER_SECOND) *
a001dfc4: e59f101c ldr r1, [pc, #28] ; a001dfe8 <_Timespec_From_ticks+0x44><== NOT EXECUTED
{
uint32_t usecs;
usecs = ticks * rtems_configuration_get_microseconds_per_tick();
time->tv_sec = usecs / TOD_MICROSECONDS_PER_SECOND;
a001dfc8: e5840000 str r0, [r4] <== NOT EXECUTED
time->tv_nsec = (usecs % TOD_MICROSECONDS_PER_SECOND) *
a001dfcc: e1a00005 mov r0, r5 <== NOT EXECUTED
a001dfd0: ebfff6e4 bl a001bb68 <__umodsi3> <== NOT EXECUTED
a001dfd4: e3a03ffa mov r3, #1000 ; 0x3e8 <== NOT EXECUTED
a001dfd8: e0030390 mul r3, r0, r3 <== NOT EXECUTED
a001dfdc: e5843004 str r3, [r4, #4] <== NOT EXECUTED
TOD_NANOSECONDS_PER_MICROSECOND;
}
a001dfe0: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a001dfec <_Timespec_Is_valid>:
bool _Timespec_Is_valid(
const struct timespec *time
)
{
if ( !time )
a001dfec: e3500000 cmp r0, #0
a001dff0: 012fff1e bxeq lr
return false;
if ( time->tv_sec < 0 )
a001dff4: e5903000 ldr r3, [r0]
a001dff8: e3530000 cmp r3, #0
return false;
a001dffc: b3a00000 movlt r0, #0
)
{
if ( !time )
return false;
if ( time->tv_sec < 0 )
a001e000: b12fff1e bxlt lr
return false;
if ( time->tv_nsec < 0 )
a001e004: e5903004 ldr r3, [r0, #4]
a001e008: e3530000 cmp r3, #0
a001e00c: ba000004 blt a001e024 <_Timespec_Is_valid+0x38>
#include <rtems/system.h>
#include <rtems/score/timespec.h>
#include <rtems/score/tod.h>
bool _Timespec_Is_valid(
a001e010: e59f0014 ldr r0, [pc, #20] ; a001e02c <_Timespec_Is_valid+0x40>
a001e014: e1530000 cmp r3, r0
a001e018: 83a00000 movhi r0, #0
a001e01c: 93a00001 movls r0, #1
a001e020: e12fff1e bx lr
if ( time->tv_sec < 0 )
return false;
if ( time->tv_nsec < 0 )
return false;
a001e024: e3a00000 mov r0, #0 <== NOT EXECUTED
if ( time->tv_nsec >= TOD_NANOSECONDS_PER_SECOND )
return false;
return true;
}
a001e028: e12fff1e bx lr <== NOT EXECUTED
a000f6f4 <_Timespec_Less_than>:
bool _Timespec_Less_than(
const struct timespec *lhs,
const struct timespec *rhs
)
{
if ( lhs->tv_sec < rhs->tv_sec )
a000f6f4: e5902000 ldr r2, [r0]
a000f6f8: e5913000 ldr r3, [r1]
a000f6fc: e1520003 cmp r2, r3
return true;
a000f700: b3a00001 movlt r0, #1
bool _Timespec_Less_than(
const struct timespec *lhs,
const struct timespec *rhs
)
{
if ( lhs->tv_sec < rhs->tv_sec )
a000f704: b12fff1e bxlt lr
return true;
if ( lhs->tv_sec > rhs->tv_sec )
a000f708: ca000005 bgt a000f724 <_Timespec_Less_than+0x30>
#include <rtems/system.h>
#include <rtems/score/timespec.h>
#include <rtems/score/tod.h>
bool _Timespec_Less_than(
a000f70c: e5900004 ldr r0, [r0, #4]
a000f710: e5913004 ldr r3, [r1, #4]
a000f714: e1500003 cmp r0, r3
a000f718: a3a00000 movge r0, #0
a000f71c: b3a00001 movlt r0, #1
a000f720: e12fff1e bx lr
{
if ( lhs->tv_sec < rhs->tv_sec )
return true;
if ( lhs->tv_sec > rhs->tv_sec )
return false;
a000f724: e3a00000 mov r0, #0
/* ASSERT: lhs->tv_sec == rhs->tv_sec */
if ( lhs->tv_nsec < rhs->tv_nsec )
return true;
return false;
}
a000f728: e12fff1e bx lr
a000c34c <_User_extensions_Fatal>:
void _User_extensions_Fatal (
Internal_errors_Source the_source,
bool is_internal,
Internal_errors_t the_error
)
{
a000c34c: e92d41f0 push {r4, r5, r6, r7, r8, lr}
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.fatal != NULL )
(*the_extension->Callouts.fatal)( the_source, is_internal, the_error );
}
}
a000c350: e59f503c ldr r5, [pc, #60] ; a000c394 <_User_extensions_Fatal+0x48>
void _User_extensions_Fatal (
Internal_errors_Source the_source,
bool is_internal,
Internal_errors_t the_error
)
{
a000c354: e1a08000 mov r8, r0
a000c358: e1a07002 mov r7, r2
a000c35c: e20160ff and r6, r1, #255 ; 0xff
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.fatal != NULL )
(*the_extension->Callouts.fatal)( the_source, is_internal, the_error );
}
}
a000c360: e5954008 ldr r4, [r5, #8]
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _Chain_Last( &_User_extensions_List );
a000c364: ea000007 b a000c388 <_User_extensions_Fatal+0x3c>
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.fatal != NULL )
a000c368: e5943030 ldr r3, [r4, #48] ; 0x30
a000c36c: e3530000 cmp r3, #0
a000c370: 0a000003 beq a000c384 <_User_extensions_Fatal+0x38>
(*the_extension->Callouts.fatal)( the_source, is_internal, the_error );
a000c374: e1a00008 mov r0, r8
a000c378: e1a01006 mov r1, r6
a000c37c: e1a02007 mov r2, r7
a000c380: e12fff33 blx r3
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _Chain_Last( &_User_extensions_List );
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
a000c384: e5944004 ldr r4, [r4, #4]
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _Chain_Last( &_User_extensions_List );
a000c388: e1540005 cmp r4, r5
a000c38c: 1afffff5 bne a000c368 <_User_extensions_Fatal+0x1c>
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.fatal != NULL )
(*the_extension->Callouts.fatal)( the_source, is_internal, the_error );
}
}
a000c390: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
a000da78 <_User_extensions_Remove_set>:
#include <rtems/score/userext.h>
void _User_extensions_Remove_set (
User_extensions_Control *the_extension
)
{
a000da78: e92d4010 push {r4, lr}
a000da7c: e1a04000 mov r4, r0
_Chain_Extract( &the_extension->Node );
a000da80: ebfff673 bl a000b454 <_Chain_Extract>
/*
* If a switch handler is present, remove it.
*/
if ( the_extension->Callouts.thread_switch != NULL )
a000da84: e5943024 ldr r3, [r4, #36] ; 0x24
a000da88: e3530000 cmp r3, #0
a000da8c: 0a000002 beq a000da9c <_User_extensions_Remove_set+0x24>
_Chain_Extract( &the_extension->Switch.Node );
a000da90: e2840008 add r0, r4, #8
}
a000da94: e8bd4010 pop {r4, lr}
/*
* If a switch handler is present, remove it.
*/
if ( the_extension->Callouts.thread_switch != NULL )
_Chain_Extract( &the_extension->Switch.Node );
a000da98: eafff66d b a000b454 <_Chain_Extract> <== NOT EXECUTED
a000da9c: e8bd8010 pop {r4, pc}
a000e0c0 <_Watchdog_Adjust>:
void _Watchdog_Adjust(
Chain_Control *header,
Watchdog_Adjust_directions direction,
Watchdog_Interval units
)
{
a000e0c0: e92d41f0 push {r4, r5, r6, r7, r8, lr}
a000e0c4: e1a04000 mov r4, r0
a000e0c8: e1a05002 mov r5, r2
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000e0cc: e10f3000 mrs r3, CPSR
a000e0d0: e3832080 orr r2, r3, #128 ; 0x80
a000e0d4: e129f002 msr CPSR_fc, r2
}
}
_ISR_Enable( level );
}
a000e0d8: e1a06000 mov r6, r0
a000e0dc: e4962004 ldr r2, [r6], #4
* hence the compiler must not assume *header to remain
* unmodified across that call.
*
* Till Straumann, 7/2003
*/
if ( !_Chain_Is_empty( header ) ) {
a000e0e0: e1520006 cmp r2, r6
a000e0e4: 0a00001b beq a000e158 <_Watchdog_Adjust+0x98>
switch ( direction ) {
a000e0e8: e3510000 cmp r1, #0
if ( units < _Watchdog_First( header )->delta_interval ) {
_Watchdog_First( header )->delta_interval -= units;
break;
} else {
units -= _Watchdog_First( header )->delta_interval;
_Watchdog_First( header )->delta_interval = 1;
a000e0ec: 03a08001 moveq r8, #1
* unmodified across that call.
*
* Till Straumann, 7/2003
*/
if ( !_Chain_Is_empty( header ) ) {
switch ( direction ) {
a000e0f0: 0a000016 beq a000e150 <_Watchdog_Adjust+0x90>
a000e0f4: e3510001 cmp r1, #1 <== NOT EXECUTED
a000e0f8: 1a000016 bne a000e158 <_Watchdog_Adjust+0x98> <== NOT EXECUTED
case WATCHDOG_BACKWARD:
_Watchdog_First( header )->delta_interval += units;
a000e0fc: e5921010 ldr r1, [r2, #16] <== NOT EXECUTED
a000e100: e0815005 add r5, r1, r5 <== NOT EXECUTED
a000e104: ea000004 b a000e11c <_Watchdog_Adjust+0x5c> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE Watchdog_Control *_Watchdog_First(
Chain_Control *header
)
{
return ( (Watchdog_Control *) _Chain_First( header ) );
a000e108: e5942000 ldr r2, [r4]
break;
case WATCHDOG_FORWARD:
while ( units ) {
if ( units < _Watchdog_First( header )->delta_interval ) {
a000e10c: e5927010 ldr r7, [r2, #16]
a000e110: e1550007 cmp r5, r7
a000e114: 2a000002 bcs a000e124 <_Watchdog_Adjust+0x64>
_Watchdog_First( header )->delta_interval -= units;
a000e118: e0655007 rsb r5, r5, r7 <== NOT EXECUTED
a000e11c: e5825010 str r5, [r2, #16] <== NOT EXECUTED
break;
a000e120: ea00000c b a000e158 <_Watchdog_Adjust+0x98> <== NOT EXECUTED
} else {
units -= _Watchdog_First( header )->delta_interval;
_Watchdog_First( header )->delta_interval = 1;
a000e124: e5828010 str r8, [r2, #16]
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000e128: e129f003 msr CPSR_fc, r3
_ISR_Enable( level );
_Watchdog_Tickle( header );
a000e12c: e1a00004 mov r0, r4
a000e130: eb00008b bl a000e364 <_Watchdog_Tickle>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000e134: e10f3000 mrs r3, CPSR
a000e138: e3832080 orr r2, r3, #128 ; 0x80
a000e13c: e129f002 msr CPSR_fc, r2
_ISR_Disable( level );
if ( _Chain_Is_empty( header ) )
a000e140: e5942000 ldr r2, [r4]
a000e144: e1520006 cmp r2, r6
a000e148: 0a000002 beq a000e158 <_Watchdog_Adjust+0x98>
while ( units ) {
if ( units < _Watchdog_First( header )->delta_interval ) {
_Watchdog_First( header )->delta_interval -= units;
break;
} else {
units -= _Watchdog_First( header )->delta_interval;
a000e14c: e0675005 rsb r5, r7, r5 <== NOT EXECUTED
switch ( direction ) {
case WATCHDOG_BACKWARD:
_Watchdog_First( header )->delta_interval += units;
break;
case WATCHDOG_FORWARD:
while ( units ) {
a000e150: e3550000 cmp r5, #0
a000e154: 1affffeb bne a000e108 <_Watchdog_Adjust+0x48>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000e158: e129f003 msr CPSR_fc, r3
}
}
_ISR_Enable( level );
}
a000e15c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a001c918 <_Watchdog_Adjust_to_chain>:
{
Watchdog_Interval units = units_arg;
ISR_Level level;
Watchdog_Control *first;
if ( units <= 0 ) {
a001c918: e3510000 cmp r1, #0
Chain_Control *header,
Watchdog_Interval units_arg,
Chain_Control *to_fire
)
{
a001c91c: e92d41f0 push {r4, r5, r6, r7, r8, lr}
Watchdog_Interval units = units_arg;
ISR_Level level;
Watchdog_Control *first;
if ( units <= 0 ) {
a001c920: 0a000026 beq a001c9c0 <_Watchdog_Adjust_to_chain+0xa8>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a001c924: e10f5000 mrs r5, CPSR
a001c928: e3853080 orr r3, r5, #128 ; 0x80
a001c92c: e129f003 msr CPSR_fc, r3
/*
* The first set happens in less than units, so take all of them
* off the chain and adjust units to reflect this.
*/
units -= first->delta_interval;
first->delta_interval = 0;
a001c930: e3a08000 mov r8, #0
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a001c934: e2806004 add r6, r0, #4
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
Chain_Node *tail = _Chain_Tail( the_chain );
a001c938: e2827004 add r7, r2, #4
a001c93c: ea000001 b a001c948 <_Watchdog_Adjust_to_chain+0x30>
}
_ISR_Disable( level );
while ( 1 ) {
if ( units <= 0 ) {
a001c940: e3510000 cmp r1, #0
a001c944: 0a00001c beq a001c9bc <_Watchdog_Adjust_to_chain+0xa4>
break;
}
}
_ISR_Enable( level );
}
a001c948: e590c000 ldr ip, [r0]
while ( 1 ) {
if ( units <= 0 ) {
break;
}
if ( _Chain_Is_empty( header ) ) {
a001c94c: e15c0006 cmp ip, r6
a001c950: 0a000019 beq a001c9bc <_Watchdog_Adjust_to_chain+0xa4>
/*
* If it is longer than "units" until the first element on the chain
* fires, then bump it and quit.
*/
if ( units < first->delta_interval ) {
a001c954: e59c4010 ldr r4, [ip, #16]
a001c958: e1a0300c mov r3, ip
a001c95c: e1510004 cmp r1, r4
first->delta_interval -= units;
a001c960: 30611004 rsbcc r1, r1, r4
a001c964: 358c1010 strcc r1, [ip, #16]
break;
a001c968: 3a000013 bcc a001c9bc <_Watchdog_Adjust_to_chain+0xa4>
/*
* The first set happens in less than units, so take all of them
* off the chain and adjust units to reflect this.
*/
units -= first->delta_interval;
a001c96c: e0641001 rsb r1, r4, r1
first->delta_interval = 0;
a001c970: e58c8010 str r8, [ip, #16]
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
a001c974: e8931010 ldm r3, {r4, ip}
next->previous = previous;
a001c978: e584c004 str ip, [r4, #4]
previous->next = next;
a001c97c: e58c4000 str r4, [ip]
Chain_Control *the_chain,
Chain_Node *the_node
)
{
Chain_Node *tail = _Chain_Tail( the_chain );
Chain_Node *old_last = tail->previous;
a001c980: e592c008 ldr ip, [r2, #8]
the_node->next = tail;
a001c984: e5837000 str r7, [r3]
tail->previous = the_node;
a001c988: e5823008 str r3, [r2, #8]
old_last->next = the_node;
a001c98c: e58c3000 str r3, [ip]
the_node->previous = old_last;
a001c990: e583c004 str ip, [r3, #4]
static inline void arm_interrupt_flash( uint32_t level )
{
uint32_t arm_switch_reg;
asm volatile (
a001c994: e10f3000 mrs r3, CPSR
a001c998: e129f005 msr CPSR_fc, r5
a001c99c: e129f003 msr CPSR_fc, r3
break;
}
}
_ISR_Enable( level );
}
a001c9a0: e5903000 ldr r3, [r0]
_Chain_Extract_unprotected( &first->Node );
_Chain_Append_unprotected( to_fire, &first->Node );
_ISR_Flash( level );
if ( _Chain_Is_empty( header ) )
a001c9a4: e1530006 cmp r3, r6
a001c9a8: 0affffe4 beq a001c940 <_Watchdog_Adjust_to_chain+0x28>
break;
first = _Watchdog_First( header );
if ( first->delta_interval != 0 )
a001c9ac: e593c010 ldr ip, [r3, #16] <== NOT EXECUTED
a001c9b0: e35c0000 cmp ip, #0 <== NOT EXECUTED
a001c9b4: 0affffee beq a001c974 <_Watchdog_Adjust_to_chain+0x5c> <== NOT EXECUTED
a001c9b8: eaffffe0 b a001c940 <_Watchdog_Adjust_to_chain+0x28> <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a001c9bc: e129f005 msr CPSR_fc, r5
a001c9c0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a000c4b8 <_Watchdog_Insert>:
Watchdog_Control *after;
uint32_t insert_isr_nest_level;
Watchdog_Interval delta_interval;
insert_isr_nest_level = _ISR_Nest_level;
a000c4b8: e59f30f4 ldr r3, [pc, #244] ; a000c5b4 <_Watchdog_Insert+0xfc>
void _Watchdog_Insert(
Chain_Control *header,
Watchdog_Control *the_watchdog
)
{
a000c4bc: e92d41f0 push {r4, r5, r6, r7, r8, lr}
Watchdog_Control *after;
uint32_t insert_isr_nest_level;
Watchdog_Interval delta_interval;
insert_isr_nest_level = _ISR_Nest_level;
a000c4c0: e5934000 ldr r4, [r3]
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000c4c4: e10fc000 mrs ip, CPSR
a000c4c8: e38c3080 orr r3, ip, #128 ; 0x80
a000c4cc: e129f003 msr CPSR_fc, r3
/*
* Check to see if the watchdog has just been inserted by a
* higher priority interrupt. If so, abandon this insert.
*/
if ( the_watchdog->state != WATCHDOG_INACTIVE ) {
a000c4d0: e5913008 ldr r3, [r1, #8]
a000c4d4: e3530000 cmp r3, #0
a000c4d8: 0a000000 beq a000c4e0 <_Watchdog_Insert+0x28>
_ISR_Enable( level );
a000c4dc: ea000032 b a000c5ac <_Watchdog_Insert+0xf4> <== NOT EXECUTED
return;
}
the_watchdog->state = WATCHDOG_BEING_INSERTED;
a000c4e0: e3a03001 mov r3, #1
a000c4e4: e5813008 str r3, [r1, #8]
_Watchdog_Sync_count++;
a000c4e8: e59f30c8 ldr r3, [pc, #200] ; a000c5b8 <_Watchdog_Insert+0x100>
if ( the_watchdog->state != WATCHDOG_BEING_INSERTED ) {
goto exit_insert;
}
if ( _Watchdog_Sync_level > insert_isr_nest_level ) {
a000c4ec: e59f60c8 ldr r6, [pc, #200] ; a000c5bc <_Watchdog_Insert+0x104>
_ISR_Enable( level );
return;
}
the_watchdog->state = WATCHDOG_BEING_INSERTED;
_Watchdog_Sync_count++;
a000c4f0: e5932000 ldr r2, [r3]
if ( the_watchdog->state != WATCHDOG_BEING_INSERTED ) {
goto exit_insert;
}
if ( _Watchdog_Sync_level > insert_isr_nest_level ) {
a000c4f4: e1a07006 mov r7, r6
_ISR_Enable( level );
return;
}
the_watchdog->state = WATCHDOG_BEING_INSERTED;
_Watchdog_Sync_count++;
a000c4f8: e2822001 add r2, r2, #1
a000c4fc: e5832000 str r2, [r3]
restart:
delta_interval = the_watchdog->initial;
a000c500: e591200c ldr r2, [r1, #12]
RTEMS_INLINE_ROUTINE Watchdog_Control *_Watchdog_First(
Chain_Control *header
)
{
return ( (Watchdog_Control *) _Chain_First( header ) );
a000c504: e5903000 ldr r3, [r0]
for ( after = _Watchdog_First( header ) ;
;
after = _Watchdog_Next( after ) ) {
if ( delta_interval == 0 || !_Watchdog_Next( after ) )
a000c508: e3520000 cmp r2, #0
a000c50c: 0a000014 beq a000c564 <_Watchdog_Insert+0xac>
a000c510: e5935000 ldr r5, [r3]
a000c514: e3550000 cmp r5, #0
a000c518: 0a000011 beq a000c564 <_Watchdog_Insert+0xac>
break;
if ( delta_interval < after->delta_interval ) {
a000c51c: e5935010 ldr r5, [r3, #16]
a000c520: e1520005 cmp r2, r5
after->delta_interval -= delta_interval;
a000c524: 30625005 rsbcc r5, r2, r5
a000c528: 35835010 strcc r5, [r3, #16]
break;
a000c52c: 3a00000c bcc a000c564 <_Watchdog_Insert+0xac>
static inline void arm_interrupt_flash( uint32_t level )
{
uint32_t arm_switch_reg;
asm volatile (
a000c530: e10f8000 mrs r8, CPSR
a000c534: e129f00c msr CPSR_fc, ip
a000c538: e129f008 msr CPSR_fc, r8
delta_interval -= after->delta_interval;
_ISR_Flash( level );
if ( the_watchdog->state != WATCHDOG_BEING_INSERTED ) {
a000c53c: e5918008 ldr r8, [r1, #8]
a000c540: e3580001 cmp r8, #1
a000c544: 1a000012 bne a000c594 <_Watchdog_Insert+0xdc>
goto exit_insert;
}
if ( _Watchdog_Sync_level > insert_isr_nest_level ) {
a000c548: e5968000 ldr r8, [r6]
a000c54c: e1580004 cmp r8, r4
_Watchdog_Sync_level = insert_isr_nest_level;
a000c550: 85874000 strhi r4, [r7]
goto restart;
a000c554: 8affffe9 bhi a000c500 <_Watchdog_Insert+0x48>
if ( delta_interval < after->delta_interval ) {
after->delta_interval -= delta_interval;
break;
}
delta_interval -= after->delta_interval;
a000c558: e0652002 rsb r2, r5, r2
exit_insert:
_Watchdog_Sync_level = insert_isr_nest_level;
_Watchdog_Sync_count--;
_ISR_Enable( level );
}
a000c55c: e5933000 ldr r3, [r3]
if ( _Watchdog_Sync_level > insert_isr_nest_level ) {
_Watchdog_Sync_level = insert_isr_nest_level;
goto restart;
}
}
a000c560: eaffffe8 b a000c508 <_Watchdog_Insert+0x50>
_Watchdog_Activate( the_watchdog );
the_watchdog->delta_interval = delta_interval;
_Chain_Insert_unprotected( after->Node.previous, &the_watchdog->Node );
a000c564: e5933004 ldr r3, [r3, #4]
RTEMS_INLINE_ROUTINE void _Watchdog_Activate(
Watchdog_Control *the_watchdog
)
{
the_watchdog->state = WATCHDOG_ACTIVE;
a000c568: e3a00002 mov r0, #2
}
}
_Watchdog_Activate( the_watchdog );
the_watchdog->delta_interval = delta_interval;
a000c56c: e5812010 str r2, [r1, #16]
a000c570: e5810008 str r0, [r1, #8]
)
{
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
a000c574: e5932000 ldr r2, [r3]
Chain_Node *the_node
)
{
Chain_Node *before_node;
the_node->previous = after_node;
a000c578: e5813004 str r3, [r1, #4]
before_node = after_node->next;
after_node->next = the_node;
a000c57c: e5831000 str r1, [r3]
_Chain_Insert_unprotected( after->Node.previous, &the_watchdog->Node );
the_watchdog->start_time = _Watchdog_Ticks_since_boot;
a000c580: e59f3038 ldr r3, [pc, #56] ; a000c5c0 <_Watchdog_Insert+0x108>
the_node->next = before_node;
before_node->previous = the_node;
a000c584: e5821004 str r1, [r2, #4]
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
after_node->next = the_node;
the_node->next = before_node;
a000c588: e5812000 str r2, [r1]
a000c58c: e5933000 ldr r3, [r3]
a000c590: e5813014 str r3, [r1, #20]
exit_insert:
_Watchdog_Sync_level = insert_isr_nest_level;
a000c594: e59f3020 ldr r3, [pc, #32] ; a000c5bc <_Watchdog_Insert+0x104>
a000c598: e5834000 str r4, [r3]
_Watchdog_Sync_count--;
a000c59c: e59f3014 ldr r3, [pc, #20] ; a000c5b8 <_Watchdog_Insert+0x100>
a000c5a0: e5932000 ldr r2, [r3]
a000c5a4: e2422001 sub r2, r2, #1
a000c5a8: e5832000 str r2, [r3]
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000c5ac: e129f00c msr CPSR_fc, ip
a000c5b0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a000dbb8 <_Watchdog_Report>:
void _Watchdog_Report(
const char *name,
Watchdog_Control *watch
)
{
a000dbb8: e92d401f push {r0, r1, r2, r3, r4, lr} <== NOT EXECUTED
a000dbbc: e1a03001 mov r3, r1 <== NOT EXECUTED
printk(
a000dbc0: e2501000 subs r1, r0, #0 <== NOT EXECUTED
a000dbc4: e593000c ldr r0, [r3, #12] <== NOT EXECUTED
a000dbc8: e58d3004 str r3, [sp, #4] <== NOT EXECUTED
a000dbcc: 059f1034 ldreq r1, [pc, #52] ; a000dc08 <_Watchdog_Report+0x50><== NOT EXECUTED
a000dbd0: e58d0000 str r0, [sp] <== NOT EXECUTED
a000dbd4: e593001c ldr r0, [r3, #28] <== NOT EXECUTED
a000dbd8: 01a02001 moveq r2, r1 <== NOT EXECUTED
a000dbdc: 159f2028 ldrne r2, [pc, #40] ; a000dc0c <_Watchdog_Report+0x54><== NOT EXECUTED
a000dbe0: e58d0008 str r0, [sp, #8] <== NOT EXECUTED
a000dbe4: e5930020 ldr r0, [r3, #32] <== NOT EXECUTED
a000dbe8: e58d000c str r0, [sp, #12] <== NOT EXECUTED
a000dbec: e5930024 ldr r0, [r3, #36] ; 0x24 <== NOT EXECUTED
a000dbf0: e58d0010 str r0, [sp, #16] <== NOT EXECUTED
a000dbf4: e5933010 ldr r3, [r3, #16] <== NOT EXECUTED
a000dbf8: e59f0010 ldr r0, [pc, #16] ; a000dc10 <_Watchdog_Report+0x58><== NOT EXECUTED
a000dbfc: ebffe834 bl a0007cd4 <printk> <== NOT EXECUTED
watch,
watch->routine,
watch->id,
watch->user_data
);
}
a000dc00: e28dd014 add sp, sp, #20 <== NOT EXECUTED
a000dc04: e8bd8000 pop {pc} <== NOT EXECUTED
a000db40 <_Watchdog_Report_chain>:
void _Watchdog_Report_chain(
const char *name,
Chain_Control *header
)
{
a000db40: e92d40f0 push {r4, r5, r6, r7, lr}
a000db44: e1a04000 mov r4, r0
a000db48: e1a05001 mov r5, r1
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000db4c: e10f6000 mrs r6, CPSR
a000db50: e3863080 orr r3, r6, #128 ; 0x80
a000db54: e129f003 msr CPSR_fc, r3
ISR_Level level;
Chain_Node *node;
_ISR_Disable( level );
printk( "Watchdog Chain: %s %p\n", name, header );
a000db58: e59f004c ldr r0, [pc, #76] ; a000dbac <_Watchdog_Report_chain+0x6c>
a000db5c: e1a02005 mov r2, r5
a000db60: e1a01004 mov r1, r4
a000db64: ebffe85a bl a0007cd4 <printk>
printk( "== end of %s \n", name );
} else {
printk( "Chain is empty\n" );
}
_ISR_Enable( level );
}
a000db68: e4957004 ldr r7, [r5], #4
ISR_Level level;
Chain_Node *node;
_ISR_Disable( level );
printk( "Watchdog Chain: %s %p\n", name, header );
if ( !_Chain_Is_empty( header ) ) {
a000db6c: e1570005 cmp r7, r5
a000db70: 0a000009 beq a000db9c <_Watchdog_Report_chain+0x5c>
node != _Chain_Tail(header) ;
node = node->next )
{
Watchdog_Control *watch = (Watchdog_Control *) node;
_Watchdog_Report( NULL, watch );
a000db74: e1a01007 mov r1, r7 <== NOT EXECUTED
a000db78: e3a00000 mov r0, #0 <== NOT EXECUTED
a000db7c: eb00000d bl a000dbb8 <_Watchdog_Report> <== NOT EXECUTED
_ISR_Disable( level );
printk( "Watchdog Chain: %s %p\n", name, header );
if ( !_Chain_Is_empty( header ) ) {
for ( node = _Chain_First( header ) ;
node != _Chain_Tail(header) ;
node = node->next )
a000db80: e5977000 ldr r7, [r7] <== NOT EXECUTED
Chain_Node *node;
_ISR_Disable( level );
printk( "Watchdog Chain: %s %p\n", name, header );
if ( !_Chain_Is_empty( header ) ) {
for ( node = _Chain_First( header ) ;
a000db84: e1570005 cmp r7, r5 <== NOT EXECUTED
a000db88: 1afffff9 bne a000db74 <_Watchdog_Report_chain+0x34> <== NOT EXECUTED
{
Watchdog_Control *watch = (Watchdog_Control *) node;
_Watchdog_Report( NULL, watch );
}
printk( "== end of %s \n", name );
a000db8c: e59f001c ldr r0, [pc, #28] ; a000dbb0 <_Watchdog_Report_chain+0x70><== NOT EXECUTED
a000db90: e1a01004 mov r1, r4 <== NOT EXECUTED
a000db94: ebffe84e bl a0007cd4 <printk> <== NOT EXECUTED
a000db98: ea000001 b a000dba4 <_Watchdog_Report_chain+0x64> <== NOT EXECUTED
} else {
printk( "Chain is empty\n" );
a000db9c: e59f0010 ldr r0, [pc, #16] ; a000dbb4 <_Watchdog_Report_chain+0x74>
a000dba0: ebffe84b bl a0007cd4 <printk>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000dba4: e129f006 msr CPSR_fc, r6
}
_ISR_Enable( level );
}
a000dba8: e8bd80f0 pop {r4, r5, r6, r7, pc}
a000c6bc <_Watchdog_Tickle>:
*/
void _Watchdog_Tickle(
Chain_Control *header
)
{
a000c6bc: e92d40f0 push {r4, r5, r6, r7, lr}
a000c6c0: e1a05000 mov r5, r0
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000c6c4: e10f7000 mrs r7, CPSR
a000c6c8: e3873080 orr r3, r7, #128 ; 0x80
a000c6cc: e129f003 msr CPSR_fc, r3
} while ( !_Chain_Is_empty( header ) &&
(the_watchdog->delta_interval == 0) );
leave:
_ISR_Enable(level);
}
a000c6d0: e1a04000 mov r4, r0
a000c6d4: e4943004 ldr r3, [r4], #4
* volatile data - till, 2003/7
*/
_ISR_Disable( level );
if ( _Chain_Is_empty( header ) )
a000c6d8: e1530004 cmp r3, r4
a000c6dc: 0a000019 beq a000c748 <_Watchdog_Tickle+0x8c>
* to be inserted has already had its delta_interval adjusted to 0, and
* so is added to the head of the chain with a delta_interval of 0.
*
* Steven Johnson - 12/2005 (gcc-3.2.3 -O3 on powerpc)
*/
if (the_watchdog->delta_interval != 0) {
a000c6e0: e5932010 ldr r2, [r3, #16]
RTEMS_INLINE_ROUTINE Watchdog_Control *_Watchdog_First(
Chain_Control *header
)
{
return ( (Watchdog_Control *) _Chain_First( header ) );
a000c6e4: e1a06003 mov r6, r3
a000c6e8: e3520000 cmp r2, #0
a000c6ec: 0a000003 beq a000c700 <_Watchdog_Tickle+0x44>
the_watchdog->delta_interval--;
a000c6f0: e2422001 sub r2, r2, #1
a000c6f4: e5832010 str r2, [r3, #16]
if ( the_watchdog->delta_interval != 0 )
a000c6f8: e3520000 cmp r2, #0
a000c6fc: 1a000011 bne a000c748 <_Watchdog_Tickle+0x8c>
goto leave;
}
do {
watchdog_state = _Watchdog_Remove( the_watchdog );
a000c700: e1a00006 mov r0, r6
a000c704: ebffffc3 bl a000c618 <_Watchdog_Remove>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000c708: e129f007 msr CPSR_fc, r7
_ISR_Enable( level );
switch( watchdog_state ) {
a000c70c: e3500002 cmp r0, #2
a000c710: 1a000003 bne a000c724 <_Watchdog_Tickle+0x68>
case WATCHDOG_ACTIVE:
(*the_watchdog->routine)(
a000c714: e596301c ldr r3, [r6, #28]
a000c718: e5960020 ldr r0, [r6, #32]
a000c71c: e5961024 ldr r1, [r6, #36] ; 0x24
a000c720: e12fff33 blx r3
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000c724: e10f7000 mrs r7, CPSR
a000c728: e3873080 orr r3, r7, #128 ; 0x80
a000c72c: e129f003 msr CPSR_fc, r3
} while ( !_Chain_Is_empty( header ) &&
(the_watchdog->delta_interval == 0) );
leave:
_ISR_Enable(level);
}
a000c730: e5956000 ldr r6, [r5]
_ISR_Disable( level );
the_watchdog = _Watchdog_First( header );
} while ( !_Chain_Is_empty( header ) &&
(the_watchdog->delta_interval == 0) );
a000c734: e1560004 cmp r6, r4
a000c738: 0a000002 beq a000c748 <_Watchdog_Tickle+0x8c>
}
_ISR_Disable( level );
the_watchdog = _Watchdog_First( header );
} while ( !_Chain_Is_empty( header ) &&
a000c73c: e5963010 ldr r3, [r6, #16] <== NOT EXECUTED
a000c740: e3530000 cmp r3, #0 <== NOT EXECUTED
a000c744: eaffffec b a000c6fc <_Watchdog_Tickle+0x40> <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000c748: e129f007 msr CPSR_fc, r7
(the_watchdog->delta_interval == 0) );
leave:
_ISR_Enable(level);
}
a000c74c: e8bd80f0 pop {r4, r5, r6, r7, pc}
a000959c <adjtime>:
int adjtime(
struct timeval *delta,
struct timeval *olddelta
)
{
a000959c: e92d4033 push {r0, r1, r4, r5, lr}
long adjustment;
/*
* Simple validations
*/
if ( !delta )
a00095a0: e2505000 subs r5, r0, #0
int adjtime(
struct timeval *delta,
struct timeval *olddelta
)
{
a00095a4: e1a04001 mov r4, r1
long adjustment;
/*
* Simple validations
*/
if ( !delta )
a00095a8: 0a000003 beq a00095bc <adjtime+0x20>
rtems_set_errno_and_return_minus_one( EINVAL );
if ( delta->tv_usec >= TOD_MICROSECONDS_PER_SECOND )
a00095ac: e5952004 ldr r2, [r5, #4]
a00095b0: e59f30f0 ldr r3, [pc, #240] ; a00096a8 <adjtime+0x10c>
a00095b4: e1520003 cmp r2, r3
a00095b8: 9a000004 bls a00095d0 <adjtime+0x34>
rtems_set_errno_and_return_minus_one( EINVAL );
a00095bc: eb0021eb bl a0011d70 <__errno>
a00095c0: e3a03016 mov r3, #22
a00095c4: e5803000 str r3, [r0]
a00095c8: e3e00000 mvn r0, #0
a00095cc: ea000034 b a00096a4 <adjtime+0x108>
if ( olddelta ) {
a00095d0: e3510000 cmp r1, #0 <== NOT EXECUTED
olddelta->tv_sec = 0;
a00095d4: 13a03000 movne r3, #0 <== NOT EXECUTED
a00095d8: 15813000 strne r3, [r1] <== NOT EXECUTED
olddelta->tv_usec = 0;
a00095dc: 15813004 strne r3, [r1, #4] <== NOT EXECUTED
}
/* convert delta to microseconds */
adjustment = (delta->tv_sec * TOD_MICROSECONDS_PER_SECOND);
adjustment += delta->tv_usec;
a00095e0: e895000c ldm r5, {r2, r3} <== NOT EXECUTED
a00095e4: e59f10c0 ldr r1, [pc, #192] ; a00096ac <adjtime+0x110> <== NOT EXECUTED
a00095e8: e0223291 mla r2, r1, r2, r3 <== NOT EXECUTED
/* too small to account for */
if ( adjustment < rtems_configuration_get_microseconds_per_tick() )
a00095ec: e59f30bc ldr r3, [pc, #188] ; a00096b0 <adjtime+0x114> <== NOT EXECUTED
a00095f0: e593300c ldr r3, [r3, #12] <== NOT EXECUTED
a00095f4: e1520003 cmp r2, r3 <== NOT EXECUTED
a00095f8: 3a000028 bcc a00096a0 <adjtime+0x104> <== NOT EXECUTED
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a00095fc: e59f30b0 ldr r3, [pc, #176] ; a00096b4 <adjtime+0x118> <== NOT EXECUTED
a0009600: e5932000 ldr r2, [r3] <== NOT EXECUTED
a0009604: e2822001 add r2, r2, #1 <== NOT EXECUTED
a0009608: e5832000 str r2, [r3] <== NOT EXECUTED
* This prevents context switches while we are adjusting the TOD
*/
_Thread_Disable_dispatch();
_TOD_Get( &ts );
a000960c: e1a0000d mov r0, sp <== NOT EXECUTED
a0009610: eb0005a6 bl a000acb0 <_TOD_Get> <== NOT EXECUTED
ts.tv_sec += delta->tv_sec;
a0009614: e5953000 ldr r3, [r5] <== NOT EXECUTED
a0009618: e89d0006 ldm sp, {r1, r2} <== NOT EXECUTED
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
a000961c: e3a00ffa mov r0, #1000 ; 0x3e8 <== NOT EXECUTED
_Thread_Disable_dispatch();
_TOD_Get( &ts );
ts.tv_sec += delta->tv_sec;
a0009620: e0811003 add r1, r1, r3 <== NOT EXECUTED
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
a0009624: e5953004 ldr r3, [r5, #4] <== NOT EXECUTED
a0009628: e0232390 mla r3, r0, r3, r2 <== NOT EXECUTED
/* if adjustment is too much positive */
while ( ts.tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
a000962c: e59f0084 ldr r0, [pc, #132] ; a00096b8 <adjtime+0x11c> <== NOT EXECUTED
a0009630: ea000002 b a0009640 <adjtime+0xa4> <== NOT EXECUTED
a0009634: e2833331 add r3, r3, #-1006632960 ; 0xc4000000 <== NOT EXECUTED
a0009638: e2833865 add r3, r3, #6619136 ; 0x650000 <== NOT EXECUTED
a000963c: e2833c36 add r3, r3, #13824 ; 0x3600 <== NOT EXECUTED
a0009640: e1530000 cmp r3, r0 <== NOT EXECUTED
a0009644: e1a02001 mov r2, r1 <== NOT EXECUTED
a0009648: e2811001 add r1, r1, #1 <== NOT EXECUTED
a000964c: 8afffff8 bhi a0009634 <adjtime+0x98> <== NOT EXECUTED
ts.tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec++;
}
/* if adjustment is too much negative */
while ( ts.tv_nsec <= (-1 * TOD_NANOSECONDS_PER_SECOND) ) {
a0009650: e59f0064 ldr r0, [pc, #100] ; a00096bc <adjtime+0x120> <== NOT EXECUTED
a0009654: ea000002 b a0009664 <adjtime+0xc8> <== NOT EXECUTED
ts.tv_sec += delta->tv_sec;
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
/* if adjustment is too much positive */
while ( ts.tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
a0009658: e28335ee add r3, r3, #998244352 ; 0x3b800000 <== NOT EXECUTED
a000965c: e283396b add r3, r3, #1753088 ; 0x1ac000 <== NOT EXECUTED
a0009660: e2833c0a add r3, r3, #2560 ; 0xa00 <== NOT EXECUTED
ts.tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec++;
}
/* if adjustment is too much negative */
while ( ts.tv_nsec <= (-1 * TOD_NANOSECONDS_PER_SECOND) ) {
a0009664: e1530000 cmp r3, r0 <== NOT EXECUTED
ts.tv_sec += delta->tv_sec;
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
/* if adjustment is too much positive */
while ( ts.tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
a0009668: e1a01002 mov r1, r2 <== NOT EXECUTED
a000966c: e2422001 sub r2, r2, #1 <== NOT EXECUTED
ts.tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec++;
}
/* if adjustment is too much negative */
while ( ts.tv_nsec <= (-1 * TOD_NANOSECONDS_PER_SECOND) ) {
a0009670: 9afffff8 bls a0009658 <adjtime+0xbc> <== NOT EXECUTED
a0009674: e28d0008 add r0, sp, #8 <== NOT EXECUTED
a0009678: e5201008 str r1, [r0, #-8]! <== NOT EXECUTED
ts.tv_nsec += TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec--;
}
_TOD_Set( &ts );
a000967c: e1a0000d mov r0, sp <== NOT EXECUTED
ts.tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec++;
}
/* if adjustment is too much negative */
while ( ts.tv_nsec <= (-1 * TOD_NANOSECONDS_PER_SECOND) ) {
a0009680: e58d3004 str r3, [sp, #4] <== NOT EXECUTED
ts.tv_nsec += TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec--;
}
_TOD_Set( &ts );
a0009684: eb0005af bl a000ad48 <_TOD_Set> <== NOT EXECUTED
_Thread_Enable_dispatch();
a0009688: eb000ad6 bl a000c1e8 <_Thread_Enable_dispatch> <== NOT EXECUTED
/* set the user's output */
if ( olddelta )
a000968c: e3540000 cmp r4, #0 <== NOT EXECUTED
*olddelta = *delta;
return 0;
a0009690: 01a00004 moveq r0, r4 <== NOT EXECUTED
_TOD_Set( &ts );
_Thread_Enable_dispatch();
/* set the user's output */
if ( olddelta )
a0009694: 0a000002 beq a00096a4 <adjtime+0x108> <== NOT EXECUTED
*olddelta = *delta;
a0009698: e895000c ldm r5, {r2, r3} <== NOT EXECUTED
a000969c: e884000c stm r4, {r2, r3} <== NOT EXECUTED
adjustment = (delta->tv_sec * TOD_MICROSECONDS_PER_SECOND);
adjustment += delta->tv_usec;
/* too small to account for */
if ( adjustment < rtems_configuration_get_microseconds_per_tick() )
return 0;
a00096a0: e3a00000 mov r0, #0 <== NOT EXECUTED
/* set the user's output */
if ( olddelta )
*olddelta = *delta;
return 0;
}
a00096a4: e8bd803c pop {r2, r3, r4, r5, pc}
a0009cec <aio_cancel>:
* operation(s) cannot be canceled
*/
int aio_cancel(int fildes, struct aiocb *aiocbp)
{
a0009cec: e92d41f0 push {r4, r5, r6, r7, r8, lr}
rtems_aio_request_chain *r_chain;
int result;
pthread_mutex_lock (&aio_request_queue.mutex);
a0009cf0: e59f4198 ldr r4, [pc, #408] ; a0009e90 <aio_cancel+0x1a4>
* operation(s) cannot be canceled
*/
int aio_cancel(int fildes, struct aiocb *aiocbp)
{
a0009cf4: e1a07000 mov r7, r0
a0009cf8: e1a05001 mov r5, r1
rtems_aio_request_chain *r_chain;
int result;
pthread_mutex_lock (&aio_request_queue.mutex);
a0009cfc: e1a00004 mov r0, r4
a0009d00: eb00041f bl a000ad84 <pthread_mutex_lock>
if (fcntl (fildes, F_GETFD) < 0) {
a0009d04: e1a00007 mov r0, r7
a0009d08: e3a01001 mov r1, #1
a0009d0c: eb001a2c bl a00105c4 <fcntl>
a0009d10: e3500000 cmp r0, #0
a0009d14: aa000004 bge a0009d2c <aio_cancel+0x40>
pthread_mutex_unlock(&aio_request_queue.mutex);
a0009d18: e1a00004 mov r0, r4
a0009d1c: eb000437 bl a000ae00 <pthread_mutex_unlock>
rtems_set_errno_and_return_minus_one (EBADF);
a0009d20: eb002751 bl a0013a6c <__errno>
a0009d24: e3a03009 mov r3, #9
a0009d28: ea00002f b a0009dec <aio_cancel+0x100>
}
/* if aiocbp is NULL remove all request for given file descriptor */
if (aiocbp == NULL) {
a0009d2c: e3550000 cmp r5, #0 <== NOT EXECUTED
a0009d30: 1a000026 bne a0009dd0 <aio_cancel+0xe4> <== NOT EXECUTED
AIO_printf ("Cancel all requests\n");
r_chain = rtems_aio_search_fd (&aio_request_queue.work_req, fildes, 0);
a0009d34: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED
a0009d38: e1a01007 mov r1, r7 <== NOT EXECUTED
a0009d3c: e1a02005 mov r2, r5 <== NOT EXECUTED
a0009d40: eb0000a5 bl a0009fdc <rtems_aio_search_fd> <== NOT EXECUTED
if (r_chain == NULL) {
a0009d44: e2506000 subs r6, r0, #0 <== NOT EXECUTED
a0009d48: 1a000017 bne a0009dac <aio_cancel+0xc0> <== NOT EXECUTED
AIO_printf ("Request chain not on [WQ]\n");
if (!rtems_chain_is_empty (&aio_request_queue.idle_req)) {
a0009d4c: e5942054 ldr r2, [r4, #84] ; 0x54 <== NOT EXECUTED
a0009d50: e2843058 add r3, r4, #88 ; 0x58 <== NOT EXECUTED
a0009d54: e1520003 cmp r2, r3 <== NOT EXECUTED
a0009d58: 0a00003b beq a0009e4c <aio_cancel+0x160> <== NOT EXECUTED
r_chain = rtems_aio_search_fd (&aio_request_queue.idle_req, fildes, 0);
a0009d5c: e2840054 add r0, r4, #84 ; 0x54 <== NOT EXECUTED
a0009d60: e1a01007 mov r1, r7 <== NOT EXECUTED
a0009d64: e1a02006 mov r2, r6 <== NOT EXECUTED
a0009d68: eb00009b bl a0009fdc <rtems_aio_search_fd> <== NOT EXECUTED
if (r_chain == NULL) {
a0009d6c: e2505000 subs r5, r0, #0 <== NOT EXECUTED
a0009d70: 0a000035 beq a0009e4c <aio_cancel+0x160> <== NOT EXECUTED
AIO_printf ("Request chain on [IQ]\n");
rtems_chain_extract (&r_chain->next_fd);
rtems_aio_remove_fd (r_chain);
pthread_mutex_destroy (&r_chain->mutex);
a0009d74: e285701c add r7, r5, #28 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
a0009d78: eb000a1e bl a000c5f8 <_Chain_Extract> <== NOT EXECUTED
}
AIO_printf ("Request chain on [IQ]\n");
rtems_chain_extract (&r_chain->next_fd);
rtems_aio_remove_fd (r_chain);
a0009d7c: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009d80: eb000175 bl a000a35c <rtems_aio_remove_fd> <== NOT EXECUTED
pthread_mutex_destroy (&r_chain->mutex);
a0009d84: e1a00007 mov r0, r7 <== NOT EXECUTED
a0009d88: eb00035a bl a000aaf8 <pthread_mutex_destroy> <== NOT EXECUTED
pthread_cond_destroy (&r_chain->mutex);
a0009d8c: e1a00007 mov r0, r7 <== NOT EXECUTED
a0009d90: eb000289 bl a000a7bc <pthread_cond_destroy> <== NOT EXECUTED
free (r_chain);
a0009d94: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009d98: ebfff40f bl a0006ddc <free> <== NOT EXECUTED
pthread_mutex_unlock (&aio_request_queue.mutex);
a0009d9c: e1a00004 mov r0, r4 <== NOT EXECUTED
a0009da0: eb000416 bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
return AIO_CANCELED;
a0009da4: e1a05006 mov r5, r6 <== NOT EXECUTED
a0009da8: ea000036 b a0009e88 <aio_cancel+0x19c> <== NOT EXECUTED
return AIO_ALLDONE;
}
AIO_printf ("Request chain on [WQ]\n");
pthread_mutex_lock (&r_chain->mutex);
a0009dac: e286701c add r7, r6, #28 <== NOT EXECUTED
a0009db0: e1a00007 mov r0, r7 <== NOT EXECUTED
a0009db4: eb0003f2 bl a000ad84 <pthread_mutex_lock> <== NOT EXECUTED
a0009db8: e1a00006 mov r0, r6 <== NOT EXECUTED
a0009dbc: eb000a0d bl a000c5f8 <_Chain_Extract> <== NOT EXECUTED
rtems_chain_extract (&r_chain->next_fd);
rtems_aio_remove_fd (r_chain);
a0009dc0: e1a00006 mov r0, r6 <== NOT EXECUTED
a0009dc4: eb000164 bl a000a35c <rtems_aio_remove_fd> <== NOT EXECUTED
pthread_mutex_unlock (&r_chain->mutex);
a0009dc8: e1a00007 mov r0, r7 <== NOT EXECUTED
a0009dcc: ea00002a b a0009e7c <aio_cancel+0x190> <== NOT EXECUTED
pthread_mutex_unlock (&aio_request_queue.mutex);
return AIO_CANCELED;
} else {
AIO_printf ("Cancel request\n");
if (aiocbp->aio_fildes != fildes) {
a0009dd0: e5956000 ldr r6, [r5] <== NOT EXECUTED
a0009dd4: e1560007 cmp r6, r7 <== NOT EXECUTED
a0009dd8: 0a000006 beq a0009df8 <aio_cancel+0x10c> <== NOT EXECUTED
pthread_mutex_unlock (&aio_request_queue.mutex);
a0009ddc: e1a00004 mov r0, r4 <== NOT EXECUTED
a0009de0: eb000406 bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one (EINVAL);
a0009de4: eb002720 bl a0013a6c <__errno> <== NOT EXECUTED
a0009de8: e3a03016 mov r3, #22 <== NOT EXECUTED
a0009dec: e5803000 str r3, [r0]
a0009df0: e3e05000 mvn r5, #0
a0009df4: ea000023 b a0009e88 <aio_cancel+0x19c>
}
r_chain = rtems_aio_search_fd (&aio_request_queue.work_req, fildes, 0);
a0009df8: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED
a0009dfc: e1a01006 mov r1, r6 <== NOT EXECUTED
a0009e00: e3a02000 mov r2, #0 <== NOT EXECUTED
a0009e04: eb000074 bl a0009fdc <rtems_aio_search_fd> <== NOT EXECUTED
if (r_chain == NULL) {
a0009e08: e2507000 subs r7, r0, #0 <== NOT EXECUTED
a0009e0c: 1a000012 bne a0009e5c <aio_cancel+0x170> <== NOT EXECUTED
if (!rtems_chain_is_empty (&aio_request_queue.idle_req)) {
a0009e10: e5942054 ldr r2, [r4, #84] ; 0x54 <== NOT EXECUTED
a0009e14: e2843058 add r3, r4, #88 ; 0x58 <== NOT EXECUTED
a0009e18: e1520003 cmp r2, r3 <== NOT EXECUTED
a0009e1c: 0a00000a beq a0009e4c <aio_cancel+0x160> <== NOT EXECUTED
r_chain = rtems_aio_search_fd (&aio_request_queue.idle_req, fildes, 0);
a0009e20: e2840054 add r0, r4, #84 ; 0x54 <== NOT EXECUTED
a0009e24: e1a01006 mov r1, r6 <== NOT EXECUTED
a0009e28: e1a02007 mov r2, r7 <== NOT EXECUTED
a0009e2c: eb00006a bl a0009fdc <rtems_aio_search_fd> <== NOT EXECUTED
if (r_chain == NULL) {
a0009e30: e3500000 cmp r0, #0 <== NOT EXECUTED
a0009e34: 0affffe8 beq a0009ddc <aio_cancel+0xf0> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one (EINVAL);
}
AIO_printf ("Request on [IQ]\n");
result = rtems_aio_remove_req (&r_chain->perfd, aiocbp);
a0009e38: e1a01005 mov r1, r5 <== NOT EXECUTED
a0009e3c: e2800008 add r0, r0, #8 <== NOT EXECUTED
a0009e40: eb000157 bl a000a3a4 <rtems_aio_remove_req> <== NOT EXECUTED
a0009e44: e1a05000 mov r5, r0 <== NOT EXECUTED
a0009e48: ea00000c b a0009e80 <aio_cancel+0x194> <== NOT EXECUTED
pthread_mutex_unlock (&aio_request_queue.mutex);
return result;
} else {
pthread_mutex_unlock (&aio_request_queue.mutex);
a0009e4c: e1a00004 mov r0, r4 <== NOT EXECUTED
a0009e50: eb0003ea bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
return AIO_ALLDONE;
a0009e54: e3a05002 mov r5, #2 <== NOT EXECUTED
a0009e58: ea00000a b a0009e88 <aio_cancel+0x19c> <== NOT EXECUTED
}
}
AIO_printf ("Request on [WQ]\n");
pthread_mutex_lock (&r_chain->mutex);
a0009e5c: e287801c add r8, r7, #28 <== NOT EXECUTED
a0009e60: e1a00008 mov r0, r8 <== NOT EXECUTED
a0009e64: eb0003c6 bl a000ad84 <pthread_mutex_lock> <== NOT EXECUTED
result = rtems_aio_remove_req (&r_chain->perfd, aiocbp);
a0009e68: e1a01005 mov r1, r5 <== NOT EXECUTED
a0009e6c: e2870008 add r0, r7, #8 <== NOT EXECUTED
a0009e70: eb00014b bl a000a3a4 <rtems_aio_remove_req> <== NOT EXECUTED
a0009e74: e1a05000 mov r5, r0 <== NOT EXECUTED
pthread_mutex_unlock (&r_chain->mutex);
a0009e78: e1a00008 mov r0, r8 <== NOT EXECUTED
a0009e7c: eb0003df bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
pthread_mutex_unlock (&aio_request_queue.mutex);
a0009e80: e1a00004 mov r0, r4 <== NOT EXECUTED
a0009e84: eb0003dd bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
return result;
}
return AIO_ALLDONE;
}
a0009e88: e1a00005 mov r0, r5
a0009e8c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a0009e9c <aio_fsync>:
)
{
rtems_aio_request *req;
int mode;
if (op != O_SYNC)
a0009e9c: e3500a02 cmp r0, #8192 ; 0x2000
int aio_fsync(
int op,
struct aiocb *aiocbp
)
{
a0009ea0: e92d4030 push {r4, r5, lr}
a0009ea4: e1a04001 mov r4, r1
rtems_aio_request *req;
int mode;
if (op != O_SYNC)
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
a0009ea8: 13a05016 movne r5, #22
)
{
rtems_aio_request *req;
int mode;
if (op != O_SYNC)
a0009eac: 1a00000c bne a0009ee4 <aio_fsync+0x48>
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
mode = fcntl (aiocbp->aio_fildes, F_GETFL);
a0009eb0: e5910000 ldr r0, [r1]
a0009eb4: e3a01003 mov r1, #3
a0009eb8: eb0019c1 bl a00105c4 <fcntl>
if (!(((mode & O_ACCMODE) == O_WRONLY) || ((mode & O_ACCMODE) == O_RDWR)))
a0009ebc: e2000003 and r0, r0, #3
a0009ec0: e2400001 sub r0, r0, #1
a0009ec4: e3500001 cmp r0, #1
rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);
a0009ec8: 83a05009 movhi r5, #9
if (op != O_SYNC)
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
mode = fcntl (aiocbp->aio_fildes, F_GETFL);
if (!(((mode & O_ACCMODE) == O_WRONLY) || ((mode & O_ACCMODE) == O_RDWR)))
a0009ecc: 8a000004 bhi a0009ee4 <aio_fsync+0x48>
rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);
req = malloc (sizeof (rtems_aio_request));
a0009ed0: e3a00018 mov r0, #24 <== NOT EXECUTED
a0009ed4: ebfff536 bl a00073b4 <malloc> <== NOT EXECUTED
if (req == NULL)
a0009ed8: e2503000 subs r3, r0, #0 <== NOT EXECUTED
a0009edc: 1a000007 bne a0009f00 <aio_fsync+0x64> <== NOT EXECUTED
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
a0009ee0: e3a0500b mov r5, #11 <== NOT EXECUTED
a0009ee4: e3e03000 mvn r3, #0
a0009ee8: e5845030 str r5, [r4, #48] ; 0x30
a0009eec: e5843034 str r3, [r4, #52] ; 0x34
a0009ef0: eb0026dd bl a0013a6c <__errno>
a0009ef4: e5805000 str r5, [r0]
req->aiocbp = aiocbp;
req->aiocbp->aio_lio_opcode = LIO_SYNC;
return rtems_aio_enqueue (req);
}
a0009ef8: e3e00000 mvn r0, #0
a0009efc: e8bd8030 pop {r4, r5, pc}
req = malloc (sizeof (rtems_aio_request));
if (req == NULL)
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
req->aiocbp = aiocbp;
a0009f00: e5834014 str r4, [r3, #20] <== NOT EXECUTED
req->aiocbp->aio_lio_opcode = LIO_SYNC;
a0009f04: e3a03003 mov r3, #3 <== NOT EXECUTED
a0009f08: e584302c str r3, [r4, #44] ; 0x2c <== NOT EXECUTED
return rtems_aio_enqueue (req);
}
a0009f0c: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
req->aiocbp = aiocbp;
req->aiocbp->aio_lio_opcode = LIO_SYNC;
return rtems_aio_enqueue (req);
a0009f10: ea00013e b a000a410 <rtems_aio_enqueue> <== NOT EXECUTED
a000a61c <aio_read>:
* 0 - otherwise
*/
int
aio_read (struct aiocb *aiocbp)
{
a000a61c: e92d4030 push {r4, r5, lr}
rtems_aio_request *req;
int mode;
mode = fcntl (aiocbp->aio_fildes, F_GETFL);
a000a620: e3a01003 mov r1, #3
* 0 - otherwise
*/
int
aio_read (struct aiocb *aiocbp)
{
a000a624: e1a04000 mov r4, r0
rtems_aio_request *req;
int mode;
mode = fcntl (aiocbp->aio_fildes, F_GETFL);
a000a628: e5900000 ldr r0, [r0]
a000a62c: eb0017e4 bl a00105c4 <fcntl>
if (!(((mode & O_ACCMODE) == O_RDONLY) || ((mode & O_ACCMODE) == O_RDWR)))
a000a630: e2000003 and r0, r0, #3
a000a634: e3500002 cmp r0, #2
a000a638: 13500000 cmpne r0, #0
rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);
a000a63c: 13a05009 movne r5, #9
{
rtems_aio_request *req;
int mode;
mode = fcntl (aiocbp->aio_fildes, F_GETFL);
if (!(((mode & O_ACCMODE) == O_RDONLY) || ((mode & O_ACCMODE) == O_RDWR)))
a000a640: 1a00000d bne a000a67c <aio_read+0x60>
rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);
if (aiocbp->aio_reqprio < 0 || aiocbp->aio_reqprio > AIO_PRIO_DELTA_MAX)
a000a644: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED
a000a648: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a64c: 1a000007 bne a000a670 <aio_read+0x54> <== NOT EXECUTED
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
if (aiocbp->aio_offset < 0)
a000a650: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED
a000a654: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a658: ba000004 blt a000a670 <aio_read+0x54> <== NOT EXECUTED
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
req = malloc (sizeof (rtems_aio_request));
a000a65c: e3a00018 mov r0, #24 <== NOT EXECUTED
a000a660: ebfff353 bl a00073b4 <malloc> <== NOT EXECUTED
if (req == NULL)
a000a664: e2503000 subs r3, r0, #0 <== NOT EXECUTED
a000a668: 1a00000a bne a000a698 <aio_read+0x7c> <== NOT EXECUTED
a000a66c: ea000001 b a000a678 <aio_read+0x5c> <== NOT EXECUTED
if (aiocbp->aio_reqprio < 0 || aiocbp->aio_reqprio > AIO_PRIO_DELTA_MAX)
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
if (aiocbp->aio_offset < 0)
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
a000a670: e3a05016 mov r5, #22 <== NOT EXECUTED
a000a674: ea000000 b a000a67c <aio_read+0x60> <== NOT EXECUTED
req = malloc (sizeof (rtems_aio_request));
if (req == NULL)
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
a000a678: e3a0500b mov r5, #11 <== NOT EXECUTED
a000a67c: e3e03000 mvn r3, #0
a000a680: e5845030 str r5, [r4, #48] ; 0x30
a000a684: e5843034 str r3, [r4, #52] ; 0x34
a000a688: eb0024f7 bl a0013a6c <__errno>
a000a68c: e5805000 str r5, [r0]
req->aiocbp = aiocbp;
req->aiocbp->aio_lio_opcode = LIO_READ;
return rtems_aio_enqueue (req);
}
a000a690: e3e00000 mvn r0, #0
a000a694: e8bd8030 pop {r4, r5, pc}
req = malloc (sizeof (rtems_aio_request));
if (req == NULL)
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
req->aiocbp = aiocbp;
a000a698: e5834014 str r4, [r3, #20] <== NOT EXECUTED
req->aiocbp->aio_lio_opcode = LIO_READ;
a000a69c: e3a03001 mov r3, #1 <== NOT EXECUTED
a000a6a0: e584302c str r3, [r4, #44] ; 0x2c <== NOT EXECUTED
return rtems_aio_enqueue (req);
}
a000a6a4: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
req->aiocbp = aiocbp;
req->aiocbp->aio_lio_opcode = LIO_READ;
return rtems_aio_enqueue (req);
a000a6a8: eaffff58 b a000a410 <rtems_aio_enqueue> <== NOT EXECUTED
a000a6b4 <aio_write>:
* 0 - otherwise
*/
int
aio_write (struct aiocb *aiocbp)
{
a000a6b4: e92d4030 push {r4, r5, lr}
rtems_aio_request *req;
int mode;
mode = fcntl (aiocbp->aio_fildes, F_GETFL);
a000a6b8: e3a01003 mov r1, #3
* 0 - otherwise
*/
int
aio_write (struct aiocb *aiocbp)
{
a000a6bc: e1a04000 mov r4, r0
rtems_aio_request *req;
int mode;
mode = fcntl (aiocbp->aio_fildes, F_GETFL);
a000a6c0: e5900000 ldr r0, [r0]
a000a6c4: eb0017be bl a00105c4 <fcntl>
if (!(((mode & O_ACCMODE) == O_WRONLY) || ((mode & O_ACCMODE) == O_RDWR)))
a000a6c8: e2000003 and r0, r0, #3
a000a6cc: e2400001 sub r0, r0, #1
a000a6d0: e3500001 cmp r0, #1
rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);
a000a6d4: 83a05009 movhi r5, #9
{
rtems_aio_request *req;
int mode;
mode = fcntl (aiocbp->aio_fildes, F_GETFL);
if (!(((mode & O_ACCMODE) == O_WRONLY) || ((mode & O_ACCMODE) == O_RDWR)))
a000a6d8: 8a00000d bhi a000a714 <aio_write+0x60>
rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);
if (aiocbp->aio_reqprio < 0 || aiocbp->aio_reqprio > AIO_PRIO_DELTA_MAX)
a000a6dc: e5943014 ldr r3, [r4, #20]
a000a6e0: e3530000 cmp r3, #0
a000a6e4: 1a000007 bne a000a708 <aio_write+0x54>
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
if (aiocbp->aio_offset < 0)
a000a6e8: e5943008 ldr r3, [r4, #8]
a000a6ec: e3530000 cmp r3, #0
a000a6f0: ba000004 blt a000a708 <aio_write+0x54>
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
req = malloc (sizeof (rtems_aio_request));
a000a6f4: e3a00018 mov r0, #24
a000a6f8: ebfff32d bl a00073b4 <malloc>
if (req == NULL)
a000a6fc: e2503000 subs r3, r0, #0
a000a700: 1a00000a bne a000a730 <aio_write+0x7c>
a000a704: ea000001 b a000a710 <aio_write+0x5c> <== NOT EXECUTED
if (aiocbp->aio_reqprio < 0 || aiocbp->aio_reqprio > AIO_PRIO_DELTA_MAX)
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
if (aiocbp->aio_offset < 0)
rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);
a000a708: e3a05016 mov r5, #22
a000a70c: ea000000 b a000a714 <aio_write+0x60>
req = malloc (sizeof (rtems_aio_request));
if (req == NULL)
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
a000a710: e3a0500b mov r5, #11 <== NOT EXECUTED
a000a714: e3e03000 mvn r3, #0
a000a718: e5845030 str r5, [r4, #48] ; 0x30
a000a71c: e5843034 str r3, [r4, #52] ; 0x34
a000a720: eb0024d1 bl a0013a6c <__errno>
a000a724: e5805000 str r5, [r0]
req->aiocbp = aiocbp;
req->aiocbp->aio_lio_opcode = LIO_WRITE;
return rtems_aio_enqueue (req);
}
a000a728: e3e00000 mvn r0, #0
a000a72c: e8bd8030 pop {r4, r5, pc}
req = malloc (sizeof (rtems_aio_request));
if (req == NULL)
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
req->aiocbp = aiocbp;
a000a730: e5834014 str r4, [r3, #20]
req->aiocbp->aio_lio_opcode = LIO_WRITE;
a000a734: e3a03002 mov r3, #2
a000a738: e584302c str r3, [r4, #44] ; 0x2c
return rtems_aio_enqueue (req);
}
a000a73c: e8bd4030 pop {r4, r5, lr}
rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);
req->aiocbp = aiocbp;
req->aiocbp->aio_lio_opcode = LIO_WRITE;
return rtems_aio_enqueue (req);
a000a740: eaffff32 b a000a410 <rtems_aio_enqueue>
a000b270 <alarm>:
}
unsigned int alarm(
unsigned int seconds
)
{
a000b270: e92d4070 push {r4, r5, r6, lr}
/*
* Initialize the timer used to implement alarm().
*/
if ( !the_timer->routine ) {
a000b274: e59f6080 ldr r6, [pc, #128] ; a000b2fc <alarm+0x8c>
}
unsigned int alarm(
unsigned int seconds
)
{
a000b278: e1a05000 mov r5, r0
/*
* Initialize the timer used to implement alarm().
*/
if ( !the_timer->routine ) {
a000b27c: e596401c ldr r4, [r6, #28]
a000b280: e3540000 cmp r4, #0
a000b284: 1a000005 bne a000b2a0 <alarm+0x30>
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a000b288: e59f3070 ldr r3, [pc, #112] ; a000b300 <alarm+0x90>
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a000b28c: e5864008 str r4, [r6, #8]
the_watchdog->routine = routine;
the_watchdog->id = id;
a000b290: e5864020 str r4, [r6, #32]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a000b294: e586301c str r3, [r6, #28]
the_watchdog->id = id;
the_watchdog->user_data = user_data;
a000b298: e5864024 str r4, [r6, #36] ; 0x24
a000b29c: ea00000e b a000b2dc <alarm+0x6c>
_Watchdog_Initialize( the_timer, _POSIX_signals_Alarm_TSR, 0, NULL );
} else {
Watchdog_States state;
state = _Watchdog_Remove( the_timer );
a000b2a0: e1a00006 mov r0, r6
a000b2a4: eb0012b0 bl a000fd6c <_Watchdog_Remove>
if ( (state == WATCHDOG_ACTIVE) || (state == WATCHDOG_REMOVE_IT) ) {
a000b2a8: e2400002 sub r0, r0, #2 <== NOT EXECUTED
a000b2ac: e3500001 cmp r0, #1 <== NOT EXECUTED
unsigned int alarm(
unsigned int seconds
)
{
unsigned int remaining = 0;
a000b2b0: 83a04000 movhi r4, #0 <== NOT EXECUTED
_Watchdog_Initialize( the_timer, _POSIX_signals_Alarm_TSR, 0, NULL );
} else {
Watchdog_States state;
state = _Watchdog_Remove( the_timer );
if ( (state == WATCHDOG_ACTIVE) || (state == WATCHDOG_REMOVE_IT) ) {
a000b2b4: 8a000008 bhi a000b2dc <alarm+0x6c> <== NOT EXECUTED
* boot. Since alarm() is dealing in seconds, we must account for
* this.
*/
remaining = the_timer->initial -
((the_timer->stop_time - the_timer->start_time) / TOD_TICKS_PER_SECOND);
a000b2b8: e5962018 ldr r2, [r6, #24] <== NOT EXECUTED
a000b2bc: e5963014 ldr r3, [r6, #20] <== NOT EXECUTED
* The stop_time and start_time fields are snapshots of ticks since
* boot. Since alarm() is dealing in seconds, we must account for
* this.
*/
remaining = the_timer->initial -
a000b2c0: e596400c ldr r4, [r6, #12] <== NOT EXECUTED
((the_timer->stop_time - the_timer->start_time) / TOD_TICKS_PER_SECOND);
a000b2c4: e0636002 rsb r6, r3, r2 <== NOT EXECUTED
a000b2c8: eb000978 bl a000d8b0 <TOD_TICKS_PER_SECOND_method> <== NOT EXECUTED
a000b2cc: e1a01000 mov r1, r0 <== NOT EXECUTED
a000b2d0: e1a00006 mov r0, r6 <== NOT EXECUTED
a000b2d4: eb0037d3 bl a0019228 <__aeabi_uidiv> <== NOT EXECUTED
* The stop_time and start_time fields are snapshots of ticks since
* boot. Since alarm() is dealing in seconds, we must account for
* this.
*/
remaining = the_timer->initial -
a000b2d8: e0604004 rsb r4, r0, r4 <== NOT EXECUTED
((the_timer->stop_time - the_timer->start_time) / TOD_TICKS_PER_SECOND);
}
}
if ( seconds )
a000b2dc: e3550000 cmp r5, #0
a000b2e0: 0a000003 beq a000b2f4 <alarm+0x84>
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000b2e4: e59f1010 ldr r1, [pc, #16] ; a000b2fc <alarm+0x8c>
_Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog );
a000b2e8: e59f0014 ldr r0, [pc, #20] ; a000b304 <alarm+0x94>
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000b2ec: e581500c str r5, [r1, #12]
_Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog );
a000b2f0: eb001245 bl a000fc0c <_Watchdog_Insert>
_Watchdog_Insert_seconds( the_timer, seconds );
return remaining;
}
a000b2f4: e1a00004 mov r0, r4
a000b2f8: e8bd8070 pop {r4, r5, r6, pc}
a0009a68 <clock_getres>:
int clock_getres(
clockid_t clock_id,
struct timespec *res
)
{
a0009a68: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
if ( !res )
a0009a6c: e2514000 subs r4, r1, #0 <== NOT EXECUTED
a0009a70: 1a000004 bne a0009a88 <clock_getres+0x20> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
a0009a74: eb0021d2 bl a00121c4 <__errno> <== NOT EXECUTED
a0009a78: e3a03016 mov r3, #22 <== NOT EXECUTED
a0009a7c: e5803000 str r3, [r0] <== NOT EXECUTED
a0009a80: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009a84: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
switch ( clock_id ) {
a0009a88: e2400001 sub r0, r0, #1 <== NOT EXECUTED
a0009a8c: e3500002 cmp r0, #2 <== NOT EXECUTED
a0009a90: 8a000009 bhi a0009abc <clock_getres+0x54> <== NOT EXECUTED
case CLOCK_REALTIME:
case CLOCK_PROCESS_CPUTIME:
case CLOCK_THREAD_CPUTIME:
if ( res ) {
res->tv_sec = rtems_configuration_get_microseconds_per_tick() /
a0009a94: e59f3034 ldr r3, [pc, #52] ; a0009ad0 <clock_getres+0x68> <== NOT EXECUTED
a0009a98: e59f1034 ldr r1, [pc, #52] ; a0009ad4 <clock_getres+0x6c> <== NOT EXECUTED
a0009a9c: e593500c ldr r5, [r3, #12] <== NOT EXECUTED
a0009aa0: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009aa4: eb004c74 bl a001cc7c <__aeabi_uidiv> <== NOT EXECUTED
TOD_MICROSECONDS_PER_SECOND;
res->tv_nsec = rtems_configuration_get_nanoseconds_per_tick();
a0009aa8: e3a03ffa mov r3, #1000 ; 0x3e8 <== NOT EXECUTED
a0009aac: e0050593 mul r5, r3, r5 <== NOT EXECUTED
case CLOCK_REALTIME:
case CLOCK_PROCESS_CPUTIME:
case CLOCK_THREAD_CPUTIME:
if ( res ) {
res->tv_sec = rtems_configuration_get_microseconds_per_tick() /
a0009ab0: e8840021 stm r4, {r0, r5} <== NOT EXECUTED
default:
rtems_set_errno_and_return_minus_one( EINVAL );
}
return 0;
a0009ab4: e3a00000 mov r0, #0 <== NOT EXECUTED
a0009ab8: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
res->tv_nsec = rtems_configuration_get_nanoseconds_per_tick();
}
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
a0009abc: eb0021c0 bl a00121c4 <__errno> <== NOT EXECUTED
a0009ac0: e3a03016 mov r3, #22 <== NOT EXECUTED
a0009ac4: e5803000 str r3, [r0] <== NOT EXECUTED
a0009ac8: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
return 0;
}
a0009acc: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a00093f0 <clock_gettime>:
int clock_gettime(
clockid_t clock_id,
struct timespec *tp
)
{
a00093f0: e1a03000 mov r3, r0
if ( !tp )
a00093f4: e2510000 subs r0, r1, #0
int clock_gettime(
clockid_t clock_id,
struct timespec *tp
)
{
a00093f8: e52de004 push {lr} ; (str lr, [sp, #-4]!)
if ( !tp )
a00093fc: 1a000002 bne a000940c <clock_gettime+0x1c>
rtems_set_errno_and_return_minus_one( EINVAL );
a0009400: eb0023cb bl a0012334 <__errno>
a0009404: e3a03016 mov r3, #22
a0009408: ea00000e b a0009448 <clock_gettime+0x58>
if ( clock_id == CLOCK_REALTIME ) {
a000940c: e3530001 cmp r3, #1
a0009410: 1a000001 bne a000941c <clock_gettime+0x2c>
_TOD_Get(tp);
a0009414: eb000751 bl a000b160 <_TOD_Get>
a0009418: ea000004 b a0009430 <clock_gettime+0x40>
return 0;
}
#ifdef CLOCK_MONOTONIC
if ( clock_id == CLOCK_MONOTONIC ) {
a000941c: e3530004 cmp r3, #4
a0009420: 0a000001 beq a000942c <clock_gettime+0x3c>
return 0;
}
#endif
#ifdef _POSIX_CPUTIME
if ( clock_id == CLOCK_PROCESS_CPUTIME ) {
a0009424: e3530002 cmp r3, #2
a0009428: 1a000002 bne a0009438 <clock_gettime+0x48>
_TOD_Get_uptime_as_timespec( tp );
a000942c: eb000762 bl a000b1bc <_TOD_Get_uptime_as_timespec> <== NOT EXECUTED
return 0;
a0009430: e3a00000 mov r0, #0
a0009434: e49df004 pop {pc} ; (ldr pc, [sp], #4)
}
#endif
#ifdef _POSIX_THREAD_CPUTIME
if ( clock_id == CLOCK_THREAD_CPUTIME )
a0009438: e3530003 cmp r3, #3
a000943c: 1a000004 bne a0009454 <clock_gettime+0x64>
rtems_set_errno_and_return_minus_one( ENOSYS );
a0009440: eb0023bb bl a0012334 <__errno> <== NOT EXECUTED
a0009444: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a0009448: e5803000 str r3, [r0]
a000944c: e3e00000 mvn r0, #0
a0009450: e49df004 pop {pc} ; (ldr pc, [sp], #4)
#endif
rtems_set_errno_and_return_minus_one( EINVAL );
a0009454: eb0023b6 bl a0012334 <__errno>
a0009458: e3a03016 mov r3, #22
a000945c: e5803000 str r3, [r0]
a0009460: e3e00000 mvn r0, #0
return 0;
}
a0009464: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a0009468 <clock_settime>:
int clock_settime(
clockid_t clock_id,
const struct timespec *tp
)
{
a0009468: e1a03000 mov r3, r0
if ( !tp )
a000946c: e2510000 subs r0, r1, #0
int clock_settime(
clockid_t clock_id,
const struct timespec *tp
)
{
a0009470: e52de004 push {lr} ; (str lr, [sp, #-4]!)
if ( !tp )
a0009474: 0a000005 beq a0009490 <clock_settime+0x28>
rtems_set_errno_and_return_minus_one( EINVAL );
if ( clock_id == CLOCK_REALTIME ) {
a0009478: e3530001 cmp r3, #1
a000947c: 1a00000e bne a00094bc <clock_settime+0x54>
if ( tp->tv_sec < TOD_SECONDS_1970_THROUGH_1988 )
a0009480: e5902000 ldr r2, [r0]
a0009484: e59f3068 ldr r3, [pc, #104] ; a00094f4 <clock_settime+0x8c>
a0009488: e1520003 cmp r2, r3
a000948c: 8a000002 bhi a000949c <clock_settime+0x34>
rtems_set_errno_and_return_minus_one( EINVAL );
a0009490: eb0023a7 bl a0012334 <__errno>
a0009494: e3a03016 mov r3, #22
a0009498: ea00000d b a00094d4 <clock_settime+0x6c>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000949c: e59f3054 ldr r3, [pc, #84] ; a00094f8 <clock_settime+0x90>
a00094a0: e5932000 ldr r2, [r3]
a00094a4: e2822001 add r2, r2, #1
a00094a8: e5832000 str r2, [r3]
_Thread_Disable_dispatch();
_TOD_Set( tp );
a00094ac: eb000758 bl a000b214 <_TOD_Set>
_Thread_Enable_dispatch();
a00094b0: eb000c7f bl a000c6b4 <_Thread_Enable_dispatch>
rtems_set_errno_and_return_minus_one( ENOSYS );
#endif
else
rtems_set_errno_and_return_minus_one( EINVAL );
return 0;
a00094b4: e3a00000 mov r0, #0
a00094b8: e49df004 pop {pc} ; (ldr pc, [sp], #4)
_Thread_Disable_dispatch();
_TOD_Set( tp );
_Thread_Enable_dispatch();
}
#ifdef _POSIX_CPUTIME
else if ( clock_id == CLOCK_PROCESS_CPUTIME )
a00094bc: e3530002 cmp r3, #2
a00094c0: 0a000001 beq a00094cc <clock_settime+0x64>
rtems_set_errno_and_return_minus_one( ENOSYS );
#endif
#ifdef _POSIX_THREAD_CPUTIME
else if ( clock_id == CLOCK_THREAD_CPUTIME )
a00094c4: e3530003 cmp r3, #3
a00094c8: 1a000004 bne a00094e0 <clock_settime+0x78>
rtems_set_errno_and_return_minus_one( ENOSYS );
a00094cc: eb002398 bl a0012334 <__errno>
a00094d0: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a00094d4: e5803000 str r3, [r0]
a00094d8: e3e00000 mvn r0, #0
a00094dc: e49df004 pop {pc} ; (ldr pc, [sp], #4)
#endif
else
rtems_set_errno_and_return_minus_one( EINVAL );
a00094e0: eb002393 bl a0012334 <__errno>
a00094e4: e3a03016 mov r3, #22
a00094e8: e5803000 str r3, [r0]
a00094ec: e3e00000 mvn r0, #0
return 0;
}
a00094f0: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a0009250 <fork>:
#include <sys/types.h>
#include <errno.h>
#include <rtems/seterr.h>
int fork( void )
{
a0009250: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a0009254: eb0021e8 bl a00119fc <__errno> <== NOT EXECUTED
a0009258: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a000925c: e5803000 str r3, [r0] <== NOT EXECUTED
}
a0009260: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009264: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a0025828 <killinfo>:
int killinfo(
pid_t pid,
int sig,
const union sigval *value
)
{
a0025828: e92d47f7 push {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, lr}
a002582c: e1a05000 mov r5, r0
a0025830: e1a04001 mov r4, r1
a0025834: e1a06002 mov r6, r2
POSIX_signals_Siginfo_node *psiginfo;
/*
* Only supported for the "calling process" (i.e. this node).
*/
if ( pid != getpid() )
a0025838: ebffff4f bl a002557c <getpid>
a002583c: e1550000 cmp r5, r0
a0025840: 0a000002 beq a0025850 <killinfo+0x28>
rtems_set_errno_and_return_minus_one( ESRCH );
a0025844: ebffc291 bl a0016290 <__errno> <== NOT EXECUTED
a0025848: e3a03003 mov r3, #3 <== NOT EXECUTED
a002584c: ea00007c b a0025a44 <killinfo+0x21c> <== NOT EXECUTED
/*
* Validate the signal passed.
*/
if ( !sig )
a0025850: e3540000 cmp r4, #0
a0025854: 0a000002 beq a0025864 <killinfo+0x3c>
static inline bool is_valid_signo(
int signo
)
{
return ((signo) >= 1 && (signo) <= 32 );
a0025858: e2445001 sub r5, r4, #1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(sig) )
a002585c: e355001f cmp r5, #31
a0025860: 9a000002 bls a0025870 <killinfo+0x48>
rtems_set_errno_and_return_minus_one( EINVAL );
a0025864: ebffc289 bl a0016290 <__errno> <== NOT EXECUTED
a0025868: e3a03016 mov r3, #22 <== NOT EXECUTED
a002586c: ea000074 b a0025a44 <killinfo+0x21c> <== NOT EXECUTED
/*
* If the signal is being ignored, then we are out of here.
*/
if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN )
a0025870: e59f320c ldr r3, [pc, #524] ; a0025a84 <killinfo+0x25c>
a0025874: e3a0200c mov r2, #12
a0025878: e0233492 mla r3, r2, r4, r3
a002587c: e5933008 ldr r3, [r3, #8]
a0025880: e3530001 cmp r3, #1
a0025884: 0a00007c beq a0025a7c <killinfo+0x254>
/*
* P1003.1c/Draft 10, p. 33 says that certain signals should always
* be directed to the executing thread such as those caused by hardware
* faults.
*/
if ( (sig == SIGFPE) || (sig == SIGILL) || (sig == SIGSEGV ) )
a0025888: e3540008 cmp r4, #8
a002588c: 13540004 cmpne r4, #4
a0025890: 0a000001 beq a002589c <killinfo+0x74>
a0025894: e354000b cmp r4, #11
a0025898: 1a000003 bne a00258ac <killinfo+0x84>
return pthread_kill( pthread_self(), sig );
a002589c: eb00010b bl a0025cd0 <pthread_self> <== NOT EXECUTED
a00258a0: e1a01004 mov r1, r4 <== NOT EXECUTED
a00258a4: eb0000d4 bl a0025bfc <pthread_kill> <== NOT EXECUTED
a00258a8: ea000074 b a0025a80 <killinfo+0x258> <== NOT EXECUTED
static inline sigset_t signo_to_mask(
uint32_t sig
)
{
return 1u << (sig - 1);
a00258ac: e3a03001 mov r3, #1
* Build up a siginfo structure
*/
siginfo = &siginfo_struct;
siginfo->si_signo = sig;
siginfo->si_code = SI_USER;
if ( !value ) {
a00258b0: e3560000 cmp r6, #0
/*
* Build up a siginfo structure
*/
siginfo = &siginfo_struct;
siginfo->si_signo = sig;
siginfo->si_code = SI_USER;
a00258b4: e58d3004 str r3, [sp, #4]
/*
* Build up a siginfo structure
*/
siginfo = &siginfo_struct;
siginfo->si_signo = sig;
a00258b8: e58d4000 str r4, [sp]
a00258bc: e1a05513 lsl r5, r3, r5
siginfo->si_code = SI_USER;
if ( !value ) {
siginfo->si_value.sival_int = 0;
} else {
siginfo->si_value = *value;
a00258c0: 15963000 ldrne r3, [r6]
*/
siginfo = &siginfo_struct;
siginfo->si_signo = sig;
siginfo->si_code = SI_USER;
if ( !value ) {
siginfo->si_value.sival_int = 0;
a00258c4: 058d6008 streq r6, [sp, #8]
} else {
siginfo->si_value = *value;
a00258c8: 158d3008 strne r3, [sp, #8]
a00258cc: e59f31b4 ldr r3, [pc, #436] ; a0025a88 <killinfo+0x260>
a00258d0: e5932000 ldr r2, [r3]
a00258d4: e2822001 add r2, r2, #1
a00258d8: e5832000 str r2, [r3]
/*
* Is the currently executing thread interested? If so then it will
* get it an execute it as soon as the dispatcher executes.
*/
the_thread = _Thread_Executing;
a00258dc: e59f31a8 ldr r3, [pc, #424] ; a0025a8c <killinfo+0x264>
a00258e0: e5930004 ldr r0, [r3, #4]
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
if ( _POSIX_signals_Is_interested( api, mask ) ) {
a00258e4: e59030fc ldr r3, [r0, #252] ; 0xfc
a00258e8: e59330d0 ldr r3, [r3, #208] ; 0xd0
a00258ec: e1d53003 bics r3, r5, r3
}
DEBUG_STEP("\n");
_Thread_Enable_dispatch();
return 0;
}
a00258f0: 059f2198 ldreq r2, [pc, #408] ; a0025a90 <killinfo+0x268>
a00258f4: 04923004 ldreq r3, [r2], #4
* get it an execute it as soon as the dispatcher executes.
*/
the_thread = _Thread_Executing;
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
if ( _POSIX_signals_Is_interested( api, mask ) ) {
a00258f8: 0a000009 beq a0025924 <killinfo+0xfc>
a00258fc: ea00003c b a00259f4 <killinfo+0x1cc> <== NOT EXECUTED
#endif
/*
* Is this thread is actually blocked waiting for the signal?
*/
if (the_thread->Wait.option & mask)
a0025900: e593c030 ldr ip, [r3, #48] ; 0x30 <== NOT EXECUTED
for ( the_node = _Chain_First( the_chain );
!_Chain_Is_tail( the_chain, the_node ) ;
the_node = the_node->next ) {
the_thread = (Thread_Control *)the_node;
a0025904: e1a00003 mov r0, r3 <== NOT EXECUTED
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
a0025908: e59310fc ldr r1, [r3, #252] ; 0xfc <== NOT EXECUTED
#endif
/*
* Is this thread is actually blocked waiting for the signal?
*/
if (the_thread->Wait.option & mask)
a002590c: e115000c tst r5, ip <== NOT EXECUTED
a0025910: 1a000037 bne a00259f4 <killinfo+0x1cc> <== NOT EXECUTED
/*
* Is this thread is blocked waiting for another signal but has
* not blocked this one?
*/
if (~api->signals_blocked & mask)
a0025914: e59110d0 ldr r1, [r1, #208] ; 0xd0 <== NOT EXECUTED
a0025918: e1d51001 bics r1, r5, r1 <== NOT EXECUTED
a002591c: 1a000034 bne a00259f4 <killinfo+0x1cc> <== NOT EXECUTED
the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo;
for ( the_node = _Chain_First( the_chain );
!_Chain_Is_tail( the_chain, the_node ) ;
the_node = the_node->next ) {
a0025920: e5933000 ldr r3, [r3] <== NOT EXECUTED
/* XXX violation of visibility -- need to define thread queue support */
the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo;
for ( the_node = _Chain_First( the_chain );
a0025924: e1530002 cmp r3, r2
a0025928: 1afffff4 bne a0025900 <killinfo+0xd8>
* NOTES:
*
* + rtems internal threads do not receive signals.
*/
interested = NULL;
interested_priority = PRIORITY_MAXIMUM + 1;
a002592c: e59f3160 ldr r3, [pc, #352] ; a0025a94 <killinfo+0x26c>
a0025930: e59fc160 ldr ip, [pc, #352] ; a0025a98 <killinfo+0x270>
*
* NOTES:
*
* + rtems internal threads do not receive signals.
*/
interested = NULL;
a0025934: e3a00000 mov r0, #0
interested_priority = PRIORITY_MAXIMUM + 1;
a0025938: e5d32000 ldrb r2, [r3]
*/
#define _POSIX_signals_Is_interested( _api, _mask ) \
( ~(_api)->signals_blocked & (_mask) )
int killinfo(
a002593c: e28ca008 add sl, ip, #8
* NOTES:
*
* + rtems internal threads do not receive signals.
*/
interested = NULL;
interested_priority = PRIORITY_MAXIMUM + 1;
a0025940: e2822001 add r2, r2, #1
for (the_api = OBJECTS_CLASSIC_API; the_api <= OBJECTS_APIS_LAST; the_api++) {
/*
* This can occur when no one is interested and an API is not configured.
*/
if ( !_Objects_Information_table[ the_api ] )
a0025944: e5bc3004 ldr r3, [ip, #4]!
a0025948: e3530000 cmp r3, #0
a002594c: 0a000024 beq a00259e4 <killinfo+0x1bc>
continue;
the_info = _Objects_Information_table[ the_api ][ 1 ];
a0025950: e5933004 ldr r3, [r3, #4]
#endif
maximum = the_info->maximum;
object_table = the_info->local_table;
for ( index = 1 ; index <= maximum ; index++ ) {
a0025954: e3a0e001 mov lr, #1
*/
if ( !the_info )
continue;
#endif
maximum = the_info->maximum;
a0025958: e1d391b0 ldrh r9, [r3, #16]
a002595c: e593601c ldr r6, [r3, #28]
object_table = the_info->local_table;
for ( index = 1 ; index <= maximum ; index++ ) {
a0025960: ea00001d b a00259dc <killinfo+0x1b4>
the_thread = (Thread_Control *) object_table[ index ];
a0025964: e5b63004 ldr r3, [r6, #4]!
if ( !the_thread )
a0025968: e3530000 cmp r3, #0
a002596c: 0a000019 beq a00259d8 <killinfo+0x1b0>
/*
* If this thread is of lower priority than the interested thread,
* go on to the next thread.
*/
if ( the_thread->current_priority > interested_priority )
a0025970: e5931014 ldr r1, [r3, #20]
a0025974: e1510002 cmp r1, r2
a0025978: 8a000016 bhi a00259d8 <killinfo+0x1b0>
#if defined(RTEMS_DEBUG)
if ( !api )
continue;
#endif
if ( !_POSIX_signals_Is_interested( api, mask ) )
a002597c: e59370fc ldr r7, [r3, #252] ; 0xfc
a0025980: e59770d0 ldr r7, [r7, #208] ; 0xd0
a0025984: e1d57007 bics r7, r5, r7
a0025988: 0a000012 beq a00259d8 <killinfo+0x1b0>
*
* NOTE: We initialized interested_priority to PRIORITY_MAXIMUM + 1
* so we never have to worry about deferencing a NULL
* interested thread.
*/
if ( the_thread->current_priority < interested_priority ) {
a002598c: e1510002 cmp r1, r2 <== NOT EXECUTED
a0025990: 3a00000e bcc a00259d0 <killinfo+0x1a8> <== NOT EXECUTED
* and blocking interruptibutable by signal.
*
* If the interested thread is ready, don't think about changing.
*/
if ( interested && !_States_Is_ready( interested->current_state ) ) {
a0025994: e3500000 cmp r0, #0 <== NOT EXECUTED
a0025998: 0a00000e beq a00259d8 <killinfo+0x1b0> <== NOT EXECUTED
a002599c: e5908010 ldr r8, [r0, #16] <== NOT EXECUTED
a00259a0: e3580000 cmp r8, #0 <== NOT EXECUTED
a00259a4: 0a00000b beq a00259d8 <killinfo+0x1b0> <== NOT EXECUTED
/* preferred ready over blocked */
DEBUG_STEP("5");
if ( _States_Is_ready( the_thread->current_state ) ) {
a00259a8: e5937010 ldr r7, [r3, #16] <== NOT EXECUTED
a00259ac: e3570000 cmp r7, #0 <== NOT EXECUTED
a00259b0: 0a000006 beq a00259d0 <killinfo+0x1a8> <== NOT EXECUTED
continue;
}
DEBUG_STEP("6");
/* prefer blocked/interruptible over blocked/not interruptible */
if ( !_States_Is_interruptible_by_signal(interested->current_state) ) {
a00259b4: e3180201 tst r8, #268435456 ; 0x10000000 <== NOT EXECUTED
a00259b8: 1a000006 bne a00259d8 <killinfo+0x1b0> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE bool _States_Is_interruptible_by_signal (
States_Control the_states
)
{
return (the_states & STATES_INTERRUPTIBLE_BY_SIGNAL);
a00259bc: e2077201 and r7, r7, #268435456 ; 0x10000000 <== NOT EXECUTED
DEBUG_STEP("7");
if ( _States_Is_interruptible_by_signal(the_thread->current_state) ) {
a00259c0: e3570000 cmp r7, #0 <== NOT EXECUTED
a00259c4: 11a02001 movne r2, r1 <== NOT EXECUTED
a00259c8: 11a00003 movne r0, r3 <== NOT EXECUTED
a00259cc: ea000001 b a00259d8 <killinfo+0x1b0> <== NOT EXECUTED
*/
if ( interested && !_States_Is_ready( interested->current_state ) ) {
/* preferred ready over blocked */
DEBUG_STEP("5");
if ( _States_Is_ready( the_thread->current_state ) ) {
a00259d0: e1a02001 mov r2, r1 <== NOT EXECUTED
a00259d4: e1a00003 mov r0, r3 <== NOT EXECUTED
#endif
maximum = the_info->maximum;
object_table = the_info->local_table;
for ( index = 1 ; index <= maximum ; index++ ) {
a00259d8: e28ee001 add lr, lr, #1
a00259dc: e15e0009 cmp lr, r9
a00259e0: 9affffdf bls a0025964 <killinfo+0x13c>
* + rtems internal threads do not receive signals.
*/
interested = NULL;
interested_priority = PRIORITY_MAXIMUM + 1;
for (the_api = OBJECTS_CLASSIC_API; the_api <= OBJECTS_APIS_LAST; the_api++) {
a00259e4: e15c000a cmp ip, sl
a00259e8: 1affffd5 bne a0025944 <killinfo+0x11c>
}
}
}
}
if ( interested ) {
a00259ec: e3500000 cmp r0, #0
a00259f0: 0a000004 beq a0025a08 <killinfo+0x1e0>
/*
* Returns true if the signal was synchronously given to a thread
* blocked waiting for the signal.
*/
if ( _POSIX_signals_Unblock_thread( the_thread, sig, siginfo ) ) {
a00259f4: e1a01004 mov r1, r4 <== NOT EXECUTED
a00259f8: e1a0200d mov r2, sp <== NOT EXECUTED
a00259fc: eb000032 bl a0025acc <_POSIX_signals_Unblock_thread> <== NOT EXECUTED
a0025a00: e3500000 cmp r0, #0 <== NOT EXECUTED
a0025a04: 1a00001b bne a0025a78 <killinfo+0x250> <== NOT EXECUTED
/*
* We may have woken up a thread but we definitely need to post the
* signal to the process wide information set.
*/
_POSIX_signals_Set_process_signals( mask );
a0025a08: e1a00005 mov r0, r5
a0025a0c: eb000024 bl a0025aa4 <_POSIX_signals_Set_process_signals>
if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) {
a0025a10: e3a0300c mov r3, #12
a0025a14: e0040493 mul r4, r3, r4
a0025a18: e59f3064 ldr r3, [pc, #100] ; a0025a84 <killinfo+0x25c>
a0025a1c: e7933004 ldr r3, [r3, r4]
a0025a20: e3530002 cmp r3, #2
a0025a24: 1a000013 bne a0025a78 <killinfo+0x250>
psiginfo = (POSIX_signals_Siginfo_node *)
_Chain_Get( &_POSIX_signals_Inactive_siginfo );
a0025a28: e59f006c ldr r0, [pc, #108] ; a0025a9c <killinfo+0x274> <== NOT EXECUTED
a0025a2c: ebffa4ed bl a000ede8 <_Chain_Get> <== NOT EXECUTED
if ( !psiginfo ) {
a0025a30: e2501000 subs r1, r0, #0 <== NOT EXECUTED
a0025a34: 1a000005 bne a0025a50 <killinfo+0x228> <== NOT EXECUTED
_Thread_Enable_dispatch();
a0025a38: ebffab3e bl a0010738 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EAGAIN );
a0025a3c: ebffc213 bl a0016290 <__errno> <== NOT EXECUTED
a0025a40: e3a0300b mov r3, #11 <== NOT EXECUTED
a0025a44: e5803000 str r3, [r0] <== NOT EXECUTED
a0025a48: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0025a4c: ea00000b b a0025a80 <killinfo+0x258> <== NOT EXECUTED
}
psiginfo->Info = *siginfo;
a0025a50: e59d3000 ldr r3, [sp] <== NOT EXECUTED
_Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node );
a0025a54: e59f0044 ldr r0, [pc, #68] ; a0025aa0 <killinfo+0x278> <== NOT EXECUTED
if ( !psiginfo ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( EAGAIN );
}
psiginfo->Info = *siginfo;
a0025a58: e5813008 str r3, [r1, #8] <== NOT EXECUTED
a0025a5c: e28d3004 add r3, sp, #4 <== NOT EXECUTED
a0025a60: e4932004 ldr r2, [r3], #4 <== NOT EXECUTED
_Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node );
a0025a64: e0800004 add r0, r0, r4 <== NOT EXECUTED
if ( !psiginfo ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( EAGAIN );
}
psiginfo->Info = *siginfo;
a0025a68: e5933000 ldr r3, [r3] <== NOT EXECUTED
a0025a6c: e581200c str r2, [r1, #12] <== NOT EXECUTED
a0025a70: e5813010 str r3, [r1, #16] <== NOT EXECUTED
_Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node );
a0025a74: ebffa4c8 bl a000ed9c <_Chain_Append> <== NOT EXECUTED
}
DEBUG_STEP("\n");
_Thread_Enable_dispatch();
a0025a78: ebffab2e bl a0010738 <_Thread_Enable_dispatch>
/*
* If the signal is being ignored, then we are out of here.
*/
if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN )
return 0;
a0025a7c: e3a00000 mov r0, #0
}
DEBUG_STEP("\n");
_Thread_Enable_dispatch();
return 0;
}
a0025a80: e8bd87fe pop {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, pc}
a0009280 <mprotect>:
const void *addr __attribute__((unused)),
size_t len __attribute__((unused)),
int prot __attribute__((unused)) )
{
return 0;
}
a0009280: e3a00000 mov r0, #0 <== NOT EXECUTED
a0009284: e12fff1e bx lr <== NOT EXECUTED
a000e57c <mq_close>:
*/
int mq_close(
mqd_t mqdes
)
{
a000e57c: e92d4031 push {r0, r4, r5, lr}
a000e580: e1a01000 mov r1, r0
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *_POSIX_Message_queue_Get_fd (
mqd_t id,
Objects_Locations *location
)
{
return (POSIX_Message_queue_Control_fd *) _Objects_Get(
a000e584: e1a0200d mov r2, sp
a000e588: e59f005c ldr r0, [pc, #92] ; a000e5ec <mq_close+0x70>
a000e58c: eb000cb2 bl a001185c <_Objects_Get>
POSIX_Message_queue_Control *the_mq;
POSIX_Message_queue_Control_fd *the_mq_fd;
Objects_Locations location;
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
if ( location == OBJECTS_LOCAL ) {
a000e590: e59d5000 ldr r5, [sp]
a000e594: e1a04000 mov r4, r0
a000e598: e3550000 cmp r5, #0
a000e59c: 1a00000d bne a000e5d8 <mq_close+0x5c>
* First update the actual message queue to reflect this descriptor
* being disassociated. This may result in the queue being really
* deleted.
*/
the_mq = the_mq_fd->Queue;
a000e5a0: e5900010 ldr r0, [r0, #16]
the_mq->open_count -= 1;
a000e5a4: e5903018 ldr r3, [r0, #24]
a000e5a8: e2433001 sub r3, r3, #1
a000e5ac: e5803018 str r3, [r0, #24]
_POSIX_Message_queue_Delete( the_mq );
a000e5b0: eb00000e bl a000e5f0 <_POSIX_Message_queue_Delete>
/*
* Now close this file descriptor.
*/
_Objects_Close(
a000e5b4: e59f0030 ldr r0, [pc, #48] ; a000e5ec <mq_close+0x70>
a000e5b8: e1a01004 mov r1, r4
a000e5bc: eb000ba7 bl a0011460 <_Objects_Close>
RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Free_fd (
POSIX_Message_queue_Control_fd *the_mq_fd
)
{
_Objects_Free( &_POSIX_Message_queue_Information_fds, &the_mq_fd->Object );
a000e5c0: e59f0024 ldr r0, [pc, #36] ; a000e5ec <mq_close+0x70>
a000e5c4: e1a01004 mov r1, r4
a000e5c8: eb000c4b bl a00116fc <_Objects_Free>
&_POSIX_Message_queue_Information_fds, &the_mq_fd->Object );
_POSIX_Message_queue_Free_fd( the_mq_fd );
_Thread_Enable_dispatch();
a000e5cc: eb000f7d bl a00123c8 <_Thread_Enable_dispatch>
return 0;
a000e5d0: e1a00005 mov r0, r5
a000e5d4: ea000003 b a000e5e8 <mq_close+0x6c>
/*
* OBJECTS_REMOTE:
* OBJECTS_ERROR:
*/
rtems_set_errno_and_return_minus_one( EBADF );
a000e5d8: eb00283c bl a00186d0 <__errno>
a000e5dc: e3a03009 mov r3, #9
a000e5e0: e5803000 str r3, [r0]
a000e5e4: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000e5e8: e8bd8038 pop {r3, r4, r5, pc}
a000e644 <mq_getattr>:
int mq_getattr(
mqd_t mqdes,
struct mq_attr *mqstat
)
{
a000e644: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
POSIX_Message_queue_Control *the_mq;
POSIX_Message_queue_Control_fd *the_mq_fd;
Objects_Locations location;
CORE_message_queue_Attributes *the_mq_attr;
if ( !mqstat )
a000e648: e2514000 subs r4, r1, #0 <== NOT EXECUTED
int mq_getattr(
mqd_t mqdes,
struct mq_attr *mqstat
)
{
a000e64c: e1a03000 mov r3, r0 <== NOT EXECUTED
POSIX_Message_queue_Control *the_mq;
POSIX_Message_queue_Control_fd *the_mq_fd;
Objects_Locations location;
CORE_message_queue_Attributes *the_mq_attr;
if ( !mqstat )
a000e650: 1a000002 bne a000e660 <mq_getattr+0x1c> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
a000e654: eb00281d bl a00186d0 <__errno> <== NOT EXECUTED
a000e658: e3a03016 mov r3, #22 <== NOT EXECUTED
a000e65c: ea000014 b a000e6b4 <mq_getattr+0x70> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *_POSIX_Message_queue_Get_fd (
mqd_t id,
Objects_Locations *location
)
{
return (POSIX_Message_queue_Control_fd *) _Objects_Get(
a000e660: e59f0058 ldr r0, [pc, #88] ; a000e6c0 <mq_getattr+0x7c> <== NOT EXECUTED
a000e664: e1a01003 mov r1, r3 <== NOT EXECUTED
a000e668: e1a0200d mov r2, sp <== NOT EXECUTED
a000e66c: eb000c7a bl a001185c <_Objects_Get> <== NOT EXECUTED
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
a000e670: e59d5000 ldr r5, [sp] <== NOT EXECUTED
a000e674: e3550000 cmp r5, #0 <== NOT EXECUTED
a000e678: 1a00000b bne a000e6ac <mq_getattr+0x68> <== NOT EXECUTED
case OBJECTS_LOCAL:
the_mq = the_mq_fd->Queue;
a000e67c: e5903010 ldr r3, [r0, #16] <== NOT EXECUTED
* Return the old values.
*/
the_mq_attr = &the_mq->Message_queue.Attributes;
mqstat->mq_flags = the_mq_fd->oflag;
a000e680: e5902014 ldr r2, [r0, #20] <== NOT EXECUTED
a000e684: e5842000 str r2, [r4] <== NOT EXECUTED
mqstat->mq_msgsize = the_mq->Message_queue.maximum_message_size;
a000e688: e5932068 ldr r2, [r3, #104] ; 0x68 <== NOT EXECUTED
a000e68c: e5842008 str r2, [r4, #8] <== NOT EXECUTED
mqstat->mq_maxmsg = the_mq->Message_queue.maximum_pending_messages;
a000e690: e5932060 ldr r2, [r3, #96] ; 0x60 <== NOT EXECUTED
mqstat->mq_curmsgs = the_mq->Message_queue.number_of_pending_messages;
a000e694: e5933064 ldr r3, [r3, #100] ; 0x64 <== NOT EXECUTED
the_mq_attr = &the_mq->Message_queue.Attributes;
mqstat->mq_flags = the_mq_fd->oflag;
mqstat->mq_msgsize = the_mq->Message_queue.maximum_message_size;
mqstat->mq_maxmsg = the_mq->Message_queue.maximum_pending_messages;
a000e698: e5842004 str r2, [r4, #4] <== NOT EXECUTED
mqstat->mq_curmsgs = the_mq->Message_queue.number_of_pending_messages;
a000e69c: e584300c str r3, [r4, #12] <== NOT EXECUTED
_Thread_Enable_dispatch();
a000e6a0: eb000f48 bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000e6a4: e1a00005 mov r0, r5 <== NOT EXECUTED
a000e6a8: ea000003 b a000e6bc <mq_getattr+0x78> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EBADF );
a000e6ac: eb002807 bl a00186d0 <__errno> <== NOT EXECUTED
a000e6b0: e3a03009 mov r3, #9 <== NOT EXECUTED
a000e6b4: e5803000 str r3, [r0] <== NOT EXECUTED
a000e6b8: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000e6bc: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a000e6e8 <mq_notify>:
int mq_notify(
mqd_t mqdes,
const struct sigevent *notification
)
{
a000e6e8: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
a000e6ec: e1a03000 mov r3, r0 <== NOT EXECUTED
a000e6f0: e1a04001 mov r4, r1 <== NOT EXECUTED
a000e6f4: e59f008c ldr r0, [pc, #140] ; a000e788 <mq_notify+0xa0> <== NOT EXECUTED
a000e6f8: e1a01003 mov r1, r3 <== NOT EXECUTED
a000e6fc: e1a0200d mov r2, sp <== NOT EXECUTED
a000e700: eb000c55 bl a001185c <_Objects_Get> <== NOT EXECUTED
POSIX_Message_queue_Control *the_mq;
POSIX_Message_queue_Control_fd *the_mq_fd;
Objects_Locations location;
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
a000e704: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a000e708: e3530000 cmp r3, #0 <== NOT EXECUTED
a000e70c: 1a000018 bne a000e774 <mq_notify+0x8c> <== NOT EXECUTED
case OBJECTS_LOCAL:
the_mq = the_mq_fd->Queue;
if ( notification ) {
a000e710: e3540000 cmp r4, #0 <== NOT EXECUTED
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
case OBJECTS_LOCAL:
the_mq = the_mq_fd->Queue;
a000e714: e590c010 ldr ip, [r0, #16] <== NOT EXECUTED
if ( notification ) {
a000e718: 0a000010 beq a000e760 <mq_notify+0x78> <== NOT EXECUTED
if ( _CORE_message_queue_Is_notify_enabled( &the_mq->Message_queue ) ) {
a000e71c: e59c307c ldr r3, [ip, #124] ; 0x7c <== NOT EXECUTED
a000e720: e3530000 cmp r3, #0 <== NOT EXECUTED
a000e724: 0a000003 beq a000e738 <mq_notify+0x50> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000e728: eb000f26 bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EBUSY );
a000e72c: eb0027e7 bl a00186d0 <__errno> <== NOT EXECUTED
a000e730: e3a03010 mov r3, #16 <== NOT EXECUTED
a000e734: ea000010 b a000e77c <mq_notify+0x94> <== NOT EXECUTED
a000e738: e58c3080 str r3, [ip, #128] ; 0x80 <== NOT EXECUTED
}
_CORE_message_queue_Set_notify( &the_mq->Message_queue, NULL, NULL );
the_mq->notification = *notification;
a000e73c: e28ce090 add lr, ip, #144 ; 0x90 <== NOT EXECUTED
a000e740: e8b4000f ldm r4!, {r0, r1, r2, r3} <== NOT EXECUTED
a000e744: e8ae000f stmia lr!, {r0, r1, r2, r3} <== NOT EXECUTED
a000e748: e5943000 ldr r3, [r4] <== NOT EXECUTED
a000e74c: e58cc080 str ip, [ip, #128] ; 0x80 <== NOT EXECUTED
a000e750: e58e3000 str r3, [lr] <== NOT EXECUTED
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Notify_Handler the_handler,
void *the_argument
)
{
the_message_queue->notify_handler = the_handler;
a000e754: e59f3030 ldr r3, [pc, #48] ; a000e78c <mq_notify+0xa4> <== NOT EXECUTED
a000e758: e58c307c str r3, [ip, #124] ; 0x7c <== NOT EXECUTED
a000e75c: ea000001 b a000e768 <mq_notify+0x80> <== NOT EXECUTED
a000e760: e58c407c str r4, [ip, #124] ; 0x7c <== NOT EXECUTED
the_message_queue->notify_argument = the_argument;
a000e764: e58c4080 str r4, [ip, #128] ; 0x80 <== NOT EXECUTED
_CORE_message_queue_Set_notify( &the_mq->Message_queue, NULL, NULL );
}
_Thread_Enable_dispatch();
a000e768: eb000f16 bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000e76c: e3a00000 mov r0, #0 <== NOT EXECUTED
a000e770: ea000003 b a000e784 <mq_notify+0x9c> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EBADF );
a000e774: eb0027d5 bl a00186d0 <__errno> <== NOT EXECUTED
a000e778: e3a03009 mov r3, #9 <== NOT EXECUTED
a000e77c: e5803000 str r3, [r0] <== NOT EXECUTED
a000e780: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000e784: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000e790 <mq_open>:
int oflag,
...
/* mode_t mode, */
/* struct mq_attr attr */
)
{
a000e790: e92d000e push {r1, r2, r3}
a000e794: e92d47ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, lr}
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000e798: e59f3164 ldr r3, [pc, #356] ; a000e904 <mq_open+0x174>
a000e79c: e59d7030 ldr r7, [sp, #48] ; 0x30
a000e7a0: e1a0a000 mov sl, r0
a000e7a4: e5932000 ldr r2, [r3]
a000e7a8: e2822001 add r2, r2, #1
a000e7ac: e5832000 str r2, [r3]
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *
_POSIX_Message_queue_Allocate_fd( void )
{
return (POSIX_Message_queue_Control_fd *)
_Objects_Allocate( &_POSIX_Message_queue_Information_fds );
a000e7b0: e59f5150 ldr r5, [pc, #336] ; a000e908 <mq_open+0x178>
POSIX_Message_queue_Control_fd *the_mq_fd;
Objects_Locations location;
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
a000e7b4: e2179c02 ands r9, r7, #512 ; 0x200
va_start(arg, oflag);
mode = (mode_t) va_arg( arg, unsigned int );
attr = (struct mq_attr *) va_arg( arg, struct mq_attr * );
a000e7b8: 128d303c addne r3, sp, #60 ; 0x3c
a000e7bc: e1a00005 mov r0, r5
a000e7c0: 158d300c strne r3, [sp, #12]
a000e7c4: 159d8038 ldrne r8, [sp, #56] ; 0x38
/* struct mq_attr attr */
)
{
va_list arg;
mode_t mode;
struct mq_attr *attr = NULL;
a000e7c8: 01a08009 moveq r8, r9
a000e7cc: eb000b01 bl a00113d8 <_Objects_Allocate>
attr = (struct mq_attr *) va_arg( arg, struct mq_attr * );
va_end(arg);
}
the_mq_fd = _POSIX_Message_queue_Allocate_fd();
if ( !the_mq_fd ) {
a000e7d0: e2504000 subs r4, r0, #0
a000e7d4: 1a000003 bne a000e7e8 <mq_open+0x58>
_Thread_Enable_dispatch();
a000e7d8: eb000efa bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENFILE );
a000e7dc: eb0027bb bl a00186d0 <__errno> <== NOT EXECUTED
a000e7e0: e3a03017 mov r3, #23 <== NOT EXECUTED
a000e7e4: ea00001a b a000e854 <mq_open+0xc4> <== NOT EXECUTED
}
the_mq_fd->oflag = oflag;
a000e7e8: e5847014 str r7, [r4, #20]
status = _POSIX_Message_queue_Name_to_id( name, &the_mq_id );
a000e7ec: e1a0000a mov r0, sl
a000e7f0: e28d1008 add r1, sp, #8
a000e7f4: eb001a49 bl a0015120 <_POSIX_Message_queue_Name_to_id>
* If the name to id translation worked, then the message queue exists
* and we can just return a pointer to the id. Otherwise we may
* need to check to see if this is a "message queue does not exist"
* or some other miscellaneous error on the name.
*/
if ( status ) {
a000e7f8: e2506000 subs r6, r0, #0
a000e7fc: 0a00000b beq a000e830 <mq_open+0xa0>
/*
* Unless provided a valid name that did not already exist
* and we are willing to create then it is an error.
*/
if ( !( status == ENOENT && (oflag & O_CREAT) ) ) {
a000e800: e3560002 cmp r6, #2
a000e804: 1a000001 bne a000e810 <mq_open+0x80>
a000e808: e3590000 cmp r9, #0
a000e80c: 1a000021 bne a000e898 <mq_open+0x108>
RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Free_fd (
POSIX_Message_queue_Control_fd *the_mq_fd
)
{
_Objects_Free( &_POSIX_Message_queue_Information_fds, &the_mq_fd->Object );
a000e810: e59f00f0 ldr r0, [pc, #240] ; a000e908 <mq_open+0x178>
a000e814: e1a01004 mov r1, r4
a000e818: eb000bb7 bl a00116fc <_Objects_Free>
_POSIX_Message_queue_Free_fd( the_mq_fd );
_Thread_Enable_dispatch();
a000e81c: eb000ee9 bl a00123c8 <_Thread_Enable_dispatch>
rtems_set_errno_and_return_minus_one_cast( status, mqd_t );
a000e820: eb0027aa bl a00186d0 <__errno>
a000e824: e5806000 str r6, [r0]
a000e828: e3e00000 mvn r0, #0
a000e82c: ea000030 b a000e8f4 <mq_open+0x164>
} else { /* name -> ID translation succeeded */
/*
* Check for existence with creation.
*/
if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {
a000e830: e2077c0a and r7, r7, #2560 ; 0xa00 <== NOT EXECUTED
a000e834: e3570c0a cmp r7, #2560 ; 0xa00 <== NOT EXECUTED
a000e838: 1a000007 bne a000e85c <mq_open+0xcc> <== NOT EXECUTED
a000e83c: e1a00005 mov r0, r5 <== NOT EXECUTED
a000e840: e1a01004 mov r1, r4 <== NOT EXECUTED
a000e844: eb000bac bl a00116fc <_Objects_Free> <== NOT EXECUTED
_POSIX_Message_queue_Free_fd( the_mq_fd );
_Thread_Enable_dispatch();
a000e848: eb000ede bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one_cast( EEXIST, mqd_t );
a000e84c: eb00279f bl a00186d0 <__errno> <== NOT EXECUTED
a000e850: e3a03011 mov r3, #17 <== NOT EXECUTED
a000e854: e5803000 str r3, [r0] <== NOT EXECUTED
a000e858: eafffff2 b a000e828 <mq_open+0x98> <== NOT EXECUTED
Objects_Id id,
Objects_Locations *location
)
{
return (POSIX_Message_queue_Control *)
_Objects_Get( &_POSIX_Message_queue_Information, id, location );
a000e85c: e1a0200d mov r2, sp <== NOT EXECUTED
a000e860: e59d1008 ldr r1, [sp, #8] <== NOT EXECUTED
a000e864: e59f00a0 ldr r0, [pc, #160] ; a000e90c <mq_open+0x17c> <== NOT EXECUTED
a000e868: eb000bfb bl a001185c <_Objects_Get> <== NOT EXECUTED
/*
* In this case we need to do an ID->pointer conversion to
* check the mode.
*/
the_mq = _POSIX_Message_queue_Get( the_mq_id, &location );
the_mq->open_count += 1;
a000e86c: e5903018 ldr r3, [r0, #24] <== NOT EXECUTED
Objects_Information *information,
Objects_Control *the_object,
const char *name
)
{
_Objects_Set_local_object(
a000e870: e1d420b8 ldrh r2, [r4, #8] <== NOT EXECUTED
/*
* In this case we need to do an ID->pointer conversion to
* check the mode.
*/
the_mq = _POSIX_Message_queue_Get( the_mq_id, &location );
a000e874: e58d0004 str r0, [sp, #4] <== NOT EXECUTED
the_mq->open_count += 1;
a000e878: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000e87c: e5803018 str r3, [r0, #24] <== NOT EXECUTED
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000e880: e595301c ldr r3, [r5, #28] <== NOT EXECUTED
the_mq_fd->Queue = the_mq;
a000e884: e5840010 str r0, [r4, #16] <== NOT EXECUTED
a000e888: e7834102 str r4, [r3, r2, lsl #2] <== NOT EXECUTED
the_object
);
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
/* ASSERT: information->is_string */
the_object->name.name_p = name;
a000e88c: e584600c str r6, [r4, #12] <== NOT EXECUTED
_Objects_Open_string(
&_POSIX_Message_queue_Information_fds,
&the_mq_fd->Object,
NULL
);
_Thread_Enable_dispatch();
a000e890: eb000ecc bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
a000e894: ea000014 b a000e8ec <mq_open+0x15c> <== NOT EXECUTED
/*
* At this point, the message queue does not exist and everything has been
* checked. We should go ahead and create a message queue.
*/
status = _POSIX_Message_queue_Create_support(
a000e898: e1a0000a mov r0, sl
a000e89c: e3a01001 mov r1, #1
a000e8a0: e1a02008 mov r2, r8
a000e8a4: e28d3004 add r3, sp, #4
a000e8a8: eb0019c7 bl a0014fcc <_POSIX_Message_queue_Create_support>
);
/*
* errno was set by Create_support, so don't set it again.
*/
if ( status == -1 ) {
a000e8ac: e3700001 cmn r0, #1
/*
* At this point, the message queue does not exist and everything has been
* checked. We should go ahead and create a message queue.
*/
status = _POSIX_Message_queue_Create_support(
a000e8b0: e1a06000 mov r6, r0
);
/*
* errno was set by Create_support, so don't set it again.
*/
if ( status == -1 ) {
a000e8b4: 1a000005 bne a000e8d0 <mq_open+0x140>
RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Free_fd (
POSIX_Message_queue_Control_fd *the_mq_fd
)
{
_Objects_Free( &_POSIX_Message_queue_Information_fds, &the_mq_fd->Object );
a000e8b8: e1a00005 mov r0, r5
a000e8bc: e1a01004 mov r1, r4
a000e8c0: eb000b8d bl a00116fc <_Objects_Free>
_POSIX_Message_queue_Free_fd( the_mq_fd );
_Thread_Enable_dispatch();
a000e8c4: eb000ebf bl a00123c8 <_Thread_Enable_dispatch>
return (mqd_t) -1;
a000e8c8: e1a00006 mov r0, r6
a000e8cc: ea000008 b a000e8f4 <mq_open+0x164>
}
the_mq_fd->Queue = the_mq;
a000e8d0: e59d3004 ldr r3, [sp, #4]
Objects_Information *information,
Objects_Control *the_object,
const char *name
)
{
_Objects_Set_local_object(
a000e8d4: e1d420b8 ldrh r2, [r4, #8]
a000e8d8: e5843010 str r3, [r4, #16]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000e8dc: e595301c ldr r3, [r5, #28]
a000e8e0: e7834102 str r4, [r3, r2, lsl #2]
the_object
);
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
/* ASSERT: information->is_string */
the_object->name.name_p = name;
a000e8e4: e3a03000 mov r3, #0
a000e8e8: e584300c str r3, [r4, #12]
&_POSIX_Message_queue_Information_fds,
&the_mq_fd->Object,
NULL
);
_Thread_Enable_dispatch();
a000e8ec: eb000eb5 bl a00123c8 <_Thread_Enable_dispatch>
return (mqd_t) the_mq_fd->Object.id;
a000e8f0: e5940008 ldr r0, [r4, #8]
}
a000e8f4: e28dd010 add sp, sp, #16
a000e8f8: e8bd47f0 pop {r4, r5, r6, r7, r8, r9, sl, lr}
a000e8fc: e28dd00c add sp, sp, #12
a000e900: e12fff1e bx lr
a000e910 <mq_receive>:
mqd_t mqdes,
char *msg_ptr,
size_t msg_len,
unsigned int *msg_prio
)
{
a000e910: e92d4003 push {r0, r1, lr} <== NOT EXECUTED
return _POSIX_Message_queue_Receive_support(
a000e914: e3a0c001 mov ip, #1 <== NOT EXECUTED
a000e918: e58dc000 str ip, [sp] <== NOT EXECUTED
a000e91c: e3a0c000 mov ip, #0 <== NOT EXECUTED
a000e920: e58dc004 str ip, [sp, #4] <== NOT EXECUTED
a000e924: eb000000 bl a000e92c <_POSIX_Message_queue_Receive_support><== NOT EXECUTED
msg_len,
msg_prio,
true,
THREAD_QUEUE_WAIT_FOREVER
);
}
a000e928: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED
a000eb58 <mq_setattr>:
int mq_setattr(
mqd_t mqdes,
const struct mq_attr *mqstat,
struct mq_attr *omqstat
)
{
a000eb58: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
POSIX_Message_queue_Control_fd *the_mq_fd;
CORE_message_queue_Control *the_core_mq;
Objects_Locations location;
if ( !mqstat )
a000eb5c: e2515000 subs r5, r1, #0 <== NOT EXECUTED
int mq_setattr(
mqd_t mqdes,
const struct mq_attr *mqstat,
struct mq_attr *omqstat
)
{
a000eb60: e1a03000 mov r3, r0 <== NOT EXECUTED
a000eb64: e1a04002 mov r4, r2 <== NOT EXECUTED
POSIX_Message_queue_Control_fd *the_mq_fd;
CORE_message_queue_Control *the_core_mq;
Objects_Locations location;
if ( !mqstat )
a000eb68: 1a000002 bne a000eb78 <mq_setattr+0x20> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
a000eb6c: eb0026d7 bl a00186d0 <__errno> <== NOT EXECUTED
a000eb70: e3a03016 mov r3, #22 <== NOT EXECUTED
a000eb74: ea000018 b a000ebdc <mq_setattr+0x84> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *_POSIX_Message_queue_Get_fd (
mqd_t id,
Objects_Locations *location
)
{
return (POSIX_Message_queue_Control_fd *) _Objects_Get(
a000eb78: e1a01003 mov r1, r3 <== NOT EXECUTED
a000eb7c: e59f0064 ldr r0, [pc, #100] ; a000ebe8 <mq_setattr+0x90> <== NOT EXECUTED
a000eb80: e1a0200d mov r2, sp <== NOT EXECUTED
a000eb84: eb000b34 bl a001185c <_Objects_Get> <== NOT EXECUTED
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
a000eb88: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a000eb8c: e3530000 cmp r3, #0 <== NOT EXECUTED
a000eb90: 1a00000f bne a000ebd4 <mq_setattr+0x7c> <== NOT EXECUTED
/*
* Return the old values.
*/
if ( omqstat ) {
a000eb94: e3540000 cmp r4, #0 <== NOT EXECUTED
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
case OBJECTS_LOCAL:
the_core_mq = &the_mq_fd->Queue->Message_queue;
a000eb98: e5903010 ldr r3, [r0, #16] <== NOT EXECUTED
/*
* Return the old values.
*/
if ( omqstat ) {
a000eb9c: 0a000007 beq a000ebc0 <mq_setattr+0x68> <== NOT EXECUTED
omqstat->mq_flags = the_mq_fd->oflag;
a000eba0: e5902014 ldr r2, [r0, #20] <== NOT EXECUTED
a000eba4: e5842000 str r2, [r4] <== NOT EXECUTED
omqstat->mq_msgsize = the_core_mq->maximum_message_size;
a000eba8: e5932068 ldr r2, [r3, #104] ; 0x68 <== NOT EXECUTED
a000ebac: e5842008 str r2, [r4, #8] <== NOT EXECUTED
omqstat->mq_maxmsg = the_core_mq->maximum_pending_messages;
a000ebb0: e5932060 ldr r2, [r3, #96] ; 0x60 <== NOT EXECUTED
omqstat->mq_curmsgs = the_core_mq->number_of_pending_messages;
a000ebb4: e5933064 ldr r3, [r3, #100] ; 0x64 <== NOT EXECUTED
*/
if ( omqstat ) {
omqstat->mq_flags = the_mq_fd->oflag;
omqstat->mq_msgsize = the_core_mq->maximum_message_size;
omqstat->mq_maxmsg = the_core_mq->maximum_pending_messages;
a000ebb8: e5842004 str r2, [r4, #4] <== NOT EXECUTED
omqstat->mq_curmsgs = the_core_mq->number_of_pending_messages;
a000ebbc: e584300c str r3, [r4, #12] <== NOT EXECUTED
}
the_mq_fd->oflag = mqstat->mq_flags;
a000ebc0: e5953000 ldr r3, [r5] <== NOT EXECUTED
a000ebc4: e5803014 str r3, [r0, #20] <== NOT EXECUTED
_Thread_Enable_dispatch();
a000ebc8: eb000dfe bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000ebcc: e3a00000 mov r0, #0 <== NOT EXECUTED
a000ebd0: ea000003 b a000ebe4 <mq_setattr+0x8c> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EBADF );
a000ebd4: eb0026bd bl a00186d0 <__errno> <== NOT EXECUTED
a000ebd8: e3a03009 mov r3, #9 <== NOT EXECUTED
a000ebdc: e5803000 str r3, [r0] <== NOT EXECUTED
a000ebe0: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000ebe4: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a000ebec <mq_timedreceive>:
char *msg_ptr,
size_t msg_len,
unsigned int *msg_prio,
const struct timespec *abstime
)
{
a000ebec: e92d40f7 push {r0, r1, r2, r4, r5, r6, r7, lr} <== NOT EXECUTED
a000ebf0: e1a05000 mov r5, r0 <== NOT EXECUTED
a000ebf4: e1a04001 mov r4, r1 <== NOT EXECUTED
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
a000ebf8: e59d0020 ldr r0, [sp, #32] <== NOT EXECUTED
a000ebfc: e28d1008 add r1, sp, #8 <== NOT EXECUTED
char *msg_ptr,
size_t msg_len,
unsigned int *msg_prio,
const struct timespec *abstime
)
{
a000ec00: e1a06003 mov r6, r3 <== NOT EXECUTED
a000ec04: e1a07002 mov r7, r2 <== NOT EXECUTED
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
a000ec08: eb00003d bl a000ed04 <_POSIX_Absolute_timeout_to_ticks> <== NOT EXECUTED
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
return _POSIX_Message_queue_Receive_support(
a000ec0c: e59d3008 ldr r3, [sp, #8] <== NOT EXECUTED
a000ec10: e3500003 cmp r0, #3 <== NOT EXECUTED
a000ec14: 13a00000 movne r0, #0 <== NOT EXECUTED
a000ec18: 03a00001 moveq r0, #1 <== NOT EXECUTED
a000ec1c: e88d0009 stm sp, {r0, r3} <== NOT EXECUTED
a000ec20: e1a00005 mov r0, r5 <== NOT EXECUTED
a000ec24: e1a01004 mov r1, r4 <== NOT EXECUTED
a000ec28: e1a02007 mov r2, r7 <== NOT EXECUTED
a000ec2c: e1a03006 mov r3, r6 <== NOT EXECUTED
a000ec30: ebffff3d bl a000e92c <_POSIX_Message_queue_Receive_support><== NOT EXECUTED
msg_len,
msg_prio,
do_wait,
ticks
);
}
a000ec34: e8bd80fe pop {r1, r2, r3, r4, r5, r6, r7, pc} <== NOT EXECUTED
a000ec38 <mq_timedsend>:
const char *msg_ptr,
size_t msg_len,
unsigned int msg_prio,
const struct timespec *abstime
)
{
a000ec38: e92d40f7 push {r0, r1, r2, r4, r5, r6, r7, lr} <== NOT EXECUTED
a000ec3c: e1a05000 mov r5, r0 <== NOT EXECUTED
a000ec40: e1a04001 mov r4, r1 <== NOT EXECUTED
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
a000ec44: e59d0020 ldr r0, [sp, #32] <== NOT EXECUTED
a000ec48: e28d1008 add r1, sp, #8 <== NOT EXECUTED
const char *msg_ptr,
size_t msg_len,
unsigned int msg_prio,
const struct timespec *abstime
)
{
a000ec4c: e1a06003 mov r6, r3 <== NOT EXECUTED
a000ec50: e1a07002 mov r7, r2 <== NOT EXECUTED
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
a000ec54: eb00002a bl a000ed04 <_POSIX_Absolute_timeout_to_ticks> <== NOT EXECUTED
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
return _POSIX_Message_queue_Send_support(
a000ec58: e59d3008 ldr r3, [sp, #8] <== NOT EXECUTED
a000ec5c: e3500003 cmp r0, #3 <== NOT EXECUTED
a000ec60: 13a00000 movne r0, #0 <== NOT EXECUTED
a000ec64: 03a00001 moveq r0, #1 <== NOT EXECUTED
a000ec68: e88d0009 stm sp, {r0, r3} <== NOT EXECUTED
a000ec6c: e1a00005 mov r0, r5 <== NOT EXECUTED
a000ec70: e1a01004 mov r1, r4 <== NOT EXECUTED
a000ec74: e1a02007 mov r2, r7 <== NOT EXECUTED
a000ec78: e1a03006 mov r3, r6 <== NOT EXECUTED
a000ec7c: ebffff75 bl a000ea58 <_POSIX_Message_queue_Send_support> <== NOT EXECUTED
msg_len,
msg_prio,
do_wait,
ticks
);
}
a000ec80: e8bd80fe pop {r1, r2, r3, r4, r5, r6, r7, pc} <== NOT EXECUTED
a000ec94 <mq_unlink>:
a000ec94: e59f3060 ldr r3, [pc, #96] ; a000ecfc <mq_unlink+0x68>
*/
int mq_unlink(
const char *name
)
{
a000ec98: e92d4031 push {r0, r4, r5, lr}
a000ec9c: e5932000 ldr r2, [r3]
a000eca0: e2822001 add r2, r2, #1
a000eca4: e5832000 str r2, [r3]
register POSIX_Message_queue_Control *the_mq;
Objects_Id the_mq_id;
_Thread_Disable_dispatch();
status = _POSIX_Message_queue_Name_to_id( name, &the_mq_id );
a000eca8: e1a0100d mov r1, sp
a000ecac: eb00191b bl a0015120 <_POSIX_Message_queue_Name_to_id>
if ( status != 0 ) {
a000ecb0: e2504000 subs r4, r0, #0
a000ecb4: 0a000004 beq a000eccc <mq_unlink+0x38>
_Thread_Enable_dispatch();
a000ecb8: eb000dc2 bl a00123c8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( status );
a000ecbc: eb002683 bl a00186d0 <__errno> <== NOT EXECUTED
a000ecc0: e5804000 str r4, [r0] <== NOT EXECUTED
a000ecc4: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000ecc8: ea00000a b a000ecf8 <mq_unlink+0x64> <== NOT EXECUTED
_POSIX_Message_queue_Namespace_remove( the_mq );
_POSIX_Message_queue_Delete( the_mq );
_Thread_Enable_dispatch();
return 0;
}
a000eccc: e59f002c ldr r0, [pc, #44] ; a000ed00 <mq_unlink+0x6c>
*/
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return NULL;
#endif
return information->local_table[ index ];
a000ecd0: e1dd20b0 ldrh r2, [sp]
a000ecd4: e590301c ldr r3, [r0, #28]
if ( status != 0 ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( status );
}
the_mq = (POSIX_Message_queue_Control *) _Objects_Get_local_object(
a000ecd8: e7935102 ldr r5, [r3, r2, lsl #2]
RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Namespace_remove (
POSIX_Message_queue_Control *the_mq
)
{
_Objects_Namespace_remove(
a000ecdc: e1a01005 mov r1, r5
&_POSIX_Message_queue_Information,
_Objects_Get_index( the_mq_id )
);
the_mq->linked = false;
a000ece0: e5c54015 strb r4, [r5, #21]
a000ece4: eb000b2e bl a00119a4 <_Objects_Namespace_remove>
_POSIX_Message_queue_Namespace_remove( the_mq );
_POSIX_Message_queue_Delete( the_mq );
a000ece8: e1a00005 mov r0, r5
a000ecec: ebfffe3f bl a000e5f0 <_POSIX_Message_queue_Delete>
_Thread_Enable_dispatch();
a000ecf0: eb000db4 bl a00123c8 <_Thread_Enable_dispatch>
return 0;
a000ecf4: e1a00004 mov r0, r4
}
a000ecf8: e8bd8038 pop {r3, r4, r5, pc}
a001de64 <nanosleep>:
int nanosleep(
const struct timespec *rqtp,
struct timespec *rmtp
)
{
a001de64: e92d4070 push {r4, r5, r6, lr}
a001de68: e1a05000 mov r5, r0
a001de6c: e1a04001 mov r4, r1
* Return EINVAL if the delay interval is negative.
*
* NOTE: This behavior is beyond the POSIX specification.
* FSU and GNU/Linux pthreads shares this behavior.
*/
if ( !_Timespec_Is_valid( rqtp ) )
a001de70: eb00005d bl a001dfec <_Timespec_Is_valid>
a001de74: e3500000 cmp r0, #0
a001de78: 1a000002 bne a001de88 <nanosleep+0x24>
rtems_set_errno_and_return_minus_one( EINVAL );
a001de7c: ebffcdba bl a001156c <__errno>
a001de80: e3a03016 mov r3, #22
a001de84: ea00002d b a001df40 <nanosleep+0xdc>
ticks = _Timespec_To_ticks( rqtp );
a001de88: e1a00005 mov r0, r5
a001de8c: ebffc739 bl a000fb78 <_Timespec_To_ticks>
* A nanosleep for zero time is implemented as a yield.
* This behavior is also beyond the POSIX specification but is
* consistent with the RTEMS API and yields desirable behavior.
*/
if ( !ticks ) {
a001de90: e2505000 subs r5, r0, #0
a001de94: 1a000009 bne a001dec0 <nanosleep+0x5c>
_Thread_Disable_dispatch();
a001de98: ebffffeb bl a001de4c <_Thread_Disable_dispatch> <== NOT EXECUTED
* always operates on the scheduler that 'owns' the currently executing
* thread.
*/
RTEMS_INLINE_ROUTINE void _Scheduler_Yield( void )
{
_Scheduler.Operations.yield( &_Scheduler );
a001de9c: e59f00b4 ldr r0, [pc, #180] ; a001df58 <nanosleep+0xf4> <== NOT EXECUTED
a001dea0: e5903008 ldr r3, [r0, #8] <== NOT EXECUTED
a001dea4: e12fff33 blx r3 <== NOT EXECUTED
_Scheduler_Yield();
_Thread_Enable_dispatch();
a001dea8: ebffb6ec bl a000ba60 <_Thread_Enable_dispatch> <== NOT EXECUTED
if ( rmtp ) {
a001deac: e3540000 cmp r4, #0 <== NOT EXECUTED
rmtp->tv_sec = 0;
a001deb0: 15845000 strne r5, [r4] <== NOT EXECUTED
rmtp->tv_nsec = 0;
a001deb4: 15845004 strne r5, [r4, #4] <== NOT EXECUTED
if ( !ticks ) {
_Thread_Disable_dispatch();
_Scheduler_Yield();
_Thread_Enable_dispatch();
if ( rmtp ) {
a001deb8: 1a000024 bne a001df50 <nanosleep+0xec> <== NOT EXECUTED
a001debc: ea000022 b a001df4c <nanosleep+0xe8> <== NOT EXECUTED
/*
* Block for the desired amount of time
*/
_Thread_Disable_dispatch();
_Thread_Set_state(
a001dec0: e59f6094 ldr r6, [pc, #148] ; a001df5c <nanosleep+0xf8>
}
/*
* Block for the desired amount of time
*/
_Thread_Disable_dispatch();
a001dec4: ebffffe0 bl a001de4c <_Thread_Disable_dispatch>
_Thread_Set_state(
a001dec8: e5960004 ldr r0, [r6, #4]
a001decc: e3a01281 mov r1, #268435464 ; 0x10000008
a001ded0: ebffb8f7 bl a000c2b4 <_Thread_Set_state>
_Thread_Executing,
STATES_DELAYING | STATES_INTERRUPTIBLE_BY_SIGNAL
);
_Watchdog_Initialize(
&_Thread_Executing->Timer,
a001ded4: e5961004 ldr r1, [r6, #4]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a001ded8: e59f0080 ldr r0, [pc, #128] ; a001df60 <nanosleep+0xfc>
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a001dedc: e3a03000 mov r3, #0
_Thread_Disable_dispatch();
_Thread_Set_state(
_Thread_Executing,
STATES_DELAYING | STATES_INTERRUPTIBLE_BY_SIGNAL
);
_Watchdog_Initialize(
a001dee0: e5912008 ldr r2, [r1, #8]
a001dee4: e5813050 str r3, [r1, #80] ; 0x50
the_watchdog->routine = routine;
a001dee8: e5810064 str r0, [r1, #100] ; 0x64
the_watchdog->id = id;
a001deec: e5812068 str r2, [r1, #104] ; 0x68
the_watchdog->user_data = user_data;
a001def0: e581306c str r3, [r1, #108] ; 0x6c
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a001def4: e5815054 str r5, [r1, #84] ; 0x54
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a001def8: e59f0064 ldr r0, [pc, #100] ; a001df64 <nanosleep+0x100>
a001defc: e2811048 add r1, r1, #72 ; 0x48
a001df00: ebffba86 bl a000c920 <_Watchdog_Insert>
_Thread_Delay_ended,
_Thread_Executing->Object.id,
NULL
);
_Watchdog_Insert_ticks( &_Thread_Executing->Timer, ticks );
_Thread_Enable_dispatch();
a001df04: ebffb6d5 bl a000ba60 <_Thread_Enable_dispatch>
/* calculate time remaining */
if ( rmtp ) {
a001df08: e3540000 cmp r4, #0 <== NOT EXECUTED
a001df0c: 0a00000e beq a001df4c <nanosleep+0xe8> <== NOT EXECUTED
ticks -=
_Thread_Executing->Timer.stop_time - _Thread_Executing->Timer.start_time;
a001df10: e5963004 ldr r3, [r6, #4] <== NOT EXECUTED
_Timespec_From_ticks( ticks, rmtp );
a001df14: e1a01004 mov r1, r4 <== NOT EXECUTED
/* calculate time remaining */
if ( rmtp ) {
ticks -=
_Thread_Executing->Timer.stop_time - _Thread_Executing->Timer.start_time;
a001df18: e593205c ldr r2, [r3, #92] ; 0x5c <== NOT EXECUTED
a001df1c: e5933060 ldr r3, [r3, #96] ; 0x60 <== NOT EXECUTED
a001df20: e0633002 rsb r3, r3, r2 <== NOT EXECUTED
_Thread_Enable_dispatch();
/* calculate time remaining */
if ( rmtp ) {
ticks -=
a001df24: e0835005 add r5, r3, r5 <== NOT EXECUTED
_Thread_Executing->Timer.stop_time - _Thread_Executing->Timer.start_time;
_Timespec_From_ticks( ticks, rmtp );
a001df28: e1a00005 mov r0, r5 <== NOT EXECUTED
a001df2c: eb00001c bl a001dfa4 <_Timespec_From_ticks> <== NOT EXECUTED
*/
#if defined(RTEMS_POSIX_API)
/*
* If there is time remaining, then we were interrupted by a signal.
*/
if ( ticks )
a001df30: e3550000 cmp r5, #0 <== NOT EXECUTED
a001df34: 0a000005 beq a001df50 <nanosleep+0xec> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINTR );
a001df38: ebffcd8b bl a001156c <__errno> <== NOT EXECUTED
a001df3c: e3a03004 mov r3, #4 <== NOT EXECUTED
a001df40: e5803000 str r3, [r0] <== NOT EXECUTED
a001df44: e3e05000 mvn r5, #0 <== NOT EXECUTED
a001df48: ea000000 b a001df50 <nanosleep+0xec> <== NOT EXECUTED
#endif
}
return 0;
a001df4c: e1a05004 mov r5, r4 <== NOT EXECUTED
}
a001df50: e1a00005 mov r0, r5 <== NOT EXECUTED
a001df54: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
a000b3a4 <pause>:
/*
* 3.4.2 Suspend Process Execution, P1003.1b-1993, p. 81
*/
int pause( void )
{
a000b3a4: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
sigset_t all_signals;
int status;
(void) sigfillset( &all_signals );
a000b3a8: e1a0000d mov r0, sp <== NOT EXECUTED
a000b3ac: eb000327 bl a000c050 <sigfillset> <== NOT EXECUTED
status = sigtimedwait( &all_signals, NULL, NULL );
a000b3b0: e3a01000 mov r1, #0 <== NOT EXECUTED
a000b3b4: e1a0000d mov r0, sp <== NOT EXECUTED
a000b3b8: e1a02001 mov r2, r1 <== NOT EXECUTED
int pause( void )
{
sigset_t all_signals;
int status;
(void) sigfillset( &all_signals );
a000b3bc: e1a0400d mov r4, sp <== NOT EXECUTED
status = sigtimedwait( &all_signals, NULL, NULL );
a000b3c0: eb000388 bl a000c1e8 <sigtimedwait> <== NOT EXECUTED
return status;
}
a000b3c4: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a0009288 <pthread_atfork>:
int pthread_atfork(
void (*prepare)(void) __attribute__((unused)),
void (*parent)(void) __attribute__((unused)),
void (*child)(void) __attribute__((unused))
)
{
a0009288: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a000928c: eb0021da bl a00119fc <__errno> <== NOT EXECUTED
a0009290: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a0009294: e5803000 str r3, [r0] <== NOT EXECUTED
}
a0009298: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000929c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a000eb8c <pthread_attr_getcputime>:
int pthread_attr_getcputime(
pthread_attr_t *attr,
int *clock_allowed
)
{
if ( !attr || !attr->is_initialized || !clock_allowed )
a000eb8c: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000eb90: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_getcputime(
pthread_attr_t *attr,
int *clock_allowed
)
{
if ( !attr || !attr->is_initialized || !clock_allowed )
a000eb94: 012fff1e bxeq lr <== NOT EXECUTED
a000eb98: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000eb9c: e3500000 cmp r0, #0 <== NOT EXECUTED
a000eba0: 13510000 cmpne r1, #0 <== NOT EXECUTED
return EINVAL;
*clock_allowed = attr->cputime_clock_allowed;
a000eba4: 15933038 ldrne r3, [r3, #56] ; 0x38 <== NOT EXECUTED
int pthread_attr_getcputime(
pthread_attr_t *attr,
int *clock_allowed
)
{
if ( !attr || !attr->is_initialized || !clock_allowed )
a000eba8: 13a00000 movne r0, #0 <== NOT EXECUTED
a000ebac: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a000ebb0: 03a00016 moveq r0, #22 <== NOT EXECUTED
*clock_allowed = attr->cputime_clock_allowed;
a000ebb4: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000ebb8: e12fff1e bx lr <== NOT EXECUTED
a000e45c <pthread_attr_getdetachstate>:
int pthread_attr_getdetachstate(
const pthread_attr_t *attr,
int *detachstate
)
{
if ( !attr || !attr->is_initialized || !detachstate )
a000e45c: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000e460: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_getdetachstate(
const pthread_attr_t *attr,
int *detachstate
)
{
if ( !attr || !attr->is_initialized || !detachstate )
a000e464: 012fff1e bxeq lr <== NOT EXECUTED
a000e468: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000e46c: e3500000 cmp r0, #0 <== NOT EXECUTED
a000e470: 13510000 cmpne r1, #0 <== NOT EXECUTED
return EINVAL;
*detachstate = attr->detachstate;
a000e474: 1593303c ldrne r3, [r3, #60] ; 0x3c <== NOT EXECUTED
int pthread_attr_getdetachstate(
const pthread_attr_t *attr,
int *detachstate
)
{
if ( !attr || !attr->is_initialized || !detachstate )
a000e478: 13a00000 movne r0, #0 <== NOT EXECUTED
a000e47c: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a000e480: 03a00016 moveq r0, #22 <== NOT EXECUTED
*detachstate = attr->detachstate;
a000e484: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000e488: e12fff1e bx lr <== NOT EXECUTED
a000e48c <pthread_attr_getguardsize>:
int pthread_attr_getguardsize(
const pthread_attr_t *attr,
size_t *guardsize
)
{
if ( !attr || !attr->is_initialized || !guardsize )
a000e48c: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000e490: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_getguardsize(
const pthread_attr_t *attr,
size_t *guardsize
)
{
if ( !attr || !attr->is_initialized || !guardsize )
a000e494: 012fff1e bxeq lr <== NOT EXECUTED
a000e498: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000e49c: e3500000 cmp r0, #0 <== NOT EXECUTED
a000e4a0: 13510000 cmpne r1, #0 <== NOT EXECUTED
return EINVAL;
*guardsize = attr->guardsize;
a000e4a4: 15933034 ldrne r3, [r3, #52] ; 0x34 <== NOT EXECUTED
int pthread_attr_getguardsize(
const pthread_attr_t *attr,
size_t *guardsize
)
{
if ( !attr || !attr->is_initialized || !guardsize )
a000e4a8: 13a00000 movne r0, #0 <== NOT EXECUTED
a000e4ac: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a000e4b0: 03a00016 moveq r0, #22 <== NOT EXECUTED
*guardsize = attr->guardsize;
a000e4b4: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000e4b8: e12fff1e bx lr <== NOT EXECUTED
a000e4bc <pthread_attr_getinheritsched>:
int pthread_attr_getinheritsched(
const pthread_attr_t *attr,
int *inheritsched
)
{
if ( !attr || !attr->is_initialized || !inheritsched )
a000e4bc: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000e4c0: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_getinheritsched(
const pthread_attr_t *attr,
int *inheritsched
)
{
if ( !attr || !attr->is_initialized || !inheritsched )
a000e4c4: 012fff1e bxeq lr <== NOT EXECUTED
a000e4c8: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000e4cc: e3500000 cmp r0, #0 <== NOT EXECUTED
a000e4d0: 13510000 cmpne r1, #0 <== NOT EXECUTED
return EINVAL;
*inheritsched = attr->inheritsched;
a000e4d4: 15933010 ldrne r3, [r3, #16] <== NOT EXECUTED
int pthread_attr_getinheritsched(
const pthread_attr_t *attr,
int *inheritsched
)
{
if ( !attr || !attr->is_initialized || !inheritsched )
a000e4d8: 13a00000 movne r0, #0 <== NOT EXECUTED
a000e4dc: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a000e4e0: 03a00016 moveq r0, #22 <== NOT EXECUTED
*inheritsched = attr->inheritsched;
a000e4e4: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000e4e8: e12fff1e bx lr <== NOT EXECUTED
a000e4ec <pthread_attr_getschedparam>:
int pthread_attr_getschedparam(
const pthread_attr_t *attr,
struct sched_param *param
)
{
if ( !attr || !attr->is_initialized || !param )
a000e4ec: e3500000 cmp r0, #0 <== NOT EXECUTED
int pthread_attr_getschedparam(
const pthread_attr_t *attr,
struct sched_param *param
)
{
a000e4f0: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
a000e4f4: e1a04001 mov r4, r1 <== NOT EXECUTED
if ( !attr || !attr->is_initialized || !param )
a000e4f8: 0a00000c beq a000e530 <pthread_attr_getschedparam+0x44> <== NOT EXECUTED
a000e4fc: e5905000 ldr r5, [r0] <== NOT EXECUTED
a000e500: e3550000 cmp r5, #0 <== NOT EXECUTED
a000e504: 13510000 cmpne r1, #0 <== NOT EXECUTED
a000e508: 13a05000 movne r5, #0 <== NOT EXECUTED
a000e50c: 03a05001 moveq r5, #1 <== NOT EXECUTED
a000e510: 0a000008 beq a000e538 <pthread_attr_getschedparam+0x4c> <== NOT EXECUTED
return EINVAL;
*param = attr->schedparam;
a000e514: e280c018 add ip, r0, #24 <== NOT EXECUTED
a000e518: e8bc000f ldm ip!, {r0, r1, r2, r3} <== NOT EXECUTED
a000e51c: e8a4000f stmia r4!, {r0, r1, r2, r3} <== NOT EXECUTED
a000e520: e89c0007 ldm ip, {r0, r1, r2} <== NOT EXECUTED
a000e524: e8840007 stm r4, {r0, r1, r2} <== NOT EXECUTED
return 0;
a000e528: e1a00005 mov r0, r5 <== NOT EXECUTED
a000e52c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
const pthread_attr_t *attr,
struct sched_param *param
)
{
if ( !attr || !attr->is_initialized || !param )
return EINVAL;
a000e530: e3a00016 mov r0, #22 <== NOT EXECUTED
a000e534: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000e538: e3a00016 mov r0, #22 <== NOT EXECUTED
*param = attr->schedparam;
return 0;
}
a000e53c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000e540 <pthread_attr_getschedpolicy>:
int pthread_attr_getschedpolicy(
const pthread_attr_t *attr,
int *policy
)
{
if ( !attr || !attr->is_initialized || !policy )
a000e540: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000e544: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_getschedpolicy(
const pthread_attr_t *attr,
int *policy
)
{
if ( !attr || !attr->is_initialized || !policy )
a000e548: 012fff1e bxeq lr <== NOT EXECUTED
a000e54c: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000e550: e3500000 cmp r0, #0 <== NOT EXECUTED
a000e554: 13510000 cmpne r1, #0 <== NOT EXECUTED
return EINVAL;
*policy = attr->schedpolicy;
a000e558: 15933014 ldrne r3, [r3, #20] <== NOT EXECUTED
int pthread_attr_getschedpolicy(
const pthread_attr_t *attr,
int *policy
)
{
if ( !attr || !attr->is_initialized || !policy )
a000e55c: 13a00000 movne r0, #0 <== NOT EXECUTED
a000e560: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a000e564: 03a00016 moveq r0, #22 <== NOT EXECUTED
*policy = attr->schedpolicy;
a000e568: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000e56c: e12fff1e bx lr <== NOT EXECUTED
a000e570 <pthread_attr_getscope>:
int pthread_attr_getscope(
const pthread_attr_t *attr,
int *contentionscope
)
{
if ( !attr || !attr->is_initialized || !contentionscope )
a000e570: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000e574: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_getscope(
const pthread_attr_t *attr,
int *contentionscope
)
{
if ( !attr || !attr->is_initialized || !contentionscope )
a000e578: 012fff1e bxeq lr <== NOT EXECUTED
a000e57c: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000e580: e3500000 cmp r0, #0 <== NOT EXECUTED
a000e584: 13510000 cmpne r1, #0 <== NOT EXECUTED
return EINVAL;
*contentionscope = attr->contentionscope;
a000e588: 1593300c ldrne r3, [r3, #12] <== NOT EXECUTED
int pthread_attr_getscope(
const pthread_attr_t *attr,
int *contentionscope
)
{
if ( !attr || !attr->is_initialized || !contentionscope )
a000e58c: 13a00000 movne r0, #0 <== NOT EXECUTED
a000e590: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a000e594: 03a00016 moveq r0, #22 <== NOT EXECUTED
*contentionscope = attr->contentionscope;
a000e598: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000e59c: e12fff1e bx lr <== NOT EXECUTED
a000e5d0 <pthread_attr_getstack>:
const pthread_attr_t *attr,
void **stackaddr,
size_t *stacksize
)
{
if ( !attr || !attr->is_initialized || !stackaddr || !stacksize )
a000e5d0: e2503000 subs r3, r0, #0 <== NOT EXECUTED
a000e5d4: 0a00000c beq a000e60c <pthread_attr_getstack+0x3c> <== NOT EXECUTED
a000e5d8: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000e5dc: e3500000 cmp r0, #0 <== NOT EXECUTED
a000e5e0: 13510000 cmpne r1, #0 <== NOT EXECUTED
a000e5e4: 13a00000 movne r0, #0 <== NOT EXECUTED
a000e5e8: 03a00001 moveq r0, #1 <== NOT EXECUTED
a000e5ec: 0a000006 beq a000e60c <pthread_attr_getstack+0x3c> <== NOT EXECUTED
a000e5f0: e3520000 cmp r2, #0 <== NOT EXECUTED
a000e5f4: 0a000006 beq a000e614 <pthread_attr_getstack+0x44> <== NOT EXECUTED
return EINVAL;
*stackaddr = attr->stackaddr;
a000e5f8: e593c004 ldr ip, [r3, #4] <== NOT EXECUTED
*stacksize = attr->stacksize;
a000e5fc: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED
)
{
if ( !attr || !attr->is_initialized || !stackaddr || !stacksize )
return EINVAL;
*stackaddr = attr->stackaddr;
a000e600: e581c000 str ip, [r1] <== NOT EXECUTED
*stacksize = attr->stacksize;
a000e604: e5823000 str r3, [r2] <== NOT EXECUTED
return 0;
a000e608: e12fff1e bx lr <== NOT EXECUTED
void **stackaddr,
size_t *stacksize
)
{
if ( !attr || !attr->is_initialized || !stackaddr || !stacksize )
return EINVAL;
a000e60c: e3a00016 mov r0, #22 <== NOT EXECUTED
a000e610: e12fff1e bx lr <== NOT EXECUTED
a000e614: e3a00016 mov r0, #22 <== NOT EXECUTED
*stackaddr = attr->stackaddr;
*stacksize = attr->stacksize;
return 0;
}
a000e618: e12fff1e bx lr <== NOT EXECUTED
a000e5a0 <pthread_attr_getstackaddr>:
int pthread_attr_getstackaddr(
const pthread_attr_t *attr,
void **stackaddr
)
{
if ( !attr || !attr->is_initialized || !stackaddr )
a000e5a0: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000e5a4: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_getstackaddr(
const pthread_attr_t *attr,
void **stackaddr
)
{
if ( !attr || !attr->is_initialized || !stackaddr )
a000e5a8: 012fff1e bxeq lr <== NOT EXECUTED
a000e5ac: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000e5b0: e3500000 cmp r0, #0 <== NOT EXECUTED
a000e5b4: 13510000 cmpne r1, #0 <== NOT EXECUTED
return EINVAL;
*stackaddr = attr->stackaddr;
a000e5b8: 15933004 ldrne r3, [r3, #4] <== NOT EXECUTED
int pthread_attr_getstackaddr(
const pthread_attr_t *attr,
void **stackaddr
)
{
if ( !attr || !attr->is_initialized || !stackaddr )
a000e5bc: 13a00000 movne r0, #0 <== NOT EXECUTED
a000e5c0: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a000e5c4: 03a00016 moveq r0, #22 <== NOT EXECUTED
*stackaddr = attr->stackaddr;
a000e5c8: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000e5cc: e12fff1e bx lr <== NOT EXECUTED
a000e61c <pthread_attr_getstacksize>:
int pthread_attr_getstacksize(
const pthread_attr_t *attr,
size_t *stacksize
)
{
if ( !attr || !attr->is_initialized || !stacksize )
a000e61c: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000e620: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_getstacksize(
const pthread_attr_t *attr,
size_t *stacksize
)
{
if ( !attr || !attr->is_initialized || !stacksize )
a000e624: 012fff1e bxeq lr <== NOT EXECUTED
a000e628: e5930000 ldr r0, [r3] <== NOT EXECUTED
a000e62c: e3500000 cmp r0, #0 <== NOT EXECUTED
a000e630: 13510000 cmpne r1, #0 <== NOT EXECUTED
return EINVAL;
*stacksize = attr->stacksize;
a000e634: 15933008 ldrne r3, [r3, #8] <== NOT EXECUTED
int pthread_attr_getstacksize(
const pthread_attr_t *attr,
size_t *stacksize
)
{
if ( !attr || !attr->is_initialized || !stacksize )
a000e638: 13a00000 movne r0, #0 <== NOT EXECUTED
a000e63c: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a000e640: 03a00016 moveq r0, #22 <== NOT EXECUTED
*stacksize = attr->stacksize;
a000e644: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000e648: e12fff1e bx lr <== NOT EXECUTED
a000f064 <pthread_attr_setcputime>:
int pthread_attr_setcputime(
pthread_attr_t *attr,
int clock_allowed
)
{
if ( !attr || !attr->is_initialized )
a000f064: e3500000 cmp r0, #0 <== NOT EXECUTED
a000f068: 0a000007 beq a000f08c <pthread_attr_setcputime+0x28> <== NOT EXECUTED
a000f06c: e5903000 ldr r3, [r0] <== NOT EXECUTED
a000f070: e3530000 cmp r3, #0 <== NOT EXECUTED
a000f074: 0a000004 beq a000f08c <pthread_attr_setcputime+0x28> <== NOT EXECUTED
return EINVAL;
switch ( clock_allowed ) {
a000f078: e3510001 cmp r1, #1 <== NOT EXECUTED
case CLOCK_ENABLED:
case CLOCK_DISABLED:
attr->cputime_clock_allowed = clock_allowed;
a000f07c: 95801038 strls r1, [r0, #56] ; 0x38 <== NOT EXECUTED
return 0;
a000f080: 93a00000 movls r0, #0 <== NOT EXECUTED
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
switch ( clock_allowed ) {
a000f084: 912fff1e bxls lr <== NOT EXECUTED
a000f088: ea000001 b a000f094 <pthread_attr_setcputime+0x30> <== NOT EXECUTED
pthread_attr_t *attr,
int clock_allowed
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000f08c: e3a00016 mov r0, #22 <== NOT EXECUTED
a000f090: e12fff1e bx lr <== NOT EXECUTED
case CLOCK_DISABLED:
attr->cputime_clock_allowed = clock_allowed;
return 0;
default:
return EINVAL;
a000f094: e3a00016 mov r0, #22 <== NOT EXECUTED
}
}
a000f098: e12fff1e bx lr <== NOT EXECUTED
a000e694 <pthread_attr_setdetachstate>:
int pthread_attr_setdetachstate(
pthread_attr_t *attr,
int detachstate
)
{
if ( !attr || !attr->is_initialized )
a000e694: e3500000 cmp r0, #0
a000e698: 0a000007 beq a000e6bc <pthread_attr_setdetachstate+0x28>
a000e69c: e5903000 ldr r3, [r0]
a000e6a0: e3530000 cmp r3, #0
a000e6a4: 0a000004 beq a000e6bc <pthread_attr_setdetachstate+0x28>
return EINVAL;
switch ( detachstate ) {
a000e6a8: e3510001 cmp r1, #1
case PTHREAD_CREATE_DETACHED:
case PTHREAD_CREATE_JOINABLE:
attr->detachstate = detachstate;
a000e6ac: 9580103c strls r1, [r0, #60] ; 0x3c
return 0;
a000e6b0: 93a00000 movls r0, #0
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
switch ( detachstate ) {
a000e6b4: 912fff1e bxls lr
a000e6b8: ea000001 b a000e6c4 <pthread_attr_setdetachstate+0x30> <== NOT EXECUTED
pthread_attr_t *attr,
int detachstate
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000e6bc: e3a00016 mov r0, #22 <== NOT EXECUTED
a000e6c0: e12fff1e bx lr <== NOT EXECUTED
case PTHREAD_CREATE_JOINABLE:
attr->detachstate = detachstate;
return 0;
default:
return EINVAL;
a000e6c4: e3a00016 mov r0, #22 <== NOT EXECUTED
}
}
a000e6c8: e12fff1e bx lr <== NOT EXECUTED
a000e6cc <pthread_attr_setguardsize>:
int pthread_attr_setguardsize(
pthread_attr_t *attr,
size_t guardsize
)
{
if ( !attr || !attr->is_initialized )
a000e6cc: e3500000 cmp r0, #0 <== NOT EXECUTED
return EINVAL;
a000e6d0: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_setguardsize(
pthread_attr_t *attr,
size_t guardsize
)
{
if ( !attr || !attr->is_initialized )
a000e6d4: 012fff1e bxeq lr <== NOT EXECUTED
a000e6d8: e5903000 ldr r3, [r0] <== NOT EXECUTED
a000e6dc: e3530000 cmp r3, #0 <== NOT EXECUTED
return EINVAL;
attr->guardsize = guardsize;
a000e6e0: 15801034 strne r1, [r0, #52] ; 0x34 <== NOT EXECUTED
pthread_attr_t *attr,
size_t guardsize
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000e6e4: 03a00016 moveq r0, #22 <== NOT EXECUTED
attr->guardsize = guardsize;
return 0;
a000e6e8: 13a00000 movne r0, #0 <== NOT EXECUTED
}
a000e6ec: e12fff1e bx lr <== NOT EXECUTED
a000f948 <pthread_attr_setinheritsched>:
int pthread_attr_setinheritsched(
pthread_attr_t *attr,
int inheritsched
)
{
if ( !attr || !attr->is_initialized )
a000f948: e3500000 cmp r0, #0
a000f94c: 0a000008 beq a000f974 <pthread_attr_setinheritsched+0x2c>
a000f950: e5903000 ldr r3, [r0]
a000f954: e3530000 cmp r3, #0
a000f958: 0a000005 beq a000f974 <pthread_attr_setinheritsched+0x2c>
return EINVAL;
switch ( inheritsched ) {
a000f95c: e2413001 sub r3, r1, #1
a000f960: e3530001 cmp r3, #1
case PTHREAD_INHERIT_SCHED:
case PTHREAD_EXPLICIT_SCHED:
attr->inheritsched = inheritsched;
a000f964: 95801010 strls r1, [r0, #16]
return 0;
a000f968: 93a00000 movls r0, #0
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
switch ( inheritsched ) {
a000f96c: 912fff1e bxls lr
a000f970: ea000001 b a000f97c <pthread_attr_setinheritsched+0x34> <== NOT EXECUTED
pthread_attr_t *attr,
int inheritsched
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000f974: e3a00016 mov r0, #22 <== NOT EXECUTED
a000f978: e12fff1e bx lr <== NOT EXECUTED
case PTHREAD_EXPLICIT_SCHED:
attr->inheritsched = inheritsched;
return 0;
default:
return ENOTSUP;
a000f97c: e3a00086 mov r0, #134 ; 0x86 <== NOT EXECUTED
}
}
a000f980: e12fff1e bx lr <== NOT EXECUTED
a000e72c <pthread_attr_setschedparam>:
int pthread_attr_setschedparam(
pthread_attr_t *attr,
const struct sched_param *param
)
{
if ( !attr || !attr->is_initialized || !param )
a000e72c: e3500000 cmp r0, #0
int pthread_attr_setschedparam(
pthread_attr_t *attr,
const struct sched_param *param
)
{
a000e730: e92d4030 push {r4, r5, lr}
if ( !attr || !attr->is_initialized || !param )
a000e734: 0a00000d beq a000e770 <pthread_attr_setschedparam+0x44>
a000e738: e5905000 ldr r5, [r0]
a000e73c: e3550000 cmp r5, #0
a000e740: 13510000 cmpne r1, #0
a000e744: 13a05000 movne r5, #0
a000e748: 03a05001 moveq r5, #1
a000e74c: 0a000009 beq a000e778 <pthread_attr_setschedparam+0x4c>
return EINVAL;
attr->schedparam = *param;
a000e750: e280c018 add ip, r0, #24
a000e754: e1a04001 mov r4, r1
a000e758: e8b4000f ldm r4!, {r0, r1, r2, r3}
a000e75c: e8ac000f stmia ip!, {r0, r1, r2, r3}
a000e760: e8940007 ldm r4, {r0, r1, r2}
a000e764: e88c0007 stm ip, {r0, r1, r2}
return 0;
a000e768: e1a00005 mov r0, r5
a000e76c: e8bd8030 pop {r4, r5, pc}
pthread_attr_t *attr,
const struct sched_param *param
)
{
if ( !attr || !attr->is_initialized || !param )
return EINVAL;
a000e770: e3a00016 mov r0, #22 <== NOT EXECUTED
a000e774: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000e778: e3a00016 mov r0, #22 <== NOT EXECUTED
attr->schedparam = *param;
return 0;
}
a000e77c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000e780 <pthread_attr_setschedpolicy>:
int pthread_attr_setschedpolicy(
pthread_attr_t *attr,
int policy
)
{
if ( !attr || !attr->is_initialized )
a000e780: e3500000 cmp r0, #0
a000e784: 0a00000b beq a000e7b8 <pthread_attr_setschedpolicy+0x38>
a000e788: e5903000 ldr r3, [r0]
a000e78c: e3530000 cmp r3, #0
a000e790: 0a000008 beq a000e7b8 <pthread_attr_setschedpolicy+0x38>
return EINVAL;
switch ( policy ) {
a000e794: e3510004 cmp r1, #4
a000e798: 8a000008 bhi a000e7c0 <pthread_attr_setschedpolicy+0x40>
a000e79c: e3a03001 mov r3, #1
a000e7a0: e1a03113 lsl r3, r3, r1
a000e7a4: e3130017 tst r3, #23
case SCHED_OTHER:
case SCHED_FIFO:
case SCHED_RR:
case SCHED_SPORADIC:
attr->schedpolicy = policy;
a000e7a8: 15801014 strne r1, [r0, #20]
return 0;
a000e7ac: 13a00000 movne r0, #0
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
switch ( policy ) {
a000e7b0: 112fff1e bxne lr
a000e7b4: ea000001 b a000e7c0 <pthread_attr_setschedpolicy+0x40> <== NOT EXECUTED
pthread_attr_t *attr,
int policy
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000e7b8: e3a00016 mov r0, #22 <== NOT EXECUTED
a000e7bc: e12fff1e bx lr <== NOT EXECUTED
case SCHED_SPORADIC:
attr->schedpolicy = policy;
return 0;
default:
return ENOTSUP;
a000e7c0: e3a00086 mov r0, #134 ; 0x86 <== NOT EXECUTED
}
}
a000e7c4: e12fff1e bx lr <== NOT EXECUTED
a000e7c8 <pthread_attr_setscope>:
int pthread_attr_setscope(
pthread_attr_t *attr,
int contentionscope
)
{
if ( !attr || !attr->is_initialized )
a000e7c8: e3500000 cmp r0, #0 <== NOT EXECUTED
return EINVAL;
a000e7cc: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_attr_setscope(
pthread_attr_t *attr,
int contentionscope
)
{
if ( !attr || !attr->is_initialized )
a000e7d0: 012fff1e bxeq lr <== NOT EXECUTED
a000e7d4: e5903000 ldr r3, [r0] <== NOT EXECUTED
a000e7d8: e3530000 cmp r3, #0 <== NOT EXECUTED
a000e7dc: 0a000007 beq a000e800 <pthread_attr_setscope+0x38> <== NOT EXECUTED
return EINVAL;
switch ( contentionscope ) {
a000e7e0: e3510000 cmp r1, #0 <== NOT EXECUTED
case PTHREAD_SCOPE_PROCESS:
attr->contentionscope = contentionscope;
a000e7e4: 0580100c streq r1, [r0, #12] <== NOT EXECUTED
return 0;
a000e7e8: 01a00001 moveq r0, r1 <== NOT EXECUTED
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
switch ( contentionscope ) {
a000e7ec: 012fff1e bxeq lr <== NOT EXECUTED
case PTHREAD_SCOPE_SYSTEM:
return ENOTSUP;
default:
return EINVAL;
a000e7f0: e3510001 cmp r1, #1 <== NOT EXECUTED
a000e7f4: 03a00086 moveq r0, #134 ; 0x86 <== NOT EXECUTED
a000e7f8: 13a00016 movne r0, #22 <== NOT EXECUTED
a000e7fc: e12fff1e bx lr <== NOT EXECUTED
pthread_attr_t *attr,
int contentionscope
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000e800: e3a00016 mov r0, #22 <== NOT EXECUTED
return ENOTSUP;
default:
return EINVAL;
}
}
a000e804: e12fff1e bx lr <== NOT EXECUTED
a000e82c <pthread_attr_setstack>:
pthread_attr_t *attr,
void *stackaddr,
size_t stacksize
)
{
if ( !attr || !attr->is_initialized )
a000e82c: e3500000 cmp r0, #0
return EINVAL;
a000e830: 03a00016 moveq r0, #22
pthread_attr_t *attr,
void *stackaddr,
size_t stacksize
)
{
if ( !attr || !attr->is_initialized )
a000e834: 012fff1e bxeq lr
a000e838: e5903000 ldr r3, [r0]
a000e83c: e3530000 cmp r3, #0
a000e840: 0a000008 beq a000e868 <pthread_attr_setstack+0x3c>
return EINVAL;
if (stacksize < PTHREAD_MINIMUM_STACK_SIZE)
a000e844: e59f3024 ldr r3, [pc, #36] ; a000e870 <pthread_attr_setstack+0x44>
attr->stacksize = PTHREAD_MINIMUM_STACK_SIZE;
else
attr->stacksize = stacksize;
attr->stackaddr = stackaddr;
a000e848: e5801004 str r1, [r0, #4]
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
if (stacksize < PTHREAD_MINIMUM_STACK_SIZE)
a000e84c: e5933000 ldr r3, [r3]
a000e850: e1a03083 lsl r3, r3, #1
attr->stacksize = PTHREAD_MINIMUM_STACK_SIZE;
a000e854: e1530002 cmp r3, r2
a000e858: 25803008 strcs r3, [r0, #8]
a000e85c: 35802008 strcc r2, [r0, #8]
else
attr->stacksize = stacksize;
attr->stackaddr = stackaddr;
return 0;
a000e860: e3a00000 mov r0, #0
a000e864: e12fff1e bx lr
void *stackaddr,
size_t stacksize
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000e868: e3a00016 mov r0, #22 <== NOT EXECUTED
else
attr->stacksize = stacksize;
attr->stackaddr = stackaddr;
return 0;
}
a000e86c: e12fff1e bx lr <== NOT EXECUTED
a000f984 <pthread_attr_setstacksize>:
int pthread_attr_setstacksize(
pthread_attr_t *attr,
size_t stacksize
)
{
if ( !attr || !attr->is_initialized )
a000f984: e3500000 cmp r0, #0
return EINVAL;
a000f988: 03a00016 moveq r0, #22
int pthread_attr_setstacksize(
pthread_attr_t *attr,
size_t stacksize
)
{
if ( !attr || !attr->is_initialized )
a000f98c: 012fff1e bxeq lr
a000f990: e5903000 ldr r3, [r0]
a000f994: e3530000 cmp r3, #0
a000f998: 0a000007 beq a000f9bc <pthread_attr_setstacksize+0x38>
return EINVAL;
if (stacksize < PTHREAD_MINIMUM_STACK_SIZE)
a000f99c: e59f3020 ldr r3, [pc, #32] ; a000f9c4 <pthread_attr_setstacksize+0x40>
a000f9a0: e5933000 ldr r3, [r3]
a000f9a4: e1a03083 lsl r3, r3, #1
a000f9a8: e1510003 cmp r1, r3
attr->stacksize = PTHREAD_MINIMUM_STACK_SIZE;
a000f9ac: 35803008 strcc r3, [r0, #8]
else
attr->stacksize = stacksize;
a000f9b0: 25801008 strcs r1, [r0, #8]
return 0;
a000f9b4: e3a00000 mov r0, #0
a000f9b8: e12fff1e bx lr
pthread_attr_t *attr,
size_t stacksize
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000f9bc: e3a00016 mov r0, #22 <== NOT EXECUTED
if (stacksize < PTHREAD_MINIMUM_STACK_SIZE)
attr->stacksize = PTHREAD_MINIMUM_STACK_SIZE;
else
attr->stacksize = stacksize;
return 0;
}
a000f9c0: e12fff1e bx lr <== NOT EXECUTED
a00099e4 <pthread_barrier_destroy>:
)
{
POSIX_Barrier_Control *the_barrier = NULL;
Objects_Locations location;
if ( !barrier )
a00099e4: e2503000 subs r3, r0, #0 <== NOT EXECUTED
*/
int pthread_barrier_destroy(
pthread_barrier_t *barrier
)
{
a00099e8: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
POSIX_Barrier_Control *the_barrier = NULL;
Objects_Locations location;
if ( !barrier )
a00099ec: 0a000016 beq a0009a4c <pthread_barrier_destroy+0x68> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_Barrier_Control *_POSIX_Barrier_Get (
pthread_barrier_t *barrier,
Objects_Locations *location
)
{
return (POSIX_Barrier_Control *) _Objects_Get(
a00099f0: e5931000 ldr r1, [r3] <== NOT EXECUTED
a00099f4: e59f0058 ldr r0, [pc, #88] ; a0009a54 <pthread_barrier_destroy+0x70><== NOT EXECUTED
a00099f8: e1a0200d mov r2, sp <== NOT EXECUTED
a00099fc: eb00091f bl a000be80 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_barrier = _POSIX_Barrier_Get( barrier, &location );
switch ( location ) {
a0009a00: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a0009a04: e1a04000 mov r4, r0 <== NOT EXECUTED
a0009a08: e3530000 cmp r3, #0 <== NOT EXECUTED
a0009a0c: 1a00000e bne a0009a4c <pthread_barrier_destroy+0x68> <== NOT EXECUTED
case OBJECTS_LOCAL:
if ( the_barrier->Barrier.number_of_waiting_threads != 0 ) {
a0009a10: e5905058 ldr r5, [r0, #88] ; 0x58 <== NOT EXECUTED
a0009a14: e3550000 cmp r5, #0 <== NOT EXECUTED
a0009a18: 0a000002 beq a0009a28 <pthread_barrier_destroy+0x44> <== NOT EXECUTED
_Thread_Enable_dispatch();
a0009a1c: eb000bcf bl a000c960 <_Thread_Enable_dispatch> <== NOT EXECUTED
return EBUSY;
a0009a20: e3a00010 mov r0, #16 <== NOT EXECUTED
a0009a24: ea000009 b a0009a50 <pthread_barrier_destroy+0x6c> <== NOT EXECUTED
}
_Objects_Close( &_POSIX_Barrier_Information, &the_barrier->Object );
a0009a28: e59f0024 ldr r0, [pc, #36] ; a0009a54 <pthread_barrier_destroy+0x70><== NOT EXECUTED
a0009a2c: e1a01004 mov r1, r4 <== NOT EXECUTED
a0009a30: eb000813 bl a000ba84 <_Objects_Close> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _POSIX_Barrier_Free (
POSIX_Barrier_Control *the_barrier
)
{
_Objects_Free( &_POSIX_Barrier_Information, &the_barrier->Object );
a0009a34: e59f0018 ldr r0, [pc, #24] ; a0009a54 <pthread_barrier_destroy+0x70><== NOT EXECUTED
a0009a38: e1a01004 mov r1, r4 <== NOT EXECUTED
a0009a3c: eb0008b7 bl a000bd20 <_Objects_Free> <== NOT EXECUTED
_POSIX_Barrier_Free( the_barrier );
_Thread_Enable_dispatch();
a0009a40: eb000bc6 bl a000c960 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a0009a44: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009a48: ea000000 b a0009a50 <pthread_barrier_destroy+0x6c> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a0009a4c: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a0009a50: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a0009a58 <pthread_barrier_init>:
int pthread_barrier_init(
pthread_barrier_t *barrier,
const pthread_barrierattr_t *attr,
unsigned int count
)
{
a0009a58: e92d40ff push {r0, r1, r2, r3, r4, r5, r6, r7, lr} <== NOT EXECUTED
const pthread_barrierattr_t *the_attr;
/*
* Error check parameters
*/
if ( !barrier )
a0009a5c: e2507000 subs r7, r0, #0 <== NOT EXECUTED
int pthread_barrier_init(
pthread_barrier_t *barrier,
const pthread_barrierattr_t *attr,
unsigned int count
)
{
a0009a60: e1a04002 mov r4, r2 <== NOT EXECUTED
const pthread_barrierattr_t *the_attr;
/*
* Error check parameters
*/
if ( !barrier )
a0009a64: 0a000027 beq a0009b08 <pthread_barrier_init+0xb0> <== NOT EXECUTED
return EINVAL;
if ( count == 0 )
a0009a68: e3520000 cmp r2, #0 <== NOT EXECUTED
a0009a6c: 0a000025 beq a0009b08 <pthread_barrier_init+0xb0> <== NOT EXECUTED
return EINVAL;
/*
* If the user passed in NULL, use the default attributes
*/
if ( attr ) {
a0009a70: e3510000 cmp r1, #0 <== NOT EXECUTED
a0009a74: 1a000003 bne a0009a88 <pthread_barrier_init+0x30> <== NOT EXECUTED
the_attr = attr;
} else {
(void) pthread_barrierattr_init( &my_attr );
a0009a78: e1a0000d mov r0, sp <== NOT EXECUTED
a0009a7c: ebffffc3 bl a0009990 <pthread_barrierattr_init> <== NOT EXECUTED
a0009a80: e1a0500d mov r5, sp <== NOT EXECUTED
the_attr = &my_attr;
a0009a84: e1a0100d mov r1, sp <== NOT EXECUTED
}
/*
* Now start error checking the attributes that we are going to use
*/
if ( !the_attr->is_initialized )
a0009a88: e5913000 ldr r3, [r1] <== NOT EXECUTED
a0009a8c: e3530000 cmp r3, #0 <== NOT EXECUTED
a0009a90: 0a00001c beq a0009b08 <pthread_barrier_init+0xb0> <== NOT EXECUTED
return EINVAL;
switch ( the_attr->process_shared ) {
a0009a94: e5915004 ldr r5, [r1, #4] <== NOT EXECUTED
a0009a98: e3550000 cmp r5, #0 <== NOT EXECUTED
a0009a9c: 1a000019 bne a0009b08 <pthread_barrier_init+0xb0> <== NOT EXECUTED
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a0009aa0: e59f306c ldr r3, [pc, #108] ; a0009b14 <pthread_barrier_init+0xbc><== NOT EXECUTED
}
/*
* Convert from POSIX attributes to Core Barrier attributes
*/
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
a0009aa4: e58d5008 str r5, [sp, #8] <== NOT EXECUTED
the_attributes.maximum_count = count;
a0009aa8: e58d400c str r4, [sp, #12] <== NOT EXECUTED
a0009aac: e5932000 ldr r2, [r3] <== NOT EXECUTED
a0009ab0: e2822001 add r2, r2, #1 <== NOT EXECUTED
a0009ab4: e5832000 str r2, [r3] <== NOT EXECUTED
* the inactive chain of free barrier control blocks.
*/
RTEMS_INLINE_ROUTINE POSIX_Barrier_Control *_POSIX_Barrier_Allocate( void )
{
return (POSIX_Barrier_Control *)
_Objects_Allocate( &_POSIX_Barrier_Information );
a0009ab8: e59f6058 ldr r6, [pc, #88] ; a0009b18 <pthread_barrier_init+0xc0><== NOT EXECUTED
a0009abc: e1a00006 mov r0, r6 <== NOT EXECUTED
a0009ac0: eb0007cd bl a000b9fc <_Objects_Allocate> <== NOT EXECUTED
*/
_Thread_Disable_dispatch(); /* prevents deletion */
the_barrier = _POSIX_Barrier_Allocate();
if ( !the_barrier ) {
a0009ac4: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a0009ac8: 1a000002 bne a0009ad8 <pthread_barrier_init+0x80> <== NOT EXECUTED
_Thread_Enable_dispatch();
a0009acc: eb000ba3 bl a000c960 <_Thread_Enable_dispatch> <== NOT EXECUTED
return EAGAIN;
a0009ad0: e3a0000b mov r0, #11 <== NOT EXECUTED
a0009ad4: ea00000c b a0009b0c <pthread_barrier_init+0xb4> <== NOT EXECUTED
}
_CORE_barrier_Initialize( &the_barrier->Barrier, &the_attributes );
a0009ad8: e2840010 add r0, r4, #16 <== NOT EXECUTED
a0009adc: e28d1008 add r1, sp, #8 <== NOT EXECUTED
a0009ae0: eb000563 bl a000b074 <_CORE_barrier_Initialize> <== NOT EXECUTED
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0009ae4: e596201c ldr r2, [r6, #28] <== NOT EXECUTED
Objects_Information *information,
Objects_Control *the_object,
uint32_t name
)
{
_Objects_Set_local_object(
a0009ae8: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED
a0009aec: e1d410b8 ldrh r1, [r4, #8] <== NOT EXECUTED
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0009af0: e7824101 str r4, [r2, r1, lsl #2] <== NOT EXECUTED
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
a0009af4: e584500c str r5, [r4, #12] <== NOT EXECUTED
);
/*
* Exit the critical section and return the user an operational barrier
*/
*barrier = the_barrier->Object.id;
a0009af8: e5873000 str r3, [r7] <== NOT EXECUTED
_Thread_Enable_dispatch();
a0009afc: eb000b97 bl a000c960 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a0009b00: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009b04: ea000000 b a0009b0c <pthread_barrier_init+0xb4> <== NOT EXECUTED
switch ( the_attr->process_shared ) {
case PTHREAD_PROCESS_PRIVATE: /* only supported values */
break;
case PTHREAD_PROCESS_SHARED:
default:
return EINVAL;
a0009b08: e3a00016 mov r0, #22 <== NOT EXECUTED
* Exit the critical section and return the user an operational barrier
*/
*barrier = the_barrier->Object.id;
_Thread_Enable_dispatch();
return 0;
}
a0009b0c: e28dd010 add sp, sp, #16 <== NOT EXECUTED
a0009b10: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
a0009b1c <pthread_barrier_wait>:
)
{
POSIX_Barrier_Control *the_barrier = NULL;
Objects_Locations location;
if ( !barrier )
a0009b1c: e2503000 subs r3, r0, #0 <== NOT EXECUTED
*/
int pthread_barrier_wait(
pthread_barrier_t *barrier
)
{
a0009b20: e92d4003 push {r0, r1, lr} <== NOT EXECUTED
POSIX_Barrier_Control *the_barrier = NULL;
Objects_Locations location;
if ( !barrier )
a0009b24: 0a000012 beq a0009b74 <pthread_barrier_wait+0x58> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_Barrier_Control *_POSIX_Barrier_Get (
pthread_barrier_t *barrier,
Objects_Locations *location
)
{
return (POSIX_Barrier_Control *) _Objects_Get(
a0009b28: e5931000 ldr r1, [r3] <== NOT EXECUTED
a0009b2c: e28d2004 add r2, sp, #4 <== NOT EXECUTED
a0009b30: e59f0044 ldr r0, [pc, #68] ; a0009b7c <pthread_barrier_wait+0x60><== NOT EXECUTED
a0009b34: eb0008d1 bl a000be80 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_barrier = _POSIX_Barrier_Get( barrier, &location );
switch ( location ) {
a0009b38: e59d3004 ldr r3, [sp, #4] <== NOT EXECUTED
a0009b3c: e1a02000 mov r2, r0 <== NOT EXECUTED
a0009b40: e3530000 cmp r3, #0 <== NOT EXECUTED
a0009b44: 1a00000a bne a0009b74 <pthread_barrier_wait+0x58> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_barrier_Wait(
a0009b48: e58d3000 str r3, [sp] <== NOT EXECUTED
a0009b4c: e5921008 ldr r1, [r2, #8] <== NOT EXECUTED
a0009b50: e2800010 add r0, r0, #16 <== NOT EXECUTED
a0009b54: e3a02001 mov r2, #1 <== NOT EXECUTED
a0009b58: eb00054d bl a000b094 <_CORE_barrier_Wait> <== NOT EXECUTED
the_barrier->Object.id,
true,
0,
NULL
);
_Thread_Enable_dispatch();
a0009b5c: eb000b7f bl a000c960 <_Thread_Enable_dispatch> <== NOT EXECUTED
return _POSIX_Barrier_Translate_core_barrier_return_code(
_Thread_Executing->Wait.return_code );
a0009b60: e59f3018 ldr r3, [pc, #24] ; a0009b80 <pthread_barrier_wait+0x64><== NOT EXECUTED
a0009b64: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
true,
0,
NULL
);
_Thread_Enable_dispatch();
return _POSIX_Barrier_Translate_core_barrier_return_code(
a0009b68: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a0009b6c: eb00169e bl a000f5ec <_POSIX_Barrier_Translate_core_barrier_return_code><== NOT EXECUTED
a0009b70: ea000000 b a0009b78 <pthread_barrier_wait+0x5c> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a0009b74: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a0009b78: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED
a0009944 <pthread_barrierattr_destroy>:
int pthread_barrierattr_destroy(
pthread_barrierattr_t *attr
)
{
if ( !attr || attr->is_initialized == false )
a0009944: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a0009948: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_barrierattr_destroy(
pthread_barrierattr_t *attr
)
{
if ( !attr || attr->is_initialized == false )
a000994c: 012fff1e bxeq lr <== NOT EXECUTED
a0009950: e5932000 ldr r2, [r3] <== NOT EXECUTED
a0009954: e3520000 cmp r2, #0 <== NOT EXECUTED
return EINVAL;
attr->is_initialized = false;
a0009958: 13a00000 movne r0, #0 <== NOT EXECUTED
a000995c: 15830000 strne r0, [r3] <== NOT EXECUTED
int pthread_barrierattr_destroy(
pthread_barrierattr_t *attr
)
{
if ( !attr || attr->is_initialized == false )
return EINVAL;
a0009960: 03a00016 moveq r0, #22 <== NOT EXECUTED
attr->is_initialized = false;
return 0;
}
a0009964: e12fff1e bx lr <== NOT EXECUTED
a0009968 <pthread_barrierattr_getpshared>:
int pthread_barrierattr_getpshared(
const pthread_barrierattr_t *attr,
int *pshared
)
{
if ( !attr )
a0009968: e3500000 cmp r0, #0
return EINVAL;
a000996c: 03a00016 moveq r0, #22
int pthread_barrierattr_getpshared(
const pthread_barrierattr_t *attr,
int *pshared
)
{
if ( !attr )
a0009970: 012fff1e bxeq lr
return EINVAL;
if ( !attr->is_initialized )
a0009974: e5903000 ldr r3, [r0] <== NOT EXECUTED
a0009978: e3530000 cmp r3, #0 <== NOT EXECUTED
return EINVAL;
*pshared = attr->process_shared;
a000997c: 15903004 ldrne r3, [r0, #4] <== NOT EXECUTED
{
if ( !attr )
return EINVAL;
if ( !attr->is_initialized )
return EINVAL;
a0009980: 03a00016 moveq r0, #22 <== NOT EXECUTED
*pshared = attr->process_shared;
return 0;
a0009984: 13a00000 movne r0, #0 <== NOT EXECUTED
return EINVAL;
if ( !attr->is_initialized )
return EINVAL;
*pshared = attr->process_shared;
a0009988: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000998c: e12fff1e bx lr <== NOT EXECUTED
a00099ac <pthread_barrierattr_setpshared>:
int pthread_barrierattr_setpshared(
pthread_barrierattr_t *attr,
int pshared
)
{
if ( !attr )
a00099ac: e3500000 cmp r0, #0
a00099b0: 0a000007 beq a00099d4 <pthread_barrierattr_setpshared+0x28>
return EINVAL;
if ( !attr->is_initialized )
a00099b4: e5903000 ldr r3, [r0] <== NOT EXECUTED
a00099b8: e3530000 cmp r3, #0 <== NOT EXECUTED
a00099bc: 0a000004 beq a00099d4 <pthread_barrierattr_setpshared+0x28><== NOT EXECUTED
return EINVAL;
switch ( pshared ) {
a00099c0: e3510001 cmp r1, #1 <== NOT EXECUTED
case PTHREAD_PROCESS_SHARED:
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
a00099c4: 95801004 strls r1, [r0, #4] <== NOT EXECUTED
return 0;
a00099c8: 93a00000 movls r0, #0 <== NOT EXECUTED
return EINVAL;
if ( !attr->is_initialized )
return EINVAL;
switch ( pshared ) {
a00099cc: 912fff1e bxls lr <== NOT EXECUTED
a00099d0: ea000001 b a00099dc <pthread_barrierattr_setpshared+0x30> <== NOT EXECUTED
{
if ( !attr )
return EINVAL;
if ( !attr->is_initialized )
return EINVAL;
a00099d4: e3a00016 mov r0, #22
a00099d8: e12fff1e bx lr
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
return 0;
default:
return EINVAL;
a00099dc: e3a00016 mov r0, #22
}
}
a00099e0: e12fff1e bx lr
a0008f8c <pthread_cancel>:
/*
* Don't even think about deleting a resource from an ISR.
*/
if ( _ISR_Is_in_progress() )
a0008f8c: e59f304c ldr r3, [pc, #76] ; a0008fe0 <pthread_cancel+0x54>
*/
int pthread_cancel(
pthread_t thread
)
{
a0008f90: e92d4011 push {r0, r4, lr}
/*
* Don't even think about deleting a resource from an ISR.
*/
if ( _ISR_Is_in_progress() )
a0008f94: e5933000 ldr r3, [r3]
*/
int pthread_cancel(
pthread_t thread
)
{
a0008f98: e1a01000 mov r1, r0
/*
* Don't even think about deleting a resource from an ISR.
*/
if ( _ISR_Is_in_progress() )
a0008f9c: e3530000 cmp r3, #0
return EPROTO;
a0008fa0: 13a00047 movne r0, #71 ; 0x47
/*
* Don't even think about deleting a resource from an ISR.
*/
if ( _ISR_Is_in_progress() )
a0008fa4: 1a00000c bne a0008fdc <pthread_cancel+0x50>
pthread_t id,
Objects_Locations *location
)
{
return (Thread_Control *)
_Objects_Get( &_POSIX_Threads_Information, (Objects_Id)id, location );
a0008fa8: e59f0034 ldr r0, [pc, #52] ; a0008fe4 <pthread_cancel+0x58>
a0008fac: e1a0200d mov r2, sp
a0008fb0: eb0007f5 bl a000af8c <_Objects_Get>
return EPROTO;
the_thread = _POSIX_Threads_Get( thread, &location );
switch ( location ) {
a0008fb4: e59d4000 ldr r4, [sp]
a0008fb8: e1a03000 mov r3, r0
a0008fbc: e3540000 cmp r4, #0
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a0008fc0: 13a00016 movne r0, #22
if ( _ISR_Is_in_progress() )
return EPROTO;
the_thread = _POSIX_Threads_Get( thread, &location );
switch ( location ) {
a0008fc4: 1a000004 bne a0008fdc <pthread_cancel+0x50>
case OBJECTS_LOCAL:
thread_support = the_thread->API_Extensions[ THREAD_API_POSIX ];
thread_support->cancelation_requested = 1;
a0008fc8: e59330fc ldr r3, [r3, #252] ; 0xfc <== NOT EXECUTED
a0008fcc: e3a02001 mov r2, #1 <== NOT EXECUTED
a0008fd0: e58320e0 str r2, [r3, #224] ; 0xe0 <== NOT EXECUTED
/* This enables dispatch implicitly */
_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch( the_thread );
a0008fd4: eb001501 bl a000e3e0 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch><== NOT EXECUTED
return 0;
a0008fd8: e1a00004 mov r0, r4 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
a0008fdc: e8bd8018 pop {r3, r4, pc}
a0008b10 <pthread_cleanup_pop>:
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a0008b10: e59f207c ldr r2, [pc, #124] ; a0008b94 <pthread_cleanup_pop+0x84>
POSIX_Cancel_Handler_control tmp_handler;
Chain_Control *handler_stack;
POSIX_API_Control *thread_support;
ISR_Level level;
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0008b14: e59f307c ldr r3, [pc, #124] ; a0008b98 <pthread_cleanup_pop+0x88>
*/
void pthread_cleanup_pop(
int execute
)
{
a0008b18: e92d4070 push {r4, r5, r6, lr}
a0008b1c: e5921000 ldr r1, [r2]
POSIX_Cancel_Handler_control tmp_handler;
Chain_Control *handler_stack;
POSIX_API_Control *thread_support;
ISR_Level level;
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0008b20: e5933004 ldr r3, [r3, #4]
*/
void pthread_cleanup_pop(
int execute
)
{
a0008b24: e1a06000 mov r6, r0
a0008b28: e2811001 add r1, r1, #1
POSIX_Cancel_Handler_control tmp_handler;
Chain_Control *handler_stack;
POSIX_API_Control *thread_support;
ISR_Level level;
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0008b2c: e59330fc ldr r3, [r3, #252] ; 0xfc
a0008b30: e5821000 str r1, [r2]
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0008b34: e10f4000 mrs r4, CPSR
a0008b38: e3842080 orr r2, r4, #128 ; 0x80
a0008b3c: e129f002 msr CPSR_fc, r2
*/
_Thread_Disable_dispatch();
_ISR_Disable( level );
if ( _Chain_Is_empty( handler_stack ) ) {
a0008b40: e59310e4 ldr r1, [r3, #228] ; 0xe4
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a0008b44: e28320e8 add r2, r3, #232 ; 0xe8
a0008b48: e1510002 cmp r1, r2
a0008b4c: 1a000002 bne a0008b5c <pthread_cleanup_pop+0x4c>
_Thread_Enable_dispatch();
a0008b50: eb0009fc bl a000b348 <_Thread_Enable_dispatch>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0008b54: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED
a0008b58: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
_ISR_Enable( level );
return;
}
handler = (POSIX_Cancel_Handler_control *)
a0008b5c: e59300ec ldr r0, [r3, #236] ; 0xec
)
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
a0008b60: e890000c ldm r0, {r2, r3}
previous = the_node->previous;
next->previous = previous;
a0008b64: e5823004 str r3, [r2, #4]
previous->next = next;
a0008b68: e5832000 str r2, [r3]
a0008b6c: e129f004 msr CPSR_fc, r4
a0008b70: e5904008 ldr r4, [r0, #8]
a0008b74: e590500c ldr r5, [r0, #12]
_ISR_Enable( level );
tmp_handler = *handler;
_Workspace_Free( handler );
a0008b78: eb000df0 bl a000c340 <_Workspace_Free>
_Thread_Enable_dispatch();
a0008b7c: eb0009f1 bl a000b348 <_Thread_Enable_dispatch>
if ( execute )
a0008b80: e3560000 cmp r6, #0
a0008b84: 0a000001 beq a0008b90 <pthread_cleanup_pop+0x80>
(*tmp_handler.routine)( tmp_handler.arg );
a0008b88: e1a00005 mov r0, r5
a0008b8c: e12fff34 blx r4
a0008b90: e8bd8070 pop {r4, r5, r6, pc}
a0009264 <pthread_cleanup_push>:
void pthread_cleanup_push(
void (*routine)( void * ),
void *arg
)
{
a0009264: e92d4030 push {r4, r5, lr}
/*
* The POSIX standard does not address what to do when the routine
* is NULL. It also does not address what happens when we cannot
* allocate memory or anything else bad happens.
*/
if ( !routine )
a0009268: e2505000 subs r5, r0, #0
void pthread_cleanup_push(
void (*routine)( void * ),
void *arg
)
{
a000926c: e1a04001 mov r4, r1
/*
* The POSIX standard does not address what to do when the routine
* is NULL. It also does not address what happens when we cannot
* allocate memory or anything else bad happens.
*/
if ( !routine )
a0009270: 0a000011 beq a00092bc <pthread_cleanup_push+0x58>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a0009274: e59f3044 ldr r3, [pc, #68] ; a00092c0 <pthread_cleanup_push+0x5c>
a0009278: e5932000 ldr r2, [r3]
a000927c: e2822001 add r2, r2, #1
a0009280: e5832000 str r2, [r3]
return;
_Thread_Disable_dispatch();
handler = _Workspace_Allocate( sizeof( POSIX_Cancel_Handler_control ) );
a0009284: e3a00010 mov r0, #16
a0009288: eb00104c bl a000d3c0 <_Workspace_Allocate>
if ( handler ) {
a000928c: e2503000 subs r3, r0, #0
a0009290: 0a000007 beq a00092b4 <pthread_cleanup_push+0x50>
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0009294: e59f2028 ldr r2, [pc, #40] ; a00092c4 <pthread_cleanup_push+0x60>
handler_stack = &thread_support->Cancellation_Handlers;
handler->routine = routine;
handler->arg = arg;
_Chain_Append( handler_stack, &handler->Node );
a0009298: e1a01003 mov r1, r3
_Thread_Disable_dispatch();
handler = _Workspace_Allocate( sizeof( POSIX_Cancel_Handler_control ) );
if ( handler ) {
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a000929c: e5922004 ldr r2, [r2, #4]
handler_stack = &thread_support->Cancellation_Handlers;
a00092a0: e59200fc ldr r0, [r2, #252] ; 0xfc
handler->routine = routine;
a00092a4: e5835008 str r5, [r3, #8]
handler->arg = arg;
a00092a8: e583400c str r4, [r3, #12]
_Chain_Append( handler_stack, &handler->Node );
a00092ac: e28000e4 add r0, r0, #228 ; 0xe4
a00092b0: eb0005a7 bl a000a954 <_Chain_Append>
}
_Thread_Enable_dispatch();
}
a00092b4: e8bd4030 pop {r4, r5, lr}
handler->routine = routine;
handler->arg = arg;
_Chain_Append( handler_stack, &handler->Node );
}
_Thread_Enable_dispatch();
a00092b8: ea000bd6 b a000c218 <_Thread_Enable_dispatch>
a00092bc: e8bd8030 pop {r4, r5, pc}
a000a1ec <pthread_cond_destroy>:
*/
int pthread_cond_destroy(
pthread_cond_t *cond
)
{
a000a1ec: e92d4031 push {r0, r4, r5, lr}
POSIX_Condition_variables_Control *the_cond;
Objects_Locations location;
the_cond = _POSIX_Condition_variables_Get( cond, &location );
a000a1f0: e1a0100d mov r1, sp
a000a1f4: eb000015 bl a000a250 <_POSIX_Condition_variables_Get>
switch ( location ) {
a000a1f8: e59d3000 ldr r3, [sp]
)
{
POSIX_Condition_variables_Control *the_cond;
Objects_Locations location;
the_cond = _POSIX_Condition_variables_Get( cond, &location );
a000a1fc: e1a04000 mov r4, r0
switch ( location ) {
a000a200: e3530000 cmp r3, #0
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000a204: 13a00016 movne r0, #22
{
POSIX_Condition_variables_Control *the_cond;
Objects_Locations location;
the_cond = _POSIX_Condition_variables_Get( cond, &location );
switch ( location ) {
a000a208: 1a00000e bne a000a248 <pthread_cond_destroy+0x5c>
case OBJECTS_LOCAL:
if ( _Thread_queue_First( &the_cond->Wait_queue ) ) {
a000a20c: e2840018 add r0, r4, #24
a000a210: eb000f03 bl a000de24 <_Thread_queue_First>
a000a214: e2505000 subs r5, r0, #0
a000a218: 0a000002 beq a000a228 <pthread_cond_destroy+0x3c>
_Thread_Enable_dispatch();
a000a21c: eb000d3d bl a000d718 <_Thread_Enable_dispatch> <== NOT EXECUTED
return EBUSY;
a000a220: e3a00010 mov r0, #16 <== NOT EXECUTED
a000a224: ea000007 b a000a248 <pthread_cond_destroy+0x5c> <== NOT EXECUTED
}
_Objects_Close(
a000a228: e59f001c ldr r0, [pc, #28] ; a000a24c <pthread_cond_destroy+0x60>
a000a22c: e1a01004 mov r1, r4
a000a230: eb000981 bl a000c83c <_Objects_Close>
RTEMS_INLINE_ROUTINE void _POSIX_Condition_variables_Free (
POSIX_Condition_variables_Control *the_condition_variable
)
{
_Objects_Free(
a000a234: e59f0010 ldr r0, [pc, #16] ; a000a24c <pthread_cond_destroy+0x60>
a000a238: e1a01004 mov r1, r4
a000a23c: eb000a25 bl a000cad8 <_Objects_Free>
&_POSIX_Condition_variables_Information,
&the_cond->Object
);
_POSIX_Condition_variables_Free( the_cond );
_Thread_Enable_dispatch();
a000a240: eb000d34 bl a000d718 <_Thread_Enable_dispatch>
return 0;
a000a244: e1a00005 mov r0, r5
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
a000a248: e8bd8038 pop {r3, r4, r5, pc}
a000a2b4 <pthread_cond_init>:
int pthread_cond_init(
pthread_cond_t *cond,
const pthread_condattr_t *attr
)
{
a000a2b4: e92d40f0 push {r4, r5, r6, r7, lr}
POSIX_Condition_variables_Control *the_cond;
const pthread_condattr_t *the_attr;
if ( attr ) the_attr = attr;
else the_attr = &_POSIX_Condition_variables_Default_attributes;
a000a2b8: e59f50a8 ldr r5, [pc, #168] ; a000a368 <pthread_cond_init+0xb4>
a000a2bc: e3510000 cmp r1, #0
a000a2c0: 11a05001 movne r5, r1
/*
* Be careful about attributes when global!!!
*/
if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )
a000a2c4: e5953004 ldr r3, [r5, #4]
int pthread_cond_init(
pthread_cond_t *cond,
const pthread_condattr_t *attr
)
{
a000a2c8: e1a07000 mov r7, r0
else the_attr = &_POSIX_Condition_variables_Default_attributes;
/*
* Be careful about attributes when global!!!
*/
if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )
a000a2cc: e3530001 cmp r3, #1
a000a2d0: 0a000020 beq a000a358 <pthread_cond_init+0xa4>
return EINVAL;
if ( !the_attr->is_initialized )
a000a2d4: e5953000 ldr r3, [r5]
a000a2d8: e3530000 cmp r3, #0
a000a2dc: 0a00001f beq a000a360 <pthread_cond_init+0xac>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000a2e0: e59f3084 ldr r3, [pc, #132] ; a000a36c <pthread_cond_init+0xb8>
a000a2e4: e5932000 ldr r2, [r3]
a000a2e8: e2822001 add r2, r2, #1
a000a2ec: e5832000 str r2, [r3]
RTEMS_INLINE_ROUTINE POSIX_Condition_variables_Control
*_POSIX_Condition_variables_Allocate( void )
{
return (POSIX_Condition_variables_Control *)
_Objects_Allocate( &_POSIX_Condition_variables_Information );
a000a2f0: e59f6078 ldr r6, [pc, #120] ; a000a370 <pthread_cond_init+0xbc>
a000a2f4: e1a00006 mov r0, r6
a000a2f8: eb00092d bl a000c7b4 <_Objects_Allocate>
_Thread_Disable_dispatch();
the_cond = _POSIX_Condition_variables_Allocate();
if ( !the_cond ) {
a000a2fc: e2504000 subs r4, r0, #0
a000a300: 1a000002 bne a000a310 <pthread_cond_init+0x5c>
_Thread_Enable_dispatch();
a000a304: eb000d03 bl a000d718 <_Thread_Enable_dispatch>
return ENOMEM;
a000a308: e3a0000c mov r0, #12
a000a30c: e8bd80f0 pop {r4, r5, r6, r7, pc}
}
the_cond->process_shared = the_attr->process_shared;
a000a310: e5953004 ldr r3, [r5, #4]
the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX;
a000a314: e3a05000 mov r5, #0
_Thread_queue_Initialize(
a000a318: e2840018 add r0, r4, #24
if ( !the_cond ) {
_Thread_Enable_dispatch();
return ENOMEM;
}
the_cond->process_shared = the_attr->process_shared;
a000a31c: e5843010 str r3, [r4, #16]
the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX;
_Thread_queue_Initialize(
a000a320: e1a01005 mov r1, r5
a000a324: e59f2048 ldr r2, [pc, #72] ; a000a374 <pthread_cond_init+0xc0>
a000a328: e3a03074 mov r3, #116 ; 0x74
return ENOMEM;
}
the_cond->process_shared = the_attr->process_shared;
the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX;
a000a32c: e5845014 str r5, [r4, #20]
_Thread_queue_Initialize(
a000a330: eb000ee1 bl a000debc <_Thread_queue_Initialize>
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000a334: e596201c ldr r2, [r6, #28]
Objects_Information *information,
Objects_Control *the_object,
uint32_t name
)
{
_Objects_Set_local_object(
a000a338: e5943008 ldr r3, [r4, #8]
a000a33c: e1d410b8 ldrh r1, [r4, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000a340: e7824101 str r4, [r2, r1, lsl #2]
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
a000a344: e584500c str r5, [r4, #12]
&_POSIX_Condition_variables_Information,
&the_cond->Object,
0
);
*cond = the_cond->Object.id;
a000a348: e5873000 str r3, [r7]
_Thread_Enable_dispatch();
a000a34c: eb000cf1 bl a000d718 <_Thread_Enable_dispatch>
return 0;
a000a350: e1a00005 mov r0, r5
a000a354: e8bd80f0 pop {r4, r5, r6, r7, pc}
/*
* Be careful about attributes when global!!!
*/
if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )
return EINVAL;
a000a358: e3a00016 mov r0, #22 <== NOT EXECUTED
a000a35c: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
if ( !the_attr->is_initialized )
return EINVAL;
a000a360: e3a00016 mov r0, #22 <== NOT EXECUTED
*cond = the_cond->Object.id;
_Thread_Enable_dispatch();
return 0;
}
a000a364: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
a000a3d4 <pthread_cond_timedwait>:
int pthread_cond_timedwait(
pthread_cond_t *cond,
pthread_mutex_t *mutex,
const struct timespec *abstime
)
{
a000a3d4: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
a000a3d8: e1a05000 mov r5, r0 <== NOT EXECUTED
a000a3dc: e1a04001 mov r4, r1 <== NOT EXECUTED
* is valid or not. If it isn't correct and in the future,
* then we do a polling operation and convert the UNSATISFIED
* status into the appropriate error.
*/
already_timedout = false;
status = _POSIX_Absolute_timeout_to_ticks(abstime, &ticks);
a000a3e0: e1a00002 mov r0, r2 <== NOT EXECUTED
a000a3e4: e1a0100d mov r1, sp <== NOT EXECUTED
a000a3e8: eb000123 bl a000a87c <_POSIX_Absolute_timeout_to_ticks> <== NOT EXECUTED
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
a000a3ec: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000a3f0: 03a00016 moveq r0, #22 <== NOT EXECUTED
* then we do a polling operation and convert the UNSATISFIED
* status into the appropriate error.
*/
already_timedout = false;
status = _POSIX_Absolute_timeout_to_ticks(abstime, &ticks);
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
a000a3f4: 0a000007 beq a000a418 <pthread_cond_timedwait+0x44> <== NOT EXECUTED
return EINVAL;
if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||
a000a3f8: e2433001 sub r3, r3, #1 <== NOT EXECUTED
status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )
already_timedout = true;
return _POSIX_Condition_variables_Wait_support(
a000a3fc: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a400: e1a01004 mov r1, r4 <== NOT EXECUTED
a000a404: e59d2000 ldr r2, [sp] <== NOT EXECUTED
a000a408: e3530001 cmp r3, #1 <== NOT EXECUTED
a000a40c: 83a03000 movhi r3, #0 <== NOT EXECUTED
a000a410: 93a03001 movls r3, #1 <== NOT EXECUTED
a000a414: eb000003 bl a000a428 <_POSIX_Condition_variables_Wait_support><== NOT EXECUTED
cond,
mutex,
ticks,
already_timedout
);
}
a000a418: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a000a180 <pthread_condattr_getpshared>:
int pthread_condattr_getpshared(
const pthread_condattr_t *attr,
int *pshared
)
{
if ( !attr )
a000a180: e3500000 cmp r0, #0 <== NOT EXECUTED
return EINVAL;
*pshared = attr->process_shared;
a000a184: 15903004 ldrne r3, [r0, #4] <== NOT EXECUTED
const pthread_condattr_t *attr,
int *pshared
)
{
if ( !attr )
return EINVAL;
a000a188: 03a00016 moveq r0, #22 <== NOT EXECUTED
*pshared = attr->process_shared;
return 0;
a000a18c: 13a00000 movne r0, #0 <== NOT EXECUTED
)
{
if ( !attr )
return EINVAL;
*pshared = attr->process_shared;
a000a190: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000a194: e12fff1e bx lr <== NOT EXECUTED
a000a1c4 <pthread_condattr_setpshared>:
int pthread_condattr_setpshared(
pthread_condattr_t *attr,
int pshared
)
{
if ( !attr )
a000a1c4: e3500000 cmp r0, #0 <== NOT EXECUTED
return EINVAL;
a000a1c8: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_condattr_setpshared(
pthread_condattr_t *attr,
int pshared
)
{
if ( !attr )
a000a1cc: 012fff1e bxeq lr <== NOT EXECUTED
return EINVAL;
switch ( pshared ) {
a000a1d0: e3510001 cmp r1, #1 <== NOT EXECUTED
case PTHREAD_PROCESS_SHARED:
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
a000a1d4: 95801004 strls r1, [r0, #4] <== NOT EXECUTED
return 0;
default:
return EINVAL;
a000a1d8: 83a00016 movhi r0, #22 <== NOT EXECUTED
switch ( pshared ) {
case PTHREAD_PROCESS_SHARED:
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
return 0;
a000a1dc: 93a00000 movls r0, #0 <== NOT EXECUTED
default:
return EINVAL;
}
}
a000a1e0: e12fff1e bx lr <== NOT EXECUTED
a00096e0 <pthread_create>:
pthread_t *thread,
const pthread_attr_t *attr,
void *(*start_routine)( void * ),
void *arg
)
{
a00096e0: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
int schedpolicy = SCHED_RR;
struct sched_param schedparam;
Objects_Name name;
int rc;
if ( !start_routine )
a00096e4: e3520000 cmp r2, #0
pthread_t *thread,
const pthread_attr_t *attr,
void *(*start_routine)( void * ),
void *arg
)
{
a00096e8: e24dd04c sub sp, sp, #76 ; 0x4c
a00096ec: e58d001c str r0, [sp, #28]
a00096f0: e58d3024 str r3, [sp, #36] ; 0x24
int schedpolicy = SCHED_RR;
struct sched_param schedparam;
Objects_Name name;
int rc;
if ( !start_routine )
a00096f4: e58d2020 str r2, [sp, #32]
return EFAULT;
a00096f8: 03a0500e moveq r5, #14
int schedpolicy = SCHED_RR;
struct sched_param schedparam;
Objects_Name name;
int rc;
if ( !start_routine )
a00096fc: 0a000082 beq a000990c <pthread_create+0x22c>
return EFAULT;
the_attr = (attr) ? attr : &_POSIX_Threads_Default_attributes;
a0009700: e59f4210 ldr r4, [pc, #528] ; a0009918 <pthread_create+0x238>
a0009704: e3510000 cmp r1, #0
a0009708: 11a04001 movne r4, r1
if ( !the_attr->is_initialized )
a000970c: e5943000 ldr r3, [r4]
a0009710: e3530000 cmp r3, #0
a0009714: 0a00007b beq a0009908 <pthread_create+0x228>
* stack space if it is allowed to allocate it itself.
*
* NOTE: If the user provides the stack we will let it drop below
* twice the minimum.
*/
if ( the_attr->stackaddr && !_Stack_Is_enough(the_attr->stacksize) )
a0009718: e5943004 ldr r3, [r4, #4]
a000971c: e3530000 cmp r3, #0
a0009720: 0a000004 beq a0009738 <pthread_create+0x58>
a0009724: e59f31f0 ldr r3, [pc, #496] ; a000991c <pthread_create+0x23c>
a0009728: e5942008 ldr r2, [r4, #8]
a000972c: e5933000 ldr r3, [r3]
a0009730: e1520003 cmp r2, r3
a0009734: 3a000073 bcc a0009908 <pthread_create+0x228>
* If inheritsched is set to PTHREAD_INHERIT_SCHED, then this thread
* inherits scheduling attributes from the creating thread. If it is
* PTHREAD_EXPLICIT_SCHED, then scheduling parameters come from the
* attributes structure.
*/
switch ( the_attr->inheritsched ) {
a0009738: e5943010 ldr r3, [r4, #16]
a000973c: e3530001 cmp r3, #1
a0009740: 0a000002 beq a0009750 <pthread_create+0x70>
a0009744: e3530002 cmp r3, #2
a0009748: 1a00006e bne a0009908 <pthread_create+0x228>
a000974c: ea000006 b a000976c <pthread_create+0x8c>
case PTHREAD_INHERIT_SCHED:
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0009750: e59f31c8 ldr r3, [pc, #456] ; a0009920 <pthread_create+0x240>
schedpolicy = api->schedpolicy;
schedparam = api->schedparam;
a0009754: e28dc028 add ip, sp, #40 ; 0x28
* PTHREAD_EXPLICIT_SCHED, then scheduling parameters come from the
* attributes structure.
*/
switch ( the_attr->inheritsched ) {
case PTHREAD_INHERIT_SCHED:
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0009758: e5933004 ldr r3, [r3, #4]
a000975c: e59350fc ldr r5, [r3, #252] ; 0xfc
schedpolicy = api->schedpolicy;
a0009760: e595a084 ldr sl, [r5, #132] ; 0x84
schedparam = api->schedparam;
a0009764: e2855088 add r5, r5, #136 ; 0x88
a0009768: ea000002 b a0009778 <pthread_create+0x98>
break;
case PTHREAD_EXPLICIT_SCHED:
schedpolicy = the_attr->schedpolicy;
a000976c: e594a014 ldr sl, [r4, #20]
schedparam = the_attr->schedparam;
a0009770: e28dc028 add ip, sp, #40 ; 0x28
a0009774: e2845018 add r5, r4, #24
a0009778: e8b5000f ldm r5!, {r0, r1, r2, r3}
a000977c: e8ac000f stmia ip!, {r0, r1, r2, r3}
/*
* Check the contentionscope since rtems only supports PROCESS wide
* contention (i.e. no system wide contention).
*/
if ( the_attr->contentionscope != PTHREAD_SCOPE_PROCESS )
a0009780: e594300c ldr r3, [r4, #12]
schedparam = api->schedparam;
break;
case PTHREAD_EXPLICIT_SCHED:
schedpolicy = the_attr->schedpolicy;
schedparam = the_attr->schedparam;
a0009784: e8950007 ldm r5, {r0, r1, r2}
a0009788: e88c0007 stm ip, {r0, r1, r2}
/*
* Check the contentionscope since rtems only supports PROCESS wide
* contention (i.e. no system wide contention).
*/
if ( the_attr->contentionscope != PTHREAD_SCOPE_PROCESS )
a000978c: e3530000 cmp r3, #0
return ENOTSUP;
a0009790: 13a05086 movne r5, #134 ; 0x86
/*
* Check the contentionscope since rtems only supports PROCESS wide
* contention (i.e. no system wide contention).
*/
if ( the_attr->contentionscope != PTHREAD_SCOPE_PROCESS )
a0009794: 1a00005c bne a000990c <pthread_create+0x22c>
return ENOTSUP;
/*
* Interpret the scheduling parameters.
*/
if ( !_POSIX_Priority_Is_valid( schedparam.sched_priority ) )
a0009798: e59d0028 ldr r0, [sp, #40] ; 0x28
a000979c: eb001810 bl a000f7e4 <_POSIX_Priority_Is_valid>
a00097a0: e3500000 cmp r0, #0
a00097a4: 0a000057 beq a0009908 <pthread_create+0x228>
return EINVAL;
core_priority = _POSIX_Priority_To_core( schedparam.sched_priority );
a00097a8: e28d804c add r8, sp, #76 ; 0x4c
a00097ac: e538b024 ldr fp, [r8, #-36]! ; 0x24
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(
int priority
)
{
return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
a00097b0: e59f316c ldr r3, [pc, #364] ; a0009924 <pthread_create+0x244>
/*
* Set the core scheduling policy information.
*/
rc = _POSIX_Thread_Translate_sched_param(
a00097b4: e1a0000a mov r0, sl
a00097b8: e1a01008 mov r1, r8
a00097bc: e5d39000 ldrb r9, [r3]
a00097c0: e28d2048 add r2, sp, #72 ; 0x48
a00097c4: e28d3044 add r3, sp, #68 ; 0x44
a00097c8: eb001810 bl a000f810 <_POSIX_Thread_Translate_sched_param>
schedpolicy,
&schedparam,
&budget_algorithm,
&budget_callout
);
if ( rc )
a00097cc: e2505000 subs r5, r0, #0
a00097d0: 1a00004d bne a000990c <pthread_create+0x22c>
#endif
/*
* Lock the allocator mutex for protection
*/
_RTEMS_Lock_allocator();
a00097d4: e59f614c ldr r6, [pc, #332] ; a0009928 <pthread_create+0x248>
a00097d8: e5960000 ldr r0, [r6]
a00097dc: eb00059f bl a000ae60 <_API_Mutex_Lock>
* _POSIX_Threads_Allocate
*/
RTEMS_INLINE_ROUTINE Thread_Control *_POSIX_Threads_Allocate( void )
{
return (Thread_Control *) _Objects_Allocate( &_POSIX_Threads_Information );
a00097e0: e59f0144 ldr r0, [pc, #324] ; a000992c <pthread_create+0x24c>
a00097e4: eb00081b bl a000b858 <_Objects_Allocate>
* Allocate the thread control block.
*
* NOTE: Global threads are not currently supported.
*/
the_thread = _POSIX_Threads_Allocate();
if ( !the_thread ) {
a00097e8: e2507000 subs r7, r0, #0
a00097ec: 0a000019 beq a0009858 <pthread_create+0x178>
static inline size_t _POSIX_Threads_Ensure_minimum_stack (
size_t size
)
{
if ( size >= PTHREAD_MINIMUM_STACK_SIZE )
a00097f0: e59f3124 ldr r3, [pc, #292] ; a000991c <pthread_create+0x23c>
/*
* Initialize the core thread for this task.
*/
name.name_p = NULL; /* posix threads don't have a name by default */
status = _Thread_Initialize(
a00097f4: e59d1048 ldr r1, [sp, #72] ; 0x48
a00097f8: e594c008 ldr ip, [r4, #8]
static inline size_t _POSIX_Threads_Ensure_minimum_stack (
size_t size
)
{
if ( size >= PTHREAD_MINIMUM_STACK_SIZE )
a00097fc: e5933000 ldr r3, [r3]
/*
* Initialize the core thread for this task.
*/
name.name_p = NULL; /* posix threads don't have a name by default */
status = _Thread_Initialize(
a0009800: e5942004 ldr r2, [r4, #4]
a0009804: e58d100c str r1, [sp, #12]
a0009808: e59d1044 ldr r1, [sp, #68] ; 0x44
a000980c: e06b9009 rsb r9, fp, r9
static inline size_t _POSIX_Threads_Ensure_minimum_stack (
size_t size
)
{
if ( size >= PTHREAD_MINIMUM_STACK_SIZE )
a0009810: e1a03083 lsl r3, r3, #1
/*
* Initialize the core thread for this task.
*/
name.name_p = NULL; /* posix threads don't have a name by default */
status = _Thread_Initialize(
a0009814: e58d9004 str r9, [sp, #4]
a0009818: e58d1010 str r1, [sp, #16]
a000981c: e153000c cmp r3, ip
a0009820: 31a0300c movcc r3, ip
a0009824: e3a09001 mov r9, #1
a0009828: e59f00fc ldr r0, [pc, #252] ; a000992c <pthread_create+0x24c>
a000982c: e1a01007 mov r1, r7
a0009830: e58d5000 str r5, [sp]
a0009834: e58d9008 str r9, [sp, #8]
a0009838: e58d5014 str r5, [sp, #20]
a000983c: e58d5018 str r5, [sp, #24]
a0009840: eb000c08 bl a000c868 <_Thread_Initialize>
budget_callout,
0, /* isr level */
name /* posix threads don't have a name */
);
if ( !status ) {
a0009844: e3500000 cmp r0, #0
a0009848: 1a000006 bne a0009868 <pthread_create+0x188>
RTEMS_INLINE_ROUTINE void _POSIX_Threads_Free (
Thread_Control *the_pthread
)
{
_Objects_Free( &_POSIX_Threads_Information, &the_pthread->Object );
a000984c: e59f00d8 ldr r0, [pc, #216] ; a000992c <pthread_create+0x24c>
a0009850: e1a01007 mov r1, r7
a0009854: eb0008c8 bl a000bb7c <_Objects_Free>
_POSIX_Threads_Free( the_thread );
_RTEMS_Unlock_allocator();
a0009858: e5960000 ldr r0, [r6]
a000985c: eb000598 bl a000aec4 <_API_Mutex_Unlock>
return EAGAIN;
a0009860: e3a0500b mov r5, #11
a0009864: ea000028 b a000990c <pthread_create+0x22c>
}
/*
* finish initializing the per API structure
*/
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
a0009868: e59760fc ldr r6, [r7, #252] ; 0xfc
api->Attributes = *the_attr;
a000986c: e1a0e004 mov lr, r4
a0009870: e8be000f ldm lr!, {r0, r1, r2, r3}
a0009874: e1a0c006 mov ip, r6
a0009878: e8ac000f stmia ip!, {r0, r1, r2, r3}
a000987c: e8be000f ldm lr!, {r0, r1, r2, r3}
a0009880: e8ac000f stmia ip!, {r0, r1, r2, r3}
a0009884: e8be000f ldm lr!, {r0, r1, r2, r3}
a0009888: e8ac000f stmia ip!, {r0, r1, r2, r3}
a000988c: e89e000f ldm lr, {r0, r1, r2, r3}
a0009890: e88c000f stm ip, {r0, r1, r2, r3}
api->detachstate = the_attr->detachstate;
a0009894: e594303c ldr r3, [r4, #60] ; 0x3c
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
a0009898: e286c088 add ip, r6, #136 ; 0x88
* finish initializing the per API structure
*/
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
a000989c: e5863040 str r3, [r6, #64] ; 0x40
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
a00098a0: e8b8000f ldm r8!, {r0, r1, r2, r3}
a00098a4: e8ac000f stmia ip!, {r0, r1, r2, r3}
a00098a8: e8980007 ldm r8, {r0, r1, r2}
*/
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
api->schedpolicy = schedpolicy;
a00098ac: e586a084 str sl, [r6, #132] ; 0x84
api->schedparam = schedparam;
a00098b0: e88c0007 stm ip, {r0, r1, r2}
/*
* POSIX threads are allocated and started in one operation.
*/
status = _Thread_Start(
a00098b4: e59d3024 ldr r3, [sp, #36] ; 0x24
a00098b8: e1a00007 mov r0, r7
a00098bc: e1a01009 mov r1, r9
a00098c0: e59d2020 ldr r2, [sp, #32]
a00098c4: e58d5000 str r5, [sp]
a00098c8: eb000e3b bl a000d1bc <_Thread_Start>
_RTEMS_Unlock_allocator();
return EINVAL;
}
#endif
if ( schedpolicy == SCHED_SPORADIC ) {
a00098cc: e35a0004 cmp sl, #4
a00098d0: 1a000005 bne a00098ec <pthread_create+0x20c>
_Watchdog_Insert_ticks(
a00098d4: e2860090 add r0, r6, #144 ; 0x90 <== NOT EXECUTED
a00098d8: eb000eaf bl a000d39c <_Timespec_To_ticks> <== NOT EXECUTED
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a00098dc: e28610a8 add r1, r6, #168 ; 0xa8 <== NOT EXECUTED
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a00098e0: e58600b4 str r0, [r6, #180] ; 0xb4 <== NOT EXECUTED
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a00098e4: e59f0044 ldr r0, [pc, #68] ; a0009930 <pthread_create+0x250><== NOT EXECUTED
a00098e8: eb000f71 bl a000d6b4 <_Watchdog_Insert> <== NOT EXECUTED
}
/*
* Return the id and indicate we successfully created the thread
*/
*thread = the_thread->Object.id;
a00098ec: e5973008 ldr r3, [r7, #8]
a00098f0: e59d201c ldr r2, [sp, #28]
a00098f4: e5823000 str r3, [r2]
_RTEMS_Unlock_allocator();
a00098f8: e59f3028 ldr r3, [pc, #40] ; a0009928 <pthread_create+0x248>
a00098fc: e5930000 ldr r0, [r3]
a0009900: eb00056f bl a000aec4 <_API_Mutex_Unlock>
return 0;
a0009904: ea000000 b a000990c <pthread_create+0x22c>
/*
* Interpret the scheduling parameters.
*/
if ( !_POSIX_Priority_Is_valid( schedparam.sched_priority ) )
return EINVAL;
a0009908: e3a05016 mov r5, #22 <== NOT EXECUTED
*/
*thread = the_thread->Object.id;
_RTEMS_Unlock_allocator();
return 0;
}
a000990c: e1a00005 mov r0, r5
a0009910: e28dd04c add sp, sp, #76 ; 0x4c
a0009914: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
a0009934 <pthread_equal>:
break;
}
return status;
#endif
}
a0009934: e1500001 cmp r0, r1 <== NOT EXECUTED
a0009938: 13a00000 movne r0, #0 <== NOT EXECUTED
a000993c: 03a00001 moveq r0, #1 <== NOT EXECUTED
a0009940: e12fff1e bx lr <== NOT EXECUTED
a00092a0 <pthread_getcpuclockid>:
int pthread_getcpuclockid(
pthread_t pid,
clockid_t *clock_id
)
{
a00092a0: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a00092a4: eb0021d4 bl a00119fc <__errno> <== NOT EXECUTED
a00092a8: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a00092ac: e5803000 str r3, [r0] <== NOT EXECUTED
}
a00092b0: e3e00000 mvn r0, #0 <== NOT EXECUTED
a00092b4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a00095cc <pthread_getspecific>:
*/
void *pthread_getspecific(
pthread_key_t key
)
{
a00095cc: e92d4011 push {r0, r4, lr}
a00095d0: e1a01000 mov r1, r0
pthread_key_t id,
Objects_Locations *location
)
{
return (POSIX_Keys_Control *)
_Objects_Get( &_POSIX_Keys_Information, (Objects_Id) id, location );
a00095d4: e1a0200d mov r2, sp
a00095d8: e59f0040 ldr r0, [pc, #64] ; a0009620 <pthread_getspecific+0x54>
a00095dc: eb000908 bl a000ba04 <_Objects_Get>
uint32_t index;
Objects_Locations location;
void *key_data;
the_key = _POSIX_Keys_Get( key, &location );
switch ( location ) {
a00095e0: e59d3000 ldr r3, [sp]
a00095e4: e3530000 cmp r3, #0
#endif
case OBJECTS_ERROR:
break;
}
return NULL;
a00095e8: 13a04000 movne r4, #0
uint32_t index;
Objects_Locations location;
void *key_data;
the_key = _POSIX_Keys_Get( key, &location );
switch ( location ) {
a00095ec: 1a000009 bne a0009618 <pthread_getspecific+0x4c>
case OBJECTS_LOCAL:
api = _Objects_Get_API( _Thread_Executing->Object.id );
a00095f0: e59f302c ldr r3, [pc, #44] ; a0009624 <pthread_getspecific+0x58><== NOT EXECUTED
a00095f4: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
a00095f8: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API(
Objects_Id id
)
{
return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS);
a00095fc: e1a02c23 lsr r2, r3, #24 <== NOT EXECUTED
a0009600: e2022007 and r2, r2, #7 <== NOT EXECUTED
index = _Objects_Get_index( _Thread_Executing->Object.id );
key_data = (void *) the_key->Values[ api ][ index ];
a0009604: e2822005 add r2, r2, #5 <== NOT EXECUTED
a0009608: e7902102 ldr r2, [r0, r2, lsl #2] <== NOT EXECUTED
the_key = _POSIX_Keys_Get( key, &location );
switch ( location ) {
case OBJECTS_LOCAL:
api = _Objects_Get_API( _Thread_Executing->Object.id );
index = _Objects_Get_index( _Thread_Executing->Object.id );
a000960c: e1a03803 lsl r3, r3, #16 <== NOT EXECUTED
key_data = (void *) the_key->Values[ api ][ index ];
a0009610: e7924723 ldr r4, [r2, r3, lsr #14] <== NOT EXECUTED
_Thread_Enable_dispatch();
a0009614: eb000bb2 bl a000c4e4 <_Thread_Enable_dispatch> <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return NULL;
}
a0009618: e1a00004 mov r0, r4
a000961c: e8bd8018 pop {r3, r4, pc}
a000ece0 <pthread_join>:
int pthread_join(
pthread_t thread,
void **value_ptr
)
{
a000ece0: e92d4033 push {r0, r1, r4, r5, lr}
a000ece4: e1a03000 mov r3, r0
a000ece8: e1a04001 mov r4, r1
a000ecec: e59f0088 ldr r0, [pc, #136] ; a000ed7c <pthread_join+0x9c>
a000ecf0: e1a01003 mov r1, r3
a000ecf4: e28d2004 add r2, sp, #4
a000ecf8: eb00089a bl a0010f68 <_Objects_Get>
POSIX_API_Control *api;
Objects_Locations location;
void *return_pointer;
the_thread = _POSIX_Threads_Get( thread, &location );
switch ( location ) {
a000ecfc: e59d5004 ldr r5, [sp, #4]
a000ed00: e3550000 cmp r5, #0
#endif
case OBJECTS_ERROR:
break;
}
return ESRCH;
a000ed04: 13a00003 movne r0, #3
POSIX_API_Control *api;
Objects_Locations location;
void *return_pointer;
the_thread = _POSIX_Threads_Get( thread, &location );
switch ( location ) {
a000ed08: 1a00001a bne a000ed78 <pthread_join+0x98>
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
a000ed0c: e59030fc ldr r3, [r0, #252] ; 0xfc
if ( api->detachstate == PTHREAD_CREATE_DETACHED ) {
a000ed10: e5932040 ldr r2, [r3, #64] ; 0x40
a000ed14: e3520000 cmp r2, #0
a000ed18: 1a000002 bne a000ed28 <pthread_join+0x48>
_Thread_Enable_dispatch();
a000ed1c: eb000b49 bl a0011a48 <_Thread_Enable_dispatch>
return EINVAL;
a000ed20: e3a00016 mov r0, #22
a000ed24: ea000013 b a000ed78 <pthread_join+0x98>
RTEMS_INLINE_ROUTINE bool _Thread_Is_executing (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Executing );
a000ed28: e59f2050 ldr r2, [pc, #80] ; a000ed80 <pthread_join+0xa0>
a000ed2c: e5922004 ldr r2, [r2, #4]
}
if ( _Thread_Is_executing( the_thread ) ) {
a000ed30: e1500002 cmp r0, r2
a000ed34: 1a000002 bne a000ed44 <pthread_join+0x64>
_Thread_Enable_dispatch();
a000ed38: eb000b42 bl a0011a48 <_Thread_Enable_dispatch>
return EDEADLK;
a000ed3c: e3a0002d mov r0, #45 ; 0x2d <== NOT EXECUTED
a000ed40: ea00000c b a000ed78 <pthread_join+0x98> <== NOT EXECUTED
/*
* Put ourself on the threads join list
*/
_Thread_Executing->Wait.return_argument = &return_pointer;
a000ed44: e582d028 str sp, [r2, #40] ; 0x28
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a000ed48: e3a02001 mov r2, #1
_Thread_queue_Enter_critical_section( &api->Join_List );
_Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT );
a000ed4c: e2830044 add r0, r3, #68 ; 0x44
a000ed50: e5832074 str r2, [r3, #116] ; 0x74
a000ed54: e1a01005 mov r1, r5
a000ed58: e59f2024 ldr r2, [pc, #36] ; a000ed84 <pthread_join+0xa4>
a000ed5c: eb000c62 bl a0011eec <_Thread_queue_Enqueue_with_handler>
_Thread_Enable_dispatch();
a000ed60: eb000b38 bl a0011a48 <_Thread_Enable_dispatch>
if ( value_ptr )
a000ed64: e3540000 cmp r4, #0
*value_ptr = return_pointer;
a000ed68: 159d3000 ldrne r3, [sp]
return 0;
a000ed6c: 11a00005 movne r0, r5
a000ed70: 01a00004 moveq r0, r4
_Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT );
_Thread_Enable_dispatch();
if ( value_ptr )
*value_ptr = return_pointer;
a000ed74: 15843000 strne r3, [r4]
case OBJECTS_ERROR:
break;
}
return ESRCH;
}
a000ed78: e8bd803c pop {r2, r3, r4, r5, pc}
a0025bfc <pthread_kill>:
int pthread_kill(
pthread_t thread,
int sig
)
{
a0025bfc: e92d41f1 push {r0, r4, r5, r6, r7, r8, lr}
POSIX_API_Control *api;
Thread_Control *the_thread;
Objects_Locations location;
if ( !sig )
a0025c00: e2514000 subs r4, r1, #0
int pthread_kill(
pthread_t thread,
int sig
)
{
a0025c04: e1a03000 mov r3, r0
POSIX_API_Control *api;
Thread_Control *the_thread;
Objects_Locations location;
if ( !sig )
a0025c08: 0a000002 beq a0025c18 <pthread_kill+0x1c>
static inline bool is_valid_signo(
int signo
)
{
return ((signo) >= 1 && (signo) <= 32 );
a0025c0c: e2447001 sub r7, r4, #1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(sig) )
a0025c10: e357001f cmp r7, #31
a0025c14: 9a000002 bls a0025c24 <pthread_kill+0x28>
rtems_set_errno_and_return_minus_one( EINVAL );
a0025c18: ebffc19c bl a0016290 <__errno> <== NOT EXECUTED
a0025c1c: e3a03016 mov r3, #22 <== NOT EXECUTED
a0025c20: ea000024 b a0025cb8 <pthread_kill+0xbc> <== NOT EXECUTED
pthread_t id,
Objects_Locations *location
)
{
return (Thread_Control *)
_Objects_Get( &_POSIX_Threads_Information, (Objects_Id)id, location );
a0025c24: e59f0098 ldr r0, [pc, #152] ; a0025cc4 <pthread_kill+0xc8>
a0025c28: e1a01003 mov r1, r3
a0025c2c: e1a0200d mov r2, sp
a0025c30: ebffa7e2 bl a000fbc0 <_Objects_Get>
the_thread = _POSIX_Threads_Get( thread, &location );
switch ( location ) {
a0025c34: e59d8000 ldr r8, [sp]
a0025c38: e1a06000 mov r6, r0
a0025c3c: e3580000 cmp r8, #0
a0025c40: 1a00001a bne a0025cb0 <pthread_kill+0xb4>
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
if ( sig ) {
if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN ) {
a0025c44: e59f207c ldr r2, [pc, #124] ; a0025cc8 <pthread_kill+0xcc>
a0025c48: e3a0100c mov r1, #12
case OBJECTS_LOCAL:
/*
* If sig == 0 then just validate arguments
*/
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
a0025c4c: e59030fc ldr r3, [r0, #252] ; 0xfc
if ( sig ) {
if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN ) {
a0025c50: e0222491 mla r2, r1, r4, r2
a0025c54: e5922008 ldr r2, [r2, #8]
a0025c58: e3520001 cmp r2, #1
a0025c5c: 1a000002 bne a0025c6c <pthread_kill+0x70>
_Thread_Enable_dispatch();
a0025c60: ebffaab4 bl a0010738 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a0025c64: e1a00008 mov r0, r8 <== NOT EXECUTED
a0025c68: ea000014 b a0025cc0 <pthread_kill+0xc4> <== NOT EXECUTED
}
/* XXX critical section */
api->signals_pending |= signo_to_mask( sig );
a0025c6c: e59320d4 ldr r2, [r3, #212] ; 0xd4
static inline sigset_t signo_to_mask(
uint32_t sig
)
{
return 1u << (sig - 1);
a0025c70: e3a05001 mov r5, #1
(void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL );
a0025c74: e1a01004 mov r1, r4
return 0;
}
/* XXX critical section */
api->signals_pending |= signo_to_mask( sig );
a0025c78: e1827715 orr r7, r2, r5, lsl r7
(void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL );
a0025c7c: e1a02008 mov r2, r8
return 0;
}
/* XXX critical section */
api->signals_pending |= signo_to_mask( sig );
a0025c80: e58370d4 str r7, [r3, #212] ; 0xd4
(void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL );
a0025c84: ebffff90 bl a0025acc <_POSIX_signals_Unblock_thread>
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
a0025c88: e59f303c ldr r3, [pc, #60] ; a0025ccc <pthread_kill+0xd0>
a0025c8c: e5932000 ldr r2, [r3]
a0025c90: e3520000 cmp r2, #0
a0025c94: 0a000002 beq a0025ca4 <pthread_kill+0xa8>
a0025c98: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED
a0025c9c: e1560002 cmp r6, r2 <== NOT EXECUTED
_Thread_Dispatch_necessary = true;
a0025ca0: 05c35010 strbeq r5, [r3, #16] <== NOT EXECUTED
}
_Thread_Enable_dispatch();
a0025ca4: ebffaaa3 bl a0010738 <_Thread_Enable_dispatch>
return 0;
a0025ca8: e3a00000 mov r0, #0
a0025cac: ea000003 b a0025cc0 <pthread_kill+0xc4>
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( ESRCH );
a0025cb0: ebffc176 bl a0016290 <__errno> <== NOT EXECUTED
a0025cb4: e3a03003 mov r3, #3 <== NOT EXECUTED
a0025cb8: e5803000 str r3, [r0] <== NOT EXECUTED
a0025cbc: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a0025cc0: e8bd81f8 pop {r3, r4, r5, r6, r7, r8, pc}
a000b5e4 <pthread_mutex_destroy>:
*/
int pthread_mutex_destroy(
pthread_mutex_t *mutex
)
{
a000b5e4: e92d4031 push {r0, r4, r5, lr}
register POSIX_Mutex_Control *the_mutex;
Objects_Locations location;
the_mutex = _POSIX_Mutex_Get( mutex, &location );
a000b5e8: e1a0100d mov r1, sp
a000b5ec: eb000018 bl a000b654 <_POSIX_Mutex_Get>
switch ( location ) {
a000b5f0: e59d5000 ldr r5, [sp]
)
{
register POSIX_Mutex_Control *the_mutex;
Objects_Locations location;
the_mutex = _POSIX_Mutex_Get( mutex, &location );
a000b5f4: e1a04000 mov r4, r0
switch ( location ) {
a000b5f8: e3550000 cmp r5, #0
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000b5fc: 13a00016 movne r0, #22
{
register POSIX_Mutex_Control *the_mutex;
Objects_Locations location;
the_mutex = _POSIX_Mutex_Get( mutex, &location );
switch ( location ) {
a000b600: 1a000011 bne a000b64c <pthread_mutex_destroy+0x68>
/*
* XXX: There is an error for the mutex being locked
* or being in use by a condition variable.
*/
if ( _CORE_mutex_Is_locked( &the_mutex->Mutex ) ) {
a000b604: e5943064 ldr r3, [r4, #100] ; 0x64
a000b608: e3530000 cmp r3, #0
a000b60c: 1a000002 bne a000b61c <pthread_mutex_destroy+0x38>
_Thread_Enable_dispatch();
a000b610: eb000d52 bl a000eb60 <_Thread_Enable_dispatch> <== NOT EXECUTED
return EBUSY;
a000b614: e3a00010 mov r0, #16 <== NOT EXECUTED
a000b618: ea00000b b a000b64c <pthread_mutex_destroy+0x68> <== NOT EXECUTED
}
_Objects_Close( &_POSIX_Mutex_Information, &the_mutex->Object );
a000b61c: e59f002c ldr r0, [pc, #44] ; a000b650 <pthread_mutex_destroy+0x6c>
a000b620: e1a01004 mov r1, r4
a000b624: eb000996 bl a000dc84 <_Objects_Close>
_CORE_mutex_Flush( &the_mutex->Mutex, NULL, EINVAL );
a000b628: e3a02016 mov r2, #22
a000b62c: e2840014 add r0, r4, #20
a000b630: e1a01005 mov r1, r5
a000b634: eb000719 bl a000d2a0 <_CORE_mutex_Flush>
RTEMS_INLINE_ROUTINE void _POSIX_Mutex_Free (
POSIX_Mutex_Control *the_mutex
)
{
_Objects_Free( &_POSIX_Mutex_Information, &the_mutex->Object );
a000b638: e59f0010 ldr r0, [pc, #16] ; a000b650 <pthread_mutex_destroy+0x6c>
a000b63c: e1a01004 mov r1, r4
a000b640: eb000a36 bl a000df20 <_Objects_Free>
_POSIX_Mutex_Free( the_mutex );
_Thread_Enable_dispatch();
a000b644: eb000d45 bl a000eb60 <_Thread_Enable_dispatch>
return 0;
a000b648: e1a00005 mov r0, r5
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
a000b64c: e8bd8038 pop {r3, r4, r5, pc}
a000b770 <pthread_mutex_init>:
CORE_mutex_Attributes *the_mutex_attr;
const pthread_mutexattr_t *the_attr;
CORE_mutex_Disciplines the_discipline;
if ( attr ) the_attr = attr;
else the_attr = &_POSIX_Mutex_Default_attributes;
a000b770: e59f3134 ldr r3, [pc, #308] ; a000b8ac <pthread_mutex_init+0x13c>
a000b774: e3510000 cmp r1, #0
int pthread_mutex_init(
pthread_mutex_t *mutex,
const pthread_mutexattr_t *attr
)
{
a000b778: e92d40f0 push {r4, r5, r6, r7, lr}
CORE_mutex_Attributes *the_mutex_attr;
const pthread_mutexattr_t *the_attr;
CORE_mutex_Disciplines the_discipline;
if ( attr ) the_attr = attr;
else the_attr = &_POSIX_Mutex_Default_attributes;
a000b77c: 11a06001 movne r6, r1
a000b780: 01a06003 moveq r6, r3
/* Check for NULL mutex */
if ( !mutex )
a000b784: e2505000 subs r5, r0, #0
a000b788: 0a000043 beq a000b89c <pthread_mutex_init+0x12c>
}
}
}
#endif
if ( !the_attr->is_initialized )
a000b78c: e5963000 ldr r3, [r6]
a000b790: e3530000 cmp r3, #0
a000b794: 0a000040 beq a000b89c <pthread_mutex_init+0x12c>
return EINVAL;
/*
* We only support process private mutexes.
*/
if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )
a000b798: e5963004 ldr r3, [r6, #4]
a000b79c: e3530001 cmp r3, #1
a000b7a0: 0a00003b beq a000b894 <pthread_mutex_init+0x124>
return ENOSYS;
if ( the_attr->process_shared != PTHREAD_PROCESS_PRIVATE )
a000b7a4: e3530000 cmp r3, #0
a000b7a8: 1a00003b bne a000b89c <pthread_mutex_init+0x12c>
return EINVAL;
/*
* Determine the discipline of the mutex
*/
switch ( the_attr->protocol ) {
a000b7ac: e596700c ldr r7, [r6, #12]
a000b7b0: e3570001 cmp r7, #1
a000b7b4: 0a000006 beq a000b7d4 <pthread_mutex_init+0x64>
a000b7b8: e3570002 cmp r7, #2
a000b7bc: 0a000002 beq a000b7cc <pthread_mutex_init+0x5c>
a000b7c0: e3570000 cmp r7, #0
a000b7c4: 1a000034 bne a000b89c <pthread_mutex_init+0x12c>
a000b7c8: ea000002 b a000b7d8 <pthread_mutex_init+0x68>
break;
case PTHREAD_PRIO_INHERIT:
the_discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT;
break;
case PTHREAD_PRIO_PROTECT:
the_discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING;
a000b7cc: e3a07003 mov r7, #3 <== NOT EXECUTED
break;
a000b7d0: ea000000 b a000b7d8 <pthread_mutex_init+0x68> <== NOT EXECUTED
switch ( the_attr->protocol ) {
case PTHREAD_PRIO_NONE:
the_discipline = CORE_MUTEX_DISCIPLINES_FIFO;
break;
case PTHREAD_PRIO_INHERIT:
the_discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT;
a000b7d4: e3a07002 mov r7, #2 <== NOT EXECUTED
}
/*
* Validate the priority ceiling field -- should always be valid.
*/
if ( !_POSIX_Priority_Is_valid( the_attr->prio_ceiling ) )
a000b7d8: e5960008 ldr r0, [r6, #8]
a000b7dc: eb0000c3 bl a000baf0 <_POSIX_Priority_Is_valid>
a000b7e0: e3500000 cmp r0, #0
a000b7e4: 0a00002c beq a000b89c <pthread_mutex_init+0x12c>
#if defined(_UNIX98_THREAD_MUTEX_ATTRIBUTES)
/*
* Validate the mutex type and set appropriate SuperCore mutex
* attributes.
*/
switch ( the_attr->type ) {
a000b7e8: e5963010 ldr r3, [r6, #16]
a000b7ec: e3530003 cmp r3, #3
a000b7f0: 8a00002b bhi a000b8a4 <pthread_mutex_init+0x134>
a000b7f4: e59f30b4 ldr r3, [pc, #180] ; a000b8b0 <pthread_mutex_init+0x140>
a000b7f8: e5932000 ldr r2, [r3]
a000b7fc: e2822001 add r2, r2, #1
a000b800: e5832000 str r2, [r3]
* _POSIX_Mutex_Allocate
*/
RTEMS_INLINE_ROUTINE POSIX_Mutex_Control *_POSIX_Mutex_Allocate( void )
{
return (POSIX_Mutex_Control *) _Objects_Allocate( &_POSIX_Mutex_Information );
a000b804: e59f00a8 ldr r0, [pc, #168] ; a000b8b4 <pthread_mutex_init+0x144>
a000b808: eb0008fb bl a000dbfc <_Objects_Allocate>
*/
_Thread_Disable_dispatch();
the_mutex = _POSIX_Mutex_Allocate();
if ( !the_mutex ) {
a000b80c: e2504000 subs r4, r0, #0
a000b810: 1a000002 bne a000b820 <pthread_mutex_init+0xb0>
_Thread_Enable_dispatch();
a000b814: eb000cd1 bl a000eb60 <_Thread_Enable_dispatch>
return EAGAIN;
a000b818: e3a0000b mov r0, #11
a000b81c: e8bd80f0 pop {r4, r5, r6, r7, pc}
}
the_mutex->process_shared = the_attr->process_shared;
a000b820: e5963004 ldr r3, [r6, #4]
if ( the_attr->recursive )
the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
else
the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR;
the_mutex_attr->only_owner_release = true;
a000b824: e3a02001 mov r2, #1
return EAGAIN;
}
the_mutex->process_shared = the_attr->process_shared;
the_mutex_attr = &the_mutex->Mutex.Attributes;
a000b828: e2841054 add r1, r4, #84 ; 0x54
if ( !the_mutex ) {
_Thread_Enable_dispatch();
return EAGAIN;
}
the_mutex->process_shared = the_attr->process_shared;
a000b82c: e5843010 str r3, [r4, #16]
the_mutex_attr = &the_mutex->Mutex.Attributes;
if ( the_attr->recursive )
a000b830: e5963014 ldr r3, [r6, #20]
the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
else
the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR;
the_mutex_attr->only_owner_release = true;
a000b834: e5c42058 strb r2, [r4, #88] ; 0x58
the_mutex->process_shared = the_attr->process_shared;
the_mutex_attr = &the_mutex->Mutex.Attributes;
if ( the_attr->recursive )
a000b838: e3530000 cmp r3, #0
the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
a000b83c: 13a03000 movne r3, #0
else
the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR;
a000b840: 03a03001 moveq r3, #1
a000b844: e5843054 str r3, [r4, #84] ; 0x54
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(
int priority
)
{
return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
a000b848: e59f3068 ldr r3, [pc, #104] ; a000b8b8 <pthread_mutex_init+0x148>
a000b84c: e5d30000 ldrb r0, [r3]
a000b850: e5963008 ldr r3, [r6, #8]
the_mutex_attr->only_owner_release = true;
the_mutex_attr->priority_ceiling =
_POSIX_Priority_To_core( the_attr->prio_ceiling );
the_mutex_attr->discipline = the_discipline;
a000b854: e584705c str r7, [r4, #92] ; 0x5c
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
a000b858: e3a06000 mov r6, #0
a000b85c: e0633000 rsb r3, r3, r0
if ( the_attr->recursive )
the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
else
the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR;
the_mutex_attr->only_owner_release = true;
the_mutex_attr->priority_ceiling =
a000b860: e5843060 str r3, [r4, #96] ; 0x60
the_mutex_attr->discipline = the_discipline;
/*
* Must be initialized to unlocked.
*/
_CORE_mutex_Initialize(
a000b864: e2840014 add r0, r4, #20
a000b868: eb00068d bl a000d2a4 <_CORE_mutex_Initialize>
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000b86c: e59f2040 ldr r2, [pc, #64] ; a000b8b4 <pthread_mutex_init+0x144>
Objects_Information *information,
Objects_Control *the_object,
uint32_t name
)
{
_Objects_Set_local_object(
a000b870: e5943008 ldr r3, [r4, #8]
a000b874: e1d410b8 ldrh r1, [r4, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000b878: e592201c ldr r2, [r2, #28]
a000b87c: e7824101 str r4, [r2, r1, lsl #2]
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
a000b880: e584600c str r6, [r4, #12]
CORE_MUTEX_UNLOCKED
);
_Objects_Open_u32( &_POSIX_Mutex_Information, &the_mutex->Object, 0 );
*mutex = the_mutex->Object.id;
a000b884: e5853000 str r3, [r5]
_Thread_Enable_dispatch();
a000b888: eb000cb4 bl a000eb60 <_Thread_Enable_dispatch>
return 0;
a000b88c: e1a00006 mov r0, r6
a000b890: e8bd80f0 pop {r4, r5, r6, r7, pc}
/*
* We only support process private mutexes.
*/
if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )
return ENOSYS;
a000b894: e3a00058 mov r0, #88 ; 0x58 <== NOT EXECUTED
a000b898: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
/*
* Validate the priority ceiling field -- should always be valid.
*/
if ( !_POSIX_Priority_Is_valid( the_attr->prio_ceiling ) )
return EINVAL;
a000b89c: e3a00016 mov r0, #22 <== NOT EXECUTED
a000b8a0: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
case PTHREAD_MUTEX_ERRORCHECK:
case PTHREAD_MUTEX_DEFAULT:
break;
default:
return EINVAL;
a000b8a4: e3a00016 mov r0, #22 <== NOT EXECUTED
*mutex = the_mutex->Object.id;
_Thread_Enable_dispatch();
return 0;
}
a000b8a8: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
a000b928 <pthread_mutex_setprioceiling>:
int pthread_mutex_setprioceiling(
pthread_mutex_t *mutex,
int prioceiling,
int *old_ceiling
)
{
a000b928: e92d41f1 push {r0, r4, r5, r6, r7, r8, lr} <== NOT EXECUTED
register POSIX_Mutex_Control *the_mutex;
Objects_Locations location;
Priority_Control the_priority;
if ( !old_ceiling )
a000b92c: e2528000 subs r8, r2, #0 <== NOT EXECUTED
int pthread_mutex_setprioceiling(
pthread_mutex_t *mutex,
int prioceiling,
int *old_ceiling
)
{
a000b930: e1a04000 mov r4, r0 <== NOT EXECUTED
a000b934: e1a05001 mov r5, r1 <== NOT EXECUTED
register POSIX_Mutex_Control *the_mutex;
Objects_Locations location;
Priority_Control the_priority;
if ( !old_ceiling )
a000b938: 0a00001b beq a000b9ac <pthread_mutex_setprioceiling+0x84> <== NOT EXECUTED
return EINVAL;
if ( !_POSIX_Priority_Is_valid( prioceiling ) )
a000b93c: e1a00001 mov r0, r1 <== NOT EXECUTED
a000b940: eb00006a bl a000baf0 <_POSIX_Priority_Is_valid> <== NOT EXECUTED
a000b944: e3500000 cmp r0, #0 <== NOT EXECUTED
a000b948: 0a000017 beq a000b9ac <pthread_mutex_setprioceiling+0x84> <== NOT EXECUTED
a000b94c: e59f6060 ldr r6, [pc, #96] ; a000b9b4 <pthread_mutex_setprioceiling+0x8c><== NOT EXECUTED
/*
* Must acquire the mutex before we can change it's ceiling.
* POSIX says block until we acquire it.
*/
(void) pthread_mutex_lock( mutex );
a000b950: e1a00004 mov r0, r4 <== NOT EXECUTED
a000b954: e5d67000 ldrb r7, [r6] <== NOT EXECUTED
a000b958: ebffffd7 bl a000b8bc <pthread_mutex_lock> <== NOT EXECUTED
* operations.
*
* NOTE: This makes it easier to get 100% binary coverage since the
* bad Id case is handled by the switch.
*/
the_mutex = _POSIX_Mutex_Get( mutex, &location );
a000b95c: e1a00004 mov r0, r4 <== NOT EXECUTED
a000b960: e1a0100d mov r1, sp <== NOT EXECUTED
a000b964: ebffff3a bl a000b654 <_POSIX_Mutex_Get> <== NOT EXECUTED
switch ( location ) {
a000b968: e59d4000 ldr r4, [sp] <== NOT EXECUTED
* operations.
*
* NOTE: This makes it easier to get 100% binary coverage since the
* bad Id case is handled by the switch.
*/
the_mutex = _POSIX_Mutex_Get( mutex, &location );
a000b96c: e1a03000 mov r3, r0 <== NOT EXECUTED
switch ( location ) {
a000b970: e3540000 cmp r4, #0 <== NOT EXECUTED
a000b974: 1a00000c bne a000b9ac <pthread_mutex_setprioceiling+0x84> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE int _POSIX_Priority_From_core(
Priority_Control priority
)
{
return (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
a000b978: e5902060 ldr r2, [r0, #96] ; 0x60 <== NOT EXECUTED
a000b97c: e5d61000 ldrb r1, [r6] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(
int priority
)
{
return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
a000b980: e0655007 rsb r5, r5, r7 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE int _POSIX_Priority_From_core(
Priority_Control priority
)
{
return (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
a000b984: e0622001 rsb r2, r2, r1 <== NOT EXECUTED
case OBJECTS_LOCAL:
*old_ceiling = _POSIX_Priority_From_core(
a000b988: e5882000 str r2, [r8] <== NOT EXECUTED
);
the_mutex->Mutex.Attributes.priority_ceiling = the_priority;
/*
* We are required to unlock the mutex before we return.
*/
_CORE_mutex_Surrender(
a000b98c: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED
case OBJECTS_LOCAL:
*old_ceiling = _POSIX_Priority_From_core(
the_mutex->Mutex.Attributes.priority_ceiling
);
the_mutex->Mutex.Attributes.priority_ceiling = the_priority;
a000b990: e5805060 str r5, [r0, #96] ; 0x60 <== NOT EXECUTED
/*
* We are required to unlock the mutex before we return.
*/
_CORE_mutex_Surrender(
a000b994: e1a02004 mov r2, r4 <== NOT EXECUTED
a000b998: e2800014 add r0, r0, #20 <== NOT EXECUTED
a000b99c: eb0006bb bl a000d490 <_CORE_mutex_Surrender> <== NOT EXECUTED
&the_mutex->Mutex,
the_mutex->Object.id,
NULL
);
_Thread_Enable_dispatch();
a000b9a0: eb000c6e bl a000eb60 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000b9a4: e1a00004 mov r0, r4 <== NOT EXECUTED
a000b9a8: ea000000 b a000b9b0 <pthread_mutex_setprioceiling+0x88> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000b9ac: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a000b9b0: e8bd81f8 pop {r3, r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
a000b9b8 <pthread_mutex_timedlock>:
int pthread_mutex_timedlock(
pthread_mutex_t *mutex,
const struct timespec *abstime
)
{
a000b9b8: e92d4071 push {r0, r4, r5, r6, lr} <== NOT EXECUTED
a000b9bc: e1a06000 mov r6, r0 <== NOT EXECUTED
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
a000b9c0: e1a00001 mov r0, r1 <== NOT EXECUTED
a000b9c4: e1a0100d mov r1, sp <== NOT EXECUTED
a000b9c8: eb00002a bl a000ba78 <_POSIX_Absolute_timeout_to_ticks> <== NOT EXECUTED
int _EXFUN(pthread_mutex_trylock, (pthread_mutex_t *__mutex));
int _EXFUN(pthread_mutex_unlock, (pthread_mutex_t *__mutex));
#if defined(_POSIX_TIMEOUTS)
int _EXFUN(pthread_mutex_timedlock,
a000b9cc: e3500003 cmp r0, #3 <== NOT EXECUTED
a000b9d0: 13a05000 movne r5, #0 <== NOT EXECUTED
a000b9d4: 03a05001 moveq r5, #1 <== NOT EXECUTED
a000b9d8: e1a04000 mov r4, r0 <== NOT EXECUTED
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
lock_status = _POSIX_Mutex_Lock_support( mutex, do_wait, ticks );
a000b9dc: e1a01005 mov r1, r5 <== NOT EXECUTED
a000b9e0: e1a00006 mov r0, r6 <== NOT EXECUTED
a000b9e4: e59d2000 ldr r2, [sp] <== NOT EXECUTED
a000b9e8: ebffffb6 bl a000b8c8 <_POSIX_Mutex_Lock_support> <== NOT EXECUTED
* This service only gives us the option to block. We used a polling
* attempt to lock if the abstime was not in the future. If we did
* not obtain the mutex, then not look at the status immediately,
* make sure the right reason is returned.
*/
if ( !do_wait && (lock_status == EBUSY) ) {
a000b9ec: e3550000 cmp r5, #0 <== NOT EXECUTED
a000b9f0: 1a000008 bne a000ba18 <pthread_mutex_timedlock+0x60> <== NOT EXECUTED
a000b9f4: e3500010 cmp r0, #16 <== NOT EXECUTED
a000b9f8: 1a000006 bne a000ba18 <pthread_mutex_timedlock+0x60> <== NOT EXECUTED
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
a000b9fc: e3540000 cmp r4, #0 <== NOT EXECUTED
return EINVAL;
a000ba00: 03a00016 moveq r0, #22 <== NOT EXECUTED
* attempt to lock if the abstime was not in the future. If we did
* not obtain the mutex, then not look at the status immediately,
* make sure the right reason is returned.
*/
if ( !do_wait && (lock_status == EBUSY) ) {
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
a000ba04: 0a000003 beq a000ba18 <pthread_mutex_timedlock+0x60> <== NOT EXECUTED
return EINVAL;
if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||
a000ba08: e2444001 sub r4, r4, #1 <== NOT EXECUTED
status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )
return ETIMEDOUT;
a000ba0c: e3540001 cmp r4, #1 <== NOT EXECUTED
a000ba10: 83a00010 movhi r0, #16 <== NOT EXECUTED
a000ba14: 93a00074 movls r0, #116 ; 0x74 <== NOT EXECUTED
}
return lock_status;
}
a000ba18: e8bd8078 pop {r3, r4, r5, r6, pc} <== NOT EXECUTED
a000ba2c <pthread_mutex_trylock>:
int pthread_mutex_trylock(
pthread_mutex_t *mutex
)
{
return _POSIX_Mutex_Lock_support( mutex, false, THREAD_QUEUE_WAIT_FOREVER );
a000ba2c: e3a01000 mov r1, #0 <== NOT EXECUTED
a000ba30: e1a02001 mov r2, r1 <== NOT EXECUTED
a000ba34: eaffffa3 b a000b8c8 <_POSIX_Mutex_Lock_support> <== NOT EXECUTED
a000b448 <pthread_mutexattr_destroy>:
int pthread_mutexattr_destroy(
pthread_mutexattr_t *attr
)
{
if ( !attr || !attr->is_initialized )
a000b448: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000b44c: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_mutexattr_destroy(
pthread_mutexattr_t *attr
)
{
if ( !attr || !attr->is_initialized )
a000b450: 012fff1e bxeq lr <== NOT EXECUTED
a000b454: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000b458: e3520000 cmp r2, #0 <== NOT EXECUTED
return EINVAL;
attr->is_initialized = false;
a000b45c: 13a00000 movne r0, #0 <== NOT EXECUTED
a000b460: 15830000 strne r0, [r3] <== NOT EXECUTED
int pthread_mutexattr_destroy(
pthread_mutexattr_t *attr
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000b464: 03a00016 moveq r0, #22 <== NOT EXECUTED
attr->is_initialized = false;
return 0;
}
a000b468: e12fff1e bx lr <== NOT EXECUTED
a000b52c <pthread_mutexattr_setprioceiling>:
int pthread_mutexattr_setprioceiling(
pthread_mutexattr_t *attr,
int prioceiling
)
{
a000b52c: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
if ( !attr || !attr->is_initialized )
a000b530: e2504000 subs r4, r0, #0 <== NOT EXECUTED
int pthread_mutexattr_setprioceiling(
pthread_mutexattr_t *attr,
int prioceiling
)
{
a000b534: e1a05001 mov r5, r1 <== NOT EXECUTED
if ( !attr || !attr->is_initialized )
a000b538: 0a000009 beq a000b564 <pthread_mutexattr_setprioceiling+0x38><== NOT EXECUTED
a000b53c: e5943000 ldr r3, [r4] <== NOT EXECUTED
a000b540: e3530000 cmp r3, #0 <== NOT EXECUTED
a000b544: 0a000006 beq a000b564 <pthread_mutexattr_setprioceiling+0x38><== NOT EXECUTED
return EINVAL;
if ( !_POSIX_Priority_Is_valid( prioceiling ) )
a000b548: e1a00001 mov r0, r1 <== NOT EXECUTED
a000b54c: eb000167 bl a000baf0 <_POSIX_Priority_Is_valid> <== NOT EXECUTED
a000b550: e3500000 cmp r0, #0 <== NOT EXECUTED
a000b554: 0a000004 beq a000b56c <pthread_mutexattr_setprioceiling+0x40><== NOT EXECUTED
return EINVAL;
attr->prio_ceiling = prioceiling;
a000b558: e5845008 str r5, [r4, #8] <== NOT EXECUTED
return 0;
a000b55c: e3a00000 mov r0, #0 <== NOT EXECUTED
a000b560: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
pthread_mutexattr_t *attr,
int prioceiling
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000b564: e3a00016 mov r0, #22 <== NOT EXECUTED
a000b568: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
if ( !_POSIX_Priority_Is_valid( prioceiling ) )
return EINVAL;
a000b56c: e3a00016 mov r0, #22 <== NOT EXECUTED
attr->prio_ceiling = prioceiling;
return 0;
}
a000b570: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000b574 <pthread_mutexattr_setprotocol>:
int pthread_mutexattr_setprotocol(
pthread_mutexattr_t *attr,
int protocol
)
{
if ( !attr || !attr->is_initialized )
a000b574: e3500000 cmp r0, #0 <== NOT EXECUTED
a000b578: 0a000007 beq a000b59c <pthread_mutexattr_setprotocol+0x28> <== NOT EXECUTED
a000b57c: e5903000 ldr r3, [r0] <== NOT EXECUTED
a000b580: e3530000 cmp r3, #0 <== NOT EXECUTED
a000b584: 0a000004 beq a000b59c <pthread_mutexattr_setprotocol+0x28> <== NOT EXECUTED
return EINVAL;
switch ( protocol ) {
a000b588: e3510002 cmp r1, #2 <== NOT EXECUTED
case PTHREAD_PRIO_NONE:
case PTHREAD_PRIO_INHERIT:
case PTHREAD_PRIO_PROTECT:
attr->protocol = protocol;
a000b58c: 9580100c strls r1, [r0, #12] <== NOT EXECUTED
return 0;
a000b590: 93a00000 movls r0, #0 <== NOT EXECUTED
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
switch ( protocol ) {
a000b594: 912fff1e bxls lr <== NOT EXECUTED
a000b598: ea000001 b a000b5a4 <pthread_mutexattr_setprotocol+0x30> <== NOT EXECUTED
pthread_mutexattr_t *attr,
int protocol
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000b59c: e3a00016 mov r0, #22 <== NOT EXECUTED
a000b5a0: e12fff1e bx lr <== NOT EXECUTED
case PTHREAD_PRIO_PROTECT:
attr->protocol = protocol;
return 0;
default:
return EINVAL;
a000b5a4: e3a00016 mov r0, #22 <== NOT EXECUTED
}
}
a000b5a8: e12fff1e bx lr <== NOT EXECUTED
a000b5ac <pthread_mutexattr_setpshared>:
int pthread_mutexattr_setpshared(
pthread_mutexattr_t *attr,
int pshared
)
{
if ( !attr || !attr->is_initialized )
a000b5ac: e3500000 cmp r0, #0 <== NOT EXECUTED
a000b5b0: 0a000007 beq a000b5d4 <pthread_mutexattr_setpshared+0x28> <== NOT EXECUTED
a000b5b4: e5903000 ldr r3, [r0] <== NOT EXECUTED
a000b5b8: e3530000 cmp r3, #0 <== NOT EXECUTED
a000b5bc: 0a000004 beq a000b5d4 <pthread_mutexattr_setpshared+0x28> <== NOT EXECUTED
return EINVAL;
switch ( pshared ) {
a000b5c0: e3510001 cmp r1, #1 <== NOT EXECUTED
case PTHREAD_PROCESS_SHARED:
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
a000b5c4: 95801004 strls r1, [r0, #4] <== NOT EXECUTED
return 0;
a000b5c8: 93a00000 movls r0, #0 <== NOT EXECUTED
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
switch ( pshared ) {
a000b5cc: 912fff1e bxls lr <== NOT EXECUTED
a000b5d0: ea000001 b a000b5dc <pthread_mutexattr_setpshared+0x30> <== NOT EXECUTED
pthread_mutexattr_t *attr,
int pshared
)
{
if ( !attr || !attr->is_initialized )
return EINVAL;
a000b5d4: e3a00016 mov r0, #22 <== NOT EXECUTED
a000b5d8: e12fff1e bx lr <== NOT EXECUTED
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
return 0;
default:
return EINVAL;
a000b5dc: e3a00016 mov r0, #22 <== NOT EXECUTED
}
}
a000b5e0: e12fff1e bx lr <== NOT EXECUTED
a0009d20 <pthread_once>:
int pthread_once(
pthread_once_t *once_control,
void (*init_routine)(void)
)
{
if ( !once_control || !init_routine )
a0009d20: e3500000 cmp r0, #0 <== NOT EXECUTED
a0009d24: 13510000 cmpne r1, #0 <== NOT EXECUTED
int pthread_once(
pthread_once_t *once_control,
void (*init_routine)(void)
)
{
a0009d28: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
if ( !once_control || !init_routine )
a0009d2c: e1a04000 mov r4, r0 <== NOT EXECUTED
a0009d30: e1a05001 mov r5, r1 <== NOT EXECUTED
a0009d34: 13a00000 movne r0, #0 <== NOT EXECUTED
a0009d38: 03a00001 moveq r0, #1 <== NOT EXECUTED
return EINVAL;
a0009d3c: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_once(
pthread_once_t *once_control,
void (*init_routine)(void)
)
{
if ( !once_control || !init_routine )
a0009d40: 0a000012 beq a0009d90 <pthread_once+0x70> <== NOT EXECUTED
return EINVAL;
if ( !once_control->init_executed ) {
a0009d44: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED
a0009d48: e3530000 cmp r3, #0 <== NOT EXECUTED
a0009d4c: 1a00000f bne a0009d90 <pthread_once+0x70> <== NOT EXECUTED
rtems_mode saveMode;
rtems_task_mode(RTEMS_NO_PREEMPT, RTEMS_PREEMPT_MASK, &saveMode);
a0009d50: e3a00c01 mov r0, #256 ; 0x100 <== NOT EXECUTED
a0009d54: e1a01000 mov r1, r0 <== NOT EXECUTED
a0009d58: e1a0200d mov r2, sp <== NOT EXECUTED
a0009d5c: eb0002c6 bl a000a87c <rtems_task_mode> <== NOT EXECUTED
if ( !once_control->init_executed ) {
a0009d60: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED
a0009d64: e3530000 cmp r3, #0 <== NOT EXECUTED
a0009d68: 1a000003 bne a0009d7c <pthread_once+0x5c> <== NOT EXECUTED
once_control->is_initialized = true;
a0009d6c: e2833001 add r3, r3, #1 <== NOT EXECUTED
a0009d70: e5843000 str r3, [r4] <== NOT EXECUTED
once_control->init_executed = true;
a0009d74: e5843004 str r3, [r4, #4] <== NOT EXECUTED
(*init_routine)();
a0009d78: e12fff35 blx r5 <== NOT EXECUTED
}
rtems_task_mode(saveMode, RTEMS_PREEMPT_MASK, &saveMode);
a0009d7c: e59d0000 ldr r0, [sp] <== NOT EXECUTED
a0009d80: e3a01c01 mov r1, #256 ; 0x100 <== NOT EXECUTED
a0009d84: e1a0200d mov r2, sp <== NOT EXECUTED
a0009d88: eb0002bb bl a000a87c <rtems_task_mode> <== NOT EXECUTED
}
return 0;
a0009d8c: e3a00000 mov r0, #0 <== NOT EXECUTED
}
a0009d90: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a000a80c <pthread_rwlock_destroy>:
)
{
POSIX_RWLock_Control *the_rwlock = NULL;
Objects_Locations location;
if ( !rwlock )
a000a80c: e2503000 subs r3, r0, #0 <== NOT EXECUTED
*/
int pthread_rwlock_destroy(
pthread_rwlock_t *rwlock
)
{
a000a810: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
POSIX_RWLock_Control *the_rwlock = NULL;
Objects_Locations location;
if ( !rwlock )
a000a814: 0a000017 beq a000a878 <pthread_rwlock_destroy+0x6c> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_RWLock_Control *_POSIX_RWLock_Get (
pthread_rwlock_t *RWLock,
Objects_Locations *location
)
{
return (POSIX_RWLock_Control *) _Objects_Get(
a000a818: e5931000 ldr r1, [r3] <== NOT EXECUTED
a000a81c: e59f005c ldr r0, [pc, #92] ; a000a880 <pthread_rwlock_destroy+0x74><== NOT EXECUTED
a000a820: e1a0200d mov r2, sp <== NOT EXECUTED
a000a824: eb000a83 bl a000d238 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
a000a828: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a000a82c: e1a04000 mov r4, r0 <== NOT EXECUTED
a000a830: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a834: 1a00000f bne a000a878 <pthread_rwlock_destroy+0x6c> <== NOT EXECUTED
case OBJECTS_LOCAL:
/*
* If there is at least one thread waiting, then do not delete it.
*/
if ( _Thread_queue_First( &the_rwlock->RWLock.Wait_queue ) != NULL ) {
a000a838: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000a83c: eb000f34 bl a000e514 <_Thread_queue_First> <== NOT EXECUTED
a000a840: e2505000 subs r5, r0, #0 <== NOT EXECUTED
a000a844: 0a000002 beq a000a854 <pthread_rwlock_destroy+0x48> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000a848: eb000d32 bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return EBUSY;
a000a84c: e3a00010 mov r0, #16 <== NOT EXECUTED
a000a850: ea000009 b a000a87c <pthread_rwlock_destroy+0x70> <== NOT EXECUTED
/*
* POSIX doesn't require behavior when it is locked.
*/
_Objects_Close( &_POSIX_RWLock_Information, &the_rwlock->Object );
a000a854: e59f0024 ldr r0, [pc, #36] ; a000a880 <pthread_rwlock_destroy+0x74><== NOT EXECUTED
a000a858: e1a01004 mov r1, r4 <== NOT EXECUTED
a000a85c: eb000976 bl a000ce3c <_Objects_Close> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _POSIX_RWLock_Free (
POSIX_RWLock_Control *the_RWLock
)
{
_Objects_Free( &_POSIX_RWLock_Information, &the_RWLock->Object );
a000a860: e59f0018 ldr r0, [pc, #24] ; a000a880 <pthread_rwlock_destroy+0x74><== NOT EXECUTED
a000a864: e1a01004 mov r1, r4 <== NOT EXECUTED
a000a868: eb000a1a bl a000d0d8 <_Objects_Free> <== NOT EXECUTED
_POSIX_RWLock_Free( the_rwlock );
_Thread_Enable_dispatch();
a000a86c: eb000d29 bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000a870: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a874: ea000000 b a000a87c <pthread_rwlock_destroy+0x70> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000a878: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a000a87c: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a000a884 <pthread_rwlock_init>:
int pthread_rwlock_init(
pthread_rwlock_t *rwlock,
const pthread_rwlockattr_t *attr
)
{
a000a884: e92d40f7 push {r0, r1, r2, r4, r5, r6, r7, lr} <== NOT EXECUTED
const pthread_rwlockattr_t *the_attr;
/*
* Error check parameters
*/
if ( !rwlock )
a000a888: e2507000 subs r7, r0, #0 <== NOT EXECUTED
a000a88c: 0a000024 beq a000a924 <pthread_rwlock_init+0xa0> <== NOT EXECUTED
return EINVAL;
/*
* If the user passed in NULL, use the default attributes
*/
if ( attr ) {
a000a890: e3510000 cmp r1, #0 <== NOT EXECUTED
a000a894: 1a000003 bne a000a8a8 <pthread_rwlock_init+0x24> <== NOT EXECUTED
the_attr = attr;
} else {
(void) pthread_rwlockattr_init( &default_attr );
a000a898: e1a0000d mov r0, sp <== NOT EXECUTED
a000a89c: eb000256 bl a000b1fc <pthread_rwlockattr_init> <== NOT EXECUTED
a000a8a0: e1a0400d mov r4, sp <== NOT EXECUTED
the_attr = &default_attr;
a000a8a4: e1a0100d mov r1, sp <== NOT EXECUTED
}
/*
* Now start error checking the attributes that we are going to use
*/
if ( !the_attr->is_initialized )
a000a8a8: e5913000 ldr r3, [r1] <== NOT EXECUTED
a000a8ac: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a8b0: 0a00001b beq a000a924 <pthread_rwlock_init+0xa0> <== NOT EXECUTED
return EINVAL;
switch ( the_attr->process_shared ) {
a000a8b4: e5915004 ldr r5, [r1, #4] <== NOT EXECUTED
a000a8b8: e3550000 cmp r5, #0 <== NOT EXECUTED
a000a8bc: 1a000018 bne a000a924 <pthread_rwlock_init+0xa0> <== NOT EXECUTED
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000a8c0: e59f3064 ldr r3, [pc, #100] ; a000a92c <pthread_rwlock_init+0xa8><== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _CORE_RWLock_Initialize_attributes(
CORE_RWLock_Attributes *the_attributes
)
{
the_attributes->XXX = 0;
a000a8c4: e58d5008 str r5, [sp, #8] <== NOT EXECUTED
a000a8c8: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000a8cc: e2822001 add r2, r2, #1 <== NOT EXECUTED
a000a8d0: e5832000 str r2, [r3] <== NOT EXECUTED
* the inactive chain of free RWLock control blocks.
*/
RTEMS_INLINE_ROUTINE POSIX_RWLock_Control *_POSIX_RWLock_Allocate( void )
{
return (POSIX_RWLock_Control *)
_Objects_Allocate( &_POSIX_RWLock_Information );
a000a8d4: e59f6054 ldr r6, [pc, #84] ; a000a930 <pthread_rwlock_init+0xac><== NOT EXECUTED
a000a8d8: e1a00006 mov r0, r6 <== NOT EXECUTED
a000a8dc: eb000934 bl a000cdb4 <_Objects_Allocate> <== NOT EXECUTED
*/
_Thread_Disable_dispatch(); /* prevents deletion */
the_rwlock = _POSIX_RWLock_Allocate();
if ( !the_rwlock ) {
a000a8e0: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a000a8e4: 1a000002 bne a000a8f4 <pthread_rwlock_init+0x70> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000a8e8: eb000d0a bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return EAGAIN;
a000a8ec: e3a0000b mov r0, #11 <== NOT EXECUTED
a000a8f0: ea00000c b a000a928 <pthread_rwlock_init+0xa4> <== NOT EXECUTED
}
_CORE_RWLock_Initialize( &the_rwlock->RWLock, &the_attributes );
a000a8f4: e2840010 add r0, r4, #16 <== NOT EXECUTED
a000a8f8: e28d1008 add r1, sp, #8 <== NOT EXECUTED
a000a8fc: eb00070a bl a000c52c <_CORE_RWLock_Initialize> <== NOT EXECUTED
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000a900: e596201c ldr r2, [r6, #28] <== NOT EXECUTED
Objects_Information *information,
Objects_Control *the_object,
uint32_t name
)
{
_Objects_Set_local_object(
a000a904: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED
a000a908: e1d410b8 ldrh r1, [r4, #8] <== NOT EXECUTED
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000a90c: e7824101 str r4, [r2, r1, lsl #2] <== NOT EXECUTED
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
a000a910: e584500c str r5, [r4, #12] <== NOT EXECUTED
&_POSIX_RWLock_Information,
&the_rwlock->Object,
0
);
*rwlock = the_rwlock->Object.id;
a000a914: e5873000 str r3, [r7] <== NOT EXECUTED
_Thread_Enable_dispatch();
a000a918: eb000cfe bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000a91c: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a920: ea000000 b a000a928 <pthread_rwlock_init+0xa4> <== NOT EXECUTED
switch ( the_attr->process_shared ) {
case PTHREAD_PROCESS_PRIVATE: /* only supported values */
break;
case PTHREAD_PROCESS_SHARED:
default:
return EINVAL;
a000a924: e3a00016 mov r0, #22 <== NOT EXECUTED
*rwlock = the_rwlock->Object.id;
_Thread_Enable_dispatch();
return 0;
}
a000a928: e8bd80fe pop {r1, r2, r3, r4, r5, r6, r7, pc} <== NOT EXECUTED
a000a934 <pthread_rwlock_rdlock>:
*/
int pthread_rwlock_rdlock(
pthread_rwlock_t *rwlock
)
{
a000a934: e92d4013 push {r0, r1, r4, lr} <== NOT EXECUTED
POSIX_RWLock_Control *the_rwlock;
Objects_Locations location;
if ( !rwlock )
a000a938: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a000a93c: 0a000011 beq a000a988 <pthread_rwlock_rdlock+0x54> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_RWLock_Control *_POSIX_RWLock_Get (
pthread_rwlock_t *RWLock,
Objects_Locations *location
)
{
return (POSIX_RWLock_Control *) _Objects_Get(
a000a940: e59f0048 ldr r0, [pc, #72] ; a000a990 <pthread_rwlock_rdlock+0x5c><== NOT EXECUTED
a000a944: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000a948: e28d2004 add r2, sp, #4 <== NOT EXECUTED
a000a94c: eb000a39 bl a000d238 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
a000a950: e59d3004 ldr r3, [sp, #4] <== NOT EXECUTED
a000a954: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a958: 1a00000a bne a000a988 <pthread_rwlock_rdlock+0x54> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_RWLock_Obtain_for_reading(
a000a95c: e58d3000 str r3, [sp] <== NOT EXECUTED
a000a960: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000a964: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000a968: e3a02001 mov r2, #1 <== NOT EXECUTED
a000a96c: eb0006f6 bl a000c54c <_CORE_RWLock_Obtain_for_reading> <== NOT EXECUTED
true, /* we are willing to wait forever */
0,
NULL
);
_Thread_Enable_dispatch();
a000a970: eb000ce8 bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return _POSIX_RWLock_Translate_core_RWLock_return_code(
(CORE_RWLock_Status) _Thread_Executing->Wait.return_code
a000a974: e59f3018 ldr r3, [pc, #24] ; a000a994 <pthread_rwlock_rdlock+0x60><== NOT EXECUTED
a000a978: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
0,
NULL
);
_Thread_Enable_dispatch();
return _POSIX_RWLock_Translate_core_RWLock_return_code(
a000a97c: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a000a980: eb000060 bl a000ab08 <_POSIX_RWLock_Translate_core_RWLock_return_code><== NOT EXECUTED
a000a984: ea000000 b a000a98c <pthread_rwlock_rdlock+0x58> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000a988: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a000a98c: e8bd801c pop {r2, r3, r4, pc} <== NOT EXECUTED
a000a998 <pthread_rwlock_timedrdlock>:
int pthread_rwlock_timedrdlock(
pthread_rwlock_t *rwlock,
const struct timespec *abstime
)
{
a000a998: e92d4077 push {r0, r1, r2, r4, r5, r6, lr} <== NOT EXECUTED
Objects_Locations location;
Watchdog_Interval ticks;
bool do_wait = true;
POSIX_Absolute_timeout_conversion_results_t status;
if ( !rwlock )
a000a99c: e2506000 subs r6, r0, #0 <== NOT EXECUTED
a000a9a0: 0a000026 beq a000aa40 <pthread_rwlock_timedrdlock+0xa8> <== NOT EXECUTED
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
a000a9a4: e1a00001 mov r0, r1 <== NOT EXECUTED
a000a9a8: e28d1004 add r1, sp, #4 <== NOT EXECUTED
a000a9ac: eb001867 bl a0010b50 <_POSIX_Absolute_timeout_to_ticks> <== NOT EXECUTED
a000a9b0: e5961000 ldr r1, [r6] <== NOT EXECUTED
a000a9b4: e1a04000 mov r4, r0 <== NOT EXECUTED
a000a9b8: e28d2008 add r2, sp, #8 <== NOT EXECUTED
a000a9bc: e59f0084 ldr r0, [pc, #132] ; a000aa48 <pthread_rwlock_timedrdlock+0xb0><== NOT EXECUTED
a000a9c0: eb000a1c bl a000d238 <_Objects_Get> <== NOT EXECUTED
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
a000a9c4: e59d3008 ldr r3, [sp, #8] <== NOT EXECUTED
a000a9c8: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a9cc: 1a00001b bne a000aa40 <pthread_rwlock_timedrdlock+0xa8> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_RWLock_Obtain_for_reading(
a000a9d0: e58d3000 str r3, [sp] <== NOT EXECUTED
int _EXFUN(pthread_rwlock_init,
(pthread_rwlock_t *__rwlock, _CONST pthread_rwlockattr_t *__attr));
int _EXFUN(pthread_rwlock_destroy, (pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_rdlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_tryrdlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_timedrdlock,
a000a9d4: e3540003 cmp r4, #3 <== NOT EXECUTED
a000a9d8: 13a05000 movne r5, #0 <== NOT EXECUTED
a000a9dc: 03a05001 moveq r5, #1 <== NOT EXECUTED
a000a9e0: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000a9e4: e5961000 ldr r1, [r6] <== NOT EXECUTED
a000a9e8: e1a02005 mov r2, r5 <== NOT EXECUTED
a000a9ec: e59d3004 ldr r3, [sp, #4] <== NOT EXECUTED
a000a9f0: eb0006d5 bl a000c54c <_CORE_RWLock_Obtain_for_reading> <== NOT EXECUTED
do_wait,
ticks,
NULL
);
_Thread_Enable_dispatch();
a000a9f4: eb000cc7 bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
if ( !do_wait ) {
a000a9f8: e3550000 cmp r5, #0 <== NOT EXECUTED
a000a9fc: 1a00000a bne a000aa2c <pthread_rwlock_timedrdlock+0x94> <== NOT EXECUTED
if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) {
a000aa00: e59f3044 ldr r3, [pc, #68] ; a000aa4c <pthread_rwlock_timedrdlock+0xb4><== NOT EXECUTED
a000aa04: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
a000aa08: e5933034 ldr r3, [r3, #52] ; 0x34 <== NOT EXECUTED
a000aa0c: e3530002 cmp r3, #2 <== NOT EXECUTED
a000aa10: 1a000005 bne a000aa2c <pthread_rwlock_timedrdlock+0x94> <== NOT EXECUTED
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
a000aa14: e3540000 cmp r4, #0 <== NOT EXECUTED
a000aa18: 0a000008 beq a000aa40 <pthread_rwlock_timedrdlock+0xa8> <== NOT EXECUTED
return EINVAL;
if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||
a000aa1c: e2444001 sub r4, r4, #1 <== NOT EXECUTED
a000aa20: e3540001 cmp r4, #1 <== NOT EXECUTED
status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )
return ETIMEDOUT;
a000aa24: 93a00074 movls r0, #116 ; 0x74 <== NOT EXECUTED
_Thread_Enable_dispatch();
if ( !do_wait ) {
if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) {
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
return EINVAL;
if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||
a000aa28: 9a000005 bls a000aa44 <pthread_rwlock_timedrdlock+0xac> <== NOT EXECUTED
return ETIMEDOUT;
}
}
return _POSIX_RWLock_Translate_core_RWLock_return_code(
(CORE_RWLock_Status) _Thread_Executing->Wait.return_code
a000aa2c: e59f3018 ldr r3, [pc, #24] ; a000aa4c <pthread_rwlock_timedrdlock+0xb4><== NOT EXECUTED
a000aa30: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )
return ETIMEDOUT;
}
}
return _POSIX_RWLock_Translate_core_RWLock_return_code(
a000aa34: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a000aa38: eb000032 bl a000ab08 <_POSIX_RWLock_Translate_core_RWLock_return_code><== NOT EXECUTED
a000aa3c: ea000000 b a000aa44 <pthread_rwlock_timedrdlock+0xac> <== NOT EXECUTED
_Thread_Enable_dispatch();
if ( !do_wait ) {
if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) {
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
return EINVAL;
a000aa40: e3a00016 mov r0, #22 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
a000aa44: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc} <== NOT EXECUTED
a000aa50 <pthread_rwlock_timedwrlock>:
int pthread_rwlock_timedwrlock(
pthread_rwlock_t *rwlock,
const struct timespec *abstime
)
{
a000aa50: e92d4077 push {r0, r1, r2, r4, r5, r6, lr} <== NOT EXECUTED
Objects_Locations location;
Watchdog_Interval ticks;
bool do_wait = true;
POSIX_Absolute_timeout_conversion_results_t status;
if ( !rwlock )
a000aa54: e2506000 subs r6, r0, #0 <== NOT EXECUTED
a000aa58: 0a000026 beq a000aaf8 <pthread_rwlock_timedwrlock+0xa8> <== NOT EXECUTED
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
a000aa5c: e1a00001 mov r0, r1 <== NOT EXECUTED
a000aa60: e28d1004 add r1, sp, #4 <== NOT EXECUTED
a000aa64: eb001839 bl a0010b50 <_POSIX_Absolute_timeout_to_ticks> <== NOT EXECUTED
a000aa68: e5961000 ldr r1, [r6] <== NOT EXECUTED
a000aa6c: e1a04000 mov r4, r0 <== NOT EXECUTED
a000aa70: e28d2008 add r2, sp, #8 <== NOT EXECUTED
a000aa74: e59f0084 ldr r0, [pc, #132] ; a000ab00 <pthread_rwlock_timedwrlock+0xb0><== NOT EXECUTED
a000aa78: eb0009ee bl a000d238 <_Objects_Get> <== NOT EXECUTED
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
a000aa7c: e59d3008 ldr r3, [sp, #8] <== NOT EXECUTED
a000aa80: e3530000 cmp r3, #0 <== NOT EXECUTED
a000aa84: 1a00001b bne a000aaf8 <pthread_rwlock_timedwrlock+0xa8> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_RWLock_Obtain_for_writing(
a000aa88: e58d3000 str r3, [sp] <== NOT EXECUTED
(pthread_rwlock_t *__rwlock, _CONST struct timespec *__abstime));
int _EXFUN(pthread_rwlock_unlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_wrlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_trywrlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_timedwrlock,
a000aa8c: e3540003 cmp r4, #3 <== NOT EXECUTED
a000aa90: 13a05000 movne r5, #0 <== NOT EXECUTED
a000aa94: 03a05001 moveq r5, #1 <== NOT EXECUTED
a000aa98: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000aa9c: e5961000 ldr r1, [r6] <== NOT EXECUTED
a000aaa0: e1a02005 mov r2, r5 <== NOT EXECUTED
a000aaa4: e59d3004 ldr r3, [sp, #4] <== NOT EXECUTED
a000aaa8: eb0006db bl a000c61c <_CORE_RWLock_Obtain_for_writing> <== NOT EXECUTED
do_wait,
ticks,
NULL
);
_Thread_Enable_dispatch();
a000aaac: eb000c99 bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
if ( !do_wait &&
a000aab0: e3550000 cmp r5, #0 <== NOT EXECUTED
a000aab4: 1a00000a bne a000aae4 <pthread_rwlock_timedwrlock+0x94> <== NOT EXECUTED
(_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) {
a000aab8: e59f3044 ldr r3, [pc, #68] ; a000ab04 <pthread_rwlock_timedwrlock+0xb4><== NOT EXECUTED
a000aabc: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
ticks,
NULL
);
_Thread_Enable_dispatch();
if ( !do_wait &&
a000aac0: e5933034 ldr r3, [r3, #52] ; 0x34 <== NOT EXECUTED
a000aac4: e3530002 cmp r3, #2 <== NOT EXECUTED
a000aac8: 1a000005 bne a000aae4 <pthread_rwlock_timedwrlock+0x94> <== NOT EXECUTED
(_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) {
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
a000aacc: e3540000 cmp r4, #0 <== NOT EXECUTED
a000aad0: 0a000008 beq a000aaf8 <pthread_rwlock_timedwrlock+0xa8> <== NOT EXECUTED
return EINVAL;
if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||
a000aad4: e2444001 sub r4, r4, #1 <== NOT EXECUTED
a000aad8: e3540001 cmp r4, #1 <== NOT EXECUTED
status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )
return ETIMEDOUT;
a000aadc: 93a00074 movls r0, #116 ; 0x74 <== NOT EXECUTED
_Thread_Enable_dispatch();
if ( !do_wait &&
(_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) {
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
return EINVAL;
if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||
a000aae0: 9a000005 bls a000aafc <pthread_rwlock_timedwrlock+0xac> <== NOT EXECUTED
status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )
return ETIMEDOUT;
}
return _POSIX_RWLock_Translate_core_RWLock_return_code(
(CORE_RWLock_Status) _Thread_Executing->Wait.return_code
a000aae4: e59f3018 ldr r3, [pc, #24] ; a000ab04 <pthread_rwlock_timedwrlock+0xb4><== NOT EXECUTED
a000aae8: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||
status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )
return ETIMEDOUT;
}
return _POSIX_RWLock_Translate_core_RWLock_return_code(
a000aaec: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a000aaf0: eb000004 bl a000ab08 <_POSIX_RWLock_Translate_core_RWLock_return_code><== NOT EXECUTED
a000aaf4: ea000000 b a000aafc <pthread_rwlock_timedwrlock+0xac> <== NOT EXECUTED
_Thread_Enable_dispatch();
if ( !do_wait &&
(_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) {
if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )
return EINVAL;
a000aaf8: e3a00016 mov r0, #22 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
a000aafc: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc} <== NOT EXECUTED
a000ab18 <pthread_rwlock_tryrdlock>:
*/
int pthread_rwlock_tryrdlock(
pthread_rwlock_t *rwlock
)
{
a000ab18: e92d4013 push {r0, r1, r4, lr} <== NOT EXECUTED
POSIX_RWLock_Control *the_rwlock;
Objects_Locations location;
if ( !rwlock )
a000ab1c: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a000ab20: 0a000011 beq a000ab6c <pthread_rwlock_tryrdlock+0x54> <== NOT EXECUTED
a000ab24: e28d2004 add r2, sp, #4 <== NOT EXECUTED
a000ab28: e59f0044 ldr r0, [pc, #68] ; a000ab74 <pthread_rwlock_tryrdlock+0x5c><== NOT EXECUTED
a000ab2c: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000ab30: eb0009c0 bl a000d238 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
a000ab34: e59d2004 ldr r2, [sp, #4] <== NOT EXECUTED
a000ab38: e3520000 cmp r2, #0 <== NOT EXECUTED
a000ab3c: 1a00000a bne a000ab6c <pthread_rwlock_tryrdlock+0x54> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_RWLock_Obtain_for_reading(
a000ab40: e58d2000 str r2, [sp] <== NOT EXECUTED
a000ab44: e1a03002 mov r3, r2 <== NOT EXECUTED
a000ab48: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000ab4c: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000ab50: eb00067d bl a000c54c <_CORE_RWLock_Obtain_for_reading> <== NOT EXECUTED
0,
NULL
);
_Thread_Enable_dispatch();
a000ab54: eb000c6f bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return _POSIX_RWLock_Translate_core_RWLock_return_code(
(CORE_RWLock_Status) _Thread_Executing->Wait.return_code
a000ab58: e59f3018 ldr r3, [pc, #24] ; a000ab78 <pthread_rwlock_tryrdlock+0x60><== NOT EXECUTED
a000ab5c: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
NULL
);
_Thread_Enable_dispatch();
return _POSIX_RWLock_Translate_core_RWLock_return_code(
a000ab60: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a000ab64: ebffffe7 bl a000ab08 <_POSIX_RWLock_Translate_core_RWLock_return_code><== NOT EXECUTED
a000ab68: ea000000 b a000ab70 <pthread_rwlock_tryrdlock+0x58> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000ab6c: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a000ab70: e8bd801c pop {r2, r3, r4, pc} <== NOT EXECUTED
a000ab7c <pthread_rwlock_trywrlock>:
*/
int pthread_rwlock_trywrlock(
pthread_rwlock_t *rwlock
)
{
a000ab7c: e92d4013 push {r0, r1, r4, lr} <== NOT EXECUTED
POSIX_RWLock_Control *the_rwlock;
Objects_Locations location;
if ( !rwlock )
a000ab80: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a000ab84: 0a000011 beq a000abd0 <pthread_rwlock_trywrlock+0x54> <== NOT EXECUTED
a000ab88: e28d2004 add r2, sp, #4 <== NOT EXECUTED
a000ab8c: e59f0044 ldr r0, [pc, #68] ; a000abd8 <pthread_rwlock_trywrlock+0x5c><== NOT EXECUTED
a000ab90: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000ab94: eb0009a7 bl a000d238 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
a000ab98: e59d2004 ldr r2, [sp, #4] <== NOT EXECUTED
a000ab9c: e3520000 cmp r2, #0 <== NOT EXECUTED
a000aba0: 1a00000a bne a000abd0 <pthread_rwlock_trywrlock+0x54> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_RWLock_Obtain_for_writing(
a000aba4: e58d2000 str r2, [sp] <== NOT EXECUTED
a000aba8: e1a03002 mov r3, r2 <== NOT EXECUTED
a000abac: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000abb0: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000abb4: eb000698 bl a000c61c <_CORE_RWLock_Obtain_for_writing> <== NOT EXECUTED
false, /* we are not willing to wait */
0,
NULL
);
_Thread_Enable_dispatch();
a000abb8: eb000c56 bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return _POSIX_RWLock_Translate_core_RWLock_return_code(
(CORE_RWLock_Status) _Thread_Executing->Wait.return_code
a000abbc: e59f3018 ldr r3, [pc, #24] ; a000abdc <pthread_rwlock_trywrlock+0x60><== NOT EXECUTED
a000abc0: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
0,
NULL
);
_Thread_Enable_dispatch();
return _POSIX_RWLock_Translate_core_RWLock_return_code(
a000abc4: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a000abc8: ebffffce bl a000ab08 <_POSIX_RWLock_Translate_core_RWLock_return_code><== NOT EXECUTED
a000abcc: ea000000 b a000abd4 <pthread_rwlock_trywrlock+0x58> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000abd0: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a000abd4: e8bd801c pop {r2, r3, r4, pc} <== NOT EXECUTED
a000abe0 <pthread_rwlock_unlock>:
{
POSIX_RWLock_Control *the_rwlock;
Objects_Locations location;
CORE_RWLock_Status status;
if ( !rwlock )
a000abe0: e2503000 subs r3, r0, #0 <== NOT EXECUTED
*/
int pthread_rwlock_unlock(
pthread_rwlock_t *rwlock
)
{
a000abe4: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
POSIX_RWLock_Control *the_rwlock;
Objects_Locations location;
CORE_RWLock_Status status;
if ( !rwlock )
a000abe8: 0a00000d beq a000ac24 <pthread_rwlock_unlock+0x44> <== NOT EXECUTED
a000abec: e5931000 ldr r1, [r3] <== NOT EXECUTED
a000abf0: e59f0034 ldr r0, [pc, #52] ; a000ac2c <pthread_rwlock_unlock+0x4c><== NOT EXECUTED
a000abf4: e1a0200d mov r2, sp <== NOT EXECUTED
a000abf8: eb00098e bl a000d238 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
a000abfc: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a000ac00: e3530000 cmp r3, #0 <== NOT EXECUTED
a000ac04: 1a000006 bne a000ac24 <pthread_rwlock_unlock+0x44> <== NOT EXECUTED
case OBJECTS_LOCAL:
status = _CORE_RWLock_Release( &the_rwlock->RWLock );
a000ac08: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000ac0c: eb0006a5 bl a000c6a8 <_CORE_RWLock_Release> <== NOT EXECUTED
a000ac10: e1a04000 mov r4, r0 <== NOT EXECUTED
_Thread_Enable_dispatch();
a000ac14: eb000c3f bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return _POSIX_RWLock_Translate_core_RWLock_return_code( status );
a000ac18: e1a00004 mov r0, r4 <== NOT EXECUTED
a000ac1c: ebffffb9 bl a000ab08 <_POSIX_RWLock_Translate_core_RWLock_return_code><== NOT EXECUTED
a000ac20: ea000000 b a000ac28 <pthread_rwlock_unlock+0x48> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000ac24: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a000ac28: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000ac30 <pthread_rwlock_wrlock>:
*/
int pthread_rwlock_wrlock(
pthread_rwlock_t *rwlock
)
{
a000ac30: e92d4013 push {r0, r1, r4, lr} <== NOT EXECUTED
POSIX_RWLock_Control *the_rwlock;
Objects_Locations location;
if ( !rwlock )
a000ac34: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a000ac38: 0a000011 beq a000ac84 <pthread_rwlock_wrlock+0x54> <== NOT EXECUTED
a000ac3c: e59f0048 ldr r0, [pc, #72] ; a000ac8c <pthread_rwlock_wrlock+0x5c><== NOT EXECUTED
a000ac40: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000ac44: e28d2004 add r2, sp, #4 <== NOT EXECUTED
a000ac48: eb00097a bl a000d238 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
a000ac4c: e59d3004 ldr r3, [sp, #4] <== NOT EXECUTED
a000ac50: e3530000 cmp r3, #0 <== NOT EXECUTED
a000ac54: 1a00000a bne a000ac84 <pthread_rwlock_wrlock+0x54> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_RWLock_Obtain_for_writing(
a000ac58: e58d3000 str r3, [sp] <== NOT EXECUTED
a000ac5c: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000ac60: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000ac64: e3a02001 mov r2, #1 <== NOT EXECUTED
a000ac68: eb00066b bl a000c61c <_CORE_RWLock_Obtain_for_writing> <== NOT EXECUTED
true, /* do not timeout -- wait forever */
0,
NULL
);
_Thread_Enable_dispatch();
a000ac6c: eb000c29 bl a000dd18 <_Thread_Enable_dispatch> <== NOT EXECUTED
return _POSIX_RWLock_Translate_core_RWLock_return_code(
(CORE_RWLock_Status) _Thread_Executing->Wait.return_code
a000ac70: e59f3018 ldr r3, [pc, #24] ; a000ac90 <pthread_rwlock_wrlock+0x60><== NOT EXECUTED
a000ac74: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
0,
NULL
);
_Thread_Enable_dispatch();
return _POSIX_RWLock_Translate_core_RWLock_return_code(
a000ac78: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED
a000ac7c: ebffffa1 bl a000ab08 <_POSIX_RWLock_Translate_core_RWLock_return_code><== NOT EXECUTED
a000ac80: ea000000 b a000ac88 <pthread_rwlock_wrlock+0x58> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000ac84: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a000ac88: e8bd801c pop {r2, r3, r4, pc} <== NOT EXECUTED
a000b1b0 <pthread_rwlockattr_destroy>:
int pthread_rwlockattr_destroy(
pthread_rwlockattr_t *attr
)
{
if ( !attr || attr->is_initialized == false )
a000b1b0: e2503000 subs r3, r0, #0 <== NOT EXECUTED
return EINVAL;
a000b1b4: 03a00016 moveq r0, #22 <== NOT EXECUTED
int pthread_rwlockattr_destroy(
pthread_rwlockattr_t *attr
)
{
if ( !attr || attr->is_initialized == false )
a000b1b8: 012fff1e bxeq lr <== NOT EXECUTED
a000b1bc: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000b1c0: e3520000 cmp r2, #0 <== NOT EXECUTED
return EINVAL;
attr->is_initialized = false;
a000b1c4: 13a00000 movne r0, #0 <== NOT EXECUTED
a000b1c8: 15830000 strne r0, [r3] <== NOT EXECUTED
int pthread_rwlockattr_destroy(
pthread_rwlockattr_t *attr
)
{
if ( !attr || attr->is_initialized == false )
return EINVAL;
a000b1cc: 03a00016 moveq r0, #22 <== NOT EXECUTED
attr->is_initialized = false;
return 0;
}
a000b1d0: e12fff1e bx lr <== NOT EXECUTED
a000b1d4 <pthread_rwlockattr_getpshared>:
int pthread_rwlockattr_getpshared(
const pthread_rwlockattr_t *attr,
int *pshared
)
{
if ( !attr )
a000b1d4: e3500000 cmp r0, #0
return EINVAL;
a000b1d8: 03a00016 moveq r0, #22
int pthread_rwlockattr_getpshared(
const pthread_rwlockattr_t *attr,
int *pshared
)
{
if ( !attr )
a000b1dc: 012fff1e bxeq lr
return EINVAL;
if ( !attr->is_initialized )
a000b1e0: e5903000 ldr r3, [r0]
a000b1e4: e3530000 cmp r3, #0 <== NOT EXECUTED
return EINVAL;
*pshared = attr->process_shared;
a000b1e8: 15903004 ldrne r3, [r0, #4] <== NOT EXECUTED
{
if ( !attr )
return EINVAL;
if ( !attr->is_initialized )
return EINVAL;
a000b1ec: 03a00016 moveq r0, #22 <== NOT EXECUTED
*pshared = attr->process_shared;
return 0;
a000b1f0: 13a00000 movne r0, #0 <== NOT EXECUTED
return EINVAL;
if ( !attr->is_initialized )
return EINVAL;
*pshared = attr->process_shared;
a000b1f4: 15813000 strne r3, [r1] <== NOT EXECUTED
return 0;
}
a000b1f8: e12fff1e bx lr <== NOT EXECUTED
a000b218 <pthread_rwlockattr_setpshared>:
int pthread_rwlockattr_setpshared(
pthread_rwlockattr_t *attr,
int pshared
)
{
if ( !attr )
a000b218: e3500000 cmp r0, #0
a000b21c: 0a000007 beq a000b240 <pthread_rwlockattr_setpshared+0x28>
return EINVAL;
if ( !attr->is_initialized )
a000b220: e5903000 ldr r3, [r0]
a000b224: e3530000 cmp r3, #0
a000b228: 0a000004 beq a000b240 <pthread_rwlockattr_setpshared+0x28>
return EINVAL;
switch ( pshared ) {
a000b22c: e3510001 cmp r1, #1 <== NOT EXECUTED
case PTHREAD_PROCESS_SHARED:
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
a000b230: 95801004 strls r1, [r0, #4] <== NOT EXECUTED
return 0;
a000b234: 93a00000 movls r0, #0 <== NOT EXECUTED
return EINVAL;
if ( !attr->is_initialized )
return EINVAL;
switch ( pshared ) {
a000b238: 912fff1e bxls lr <== NOT EXECUTED
a000b23c: ea000001 b a000b248 <pthread_rwlockattr_setpshared+0x30> <== NOT EXECUTED
{
if ( !attr )
return EINVAL;
if ( !attr->is_initialized )
return EINVAL;
a000b240: e3a00016 mov r0, #22
a000b244: e12fff1e bx lr
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
return 0;
default:
return EINVAL;
a000b248: e3a00016 mov r0, #22
}
}
a000b24c: e12fff1e bx lr <== NOT EXECUTED
a0009090 <pthread_setcancelstate>:
* Don't even think about deleting a resource from an ISR.
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
a0009090: e59f3068 ldr r3, [pc, #104] ; a0009100 <pthread_setcancelstate+0x70>
int pthread_setcancelstate(
int state,
int *oldstate
)
{
a0009094: e92d4010 push {r4, lr}
* Don't even think about deleting a resource from an ISR.
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
a0009098: e5934000 ldr r4, [r3]
a000909c: e3540000 cmp r4, #0
a00090a0: 1a000010 bne a00090e8 <pthread_setcancelstate+0x58>
return EPROTO;
if ( !oldstate )
a00090a4: e3510000 cmp r1, #0
a00090a8: 0a000010 beq a00090f0 <pthread_setcancelstate+0x60>
return EINVAL;
if ( state != PTHREAD_CANCEL_ENABLE && state != PTHREAD_CANCEL_DISABLE )
a00090ac: e3500001 cmp r0, #1
a00090b0: 8a000010 bhi a00090f8 <pthread_setcancelstate+0x68>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a00090b4: e59fc048 ldr ip, [pc, #72] ; a0009104 <pthread_setcancelstate+0x74>
return EINVAL;
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a00090b8: e5932004 ldr r2, [r3, #4]
a00090bc: e59ce000 ldr lr, [ip]
a00090c0: e59220fc ldr r2, [r2, #252] ; 0xfc
a00090c4: e28ee001 add lr, lr, #1
a00090c8: e58ce000 str lr, [ip]
_Thread_Disable_dispatch();
*oldstate = thread_support->cancelability_state;
a00090cc: e592c0d8 ldr ip, [r2, #216] ; 0xd8
a00090d0: e581c000 str ip, [r1]
thread_support->cancelability_state = state;
a00090d4: e58200d8 str r0, [r2, #216] ; 0xd8
_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch(_Thread_Executing);
a00090d8: e5930004 ldr r0, [r3, #4]
a00090dc: eb0014bf bl a000e3e0 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch>
/*
* _Thread_Enable_dispatch is invoked by above call.
*/
return 0;
a00090e0: e1a00004 mov r0, r4
a00090e4: e8bd8010 pop {r4, pc}
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
return EPROTO;
a00090e8: e3a00047 mov r0, #71 ; 0x47
a00090ec: e8bd8010 pop {r4, pc}
if ( !oldstate )
return EINVAL;
a00090f0: e3a00016 mov r0, #22
a00090f4: e8bd8010 pop {r4, pc}
if ( state != PTHREAD_CANCEL_ENABLE && state != PTHREAD_CANCEL_DISABLE )
return EINVAL;
a00090f8: e3a00016 mov r0, #22
/*
* _Thread_Enable_dispatch is invoked by above call.
*/
return 0;
}
a00090fc: e8bd8010 pop {r4, pc}
a0009108 <pthread_setcanceltype>:
* Don't even think about deleting a resource from an ISR.
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
a0009108: e59f3068 ldr r3, [pc, #104] ; a0009178 <pthread_setcanceltype+0x70>
int pthread_setcanceltype(
int type,
int *oldtype
)
{
a000910c: e92d4010 push {r4, lr}
* Don't even think about deleting a resource from an ISR.
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
a0009110: e5934000 ldr r4, [r3]
a0009114: e3540000 cmp r4, #0
a0009118: 1a000010 bne a0009160 <pthread_setcanceltype+0x58>
return EPROTO;
if ( !oldtype )
a000911c: e3510000 cmp r1, #0
a0009120: 0a000010 beq a0009168 <pthread_setcanceltype+0x60>
return EINVAL;
if ( type != PTHREAD_CANCEL_DEFERRED && type != PTHREAD_CANCEL_ASYNCHRONOUS )
a0009124: e3500001 cmp r0, #1
a0009128: 8a000010 bhi a0009170 <pthread_setcanceltype+0x68>
a000912c: e59fc048 ldr ip, [pc, #72] ; a000917c <pthread_setcanceltype+0x74>
return EINVAL;
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0009130: e5932004 ldr r2, [r3, #4]
a0009134: e59ce000 ldr lr, [ip]
a0009138: e59220fc ldr r2, [r2, #252] ; 0xfc
a000913c: e28ee001 add lr, lr, #1
a0009140: e58ce000 str lr, [ip]
_Thread_Disable_dispatch();
*oldtype = thread_support->cancelability_type;
a0009144: e592c0dc ldr ip, [r2, #220] ; 0xdc
a0009148: e581c000 str ip, [r1]
thread_support->cancelability_type = type;
a000914c: e58200dc str r0, [r2, #220] ; 0xdc
_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch(_Thread_Executing);
a0009150: e5930004 ldr r0, [r3, #4]
a0009154: eb0014a1 bl a000e3e0 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch>
/*
* _Thread_Enable_dispatch is invoked by above call.
*/
return 0;
a0009158: e1a00004 mov r0, r4
a000915c: e8bd8010 pop {r4, pc}
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
return EPROTO;
a0009160: e3a00047 mov r0, #71 ; 0x47 <== NOT EXECUTED
a0009164: e8bd8010 pop {r4, pc} <== NOT EXECUTED
if ( !oldtype )
return EINVAL;
a0009168: e3a00016 mov r0, #22
a000916c: e8bd8010 pop {r4, pc}
if ( type != PTHREAD_CANCEL_DEFERRED && type != PTHREAD_CANCEL_ASYNCHRONOUS )
return EINVAL;
a0009170: e3a00016 mov r0, #22
/*
* _Thread_Enable_dispatch is invoked by above call.
*/
return 0;
}
a0009174: e8bd8010 pop {r4, pc}
a000c1f0 <pthread_setschedparam>:
int pthread_setschedparam(
pthread_t thread,
int policy,
struct sched_param *param
)
{
a000c1f0: e92d41f7 push {r0, r1, r2, r4, r5, r6, r7, r8, lr}
int rc;
/*
* Check all the parameters
*/
if ( !param )
a000c1f4: e2528000 subs r8, r2, #0
int pthread_setschedparam(
pthread_t thread,
int policy,
struct sched_param *param
)
{
a000c1f8: e1a04000 mov r4, r0
a000c1fc: e1a06001 mov r6, r1
/*
* Check all the parameters
*/
if ( !param )
return EINVAL;
a000c200: 03a07016 moveq r7, #22
int rc;
/*
* Check all the parameters
*/
if ( !param )
a000c204: 0a00003a beq a000c2f4 <pthread_setschedparam+0x104>
return EINVAL;
rc = _POSIX_Thread_Translate_sched_param(
a000c208: e1a00001 mov r0, r1
a000c20c: e28d2008 add r2, sp, #8
a000c210: e1a01008 mov r1, r8
a000c214: e28d3004 add r3, sp, #4
a000c218: eb00168f bl a0011c5c <_POSIX_Thread_Translate_sched_param>
policy,
param,
&budget_algorithm,
&budget_callout
);
if ( rc )
a000c21c: e2507000 subs r7, r0, #0
a000c220: 1a000033 bne a000c2f4 <pthread_setschedparam+0x104>
a000c224: e59f00d0 ldr r0, [pc, #208] ; a000c2fc <pthread_setschedparam+0x10c>
a000c228: e1a01004 mov r1, r4
a000c22c: e1a0200d mov r2, sp
a000c230: eb000792 bl a000e080 <_Objects_Get>
/*
* Actually change the scheduling policy and parameters
*/
the_thread = _POSIX_Threads_Get( thread, &location );
switch ( location ) {
a000c234: e59d3000 ldr r3, [sp]
a000c238: e1a05000 mov r5, r0
a000c23c: e3530000 cmp r3, #0
#endif
case OBJECTS_ERROR:
break;
}
return ESRCH;
a000c240: 13a07003 movne r7, #3
/*
* Actually change the scheduling policy and parameters
*/
the_thread = _POSIX_Threads_Get( thread, &location );
switch ( location ) {
a000c244: 1a00002a bne a000c2f4 <pthread_setschedparam+0x104>
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
a000c248: e59040fc ldr r4, [r0, #252] ; 0xfc
if ( api->schedpolicy == SCHED_SPORADIC )
a000c24c: e5943084 ldr r3, [r4, #132] ; 0x84
a000c250: e3530004 cmp r3, #4
a000c254: 1a000001 bne a000c260 <pthread_setschedparam+0x70>
(void) _Watchdog_Remove( &api->Sporadic_timer );
a000c258: e28400a8 add r0, r4, #168 ; 0xa8 <== NOT EXECUTED
a000c25c: eb000e8a bl a000fc8c <_Watchdog_Remove> <== NOT EXECUTED
api->schedpolicy = policy;
a000c260: e5846084 str r6, [r4, #132] ; 0x84
api->schedparam = *param;
a000c264: e284c088 add ip, r4, #136 ; 0x88
a000c268: e8b8000f ldm r8!, {r0, r1, r2, r3}
a000c26c: e8ac000f stmia ip!, {r0, r1, r2, r3}
the_thread->budget_algorithm = budget_algorithm;
a000c270: e59d3008 ldr r3, [sp, #8]
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
api->schedpolicy = policy;
api->schedparam = *param;
a000c274: e8980007 ldm r8, {r0, r1, r2}
a000c278: e88c0007 stm ip, {r0, r1, r2}
the_thread->budget_algorithm = budget_algorithm;
a000c27c: e585307c str r3, [r5, #124] ; 0x7c
the_thread->budget_callout = budget_callout;
a000c280: e59d3004 ldr r3, [sp, #4]
switch ( api->schedpolicy ) {
a000c284: e3560000 cmp r6, #0
(void) _Watchdog_Remove( &api->Sporadic_timer );
api->schedpolicy = policy;
api->schedparam = *param;
the_thread->budget_algorithm = budget_algorithm;
the_thread->budget_callout = budget_callout;
a000c288: e5853080 str r3, [r5, #128] ; 0x80
switch ( api->schedpolicy ) {
a000c28c: ba000017 blt a000c2f0 <pthread_setschedparam+0x100>
a000c290: e3560002 cmp r6, #2
a000c294: da000002 ble a000c2a4 <pthread_setschedparam+0xb4>
a000c298: e3560004 cmp r6, #4
a000c29c: 1a000013 bne a000c2f0 <pthread_setschedparam+0x100>
a000c2a0: ea00000b b a000c2d4 <pthread_setschedparam+0xe4>
case SCHED_OTHER:
case SCHED_FIFO:
case SCHED_RR:
the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice;
a000c2a4: e59f3054 ldr r3, [pc, #84] ; a000c300 <pthread_setschedparam+0x110>
the_thread->real_priority =
_POSIX_Priority_To_core( api->schedparam.sched_priority );
_Thread_Change_priority(
a000c2a8: e1a00005 mov r0, r5
a000c2ac: e3a02001 mov r2, #1
switch ( api->schedpolicy ) {
case SCHED_OTHER:
case SCHED_FIFO:
case SCHED_RR:
the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice;
a000c2b0: e5933000 ldr r3, [r3]
a000c2b4: e5853078 str r3, [r5, #120] ; 0x78
a000c2b8: e59f3044 ldr r3, [pc, #68] ; a000c304 <pthread_setschedparam+0x114>
a000c2bc: e5d31000 ldrb r1, [r3]
a000c2c0: e5943088 ldr r3, [r4, #136] ; 0x88
a000c2c4: e0631001 rsb r1, r3, r1
the_thread->real_priority =
a000c2c8: e5851018 str r1, [r5, #24]
_POSIX_Priority_To_core( api->schedparam.sched_priority );
_Thread_Change_priority(
a000c2cc: eb0008fd bl a000e6c8 <_Thread_Change_priority>
the_thread,
the_thread->real_priority,
true
);
break;
a000c2d0: ea000006 b a000c2f0 <pthread_setschedparam+0x100>
case SCHED_SPORADIC:
api->ss_high_priority = api->schedparam.sched_priority;
a000c2d4: e5943088 ldr r3, [r4, #136] ; 0x88
_Watchdog_Remove( &api->Sporadic_timer );
a000c2d8: e28400a8 add r0, r4, #168 ; 0xa8
true
);
break;
case SCHED_SPORADIC:
api->ss_high_priority = api->schedparam.sched_priority;
a000c2dc: e58430a4 str r3, [r4, #164] ; 0xa4
_Watchdog_Remove( &api->Sporadic_timer );
a000c2e0: eb000e69 bl a000fc8c <_Watchdog_Remove>
_POSIX_Threads_Sporadic_budget_TSR( 0, the_thread );
a000c2e4: e3a00000 mov r0, #0
a000c2e8: e1a01005 mov r1, r5
a000c2ec: ebffff76 bl a000c0cc <_POSIX_Threads_Sporadic_budget_TSR>
break;
}
_Thread_Enable_dispatch();
a000c2f0: eb000a1a bl a000eb60 <_Thread_Enable_dispatch>
case OBJECTS_ERROR:
break;
}
return ESRCH;
}
a000c2f4: e1a00007 mov r0, r7
a000c2f8: e8bd81fe pop {r1, r2, r3, r4, r5, r6, r7, r8, pc}
a000fbbc <pthread_sigmask>:
sigset_t *oset
)
{
POSIX_API_Control *api;
if ( !set && !oset )
a000fbbc: e271c001 rsbs ip, r1, #1
a000fbc0: 33a0c000 movcc ip, #0
a000fbc4: e3520000 cmp r2, #0
a000fbc8: 03510000 cmpeq r1, #0
int pthread_sigmask(
int how,
const sigset_t *set,
sigset_t *oset
)
{
a000fbcc: e92d4010 push {r4, lr}
POSIX_API_Control *api;
if ( !set && !oset )
a000fbd0: 0a00001f beq a000fc54 <pthread_sigmask+0x98>
rtems_set_errno_and_return_minus_one( EINVAL );
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a000fbd4: e59f30a0 ldr r3, [pc, #160] ; a000fc7c <pthread_sigmask+0xc0>
if ( oset )
a000fbd8: e3520000 cmp r2, #0
POSIX_API_Control *api;
if ( !set && !oset )
rtems_set_errno_and_return_minus_one( EINVAL );
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a000fbdc: e5933004 ldr r3, [r3, #4]
a000fbe0: e59330fc ldr r3, [r3, #252] ; 0xfc
if ( oset )
*oset = api->signals_blocked;
a000fbe4: 159340d0 ldrne r4, [r3, #208] ; 0xd0
a000fbe8: 15824000 strne r4, [r2]
if ( !set )
a000fbec: e35c0000 cmp ip, #0
a000fbf0: 1a00001f bne a000fc74 <pthread_sigmask+0xb8>
return 0;
switch ( how ) {
a000fbf4: e3500001 cmp r0, #1
a000fbf8: 0a000005 beq a000fc14 <pthread_sigmask+0x58>
a000fbfc: e3500002 cmp r0, #2
a000fc00: 0a000007 beq a000fc24 <pthread_sigmask+0x68>
a000fc04: e3500000 cmp r0, #0 <== NOT EXECUTED
break;
case SIG_UNBLOCK:
api->signals_blocked &= ~*set;
break;
case SIG_SETMASK:
api->signals_blocked = *set;
a000fc08: 05912000 ldreq r2, [r1] <== NOT EXECUTED
*oset = api->signals_blocked;
if ( !set )
return 0;
switch ( how ) {
a000fc0c: 0a000007 beq a000fc30 <pthread_sigmask+0x74> <== NOT EXECUTED
a000fc10: ea00000f b a000fc54 <pthread_sigmask+0x98> <== NOT EXECUTED
case SIG_BLOCK:
api->signals_blocked |= *set;
a000fc14: e59300d0 ldr r0, [r3, #208] ; 0xd0
a000fc18: e5912000 ldr r2, [r1]
a000fc1c: e1802002 orr r2, r0, r2
a000fc20: ea000002 b a000fc30 <pthread_sigmask+0x74>
break;
case SIG_UNBLOCK:
api->signals_blocked &= ~*set;
a000fc24: e5911000 ldr r1, [r1]
a000fc28: e59320d0 ldr r2, [r3, #208] ; 0xd0
a000fc2c: e1c22001 bic r2, r2, r1
break;
case SIG_SETMASK:
api->signals_blocked = *set;
a000fc30: e58320d0 str r2, [r3, #208] ; 0xd0
/* XXX are there critical section problems here? */
/* XXX evaluate the new set */
if ( ~api->signals_blocked &
(api->signals_pending | _POSIX_signals_Pending) ) {
a000fc34: e59f2044 ldr r2, [pc, #68] ; a000fc80 <pthread_sigmask+0xc4>
a000fc38: e5920000 ldr r0, [r2]
a000fc3c: e59320d4 ldr r2, [r3, #212] ; 0xd4
/* XXX are there critical section problems here? */
/* XXX evaluate the new set */
if ( ~api->signals_blocked &
a000fc40: e59330d0 ldr r3, [r3, #208] ; 0xd0
(api->signals_pending | _POSIX_signals_Pending) ) {
a000fc44: e1800002 orr r0, r0, r2
/* XXX are there critical section problems here? */
/* XXX evaluate the new set */
if ( ~api->signals_blocked &
a000fc48: e1d00003 bics r0, r0, r3
a000fc4c: 0a000009 beq a000fc78 <pthread_sigmask+0xbc>
a000fc50: ea000004 b a000fc68 <pthread_sigmask+0xac>
break;
case SIG_SETMASK:
api->signals_blocked = *set;
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
a000fc54: eb0009b6 bl a0012334 <__errno> <== NOT EXECUTED
a000fc58: e3a03016 mov r3, #22 <== NOT EXECUTED
a000fc5c: e5803000 str r3, [r0] <== NOT EXECUTED
a000fc60: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000fc64: e8bd8010 pop {r4, pc} <== NOT EXECUTED
/* XXX evaluate the new set */
if ( ~api->signals_blocked &
(api->signals_pending | _POSIX_signals_Pending) ) {
_Thread_Dispatch();
a000fc68: ebfff24d bl a000c5a4 <_Thread_Dispatch>
}
return 0;
a000fc6c: e3a00000 mov r0, #0
a000fc70: e8bd8010 pop {r4, pc}
if ( oset )
*oset = api->signals_blocked;
if ( !set )
return 0;
a000fc74: e3a00000 mov r0, #0 <== NOT EXECUTED
(api->signals_pending | _POSIX_signals_Pending) ) {
_Thread_Dispatch();
}
return 0;
}
a000fc78: e8bd8010 pop {r4, pc}
a00096d0 <pthread_spin_destroy>:
)
{
POSIX_Spinlock_Control *the_spinlock = NULL;
Objects_Locations location;
if ( !spinlock )
a00096d0: e2503000 subs r3, r0, #0 <== NOT EXECUTED
*/
int pthread_spin_destroy(
pthread_spinlock_t *spinlock
)
{
a00096d4: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
POSIX_Spinlock_Control *the_spinlock = NULL;
Objects_Locations location;
if ( !spinlock )
a00096d8: 0a000016 beq a0009738 <pthread_spin_destroy+0x68> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE POSIX_Spinlock_Control *_POSIX_Spinlock_Get (
pthread_spinlock_t *spinlock,
Objects_Locations *location
)
{
return (POSIX_Spinlock_Control *) _Objects_Get(
a00096dc: e5931000 ldr r1, [r3] <== NOT EXECUTED
a00096e0: e59f0058 ldr r0, [pc, #88] ; a0009740 <pthread_spin_destroy+0x70><== NOT EXECUTED
a00096e4: e1a0200d mov r2, sp <== NOT EXECUTED
a00096e8: eb000821 bl a000b774 <_Objects_Get> <== NOT EXECUTED
return EINVAL;
the_spinlock = _POSIX_Spinlock_Get( spinlock, &location );
switch ( location ) {
a00096ec: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a00096f0: e1a04000 mov r4, r0 <== NOT EXECUTED
a00096f4: e3530000 cmp r3, #0 <== NOT EXECUTED
a00096f8: 1a00000e bne a0009738 <pthread_spin_destroy+0x68> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE bool _CORE_spinlock_Is_busy(
CORE_spinlock_Control *the_spinlock
)
{
return (the_spinlock->users != 0);
a00096fc: e5905018 ldr r5, [r0, #24] <== NOT EXECUTED
case OBJECTS_LOCAL:
if ( _CORE_spinlock_Is_busy( &the_spinlock->Spinlock ) ) {
a0009700: e3550000 cmp r5, #0 <== NOT EXECUTED
a0009704: 0a000002 beq a0009714 <pthread_spin_destroy+0x44> <== NOT EXECUTED
_Thread_Enable_dispatch();
a0009708: eb000ad1 bl a000c254 <_Thread_Enable_dispatch> <== NOT EXECUTED
return EBUSY;
a000970c: e3a00010 mov r0, #16 <== NOT EXECUTED
a0009710: ea000009 b a000973c <pthread_spin_destroy+0x6c> <== NOT EXECUTED
}
_Objects_Close( &_POSIX_Spinlock_Information, &the_spinlock->Object );
a0009714: e59f0024 ldr r0, [pc, #36] ; a0009740 <pthread_spin_destroy+0x70><== NOT EXECUTED
a0009718: e1a01004 mov r1, r4 <== NOT EXECUTED
a000971c: eb000715 bl a000b378 <_Objects_Close> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _POSIX_Spinlock_Free (
POSIX_Spinlock_Control *the_spinlock
)
{
_Objects_Free( &_POSIX_Spinlock_Information, &the_spinlock->Object );
a0009720: e59f0018 ldr r0, [pc, #24] ; a0009740 <pthread_spin_destroy+0x70><== NOT EXECUTED
a0009724: e1a01004 mov r1, r4 <== NOT EXECUTED
a0009728: eb0007b9 bl a000b614 <_Objects_Free> <== NOT EXECUTED
_POSIX_Spinlock_Free( the_spinlock );
_Thread_Enable_dispatch();
a000972c: eb000ac8 bl a000c254 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a0009730: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009734: ea000000 b a000973c <pthread_spin_destroy+0x6c> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a0009738: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a000973c: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a0009744 <pthread_spin_init>:
int pthread_spin_init(
pthread_spinlock_t *spinlock,
int pshared
)
{
a0009744: e92d40f1 push {r0, r4, r5, r6, r7, lr}
POSIX_Spinlock_Control *the_spinlock;
CORE_spinlock_Attributes attributes;
if ( !spinlock )
a0009748: e2507000 subs r7, r0, #0
int pthread_spin_init(
pthread_spinlock_t *spinlock,
int pshared
)
{
a000974c: e1a05001 mov r5, r1
POSIX_Spinlock_Control *the_spinlock;
CORE_spinlock_Attributes attributes;
if ( !spinlock )
a0009750: 0a00001b beq a00097c4 <pthread_spin_init+0x80>
return EINVAL;
switch ( pshared ) {
a0009754: e3510000 cmp r1, #0
a0009758: 1a000019 bne a00097c4 <pthread_spin_init+0x80>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000975c: e59f3068 ldr r3, [pc, #104] ; a00097cc <pthread_spin_init+0x88>
a0009760: e5932000 ldr r2, [r3]
a0009764: e2822001 add r2, r2, #1
a0009768: e5832000 str r2, [r3]
* the inactive chain of free spinlock control blocks.
*/
RTEMS_INLINE_ROUTINE POSIX_Spinlock_Control *_POSIX_Spinlock_Allocate( void )
{
return (POSIX_Spinlock_Control *)
_Objects_Allocate( &_POSIX_Spinlock_Information );
a000976c: e59f605c ldr r6, [pc, #92] ; a00097d0 <pthread_spin_init+0x8c>
a0009770: e1a00006 mov r0, r6
a0009774: eb0006dd bl a000b2f0 <_Objects_Allocate>
_Thread_Disable_dispatch(); /* prevents deletion */
the_spinlock = _POSIX_Spinlock_Allocate();
if ( !the_spinlock ) {
a0009778: e2504000 subs r4, r0, #0
a000977c: 1a000002 bne a000978c <pthread_spin_init+0x48>
_Thread_Enable_dispatch();
a0009780: eb000ab3 bl a000c254 <_Thread_Enable_dispatch> <== NOT EXECUTED
return EAGAIN;
a0009784: e3a0000b mov r0, #11 <== NOT EXECUTED
a0009788: ea00000e b a00097c8 <pthread_spin_init+0x84> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _CORE_spinlock_Initialize_attributes(
CORE_spinlock_Attributes *the_attributes
)
{
the_attributes->XXX = 0;
a000978c: e28d1004 add r1, sp, #4
}
_CORE_spinlock_Initialize_attributes( &attributes );
_CORE_spinlock_Initialize( &the_spinlock->Spinlock, &attributes );
a0009790: e2840010 add r0, r4, #16
a0009794: e5215004 str r5, [r1, #-4]!
a0009798: e1a0100d mov r1, sp
a000979c: eb000525 bl a000ac38 <_CORE_spinlock_Initialize>
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a00097a0: e596201c ldr r2, [r6, #28]
Objects_Information *information,
Objects_Control *the_object,
uint32_t name
)
{
_Objects_Set_local_object(
a00097a4: e5943008 ldr r3, [r4, #8]
a00097a8: e1d410b8 ldrh r1, [r4, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a00097ac: e7824101 str r4, [r2, r1, lsl #2]
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
a00097b0: e584500c str r5, [r4, #12]
_Objects_Open_u32( &_POSIX_Spinlock_Information, &the_spinlock->Object, 0 );
*spinlock = the_spinlock->Object.id;
a00097b4: e5873000 str r3, [r7]
_Thread_Enable_dispatch();
a00097b8: eb000aa5 bl a000c254 <_Thread_Enable_dispatch>
return 0;
a00097bc: e1a00005 mov r0, r5
a00097c0: ea000000 b a00097c8 <pthread_spin_init+0x84>
switch ( pshared ) {
case PTHREAD_PROCESS_PRIVATE: /* only supported values */
break;
case PTHREAD_PROCESS_SHARED:
default:
return EINVAL;
a00097c4: e3a00016 mov r0, #22
*spinlock = the_spinlock->Object.id;
_Thread_Enable_dispatch();
return 0;
}
a00097c8: e8bd80f8 pop {r3, r4, r5, r6, r7, pc}
a00097d4 <pthread_spin_lock>:
{
POSIX_Spinlock_Control *the_spinlock = NULL;
Objects_Locations location;
CORE_spinlock_Status status;
if ( !spinlock )
a00097d4: e2503000 subs r3, r0, #0
*/
int pthread_spin_lock(
pthread_spinlock_t *spinlock
)
{
a00097d8: e92d4011 push {r0, r4, lr}
POSIX_Spinlock_Control *the_spinlock = NULL;
Objects_Locations location;
CORE_spinlock_Status status;
if ( !spinlock )
a00097dc: 0a00000e beq a000981c <pthread_spin_lock+0x48>
RTEMS_INLINE_ROUTINE POSIX_Spinlock_Control *_POSIX_Spinlock_Get (
pthread_spinlock_t *spinlock,
Objects_Locations *location
)
{
return (POSIX_Spinlock_Control *) _Objects_Get(
a00097e0: e1a0200d mov r2, sp
a00097e4: e59f0038 ldr r0, [pc, #56] ; a0009824 <pthread_spin_lock+0x50>
a00097e8: e5931000 ldr r1, [r3]
a00097ec: eb0007e0 bl a000b774 <_Objects_Get>
return EINVAL;
the_spinlock = _POSIX_Spinlock_Get( spinlock, &location );
switch ( location ) {
a00097f0: e59d2000 ldr r2, [sp]
a00097f4: e3520000 cmp r2, #0
a00097f8: 1a000007 bne a000981c <pthread_spin_lock+0x48>
case OBJECTS_LOCAL:
status = _CORE_spinlock_Wait( &the_spinlock->Spinlock, true, 0 );
a00097fc: e3a01001 mov r1, #1
a0009800: e2800010 add r0, r0, #16
a0009804: eb00052e bl a000acc4 <_CORE_spinlock_Wait>
a0009808: e1a04000 mov r4, r0
_Thread_Enable_dispatch();
a000980c: eb000a90 bl a000c254 <_Thread_Enable_dispatch>
return _POSIX_Spinlock_Translate_core_spinlock_return_code( status );
a0009810: e1a00004 mov r0, r4
a0009814: eb000003 bl a0009828 <_POSIX_Spinlock_Translate_core_spinlock_return_code>
a0009818: ea000000 b a0009820 <pthread_spin_lock+0x4c>
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a000981c: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a0009820: e8bd8018 pop {r3, r4, pc}
a0009838 <pthread_spin_trylock>:
{
POSIX_Spinlock_Control *the_spinlock = NULL;
Objects_Locations location;
CORE_spinlock_Status status;
if ( !spinlock )
a0009838: e2503000 subs r3, r0, #0
*/
int pthread_spin_trylock(
pthread_spinlock_t *spinlock
)
{
a000983c: e92d4011 push {r0, r4, lr}
POSIX_Spinlock_Control *the_spinlock = NULL;
Objects_Locations location;
CORE_spinlock_Status status;
if ( !spinlock )
a0009840: 0a00000e beq a0009880 <pthread_spin_trylock+0x48>
a0009844: e5931000 ldr r1, [r3]
a0009848: e59f0038 ldr r0, [pc, #56] ; a0009888 <pthread_spin_trylock+0x50>
a000984c: e1a0200d mov r2, sp
a0009850: eb0007c7 bl a000b774 <_Objects_Get>
return EINVAL;
the_spinlock = _POSIX_Spinlock_Get( spinlock, &location );
switch ( location ) {
a0009854: e59d1000 ldr r1, [sp]
a0009858: e3510000 cmp r1, #0
a000985c: 1a000007 bne a0009880 <pthread_spin_trylock+0x48>
case OBJECTS_LOCAL:
status = _CORE_spinlock_Wait( &the_spinlock->Spinlock, false, 0 );
a0009860: e1a02001 mov r2, r1
a0009864: e2800010 add r0, r0, #16
a0009868: eb000515 bl a000acc4 <_CORE_spinlock_Wait>
a000986c: e1a04000 mov r4, r0
_Thread_Enable_dispatch();
a0009870: eb000a77 bl a000c254 <_Thread_Enable_dispatch>
return _POSIX_Spinlock_Translate_core_spinlock_return_code( status );
a0009874: e1a00004 mov r0, r4
a0009878: ebffffea bl a0009828 <_POSIX_Spinlock_Translate_core_spinlock_return_code>
a000987c: ea000000 b a0009884 <pthread_spin_trylock+0x4c>
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a0009880: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a0009884: e8bd8018 pop {r3, r4, pc}
a000988c <pthread_spin_unlock>:
{
POSIX_Spinlock_Control *the_spinlock = NULL;
Objects_Locations location;
CORE_spinlock_Status status;
if ( !spinlock )
a000988c: e2503000 subs r3, r0, #0
*/
int pthread_spin_unlock(
pthread_spinlock_t *spinlock
)
{
a0009890: e92d4011 push {r0, r4, lr}
POSIX_Spinlock_Control *the_spinlock = NULL;
Objects_Locations location;
CORE_spinlock_Status status;
if ( !spinlock )
a0009894: 0a00000d beq a00098d0 <pthread_spin_unlock+0x44>
a0009898: e5931000 ldr r1, [r3]
a000989c: e59f0034 ldr r0, [pc, #52] ; a00098d8 <pthread_spin_unlock+0x4c>
a00098a0: e1a0200d mov r2, sp
a00098a4: eb0007b2 bl a000b774 <_Objects_Get>
return EINVAL;
the_spinlock = _POSIX_Spinlock_Get( spinlock, &location );
switch ( location ) {
a00098a8: e59d3000 ldr r3, [sp]
a00098ac: e3530000 cmp r3, #0
a00098b0: 1a000006 bne a00098d0 <pthread_spin_unlock+0x44>
case OBJECTS_LOCAL:
status = _CORE_spinlock_Release( &the_spinlock->Spinlock );
a00098b4: e2800010 add r0, r0, #16
a00098b8: eb0004e5 bl a000ac54 <_CORE_spinlock_Release>
a00098bc: e1a04000 mov r4, r0
_Thread_Enable_dispatch();
a00098c0: eb000a63 bl a000c254 <_Thread_Enable_dispatch>
return _POSIX_Spinlock_Translate_core_spinlock_return_code( status );
a00098c4: e1a00004 mov r0, r4
a00098c8: ebffffd6 bl a0009828 <_POSIX_Spinlock_Translate_core_spinlock_return_code>
a00098cc: ea000000 b a00098d4 <pthread_spin_unlock+0x48>
#endif
case OBJECTS_ERROR:
break;
}
return EINVAL;
a00098d0: e3a00016 mov r0, #22 <== NOT EXECUTED
}
a00098d4: e8bd8018 pop {r3, r4, pc}
a0009a10 <pthread_testcancel>:
* Don't even think about deleting a resource from an ISR.
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
a0009a10: e59f3060 ldr r3, [pc, #96] ; a0009a78 <pthread_testcancel+0x68><== NOT EXECUTED
*
* 18.2.2 Setting Cancelability State, P1003.1c/Draft 10, p. 183
*/
void pthread_testcancel( void )
{
a0009a14: e92d4010 push {r4, lr} <== NOT EXECUTED
* Don't even think about deleting a resource from an ISR.
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
a0009a18: e5934000 ldr r4, [r3] <== NOT EXECUTED
a0009a1c: e3540000 cmp r4, #0 <== NOT EXECUTED
a0009a20: 1a000013 bne a0009a74 <pthread_testcancel+0x64> <== NOT EXECUTED
a0009a24: e59f2050 ldr r2, [pc, #80] ; a0009a7c <pthread_testcancel+0x6c><== NOT EXECUTED
return;
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0009a28: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
a0009a2c: e5921000 ldr r1, [r2] <== NOT EXECUTED
a0009a30: e59330fc ldr r3, [r3, #252] ; 0xfc <== NOT EXECUTED
a0009a34: e2811001 add r1, r1, #1 <== NOT EXECUTED
a0009a38: e5821000 str r1, [r2] <== NOT EXECUTED
_Thread_Disable_dispatch();
if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE &&
a0009a3c: e59320d8 ldr r2, [r3, #216] ; 0xd8 <== NOT EXECUTED
a0009a40: e3520000 cmp r2, #0 <== NOT EXECUTED
a0009a44: 1a000002 bne a0009a54 <pthread_testcancel+0x44> <== NOT EXECUTED
/* Setting Cancelability State, P1003.1c/Draft 10, p. 183 */
int _EXFUN(pthread_setcancelstate, (int __state, int *__oldstate));
int _EXFUN(pthread_setcanceltype, (int __type, int *__oldtype));
void _EXFUN(pthread_testcancel, (void));
a0009a48: e59340e0 ldr r4, [r3, #224] ; 0xe0 <== NOT EXECUTED
a0009a4c: e2544000 subs r4, r4, #0 <== NOT EXECUTED
a0009a50: 13a04001 movne r4, #1 <== NOT EXECUTED
thread_support->cancelation_requested )
cancel = true;
_Thread_Enable_dispatch();
a0009a54: eb0009ef bl a000c218 <_Thread_Enable_dispatch> <== NOT EXECUTED
if ( cancel )
a0009a58: e3540000 cmp r4, #0 <== NOT EXECUTED
a0009a5c: 0a000004 beq a0009a74 <pthread_testcancel+0x64> <== NOT EXECUTED
_POSIX_Thread_Exit( _Thread_Executing, PTHREAD_CANCELED );
a0009a60: e59f3010 ldr r3, [pc, #16] ; a0009a78 <pthread_testcancel+0x68><== NOT EXECUTED
a0009a64: e3e01000 mvn r1, #0 <== NOT EXECUTED
a0009a68: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED
}
a0009a6c: e8bd4010 pop {r4, lr} <== NOT EXECUTED
thread_support->cancelation_requested )
cancel = true;
_Thread_Enable_dispatch();
if ( cancel )
_POSIX_Thread_Exit( _Thread_Executing, PTHREAD_CANCELED );
a0009a70: ea00166b b a000f424 <_POSIX_Thread_Exit> <== NOT EXECUTED
a0009a74: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000a410 <rtems_aio_enqueue>:
* errno - otherwise
*/
int
rtems_aio_enqueue (rtems_aio_request *req)
{
a000a410: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr}
struct sched_param param;
/* The queue should be initialized */
AIO_assert (aio_request_queue.initialized == AIO_QUEUE_INITIALIZED);
result = pthread_mutex_lock (&aio_request_queue.mutex);
a000a414: e59f41f0 ldr r4, [pc, #496] ; a000a60c <rtems_aio_enqueue+0x1fc>
* errno - otherwise
*/
int
rtems_aio_enqueue (rtems_aio_request *req)
{
a000a418: e24dd024 sub sp, sp, #36 ; 0x24
a000a41c: e1a06000 mov r6, r0
struct sched_param param;
/* The queue should be initialized */
AIO_assert (aio_request_queue.initialized == AIO_QUEUE_INITIALIZED);
result = pthread_mutex_lock (&aio_request_queue.mutex);
a000a420: e1a00004 mov r0, r4
a000a424: eb000256 bl a000ad84 <pthread_mutex_lock>
if (result != 0) {
a000a428: e2505000 subs r5, r0, #0
a000a42c: 0a000002 beq a000a43c <rtems_aio_enqueue+0x2c>
free (req);
a000a430: e1a00006 mov r0, r6 <== NOT EXECUTED
a000a434: ebfff268 bl a0006ddc <free> <== NOT EXECUTED
return result;
a000a438: ea000070 b a000a600 <rtems_aio_enqueue+0x1f0> <== NOT EXECUTED
}
/* _POSIX_PRIORITIZED_IO and _POSIX_PRIORITY_SCHEDULING are defined,
we can use aio_reqprio to lower the priority of the request */
pthread_getschedparam (pthread_self(), &policy, ¶m);
a000a43c: eb000461 bl a000b5c8 <pthread_self>
a000a440: e28d101c add r1, sp, #28
a000a444: e1a0200d mov r2, sp
a000a448: eb000363 bl a000b1dc <pthread_getschedparam>
req->caller_thread = pthread_self ();
a000a44c: eb00045d bl a000b5c8 <pthread_self>
req->priority = param.sched_priority - req->aiocbp->aio_reqprio;
a000a450: e5963014 ldr r3, [r6, #20]
a000a454: e59d1000 ldr r1, [sp]
/* _POSIX_PRIORITIZED_IO and _POSIX_PRIORITY_SCHEDULING are defined,
we can use aio_reqprio to lower the priority of the request */
pthread_getschedparam (pthread_self(), &policy, ¶m);
req->caller_thread = pthread_self ();
a000a458: e5860010 str r0, [r6, #16]
req->priority = param.sched_priority - req->aiocbp->aio_reqprio;
a000a45c: e5932014 ldr r2, [r3, #20]
a000a460: e0622001 rsb r2, r2, r1
a000a464: e586200c str r2, [r6, #12]
req->policy = policy;
a000a468: e59d201c ldr r2, [sp, #28]
a000a46c: e5862008 str r2, [r6, #8]
req->aiocbp->error_code = EINPROGRESS;
a000a470: e3a02077 mov r2, #119 ; 0x77
a000a474: e5832030 str r2, [r3, #48] ; 0x30
req->aiocbp->return_value = 0;
if ((aio_request_queue.idle_threads == 0) &&
a000a478: e5942068 ldr r2, [r4, #104] ; 0x68
req->caller_thread = pthread_self ();
req->priority = param.sched_priority - req->aiocbp->aio_reqprio;
req->policy = policy;
req->aiocbp->error_code = EINPROGRESS;
req->aiocbp->return_value = 0;
a000a47c: e5835034 str r5, [r3, #52] ; 0x34
if ((aio_request_queue.idle_threads == 0) &&
a000a480: e3520000 cmp r2, #0
a000a484: 1a00002e bne a000a544 <rtems_aio_enqueue+0x134>
a000a488: e5942064 ldr r2, [r4, #100] ; 0x64
a000a48c: e3520004 cmp r2, #4
a000a490: ca00002b bgt a000a544 <rtems_aio_enqueue+0x134>
aio_request_queue.active_threads < AIO_MAX_THREADS)
/* we still have empty places on the active_threads chain */
{
chain = &aio_request_queue.work_req;
r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);
a000a494: e5931000 ldr r1, [r3]
a000a498: e2840048 add r0, r4, #72 ; 0x48
a000a49c: e3a02001 mov r2, #1
a000a4a0: ebfffecd bl a0009fdc <rtems_aio_search_fd>
if (r_chain->new_fd == 1) {
a000a4a4: e5903018 ldr r3, [r0, #24]
if ((aio_request_queue.idle_threads == 0) &&
aio_request_queue.active_threads < AIO_MAX_THREADS)
/* we still have empty places on the active_threads chain */
{
chain = &aio_request_queue.work_req;
r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);
a000a4a8: e1a07000 mov r7, r0
a000a4ac: e2809008 add r9, r0, #8
if (r_chain->new_fd == 1) {
a000a4b0: e3530001 cmp r3, #1
a000a4b4: e280801c add r8, r0, #28
a000a4b8: e280a020 add sl, r0, #32
a000a4bc: 1a000017 bne a000a520 <rtems_aio_enqueue+0x110>
RTEMS_INLINE_ROUTINE void _Chain_Prepend(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
_Chain_Insert(_Chain_Head(the_chain), the_node);
a000a4c0: e1a01006 mov r1, r6
a000a4c4: e1a00009 mov r0, r9
a000a4c8: eb00085f bl a000c64c <_Chain_Insert>
rtems_chain_prepend (&r_chain->perfd, &req->next_prio);
r_chain->new_fd = 0;
pthread_mutex_init (&r_chain->mutex, NULL);
a000a4cc: e1a01005 mov r1, r5
chain = &aio_request_queue.work_req;
r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);
if (r_chain->new_fd == 1) {
rtems_chain_prepend (&r_chain->perfd, &req->next_prio);
r_chain->new_fd = 0;
a000a4d0: e5875018 str r5, [r7, #24]
pthread_mutex_init (&r_chain->mutex, NULL);
a000a4d4: e1a00008 mov r0, r8
a000a4d8: eb0001d6 bl a000ac38 <pthread_mutex_init>
pthread_cond_init (&r_chain->cond, NULL);
a000a4dc: e1a01005 mov r1, r5
a000a4e0: e1a0000a mov r0, sl
a000a4e4: eb0000e6 bl a000a884 <pthread_cond_init>
AIO_printf ("New thread \n");
result = pthread_create (&thid, &aio_request_queue.attr,
a000a4e8: e1a03007 mov r3, r7
a000a4ec: e28d0020 add r0, sp, #32
a000a4f0: e2841008 add r1, r4, #8
a000a4f4: e59f2114 ldr r2, [pc, #276] ; a000a610 <rtems_aio_enqueue+0x200>
a000a4f8: eb0002a2 bl a000af88 <pthread_create>
rtems_aio_handle, (void *) r_chain);
if (result != 0) {
a000a4fc: e2506000 subs r6, r0, #0
pthread_mutex_unlock (&aio_request_queue.mutex);
return result;
}
++aio_request_queue.active_threads;
a000a500: 05943064 ldreq r3, [r4, #100] ; 0x64
a000a504: 02833001 addeq r3, r3, #1
a000a508: 05843064 streq r3, [r4, #100] ; 0x64
pthread_cond_init (&r_chain->cond, NULL);
AIO_printf ("New thread \n");
result = pthread_create (&thid, &aio_request_queue.attr,
rtems_aio_handle, (void *) r_chain);
if (result != 0) {
a000a50c: 0a000039 beq a000a5f8 <rtems_aio_enqueue+0x1e8>
pthread_mutex_unlock (&aio_request_queue.mutex);
a000a510: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a514: eb000239 bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
return result;
a000a518: e1a05006 mov r5, r6 <== NOT EXECUTED
a000a51c: ea000037 b a000a600 <rtems_aio_enqueue+0x1f0> <== NOT EXECUTED
}
++aio_request_queue.active_threads;
}
else {
/* put request in the fd chain it belongs to */
pthread_mutex_lock (&r_chain->mutex);
a000a520: e1a00008 mov r0, r8 <== NOT EXECUTED
a000a524: eb000216 bl a000ad84 <pthread_mutex_lock> <== NOT EXECUTED
rtems_aio_insert_prio (&r_chain->perfd, req);
a000a528: e1a00009 mov r0, r9 <== NOT EXECUTED
a000a52c: e1a01006 mov r1, r6 <== NOT EXECUTED
a000a530: ebffff75 bl a000a30c <rtems_aio_insert_prio> <== NOT EXECUTED
pthread_cond_signal (&r_chain->cond);
a000a534: e1a0000a mov r0, sl <== NOT EXECUTED
a000a538: eb000102 bl a000a948 <pthread_cond_signal> <== NOT EXECUTED
pthread_mutex_unlock (&r_chain->mutex);
a000a53c: e1a00008 mov r0, r8 <== NOT EXECUTED
a000a540: ea00000e b a000a580 <rtems_aio_enqueue+0x170> <== NOT EXECUTED
else
{
/* the maximum number of threads has been already created
even though some of them might be idle.
The request belongs to one of the active fd chain */
r_chain = rtems_aio_search_fd (&aio_request_queue.work_req,
a000a544: e59f00c8 ldr r0, [pc, #200] ; a000a614 <rtems_aio_enqueue+0x204><== NOT EXECUTED
a000a548: e5931000 ldr r1, [r3] <== NOT EXECUTED
a000a54c: e3a02000 mov r2, #0 <== NOT EXECUTED
a000a550: ebfffea1 bl a0009fdc <rtems_aio_search_fd> <== NOT EXECUTED
req->aiocbp->aio_fildes, 0);
if (r_chain != NULL)
a000a554: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a000a558: 0a00000a beq a000a588 <rtems_aio_enqueue+0x178> <== NOT EXECUTED
{
pthread_mutex_lock (&r_chain->mutex);
a000a55c: e284701c add r7, r4, #28 <== NOT EXECUTED
a000a560: e1a00007 mov r0, r7 <== NOT EXECUTED
a000a564: eb000206 bl a000ad84 <pthread_mutex_lock> <== NOT EXECUTED
rtems_aio_insert_prio (&r_chain->perfd, req);
a000a568: e2840008 add r0, r4, #8 <== NOT EXECUTED
a000a56c: e1a01006 mov r1, r6 <== NOT EXECUTED
a000a570: ebffff65 bl a000a30c <rtems_aio_insert_prio> <== NOT EXECUTED
pthread_cond_signal (&r_chain->cond);
a000a574: e2840020 add r0, r4, #32 <== NOT EXECUTED
a000a578: eb0000f2 bl a000a948 <pthread_cond_signal> <== NOT EXECUTED
pthread_mutex_unlock (&r_chain->mutex);
a000a57c: e1a00007 mov r0, r7 <== NOT EXECUTED
a000a580: eb00021e bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
a000a584: ea00001b b a000a5f8 <rtems_aio_enqueue+0x1e8> <== NOT EXECUTED
} else {
/* or to the idle chain */
chain = &aio_request_queue.idle_req;
r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);
a000a588: e5963014 ldr r3, [r6, #20] <== NOT EXECUTED
a000a58c: e59f0084 ldr r0, [pc, #132] ; a000a618 <rtems_aio_enqueue+0x208><== NOT EXECUTED
a000a590: e3a02001 mov r2, #1 <== NOT EXECUTED
a000a594: e5931000 ldr r1, [r3] <== NOT EXECUTED
a000a598: ebfffe8f bl a0009fdc <rtems_aio_search_fd> <== NOT EXECUTED
if (r_chain->new_fd == 1) {
a000a59c: e5903018 ldr r3, [r0, #24] <== NOT EXECUTED
} else {
/* or to the idle chain */
chain = &aio_request_queue.idle_req;
r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);
a000a5a0: e1a07000 mov r7, r0 <== NOT EXECUTED
a000a5a4: e2800008 add r0, r0, #8 <== NOT EXECUTED
if (r_chain->new_fd == 1) {
a000a5a8: e3530001 cmp r3, #1 <== NOT EXECUTED
a000a5ac: 1a000009 bne a000a5d8 <rtems_aio_enqueue+0x1c8> <== NOT EXECUTED
a000a5b0: e1a01006 mov r1, r6 <== NOT EXECUTED
a000a5b4: eb000824 bl a000c64c <_Chain_Insert> <== NOT EXECUTED
/* If this is a new fd chain we signal the idle threads that
might be waiting for requests */
AIO_printf (" New chain on waiting queue \n ");
rtems_chain_prepend (&r_chain->perfd, &req->next_prio);
r_chain->new_fd = 0;
pthread_mutex_init (&r_chain->mutex, NULL);
a000a5b8: e1a01004 mov r1, r4 <== NOT EXECUTED
if (r_chain->new_fd == 1) {
/* If this is a new fd chain we signal the idle threads that
might be waiting for requests */
AIO_printf (" New chain on waiting queue \n ");
rtems_chain_prepend (&r_chain->perfd, &req->next_prio);
r_chain->new_fd = 0;
a000a5bc: e5874018 str r4, [r7, #24] <== NOT EXECUTED
pthread_mutex_init (&r_chain->mutex, NULL);
a000a5c0: e287001c add r0, r7, #28 <== NOT EXECUTED
a000a5c4: eb00019b bl a000ac38 <pthread_mutex_init> <== NOT EXECUTED
pthread_cond_init (&r_chain->cond, NULL);
a000a5c8: e2870020 add r0, r7, #32 <== NOT EXECUTED
a000a5cc: e1a01004 mov r1, r4 <== NOT EXECUTED
a000a5d0: eb0000ab bl a000a884 <pthread_cond_init> <== NOT EXECUTED
a000a5d4: ea000001 b a000a5e0 <rtems_aio_enqueue+0x1d0> <== NOT EXECUTED
} else
/* just insert the request in the existing fd chain */
rtems_aio_insert_prio (&r_chain->perfd, req);
a000a5d8: e1a01006 mov r1, r6 <== NOT EXECUTED
a000a5dc: ebffff4a bl a000a30c <rtems_aio_insert_prio> <== NOT EXECUTED
if (aio_request_queue.idle_threads > 0)
a000a5e0: e59f0024 ldr r0, [pc, #36] ; a000a60c <rtems_aio_enqueue+0x1fc><== NOT EXECUTED
a000a5e4: e5903068 ldr r3, [r0, #104] ; 0x68 <== NOT EXECUTED
a000a5e8: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a5ec: da000001 ble a000a5f8 <rtems_aio_enqueue+0x1e8> <== NOT EXECUTED
pthread_cond_signal (&aio_request_queue.new_req);
a000a5f0: e2800004 add r0, r0, #4 <== NOT EXECUTED
a000a5f4: eb0000d3 bl a000a948 <pthread_cond_signal> <== NOT EXECUTED
}
}
pthread_mutex_unlock (&aio_request_queue.mutex);
a000a5f8: e59f000c ldr r0, [pc, #12] ; a000a60c <rtems_aio_enqueue+0x1fc>
a000a5fc: eb0001ff bl a000ae00 <pthread_mutex_unlock>
return 0;
}
a000a600: e1a00005 mov r0, r5
a000a604: e28dd024 add sp, sp, #36 ; 0x24
a000a608: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc}
a000a0c0 <rtems_aio_handle>:
* NULL - if error
*/
static void *
rtems_aio_handle (void *arg)
{
a000a0c0: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} <== NOT EXECUTED
struct timespec timeout;
AIO_printf ("Chain is empty [WQ], wait for work\n");
pthread_mutex_unlock (&r_chain->mutex);
pthread_mutex_lock (&aio_request_queue.mutex);
a000a0c4: e59f4238 ldr r4, [pc, #568] ; a000a304 <rtems_aio_handle+0x244><== NOT EXECUTED
* NULL - if error
*/
static void *
rtems_aio_handle (void *arg)
{
a000a0c8: e24dd02c sub sp, sp, #44 ; 0x2c <== NOT EXECUTED
a000a0cc: e1a05000 mov r5, r0 <== NOT EXECUTED
pthread_mutex_unlock (&r_chain->mutex);
pthread_mutex_lock (&aio_request_queue.mutex);
if (rtems_chain_is_empty (chain))
{
clock_gettime (CLOCK_REALTIME, &timeout);
a000a0d0: e28d7020 add r7, sp, #32 <== NOT EXECUTED
node = rtems_chain_first (chain);
req = (rtems_aio_request *) node;
/* See _POSIX_PRIORITIZE_IO and _POSIX_PRIORITY_SCHEDULING
discussion in rtems_aio_enqueue () */
pthread_getschedparam (pthread_self(), &policy, ¶m);
a000a0d4: e28db004 add fp, sp, #4 <== NOT EXECUTED
/* acquire the mutex of the current fd chain.
we don't need to lock the queue mutex since we can
add requests to idle fd chains or even active ones
if the working request has been extracted from the
chain */
result = pthread_mutex_lock (&r_chain->mutex);
a000a0d8: e285a01c add sl, r5, #28 <== NOT EXECUTED
a000a0dc: e1a0000a mov r0, sl <== NOT EXECUTED
a000a0e0: eb000327 bl a000ad84 <pthread_mutex_lock> <== NOT EXECUTED
if (result != 0)
a000a0e4: e2509000 subs r9, r0, #0 <== NOT EXECUTED
a000a0e8: 1a000082 bne a000a2f8 <rtems_aio_handle+0x238> <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a0ec: e5956008 ldr r6, [r5, #8] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
const Chain_Control *the_chain
)
{
return _Chain_Immutable_first( the_chain )
== _Chain_Immutable_tail( the_chain );
a000a0f0: e285300c add r3, r5, #12 <== NOT EXECUTED
/* If the locked chain is not empty, take the first
request extract it, unlock the chain and process
the request, in this way the user can supply more
requests to this fd chain */
if (!rtems_chain_is_empty (chain)) {
a000a0f4: e1560003 cmp r6, r3 <== NOT EXECUTED
a000a0f8: 0a000035 beq a000a1d4 <rtems_aio_handle+0x114> <== NOT EXECUTED
node = rtems_chain_first (chain);
req = (rtems_aio_request *) node;
/* See _POSIX_PRIORITIZE_IO and _POSIX_PRIORITY_SCHEDULING
discussion in rtems_aio_enqueue () */
pthread_getschedparam (pthread_self(), &policy, ¶m);
a000a0fc: eb000531 bl a000b5c8 <pthread_self> <== NOT EXECUTED
a000a100: e28d1028 add r1, sp, #40 ; 0x28 <== NOT EXECUTED
a000a104: e1a0200b mov r2, fp <== NOT EXECUTED
a000a108: eb000433 bl a000b1dc <pthread_getschedparam> <== NOT EXECUTED
param.sched_priority = req->priority;
a000a10c: e596300c ldr r3, [r6, #12] <== NOT EXECUTED
a000a110: e58d3004 str r3, [sp, #4] <== NOT EXECUTED
pthread_setschedparam (pthread_self(), req->policy, ¶m);
a000a114: eb00052b bl a000b5c8 <pthread_self> <== NOT EXECUTED
a000a118: e1a0200b mov r2, fp <== NOT EXECUTED
a000a11c: e5961008 ldr r1, [r6, #8] <== NOT EXECUTED
a000a120: eb00052d bl a000b5dc <pthread_setschedparam> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
a000a124: e1a00006 mov r0, r6 <== NOT EXECUTED
a000a128: eb000932 bl a000c5f8 <_Chain_Extract> <== NOT EXECUTED
rtems_chain_extract (node);
pthread_mutex_unlock (&r_chain->mutex);
a000a12c: e1a0000a mov r0, sl <== NOT EXECUTED
a000a130: eb000332 bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
switch (req->aiocbp->aio_lio_opcode) {
a000a134: e5962014 ldr r2, [r6, #20] <== NOT EXECUTED
a000a138: e592302c ldr r3, [r2, #44] ; 0x2c <== NOT EXECUTED
a000a13c: e3530002 cmp r3, #2 <== NOT EXECUTED
a000a140: 0a00000b beq a000a174 <rtems_aio_handle+0xb4> <== NOT EXECUTED
a000a144: e3530003 cmp r3, #3 <== NOT EXECUTED
a000a148: 0a000011 beq a000a194 <rtems_aio_handle+0xd4> <== NOT EXECUTED
a000a14c: e3530001 cmp r3, #1 <== NOT EXECUTED
a000a150: 1a000013 bne a000a1a4 <rtems_aio_handle+0xe4> <== NOT EXECUTED
case LIO_READ:
AIO_printf ("read\n");
result = pread (req->aiocbp->aio_fildes,
a000a154: e5921008 ldr r1, [r2, #8] <== NOT EXECUTED
a000a158: e5923004 ldr r3, [r2, #4] <== NOT EXECUTED
a000a15c: e58d1000 str r1, [sp] <== NOT EXECUTED
a000a160: e592100c ldr r1, [r2, #12] <== NOT EXECUTED
a000a164: e5920000 ldr r0, [r2] <== NOT EXECUTED
a000a168: e5922010 ldr r2, [r2, #16] <== NOT EXECUTED
a000a16c: eb002942 bl a001467c <pread> <== NOT EXECUTED
(void *) req->aiocbp->aio_buf,
req->aiocbp->aio_nbytes, req->aiocbp->aio_offset);
break;
a000a170: ea000009 b a000a19c <rtems_aio_handle+0xdc> <== NOT EXECUTED
case LIO_WRITE:
AIO_printf ("write\n");
result = pwrite (req->aiocbp->aio_fildes,
a000a174: e5921008 ldr r1, [r2, #8] <== NOT EXECUTED
a000a178: e5923004 ldr r3, [r2, #4] <== NOT EXECUTED
a000a17c: e58d1000 str r1, [sp] <== NOT EXECUTED
a000a180: e592100c ldr r1, [r2, #12] <== NOT EXECUTED
a000a184: e5920000 ldr r0, [r2] <== NOT EXECUTED
a000a188: e5922010 ldr r2, [r2, #16] <== NOT EXECUTED
a000a18c: eb002984 bl a00147a4 <pwrite> <== NOT EXECUTED
(void *) req->aiocbp->aio_buf,
req->aiocbp->aio_nbytes, req->aiocbp->aio_offset);
break;
a000a190: ea000001 b a000a19c <rtems_aio_handle+0xdc> <== NOT EXECUTED
case LIO_SYNC:
AIO_printf ("sync\n");
result = fsync (req->aiocbp->aio_fildes);
a000a194: e5920000 ldr r0, [r2] <== NOT EXECUTED
a000a198: eb00197e bl a0010798 <fsync> <== NOT EXECUTED
break;
default:
result = -1;
}
if (result == -1) {
a000a19c: e3700001 cmn r0, #1 <== NOT EXECUTED
a000a1a0: 1a000006 bne a000a1c0 <rtems_aio_handle+0x100> <== NOT EXECUTED
req->aiocbp->return_value = -1;
a000a1a4: e5966014 ldr r6, [r6, #20] <== NOT EXECUTED
a000a1a8: e3e02000 mvn r2, #0 <== NOT EXECUTED
a000a1ac: e5862034 str r2, [r6, #52] ; 0x34 <== NOT EXECUTED
req->aiocbp->error_code = errno;
a000a1b0: eb00262d bl a0013a6c <__errno> <== NOT EXECUTED
a000a1b4: e5903000 ldr r3, [r0] <== NOT EXECUTED
a000a1b8: e5863030 str r3, [r6, #48] ; 0x30 <== NOT EXECUTED
a000a1bc: eaffffc5 b a000a0d8 <rtems_aio_handle+0x18> <== NOT EXECUTED
} else {
req->aiocbp->return_value = result;
a000a1c0: e5963014 ldr r3, [r6, #20] <== NOT EXECUTED
req->aiocbp->error_code = 0;
a000a1c4: e3a02000 mov r2, #0 <== NOT EXECUTED
}
if (result == -1) {
req->aiocbp->return_value = -1;
req->aiocbp->error_code = errno;
} else {
req->aiocbp->return_value = result;
a000a1c8: e5830034 str r0, [r3, #52] ; 0x34 <== NOT EXECUTED
req->aiocbp->error_code = 0;
a000a1cc: e5832030 str r2, [r3, #48] ; 0x30 <== NOT EXECUTED
a000a1d0: eaffffc0 b a000a0d8 <rtems_aio_handle+0x18> <== NOT EXECUTED
struct timespec timeout;
AIO_printf ("Chain is empty [WQ], wait for work\n");
pthread_mutex_unlock (&r_chain->mutex);
pthread_mutex_lock (&aio_request_queue.mutex);
a000a1d4: e59f8128 ldr r8, [pc, #296] ; a000a304 <rtems_aio_handle+0x244><== NOT EXECUTED
struct timespec timeout;
AIO_printf ("Chain is empty [WQ], wait for work\n");
pthread_mutex_unlock (&r_chain->mutex);
a000a1d8: e1a0000a mov r0, sl <== NOT EXECUTED
a000a1dc: eb000307 bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
pthread_mutex_lock (&aio_request_queue.mutex);
a000a1e0: e1a00008 mov r0, r8 <== NOT EXECUTED
a000a1e4: eb0002e6 bl a000ad84 <pthread_mutex_lock> <== NOT EXECUTED
if (rtems_chain_is_empty (chain))
a000a1e8: e5953008 ldr r3, [r5, #8] <== NOT EXECUTED
a000a1ec: e1530006 cmp r3, r6 <== NOT EXECUTED
a000a1f0: 1a00003d bne a000a2ec <rtems_aio_handle+0x22c> <== NOT EXECUTED
{
clock_gettime (CLOCK_REALTIME, &timeout);
a000a1f4: e1a01007 mov r1, r7 <== NOT EXECUTED
a000a1f8: e3a00001 mov r0, #1 <== NOT EXECUTED
a000a1fc: eb000150 bl a000a744 <clock_gettime> <== NOT EXECUTED
timeout.tv_sec += 3;
a000a200: e59d3020 ldr r3, [sp, #32] <== NOT EXECUTED
timeout.tv_nsec = 0;
result = pthread_cond_timedwait (&r_chain->cond,
a000a204: e2856020 add r6, r5, #32 <== NOT EXECUTED
a000a208: e1a00006 mov r0, r6 <== NOT EXECUTED
pthread_mutex_lock (&aio_request_queue.mutex);
if (rtems_chain_is_empty (chain))
{
clock_gettime (CLOCK_REALTIME, &timeout);
timeout.tv_sec += 3;
a000a20c: e2833003 add r3, r3, #3 <== NOT EXECUTED
timeout.tv_nsec = 0;
result = pthread_cond_timedwait (&r_chain->cond,
a000a210: e1a01008 mov r1, r8 <== NOT EXECUTED
a000a214: e1a02007 mov r2, r7 <== NOT EXECUTED
pthread_mutex_lock (&aio_request_queue.mutex);
if (rtems_chain_is_empty (chain))
{
clock_gettime (CLOCK_REALTIME, &timeout);
timeout.tv_sec += 3;
a000a218: e58d3020 str r3, [sp, #32] <== NOT EXECUTED
timeout.tv_nsec = 0;
a000a21c: e58d9024 str r9, [sp, #36] ; 0x24 <== NOT EXECUTED
result = pthread_cond_timedwait (&r_chain->cond,
a000a220: eb0001df bl a000a9a4 <pthread_cond_timedwait> <== NOT EXECUTED
&aio_request_queue.mutex,
&timeout);
/* If no requests were added to the chain we delete the fd chain from
the queue and start working with idle fd chains */
if (result == ETIMEDOUT) {
a000a224: e3500074 cmp r0, #116 ; 0x74 <== NOT EXECUTED
a000a228: 1a00002f bne a000a2ec <rtems_aio_handle+0x22c> <== NOT EXECUTED
a000a22c: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a230: eb0008f0 bl a000c5f8 <_Chain_Extract> <== NOT EXECUTED
rtems_chain_extract (&r_chain->next_fd);
pthread_mutex_destroy (&r_chain->mutex);
a000a234: e1a0000a mov r0, sl <== NOT EXECUTED
a000a238: eb00022e bl a000aaf8 <pthread_mutex_destroy> <== NOT EXECUTED
pthread_cond_destroy (&r_chain->cond);
a000a23c: e1a00006 mov r0, r6 <== NOT EXECUTED
a000a240: eb00015d bl a000a7bc <pthread_cond_destroy> <== NOT EXECUTED
free (r_chain);
a000a244: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a248: ebfff2e3 bl a0006ddc <free> <== NOT EXECUTED
/* If the idle chain is empty sleep for 3 seconds and wait for a
signal. The thread now becomes idle. */
if (rtems_chain_is_empty (&aio_request_queue.idle_req)) {
a000a24c: e5943054 ldr r3, [r4, #84] ; 0x54 <== NOT EXECUTED
a000a250: e59f20b0 ldr r2, [pc, #176] ; a000a308 <rtems_aio_handle+0x248><== NOT EXECUTED
a000a254: e1530002 cmp r3, r2 <== NOT EXECUTED
a000a258: 1a000018 bne a000a2c0 <rtems_aio_handle+0x200> <== NOT EXECUTED
AIO_printf ("Chain is empty [IQ], wait for work\n");
++aio_request_queue.idle_threads;
a000a25c: e5943068 ldr r3, [r4, #104] ; 0x68 <== NOT EXECUTED
--aio_request_queue.active_threads;
clock_gettime (CLOCK_REALTIME, &timeout);
a000a260: e1a01007 mov r1, r7 <== NOT EXECUTED
a000a264: e3a00001 mov r0, #1 <== NOT EXECUTED
/* If the idle chain is empty sleep for 3 seconds and wait for a
signal. The thread now becomes idle. */
if (rtems_chain_is_empty (&aio_request_queue.idle_req)) {
AIO_printf ("Chain is empty [IQ], wait for work\n");
++aio_request_queue.idle_threads;
a000a268: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000a26c: e5843068 str r3, [r4, #104] ; 0x68 <== NOT EXECUTED
--aio_request_queue.active_threads;
a000a270: e5943064 ldr r3, [r4, #100] ; 0x64 <== NOT EXECUTED
a000a274: e2433001 sub r3, r3, #1 <== NOT EXECUTED
a000a278: e5843064 str r3, [r4, #100] ; 0x64 <== NOT EXECUTED
clock_gettime (CLOCK_REALTIME, &timeout);
a000a27c: eb000130 bl a000a744 <clock_gettime> <== NOT EXECUTED
timeout.tv_sec += 3;
a000a280: e59d3020 ldr r3, [sp, #32] <== NOT EXECUTED
timeout.tv_nsec = 0;
result = pthread_cond_timedwait (&aio_request_queue.new_req,
a000a284: e2880004 add r0, r8, #4 <== NOT EXECUTED
a000a288: e1a01008 mov r1, r8 <== NOT EXECUTED
AIO_printf ("Chain is empty [IQ], wait for work\n");
++aio_request_queue.idle_threads;
--aio_request_queue.active_threads;
clock_gettime (CLOCK_REALTIME, &timeout);
timeout.tv_sec += 3;
a000a28c: e2833003 add r3, r3, #3 <== NOT EXECUTED
timeout.tv_nsec = 0;
result = pthread_cond_timedwait (&aio_request_queue.new_req,
a000a290: e1a02007 mov r2, r7 <== NOT EXECUTED
AIO_printf ("Chain is empty [IQ], wait for work\n");
++aio_request_queue.idle_threads;
--aio_request_queue.active_threads;
clock_gettime (CLOCK_REALTIME, &timeout);
timeout.tv_sec += 3;
a000a294: e58d3020 str r3, [sp, #32] <== NOT EXECUTED
timeout.tv_nsec = 0;
a000a298: e58d9024 str r9, [sp, #36] ; 0x24 <== NOT EXECUTED
result = pthread_cond_timedwait (&aio_request_queue.new_req,
a000a29c: eb0001c0 bl a000a9a4 <pthread_cond_timedwait> <== NOT EXECUTED
&aio_request_queue.mutex,
&timeout);
/* If no new fd chain was added in the idle requests
then this thread is finished */
if (result == ETIMEDOUT) {
a000a2a0: e3500074 cmp r0, #116 ; 0x74 <== NOT EXECUTED
a000a2a4: 1a000005 bne a000a2c0 <rtems_aio_handle+0x200> <== NOT EXECUTED
AIO_printf ("Etimeout\n");
--aio_request_queue.idle_threads;
a000a2a8: e5983068 ldr r3, [r8, #104] ; 0x68 <== NOT EXECUTED
pthread_mutex_unlock (&aio_request_queue.mutex);
a000a2ac: e1a00008 mov r0, r8 <== NOT EXECUTED
/* If no new fd chain was added in the idle requests
then this thread is finished */
if (result == ETIMEDOUT) {
AIO_printf ("Etimeout\n");
--aio_request_queue.idle_threads;
a000a2b0: e2433001 sub r3, r3, #1 <== NOT EXECUTED
a000a2b4: e5883068 str r3, [r8, #104] ; 0x68 <== NOT EXECUTED
pthread_mutex_unlock (&aio_request_queue.mutex);
a000a2b8: eb0002d0 bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
return NULL;
a000a2bc: ea00000d b a000a2f8 <rtems_aio_handle+0x238> <== NOT EXECUTED
}
}
/* Otherwise move this chain to the working chain and
start the loop all over again */
AIO_printf ("Work on idle\n");
--aio_request_queue.idle_threads;
a000a2c0: e5943068 ldr r3, [r4, #104] ; 0x68 <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a2c4: e5945054 ldr r5, [r4, #84] ; 0x54 <== NOT EXECUTED
}
}
/* Otherwise move this chain to the working chain and
start the loop all over again */
AIO_printf ("Work on idle\n");
--aio_request_queue.idle_threads;
a000a2c8: e2433001 sub r3, r3, #1 <== NOT EXECUTED
a000a2cc: e5843068 str r3, [r4, #104] ; 0x68 <== NOT EXECUTED
++aio_request_queue.active_threads;
a000a2d0: e5943064 ldr r3, [r4, #100] ; 0x64 <== NOT EXECUTED
a000a2d4: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a2d8: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000a2dc: e5843064 str r3, [r4, #100] ; 0x64 <== NOT EXECUTED
a000a2e0: eb0008c4 bl a000c5f8 <_Chain_Extract> <== NOT EXECUTED
node = rtems_chain_first (&aio_request_queue.idle_req);
rtems_chain_extract (node);
r_chain = (rtems_aio_request_chain *) node;
rtems_aio_move_to_work (r_chain);
a000a2e4: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a2e8: ebffff65 bl a000a084 <rtems_aio_move_to_work> <== NOT EXECUTED
}
}
/* If there was a request added in the initial fd chain then release
the mutex and process it */
pthread_mutex_unlock (&aio_request_queue.mutex);
a000a2ec: e59f0010 ldr r0, [pc, #16] ; a000a304 <rtems_aio_handle+0x244><== NOT EXECUTED
a000a2f0: eb0002c2 bl a000ae00 <pthread_mutex_unlock> <== NOT EXECUTED
a000a2f4: eaffff77 b a000a0d8 <rtems_aio_handle+0x18> <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a2f8: e3a00000 mov r0, #0 <== NOT EXECUTED
a000a2fc: e28dd02c add sp, sp, #44 ; 0x2c <== NOT EXECUTED
a000a300: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
a0009f14 <rtems_aio_init>:
* 0 - if initialization succeeded
*/
int
rtems_aio_init (void)
{
a0009f14: e92d4010 push {r4, lr}
int result = 0;
result = pthread_attr_init (&aio_request_queue.attr);
a0009f18: e59f00ac ldr r0, [pc, #172] ; a0009fcc <rtems_aio_init+0xb8>
a0009f1c: eb0003f9 bl a000af08 <pthread_attr_init>
if (result != 0)
a0009f20: e2504000 subs r4, r0, #0
a0009f24: 1a000026 bne a0009fc4 <rtems_aio_init+0xb0>
return result;
result =
a0009f28: e59f009c ldr r0, [pc, #156] ; a0009fcc <rtems_aio_init+0xb8>
a0009f2c: e1a01004 mov r1, r4
a0009f30: eb000406 bl a000af50 <pthread_attr_setdetachstate>
pthread_attr_setdetachstate (&aio_request_queue.attr,
PTHREAD_CREATE_DETACHED);
if (result != 0)
a0009f34: e3500000 cmp r0, #0
a0009f38: 0a000001 beq a0009f44 <rtems_aio_init+0x30>
pthread_attr_destroy (&aio_request_queue.attr);
a0009f3c: e59f0088 ldr r0, [pc, #136] ; a0009fcc <rtems_aio_init+0xb8><== NOT EXECUTED
a0009f40: eb0003e7 bl a000aee4 <pthread_attr_destroy> <== NOT EXECUTED
result = pthread_mutex_init (&aio_request_queue.mutex, NULL);
a0009f44: e59f0084 ldr r0, [pc, #132] ; a0009fd0 <rtems_aio_init+0xbc>
a0009f48: e3a01000 mov r1, #0
a0009f4c: eb000339 bl a000ac38 <pthread_mutex_init>
if (result != 0)
a0009f50: e3500000 cmp r0, #0
a0009f54: 0a000001 beq a0009f60 <rtems_aio_init+0x4c>
pthread_attr_destroy (&aio_request_queue.attr);
a0009f58: e59f006c ldr r0, [pc, #108] ; a0009fcc <rtems_aio_init+0xb8><== NOT EXECUTED
a0009f5c: eb0003e0 bl a000aee4 <pthread_attr_destroy> <== NOT EXECUTED
result = pthread_cond_init (&aio_request_queue.new_req, NULL);
a0009f60: e59f006c ldr r0, [pc, #108] ; a0009fd4 <rtems_aio_init+0xc0>
a0009f64: e3a01000 mov r1, #0
a0009f68: eb000245 bl a000a884 <pthread_cond_init>
if (result != 0) {
a0009f6c: e2504000 subs r4, r0, #0
a0009f70: 0a000003 beq a0009f84 <rtems_aio_init+0x70>
pthread_mutex_destroy (&aio_request_queue.mutex);
a0009f74: e59f0054 ldr r0, [pc, #84] ; a0009fd0 <rtems_aio_init+0xbc><== NOT EXECUTED
a0009f78: eb0002de bl a000aaf8 <pthread_mutex_destroy> <== NOT EXECUTED
pthread_attr_destroy (&aio_request_queue.attr);
a0009f7c: e59f0048 ldr r0, [pc, #72] ; a0009fcc <rtems_aio_init+0xb8><== NOT EXECUTED
a0009f80: eb0003d7 bl a000aee4 <pthread_attr_destroy> <== NOT EXECUTED
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *tail = _Chain_Tail( the_chain );
head->next = tail;
a0009f84: e59f3044 ldr r3, [pc, #68] ; a0009fd0 <rtems_aio_init+0xbc>
a0009f88: e283204c add r2, r3, #76 ; 0x4c
a0009f8c: e5832048 str r2, [r3, #72] ; 0x48
head->previous = NULL;
a0009f90: e3a02000 mov r2, #0
tail->previous = head;
a0009f94: e2831048 add r1, r3, #72 ; 0x48
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *tail = _Chain_Tail( the_chain );
head->next = tail;
head->previous = NULL;
a0009f98: e583204c str r2, [r3, #76] ; 0x4c
a0009f9c: e5832058 str r2, [r3, #88] ; 0x58
}
rtems_chain_initialize_empty (&aio_request_queue.work_req);
rtems_chain_initialize_empty (&aio_request_queue.idle_req);
aio_request_queue.active_threads = 0;
a0009fa0: e5832064 str r2, [r3, #100] ; 0x64
aio_request_queue.idle_threads = 0;
a0009fa4: e5832068 str r2, [r3, #104] ; 0x68
aio_request_queue.initialized = AIO_QUEUE_INITIALIZED;
a0009fa8: e59f2028 ldr r2, [pc, #40] ; a0009fd8 <rtems_aio_init+0xc4>
tail->previous = head;
a0009fac: e5831050 str r1, [r3, #80] ; 0x50
)
{
Chain_Node *head = _Chain_Head( the_chain );
Chain_Node *tail = _Chain_Tail( the_chain );
head->next = tail;
a0009fb0: e2831058 add r1, r3, #88 ; 0x58
a0009fb4: e5831054 str r1, [r3, #84] ; 0x54
head->previous = NULL;
tail->previous = head;
a0009fb8: e2831054 add r1, r3, #84 ; 0x54
a0009fbc: e583105c str r1, [r3, #92] ; 0x5c
a0009fc0: e5832060 str r2, [r3, #96] ; 0x60
return result;
}
a0009fc4: e1a00004 mov r0, r4
a0009fc8: e8bd8010 pop {r4, pc}
a000a30c <rtems_aio_insert_prio>:
a000a30c: e1a03000 mov r3, r0 <== NOT EXECUTED
a000a310: e4932004 ldr r2, [r3], #4 <== NOT EXECUTED
* NONE
*/
void
rtems_aio_insert_prio (rtems_chain_control *chain, rtems_aio_request *req)
{
a000a314: e1a0c001 mov ip, r1 <== NOT EXECUTED
rtems_chain_node *node;
AIO_printf ("FD exists \n");
node = rtems_chain_first (chain);
if (rtems_chain_is_empty (chain)) {
a000a318: e1520003 cmp r2, r3 <== NOT EXECUTED
a000a31c: 0a00000d beq a000a358 <rtems_aio_insert_prio+0x4c> <== NOT EXECUTED
AIO_printf ("First in chain \n");
rtems_chain_prepend (chain, &req->next_prio);
} else {
AIO_printf ("Add by priority \n");
int prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio;
a000a320: e5921014 ldr r1, [r2, #20] <== NOT EXECUTED
while (req->aiocbp->aio_reqprio > prio &&
a000a324: e59c0014 ldr r0, [ip, #20] <== NOT EXECUTED
if (rtems_chain_is_empty (chain)) {
AIO_printf ("First in chain \n");
rtems_chain_prepend (chain, &req->next_prio);
} else {
AIO_printf ("Add by priority \n");
int prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio;
a000a328: e5911014 ldr r1, [r1, #20] <== NOT EXECUTED
while (req->aiocbp->aio_reqprio > prio &&
a000a32c: e5900014 ldr r0, [r0, #20] <== NOT EXECUTED
a000a330: ea000002 b a000a340 <rtems_aio_insert_prio+0x34> <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a334: e5922000 ldr r2, [r2] <== NOT EXECUTED
int prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio;
while (req->aiocbp->aio_reqprio > prio &&
!rtems_chain_is_tail (chain, node)) {
node = rtems_chain_next (node);
prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio;
a000a338: e5921014 ldr r1, [r2, #20] <== NOT EXECUTED
a000a33c: e5911014 ldr r1, [r1, #20] <== NOT EXECUTED
rtems_chain_prepend (chain, &req->next_prio);
} else {
AIO_printf ("Add by priority \n");
int prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio;
while (req->aiocbp->aio_reqprio > prio &&
a000a340: e1500001 cmp r0, r1 <== NOT EXECUTED
a000a344: da000001 ble a000a350 <rtems_aio_insert_prio+0x44> <== NOT EXECUTED
a000a348: e1520003 cmp r2, r3 <== NOT EXECUTED
a000a34c: 1afffff8 bne a000a334 <rtems_aio_insert_prio+0x28> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void rtems_chain_insert(
rtems_chain_node *after_node,
rtems_chain_node *the_node
)
{
_Chain_Insert( after_node, the_node );
a000a350: e5920004 ldr r0, [r2, #4] <== NOT EXECUTED
a000a354: e1a0100c mov r1, ip <== NOT EXECUTED
a000a358: ea0008bb b a000c64c <_Chain_Insert> <== NOT EXECUTED
a000a084 <rtems_aio_move_to_work>:
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a084: e59f2030 ldr r2, [pc, #48] ; a000a0bc <rtems_aio_move_to_work+0x38><== NOT EXECUTED
* NONE
*/
void
rtems_aio_move_to_work (rtems_aio_request_chain *r_chain)
{
a000a088: e1a01000 mov r1, r0 <== NOT EXECUTED
rtems_chain_node *node;
node = rtems_chain_first (&aio_request_queue.work_req);
temp = (rtems_aio_request_chain *) node;
while (temp->fildes < r_chain->fildes &&
a000a08c: e5900014 ldr r0, [r0, #20] <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a090: e5923048 ldr r3, [r2, #72] ; 0x48 <== NOT EXECUTED
rtems_chain_node *node;
node = rtems_chain_first (&aio_request_queue.work_req);
temp = (rtems_aio_request_chain *) node;
while (temp->fildes < r_chain->fildes &&
a000a094: e282204c add r2, r2, #76 ; 0x4c <== NOT EXECUTED
a000a098: ea000000 b a000a0a0 <rtems_aio_move_to_work+0x1c> <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a09c: e5933000 ldr r3, [r3] <== NOT EXECUTED
rtems_chain_node *node;
node = rtems_chain_first (&aio_request_queue.work_req);
temp = (rtems_aio_request_chain *) node;
while (temp->fildes < r_chain->fildes &&
a000a0a0: e593c014 ldr ip, [r3, #20] <== NOT EXECUTED
a000a0a4: e15c0000 cmp ip, r0 <== NOT EXECUTED
a000a0a8: aa000001 bge a000a0b4 <rtems_aio_move_to_work+0x30> <== NOT EXECUTED
a000a0ac: e1530002 cmp r3, r2 <== NOT EXECUTED
a000a0b0: 1afffff9 bne a000a09c <rtems_aio_move_to_work+0x18> <== NOT EXECUTED
a000a0b4: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED
a000a0b8: ea000963 b a000c64c <_Chain_Insert> <== NOT EXECUTED
a000a35c <rtems_aio_remove_fd>:
* Output parameters:
* NONE
*/
void rtems_aio_remove_fd (rtems_aio_request_chain *r_chain)
{
a000a35c: e92d41f0 push {r4, r5, r6, r7, r8, lr} <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool _Chain_Is_tail(
Chain_Control *the_chain,
const Chain_Node *the_node
)
{
return (the_node == _Chain_Tail(the_chain));
a000a360: e280700c add r7, r0, #12 <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a364: e5904008 ldr r4, [r0, #8] <== NOT EXECUTED
while (!rtems_chain_is_tail (chain, node))
{
rtems_chain_extract (node);
rtems_aio_request *req = (rtems_aio_request *) node;
node = rtems_chain_next (node);
req->aiocbp->error_code = ECANCELED;
a000a368: e3a0608c mov r6, #140 ; 0x8c <== NOT EXECUTED
req->aiocbp->return_value = -1;
a000a36c: e3e05000 mvn r5, #0 <== NOT EXECUTED
rtems_chain_control *chain;
rtems_chain_node *node;
chain = &r_chain->perfd;
node = rtems_chain_first (chain);
while (!rtems_chain_is_tail (chain, node))
a000a370: ea000008 b a000a398 <rtems_aio_remove_fd+0x3c> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
a000a374: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a378: eb00089e bl a000c5f8 <_Chain_Extract> <== NOT EXECUTED
{
rtems_chain_extract (node);
rtems_aio_request *req = (rtems_aio_request *) node;
node = rtems_chain_next (node);
req->aiocbp->error_code = ECANCELED;
a000a37c: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a380: e5948000 ldr r8, [r4] <== NOT EXECUTED
rtems_chain_extract (node);
rtems_aio_request *req = (rtems_aio_request *) node;
node = rtems_chain_next (node);
req->aiocbp->error_code = ECANCELED;
req->aiocbp->return_value = -1;
free (req);
a000a384: e1a00004 mov r0, r4 <== NOT EXECUTED
while (!rtems_chain_is_tail (chain, node))
{
rtems_chain_extract (node);
rtems_aio_request *req = (rtems_aio_request *) node;
node = rtems_chain_next (node);
req->aiocbp->error_code = ECANCELED;
a000a388: e5836030 str r6, [r3, #48] ; 0x30 <== NOT EXECUTED
req->aiocbp->return_value = -1;
a000a38c: e5835034 str r5, [r3, #52] ; 0x34 <== NOT EXECUTED
free (req);
a000a390: ebfff291 bl a0006ddc <free> <== NOT EXECUTED
while (!rtems_chain_is_tail (chain, node))
{
rtems_chain_extract (node);
rtems_aio_request *req = (rtems_aio_request *) node;
node = rtems_chain_next (node);
a000a394: e1a04008 mov r4, r8 <== NOT EXECUTED
rtems_chain_control *chain;
rtems_chain_node *node;
chain = &r_chain->perfd;
node = rtems_chain_first (chain);
while (!rtems_chain_is_tail (chain, node))
a000a398: e1540007 cmp r4, r7 <== NOT EXECUTED
a000a39c: 1afffff4 bne a000a374 <rtems_aio_remove_fd+0x18> <== NOT EXECUTED
node = rtems_chain_next (node);
req->aiocbp->error_code = ECANCELED;
req->aiocbp->return_value = -1;
free (req);
}
}
a000a3a0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
a000a3a4 <rtems_aio_remove_req>:
* AIO_NOTCANCELED - if request was not canceled
* AIO_CANCELED - if request was canceled
*/
int rtems_aio_remove_req (rtems_chain_control *chain, struct aiocb *aiocbp)
{
a000a3a4: e92d4010 push {r4, lr} <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a3a8: e1a03000 mov r3, r0 <== NOT EXECUTED
a000a3ac: e4934004 ldr r4, [r3], #4 <== NOT EXECUTED
* AIO_CANCELED - if request was canceled
*/
int rtems_aio_remove_req (rtems_chain_control *chain, struct aiocb *aiocbp)
{
if (rtems_chain_is_empty (chain))
a000a3b0: e1540003 cmp r4, r3 <== NOT EXECUTED
a000a3b4: 1a000003 bne a000a3c8 <rtems_aio_remove_req+0x24> <== NOT EXECUTED
a000a3b8: ea000010 b a000a400 <rtems_aio_remove_req+0x5c> <== NOT EXECUTED
}
}
AIO_printf ("Thread finished\n");
return NULL;
}
a000a3bc: e5904000 ldr r4, [r0] <== NOT EXECUTED
rtems_chain_node *node = rtems_chain_first (chain);
rtems_aio_request *current;
current = (rtems_aio_request *) node;
while (!rtems_chain_is_tail (chain, node) && current->aiocbp != aiocbp) {
a000a3c0: e1540003 cmp r4, r3 <== NOT EXECUTED
a000a3c4: 0a00000f beq a000a408 <rtems_aio_remove_req+0x64> <== NOT EXECUTED
a000a3c8: e5942014 ldr r2, [r4, #20] <== NOT EXECUTED
node = rtems_chain_next (node);
current = (rtems_aio_request *) node;
a000a3cc: e1a00004 mov r0, r4 <== NOT EXECUTED
rtems_chain_node *node = rtems_chain_first (chain);
rtems_aio_request *current;
current = (rtems_aio_request *) node;
while (!rtems_chain_is_tail (chain, node) && current->aiocbp != aiocbp) {
a000a3d0: e1520001 cmp r2, r1 <== NOT EXECUTED
a000a3d4: 1afffff8 bne a000a3bc <rtems_aio_remove_req+0x18> <== NOT EXECUTED
a000a3d8: eb000886 bl a000c5f8 <_Chain_Extract> <== NOT EXECUTED
if (rtems_chain_is_tail (chain, node))
return AIO_NOTCANCELED;
else
{
rtems_chain_extract (node);
current->aiocbp->error_code = ECANCELED;
a000a3dc: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED
a000a3e0: e3a0208c mov r2, #140 ; 0x8c <== NOT EXECUTED
current->aiocbp->return_value = -1;
free (current);
a000a3e4: e1a00004 mov r0, r4 <== NOT EXECUTED
if (rtems_chain_is_tail (chain, node))
return AIO_NOTCANCELED;
else
{
rtems_chain_extract (node);
current->aiocbp->error_code = ECANCELED;
a000a3e8: e5832030 str r2, [r3, #48] ; 0x30 <== NOT EXECUTED
current->aiocbp->return_value = -1;
a000a3ec: e3e02000 mvn r2, #0 <== NOT EXECUTED
a000a3f0: e5832034 str r2, [r3, #52] ; 0x34 <== NOT EXECUTED
free (current);
a000a3f4: ebfff278 bl a0006ddc <free> <== NOT EXECUTED
}
return AIO_CANCELED;
a000a3f8: e3a00000 mov r0, #0 <== NOT EXECUTED
a000a3fc: e8bd8010 pop {r4, pc} <== NOT EXECUTED
*/
int rtems_aio_remove_req (rtems_chain_control *chain, struct aiocb *aiocbp)
{
if (rtems_chain_is_empty (chain))
return AIO_ALLDONE;
a000a400: e3a00002 mov r0, #2 <== NOT EXECUTED
a000a404: e8bd8010 pop {r4, pc} <== NOT EXECUTED
node = rtems_chain_next (node);
current = (rtems_aio_request *) node;
}
if (rtems_chain_is_tail (chain, node))
return AIO_NOTCANCELED;
a000a408: e3a00001 mov r0, #1 <== NOT EXECUTED
current->aiocbp->return_value = -1;
free (current);
}
return AIO_CANCELED;
}
a000a40c: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000b00c <rtems_build_id>:
uint32_t the_class,
uint32_t node,
uint32_t index
)
{
return (( (Objects_Id) the_api ) << OBJECTS_API_START_BIT) |
a000b00c: e1a00c00 lsl r0, r0, #24 <== NOT EXECUTED
a000b010: e1800d81 orr r0, r0, r1, lsl #27 <== NOT EXECUTED
(( (Objects_Id) the_class ) << OBJECTS_CLASS_START_BIT) |
a000b014: e1800003 orr r0, r0, r3 <== NOT EXECUTED
uint32_t node,
uint32_t index
)
{
return _Objects_Build_id( api, class, node, index );
}
a000b018: e1800802 orr r0, r0, r2, lsl #16 <== NOT EXECUTED
a000b01c: e12fff1e bx lr <== NOT EXECUTED
a000b020 <rtems_build_name>:
char C1,
char C2,
char C3,
char C4
)
{
a000b020: e1a01801 lsl r1, r1, #16 <== NOT EXECUTED
return _Objects_Build_name( C1, C2, C3, C4 );
a000b024: e20118ff and r1, r1, #16711680 ; 0xff0000 <== NOT EXECUTED
char C1,
char C2,
char C3,
char C4
)
{
a000b028: e1a02402 lsl r2, r2, #8 <== NOT EXECUTED
return _Objects_Build_name( C1, C2, C3, C4 );
a000b02c: e1810c00 orr r0, r1, r0, lsl #24 <== NOT EXECUTED
a000b030: e2022cff and r2, r2, #65280 ; 0xff00 <== NOT EXECUTED
char C1,
char C2,
char C3,
char C4
)
{
a000b034: e20330ff and r3, r3, #255 ; 0xff <== NOT EXECUTED
return _Objects_Build_name( C1, C2, C3, C4 );
a000b038: e1800002 orr r0, r0, r2 <== NOT EXECUTED
}
a000b03c: e1800003 orr r0, r0, r3 <== NOT EXECUTED
a000b040: e12fff1e bx lr <== NOT EXECUTED
a000a0b0 <rtems_chain_append_with_notification>:
rtems_chain_control *chain,
rtems_chain_node *node,
rtems_id task,
rtems_event_set events
)
{
a000a0b0: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
a000a0b4: e1a04002 mov r4, r2 <== NOT EXECUTED
a000a0b8: e1a05003 mov r5, r3 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool rtems_chain_append_with_empty_check(
rtems_chain_control *chain,
rtems_chain_node *node
)
{
return _Chain_Append_with_empty_check( chain, node );
a000a0bc: eb00013a bl a000a5ac <_Chain_Append_with_empty_check> <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
bool was_empty = rtems_chain_append_with_empty_check( chain, node );
if ( was_empty ) {
a000a0c0: e3500000 cmp r0, #0 <== NOT EXECUTED
a000a0c4: 0a000003 beq a000a0d8 <rtems_chain_append_with_notification+0x28><== NOT EXECUTED
sc = rtems_event_send( task, events );
a000a0c8: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a0cc: e1a01005 mov r1, r5 <== NOT EXECUTED
}
return sc;
}
a000a0d0: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
bool was_empty = rtems_chain_append_with_empty_check( chain, node );
if ( was_empty ) {
sc = rtems_event_send( task, events );
a000a0d4: eafffda5 b a0009770 <rtems_event_send> <== NOT EXECUTED
}
return sc;
}
a000a0d8: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000a0dc <rtems_chain_get_with_notification>:
rtems_chain_control *chain,
rtems_id task,
rtems_event_set events,
rtems_chain_node **node
)
{
a000a0dc: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
a000a0e0: e1a04001 mov r4, r1 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool rtems_chain_get_with_empty_check(
rtems_chain_control *chain,
rtems_chain_node **node
)
{
return _Chain_Get_with_empty_check( chain, node );
a000a0e4: e1a01003 mov r1, r3 <== NOT EXECUTED
a000a0e8: e1a05002 mov r5, r2 <== NOT EXECUTED
a000a0ec: eb000152 bl a000a63c <_Chain_Get_with_empty_check> <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
bool is_empty = rtems_chain_get_with_empty_check( chain, node );
if ( is_empty ) {
a000a0f0: e3500000 cmp r0, #0 <== NOT EXECUTED
a000a0f4: 0a000003 beq a000a108 <rtems_chain_get_with_notification+0x2c><== NOT EXECUTED
sc = rtems_event_send( task, events );
a000a0f8: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a0fc: e1a01005 mov r1, r5 <== NOT EXECUTED
}
return sc;
}
a000a100: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
bool is_empty = rtems_chain_get_with_empty_check( chain, node );
if ( is_empty ) {
sc = rtems_event_send( task, events );
a000a104: eafffd99 b a0009770 <rtems_event_send> <== NOT EXECUTED
}
return sc;
}
a000a108: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000a10c <rtems_chain_get_with_wait>:
rtems_chain_control *chain,
rtems_event_set events,
rtems_interval timeout,
rtems_chain_node **node_ptr
)
{
a000a10c: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr} <== NOT EXECUTED
a000a110: e1a07000 mov r7, r0 <== NOT EXECUTED
a000a114: e1a06001 mov r6, r1 <== NOT EXECUTED
a000a118: e1a05002 mov r5, r2 <== NOT EXECUTED
a000a11c: e1a0a003 mov sl, r3 <== NOT EXECUTED
while (
sc == RTEMS_SUCCESSFUL
&& (node = rtems_chain_get( chain )) == NULL
) {
rtems_event_set out;
sc = rtems_event_receive(
a000a120: e1a0800d mov r8, sp <== NOT EXECUTED
a000a124: ea000006 b a000a144 <rtems_chain_get_with_wait+0x38> <== NOT EXECUTED
a000a128: e1a00006 mov r0, r6 <== NOT EXECUTED
a000a12c: e1a01004 mov r1, r4 <== NOT EXECUTED
a000a130: e1a02005 mov r2, r5 <== NOT EXECUTED
a000a134: e1a0300d mov r3, sp <== NOT EXECUTED
a000a138: ebfffd30 bl a0009600 <rtems_event_receive> <== NOT EXECUTED
)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_chain_node *node = NULL;
while (
a000a13c: e3500000 cmp r0, #0 <== NOT EXECUTED
a000a140: 1a000004 bne a000a158 <rtems_chain_get_with_wait+0x4c> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
a000a144: e1a00007 mov r0, r7 <== NOT EXECUTED
a000a148: eb00014f bl a000a68c <_Chain_Get> <== NOT EXECUTED
sc == RTEMS_SUCCESSFUL
&& (node = rtems_chain_get( chain )) == NULL
a000a14c: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a000a150: 0afffff4 beq a000a128 <rtems_chain_get_with_wait+0x1c> <== NOT EXECUTED
a000a154: e3a00000 mov r0, #0 <== NOT EXECUTED
timeout,
&out
);
}
*node_ptr = node;
a000a158: e58a4000 str r4, [sl] <== NOT EXECUTED
return sc;
}
a000a15c: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
a000a160 <rtems_chain_prepend_with_notification>:
rtems_chain_control *chain,
rtems_chain_node *node,
rtems_id task,
rtems_event_set events
)
{
a000a160: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
a000a164: e1a04002 mov r4, r2 <== NOT EXECUTED
a000a168: e1a05003 mov r5, r3 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool rtems_chain_prepend_with_empty_check(
rtems_chain_control *chain,
rtems_chain_node *node
)
{
return _Chain_Prepend_with_empty_check( chain, node );
a000a16c: eb00015d bl a000a6e8 <_Chain_Prepend_with_empty_check> <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
bool was_empty = rtems_chain_prepend_with_empty_check( chain, node );
if (was_empty) {
a000a170: e3500000 cmp r0, #0 <== NOT EXECUTED
a000a174: 0a000003 beq a000a188 <rtems_chain_prepend_with_notification+0x28><== NOT EXECUTED
sc = rtems_event_send( task, events );
a000a178: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a17c: e1a01005 mov r1, r5 <== NOT EXECUTED
}
return sc;
}
a000a180: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
bool was_empty = rtems_chain_prepend_with_empty_check( chain, node );
if (was_empty) {
sc = rtems_event_send( task, events );
a000a184: eafffd79 b a0009770 <rtems_event_send> <== NOT EXECUTED
}
return sc;
}
a000a188: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a001525c <rtems_clock_get>:
rtems_status_code rtems_clock_get(
rtems_clock_get_options option,
void *time_buffer
)
{
a001525c: e92d4010 push {r4, lr}
if ( !time_buffer )
a0015260: e2514000 subs r4, r1, #0
a0015264: 0a000018 beq a00152cc <rtems_clock_get+0x70>
return RTEMS_INVALID_ADDRESS;
if ( option == RTEMS_CLOCK_GET_TOD )
a0015268: e3500000 cmp r0, #0
a001526c: 1a000002 bne a001527c <rtems_clock_get+0x20>
return rtems_clock_get_tod( (rtems_time_of_day *)time_buffer );
a0015270: e1a00004 mov r0, r4
if ( option == RTEMS_CLOCK_GET_TIME_VALUE )
return rtems_clock_get_tod_timeval( (struct timeval *)time_buffer );
return RTEMS_INVALID_NUMBER;
}
a0015274: e8bd4010 pop {r4, lr}
{
if ( !time_buffer )
return RTEMS_INVALID_ADDRESS;
if ( option == RTEMS_CLOCK_GET_TOD )
return rtems_clock_get_tod( (rtems_time_of_day *)time_buffer );
a0015278: ea000031 b a0015344 <rtems_clock_get_tod>
if ( option == RTEMS_CLOCK_GET_SECONDS_SINCE_EPOCH )
a001527c: e3500001 cmp r0, #1
a0015280: 1a000002 bne a0015290 <rtems_clock_get+0x34>
return rtems_clock_get_seconds_since_epoch((rtems_interval *)time_buffer);
a0015284: e1a00004 mov r0, r4
if ( option == RTEMS_CLOCK_GET_TIME_VALUE )
return rtems_clock_get_tod_timeval( (struct timeval *)time_buffer );
return RTEMS_INVALID_NUMBER;
}
a0015288: e8bd4010 pop {r4, lr}
if ( option == RTEMS_CLOCK_GET_TOD )
return rtems_clock_get_tod( (rtems_time_of_day *)time_buffer );
if ( option == RTEMS_CLOCK_GET_SECONDS_SINCE_EPOCH )
return rtems_clock_get_seconds_since_epoch((rtems_interval *)time_buffer);
a001528c: ea000012 b a00152dc <rtems_clock_get_seconds_since_epoch>
if ( option == RTEMS_CLOCK_GET_TICKS_SINCE_BOOT ) {
a0015290: e3500002 cmp r0, #2
a0015294: 1a000001 bne a00152a0 <rtems_clock_get+0x44>
rtems_interval *interval = (rtems_interval *)time_buffer;
*interval = rtems_clock_get_ticks_since_boot();
a0015298: eb000025 bl a0015334 <rtems_clock_get_ticks_since_boot>
a001529c: ea000002 b a00152ac <rtems_clock_get+0x50>
return RTEMS_SUCCESSFUL;
}
if ( option == RTEMS_CLOCK_GET_TICKS_PER_SECOND ) {
a00152a0: e3500003 cmp r0, #3
a00152a4: 1a000003 bne a00152b8 <rtems_clock_get+0x5c>
rtems_interval *interval = (rtems_interval *)time_buffer;
*interval = rtems_clock_get_ticks_per_second();
a00152a8: eb000019 bl a0015314 <rtems_clock_get_ticks_per_second>
a00152ac: e5840000 str r0, [r4]
return RTEMS_SUCCESSFUL;
a00152b0: e3a00000 mov r0, #0
a00152b4: e8bd8010 pop {r4, pc}
}
if ( option == RTEMS_CLOCK_GET_TIME_VALUE )
a00152b8: e3500004 cmp r0, #4 <== NOT EXECUTED
a00152bc: 1a000004 bne a00152d4 <rtems_clock_get+0x78> <== NOT EXECUTED
return rtems_clock_get_tod_timeval( (struct timeval *)time_buffer );
a00152c0: e1a00004 mov r0, r4 <== NOT EXECUTED
return RTEMS_INVALID_NUMBER;
}
a00152c4: e8bd4010 pop {r4, lr} <== NOT EXECUTED
*interval = rtems_clock_get_ticks_per_second();
return RTEMS_SUCCESSFUL;
}
if ( option == RTEMS_CLOCK_GET_TIME_VALUE )
return rtems_clock_get_tod_timeval( (struct timeval *)time_buffer );
a00152c8: ea00004f b a001540c <rtems_clock_get_tod_timeval> <== NOT EXECUTED
rtems_clock_get_options option,
void *time_buffer
)
{
if ( !time_buffer )
return RTEMS_INVALID_ADDRESS;
a00152cc: e3a00009 mov r0, #9 <== NOT EXECUTED
a00152d0: e8bd8010 pop {r4, pc} <== NOT EXECUTED
}
if ( option == RTEMS_CLOCK_GET_TIME_VALUE )
return rtems_clock_get_tod_timeval( (struct timeval *)time_buffer );
return RTEMS_INVALID_NUMBER;
a00152d4: e3a0000a mov r0, #10 <== NOT EXECUTED
}
a00152d8: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a001540c <rtems_clock_get_tod_timeval>:
#include <rtems/score/watchdog.h>
rtems_status_code rtems_clock_get_tod_timeval(
struct timeval *time
)
{
a001540c: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED
if ( !time )
a0015410: e2504000 subs r4, r0, #0 <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
a0015414: 03a00009 moveq r0, #9 <== NOT EXECUTED
rtems_status_code rtems_clock_get_tod_timeval(
struct timeval *time
)
{
if ( !time )
a0015418: 0a000011 beq a0015464 <rtems_clock_get_tod_timeval+0x58> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
if ( !_TOD_Is_set )
a001541c: e59f3044 ldr r3, [pc, #68] ; a0015468 <rtems_clock_get_tod_timeval+0x5c><== NOT EXECUTED
a0015420: e5d33000 ldrb r3, [r3] <== NOT EXECUTED
a0015424: e3530000 cmp r3, #0 <== NOT EXECUTED
return RTEMS_NOT_DEFINED;
a0015428: 03a0000b moveq r0, #11 <== NOT EXECUTED
)
{
if ( !time )
return RTEMS_INVALID_ADDRESS;
if ( !_TOD_Is_set )
a001542c: 0a00000c beq a0015464 <rtems_clock_get_tod_timeval+0x58> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0015430: e10f5000 mrs r5, CPSR <== NOT EXECUTED
a0015434: e3853080 orr r3, r5, #128 ; 0x80 <== NOT EXECUTED
a0015438: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
ISR_Level level;
struct timespec now;
suseconds_t useconds;
_ISR_Disable(level);
_TOD_Get( &now );
a001543c: e1a0000d mov r0, sp <== NOT EXECUTED
a0015440: eb001122 bl a00198d0 <_TOD_Get> <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0015444: e129f005 msr CPSR_fc, r5 <== NOT EXECUTED
_ISR_Enable(level);
useconds = (suseconds_t)now.tv_nsec;
useconds /= (suseconds_t)TOD_NANOSECONDS_PER_MICROSECOND;
time->tv_sec = now.tv_sec;
a0015448: e59d3000 ldr r3, [sp] <== NOT EXECUTED
_ISR_Disable(level);
_TOD_Get( &now );
_ISR_Enable(level);
useconds = (suseconds_t)now.tv_nsec;
useconds /= (suseconds_t)TOD_NANOSECONDS_PER_MICROSECOND;
a001544c: e59d0004 ldr r0, [sp, #4] <== NOT EXECUTED
a0015450: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED
time->tv_sec = now.tv_sec;
a0015454: e5843000 str r3, [r4] <== NOT EXECUTED
_ISR_Disable(level);
_TOD_Get( &now );
_ISR_Enable(level);
useconds = (suseconds_t)now.tv_nsec;
useconds /= (suseconds_t)TOD_NANOSECONDS_PER_MICROSECOND;
a0015458: eb006566 bl a002e9f8 <__aeabi_idiv> <== NOT EXECUTED
time->tv_sec = now.tv_sec;
time->tv_usec = useconds;
a001545c: e5840004 str r0, [r4, #4] <== NOT EXECUTED
return RTEMS_NOT_DEFINED;
_TOD_Get_timeval( time );
return RTEMS_SUCCESSFUL;
a0015460: e3a00000 mov r0, #0 <== NOT EXECUTED
}
a0015464: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED
a0008ff4 <rtems_clock_get_uptime>:
*/
rtems_status_code rtems_clock_get_uptime(
struct timespec *uptime
)
{
if ( !uptime )
a0008ff4: e3500000 cmp r0, #0 <== NOT EXECUTED
* error code - if unsuccessful
*/
rtems_status_code rtems_clock_get_uptime(
struct timespec *uptime
)
{
a0008ff8: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
if ( !uptime )
a0008ffc: 0a000002 beq a000900c <rtems_clock_get_uptime+0x18> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
_TOD_Get_uptime_as_timespec( uptime );
a0009000: eb000558 bl a000a568 <_TOD_Get_uptime_as_timespec> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a0009004: e3a00000 mov r0, #0 <== NOT EXECUTED
a0009008: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
rtems_status_code rtems_clock_get_uptime(
struct timespec *uptime
)
{
if ( !uptime )
return RTEMS_INVALID_ADDRESS;
a000900c: e3a00009 mov r0, #9 <== NOT EXECUTED
_TOD_Get_uptime_as_timespec( uptime );
return RTEMS_SUCCESSFUL;
}
a0009010: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a0008ddc <rtems_clock_tick>:
*
* NOTE: This routine only works for leap-years through 2099.
*/
rtems_status_code rtems_clock_tick( void )
{
a0008ddc: e52de004 push {lr} ; (str lr, [sp, #-4]!)
_TOD_Tickle_ticks();
a0008de0: eb0004ff bl a000a1e4 <_TOD_Tickle_ticks>
*/
RTEMS_INLINE_ROUTINE void _Watchdog_Tickle_ticks( void )
{
_Watchdog_Tickle( &_Watchdog_Ticks_chain );
a0008de4: e59f0030 ldr r0, [pc, #48] ; a0008e1c <rtems_clock_tick+0x40>
a0008de8: eb000e33 bl a000c6bc <_Watchdog_Tickle>
_Watchdog_Tickle_ticks();
_Thread_Tickle_timeslice();
a0008dec: eb000cbc bl a000c0e4 <_Thread_Tickle_timeslice>
* otherwise.
*/
RTEMS_INLINE_ROUTINE bool _Thread_Is_context_switch_necessary( void )
{
return ( _Thread_Dispatch_necessary );
a0008df0: e59f3028 ldr r3, [pc, #40] ; a0008e20 <rtems_clock_tick+0x44>
a0008df4: e5d33010 ldrb r3, [r3, #16]
if ( _Thread_Is_context_switch_necessary() &&
a0008df8: e3530000 cmp r3, #0
a0008dfc: 0a000004 beq a0008e14 <rtems_clock_tick+0x38>
* otherwise.
*/
RTEMS_INLINE_ROUTINE bool _Thread_Is_dispatching_enabled( void )
{
return ( _Thread_Dispatch_disable_level == 0 );
a0008e00: e59f301c ldr r3, [pc, #28] ; a0008e24 <rtems_clock_tick+0x48><== NOT EXECUTED
a0008e04: e5933000 ldr r3, [r3] <== NOT EXECUTED
a0008e08: e3530000 cmp r3, #0 <== NOT EXECUTED
a0008e0c: 1a000000 bne a0008e14 <rtems_clock_tick+0x38> <== NOT EXECUTED
_Thread_Is_dispatching_enabled() )
_Thread_Dispatch();
a0008e10: eb0009dc bl a000b588 <_Thread_Dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
}
a0008e14: e3a00000 mov r0, #0
a0008e18: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a0008e28 <rtems_event_receive>:
rtems_event_set event_in,
rtems_option option_set,
rtems_interval ticks,
rtems_event_set *event_out
)
{
a0008e28: e92d4070 push {r4, r5, r6, lr}
RTEMS_API_Control *api;
if ( !event_out )
a0008e2c: e2535000 subs r5, r3, #0
a0008e30: 0a000010 beq a0008e78 <rtems_event_receive+0x50>
return RTEMS_INVALID_ADDRESS;
api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ];
a0008e34: e59f4044 ldr r4, [pc, #68] ; a0008e80 <rtems_event_receive+0x58>
if ( _Event_sets_Is_empty( event_in ) ) {
a0008e38: e3500000 cmp r0, #0
RTEMS_API_Control *api;
if ( !event_out )
return RTEMS_INVALID_ADDRESS;
api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ];
a0008e3c: e5946004 ldr r6, [r4, #4]
a0008e40: e59660f8 ldr r6, [r6, #248] ; 0xf8
if ( _Event_sets_Is_empty( event_in ) ) {
a0008e44: 1a000002 bne a0008e54 <rtems_event_receive+0x2c>
*event_out = api->pending_events;
a0008e48: e5963000 ldr r3, [r6]
a0008e4c: e5853000 str r3, [r5]
return RTEMS_SUCCESSFUL;
a0008e50: e8bd8070 pop {r4, r5, r6, pc}
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a0008e54: e59fc028 ldr ip, [pc, #40] ; a0008e84 <rtems_event_receive+0x5c>
a0008e58: e59ce000 ldr lr, [ip]
a0008e5c: e28ee001 add lr, lr, #1
a0008e60: e58ce000 str lr, [ip]
}
_Thread_Disable_dispatch();
_Event_Seize( event_in, option_set, ticks, event_out );
a0008e64: eb000007 bl a0008e88 <_Event_Seize>
_Thread_Enable_dispatch();
a0008e68: eb000a0a bl a000b698 <_Thread_Enable_dispatch>
return( _Thread_Executing->Wait.return_code );
a0008e6c: e5943004 ldr r3, [r4, #4]
a0008e70: e5930034 ldr r0, [r3, #52] ; 0x34
a0008e74: e8bd8070 pop {r4, r5, r6, pc}
)
{
RTEMS_API_Control *api;
if ( !event_out )
return RTEMS_INVALID_ADDRESS;
a0008e78: e3a00009 mov r0, #9 <== NOT EXECUTED
_Thread_Disable_dispatch();
_Event_Seize( event_in, option_set, ticks, event_out );
_Thread_Enable_dispatch();
return( _Thread_Executing->Wait.return_code );
}
a0008e7c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
a000bc00 <rtems_extension_ident>:
rtems_status_code rtems_extension_ident(
rtems_name name,
rtems_id *id
)
{
a000bc00: e1a02000 mov r2, r0 <== NOT EXECUTED
a000bc04: e1a03001 mov r3, r1 <== NOT EXECUTED
a000bc08: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
Objects_Name_or_id_lookup_errors status;
status = _Objects_Name_to_id_u32(
a000bc0c: e1a01002 mov r1, r2 <== NOT EXECUTED
a000bc10: e59f0010 ldr r0, [pc, #16] ; a000bc28 <rtems_extension_ident+0x28><== NOT EXECUTED
a000bc14: e3e02102 mvn r2, #-2147483648 ; 0x80000000 <== NOT EXECUTED
a000bc18: eb0004a9 bl a000cec4 <_Objects_Name_to_id_u32> <== NOT EXECUTED
OBJECTS_SEARCH_LOCAL_NODE,
id
);
return _Status_Object_name_errors_to_status[ status ];
}
a000bc1c: e59f3008 ldr r3, [pc, #8] ; a000bc2c <rtems_extension_ident+0x2c><== NOT EXECUTED
a000bc20: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED
a000bc24: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a000a244 <rtems_interrupt_disable>:
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000a244: e10f0000 mrs r0, CPSR <== NOT EXECUTED
a000a248: e3803080 orr r3, r0, #128 ; 0x80 <== NOT EXECUTED
a000a24c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
rtems_interrupt_level previous_level;
_ISR_Disable( previous_level );
return previous_level;
}
a000a250: e12fff1e bx lr <== NOT EXECUTED
a000a254 <rtems_interrupt_enable>:
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000a254: e129f000 msr CPSR_fc, r0 <== NOT EXECUTED
void rtems_interrupt_enable(
rtems_interrupt_level previous_level
)
{
_ISR_Enable( previous_level );
}
a000a258: e12fff1e bx lr <== NOT EXECUTED
a000a25c <rtems_interrupt_flash>:
static inline void arm_interrupt_flash( uint32_t level )
{
uint32_t arm_switch_reg;
asm volatile (
a000a25c: e10f3000 mrs r3, CPSR <== NOT EXECUTED
a000a260: e129f000 msr CPSR_fc, r0 <== NOT EXECUTED
a000a264: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
void rtems_interrupt_flash(
rtems_interrupt_level previous_level
)
{
_ISR_Flash( previous_level );
}
a000a268: e12fff1e bx lr <== NOT EXECUTED
a000a26c <rtems_interrupt_is_in_progress>:
#undef rtems_interrupt_is_in_progress
bool rtems_interrupt_is_in_progress( void )
{
return _ISR_Is_in_progress();
a000a26c: e59f300c ldr r3, [pc, #12] ; a000a280 <rtems_interrupt_is_in_progress+0x14><== NOT EXECUTED
a000a270: e5930000 ldr r0, [r3] <== NOT EXECUTED
}
a000a274: e2500000 subs r0, r0, #0 <== NOT EXECUTED
a000a278: 13a00001 movne r0, #1 <== NOT EXECUTED
a000a27c: e12fff1e bx lr <== NOT EXECUTED
a0009c68 <rtems_interrupt_level_attribute>:
rtems_attribute rtems_interrupt_level_attribute(
uint32_t level
)
{
return RTEMS_INTERRUPT_LEVEL(level);
}
a0009c68: e2000080 and r0, r0, #128 ; 0x80 <== NOT EXECUTED
a0009c6c: e12fff1e bx lr <== NOT EXECUTED
a0010d64 <rtems_io_close>:
void *argument
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010d64: e59fc044 ldr ip, [pc, #68] ; a0010db0 <rtems_io_close+0x4c>
rtems_status_code rtems_io_close(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010d68: e92d4010 push {r4, lr}
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010d6c: e59cc000 ldr ip, [ip]
rtems_status_code rtems_io_close(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010d70: e1a03000 mov r3, r0
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010d74: e150000c cmp r0, ip
a0010d78: 2a000008 bcs a0010da0 <rtems_io_close+0x3c>
return RTEMS_INVALID_NUMBER;
callout = _IO_Driver_address_table[major].close_entry;
a0010d7c: e59fc030 ldr ip, [pc, #48] ; a0010db4 <rtems_io_close+0x50>
a0010d80: e3a04018 mov r4, #24
a0010d84: e59cc000 ldr ip, [ip]
a0010d88: e023c394 mla r3, r4, r3, ip
a0010d8c: e5933008 ldr r3, [r3, #8]
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010d90: e3530000 cmp r3, #0
a0010d94: 0a000003 beq a0010da8 <rtems_io_close+0x44>
a0010d98: e12fff33 blx r3
a0010d9c: e8bd8010 pop {r4, pc}
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
return RTEMS_INVALID_NUMBER;
a0010da0: e3a0000a mov r0, #10 <== NOT EXECUTED
a0010da4: e8bd8010 pop {r4, pc} <== NOT EXECUTED
callout = _IO_Driver_address_table[major].close_entry;
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010da8: e1a00003 mov r0, r3
}
a0010dac: e8bd8010 pop {r4, pc}
a0010db8 <rtems_io_control>:
void *argument
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010db8: e59fc044 ldr ip, [pc, #68] ; a0010e04 <rtems_io_control+0x4c>
rtems_status_code rtems_io_control(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010dbc: e92d4010 push {r4, lr}
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010dc0: e59cc000 ldr ip, [ip]
rtems_status_code rtems_io_control(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010dc4: e1a03000 mov r3, r0
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010dc8: e150000c cmp r0, ip
a0010dcc: 2a000008 bcs a0010df4 <rtems_io_control+0x3c>
return RTEMS_INVALID_NUMBER;
callout = _IO_Driver_address_table[major].control_entry;
a0010dd0: e59fc030 ldr ip, [pc, #48] ; a0010e08 <rtems_io_control+0x50>
a0010dd4: e3a04018 mov r4, #24
a0010dd8: e59cc000 ldr ip, [ip]
a0010ddc: e023c394 mla r3, r4, r3, ip
a0010de0: e5933014 ldr r3, [r3, #20]
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010de4: e3530000 cmp r3, #0
a0010de8: 0a000003 beq a0010dfc <rtems_io_control+0x44>
a0010dec: e12fff33 blx r3
a0010df0: e8bd8010 pop {r4, pc}
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
return RTEMS_INVALID_NUMBER;
a0010df4: e3a0000a mov r0, #10 <== NOT EXECUTED
a0010df8: e8bd8010 pop {r4, pc} <== NOT EXECUTED
callout = _IO_Driver_address_table[major].control_entry;
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010dfc: e1a00003 mov r0, r3 <== NOT EXECUTED
}
a0010e00: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000ed5c <rtems_io_initialize>:
void *argument
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a000ed5c: e59fc044 ldr ip, [pc, #68] ; a000eda8 <rtems_io_initialize+0x4c>
rtems_status_code rtems_io_initialize(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a000ed60: e92d4010 push {r4, lr}
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a000ed64: e59cc000 ldr ip, [ip]
rtems_status_code rtems_io_initialize(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a000ed68: e1a03000 mov r3, r0
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a000ed6c: e150000c cmp r0, ip
a000ed70: 2a000008 bcs a000ed98 <rtems_io_initialize+0x3c>
return RTEMS_INVALID_NUMBER;
callout = _IO_Driver_address_table[major].initialization_entry;
a000ed74: e59fc030 ldr ip, [pc, #48] ; a000edac <rtems_io_initialize+0x50>
a000ed78: e3a04018 mov r4, #24
a000ed7c: e0030394 mul r3, r4, r3
a000ed80: e59cc000 ldr ip, [ip]
a000ed84: e79c3003 ldr r3, [ip, r3]
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a000ed88: e3530000 cmp r3, #0
a000ed8c: 0a000003 beq a000eda0 <rtems_io_initialize+0x44>
a000ed90: e12fff33 blx r3
a000ed94: e8bd8010 pop {r4, pc}
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
return RTEMS_INVALID_NUMBER;
a000ed98: e3a0000a mov r0, #10 <== NOT EXECUTED
a000ed9c: e8bd8010 pop {r4, pc} <== NOT EXECUTED
callout = _IO_Driver_address_table[major].initialization_entry;
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a000eda0: e1a00003 mov r0, r3
}
a000eda4: e8bd8010 pop {r4, pc}
a0010e0c <rtems_io_open>:
void *argument
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010e0c: e59fc044 ldr ip, [pc, #68] ; a0010e58 <rtems_io_open+0x4c>
rtems_status_code rtems_io_open(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010e10: e92d4010 push {r4, lr}
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010e14: e59cc000 ldr ip, [ip]
rtems_status_code rtems_io_open(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010e18: e1a03000 mov r3, r0
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010e1c: e150000c cmp r0, ip
a0010e20: 2a000008 bcs a0010e48 <rtems_io_open+0x3c>
return RTEMS_INVALID_NUMBER;
callout = _IO_Driver_address_table[major].open_entry;
a0010e24: e59fc030 ldr ip, [pc, #48] ; a0010e5c <rtems_io_open+0x50>
a0010e28: e3a04018 mov r4, #24
a0010e2c: e59cc000 ldr ip, [ip]
a0010e30: e023c394 mla r3, r4, r3, ip
a0010e34: e5933004 ldr r3, [r3, #4]
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010e38: e3530000 cmp r3, #0
a0010e3c: 0a000003 beq a0010e50 <rtems_io_open+0x44>
a0010e40: e12fff33 blx r3
a0010e44: e8bd8010 pop {r4, pc}
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
return RTEMS_INVALID_NUMBER;
a0010e48: e3a0000a mov r0, #10 <== NOT EXECUTED
a0010e4c: e8bd8010 pop {r4, pc} <== NOT EXECUTED
callout = _IO_Driver_address_table[major].open_entry;
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010e50: e1a00003 mov r0, r3
}
a0010e54: e8bd8010 pop {r4, pc}
a0010e60 <rtems_io_read>:
void *argument
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010e60: e59fc044 ldr ip, [pc, #68] ; a0010eac <rtems_io_read+0x4c>
rtems_status_code rtems_io_read(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010e64: e92d4010 push {r4, lr}
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010e68: e59cc000 ldr ip, [ip]
rtems_status_code rtems_io_read(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010e6c: e1a03000 mov r3, r0
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010e70: e150000c cmp r0, ip
a0010e74: 2a000008 bcs a0010e9c <rtems_io_read+0x3c>
return RTEMS_INVALID_NUMBER;
callout = _IO_Driver_address_table[major].read_entry;
a0010e78: e59fc030 ldr ip, [pc, #48] ; a0010eb0 <rtems_io_read+0x50>
a0010e7c: e3a04018 mov r4, #24
a0010e80: e59cc000 ldr ip, [ip]
a0010e84: e023c394 mla r3, r4, r3, ip
a0010e88: e593300c ldr r3, [r3, #12]
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010e8c: e3530000 cmp r3, #0
a0010e90: 0a000003 beq a0010ea4 <rtems_io_read+0x44>
a0010e94: e12fff33 blx r3
a0010e98: e8bd8010 pop {r4, pc}
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
return RTEMS_INVALID_NUMBER;
a0010e9c: e3a0000a mov r0, #10 <== NOT EXECUTED
a0010ea0: e8bd8010 pop {r4, pc} <== NOT EXECUTED
callout = _IO_Driver_address_table[major].read_entry;
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010ea4: e1a00003 mov r0, r3
}
a0010ea8: e8bd8010 pop {r4, pc}
a000ab70 <rtems_io_register_driver>:
rtems_status_code rtems_io_register_driver(
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
a000ab70: e92d4010 push {r4, lr}
a000ab74: e1a04000 mov r4, r0
rtems_device_major_number major_limit = _IO_Number_of_drivers;
if ( rtems_interrupt_is_in_progress() )
a000ab78: e59f015c ldr r0, [pc, #348] ; a000acdc <rtems_io_register_driver+0x16c>
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
rtems_device_major_number major_limit = _IO_Number_of_drivers;
a000ab7c: e59f315c ldr r3, [pc, #348] ; a000ace0 <rtems_io_register_driver+0x170>
if ( rtems_interrupt_is_in_progress() )
a000ab80: e5900000 ldr r0, [r0]
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
rtems_device_major_number major_limit = _IO_Number_of_drivers;
a000ab84: e5933000 ldr r3, [r3]
if ( rtems_interrupt_is_in_progress() )
a000ab88: e3500000 cmp r0, #0
a000ab8c: 1a000043 bne a000aca0 <rtems_io_register_driver+0x130>
return RTEMS_CALLED_FROM_ISR;
if ( registered_major == NULL )
a000ab90: e3520000 cmp r2, #0
a000ab94: 0a000043 beq a000aca8 <rtems_io_register_driver+0x138>
return RTEMS_INVALID_ADDRESS;
/* Set it to an invalid value */
*registered_major = major_limit;
if ( driver_table == NULL )
a000ab98: e3510000 cmp r1, #0
if ( registered_major == NULL )
return RTEMS_INVALID_ADDRESS;
/* Set it to an invalid value */
*registered_major = major_limit;
a000ab9c: e5823000 str r3, [r2]
if ( driver_table == NULL )
a000aba0: 0a000040 beq a000aca8 <rtems_io_register_driver+0x138>
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
a000aba4: e5910000 ldr r0, [r1]
a000aba8: e3500000 cmp r0, #0
a000abac: 1a000041 bne a000acb8 <rtems_io_register_driver+0x148>
a000abb0: e5910004 ldr r0, [r1, #4]
a000abb4: e3500000 cmp r0, #0
a000abb8: 1a00003e bne a000acb8 <rtems_io_register_driver+0x148>
a000abbc: ea000039 b a000aca8 <rtems_io_register_driver+0x138> <== NOT EXECUTED
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000abc0: e59f311c ldr r3, [pc, #284] ; a000ace4 <rtems_io_register_driver+0x174>
a000abc4: e5930000 ldr r0, [r3]
a000abc8: e2800001 add r0, r0, #1
a000abcc: e5830000 str r0, [r3]
if ( major >= major_limit )
return RTEMS_INVALID_NUMBER;
_Thread_Disable_dispatch();
if ( major == 0 ) {
a000abd0: e3540000 cmp r4, #0
a000abd4: e59f010c ldr r0, [pc, #268] ; a000ace8 <rtems_io_register_driver+0x178>
a000abd8: 1a000010 bne a000ac20 <rtems_io_register_driver+0xb0>
static rtems_status_code rtems_io_obtain_major_number(
rtems_device_major_number *major
)
{
rtems_device_major_number n = _IO_Number_of_drivers;
a000abdc: e59f30fc ldr r3, [pc, #252] ; a000ace0 <rtems_io_register_driver+0x170>
a000abe0: e593c000 ldr ip, [r3]
a000abe4: e5903000 ldr r3, [r0]
a000abe8: ea000006 b a000ac08 <rtems_io_register_driver+0x98>
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
a000abec: e5930000 ldr r0, [r3]
a000abf0: e3500000 cmp r0, #0
a000abf4: 1a000032 bne a000acc4 <rtems_io_register_driver+0x154>
a000abf8: e5930004 ldr r0, [r3, #4]
a000abfc: e3500000 cmp r0, #0
a000ac00: 1a00002f bne a000acc4 <rtems_io_register_driver+0x154>
a000ac04: ea000001 b a000ac10 <rtems_io_register_driver+0xa0>
rtems_device_major_number n = _IO_Number_of_drivers;
rtems_device_major_number m = 0;
/* major is error checked by caller */
for ( m = 0; m < n; ++m ) {
a000ac08: e154000c cmp r4, ip
a000ac0c: 3afffff6 bcc a000abec <rtems_io_register_driver+0x7c>
}
/* Assigns invalid value in case of failure */
*major = m;
if ( m != n )
a000ac10: e154000c cmp r4, ip
if ( rtems_io_is_empty_table( table ) )
break;
}
/* Assigns invalid value in case of failure */
*major = m;
a000ac14: e5824000 str r4, [r2]
if ( m != n )
a000ac18: 1a000011 bne a000ac64 <rtems_io_register_driver+0xf4>
a000ac1c: ea00002b b a000acd0 <rtems_io_register_driver+0x160>
_Thread_Enable_dispatch();
return sc;
}
major = *registered_major;
} else {
rtems_driver_address_table *const table = _IO_Driver_address_table + major;
a000ac20: e3a03018 mov r3, #24
a000ac24: e0030394 mul r3, r4, r3
a000ac28: e5900000 ldr r0, [r0]
a000ac2c: e080c003 add ip, r0, r3
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
a000ac30: e7903003 ldr r3, [r0, r3]
a000ac34: e3530000 cmp r3, #0
a000ac38: 13a03000 movne r3, #0
a000ac3c: 1a000002 bne a000ac4c <rtems_io_register_driver+0xdc>
return RTEMS_SUCCESSFUL;
return RTEMS_TOO_MANY;
}
rtems_status_code rtems_io_register_driver(
a000ac40: e59c3004 ldr r3, [ip, #4]
a000ac44: e2733001 rsbs r3, r3, #1
a000ac48: 33a03000 movcc r3, #0
}
major = *registered_major;
} else {
rtems_driver_address_table *const table = _IO_Driver_address_table + major;
if ( !rtems_io_is_empty_table( table ) ) {
a000ac4c: e3530000 cmp r3, #0
_Thread_Enable_dispatch();
return RTEMS_RESOURCE_IN_USE;
}
*registered_major = major;
a000ac50: 15824000 strne r4, [r2]
}
major = *registered_major;
} else {
rtems_driver_address_table *const table = _IO_Driver_address_table + major;
if ( !rtems_io_is_empty_table( table ) ) {
a000ac54: 1a000002 bne a000ac64 <rtems_io_register_driver+0xf4>
_Thread_Enable_dispatch();
a000ac58: eb0006fe bl a000c858 <_Thread_Enable_dispatch>
return RTEMS_RESOURCE_IN_USE;
a000ac5c: e3a0000c mov r0, #12
a000ac60: e8bd8010 pop {r4, pc}
}
*registered_major = major;
}
_IO_Driver_address_table [major] = *driver_table;
a000ac64: e59f307c ldr r3, [pc, #124] ; a000ace8 <rtems_io_register_driver+0x178>
a000ac68: e3a0c018 mov ip, #24
a000ac6c: e1a0e001 mov lr, r1
a000ac70: e5933000 ldr r3, [r3]
a000ac74: e02c3c94 mla ip, r4, ip, r3
a000ac78: e8be000f ldm lr!, {r0, r1, r2, r3}
a000ac7c: e8ac000f stmia ip!, {r0, r1, r2, r3}
a000ac80: e89e0003 ldm lr, {r0, r1}
a000ac84: e88c0003 stm ip, {r0, r1}
_Thread_Enable_dispatch();
a000ac88: eb0006f2 bl a000c858 <_Thread_Enable_dispatch>
return rtems_io_initialize( major, 0, NULL );
a000ac8c: e3a01000 mov r1, #0
a000ac90: e1a00004 mov r0, r4
a000ac94: e1a02001 mov r2, r1
}
a000ac98: e8bd4010 pop {r4, lr}
_IO_Driver_address_table [major] = *driver_table;
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
a000ac9c: ea001f17 b a0012900 <rtems_io_initialize>
)
{
rtems_device_major_number major_limit = _IO_Number_of_drivers;
if ( rtems_interrupt_is_in_progress() )
return RTEMS_CALLED_FROM_ISR;
a000aca0: e3a00012 mov r0, #18 <== NOT EXECUTED
a000aca4: e8bd8010 pop {r4, pc} <== NOT EXECUTED
if ( driver_table == NULL )
return RTEMS_INVALID_ADDRESS;
if ( rtems_io_is_empty_table( driver_table ) )
return RTEMS_INVALID_ADDRESS;
a000aca8: e3a00009 mov r0, #9 <== NOT EXECUTED
a000acac: e8bd8010 pop {r4, pc} <== NOT EXECUTED
if ( major >= major_limit )
return RTEMS_INVALID_NUMBER;
a000acb0: e3a0000a mov r0, #10 <== NOT EXECUTED
_IO_Driver_address_table [major] = *driver_table;
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
}
a000acb4: e8bd8010 pop {r4, pc} <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
if ( rtems_io_is_empty_table( driver_table ) )
return RTEMS_INVALID_ADDRESS;
if ( major >= major_limit )
a000acb8: e1540003 cmp r4, r3
a000acbc: 3affffbf bcc a000abc0 <rtems_io_register_driver+0x50>
a000acc0: eafffffa b a000acb0 <rtems_io_register_driver+0x140> <== NOT EXECUTED
rtems_device_major_number n = _IO_Number_of_drivers;
rtems_device_major_number m = 0;
/* major is error checked by caller */
for ( m = 0; m < n; ++m ) {
a000acc4: e2844001 add r4, r4, #1
a000acc8: e2833018 add r3, r3, #24
a000accc: eaffffcd b a000ac08 <rtems_io_register_driver+0x98>
if ( major == 0 ) {
rtems_status_code sc = rtems_io_obtain_major_number( registered_major );
if ( sc != RTEMS_SUCCESSFUL ) {
_Thread_Enable_dispatch();
a000acd0: eb0006e0 bl a000c858 <_Thread_Enable_dispatch>
*major = m;
if ( m != n )
return RTEMS_SUCCESSFUL;
return RTEMS_TOO_MANY;
a000acd4: e3a00005 mov r0, #5
if ( major == 0 ) {
rtems_status_code sc = rtems_io_obtain_major_number( registered_major );
if ( sc != RTEMS_SUCCESSFUL ) {
_Thread_Enable_dispatch();
return sc;
a000acd8: e8bd8010 pop {r4, pc}
a000acec <rtems_io_unregister_driver>:
rtems_status_code rtems_io_unregister_driver(
rtems_device_major_number major
)
{
if ( rtems_interrupt_is_in_progress() )
a000acec: e59f3060 ldr r3, [pc, #96] ; a000ad54 <rtems_io_unregister_driver+0x68>
*/
rtems_status_code rtems_io_unregister_driver(
rtems_device_major_number major
)
{
a000acf0: e92d4010 push {r4, lr}
if ( rtems_interrupt_is_in_progress() )
a000acf4: e5934000 ldr r4, [r3]
a000acf8: e3540000 cmp r4, #0
a000acfc: 1a000010 bne a000ad44 <rtems_io_unregister_driver+0x58>
return RTEMS_CALLED_FROM_ISR;
if ( major < _IO_Number_of_drivers ) {
a000ad00: e59f3050 ldr r3, [pc, #80] ; a000ad58 <rtems_io_unregister_driver+0x6c>
a000ad04: e5933000 ldr r3, [r3]
a000ad08: e1500003 cmp r0, r3
a000ad0c: 2a00000e bcs a000ad4c <rtems_io_unregister_driver+0x60>
a000ad10: e59f3044 ldr r3, [pc, #68] ; a000ad5c <rtems_io_unregister_driver+0x70>
a000ad14: e5932000 ldr r2, [r3]
a000ad18: e2822001 add r2, r2, #1
a000ad1c: e5832000 str r2, [r3]
_Thread_Disable_dispatch();
memset(
a000ad20: e59f3038 ldr r3, [pc, #56] ; a000ad60 <rtems_io_unregister_driver+0x74>
&_IO_Driver_address_table[major],
a000ad24: e3a02018 mov r2, #24
if ( rtems_interrupt_is_in_progress() )
return RTEMS_CALLED_FROM_ISR;
if ( major < _IO_Number_of_drivers ) {
_Thread_Disable_dispatch();
memset(
a000ad28: e1a01004 mov r1, r4
a000ad2c: e5933000 ldr r3, [r3]
a000ad30: e0203092 mla r0, r2, r0, r3
a000ad34: eb002a56 bl a0015694 <memset>
&_IO_Driver_address_table[major],
0,
sizeof( rtems_driver_address_table )
);
_Thread_Enable_dispatch();
a000ad38: eb0006c6 bl a000c858 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000ad3c: e1a00004 mov r0, r4
a000ad40: e8bd8010 pop {r4, pc}
rtems_status_code rtems_io_unregister_driver(
rtems_device_major_number major
)
{
if ( rtems_interrupt_is_in_progress() )
return RTEMS_CALLED_FROM_ISR;
a000ad44: e3a00012 mov r0, #18
a000ad48: e8bd8010 pop {r4, pc} <== NOT EXECUTED
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
return RTEMS_UNSATISFIED;
a000ad4c: e3a0000d mov r0, #13 <== NOT EXECUTED
}
a000ad50: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a0010eb4 <rtems_io_write>:
void *argument
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010eb4: e59fc044 ldr ip, [pc, #68] ; a0010f00 <rtems_io_write+0x4c>
rtems_status_code rtems_io_write(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010eb8: e92d4010 push {r4, lr}
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010ebc: e59cc000 ldr ip, [ip]
rtems_status_code rtems_io_write(
rtems_device_major_number major,
rtems_device_minor_number minor,
void *argument
)
{
a0010ec0: e1a03000 mov r3, r0
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
a0010ec4: e150000c cmp r0, ip
a0010ec8: 2a000008 bcs a0010ef0 <rtems_io_write+0x3c>
return RTEMS_INVALID_NUMBER;
callout = _IO_Driver_address_table[major].write_entry;
a0010ecc: e59fc030 ldr ip, [pc, #48] ; a0010f04 <rtems_io_write+0x50>
a0010ed0: e3a04018 mov r4, #24
a0010ed4: e59cc000 ldr ip, [ip]
a0010ed8: e023c394 mla r3, r4, r3, ip
a0010edc: e5933010 ldr r3, [r3, #16]
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010ee0: e3530000 cmp r3, #0
a0010ee4: 0a000003 beq a0010ef8 <rtems_io_write+0x44>
a0010ee8: e12fff33 blx r3
a0010eec: e8bd8010 pop {r4, pc}
)
{
rtems_device_driver_entry callout;
if ( major >= _IO_Number_of_drivers )
return RTEMS_INVALID_NUMBER;
a0010ef0: e3a0000a mov r0, #10 <== NOT EXECUTED
a0010ef4: e8bd8010 pop {r4, pc} <== NOT EXECUTED
callout = _IO_Driver_address_table[major].write_entry;
return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL;
a0010ef8: e1a00003 mov r0, r3
}
a0010efc: e8bd8010 pop {r4, pc}
a0015c34 <rtems_message_queue_broadcast>:
rtems_id id,
const void *buffer,
size_t size,
uint32_t *count
)
{
a0015c34: e92d40f7 push {r0, r1, r2, r4, r5, r6, r7, lr}
register Message_queue_Control *the_message_queue;
Objects_Locations location;
CORE_message_queue_Status core_status;
if ( !buffer )
a0015c38: e2517000 subs r7, r1, #0
rtems_id id,
const void *buffer,
size_t size,
uint32_t *count
)
{
a0015c3c: e1a04000 mov r4, r0
a0015c40: e1a05002 mov r5, r2
a0015c44: e1a06003 mov r6, r3
register Message_queue_Control *the_message_queue;
Objects_Locations location;
CORE_message_queue_Status core_status;
if ( !buffer )
a0015c48: 0a000015 beq a0015ca4 <rtems_message_queue_broadcast+0x70>
return RTEMS_INVALID_ADDRESS;
if ( !count )
a0015c4c: e3530000 cmp r3, #0
a0015c50: 0a000013 beq a0015ca4 <rtems_message_queue_broadcast+0x70>
Objects_Id id,
Objects_Locations *location
)
{
return (Message_queue_Control *)
_Objects_Get( &_Message_queue_Information, id, location );
a0015c54: e59f0050 ldr r0, [pc, #80] ; a0015cac <rtems_message_queue_broadcast+0x78>
a0015c58: e1a01004 mov r1, r4
a0015c5c: e28d2008 add r2, sp, #8
a0015c60: eb001430 bl a001ad28 <_Objects_Get>
return RTEMS_INVALID_ADDRESS;
the_message_queue = _Message_queue_Get( id, &location );
switch ( location ) {
a0015c64: e59d3008 ldr r3, [sp, #8]
a0015c68: e3530000 cmp r3, #0
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0015c6c: 13a00004 movne r0, #4
if ( !count )
return RTEMS_INVALID_ADDRESS;
the_message_queue = _Message_queue_Get( id, &location );
switch ( location ) {
a0015c70: 1a00000c bne a0015ca8 <rtems_message_queue_broadcast+0x74>
case OBJECTS_LOCAL:
core_status = _CORE_message_queue_Broadcast(
a0015c74: e58d3000 str r3, [sp]
a0015c78: e1a01007 mov r1, r7
a0015c7c: e1a03004 mov r3, r4
a0015c80: e1a02005 mov r2, r5
a0015c84: e2800014 add r0, r0, #20
a0015c88: e58d6004 str r6, [sp, #4]
a0015c8c: eb000d1e bl a001910c <_CORE_message_queue_Broadcast>
a0015c90: e1a04000 mov r4, r0
NULL,
#endif
count
);
_Thread_Enable_dispatch();
a0015c94: eb0016ff bl a001b898 <_Thread_Enable_dispatch>
return
a0015c98: e1a00004 mov r0, r4
a0015c9c: eb0000cc bl a0015fd4 <_Message_queue_Translate_core_message_queue_return_code>
a0015ca0: ea000000 b a0015ca8 <rtems_message_queue_broadcast+0x74>
if ( !buffer )
return RTEMS_INVALID_ADDRESS;
if ( !count )
return RTEMS_INVALID_ADDRESS;
a0015ca4: e3a00009 mov r0, #9
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0015ca8: e8bd80fe pop {r1, r2, r3, r4, r5, r6, r7, pc}
a0010fc4 <rtems_message_queue_create>:
uint32_t count,
size_t max_message_size,
rtems_attribute attribute_set,
rtems_id *id
)
{
a0010fc4: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr}
CORE_message_queue_Attributes the_msgq_attributes;
#if defined(RTEMS_MULTIPROCESSING)
bool is_global;
#endif
if ( !rtems_is_name_valid( name ) )
a0010fc8: e2507000 subs r7, r0, #0
uint32_t count,
size_t max_message_size,
rtems_attribute attribute_set,
rtems_id *id
)
{
a0010fcc: e1a06001 mov r6, r1
a0010fd0: e1a05002 mov r5, r2
a0010fd4: e1a0a003 mov sl, r3
a0010fd8: e59d8020 ldr r8, [sp, #32]
#if defined(RTEMS_MULTIPROCESSING)
bool is_global;
#endif
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
a0010fdc: 03a00003 moveq r0, #3
CORE_message_queue_Attributes the_msgq_attributes;
#if defined(RTEMS_MULTIPROCESSING)
bool is_global;
#endif
if ( !rtems_is_name_valid( name ) )
a0010fe0: 0a00002d beq a001109c <rtems_message_queue_create+0xd8>
return RTEMS_INVALID_NAME;
if ( !id )
a0010fe4: e3580000 cmp r8, #0
return RTEMS_INVALID_ADDRESS;
a0010fe8: 03a00009 moveq r0, #9
#endif
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
if ( !id )
a0010fec: 0a00002a beq a001109c <rtems_message_queue_create+0xd8>
if ( (is_global = _Attributes_Is_global( attribute_set ) ) &&
!_System_state_Is_multiprocessing )
return RTEMS_MP_NOT_CONFIGURED;
#endif
if ( count == 0 )
a0010ff0: e3510000 cmp r1, #0
return RTEMS_INVALID_NUMBER;
a0010ff4: 03a0000a moveq r0, #10
if ( (is_global = _Attributes_Is_global( attribute_set ) ) &&
!_System_state_Is_multiprocessing )
return RTEMS_MP_NOT_CONFIGURED;
#endif
if ( count == 0 )
a0010ff8: 0a000027 beq a001109c <rtems_message_queue_create+0xd8>
return RTEMS_INVALID_NUMBER;
if ( max_message_size == 0 )
a0010ffc: e3520000 cmp r2, #0
return RTEMS_INVALID_SIZE;
a0011000: 03a00008 moveq r0, #8
#endif
if ( count == 0 )
return RTEMS_INVALID_NUMBER;
if ( max_message_size == 0 )
a0011004: 0a000024 beq a001109c <rtems_message_queue_create+0xd8>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a0011008: e59f3090 ldr r3, [pc, #144] ; a00110a0 <rtems_message_queue_create+0xdc>
a001100c: e5932000 ldr r2, [r3]
a0011010: e2822001 add r2, r2, #1
a0011014: e5832000 str r2, [r3]
#endif
#endif
_Thread_Disable_dispatch(); /* protects object pointer */
the_message_queue = _Message_queue_Allocate();
a0011018: eb00183c bl a0017110 <_Message_queue_Allocate>
if ( !the_message_queue ) {
a001101c: e2504000 subs r4, r0, #0
a0011020: 1a000002 bne a0011030 <rtems_message_queue_create+0x6c>
_Thread_Enable_dispatch();
a0011024: eb000b8f bl a0013e68 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_TOO_MANY;
a0011028: e3a00005 mov r0, #5 <== NOT EXECUTED
a001102c: ea00001a b a001109c <rtems_message_queue_create+0xd8> <== NOT EXECUTED
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
#endif
the_message_queue->attribute_set = attribute_set;
a0011030: e584a010 str sl, [r4, #16]
if (_Attributes_Is_priority( attribute_set ) )
a0011034: e21aa004 ands sl, sl, #4
the_msgq_attributes.discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_PRIORITY;
a0011038: 13a03001 movne r3, #1
a001103c: 158d3000 strne r3, [sp]
else
the_msgq_attributes.discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_FIFO;
if ( ! _CORE_message_queue_Initialize(
a0011040: e2840014 add r0, r4, #20
a0011044: e1a0100d mov r1, sp
a0011048: e1a02006 mov r2, r6
a001104c: e1a03005 mov r3, r5
the_message_queue->attribute_set = attribute_set;
if (_Attributes_Is_priority( attribute_set ) )
the_msgq_attributes.discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_PRIORITY;
else
the_msgq_attributes.discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_FIFO;
a0011050: 058da000 streq sl, [sp]
if ( ! _CORE_message_queue_Initialize(
a0011054: eb00045f bl a00121d8 <_CORE_message_queue_Initialize>
a0011058: e3500000 cmp r0, #0
a001105c: 1a000005 bne a0011078 <rtems_message_queue_create+0xb4>
*/
RTEMS_INLINE_ROUTINE void _Message_queue_Free (
Message_queue_Control *the_message_queue
)
{
_Objects_Free( &_Message_queue_Information, &the_message_queue->Object );
a0011060: e59f003c ldr r0, [pc, #60] ; a00110a4 <rtems_message_queue_create+0xe0><== NOT EXECUTED
a0011064: e1a01004 mov r1, r4 <== NOT EXECUTED
a0011068: eb000824 bl a0013100 <_Objects_Free> <== NOT EXECUTED
_Objects_MP_Close(
&_Message_queue_Information, the_message_queue->Object.id);
#endif
_Message_queue_Free( the_message_queue );
_Thread_Enable_dispatch();
a001106c: eb000b7d bl a0013e68 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_UNSATISFIED;
a0011070: e3a0000d mov r0, #13 <== NOT EXECUTED
a0011074: ea000008 b a001109c <rtems_message_queue_create+0xd8> <== NOT EXECUTED
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0011078: e59f2024 ldr r2, [pc, #36] ; a00110a4 <rtems_message_queue_create+0xe0>
Objects_Information *information,
Objects_Control *the_object,
Objects_Name name
)
{
_Objects_Set_local_object(
a001107c: e5943008 ldr r3, [r4, #8]
a0011080: e1d410b8 ldrh r1, [r4, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0011084: e592201c ldr r2, [r2, #28]
a0011088: e7824101 str r4, [r2, r1, lsl #2]
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
a001108c: e584700c str r7, [r4, #12]
&_Message_queue_Information,
&the_message_queue->Object,
(Objects_Name) name
);
*id = the_message_queue->Object.id;
a0011090: e5883000 str r3, [r8]
name,
0
);
#endif
_Thread_Enable_dispatch();
a0011094: eb000b73 bl a0013e68 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0011098: e3a00000 mov r0, #0
}
a001109c: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc}
a0015e44 <rtems_message_queue_get_number_pending>:
rtems_status_code rtems_message_queue_get_number_pending(
rtems_id id,
uint32_t *count
)
{
a0015e44: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
register Message_queue_Control *the_message_queue;
Objects_Locations location;
if ( !count )
a0015e48: e2514000 subs r4, r1, #0 <== NOT EXECUTED
rtems_status_code rtems_message_queue_get_number_pending(
rtems_id id,
uint32_t *count
)
{
a0015e4c: e1a03000 mov r3, r0 <== NOT EXECUTED
register Message_queue_Control *the_message_queue;
Objects_Locations location;
if ( !count )
return RTEMS_INVALID_ADDRESS;
a0015e50: 03a00009 moveq r0, #9 <== NOT EXECUTED
)
{
register Message_queue_Control *the_message_queue;
Objects_Locations location;
if ( !count )
a0015e54: 0a00000b beq a0015e88 <rtems_message_queue_get_number_pending+0x44><== NOT EXECUTED
a0015e58: e59f002c ldr r0, [pc, #44] ; a0015e8c <rtems_message_queue_get_number_pending+0x48><== NOT EXECUTED
a0015e5c: e1a01003 mov r1, r3 <== NOT EXECUTED
a0015e60: e1a0200d mov r2, sp <== NOT EXECUTED
a0015e64: eb0013af bl a001ad28 <_Objects_Get> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
the_message_queue = _Message_queue_Get( id, &location );
switch ( location ) {
a0015e68: e59d5000 ldr r5, [sp] <== NOT EXECUTED
a0015e6c: e3550000 cmp r5, #0 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0015e70: 13a00004 movne r0, #4 <== NOT EXECUTED
if ( !count )
return RTEMS_INVALID_ADDRESS;
the_message_queue = _Message_queue_Get( id, &location );
switch ( location ) {
a0015e74: 1a000003 bne a0015e88 <rtems_message_queue_get_number_pending+0x44><== NOT EXECUTED
case OBJECTS_LOCAL:
*count = the_message_queue->message_queue.number_of_pending_messages;
a0015e78: e590305c ldr r3, [r0, #92] ; 0x5c <== NOT EXECUTED
a0015e7c: e5843000 str r3, [r4] <== NOT EXECUTED
_Thread_Enable_dispatch();
a0015e80: eb001684 bl a001b898 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a0015e84: e1a00005 mov r0, r5 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0015e88: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a00110dc <rtems_message_queue_receive>:
void *buffer,
size_t *size,
rtems_option option_set,
rtems_interval timeout
)
{
a00110dc: e92d4077 push {r0, r1, r2, r4, r5, r6, lr}
register Message_queue_Control *the_message_queue;
Objects_Locations location;
bool wait;
if ( !buffer )
a00110e0: e2515000 subs r5, r1, #0
void *buffer,
size_t *size,
rtems_option option_set,
rtems_interval timeout
)
{
a00110e4: e1a0c000 mov ip, r0
a00110e8: e1a04002 mov r4, r2
a00110ec: e1a06003 mov r6, r3
register Message_queue_Control *the_message_queue;
Objects_Locations location;
bool wait;
if ( !buffer )
a00110f0: 0a00001a beq a0011160 <rtems_message_queue_receive+0x84>
return RTEMS_INVALID_ADDRESS;
if ( !size )
a00110f4: e3520000 cmp r2, #0
a00110f8: 0a000018 beq a0011160 <rtems_message_queue_receive+0x84>
Objects_Id id,
Objects_Locations *location
)
{
return (Message_queue_Control *)
_Objects_Get( &_Message_queue_Information, id, location );
a00110fc: e28d2008 add r2, sp, #8
a0011100: e59f0060 ldr r0, [pc, #96] ; a0011168 <rtems_message_queue_receive+0x8c>
a0011104: e1a0100c mov r1, ip
a0011108: eb000854 bl a0013260 <_Objects_Get>
return RTEMS_INVALID_ADDRESS;
the_message_queue = _Message_queue_Get( id, &location );
switch ( location ) {
a001110c: e59d2008 ldr r2, [sp, #8]
a0011110: e1a03000 mov r3, r0
a0011114: e3520000 cmp r2, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0011118: 13a00004 movne r0, #4
if ( !size )
return RTEMS_INVALID_ADDRESS;
the_message_queue = _Message_queue_Get( id, &location );
switch ( location ) {
a001111c: 1a000010 bne a0011164 <rtems_message_queue_receive+0x88>
if ( _Options_Is_no_wait( option_set ) )
wait = false;
else
wait = true;
_CORE_message_queue_Seize(
a0011120: e59d201c ldr r2, [sp, #28]
*/
RTEMS_INLINE_ROUTINE bool _Options_Is_no_wait (
rtems_option option_set
)
{
return (option_set & RTEMS_NO_WAIT) ? true : false;
a0011124: e2066001 and r6, r6, #1
a0011128: e2266001 eor r6, r6, #1
a001112c: e58d2004 str r2, [sp, #4]
a0011130: e58d6000 str r6, [sp]
a0011134: e2830014 add r0, r3, #20
a0011138: e5931008 ldr r1, [r3, #8]
a001113c: e1a02005 mov r2, r5
a0011140: e1a03004 mov r3, r4
a0011144: eb000454 bl a001229c <_CORE_message_queue_Seize>
buffer,
size,
wait,
timeout
);
_Thread_Enable_dispatch();
a0011148: eb000b46 bl a0013e68 <_Thread_Enable_dispatch>
return _Message_queue_Translate_core_message_queue_return_code(
_Thread_Executing->Wait.return_code
a001114c: e59f3018 ldr r3, [pc, #24] ; a001116c <rtems_message_queue_receive+0x90>
a0011150: e5933004 ldr r3, [r3, #4]
size,
wait,
timeout
);
_Thread_Enable_dispatch();
return _Message_queue_Translate_core_message_queue_return_code(
a0011154: e5930034 ldr r0, [r3, #52] ; 0x34
a0011158: eb000023 bl a00111ec <_Message_queue_Translate_core_message_queue_return_code>
a001115c: ea000000 b a0011164 <rtems_message_queue_receive+0x88>
if ( !buffer )
return RTEMS_INVALID_ADDRESS;
if ( !size )
return RTEMS_INVALID_ADDRESS;
a0011160: e3a00009 mov r0, #9 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0011164: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc}
a00096e8 <rtems_object_api_maximum_class>:
int rtems_object_api_maximum_class(
int api
)
{
return _Objects_API_maximum_class(api);
a00096e8: ea000582 b a000acf8 <_Objects_API_maximum_class> <== NOT EXECUTED
a0009700 <rtems_object_get_api_class_name>:
)
{
const rtems_assoc_t *api_assoc;
const rtems_assoc_t *class_assoc;
if ( the_api == OBJECTS_INTERNAL_API )
a0009700: e3500001 cmp r0, #1 <== NOT EXECUTED
const char *rtems_object_get_api_class_name(
int the_api,
int the_class
)
{
a0009704: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
const rtems_assoc_t *api_assoc;
const rtems_assoc_t *class_assoc;
if ( the_api == OBJECTS_INTERNAL_API )
a0009708: 0a000005 beq a0009724 <rtems_object_get_api_class_name+0x24><== NOT EXECUTED
api_assoc = rtems_object_api_internal_assoc;
else if ( the_api == OBJECTS_CLASSIC_API )
a000970c: e3500002 cmp r0, #2 <== NOT EXECUTED
a0009710: 0a000005 beq a000972c <rtems_object_get_api_class_name+0x2c><== NOT EXECUTED
api_assoc = rtems_object_api_classic_assoc;
#ifdef RTEMS_POSIX_API
else if ( the_api == OBJECTS_POSIX_API )
a0009714: e3500003 cmp r0, #3 <== NOT EXECUTED
api_assoc = rtems_object_api_posix_assoc;
a0009718: 059f0034 ldreq r0, [pc, #52] ; a0009754 <rtems_object_get_api_class_name+0x54><== NOT EXECUTED
if ( the_api == OBJECTS_INTERNAL_API )
api_assoc = rtems_object_api_internal_assoc;
else if ( the_api == OBJECTS_CLASSIC_API )
api_assoc = rtems_object_api_classic_assoc;
#ifdef RTEMS_POSIX_API
else if ( the_api == OBJECTS_POSIX_API )
a000971c: 1a000008 bne a0009744 <rtems_object_get_api_class_name+0x44><== NOT EXECUTED
a0009720: ea000002 b a0009730 <rtems_object_get_api_class_name+0x30> <== NOT EXECUTED
{
const rtems_assoc_t *api_assoc;
const rtems_assoc_t *class_assoc;
if ( the_api == OBJECTS_INTERNAL_API )
api_assoc = rtems_object_api_internal_assoc;
a0009724: e59f002c ldr r0, [pc, #44] ; a0009758 <rtems_object_get_api_class_name+0x58><== NOT EXECUTED
a0009728: ea000000 b a0009730 <rtems_object_get_api_class_name+0x30> <== NOT EXECUTED
else if ( the_api == OBJECTS_CLASSIC_API )
api_assoc = rtems_object_api_classic_assoc;
a000972c: e59f0028 ldr r0, [pc, #40] ; a000975c <rtems_object_get_api_class_name+0x5c><== NOT EXECUTED
else if ( the_api == OBJECTS_POSIX_API )
api_assoc = rtems_object_api_posix_assoc;
#endif
else
return "BAD API";
class_assoc = rtems_assoc_ptr_by_local( api_assoc, the_class );
a0009730: eb001270 bl a000e0f8 <rtems_assoc_ptr_by_local> <== NOT EXECUTED
if ( class_assoc )
a0009734: e3500000 cmp r0, #0 <== NOT EXECUTED
return class_assoc->name;
a0009738: 15900000 ldrne r0, [r0] <== NOT EXECUTED
api_assoc = rtems_object_api_posix_assoc;
#endif
else
return "BAD API";
class_assoc = rtems_assoc_ptr_by_local( api_assoc, the_class );
if ( class_assoc )
a000973c: 149df004 popne {pc} ; (ldrne pc, [sp], #4) <== NOT EXECUTED
a0009740: ea000001 b a000974c <rtems_object_get_api_class_name+0x4c> <== NOT EXECUTED
#ifdef RTEMS_POSIX_API
else if ( the_api == OBJECTS_POSIX_API )
api_assoc = rtems_object_api_posix_assoc;
#endif
else
return "BAD API";
a0009744: e59f0014 ldr r0, [pc, #20] ; a0009760 <rtems_object_get_api_class_name+0x60><== NOT EXECUTED
a0009748: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
class_assoc = rtems_assoc_ptr_by_local( api_assoc, the_class );
if ( class_assoc )
return class_assoc->name;
return "BAD CLASS";
a000974c: e59f0010 ldr r0, [pc, #16] ; a0009764 <rtems_object_get_api_class_name+0x64><== NOT EXECUTED
}
a0009750: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a0009768 <rtems_object_get_api_name>:
};
const char *rtems_object_get_api_name(
int api
)
{
a0009768: e1a01000 mov r1, r0 <== NOT EXECUTED
a000976c: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
const rtems_assoc_t *api_assoc;
api_assoc = rtems_assoc_ptr_by_local( rtems_objects_api_assoc, api );
a0009770: e59f0010 ldr r0, [pc, #16] ; a0009788 <rtems_object_get_api_name+0x20><== NOT EXECUTED
a0009774: eb00125f bl a000e0f8 <rtems_assoc_ptr_by_local> <== NOT EXECUTED
if ( api_assoc )
a0009778: e3500000 cmp r0, #0 <== NOT EXECUTED
return api_assoc->name;
a000977c: 15900000 ldrne r0, [r0] <== NOT EXECUTED
return "BAD CLASS";
a0009780: 059f0004 ldreq r0, [pc, #4] ; a000978c <rtems_object_get_api_name+0x24><== NOT EXECUTED
}
a0009784: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a000b11c <rtems_object_get_class_information>:
rtems_status_code rtems_object_get_class_information(
int the_api,
int the_class,
rtems_object_api_class_information *info
)
{
a000b11c: e92d4010 push {r4, lr} <== NOT EXECUTED
int i;
/*
* Validate parameters and look up information structure.
*/
if ( !info )
a000b120: e2524000 subs r4, r2, #0 <== NOT EXECUTED
a000b124: 0a000019 beq a000b190 <rtems_object_get_class_information+0x74><== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
obj_info = _Objects_Get_information( the_api, the_class );
a000b128: e1a01801 lsl r1, r1, #16 <== NOT EXECUTED
a000b12c: e1a01821 lsr r1, r1, #16 <== NOT EXECUTED
a000b130: eb0006a0 bl a000cbb8 <_Objects_Get_information> <== NOT EXECUTED
if ( !obj_info )
a000b134: e3500000 cmp r0, #0 <== NOT EXECUTED
a000b138: 0a000016 beq a000b198 <rtems_object_get_class_information+0x7c><== NOT EXECUTED
return RTEMS_INVALID_NUMBER;
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
a000b13c: e5903008 ldr r3, [r0, #8] <== NOT EXECUTED
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
a000b140: e1d011b0 ldrh r1, [r0, #16] <== NOT EXECUTED
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
a000b144: e3a02000 mov r2, #0 <== NOT EXECUTED
return RTEMS_INVALID_NUMBER;
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
a000b148: e5843000 str r3, [r4] <== NOT EXECUTED
info->maximum_id = obj_info->maximum_id;
a000b14c: e590300c ldr r3, [r0, #12] <== NOT EXECUTED
a000b150: e5843004 str r3, [r4, #4] <== NOT EXECUTED
info->auto_extend = obj_info->auto_extend;
a000b154: e5d03012 ldrb r3, [r0, #18] <== NOT EXECUTED
info->maximum = obj_info->maximum;
a000b158: e5841008 str r1, [r4, #8] <== NOT EXECUTED
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
a000b15c: e5c4300c strb r3, [r4, #12] <== NOT EXECUTED
info->maximum = obj_info->maximum;
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
a000b160: e3a03001 mov r3, #1 <== NOT EXECUTED
a000b164: ea000004 b a000b17c <rtems_object_get_class_information+0x60><== NOT EXECUTED
if ( !obj_info->local_table[i] )
a000b168: e590c01c ldr ip, [r0, #28] <== NOT EXECUTED
a000b16c: e79cc103 ldr ip, [ip, r3, lsl #2] <== NOT EXECUTED
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
a000b170: e2833001 add r3, r3, #1 <== NOT EXECUTED
if ( !obj_info->local_table[i] )
a000b174: e35c0000 cmp ip, #0 <== NOT EXECUTED
unallocated++;
a000b178: 02822001 addeq r2, r2, #1 <== NOT EXECUTED
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
a000b17c: e1530001 cmp r3, r1 <== NOT EXECUTED
a000b180: 9afffff8 bls a000b168 <rtems_object_get_class_information+0x4c><== NOT EXECUTED
if ( !obj_info->local_table[i] )
unallocated++;
info->unallocated = unallocated;
a000b184: e5842010 str r2, [r4, #16] <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a000b188: e3a00000 mov r0, #0 <== NOT EXECUTED
a000b18c: e8bd8010 pop {r4, pc} <== NOT EXECUTED
/*
* Validate parameters and look up information structure.
*/
if ( !info )
return RTEMS_INVALID_ADDRESS;
a000b190: e3a00009 mov r0, #9 <== NOT EXECUTED
a000b194: e8bd8010 pop {r4, pc} <== NOT EXECUTED
obj_info = _Objects_Get_information( the_api, the_class );
if ( !obj_info )
return RTEMS_INVALID_NUMBER;
a000b198: e3a0000a mov r0, #10 <== NOT EXECUTED
unallocated++;
info->unallocated = unallocated;
return RTEMS_SUCCESSFUL;
}
a000b19c: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a000b1a4 <rtems_object_id_api_maximum>:
#undef rtems_object_id_api_maximum
int rtems_object_id_api_maximum(void)
{
return OBJECTS_APIS_LAST;
}
a000b1a4: e3a00003 mov r0, #3 <== NOT EXECUTED
a000b1a8: e12fff1e bx lr <== NOT EXECUTED
a000b1ac <rtems_object_id_api_minimum>:
#undef rtems_object_id_api_minimum
int rtems_object_id_api_minimum(void)
{
return OBJECTS_INTERNAL_API;
}
a000b1ac: e3a00001 mov r0, #1 <== NOT EXECUTED
a000b1b0: e12fff1e bx lr <== NOT EXECUTED
a000b1b4 <rtems_object_id_get_api>:
*/
RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API(
Objects_Id id
)
{
return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS);
a000b1b4: e1a00c20 lsr r0, r0, #24 <== NOT EXECUTED
int rtems_object_id_get_api(
rtems_id id
)
{
return _Objects_Get_API( id );
}
a000b1b8: e2000007 and r0, r0, #7 <== NOT EXECUTED
a000b1bc: e12fff1e bx lr <== NOT EXECUTED
a000b1c0 <rtems_object_id_get_class>:
int rtems_object_id_get_class(
rtems_id id
)
{
return _Objects_Get_class( id );
}
a000b1c0: e1a00da0 lsr r0, r0, #27 <== NOT EXECUTED
a000b1c4: e12fff1e bx lr <== NOT EXECUTED
a000b1c8 <rtems_object_id_get_index>:
#undef rtems_object_id_get_index
int rtems_object_id_get_index(
rtems_id id
)
{
return _Objects_Get_index( id );
a000b1c8: e1a00800 lsl r0, r0, #16 <== NOT EXECUTED
}
a000b1cc: e1a00820 lsr r0, r0, #16 <== NOT EXECUTED
a000b1d0: e12fff1e bx lr <== NOT EXECUTED
a000b1d4 <rtems_object_id_get_node>:
* be a single processor system.
*/
#if defined(RTEMS_USE_16_BIT_OBJECT)
return 1;
#else
return (id >> OBJECTS_NODE_START_BIT) & OBJECTS_NODE_VALID_BITS;
a000b1d4: e1a00820 lsr r0, r0, #16 <== NOT EXECUTED
int rtems_object_id_get_node(
rtems_id id
)
{
return _Objects_Get_node( id );
}
a000b1d8: e20000ff and r0, r0, #255 ; 0xff <== NOT EXECUTED
a000b1dc: e12fff1e bx lr <== NOT EXECUTED
a0009794 <rtems_object_set_name>:
*/
rtems_status_code rtems_object_set_name(
rtems_id id,
const char *name
)
{
a0009794: e92d4071 push {r0, r4, r5, r6, lr}
Objects_Information *information;
Objects_Locations location;
Objects_Control *the_object;
Objects_Id tmpId;
if ( !name )
a0009798: e2515000 subs r5, r1, #0
return RTEMS_INVALID_ADDRESS;
a000979c: 03a00009 moveq r0, #9
Objects_Information *information;
Objects_Locations location;
Objects_Control *the_object;
Objects_Id tmpId;
if ( !name )
a00097a0: 0a000016 beq a0009800 <rtems_object_set_name+0x6c>
return RTEMS_INVALID_ADDRESS;
tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id;
a00097a4: e3500000 cmp r0, #0
a00097a8: 059f3054 ldreq r3, [pc, #84] ; a0009804 <rtems_object_set_name+0x70>
a00097ac: 11a04000 movne r4, r0
a00097b0: 05933004 ldreq r3, [r3, #4]
a00097b4: 05934008 ldreq r4, [r3, #8]
information = _Objects_Get_information_id( tmpId );
a00097b8: e1a00004 mov r0, r4
a00097bc: eb000619 bl a000b028 <_Objects_Get_information_id>
if ( !information )
a00097c0: e2506000 subs r6, r0, #0
a00097c4: 0a00000c beq a00097fc <rtems_object_set_name+0x68>
return RTEMS_INVALID_ID;
the_object = _Objects_Get( information, tmpId, &location );
a00097c8: e1a01004 mov r1, r4
a00097cc: e1a0200d mov r2, sp
a00097d0: eb000690 bl a000b218 <_Objects_Get>
switch ( location ) {
a00097d4: e59d4000 ldr r4, [sp]
information = _Objects_Get_information_id( tmpId );
if ( !information )
return RTEMS_INVALID_ID;
the_object = _Objects_Get( information, tmpId, &location );
a00097d8: e1a01000 mov r1, r0
switch ( location ) {
a00097dc: e3540000 cmp r4, #0
a00097e0: 1a000005 bne a00097fc <rtems_object_set_name+0x68>
case OBJECTS_LOCAL:
_Objects_Set_name( information, the_object, name );
a00097e4: e1a02005 mov r2, r5
a00097e8: e1a00006 mov r0, r6
a00097ec: eb0006e7 bl a000b390 <_Objects_Set_name>
_Thread_Enable_dispatch();
a00097f0: eb000972 bl a000bdc0 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a00097f4: e1a00004 mov r0, r4
a00097f8: ea000000 b a0009800 <rtems_object_set_name+0x6c>
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a00097fc: e3a00004 mov r0, #4 <== NOT EXECUTED
}
a0009800: e8bd8078 pop {r3, r4, r5, r6, pc}
a0016060 <rtems_partition_create>:
uint32_t length,
uint32_t buffer_size,
rtems_attribute attribute_set,
rtems_id *id
)
{
a0016060: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
register Partition_Control *the_partition;
if ( !rtems_is_name_valid( name ) )
a0016064: e2508000 subs r8, r0, #0
uint32_t length,
uint32_t buffer_size,
rtems_attribute attribute_set,
rtems_id *id
)
{
a0016068: e1a05001 mov r5, r1
a001606c: e1a09002 mov r9, r2
a0016070: e1a0a003 mov sl, r3
register Partition_Control *the_partition;
if ( !rtems_is_name_valid( name ) )
a0016074: 0a000032 beq a0016144 <rtems_partition_create+0xe4>
return RTEMS_INVALID_NAME;
if ( !starting_address )
a0016078: e3510000 cmp r1, #0
a001607c: 0a000032 beq a001614c <rtems_partition_create+0xec>
return RTEMS_INVALID_ADDRESS;
if ( !id )
a0016080: e59d2028 ldr r2, [sp, #40] ; 0x28
a0016084: e3520000 cmp r2, #0
a0016088: 0a00002f beq a001614c <rtems_partition_create+0xec>
return RTEMS_INVALID_ADDRESS;
if ( length == 0 || buffer_size == 0 || length < buffer_size ||
a001608c: e3590000 cmp r9, #0
a0016090: 13530000 cmpne r3, #0
a0016094: 0a00002e beq a0016154 <rtems_partition_create+0xf4>
a0016098: e1590003 cmp r9, r3
a001609c: 3a00002c bcc a0016154 <rtems_partition_create+0xf4>
a00160a0: e3130007 tst r3, #7
a00160a4: 1a00002a bne a0016154 <rtems_partition_create+0xf4>
!_Partition_Is_buffer_size_aligned( buffer_size ) )
return RTEMS_INVALID_SIZE;
if ( !_Addresses_Is_aligned( starting_address ) )
a00160a8: e2116007 ands r6, r1, #7
a00160ac: 1a00002a bne a001615c <rtems_partition_create+0xfc>
a00160b0: e59f30ac ldr r3, [pc, #172] ; a0016164 <rtems_partition_create+0x104>
a00160b4: e5932000 ldr r2, [r3]
a00160b8: e2822001 add r2, r2, #1
a00160bc: e5832000 str r2, [r3]
* This function allocates a partition control block from
* the inactive chain of free partition control blocks.
*/
RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Allocate ( void )
{
return (Partition_Control *) _Objects_Allocate( &_Partition_Information );
a00160c0: e59f70a0 ldr r7, [pc, #160] ; a0016168 <rtems_partition_create+0x108>
a00160c4: e1a00007 mov r0, r7
a00160c8: eb0011e5 bl a001a864 <_Objects_Allocate>
_Thread_Disable_dispatch(); /* prevents deletion */
the_partition = _Partition_Allocate();
if ( !the_partition ) {
a00160cc: e2504000 subs r4, r0, #0
a00160d0: 1a000002 bne a00160e0 <rtems_partition_create+0x80>
_Thread_Enable_dispatch();
a00160d4: eb0015ef bl a001b898 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_TOO_MANY;
a00160d8: e3a00005 mov r0, #5 <== NOT EXECUTED
a00160dc: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
#endif
the_partition->starting_address = starting_address;
the_partition->length = length;
the_partition->buffer_size = buffer_size;
the_partition->attribute_set = attribute_set;
a00160e0: e59d3024 ldr r3, [sp, #36] ; 0x24
the_partition->number_of_used_blocks = 0;
_Chain_Initialize( &the_partition->Memory, starting_address,
a00160e4: e1a0100a mov r1, sl
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
#endif
the_partition->starting_address = starting_address;
a00160e8: e5845010 str r5, [r4, #16]
the_partition->length = length;
the_partition->buffer_size = buffer_size;
the_partition->attribute_set = attribute_set;
a00160ec: e584301c str r3, [r4, #28]
return RTEMS_TOO_MANY;
}
#endif
the_partition->starting_address = starting_address;
the_partition->length = length;
a00160f0: e5849014 str r9, [r4, #20]
the_partition->buffer_size = buffer_size;
a00160f4: e584a018 str sl, [r4, #24]
the_partition->attribute_set = attribute_set;
the_partition->number_of_used_blocks = 0;
a00160f8: e5846020 str r6, [r4, #32]
_Chain_Initialize( &the_partition->Memory, starting_address,
a00160fc: e1a00009 mov r0, r9
a0016100: eb0061f6 bl a002e8e0 <__aeabi_uidiv>
a0016104: e284b024 add fp, r4, #36 ; 0x24
a0016108: e1a02000 mov r2, r0
a001610c: e1a01005 mov r1, r5
a0016110: e1a0000b mov r0, fp
a0016114: e1a0300a mov r3, sl
a0016118: eb000beb bl a00190cc <_Chain_Initialize>
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a001611c: e597201c ldr r2, [r7, #28]
Objects_Information *information,
Objects_Control *the_object,
Objects_Name name
)
{
_Objects_Set_local_object(
a0016120: e1d410b8 ldrh r1, [r4, #8]
a0016124: e5943008 ldr r3, [r4, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0016128: e7824101 str r4, [r2, r1, lsl #2]
&_Partition_Information,
&the_partition->Object,
(Objects_Name) name
);
*id = the_partition->Object.id;
a001612c: e59d2028 ldr r2, [sp, #40] ; 0x28
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
a0016130: e584800c str r8, [r4, #12]
a0016134: e5823000 str r3, [r2]
name,
0 /* Not used */
);
#endif
_Thread_Enable_dispatch();
a0016138: eb0015d6 bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a001613c: e1a00006 mov r0, r6
a0016140: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
)
{
register Partition_Control *the_partition;
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
a0016144: e3a00003 mov r0, #3 <== NOT EXECUTED
a0016148: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
if ( !starting_address )
return RTEMS_INVALID_ADDRESS;
if ( !id )
return RTEMS_INVALID_ADDRESS;
a001614c: e3a00009 mov r0, #9 <== NOT EXECUTED
a0016150: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
if ( length == 0 || buffer_size == 0 || length < buffer_size ||
!_Partition_Is_buffer_size_aligned( buffer_size ) )
return RTEMS_INVALID_SIZE;
a0016154: e3a00008 mov r0, #8 <== NOT EXECUTED
a0016158: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
if ( !_Addresses_Is_aligned( starting_address ) )
return RTEMS_INVALID_ADDRESS;
a001615c: e3a00009 mov r0, #9 <== NOT EXECUTED
);
#endif
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
a0016160: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
a001616c <rtems_partition_delete>:
*/
rtems_status_code rtems_partition_delete(
rtems_id id
)
{
a001616c: e92d4031 push {r0, r4, r5, lr}
a0016170: e1a01000 mov r1, r0
Objects_Id id,
Objects_Locations *location
)
{
return (Partition_Control *)
_Objects_Get( &_Partition_Information, id, location );
a0016174: e1a0200d mov r2, sp
a0016178: e59f0050 ldr r0, [pc, #80] ; a00161d0 <rtems_partition_delete+0x64>
a001617c: eb0012e9 bl a001ad28 <_Objects_Get>
register Partition_Control *the_partition;
Objects_Locations location;
the_partition = _Partition_Get( id, &location );
switch ( location ) {
a0016180: e59d3000 ldr r3, [sp]
a0016184: e1a04000 mov r4, r0
a0016188: e3530000 cmp r3, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a001618c: 13a00004 movne r0, #4
{
register Partition_Control *the_partition;
Objects_Locations location;
the_partition = _Partition_Get( id, &location );
switch ( location ) {
a0016190: 1a00000d bne a00161cc <rtems_partition_delete+0x60>
case OBJECTS_LOCAL:
if ( the_partition->number_of_used_blocks == 0 ) {
a0016194: e5945020 ldr r5, [r4, #32]
a0016198: e3550000 cmp r5, #0
a001619c: 1a000008 bne a00161c4 <rtems_partition_delete+0x58>
_Objects_Close( &_Partition_Information, &the_partition->Object );
a00161a0: e59f0028 ldr r0, [pc, #40] ; a00161d0 <rtems_partition_delete+0x64>
a00161a4: e1a01004 mov r1, r4
a00161a8: eb0011cf bl a001a8ec <_Objects_Close>
*/
RTEMS_INLINE_ROUTINE void _Partition_Free (
Partition_Control *the_partition
)
{
_Objects_Free( &_Partition_Information, &the_partition->Object );
a00161ac: e59f001c ldr r0, [pc, #28] ; a00161d0 <rtems_partition_delete+0x64>
a00161b0: e1a01004 mov r1, r4
a00161b4: eb001273 bl a001ab88 <_Objects_Free>
0 /* Not used */
);
}
#endif
_Thread_Enable_dispatch();
a00161b8: eb0015b6 bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a00161bc: e1a00005 mov r0, r5
a00161c0: ea000001 b a00161cc <rtems_partition_delete+0x60>
}
_Thread_Enable_dispatch();
a00161c4: eb0015b3 bl a001b898 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_RESOURCE_IN_USE;
a00161c8: e3a0000c mov r0, #12 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a00161cc: e8bd8038 pop {r3, r4, r5, pc}
a001627c <rtems_partition_return_buffer>:
rtems_status_code rtems_partition_return_buffer(
rtems_id id,
void *buffer
)
{
a001627c: e92d4071 push {r0, r4, r5, r6, lr}
a0016280: e1a03000 mov r3, r0
a0016284: e1a04001 mov r4, r1
Objects_Id id,
Objects_Locations *location
)
{
return (Partition_Control *)
_Objects_Get( &_Partition_Information, id, location );
a0016288: e59f0088 ldr r0, [pc, #136] ; a0016318 <rtems_partition_return_buffer+0x9c>
a001628c: e1a01003 mov r1, r3
a0016290: e1a0200d mov r2, sp
a0016294: eb0012a3 bl a001ad28 <_Objects_Get>
register Partition_Control *the_partition;
Objects_Locations location;
the_partition = _Partition_Get( id, &location );
switch ( location ) {
a0016298: e59d3000 ldr r3, [sp]
a001629c: e1a05000 mov r5, r0
a00162a0: e3530000 cmp r3, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a00162a4: 13a00004 movne r0, #4
{
register Partition_Control *the_partition;
Objects_Locations location;
the_partition = _Partition_Get( id, &location );
switch ( location ) {
a00162a8: 1a000016 bne a0016308 <rtems_partition_return_buffer+0x8c>
)
{
void *starting;
void *ending;
starting = the_partition->starting_address;
a00162ac: e5950010 ldr r0, [r5, #16]
a00162b0: e5953014 ldr r3, [r5, #20]
a00162b4: e0803003 add r3, r0, r3
const void *address,
const void *base,
const void *limit
)
{
return (address >= base && address <= limit);
a00162b8: e1540003 cmp r4, r3
a00162bc: 83a03000 movhi r3, #0
a00162c0: 93a03001 movls r3, #1
a00162c4: e1540000 cmp r4, r0
a00162c8: 33a03000 movcc r3, #0
ending = _Addresses_Add_offset( starting, the_partition->length );
return (
_Addresses_Is_in_range( the_buffer, starting, ending ) &&
a00162cc: e3530000 cmp r3, #0
a00162d0: 0a00000d beq a001630c <rtems_partition_return_buffer+0x90>
offset = (uint32_t) _Addresses_Subtract(
the_buffer,
the_partition->starting_address
);
return ((offset % the_partition->buffer_size) == 0);
a00162d4: e0600004 rsb r0, r0, r4
a00162d8: e5951018 ldr r1, [r5, #24]
a00162dc: eb006217 bl a002eb40 <__umodsi3>
starting = the_partition->starting_address;
ending = _Addresses_Add_offset( starting, the_partition->length );
return (
_Addresses_Is_in_range( the_buffer, starting, ending ) &&
a00162e0: e2506000 subs r6, r0, #0
a00162e4: 1a000008 bne a001630c <rtems_partition_return_buffer+0x90>
RTEMS_INLINE_ROUTINE void _Partition_Free_buffer (
Partition_Control *the_partition,
Chain_Node *the_buffer
)
{
_Chain_Append( &the_partition->Memory, the_buffer );
a00162e8: e2850024 add r0, r5, #36 ; 0x24
a00162ec: e1a01004 mov r1, r4
a00162f0: eb000b55 bl a001904c <_Chain_Append>
case OBJECTS_LOCAL:
if ( _Partition_Is_buffer_valid( buffer, the_partition ) ) {
_Partition_Free_buffer( the_partition, buffer );
the_partition->number_of_used_blocks -= 1;
a00162f4: e5953020 ldr r3, [r5, #32]
a00162f8: e2433001 sub r3, r3, #1
a00162fc: e5853020 str r3, [r5, #32]
_Thread_Enable_dispatch();
a0016300: eb001564 bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0016304: e1a00006 mov r0, r6
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0016308: e8bd8078 pop {r3, r4, r5, r6, pc}
_Partition_Free_buffer( the_partition, buffer );
the_partition->number_of_used_blocks -= 1;
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
_Thread_Enable_dispatch();
a001630c: eb001561 bl a001b898 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
a0016310: e3a00009 mov r0, #9 <== NOT EXECUTED
a0016314: eafffffb b a0016308 <rtems_partition_return_buffer+0x8c> <== NOT EXECUTED
a00156c0 <rtems_port_create>:
void *internal_start,
void *external_start,
uint32_t length,
rtems_id *id
)
{
a00156c0: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr}
register Dual_ported_memory_Control *the_port;
if ( !rtems_is_name_valid( name ) )
a00156c4: e250a000 subs sl, r0, #0
void *internal_start,
void *external_start,
uint32_t length,
rtems_id *id
)
{
a00156c8: e1a04001 mov r4, r1
a00156cc: e1a05002 mov r5, r2
a00156d0: e1a09003 mov r9, r3
a00156d4: e59d6020 ldr r6, [sp, #32]
register Dual_ported_memory_Control *the_port;
if ( !rtems_is_name_valid( name ) )
a00156d8: 0a00001d beq a0015754 <rtems_port_create+0x94>
return RTEMS_INVALID_NAME;
if ( !id )
a00156dc: e3560000 cmp r6, #0
a00156e0: 0a00001d beq a001575c <rtems_port_create+0x9c>
* id - port id
* RTEMS_SUCCESSFUL - if successful
* error code - if unsuccessful
*/
rtems_status_code rtems_port_create(
a00156e4: e1828001 orr r8, r2, r1
return RTEMS_INVALID_NAME;
if ( !id )
return RTEMS_INVALID_ADDRESS;
if ( !_Addresses_Is_aligned( internal_start ) ||
a00156e8: e2188007 ands r8, r8, #7
a00156ec: 1a00001c bne a0015764 <rtems_port_create+0xa4>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a00156f0: e59f3074 ldr r3, [pc, #116] ; a001576c <rtems_port_create+0xac>
a00156f4: e5932000 ldr r2, [r3]
a00156f8: e2822001 add r2, r2, #1
a00156fc: e5832000 str r2, [r3]
*/
RTEMS_INLINE_ROUTINE Dual_ported_memory_Control
*_Dual_ported_memory_Allocate ( void )
{
return (Dual_ported_memory_Control *)
_Objects_Allocate( &_Dual_ported_memory_Information );
a0015700: e59f7068 ldr r7, [pc, #104] ; a0015770 <rtems_port_create+0xb0>
a0015704: e1a00007 mov r0, r7
a0015708: eb001455 bl a001a864 <_Objects_Allocate>
_Thread_Disable_dispatch(); /* to prevent deletion */
the_port = _Dual_ported_memory_Allocate();
if ( !the_port ) {
a001570c: e3500000 cmp r0, #0
a0015710: 1a000002 bne a0015720 <rtems_port_create+0x60>
_Thread_Enable_dispatch();
a0015714: eb00185f bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_TOO_MANY;
a0015718: e3a00005 mov r0, #5
a001571c: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc}
Objects_Information *information,
Objects_Control *the_object,
Objects_Name name
)
{
_Objects_Set_local_object(
a0015720: e5903008 ldr r3, [r0, #8]
a0015724: e1d010b8 ldrh r1, [r0, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0015728: e597201c ldr r2, [r7, #28]
}
the_port->internal_base = internal_start;
the_port->external_base = external_start;
the_port->length = length - 1;
a001572c: e2499001 sub r9, r9, #1
if ( !the_port ) {
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
the_port->internal_base = internal_start;
a0015730: e5804010 str r4, [r0, #16]
the_port->external_base = external_start;
a0015734: e5805014 str r5, [r0, #20]
the_port->length = length - 1;
a0015738: e5809018 str r9, [r0, #24]
a001573c: e7820101 str r0, [r2, r1, lsl #2]
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
a0015740: e580a00c str sl, [r0, #12]
&_Dual_ported_memory_Information,
&the_port->Object,
(Objects_Name) name
);
*id = the_port->Object.id;
a0015744: e5863000 str r3, [r6]
_Thread_Enable_dispatch();
a0015748: eb001852 bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a001574c: e1a00008 mov r0, r8
a0015750: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc}
)
{
register Dual_ported_memory_Control *the_port;
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
a0015754: e3a00003 mov r0, #3 <== NOT EXECUTED
a0015758: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED
if ( !id )
return RTEMS_INVALID_ADDRESS;
a001575c: e3a00009 mov r0, #9 <== NOT EXECUTED
a0015760: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED
if ( !_Addresses_Is_aligned( internal_start ) ||
!_Addresses_Is_aligned( external_start ) )
return RTEMS_INVALID_ADDRESS;
a0015764: e3a00009 mov r0, #9 <== NOT EXECUTED
);
*id = the_port->Object.id;
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
a0015768: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED
a001631c <rtems_rate_monotonic_cancel>:
*/
rtems_status_code rtems_rate_monotonic_cancel(
rtems_id id
)
{
a001631c: e92d4031 push {r0, r4, r5, lr}
a0016320: e1a01000 mov r1, r0
Objects_Id id,
Objects_Locations *location
)
{
return (Rate_monotonic_Control *)
_Objects_Get( &_Rate_monotonic_Information, id, location );
a0016324: e1a0200d mov r2, sp
a0016328: e59f004c ldr r0, [pc, #76] ; a001637c <rtems_rate_monotonic_cancel+0x60>
a001632c: eb00127d bl a001ad28 <_Objects_Get>
Rate_monotonic_Control *the_period;
Objects_Locations location;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a0016330: e59d4000 ldr r4, [sp]
a0016334: e1a05000 mov r5, r0
a0016338: e3540000 cmp r4, #0
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a001633c: 13a00004 movne r0, #4
{
Rate_monotonic_Control *the_period;
Objects_Locations location;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a0016340: 1a00000c bne a0016378 <rtems_rate_monotonic_cancel+0x5c>
case OBJECTS_LOCAL:
if ( !_Thread_Is_executing( the_period->owner ) ) {
a0016344: e59f3034 ldr r3, [pc, #52] ; a0016380 <rtems_rate_monotonic_cancel+0x64>
a0016348: e5952040 ldr r2, [r5, #64] ; 0x40
a001634c: e5933004 ldr r3, [r3, #4]
a0016350: e1520003 cmp r2, r3
a0016354: 0a000002 beq a0016364 <rtems_rate_monotonic_cancel+0x48>
_Thread_Enable_dispatch();
a0016358: eb00154e bl a001b898 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_NOT_OWNER_OF_RESOURCE;
a001635c: e3a00017 mov r0, #23 <== NOT EXECUTED
a0016360: ea000004 b a0016378 <rtems_rate_monotonic_cancel+0x5c> <== NOT EXECUTED
}
(void) _Watchdog_Remove( &the_period->Timer );
a0016364: e2850010 add r0, r5, #16
a0016368: eb0019ed bl a001cb24 <_Watchdog_Remove>
the_period->state = RATE_MONOTONIC_INACTIVE;
a001636c: e5854038 str r4, [r5, #56] ; 0x38
_Thread_Enable_dispatch();
a0016370: eb001548 bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0016374: e1a00004 mov r0, r4
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0016378: e8bd8038 pop {r3, r4, r5, pc}
a000a180 <rtems_rate_monotonic_create>:
rtems_status_code rtems_rate_monotonic_create(
rtems_name name,
rtems_id *id
)
{
a000a180: e92d41f0 push {r4, r5, r6, r7, r8, lr}
Rate_monotonic_Control *the_period;
if ( !rtems_is_name_valid( name ) )
a000a184: e2508000 subs r8, r0, #0
rtems_status_code rtems_rate_monotonic_create(
rtems_name name,
rtems_id *id
)
{
a000a188: e1a06001 mov r6, r1
Rate_monotonic_Control *the_period;
if ( !rtems_is_name_valid( name ) )
a000a18c: 0a000028 beq a000a234 <rtems_rate_monotonic_create+0xb4>
return RTEMS_INVALID_NAME;
if ( !id )
a000a190: e3510000 cmp r1, #0
a000a194: 0a000028 beq a000a23c <rtems_rate_monotonic_create+0xbc>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000a198: e59f30a4 ldr r3, [pc, #164] ; a000a244 <rtems_rate_monotonic_create+0xc4>
a000a19c: e5932000 ldr r2, [r3]
a000a1a0: e2822001 add r2, r2, #1
a000a1a4: e5832000 str r2, [r3]
* the inactive chain of free period control blocks.
*/
RTEMS_INLINE_ROUTINE Rate_monotonic_Control *_Rate_monotonic_Allocate( void )
{
return (Rate_monotonic_Control *)
_Objects_Allocate( &_Rate_monotonic_Information );
a000a1a8: e59f7098 ldr r7, [pc, #152] ; a000a248 <rtems_rate_monotonic_create+0xc8>
a000a1ac: e1a00007 mov r0, r7
a000a1b0: eb0007aa bl a000c060 <_Objects_Allocate>
_Thread_Disable_dispatch(); /* to prevent deletion */
the_period = _Rate_monotonic_Allocate();
if ( !the_period ) {
a000a1b4: e2504000 subs r4, r0, #0
a000a1b8: 1a000002 bne a000a1c8 <rtems_rate_monotonic_create+0x48>
_Thread_Enable_dispatch();
a000a1bc: eb000be6 bl a000d15c <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_TOO_MANY;
a000a1c0: e3a00005 mov r0, #5 <== NOT EXECUTED
a000a1c4: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
}
the_period->owner = _Thread_Executing;
a000a1c8: e59f307c ldr r3, [pc, #124] ; a000a24c <rtems_rate_monotonic_create+0xcc>
the_period->state = RATE_MONOTONIC_INACTIVE;
a000a1cc: e3a05000 mov r5, #0
_Watchdog_Initialize( &the_period->Timer, NULL, 0, NULL );
_Rate_monotonic_Reset_statistics( the_period );
a000a1d0: e1a01005 mov r1, r5
if ( !the_period ) {
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
the_period->owner = _Thread_Executing;
a000a1d4: e5933004 ldr r3, [r3, #4]
the_period->state = RATE_MONOTONIC_INACTIVE;
_Watchdog_Initialize( &the_period->Timer, NULL, 0, NULL );
_Rate_monotonic_Reset_statistics( the_period );
a000a1d8: e3a02038 mov r2, #56 ; 0x38
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
the_period->owner = _Thread_Executing;
the_period->state = RATE_MONOTONIC_INACTIVE;
a000a1dc: e5845038 str r5, [r4, #56] ; 0x38
if ( !the_period ) {
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
the_period->owner = _Thread_Executing;
a000a1e0: e5843040 str r3, [r4, #64] ; 0x40
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a000a1e4: e5845018 str r5, [r4, #24]
the_watchdog->routine = routine;
a000a1e8: e584502c str r5, [r4, #44] ; 0x2c
the_watchdog->id = id;
a000a1ec: e5845030 str r5, [r4, #48] ; 0x30
the_watchdog->user_data = user_data;
a000a1f0: e5845034 str r5, [r4, #52] ; 0x34
the_period->state = RATE_MONOTONIC_INACTIVE;
_Watchdog_Initialize( &the_period->Timer, NULL, 0, NULL );
_Rate_monotonic_Reset_statistics( the_period );
a000a1f4: e2840054 add r0, r4, #84 ; 0x54
a000a1f8: eb002554 bl a0013750 <memset>
a000a1fc: e3e03102 mvn r3, #-2147483648 ; 0x80000000
a000a200: e584305c str r3, [r4, #92] ; 0x5c
a000a204: e5843060 str r3, [r4, #96] ; 0x60
a000a208: e5843074 str r3, [r4, #116] ; 0x74
a000a20c: e5843078 str r3, [r4, #120] ; 0x78
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000a210: e597201c ldr r2, [r7, #28]
Objects_Information *information,
Objects_Control *the_object,
Objects_Name name
)
{
_Objects_Set_local_object(
a000a214: e5943008 ldr r3, [r4, #8]
a000a218: e1d410b8 ldrh r1, [r4, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a000a21c: e7824101 str r4, [r2, r1, lsl #2]
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
a000a220: e584800c str r8, [r4, #12]
&_Rate_monotonic_Information,
&the_period->Object,
(Objects_Name) name
);
*id = the_period->Object.id;
a000a224: e5863000 str r3, [r6]
_Thread_Enable_dispatch();
a000a228: eb000bcb bl a000d15c <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000a22c: e1a00005 mov r0, r5
a000a230: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
)
{
Rate_monotonic_Control *the_period;
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
a000a234: e3a00003 mov r0, #3 <== NOT EXECUTED
a000a238: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
if ( !id )
return RTEMS_INVALID_ADDRESS;
a000a23c: e3a00009 mov r0, #9 <== NOT EXECUTED
);
*id = the_period->Object.id;
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
a000a240: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
a001062c <rtems_rate_monotonic_get_statistics>:
rtems_status_code rtems_rate_monotonic_get_statistics(
rtems_id id,
rtems_rate_monotonic_period_statistics *statistics
)
{
a001062c: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
Objects_Locations location;
Rate_monotonic_Control *the_period;
rtems_rate_monotonic_period_statistics *dst;
Rate_monotonic_Statistics *src;
if ( !statistics )
a0010630: e2514000 subs r4, r1, #0 <== NOT EXECUTED
rtems_status_code rtems_rate_monotonic_get_statistics(
rtems_id id,
rtems_rate_monotonic_period_statistics *statistics
)
{
a0010634: e1a03000 mov r3, r0 <== NOT EXECUTED
Rate_monotonic_Control *the_period;
rtems_rate_monotonic_period_statistics *dst;
Rate_monotonic_Statistics *src;
if ( !statistics )
return RTEMS_INVALID_ADDRESS;
a0010638: 03a00009 moveq r0, #9 <== NOT EXECUTED
Objects_Locations location;
Rate_monotonic_Control *the_period;
rtems_rate_monotonic_period_statistics *dst;
Rate_monotonic_Statistics *src;
if ( !statistics )
a001063c: 0a000025 beq a00106d8 <rtems_rate_monotonic_get_statistics+0xac><== NOT EXECUTED
a0010640: e59f0094 ldr r0, [pc, #148] ; a00106dc <rtems_rate_monotonic_get_statistics+0xb0><== NOT EXECUTED
a0010644: e1a01003 mov r1, r3 <== NOT EXECUTED
a0010648: e1a0200d mov r2, sp <== NOT EXECUTED
a001064c: ebffefe6 bl a000c5ec <_Objects_Get> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a0010650: e59d5000 ldr r5, [sp] <== NOT EXECUTED
a0010654: e3550000 cmp r5, #0 <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0010658: 13a00004 movne r0, #4 <== NOT EXECUTED
if ( !statistics )
return RTEMS_INVALID_ADDRESS;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a001065c: 1a00001d bne a00106d8 <rtems_rate_monotonic_get_statistics+0xac><== NOT EXECUTED
case OBJECTS_LOCAL:
dst = statistics;
src = &the_period->Statistics;
dst->count = src->count;
a0010660: e5903054 ldr r3, [r0, #84] ; 0x54 <== NOT EXECUTED
a0010664: e5843000 str r3, [r4] <== NOT EXECUTED
dst->missed_count = src->missed_count;
a0010668: e5903058 ldr r3, [r0, #88] ; 0x58 <== NOT EXECUTED
a001066c: e5843004 str r3, [r4, #4] <== NOT EXECUTED
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
_Timestamp_To_timespec( &src->min_cpu_time, &dst->min_cpu_time );
a0010670: e280305c add r3, r0, #92 ; 0x5c <== NOT EXECUTED
a0010674: e893000c ldm r3, {r2, r3} <== NOT EXECUTED
a0010678: e5842008 str r2, [r4, #8] <== NOT EXECUTED
a001067c: e584300c str r3, [r4, #12] <== NOT EXECUTED
_Timestamp_To_timespec( &src->max_cpu_time, &dst->max_cpu_time );
a0010680: e2803064 add r3, r0, #100 ; 0x64 <== NOT EXECUTED
a0010684: e893000c ldm r3, {r2, r3} <== NOT EXECUTED
a0010688: e5842010 str r2, [r4, #16] <== NOT EXECUTED
a001068c: e5843014 str r3, [r4, #20] <== NOT EXECUTED
_Timestamp_To_timespec( &src->total_cpu_time, &dst->total_cpu_time );
a0010690: e280306c add r3, r0, #108 ; 0x6c <== NOT EXECUTED
a0010694: e893000c ldm r3, {r2, r3} <== NOT EXECUTED
a0010698: e5842018 str r2, [r4, #24] <== NOT EXECUTED
a001069c: e584301c str r3, [r4, #28] <== NOT EXECUTED
_Timestamp_To_timespec( &src->min_wall_time, &dst->min_wall_time );
a00106a0: e2803074 add r3, r0, #116 ; 0x74 <== NOT EXECUTED
a00106a4: e893000c ldm r3, {r2, r3} <== NOT EXECUTED
a00106a8: e5842020 str r2, [r4, #32] <== NOT EXECUTED
a00106ac: e5843024 str r3, [r4, #36] ; 0x24 <== NOT EXECUTED
_Timestamp_To_timespec( &src->max_wall_time, &dst->max_wall_time );
a00106b0: e280307c add r3, r0, #124 ; 0x7c <== NOT EXECUTED
a00106b4: e893000c ldm r3, {r2, r3} <== NOT EXECUTED
a00106b8: e5842028 str r2, [r4, #40] ; 0x28 <== NOT EXECUTED
a00106bc: e584302c str r3, [r4, #44] ; 0x2c <== NOT EXECUTED
_Timestamp_To_timespec( &src->total_wall_time, &dst->total_wall_time );
a00106c0: e2803084 add r3, r0, #132 ; 0x84 <== NOT EXECUTED
a00106c4: e893000c ldm r3, {r2, r3} <== NOT EXECUTED
a00106c8: e5842030 str r2, [r4, #48] ; 0x30 <== NOT EXECUTED
a00106cc: e5843034 str r3, [r4, #52] ; 0x34 <== NOT EXECUTED
dst->min_wall_time = src->min_wall_time;
dst->max_wall_time = src->max_wall_time;
dst->total_wall_time = src->total_wall_time;
#endif
_Thread_Enable_dispatch();
a00106d0: ebfff2a1 bl a000d15c <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a00106d4: e1a00005 mov r0, r5 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a00106d8: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a00106e0 <rtems_rate_monotonic_get_status>:
rtems_status_code rtems_rate_monotonic_get_status(
rtems_id id,
rtems_rate_monotonic_period_status *status
)
{
a00106e0: e92d4010 push {r4, lr}
Objects_Locations location;
Rate_monotonic_Period_time_t since_last_period;
Rate_monotonic_Control *the_period;
bool valid_status;
if ( !status )
a00106e4: e2514000 subs r4, r1, #0
rtems_status_code rtems_rate_monotonic_get_status(
rtems_id id,
rtems_rate_monotonic_period_status *status
)
{
a00106e8: e1a03000 mov r3, r0
a00106ec: e24dd014 sub sp, sp, #20
Rate_monotonic_Period_time_t since_last_period;
Rate_monotonic_Control *the_period;
bool valid_status;
if ( !status )
return RTEMS_INVALID_ADDRESS;
a00106f0: 03a00009 moveq r0, #9
Objects_Locations location;
Rate_monotonic_Period_time_t since_last_period;
Rate_monotonic_Control *the_period;
bool valid_status;
if ( !status )
a00106f4: 0a000023 beq a0010788 <rtems_rate_monotonic_get_status+0xa8>
a00106f8: e1a01003 mov r1, r3
a00106fc: e28d2010 add r2, sp, #16
a0010700: e59f0088 ldr r0, [pc, #136] ; a0010790 <rtems_rate_monotonic_get_status+0xb0>
a0010704: ebffefb8 bl a000c5ec <_Objects_Get>
return RTEMS_INVALID_ADDRESS;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a0010708: e59d2010 ldr r2, [sp, #16]
a001070c: e1a03000 mov r3, r0
a0010710: e3520000 cmp r2, #0
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0010714: 13a00004 movne r0, #4
if ( !status )
return RTEMS_INVALID_ADDRESS;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a0010718: 1a00001a bne a0010788 <rtems_rate_monotonic_get_status+0xa8>
case OBJECTS_LOCAL:
status->owner = the_period->owner->Object.id;
a001071c: e5932040 ldr r2, [r3, #64] ; 0x40
status->state = the_period->state;
a0010720: e5933038 ldr r3, [r3, #56] ; 0x38
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
case OBJECTS_LOCAL:
status->owner = the_period->owner->Object.id;
a0010724: e5922008 ldr r2, [r2, #8]
status->state = the_period->state;
/*
* If the period is inactive, there is no information.
*/
if ( status->state == RATE_MONOTONIC_INACTIVE ) {
a0010728: e3530000 cmp r3, #0
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
case OBJECTS_LOCAL:
status->owner = the_period->owner->Object.id;
status->state = the_period->state;
a001072c: e884000c stm r4, {r2, r3}
/*
* If the period is inactive, there is no information.
*/
if ( status->state == RATE_MONOTONIC_INACTIVE ) {
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
_Timespec_Set_to_zero( &status->since_last_period );
a0010730: 05843008 streq r3, [r4, #8]
a0010734: 0584300c streq r3, [r4, #12]
_Timespec_Set_to_zero( &status->executed_since_last_period );
a0010738: 05843010 streq r3, [r4, #16]
a001073c: 05843014 streq r3, [r4, #20]
a0010740: 0a00000e beq a0010780 <rtems_rate_monotonic_get_status+0xa0>
} else {
/*
* Grab the current status.
*/
valid_status =
a0010744: e1a0100d mov r1, sp <== NOT EXECUTED
a0010748: e28d2008 add r2, sp, #8 <== NOT EXECUTED
a001074c: ebffe6cb bl a000a280 <_Rate_monotonic_Get_status> <== NOT EXECUTED
_Rate_monotonic_Get_status(
the_period, &since_last_period, &executed
);
if (!valid_status) {
a0010750: e3500000 cmp r0, #0 <== NOT EXECUTED
a0010754: 1a000002 bne a0010764 <rtems_rate_monotonic_get_status+0x84><== NOT EXECUTED
_Thread_Enable_dispatch();
a0010758: ebfff27f bl a000d15c <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_NOT_DEFINED;
a001075c: e3a0000b mov r0, #11 <== NOT EXECUTED
a0010760: ea000008 b a0010788 <rtems_rate_monotonic_get_status+0xa8> <== NOT EXECUTED
}
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
_Timestamp_To_timespec(
a0010764: e89d000c ldm sp, {r2, r3} <== NOT EXECUTED
a0010768: e5842008 str r2, [r4, #8] <== NOT EXECUTED
a001076c: e584300c str r3, [r4, #12] <== NOT EXECUTED
&since_last_period, &status->since_last_period
);
_Timestamp_To_timespec(
a0010770: e28d3008 add r3, sp, #8 <== NOT EXECUTED
a0010774: e893000c ldm r3, {r2, r3} <== NOT EXECUTED
a0010778: e5842010 str r2, [r4, #16] <== NOT EXECUTED
a001077c: e5843014 str r3, [r4, #20] <== NOT EXECUTED
status->since_last_period = since_last_period;
status->executed_since_last_period = executed;
#endif
}
_Thread_Enable_dispatch();
a0010780: ebfff275 bl a000d15c <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0010784: e3a00000 mov r0, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0010788: e28dd014 add sp, sp, #20
a001078c: e8bd8010 pop {r4, pc}
a000a484 <rtems_rate_monotonic_period>:
rtems_status_code rtems_rate_monotonic_period(
rtems_id id,
rtems_interval length
)
{
a000a484: e92d40f1 push {r0, r4, r5, r6, r7, lr}
a000a488: e1a05000 mov r5, r0
a000a48c: e1a04001 mov r4, r1
Objects_Id id,
Objects_Locations *location
)
{
return (Rate_monotonic_Control *)
_Objects_Get( &_Rate_monotonic_Information, id, location );
a000a490: e59f0170 ldr r0, [pc, #368] ; a000a608 <rtems_rate_monotonic_period+0x184>
a000a494: e1a01005 mov r1, r5
a000a498: e1a0200d mov r2, sp
a000a49c: eb000852 bl a000c5ec <_Objects_Get>
rtems_rate_monotonic_period_states local_state;
ISR_Level level;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a000a4a0: e59d3000 ldr r3, [sp]
a000a4a4: e1a06000 mov r6, r0
a000a4a8: e3530000 cmp r3, #0
a000a4ac: 1a000052 bne a000a5fc <rtems_rate_monotonic_period+0x178>
case OBJECTS_LOCAL:
if ( !_Thread_Is_executing( the_period->owner ) ) {
a000a4b0: e59f3154 ldr r3, [pc, #340] ; a000a60c <rtems_rate_monotonic_period+0x188>
a000a4b4: e5902040 ldr r2, [r0, #64] ; 0x40
a000a4b8: e5933004 ldr r3, [r3, #4]
a000a4bc: e1520003 cmp r2, r3
a000a4c0: 0a000002 beq a000a4d0 <rtems_rate_monotonic_period+0x4c>
_Thread_Enable_dispatch();
a000a4c4: eb000b24 bl a000d15c <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_NOT_OWNER_OF_RESOURCE;
a000a4c8: e3a04017 mov r4, #23 <== NOT EXECUTED
a000a4cc: ea00004b b a000a600 <rtems_rate_monotonic_period+0x17c> <== NOT EXECUTED
}
if ( length == RTEMS_PERIOD_STATUS ) {
a000a4d0: e3540000 cmp r4, #0
a000a4d4: 1a000005 bne a000a4f0 <rtems_rate_monotonic_period+0x6c>
switch ( the_period->state ) {
a000a4d8: e5903038 ldr r3, [r0, #56] ; 0x38
a000a4dc: e3530004 cmp r3, #4
a000a4e0: 959f2128 ldrls r2, [pc, #296] ; a000a610 <rtems_rate_monotonic_period+0x18c>
a000a4e4: 97924103 ldrls r4, [r2, r3, lsl #2]
case RATE_MONOTONIC_ACTIVE:
default: /* unreached -- only to remove warnings */
return_value = RTEMS_SUCCESSFUL;
break;
}
_Thread_Enable_dispatch();
a000a4e8: eb000b1b bl a000d15c <_Thread_Enable_dispatch>
return( return_value );
a000a4ec: ea000043 b a000a600 <rtems_rate_monotonic_period+0x17c>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000a4f0: e10f7000 mrs r7, CPSR
a000a4f4: e3873080 orr r3, r7, #128 ; 0x80
a000a4f8: e129f003 msr CPSR_fc, r3
}
_ISR_Disable( level );
if ( the_period->state == RATE_MONOTONIC_INACTIVE ) {
a000a4fc: e5903038 ldr r3, [r0, #56] ; 0x38
a000a500: e3530000 cmp r3, #0
a000a504: 1a000011 bne a000a550 <rtems_rate_monotonic_period+0xcc>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000a508: e129f007 msr CPSR_fc, r7
_ISR_Enable( level );
/*
* Baseline statistics information for the beginning of a period.
*/
_Rate_monotonic_Initiate_statistics( the_period );
a000a50c: ebffff89 bl a000a338 <_Rate_monotonic_Initiate_statistics>
the_period->state = RATE_MONOTONIC_ACTIVE;
a000a510: e3a03002 mov r3, #2
a000a514: e5863038 str r3, [r6, #56] ; 0x38
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a000a518: e59f30f4 ldr r3, [pc, #244] ; a000a614 <rtems_rate_monotonic_period+0x190>
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a000a51c: e3a07000 mov r7, #0
_Rate_monotonic_Timeout,
id,
NULL
);
the_period->next_length = length;
a000a520: e586403c str r4, [r6, #60] ; 0x3c
the_watchdog->routine = routine;
a000a524: e586302c str r3, [r6, #44] ; 0x2c
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000a528: e586401c str r4, [r6, #28]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a000a52c: e59f00e4 ldr r0, [pc, #228] ; a000a618 <rtems_rate_monotonic_period+0x194>
a000a530: e2861010 add r1, r6, #16
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a000a534: e5867018 str r7, [r6, #24]
the_watchdog->routine = routine;
the_watchdog->id = id;
a000a538: e5865030 str r5, [r6, #48] ; 0x30
the_watchdog->user_data = user_data;
a000a53c: e5867034 str r7, [r6, #52] ; 0x34
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a000a540: eb000edb bl a000e0b4 <_Watchdog_Insert>
_Watchdog_Insert_ticks( &the_period->Timer, length );
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
a000a544: e1a04007 mov r4, r7
);
the_period->next_length = length;
_Watchdog_Insert_ticks( &the_period->Timer, length );
_Thread_Enable_dispatch();
a000a548: eb000b03 bl a000d15c <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000a54c: ea00002b b a000a600 <rtems_rate_monotonic_period+0x17c>
}
if ( the_period->state == RATE_MONOTONIC_ACTIVE ) {
a000a550: e3530002 cmp r3, #2
a000a554: 1a00001a bne a000a5c4 <rtems_rate_monotonic_period+0x140>
/*
* Update statistics from the concluding period.
*/
_Rate_monotonic_Update_statistics( the_period );
a000a558: ebffff93 bl a000a3ac <_Rate_monotonic_Update_statistics>
/*
* This tells the _Rate_monotonic_Timeout that this task is
* in the process of blocking on the period and that we
* may be changing the length of the next period.
*/
the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING;
a000a55c: e3a03001 mov r3, #1
a000a560: e5863038 str r3, [r6, #56] ; 0x38
the_period->next_length = length;
a000a564: e586403c str r4, [r6, #60] ; 0x3c
a000a568: e129f007 msr CPSR_fc, r7
_ISR_Enable( level );
_Thread_Executing->Wait.id = the_period->Object.id;
a000a56c: e59f3098 ldr r3, [pc, #152] ; a000a60c <rtems_rate_monotonic_period+0x188>
_Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
a000a570: e3a01901 mov r1, #16384 ; 0x4000
the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING;
the_period->next_length = length;
_ISR_Enable( level );
_Thread_Executing->Wait.id = the_period->Object.id;
a000a574: e5930004 ldr r0, [r3, #4]
a000a578: e5963008 ldr r3, [r6, #8]
a000a57c: e5803020 str r3, [r0, #32]
_Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
a000a580: eb000d0a bl a000d9b0 <_Thread_Set_state>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000a584: e10f2000 mrs r2, CPSR
a000a588: e3823080 orr r3, r2, #128 ; 0x80
a000a58c: e129f003 msr CPSR_fc, r3
* Did the watchdog timer expire while we were actually blocking
* on it?
*/
_ISR_Disable( level );
local_state = the_period->state;
the_period->state = RATE_MONOTONIC_ACTIVE;
a000a590: e3a01002 mov r1, #2
/*
* Did the watchdog timer expire while we were actually blocking
* on it?
*/
_ISR_Disable( level );
local_state = the_period->state;
a000a594: e5963038 ldr r3, [r6, #56] ; 0x38
the_period->state = RATE_MONOTONIC_ACTIVE;
a000a598: e5861038 str r1, [r6, #56] ; 0x38
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000a59c: e129f002 msr CPSR_fc, r2
/*
* If it did, then we want to unblock ourself and continue as
* if nothing happen. The period was reset in the timeout routine.
*/
if ( local_state == RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING )
a000a5a0: e3530003 cmp r3, #3
a000a5a4: 1a000003 bne a000a5b8 <rtems_rate_monotonic_period+0x134>
_Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
a000a5a8: e59f305c ldr r3, [pc, #92] ; a000a60c <rtems_rate_monotonic_period+0x188><== NOT EXECUTED
a000a5ac: e3a01901 mov r1, #16384 ; 0x4000 <== NOT EXECUTED
a000a5b0: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED
a000a5b4: eb000a1d bl a000ce30 <_Thread_Clear_state> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000a5b8: eb000ae7 bl a000d15c <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000a5bc: e3a04000 mov r4, #0 <== NOT EXECUTED
a000a5c0: ea00000e b a000a600 <rtems_rate_monotonic_period+0x17c> <== NOT EXECUTED
}
if ( the_period->state == RATE_MONOTONIC_EXPIRED ) {
a000a5c4: e3530004 cmp r3, #4 <== NOT EXECUTED
a000a5c8: 1a00000b bne a000a5fc <rtems_rate_monotonic_period+0x178> <== NOT EXECUTED
/*
* Update statistics from the concluding period
*/
_Rate_monotonic_Update_statistics( the_period );
a000a5cc: ebffff76 bl a000a3ac <_Rate_monotonic_Update_statistics> <== NOT EXECUTED
a000a5d0: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED
_ISR_Enable( level );
the_period->state = RATE_MONOTONIC_ACTIVE;
a000a5d4: e3a03002 mov r3, #2 <== NOT EXECUTED
a000a5d8: e5863038 str r3, [r6, #56] ; 0x38 <== NOT EXECUTED
the_period->next_length = length;
a000a5dc: e586403c str r4, [r6, #60] ; 0x3c <== NOT EXECUTED
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000a5e0: e586401c str r4, [r6, #28] <== NOT EXECUTED
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a000a5e4: e59f002c ldr r0, [pc, #44] ; a000a618 <rtems_rate_monotonic_period+0x194><== NOT EXECUTED
a000a5e8: e2861010 add r1, r6, #16 <== NOT EXECUTED
a000a5ec: eb000eb0 bl a000e0b4 <_Watchdog_Insert> <== NOT EXECUTED
_Watchdog_Insert_ticks( &the_period->Timer, length );
_Thread_Enable_dispatch();
return RTEMS_TIMEOUT;
a000a5f0: e3a04006 mov r4, #6 <== NOT EXECUTED
the_period->state = RATE_MONOTONIC_ACTIVE;
the_period->next_length = length;
_Watchdog_Insert_ticks( &the_period->Timer, length );
_Thread_Enable_dispatch();
a000a5f4: eb000ad8 bl a000d15c <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_TIMEOUT;
a000a5f8: ea000000 b a000a600 <rtems_rate_monotonic_period+0x17c> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000a5fc: e3a04004 mov r4, #4 <== NOT EXECUTED
}
a000a600: e1a00004 mov r0, r4
a000a604: e8bd80f8 pop {r3, r4, r5, r6, r7, pc}
a000a804 <rtems_rate_monotonic_report_statistics>:
void rtems_rate_monotonic_report_statistics( void )
{
rtems_rate_monotonic_report_statistics_with_plugin( NULL, printk_plugin );
a000a804: e59f1004 ldr r1, [pc, #4] ; a000a810 <rtems_rate_monotonic_report_statistics+0xc><== NOT EXECUTED
a000a808: e3a00000 mov r0, #0 <== NOT EXECUTED
a000a80c: eaffff82 b a000a61c <rtems_rate_monotonic_report_statistics_with_plugin><== NOT EXECUTED
a000a61c <rtems_rate_monotonic_report_statistics_with_plugin>:
*/
void rtems_rate_monotonic_report_statistics_with_plugin(
void *context,
rtems_printk_plugin_t print
)
{
a000a61c: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} <== NOT EXECUTED
rtems_id id;
rtems_rate_monotonic_period_statistics the_stats;
rtems_rate_monotonic_period_status the_status;
char name[5];
if ( !print )
a000a620: e2514000 subs r4, r1, #0 <== NOT EXECUTED
*/
void rtems_rate_monotonic_report_statistics_with_plugin(
void *context,
rtems_printk_plugin_t print
)
{
a000a624: e24dd078 sub sp, sp, #120 ; 0x78 <== NOT EXECUTED
a000a628: e1a05000 mov r5, r0 <== NOT EXECUTED
rtems_id id;
rtems_rate_monotonic_period_statistics the_stats;
rtems_rate_monotonic_period_status the_status;
char name[5];
if ( !print )
a000a62c: 0a000068 beq a000a7d4 <rtems_rate_monotonic_report_statistics_with_plugin+0x1b8><== NOT EXECUTED
return;
(*print)( context, "Period information by period\n" );
a000a630: e59f11a4 ldr r1, [pc, #420] ; a000a7dc <rtems_rate_monotonic_report_statistics_with_plugin+0x1c0><== NOT EXECUTED
a000a634: e12fff34 blx r4 <== NOT EXECUTED
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
(*print)( context, "--- CPU times are in seconds ---\n" );
a000a638: e59f11a0 ldr r1, [pc, #416] ; a000a7e0 <rtems_rate_monotonic_report_statistics_with_plugin+0x1c4><== NOT EXECUTED
a000a63c: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a640: e12fff34 blx r4 <== NOT EXECUTED
(*print)( context, "--- Wall times are in seconds ---\n" );
a000a644: e59f1198 ldr r1, [pc, #408] ; a000a7e4 <rtems_rate_monotonic_report_statistics_with_plugin+0x1c8><== NOT EXECUTED
a000a648: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a64c: e12fff34 blx r4 <== NOT EXECUTED
Be sure to test the various cases.
(*print)( context,"\
1234567890123456789012345678901234567890123456789012345678901234567890123456789\
\n");
*/
(*print)( context, " ID OWNER COUNT MISSED "
a000a650: e59f1190 ldr r1, [pc, #400] ; a000a7e8 <rtems_rate_monotonic_report_statistics_with_plugin+0x1cc><== NOT EXECUTED
a000a654: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a658: e12fff34 blx r4 <== NOT EXECUTED
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
status = rtems_rate_monotonic_get_statistics( id, &the_stats );
a000a65c: e28d7018 add r7, sp, #24 <== NOT EXECUTED
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
" "
#endif
" WALL TIME\n"
);
(*print)( context, " "
a000a660: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a664: e59f1180 ldr r1, [pc, #384] ; a000a7ec <rtems_rate_monotonic_report_statistics_with_plugin+0x1d0><== NOT EXECUTED
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
a000a668: e59f8180 ldr r8, [pc, #384] ; a000a7f0 <rtems_rate_monotonic_report_statistics_with_plugin+0x1d4><== NOT EXECUTED
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
" "
#endif
" WALL TIME\n"
);
(*print)( context, " "
a000a66c: e12fff34 blx r4 <== NOT EXECUTED
{
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
a000a670: e2873018 add r3, r7, #24 <== NOT EXECUTED
a000a674: e58d3010 str r3, [sp, #16] <== NOT EXECUTED
{
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
struct timespec wall_average;
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
a000a678: e2873030 add r3, r7, #48 ; 0x30 <== NOT EXECUTED
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
a000a67c: e5986008 ldr r6, [r8, #8] <== NOT EXECUTED
continue;
#else
(void) rtems_rate_monotonic_get_status( id, &the_status );
#endif
rtems_object_get_name( the_status.owner, sizeof(name), name );
a000a680: e28da070 add sl, sp, #112 ; 0x70 <== NOT EXECUTED
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
a000a684: e28d9068 add r9, sp, #104 ; 0x68 <== NOT EXECUTED
{
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
struct timespec wall_average;
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
a000a688: e58d3014 str r3, [sp, #20] <== NOT EXECUTED
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
a000a68c: ea00004d b a000a7c8 <rtems_rate_monotonic_report_statistics_with_plugin+0x1ac><== NOT EXECUTED
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
status = rtems_rate_monotonic_get_statistics( id, &the_stats );
a000a690: e1a00006 mov r0, r6 <== NOT EXECUTED
a000a694: e1a01007 mov r1, r7 <== NOT EXECUTED
a000a698: eb0017e3 bl a001062c <rtems_rate_monotonic_get_statistics> <== NOT EXECUTED
if ( status != RTEMS_SUCCESSFUL )
a000a69c: e3500000 cmp r0, #0 <== NOT EXECUTED
a000a6a0: 1a000047 bne a000a7c4 <rtems_rate_monotonic_report_statistics_with_plugin+0x1a8><== NOT EXECUTED
#if defined(RTEMS_DEBUG)
status = rtems_rate_monotonic_get_status( id, &the_status );
if ( status != RTEMS_SUCCESSFUL )
continue;
#else
(void) rtems_rate_monotonic_get_status( id, &the_status );
a000a6a4: e28d1050 add r1, sp, #80 ; 0x50 <== NOT EXECUTED
a000a6a8: e1a00006 mov r0, r6 <== NOT EXECUTED
a000a6ac: eb00180b bl a00106e0 <rtems_rate_monotonic_get_status> <== NOT EXECUTED
#endif
rtems_object_get_name( the_status.owner, sizeof(name), name );
a000a6b0: e3a01005 mov r1, #5 <== NOT EXECUTED
a000a6b4: e1a0200a mov r2, sl <== NOT EXECUTED
a000a6b8: e59d0050 ldr r0, [sp, #80] ; 0x50 <== NOT EXECUTED
a000a6bc: eb0000a8 bl a000a964 <rtems_object_get_name> <== NOT EXECUTED
/*
* Print part of report line that is not dependent on granularity
*/
(*print)( context,
a000a6c0: e59d3018 ldr r3, [sp, #24] <== NOT EXECUTED
a000a6c4: e59f1128 ldr r1, [pc, #296] ; a000a7f4 <rtems_rate_monotonic_report_statistics_with_plugin+0x1d8><== NOT EXECUTED
a000a6c8: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a6cc: e58d3000 str r3, [sp] <== NOT EXECUTED
a000a6d0: e59d301c ldr r3, [sp, #28] <== NOT EXECUTED
a000a6d4: e1a02006 mov r2, r6 <== NOT EXECUTED
a000a6d8: e58d3004 str r3, [sp, #4] <== NOT EXECUTED
a000a6dc: e1a0300a mov r3, sl <== NOT EXECUTED
a000a6e0: e12fff34 blx r4 <== NOT EXECUTED
);
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
a000a6e4: e59d1018 ldr r1, [sp, #24] <== NOT EXECUTED
a000a6e8: e3510000 cmp r1, #0 <== NOT EXECUTED
a000a6ec: 1a000003 bne a000a700 <rtems_rate_monotonic_report_statistics_with_plugin+0xe4><== NOT EXECUTED
(*print)( context, "\n" );
a000a6f0: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a6f4: e59f10fc ldr r1, [pc, #252] ; a000a7f8 <rtems_rate_monotonic_report_statistics_with_plugin+0x1dc><== NOT EXECUTED
a000a6f8: e12fff34 blx r4 <== NOT EXECUTED
continue;
a000a6fc: ea000030 b a000a7c4 <rtems_rate_monotonic_report_statistics_with_plugin+0x1a8><== NOT EXECUTED
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
a000a700: e1a02009 mov r2, r9 <== NOT EXECUTED
a000a704: e59d0010 ldr r0, [sp, #16] <== NOT EXECUTED
a000a708: eb000d7a bl a000dcf8 <_Timespec_Divide_by_integer> <== NOT EXECUTED
(*print)( context,
a000a70c: e59d0024 ldr r0, [sp, #36] ; 0x24 <== NOT EXECUTED
a000a710: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED
a000a714: eb0045f8 bl a001befc <__aeabi_idiv> <== NOT EXECUTED
a000a718: e59d3028 ldr r3, [sp, #40] ; 0x28 <== NOT EXECUTED
a000a71c: e1a0b000 mov fp, r0 <== NOT EXECUTED
a000a720: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED
a000a724: e59d002c ldr r0, [sp, #44] ; 0x2c <== NOT EXECUTED
a000a728: e58d3000 str r3, [sp] <== NOT EXECUTED
a000a72c: eb0045f2 bl a001befc <__aeabi_idiv> <== NOT EXECUTED
a000a730: e59d3068 ldr r3, [sp, #104] ; 0x68 <== NOT EXECUTED
a000a734: e58d0004 str r0, [sp, #4] <== NOT EXECUTED
a000a738: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED
a000a73c: e59d006c ldr r0, [sp, #108] ; 0x6c <== NOT EXECUTED
a000a740: e58d3008 str r3, [sp, #8] <== NOT EXECUTED
a000a744: eb0045ec bl a001befc <__aeabi_idiv> <== NOT EXECUTED
a000a748: e1a0300b mov r3, fp <== NOT EXECUTED
a000a74c: e58d000c str r0, [sp, #12] <== NOT EXECUTED
a000a750: e59f10a4 ldr r1, [pc, #164] ; a000a7fc <rtems_rate_monotonic_report_statistics_with_plugin+0x1e0><== NOT EXECUTED
a000a754: e59d2020 ldr r2, [sp, #32] <== NOT EXECUTED
a000a758: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a75c: e12fff34 blx r4 <== NOT EXECUTED
struct timespec wall_average;
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
_Timespec_Divide_by_integer(total_wall, the_stats.count, &wall_average);
a000a760: e1a02009 mov r2, r9 <== NOT EXECUTED
a000a764: e59d0014 ldr r0, [sp, #20] <== NOT EXECUTED
a000a768: e59d1018 ldr r1, [sp, #24] <== NOT EXECUTED
a000a76c: eb000d61 bl a000dcf8 <_Timespec_Divide_by_integer> <== NOT EXECUTED
(*print)( context,
a000a770: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED
a000a774: e59d003c ldr r0, [sp, #60] ; 0x3c <== NOT EXECUTED
a000a778: eb0045df bl a001befc <__aeabi_idiv> <== NOT EXECUTED
a000a77c: e59d3040 ldr r3, [sp, #64] ; 0x40 <== NOT EXECUTED
a000a780: e1a0b000 mov fp, r0 <== NOT EXECUTED
a000a784: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED
a000a788: e59d0044 ldr r0, [sp, #68] ; 0x44 <== NOT EXECUTED
a000a78c: e58d3000 str r3, [sp] <== NOT EXECUTED
a000a790: eb0045d9 bl a001befc <__aeabi_idiv> <== NOT EXECUTED
a000a794: e59d3068 ldr r3, [sp, #104] ; 0x68 <== NOT EXECUTED
a000a798: e58d0004 str r0, [sp, #4] <== NOT EXECUTED
a000a79c: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED
a000a7a0: e59d006c ldr r0, [sp, #108] ; 0x6c <== NOT EXECUTED
a000a7a4: e58d3008 str r3, [sp, #8] <== NOT EXECUTED
a000a7a8: eb0045d3 bl a001befc <__aeabi_idiv> <== NOT EXECUTED
a000a7ac: e59f104c ldr r1, [pc, #76] ; a000a800 <rtems_rate_monotonic_report_statistics_with_plugin+0x1e4><== NOT EXECUTED
a000a7b0: e58d000c str r0, [sp, #12] <== NOT EXECUTED
a000a7b4: e59d2038 ldr r2, [sp, #56] ; 0x38 <== NOT EXECUTED
a000a7b8: e1a00005 mov r0, r5 <== NOT EXECUTED
a000a7bc: e1a0300b mov r3, fp <== NOT EXECUTED
a000a7c0: e12fff34 blx r4 <== NOT EXECUTED
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
a000a7c4: e2866001 add r6, r6, #1 <== NOT EXECUTED
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
a000a7c8: e598300c ldr r3, [r8, #12] <== NOT EXECUTED
a000a7cc: e1560003 cmp r6, r3 <== NOT EXECUTED
a000a7d0: 9affffae bls a000a690 <rtems_rate_monotonic_report_statistics_with_plugin+0x74><== NOT EXECUTED
the_stats.min_wall_time, the_stats.max_wall_time, ival_wall, fval_wall
);
#endif
}
}
}
a000a7d4: e28dd078 add sp, sp, #120 ; 0x78 <== NOT EXECUTED
a000a7d8: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
a000a814 <rtems_rate_monotonic_reset_all_statistics>:
a000a814: e59f3038 ldr r3, [pc, #56] ; a000a854 <rtems_rate_monotonic_reset_all_statistics+0x40><== NOT EXECUTED
/*
* rtems_rate_monotonic_reset_all_statistics
*/
void rtems_rate_monotonic_reset_all_statistics( void )
{
a000a818: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
a000a81c: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000a820: e2822001 add r2, r2, #1 <== NOT EXECUTED
a000a824: e5832000 str r2, [r3] <== NOT EXECUTED
/*
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
a000a828: e59f5028 ldr r5, [pc, #40] ; a000a858 <rtems_rate_monotonic_reset_all_statistics+0x44><== NOT EXECUTED
a000a82c: e5954008 ldr r4, [r5, #8] <== NOT EXECUTED
a000a830: ea000002 b a000a840 <rtems_rate_monotonic_reset_all_statistics+0x2c><== NOT EXECUTED
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
(void) rtems_rate_monotonic_reset_statistics( id );
a000a834: e1a00004 mov r0, r4 <== NOT EXECUTED
a000a838: eb000007 bl a000a85c <rtems_rate_monotonic_reset_statistics><== NOT EXECUTED
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
a000a83c: e2844001 add r4, r4, #1 <== NOT EXECUTED
/*
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
a000a840: e595300c ldr r3, [r5, #12] <== NOT EXECUTED
a000a844: e1540003 cmp r4, r3 <== NOT EXECUTED
a000a848: 9afffff9 bls a000a834 <rtems_rate_monotonic_reset_all_statistics+0x20><== NOT EXECUTED
/*
* Done so exit thread dispatching disabled critical section.
*/
_Thread_Enable_dispatch();
}
a000a84c: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED
}
/*
* Done so exit thread dispatching disabled critical section.
*/
_Thread_Enable_dispatch();
a000a850: ea000a41 b a000d15c <_Thread_Enable_dispatch> <== NOT EXECUTED
a000a85c <rtems_rate_monotonic_reset_statistics>:
*/
rtems_status_code rtems_rate_monotonic_reset_statistics(
rtems_id id
)
{
a000a85c: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
a000a860: e1a01000 mov r1, r0 <== NOT EXECUTED
a000a864: e1a0200d mov r2, sp <== NOT EXECUTED
a000a868: e59f0044 ldr r0, [pc, #68] ; a000a8b4 <rtems_rate_monotonic_reset_statistics+0x58><== NOT EXECUTED
a000a86c: eb00075e bl a000c5ec <_Objects_Get> <== NOT EXECUTED
Objects_Locations location;
Rate_monotonic_Control *the_period;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a000a870: e59d5000 ldr r5, [sp] <== NOT EXECUTED
a000a874: e1a04000 mov r4, r0 <== NOT EXECUTED
a000a878: e3550000 cmp r5, #0 <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000a87c: 13a00004 movne r0, #4 <== NOT EXECUTED
{
Objects_Locations location;
Rate_monotonic_Control *the_period;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
a000a880: 1a00000a bne a000a8b0 <rtems_rate_monotonic_reset_statistics+0x54><== NOT EXECUTED
case OBJECTS_LOCAL:
_Rate_monotonic_Reset_statistics( the_period );
a000a884: e1a01005 mov r1, r5 <== NOT EXECUTED
a000a888: e3a02038 mov r2, #56 ; 0x38 <== NOT EXECUTED
a000a88c: e2840054 add r0, r4, #84 ; 0x54 <== NOT EXECUTED
a000a890: eb0023ae bl a0013750 <memset> <== NOT EXECUTED
a000a894: e3e03102 mvn r3, #-2147483648 ; 0x80000000 <== NOT EXECUTED
a000a898: e584305c str r3, [r4, #92] ; 0x5c <== NOT EXECUTED
a000a89c: e5843060 str r3, [r4, #96] ; 0x60 <== NOT EXECUTED
a000a8a0: e5843074 str r3, [r4, #116] ; 0x74 <== NOT EXECUTED
a000a8a4: e5843078 str r3, [r4, #120] ; 0x78 <== NOT EXECUTED
_Thread_Enable_dispatch();
a000a8a8: eb000a2b bl a000d15c <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a000a8ac: e1a00005 mov r0, r5 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a000a8b0: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a0016a90 <rtems_region_create>:
uintptr_t length,
uintptr_t page_size,
rtems_attribute attribute_set,
rtems_id *id
)
{
a0016a90: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
rtems_status_code return_status;
Region_Control *the_region;
if ( !rtems_is_name_valid( name ) )
a0016a94: e2509000 subs r9, r0, #0
uintptr_t length,
uintptr_t page_size,
rtems_attribute attribute_set,
rtems_id *id
)
{
a0016a98: e1a06001 mov r6, r1
a0016a9c: e1a07002 mov r7, r2
a0016aa0: e1a08003 mov r8, r3
a0016aa4: e59da024 ldr sl, [sp, #36] ; 0x24
a0016aa8: e59db028 ldr fp, [sp, #40] ; 0x28
rtems_status_code return_status;
Region_Control *the_region;
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
a0016aac: 03a06003 moveq r6, #3
)
{
rtems_status_code return_status;
Region_Control *the_region;
if ( !rtems_is_name_valid( name ) )
a0016ab0: 0a000031 beq a0016b7c <rtems_region_create+0xec>
return RTEMS_INVALID_NAME;
if ( !starting_address )
a0016ab4: e3560000 cmp r6, #0
a0016ab8: 0a00002e beq a0016b78 <rtems_region_create+0xe8>
return RTEMS_INVALID_ADDRESS;
if ( !id )
a0016abc: e35b0000 cmp fp, #0
a0016ac0: 0a00002c beq a0016b78 <rtems_region_create+0xe8>
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator(); /* to prevent deletion */
a0016ac4: e59f30b8 ldr r3, [pc, #184] ; a0016b84 <rtems_region_create+0xf4>
* This function allocates a region control block from
* the inactive chain of free region control blocks.
*/
RTEMS_INLINE_ROUTINE Region_Control *_Region_Allocate( void )
{
return (Region_Control *) _Objects_Allocate( &_Region_Information );
a0016ac8: e59f50b8 ldr r5, [pc, #184] ; a0016b88 <rtems_region_create+0xf8>
a0016acc: e5930000 ldr r0, [r3]
a0016ad0: eb000937 bl a0018fb4 <_API_Mutex_Lock>
a0016ad4: e1a00005 mov r0, r5
a0016ad8: eb000f61 bl a001a864 <_Objects_Allocate>
the_region = _Region_Allocate();
if ( !the_region )
a0016adc: e2504000 subs r4, r0, #0
return_status = RTEMS_TOO_MANY;
a0016ae0: 03a06005 moveq r6, #5
_RTEMS_Lock_allocator(); /* to prevent deletion */
the_region = _Region_Allocate();
if ( !the_region )
a0016ae4: 0a00001f beq a0016b68 <rtems_region_create+0xd8>
return_status = RTEMS_TOO_MANY;
else {
the_region->maximum_segment_size = _Heap_Initialize(
a0016ae8: e2840068 add r0, r4, #104 ; 0x68
a0016aec: e1a01006 mov r1, r6
a0016af0: e1a02007 mov r2, r7
a0016af4: e1a03008 mov r3, r8
a0016af8: eb000e3a bl a001a3e8 <_Heap_Initialize>
&the_region->Memory, starting_address, length, page_size
);
if ( !the_region->maximum_segment_size ) {
a0016afc: e3500000 cmp r0, #0
if ( !the_region )
return_status = RTEMS_TOO_MANY;
else {
the_region->maximum_segment_size = _Heap_Initialize(
a0016b00: e584005c str r0, [r4, #92] ; 0x5c
&the_region->Memory, starting_address, length, page_size
);
if ( !the_region->maximum_segment_size ) {
a0016b04: 1a000004 bne a0016b1c <rtems_region_create+0x8c>
*/
RTEMS_INLINE_ROUTINE void _Region_Free (
Region_Control *the_region
)
{
_Objects_Free( &_Region_Information, &the_region->Object );
a0016b08: e1a00005 mov r0, r5 <== NOT EXECUTED
a0016b0c: e1a01004 mov r1, r4 <== NOT EXECUTED
a0016b10: eb00101c bl a001ab88 <_Objects_Free> <== NOT EXECUTED
_Region_Free( the_region );
return_status = RTEMS_INVALID_SIZE;
a0016b14: e3a06008 mov r6, #8 <== NOT EXECUTED
a0016b18: ea000012 b a0016b68 <rtems_region_create+0xd8> <== NOT EXECUTED
}
else {
the_region->starting_address = starting_address;
a0016b1c: e5846050 str r6, [r4, #80] ; 0x50
the_region->length = length;
the_region->page_size = page_size;
the_region->attribute_set = attribute_set;
the_region->number_of_used_blocks = 0;
_Thread_queue_Initialize(
a0016b20: e31a0004 tst sl, #4
the_region->starting_address = starting_address;
the_region->length = length;
the_region->page_size = page_size;
the_region->attribute_set = attribute_set;
the_region->number_of_used_blocks = 0;
a0016b24: e3a06000 mov r6, #0
_Thread_queue_Initialize(
a0016b28: 03a01000 moveq r1, #0
a0016b2c: 13a01001 movne r1, #1
a0016b30: e3a02040 mov r2, #64 ; 0x40
a0016b34: e3a03006 mov r3, #6
}
else {
the_region->starting_address = starting_address;
the_region->length = length;
a0016b38: e5847054 str r7, [r4, #84] ; 0x54
the_region->page_size = page_size;
a0016b3c: e5848058 str r8, [r4, #88] ; 0x58
the_region->attribute_set = attribute_set;
a0016b40: e584a060 str sl, [r4, #96] ; 0x60
the_region->number_of_used_blocks = 0;
a0016b44: e5846064 str r6, [r4, #100] ; 0x64
_Thread_queue_Initialize(
a0016b48: e2840010 add r0, r4, #16
a0016b4c: eb00151e bl a001bfcc <_Thread_queue_Initialize>
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0016b50: e595201c ldr r2, [r5, #28]
Objects_Information *information,
Objects_Control *the_object,
Objects_Name name
)
{
_Objects_Set_local_object(
a0016b54: e5943008 ldr r3, [r4, #8]
a0016b58: e1d410b8 ldrh r1, [r4, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0016b5c: e7824101 str r4, [r2, r1, lsl #2]
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
a0016b60: e584900c str r9, [r4, #12]
&_Region_Information,
&the_region->Object,
(Objects_Name) name
);
*id = the_region->Object.id;
a0016b64: e58b3000 str r3, [fp]
return_status = RTEMS_SUCCESSFUL;
}
}
_RTEMS_Unlock_allocator();
a0016b68: e59f3014 ldr r3, [pc, #20] ; a0016b84 <rtems_region_create+0xf4>
a0016b6c: e5930000 ldr r0, [r3]
a0016b70: eb000928 bl a0019018 <_API_Mutex_Unlock>
return return_status;
a0016b74: ea000000 b a0016b7c <rtems_region_create+0xec>
if ( !starting_address )
return RTEMS_INVALID_ADDRESS;
if ( !id )
return RTEMS_INVALID_ADDRESS;
a0016b78: e3a06009 mov r6, #9 <== NOT EXECUTED
}
}
_RTEMS_Unlock_allocator();
return return_status;
}
a0016b7c: e1a00006 mov r0, r6
a0016b80: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
a0016c08 <rtems_region_extend>:
rtems_status_code rtems_region_extend(
rtems_id id,
void *starting_address,
uintptr_t length
)
{
a0016c08: e92d40f3 push {r0, r1, r4, r5, r6, r7, lr} <== NOT EXECUTED
bool extend_ok;
Objects_Locations location;
rtems_status_code return_status;
Region_Control *the_region;
if ( !starting_address )
a0016c0c: e2517000 subs r7, r1, #0 <== NOT EXECUTED
rtems_status_code rtems_region_extend(
rtems_id id,
void *starting_address,
uintptr_t length
)
{
a0016c10: e1a04000 mov r4, r0 <== NOT EXECUTED
a0016c14: e1a06002 mov r6, r2 <== NOT EXECUTED
Objects_Locations location;
rtems_status_code return_status;
Region_Control *the_region;
if ( !starting_address )
return RTEMS_INVALID_ADDRESS;
a0016c18: 03a05009 moveq r5, #9 <== NOT EXECUTED
bool extend_ok;
Objects_Locations location;
rtems_status_code return_status;
Region_Control *the_region;
if ( !starting_address )
a0016c1c: 0a00001d beq a0016c98 <rtems_region_extend+0x90> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator(); /* to prevent deletion */
a0016c20: e59f3078 ldr r3, [pc, #120] ; a0016ca0 <rtems_region_extend+0x98><== NOT EXECUTED
a0016c24: e5930000 ldr r0, [r3] <== NOT EXECUTED
a0016c28: eb0008e1 bl a0018fb4 <_API_Mutex_Lock> <== NOT EXECUTED
Objects_Id id,
Objects_Locations *location
)
{
return (Region_Control *)
_Objects_Get_no_protection( &_Region_Information, id, location );
a0016c2c: e1a01004 mov r1, r4 <== NOT EXECUTED
a0016c30: e59f006c ldr r0, [pc, #108] ; a0016ca4 <rtems_region_extend+0x9c><== NOT EXECUTED
a0016c34: e1a0200d mov r2, sp <== NOT EXECUTED
a0016c38: eb00102a bl a001ace8 <_Objects_Get_no_protection> <== NOT EXECUTED
the_region = _Region_Get( id, &location );
switch ( location ) {
a0016c3c: e59d5000 ldr r5, [sp] <== NOT EXECUTED
a0016c40: e1a04000 mov r4, r0 <== NOT EXECUTED
a0016c44: e3550000 cmp r5, #0 <== NOT EXECUTED
break;
#endif
case OBJECTS_ERROR:
default:
return_status = RTEMS_INVALID_ID;
a0016c48: 13a05004 movne r5, #4 <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator(); /* to prevent deletion */
the_region = _Region_Get( id, &location );
switch ( location ) {
a0016c4c: 1a00000e bne a0016c8c <rtems_region_extend+0x84> <== NOT EXECUTED
case OBJECTS_LOCAL:
extend_ok = _Heap_Extend(
a0016c50: e2800068 add r0, r0, #104 ; 0x68 <== NOT EXECUTED
a0016c54: e1a01007 mov r1, r7 <== NOT EXECUTED
a0016c58: e1a02006 mov r2, r6 <== NOT EXECUTED
a0016c5c: e28d3004 add r3, sp, #4 <== NOT EXECUTED
a0016c60: eb000c1d bl a0019cdc <_Heap_Extend> <== NOT EXECUTED
starting_address,
length,
&amount_extended
);
if ( extend_ok ) {
a0016c64: e3500000 cmp r0, #0 <== NOT EXECUTED
the_region->length += amount_extended;
the_region->maximum_segment_size += amount_extended;
return_status = RTEMS_SUCCESSFUL;
} else {
return_status = RTEMS_INVALID_ADDRESS;
a0016c68: 03a05009 moveq r5, #9 <== NOT EXECUTED
starting_address,
length,
&amount_extended
);
if ( extend_ok ) {
a0016c6c: 0a000006 beq a0016c8c <rtems_region_extend+0x84> <== NOT EXECUTED
the_region->length += amount_extended;
a0016c70: e59d3004 ldr r3, [sp, #4] <== NOT EXECUTED
a0016c74: e5942054 ldr r2, [r4, #84] ; 0x54 <== NOT EXECUTED
a0016c78: e0822003 add r2, r2, r3 <== NOT EXECUTED
a0016c7c: e5842054 str r2, [r4, #84] ; 0x54 <== NOT EXECUTED
the_region->maximum_segment_size += amount_extended;
a0016c80: e594205c ldr r2, [r4, #92] ; 0x5c <== NOT EXECUTED
a0016c84: e0823003 add r3, r2, r3 <== NOT EXECUTED
a0016c88: e584305c str r3, [r4, #92] ; 0x5c <== NOT EXECUTED
default:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
a0016c8c: e59f300c ldr r3, [pc, #12] ; a0016ca0 <rtems_region_extend+0x98><== NOT EXECUTED
a0016c90: e5930000 ldr r0, [r3] <== NOT EXECUTED
a0016c94: eb0008df bl a0019018 <_API_Mutex_Unlock> <== NOT EXECUTED
return return_status;
}
a0016c98: e1a00005 mov r0, r5 <== NOT EXECUTED
a0016c9c: e8bd80fc pop {r2, r3, r4, r5, r6, r7, pc} <== NOT EXECUTED
a0016ca8 <rtems_region_get_free_information>:
rtems_status_code rtems_region_get_free_information(
rtems_id id,
Heap_Information_block *the_info
)
{
a0016ca8: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
Objects_Locations location;
rtems_status_code return_status;
register Region_Control *the_region;
if ( !the_info )
a0016cac: e2514000 subs r4, r1, #0 <== NOT EXECUTED
rtems_status_code rtems_region_get_free_information(
rtems_id id,
Heap_Information_block *the_info
)
{
a0016cb0: e1a05000 mov r5, r0 <== NOT EXECUTED
Objects_Locations location;
rtems_status_code return_status;
register Region_Control *the_region;
if ( !the_info )
return RTEMS_INVALID_ADDRESS;
a0016cb4: 03a05009 moveq r5, #9 <== NOT EXECUTED
{
Objects_Locations location;
rtems_status_code return_status;
register Region_Control *the_region;
if ( !the_info )
a0016cb8: 0a000013 beq a0016d0c <rtems_region_get_free_information+0x64><== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
a0016cbc: e59f3050 ldr r3, [pc, #80] ; a0016d14 <rtems_region_get_free_information+0x6c><== NOT EXECUTED
a0016cc0: e5930000 ldr r0, [r3] <== NOT EXECUTED
a0016cc4: eb0008ba bl a0018fb4 <_API_Mutex_Lock> <== NOT EXECUTED
a0016cc8: e1a01005 mov r1, r5 <== NOT EXECUTED
a0016ccc: e59f0044 ldr r0, [pc, #68] ; a0016d18 <rtems_region_get_free_information+0x70><== NOT EXECUTED
a0016cd0: e1a0200d mov r2, sp <== NOT EXECUTED
a0016cd4: eb001003 bl a001ace8 <_Objects_Get_no_protection> <== NOT EXECUTED
the_region = _Region_Get( id, &location );
switch ( location ) {
a0016cd8: e59d5000 ldr r5, [sp] <== NOT EXECUTED
a0016cdc: e3550000 cmp r5, #0 <== NOT EXECUTED
break;
#endif
case OBJECTS_ERROR:
default:
return_status = RTEMS_INVALID_ID;
a0016ce0: 13a05004 movne r5, #4 <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
the_region = _Region_Get( id, &location );
switch ( location ) {
a0016ce4: 1a000005 bne a0016d00 <rtems_region_get_free_information+0x58><== NOT EXECUTED
case OBJECTS_LOCAL:
the_info->Used.number = 0;
a0016ce8: e584500c str r5, [r4, #12] <== NOT EXECUTED
the_info->Used.total = 0;
a0016cec: e5845014 str r5, [r4, #20] <== NOT EXECUTED
the_info->Used.largest = 0;
a0016cf0: e5845010 str r5, [r4, #16] <== NOT EXECUTED
_Heap_Get_free_information( &the_region->Memory, &the_info->Free );
a0016cf4: e2800068 add r0, r0, #104 ; 0x68 <== NOT EXECUTED
a0016cf8: e1a01004 mov r1, r4 <== NOT EXECUTED
a0016cfc: eb000d22 bl a001a18c <_Heap_Get_free_information> <== NOT EXECUTED
default:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
a0016d00: e59f300c ldr r3, [pc, #12] ; a0016d14 <rtems_region_get_free_information+0x6c><== NOT EXECUTED
a0016d04: e5930000 ldr r0, [r3] <== NOT EXECUTED
a0016d08: eb0008c2 bl a0019018 <_API_Mutex_Unlock> <== NOT EXECUTED
return return_status;
}
a0016d0c: e1a00005 mov r0, r5 <== NOT EXECUTED
a0016d10: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a0016d1c <rtems_region_get_information>:
rtems_status_code rtems_region_get_information(
rtems_id id,
Heap_Information_block *the_info
)
{
a0016d1c: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
Objects_Locations location;
rtems_status_code return_status;
register Region_Control *the_region;
if ( !the_info )
a0016d20: e2514000 subs r4, r1, #0 <== NOT EXECUTED
rtems_status_code rtems_region_get_information(
rtems_id id,
Heap_Information_block *the_info
)
{
a0016d24: e1a05000 mov r5, r0 <== NOT EXECUTED
Objects_Locations location;
rtems_status_code return_status;
register Region_Control *the_region;
if ( !the_info )
return RTEMS_INVALID_ADDRESS;
a0016d28: 03a05009 moveq r5, #9 <== NOT EXECUTED
{
Objects_Locations location;
rtems_status_code return_status;
register Region_Control *the_region;
if ( !the_info )
a0016d2c: 0a000010 beq a0016d74 <rtems_region_get_information+0x58> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
a0016d30: e59f3044 ldr r3, [pc, #68] ; a0016d7c <rtems_region_get_information+0x60><== NOT EXECUTED
a0016d34: e5930000 ldr r0, [r3] <== NOT EXECUTED
a0016d38: eb00089d bl a0018fb4 <_API_Mutex_Lock> <== NOT EXECUTED
a0016d3c: e1a01005 mov r1, r5 <== NOT EXECUTED
a0016d40: e59f0038 ldr r0, [pc, #56] ; a0016d80 <rtems_region_get_information+0x64><== NOT EXECUTED
a0016d44: e1a0200d mov r2, sp <== NOT EXECUTED
a0016d48: eb000fe6 bl a001ace8 <_Objects_Get_no_protection> <== NOT EXECUTED
the_region = _Region_Get( id, &location );
switch ( location ) {
a0016d4c: e59d5000 ldr r5, [sp] <== NOT EXECUTED
a0016d50: e3550000 cmp r5, #0 <== NOT EXECUTED
break;
#endif
case OBJECTS_ERROR:
default:
return_status = RTEMS_INVALID_ID;
a0016d54: 13a05004 movne r5, #4 <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
the_region = _Region_Get( id, &location );
switch ( location ) {
a0016d58: 1a000002 bne a0016d68 <rtems_region_get_information+0x4c> <== NOT EXECUTED
case OBJECTS_LOCAL:
_Heap_Get_information( &the_region->Memory, the_info );
a0016d5c: e2800068 add r0, r0, #104 ; 0x68 <== NOT EXECUTED
a0016d60: e1a01004 mov r1, r4 <== NOT EXECUTED
a0016d64: eb000d1c bl a001a1dc <_Heap_Get_information> <== NOT EXECUTED
default:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
a0016d68: e59f300c ldr r3, [pc, #12] ; a0016d7c <rtems_region_get_information+0x60><== NOT EXECUTED
a0016d6c: e5930000 ldr r0, [r3] <== NOT EXECUTED
a0016d70: eb0008a8 bl a0019018 <_API_Mutex_Unlock> <== NOT EXECUTED
return return_status;
}
a0016d74: e1a00005 mov r0, r5 <== NOT EXECUTED
a0016d78: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a0016eb0 <rtems_region_get_segment_size>:
rtems_status_code rtems_region_get_segment_size(
rtems_id id,
void *segment,
uintptr_t *size
)
{
a0016eb0: e92d4071 push {r0, r4, r5, r6, lr}
Objects_Locations location;
rtems_status_code return_status = RTEMS_SUCCESSFUL;
register Region_Control *the_region;
if ( !segment )
a0016eb4: e2515000 subs r5, r1, #0
rtems_status_code rtems_region_get_segment_size(
rtems_id id,
void *segment,
uintptr_t *size
)
{
a0016eb8: e1a06000 mov r6, r0
a0016ebc: e1a04002 mov r4, r2
Objects_Locations location;
rtems_status_code return_status = RTEMS_SUCCESSFUL;
register Region_Control *the_region;
if ( !segment )
a0016ec0: 0a000019 beq a0016f2c <rtems_region_get_segment_size+0x7c>
return RTEMS_INVALID_ADDRESS;
if ( !size )
a0016ec4: e3520000 cmp r2, #0
a0016ec8: 0a000017 beq a0016f2c <rtems_region_get_segment_size+0x7c>
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
a0016ecc: e59f3064 ldr r3, [pc, #100] ; a0016f38 <rtems_region_get_segment_size+0x88>
a0016ed0: e5930000 ldr r0, [r3]
a0016ed4: eb000836 bl a0018fb4 <_API_Mutex_Lock>
a0016ed8: e59f005c ldr r0, [pc, #92] ; a0016f3c <rtems_region_get_segment_size+0x8c>
a0016edc: e1a01006 mov r1, r6
a0016ee0: e1a0200d mov r2, sp
a0016ee4: eb000f7f bl a001ace8 <_Objects_Get_no_protection>
the_region = _Region_Get( id, &location );
switch ( location ) {
a0016ee8: e59d3000 ldr r3, [sp]
a0016eec: e3530000 cmp r3, #0
a0016ef0: 0a000002 beq a0016f00 <rtems_region_get_segment_size+0x50>
void *segment,
uintptr_t *size
)
{
Objects_Locations location;
rtems_status_code return_status = RTEMS_SUCCESSFUL;
a0016ef4: e3530001 cmp r3, #1 <== NOT EXECUTED
a0016ef8: 03a04004 moveq r4, #4 <== NOT EXECUTED
a0016efc: ea000005 b a0016f18 <rtems_region_get_segment_size+0x68> <== NOT EXECUTED
the_region = _Region_Get( id, &location );
switch ( location ) {
case OBJECTS_LOCAL:
if ( !_Heap_Size_of_alloc_area( &the_region->Memory, segment, size ) )
a0016f00: e1a02004 mov r2, r4
a0016f04: e2800068 add r0, r0, #104 ; 0x68
a0016f08: e1a01005 mov r1, r5
a0016f0c: eb000e17 bl a001a770 <_Heap_Size_of_alloc_area>
void *segment,
uintptr_t *size
)
{
Objects_Locations location;
rtems_status_code return_status = RTEMS_SUCCESSFUL;
a0016f10: e3500000 cmp r0, #0
a0016f14: 03a04009 moveq r4, #9
case OBJECTS_ERROR:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
a0016f18: e59f3018 ldr r3, [pc, #24] ; a0016f38 <rtems_region_get_segment_size+0x88>
void *segment,
uintptr_t *size
)
{
Objects_Locations location;
rtems_status_code return_status = RTEMS_SUCCESSFUL;
a0016f1c: 13a04000 movne r4, #0
case OBJECTS_ERROR:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
a0016f20: e5930000 ldr r0, [r3]
a0016f24: eb00083b bl a0019018 <_API_Mutex_Unlock>
return return_status;
a0016f28: ea000000 b a0016f30 <rtems_region_get_segment_size+0x80>
if ( !segment )
return RTEMS_INVALID_ADDRESS;
if ( !size )
return RTEMS_INVALID_ADDRESS;
a0016f2c: e3a04009 mov r4, #9 <== NOT EXECUTED
break;
}
_RTEMS_Unlock_allocator();
return return_status;
}
a0016f30: e1a00004 mov r0, r4
a0016f34: e8bd8078 pop {r3, r4, r5, r6, pc}
a0016f70 <rtems_region_resize_segment>:
rtems_id id,
void *segment,
uintptr_t size,
uintptr_t *old_size
)
{
a0016f70: e92d41ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, lr} <== NOT EXECUTED
uintptr_t osize;
rtems_status_code return_status;
Heap_Resize_status status;
register Region_Control *the_region;
if ( !old_size )
a0016f74: e2538000 subs r8, r3, #0 <== NOT EXECUTED
rtems_id id,
void *segment,
uintptr_t size,
uintptr_t *old_size
)
{
a0016f78: e1a05000 mov r5, r0 <== NOT EXECUTED
a0016f7c: e1a07001 mov r7, r1 <== NOT EXECUTED
a0016f80: e1a06002 mov r6, r2 <== NOT EXECUTED
rtems_status_code return_status;
Heap_Resize_status status;
register Region_Control *the_region;
if ( !old_size )
return RTEMS_INVALID_ADDRESS;
a0016f84: 03a00009 moveq r0, #9 <== NOT EXECUTED
uintptr_t osize;
rtems_status_code return_status;
Heap_Resize_status status;
register Region_Control *the_region;
if ( !old_size )
a0016f88: 0a000022 beq a0017018 <rtems_region_resize_segment+0xa8> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
a0016f8c: e59f408c ldr r4, [pc, #140] ; a0017020 <rtems_region_resize_segment+0xb0><== NOT EXECUTED
a0016f90: e5940000 ldr r0, [r4] <== NOT EXECUTED
a0016f94: eb000806 bl a0018fb4 <_API_Mutex_Lock> <== NOT EXECUTED
a0016f98: e1a01005 mov r1, r5 <== NOT EXECUTED
a0016f9c: e59f0080 ldr r0, [pc, #128] ; a0017024 <rtems_region_resize_segment+0xb4><== NOT EXECUTED
a0016fa0: e28d2008 add r2, sp, #8 <== NOT EXECUTED
a0016fa4: eb000f4f bl a001ace8 <_Objects_Get_no_protection> <== NOT EXECUTED
the_region = _Region_Get( id, &location );
switch ( location ) {
a0016fa8: e59d3008 ldr r3, [sp, #8] <== NOT EXECUTED
a0016fac: e1a05000 mov r5, r0 <== NOT EXECUTED
a0016fb0: e3530000 cmp r3, #0 <== NOT EXECUTED
a0016fb4: 1a000014 bne a001700c <rtems_region_resize_segment+0x9c> <== NOT EXECUTED
case OBJECTS_LOCAL:
_Region_Debug_Walk( the_region, 7 );
status = _Heap_Resize_block(
a0016fb8: e28d300c add r3, sp, #12 <== NOT EXECUTED
a0016fbc: e58d3000 str r3, [sp] <== NOT EXECUTED
a0016fc0: e1a02006 mov r2, r6 <== NOT EXECUTED
a0016fc4: e28d3004 add r3, sp, #4 <== NOT EXECUTED
a0016fc8: e2800068 add r0, r0, #104 ; 0x68 <== NOT EXECUTED
a0016fcc: e1a01007 mov r1, r7 <== NOT EXECUTED
a0016fd0: eb000d97 bl a001a634 <_Heap_Resize_block> <== NOT EXECUTED
segment,
(uint32_t) size,
&osize,
&avail_size
);
*old_size = (uint32_t) osize;
a0016fd4: e59d3004 ldr r3, [sp, #4] <== NOT EXECUTED
_Region_Debug_Walk( the_region, 8 );
if ( status == HEAP_RESIZE_SUCCESSFUL )
a0016fd8: e2506000 subs r6, r0, #0 <== NOT EXECUTED
segment,
(uint32_t) size,
&osize,
&avail_size
);
*old_size = (uint32_t) osize;
a0016fdc: e5883000 str r3, [r8] <== NOT EXECUTED
_Region_Debug_Walk( the_region, 8 );
if ( status == HEAP_RESIZE_SUCCESSFUL )
a0016fe0: 1a000003 bne a0016ff4 <rtems_region_resize_segment+0x84> <== NOT EXECUTED
_Region_Process_queue( the_region ); /* unlocks allocator */
a0016fe4: e1a00005 mov r0, r5 <== NOT EXECUTED
a0016fe8: eb001fec bl a001efa0 <_Region_Process_queue> <== NOT EXECUTED
else
_RTEMS_Unlock_allocator();
if (status == HEAP_RESIZE_SUCCESSFUL)
return RTEMS_SUCCESSFUL;
a0016fec: e1a00006 mov r0, r6 <== NOT EXECUTED
a0016ff0: ea000008 b a0017018 <rtems_region_resize_segment+0xa8> <== NOT EXECUTED
_Region_Debug_Walk( the_region, 8 );
if ( status == HEAP_RESIZE_SUCCESSFUL )
_Region_Process_queue( the_region ); /* unlocks allocator */
else
_RTEMS_Unlock_allocator();
a0016ff4: e5940000 ldr r0, [r4] <== NOT EXECUTED
a0016ff8: eb000806 bl a0019018 <_API_Mutex_Unlock> <== NOT EXECUTED
if (status == HEAP_RESIZE_SUCCESSFUL)
return RTEMS_SUCCESSFUL;
if (status == HEAP_RESIZE_UNSATISFIED)
return RTEMS_UNSATISFIED;
a0016ffc: e3560001 cmp r6, #1 <== NOT EXECUTED
a0017000: 13a00009 movne r0, #9 <== NOT EXECUTED
a0017004: 03a0000d moveq r0, #13 <== NOT EXECUTED
a0017008: ea000002 b a0017018 <rtems_region_resize_segment+0xa8> <== NOT EXECUTED
default:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
a001700c: e5940000 ldr r0, [r4] <== NOT EXECUTED
a0017010: eb000800 bl a0019018 <_API_Mutex_Unlock> <== NOT EXECUTED
return return_status;
a0017014: e3a00004 mov r0, #4 <== NOT EXECUTED
}
a0017018: e28dd010 add sp, sp, #16 <== NOT EXECUTED
a001701c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
a0017028 <rtems_region_return_segment>:
rtems_status_code rtems_region_return_segment(
rtems_id id,
void *segment
)
{
a0017028: e92d4071 push {r0, r4, r5, r6, lr}
uint32_t size;
#endif
int status;
register Region_Control *the_region;
_RTEMS_Lock_allocator();
a001702c: e59f3074 ldr r3, [pc, #116] ; a00170a8 <rtems_region_return_segment+0x80>
rtems_status_code rtems_region_return_segment(
rtems_id id,
void *segment
)
{
a0017030: e1a05000 mov r5, r0
a0017034: e1a04001 mov r4, r1
uint32_t size;
#endif
int status;
register Region_Control *the_region;
_RTEMS_Lock_allocator();
a0017038: e5930000 ldr r0, [r3]
a001703c: eb0007dc bl a0018fb4 <_API_Mutex_Lock>
a0017040: e1a01005 mov r1, r5
a0017044: e59f0060 ldr r0, [pc, #96] ; a00170ac <rtems_region_return_segment+0x84>
a0017048: e1a0200d mov r2, sp
a001704c: eb000f25 bl a001ace8 <_Objects_Get_no_protection>
the_region = _Region_Get( id, &location );
switch ( location ) {
a0017050: e59d6000 ldr r6, [sp]
a0017054: e1a05000 mov r5, r0
a0017058: e3560000 cmp r6, #0
break;
#endif
case OBJECTS_ERROR:
default:
return_status = RTEMS_INVALID_ID;
a001705c: 13a06004 movne r6, #4
register Region_Control *the_region;
_RTEMS_Lock_allocator();
the_region = _Region_Get( id, &location );
switch ( location ) {
a0017060: 1a00000b bne a0017094 <rtems_region_return_segment+0x6c>
RTEMS_INLINE_ROUTINE bool _Region_Free_segment (
Region_Control *the_region,
void *the_segment
)
{
return _Heap_Free( &the_region->Memory, the_segment );
a0017064: e2800068 add r0, r0, #104 ; 0x68
a0017068: e1a01004 mov r1, r4
a001706c: eb000bcd bl a0019fa8 <_Heap_Free>
#endif
status = _Region_Free_segment( the_region, segment );
_Region_Debug_Walk( the_region, 4 );
if ( !status )
a0017070: e3500000 cmp r0, #0
return_status = RTEMS_INVALID_ADDRESS;
a0017074: 03a06009 moveq r6, #9
#endif
status = _Region_Free_segment( the_region, segment );
_Region_Debug_Walk( the_region, 4 );
if ( !status )
a0017078: 0a000005 beq a0017094 <rtems_region_return_segment+0x6c>
return_status = RTEMS_INVALID_ADDRESS;
else {
the_region->number_of_used_blocks -= 1;
a001707c: e5953064 ldr r3, [r5, #100] ; 0x64
_Region_Process_queue(the_region); /* unlocks allocator */
a0017080: e1a00005 mov r0, r5
_Region_Debug_Walk( the_region, 4 );
if ( !status )
return_status = RTEMS_INVALID_ADDRESS;
else {
the_region->number_of_used_blocks -= 1;
a0017084: e2433001 sub r3, r3, #1
a0017088: e5853064 str r3, [r5, #100] ; 0x64
_Region_Process_queue(the_region); /* unlocks allocator */
a001708c: eb001fc3 bl a001efa0 <_Region_Process_queue>
return RTEMS_SUCCESSFUL;
a0017090: ea000002 b a00170a0 <rtems_region_return_segment+0x78>
default:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
a0017094: e59f300c ldr r3, [pc, #12] ; a00170a8 <rtems_region_return_segment+0x80><== NOT EXECUTED
a0017098: e5930000 ldr r0, [r3] <== NOT EXECUTED
a001709c: eb0007dd bl a0019018 <_API_Mutex_Unlock> <== NOT EXECUTED
return return_status;
}
a00170a0: e1a00006 mov r0, r6
a00170a4: e8bd8078 pop {r3, r4, r5, r6, pc}
a0009198 <rtems_semaphore_create>:
uint32_t count,
rtems_attribute attribute_set,
rtems_task_priority priority_ceiling,
rtems_id *id
)
{
a0009198: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr}
register Semaphore_Control *the_semaphore;
CORE_mutex_Attributes the_mutex_attr;
CORE_semaphore_Attributes the_semaphore_attr;
CORE_mutex_Status mutex_status;
if ( !rtems_is_name_valid( name ) )
a000919c: e2507000 subs r7, r0, #0
uint32_t count,
rtems_attribute attribute_set,
rtems_task_priority priority_ceiling,
rtems_id *id
)
{
a00091a0: e24dd018 sub sp, sp, #24
a00091a4: e1a04001 mov r4, r1
a00091a8: e1a08002 mov r8, r2
a00091ac: e1a09003 mov r9, r3
a00091b0: e59d6038 ldr r6, [sp, #56] ; 0x38
CORE_mutex_Attributes the_mutex_attr;
CORE_semaphore_Attributes the_semaphore_attr;
CORE_mutex_Status mutex_status;
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
a00091b4: 03a00003 moveq r0, #3
register Semaphore_Control *the_semaphore;
CORE_mutex_Attributes the_mutex_attr;
CORE_semaphore_Attributes the_semaphore_attr;
CORE_mutex_Status mutex_status;
if ( !rtems_is_name_valid( name ) )
a00091b8: 0a00005d beq a0009334 <rtems_semaphore_create+0x19c>
return RTEMS_INVALID_NAME;
if ( !id )
a00091bc: e3560000 cmp r6, #0
return RTEMS_INVALID_ADDRESS;
a00091c0: 03a00009 moveq r0, #9
CORE_mutex_Status mutex_status;
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
if ( !id )
a00091c4: 0a00005a beq a0009334 <rtems_semaphore_create+0x19c>
return RTEMS_NOT_DEFINED;
} else
#endif
if ( _Attributes_Is_inherit_priority( attribute_set ) ||
a00091c8: e21230c0 ands r3, r2, #192 ; 0xc0
a00091cc: 0a000006 beq a00091ec <rtems_semaphore_create+0x54>
*/
RTEMS_INLINE_ROUTINE bool _Attributes_Is_binary_semaphore(
rtems_attribute attribute_set
)
{
return ((attribute_set & RTEMS_SEMAPHORE_CLASS) == RTEMS_BINARY_SEMAPHORE);
a00091d0: e2022030 and r2, r2, #48 ; 0x30
_Attributes_Is_priority_ceiling( attribute_set ) ) {
if ( ! (_Attributes_Is_binary_semaphore( attribute_set ) &&
a00091d4: e3520010 cmp r2, #16
a00091d8: 1a000054 bne a0009330 <rtems_semaphore_create+0x198>
a00091dc: e3180004 tst r8, #4
a00091e0: 0a000052 beq a0009330 <rtems_semaphore_create+0x198>
_Attributes_Is_priority( attribute_set ) ) )
return RTEMS_NOT_DEFINED;
}
if ( _Attributes_Is_inherit_priority( attribute_set ) &&
a00091e4: e35300c0 cmp r3, #192 ; 0xc0
a00091e8: 0a000050 beq a0009330 <rtems_semaphore_create+0x198>
_Attributes_Is_priority_ceiling( attribute_set ) )
return RTEMS_NOT_DEFINED;
if ( !_Attributes_Is_counting_semaphore( attribute_set ) && ( count > 1 ) )
a00091ec: e218a030 ands sl, r8, #48 ; 0x30
a00091f0: 0a000002 beq a0009200 <rtems_semaphore_create+0x68>
a00091f4: e3540001 cmp r4, #1
return RTEMS_INVALID_NUMBER;
a00091f8: 83a0000a movhi r0, #10
if ( _Attributes_Is_inherit_priority( attribute_set ) &&
_Attributes_Is_priority_ceiling( attribute_set ) )
return RTEMS_NOT_DEFINED;
if ( !_Attributes_Is_counting_semaphore( attribute_set ) && ( count > 1 ) )
a00091fc: 8a00004c bhi a0009334 <rtems_semaphore_create+0x19c>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a0009200: e59f3134 ldr r3, [pc, #308] ; a000933c <rtems_semaphore_create+0x1a4>
a0009204: e5932000 ldr r2, [r3]
a0009208: e2822001 add r2, r2, #1
a000920c: e5832000 str r2, [r3]
* This function allocates a semaphore control block from
* the inactive chain of free semaphore control blocks.
*/
RTEMS_INLINE_ROUTINE Semaphore_Control *_Semaphore_Allocate( void )
{
return (Semaphore_Control *) _Objects_Allocate( &_Semaphore_Information );
a0009210: e59f0128 ldr r0, [pc, #296] ; a0009340 <rtems_semaphore_create+0x1a8>
a0009214: eb000522 bl a000a6a4 <_Objects_Allocate>
_Thread_Disable_dispatch(); /* prevents deletion */
the_semaphore = _Semaphore_Allocate();
if ( !the_semaphore ) {
a0009218: e2505000 subs r5, r0, #0
a000921c: 1a000002 bne a000922c <rtems_semaphore_create+0x94>
_Thread_Enable_dispatch();
a0009220: eb00091c bl a000b698 <_Thread_Enable_dispatch>
return RTEMS_TOO_MANY;
a0009224: e3a00005 mov r0, #5
a0009228: ea000041 b a0009334 <rtems_semaphore_create+0x19c>
the_semaphore->attribute_set = attribute_set;
/*
* Initialize it as a counting semaphore.
*/
if ( _Attributes_Is_counting_semaphore( attribute_set ) ) {
a000922c: e35a0000 cmp sl, #0
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
#endif
the_semaphore->attribute_set = attribute_set;
a0009230: e5858010 str r8, [r5, #16]
a0009234: e2083004 and r3, r8, #4
/*
* Initialize it as a counting semaphore.
*/
if ( _Attributes_Is_counting_semaphore( attribute_set ) ) {
a0009238: 1a00000d bne a0009274 <rtems_semaphore_create+0xdc>
/*
* This effectively disables limit checking.
*/
the_semaphore_attr.maximum_count = 0xFFFFFFFF;
if ( _Attributes_Is_priority( attribute_set ) )
a000923c: e3530000 cmp r3, #0
the_semaphore_attr.discipline = CORE_SEMAPHORE_DISCIPLINES_PRIORITY;
a0009240: 13a03001 movne r3, #1
*/
if ( _Attributes_Is_counting_semaphore( attribute_set ) ) {
/*
* This effectively disables limit checking.
*/
the_semaphore_attr.maximum_count = 0xFFFFFFFF;
a0009244: e3e02000 mvn r2, #0
a0009248: e58d2010 str r2, [sp, #16]
if ( _Attributes_Is_priority( attribute_set ) )
the_semaphore_attr.discipline = CORE_SEMAPHORE_DISCIPLINES_PRIORITY;
a000924c: 158d3014 strne r3, [sp, #20]
* The following are just to make Purify happy.
*/
the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
the_mutex_attr.priority_ceiling = PRIORITY_MINIMUM;
_CORE_semaphore_Initialize(
a0009250: e2850014 add r0, r5, #20
the_semaphore_attr.discipline = CORE_SEMAPHORE_DISCIPLINES_FIFO;
/*
* The following are just to make Purify happy.
*/
the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
a0009254: e3a03000 mov r3, #0
the_mutex_attr.priority_ceiling = PRIORITY_MINIMUM;
_CORE_semaphore_Initialize(
a0009258: e28d1010 add r1, sp, #16
a000925c: e1a02004 mov r2, r4
the_semaphore_attr.maximum_count = 0xFFFFFFFF;
if ( _Attributes_Is_priority( attribute_set ) )
the_semaphore_attr.discipline = CORE_SEMAPHORE_DISCIPLINES_PRIORITY;
else
the_semaphore_attr.discipline = CORE_SEMAPHORE_DISCIPLINES_FIFO;
a0009260: 058da014 streq sl, [sp, #20]
/*
* The following are just to make Purify happy.
*/
the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
a0009264: e58d3000 str r3, [sp]
the_mutex_attr.priority_ceiling = PRIORITY_MINIMUM;
a0009268: e58d300c str r3, [sp, #12]
_CORE_semaphore_Initialize(
a000926c: eb000397 bl a000a0d0 <_CORE_semaphore_Initialize>
a0009270: ea000024 b a0009308 <rtems_semaphore_create+0x170>
} else {
/*
* It is either simple binary semaphore or a more powerful mutex
* style binary semaphore. This is the mutex style.
*/
if ( _Attributes_Is_priority( attribute_set ) )
a0009274: e3530000 cmp r3, #0
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY;
a0009278: 13a03001 movne r3, #1
else
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_FIFO;
if ( _Attributes_Is_binary_semaphore( attribute_set ) ) {
a000927c: e35a0010 cmp sl, #16
* style binary semaphore. This is the mutex style.
*/
if ( _Attributes_Is_priority( attribute_set ) )
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY;
else
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_FIFO;
a0009280: e58d3008 str r3, [sp, #8]
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING;
the_mutex_attr.only_owner_release = true;
}
}
} else /* must be simple binary semaphore */ {
the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_BLOCKS;
a0009284: 13a03002 movne r3, #2
a0009288: 158d3000 strne r3, [sp]
the_mutex_attr.only_owner_release = false;
a000928c: 13a03000 movne r3, #0
if ( _Attributes_Is_priority( attribute_set ) )
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY;
else
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_FIFO;
if ( _Attributes_Is_binary_semaphore( attribute_set ) ) {
a0009290: 1a00000d bne a00092cc <rtems_semaphore_create+0x134>
the_mutex_attr.priority_ceiling = priority_ceiling;
the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
a0009294: e3a03000 mov r3, #0
a0009298: e58d3000 str r3, [sp]
the_mutex_attr.only_owner_release = false;
a000929c: e5cd3004 strb r3, [sp, #4]
if ( the_mutex_attr.discipline == CORE_MUTEX_DISCIPLINES_PRIORITY ) {
a00092a0: e59d3008 ldr r3, [sp, #8]
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY;
else
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_FIFO;
if ( _Attributes_Is_binary_semaphore( attribute_set ) ) {
the_mutex_attr.priority_ceiling = priority_ceiling;
a00092a4: e58d900c str r9, [sp, #12]
the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
the_mutex_attr.only_owner_release = false;
if ( the_mutex_attr.discipline == CORE_MUTEX_DISCIPLINES_PRIORITY ) {
a00092a8: e3530001 cmp r3, #1
a00092ac: 1a000007 bne a00092d0 <rtems_semaphore_create+0x138>
if ( _Attributes_Is_inherit_priority( attribute_set ) ) {
a00092b0: e3180040 tst r8, #64 ; 0x40
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT;
a00092b4: 13a02002 movne r2, #2
the_mutex_attr.priority_ceiling = priority_ceiling;
the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
the_mutex_attr.only_owner_release = false;
if ( the_mutex_attr.discipline == CORE_MUTEX_DISCIPLINES_PRIORITY ) {
if ( _Attributes_Is_inherit_priority( attribute_set ) ) {
a00092b8: 1a000002 bne a00092c8 <rtems_semaphore_create+0x130>
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT;
the_mutex_attr.only_owner_release = true;
} else if ( _Attributes_Is_priority_ceiling( attribute_set ) ) {
a00092bc: e3180080 tst r8, #128 ; 0x80
a00092c0: 0a000002 beq a00092d0 <rtems_semaphore_create+0x138>
the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING;
a00092c4: e3a02003 mov r2, #3
a00092c8: e58d2008 str r2, [sp, #8]
the_mutex_attr.only_owner_release = true;
}
}
} else /* must be simple binary semaphore */ {
the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_BLOCKS;
the_mutex_attr.only_owner_release = false;
a00092cc: e5cd3004 strb r3, [sp, #4]
}
mutex_status = _CORE_mutex_Initialize(
a00092d0: e3540001 cmp r4, #1
a00092d4: 13a02000 movne r2, #0
a00092d8: 03a02001 moveq r2, #1
a00092dc: e2850014 add r0, r5, #20
a00092e0: e1a0100d mov r1, sp
a00092e4: eb0002b7 bl a0009dc8 <_CORE_mutex_Initialize>
&the_semaphore->Core_control.mutex,
&the_mutex_attr,
(count == 1) ? CORE_MUTEX_UNLOCKED : CORE_MUTEX_LOCKED
);
if ( mutex_status == CORE_MUTEX_STATUS_CEILING_VIOLATED ) {
a00092e8: e3500006 cmp r0, #6
a00092ec: 1a000005 bne a0009308 <rtems_semaphore_create+0x170>
*/
RTEMS_INLINE_ROUTINE void _Semaphore_Free (
Semaphore_Control *the_semaphore
)
{
_Objects_Free( &_Semaphore_Information, &the_semaphore->Object );
a00092f0: e59f0048 ldr r0, [pc, #72] ; a0009340 <rtems_semaphore_create+0x1a8>
a00092f4: e1a01005 mov r1, r5
a00092f8: eb0005b2 bl a000a9c8 <_Objects_Free>
_Semaphore_Free( the_semaphore );
_Thread_Enable_dispatch();
a00092fc: eb0008e5 bl a000b698 <_Thread_Enable_dispatch>
return RTEMS_INVALID_PRIORITY;
a0009300: e3a00013 mov r0, #19
a0009304: ea00000a b a0009334 <rtems_semaphore_create+0x19c>
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0009308: e59f2030 ldr r2, [pc, #48] ; a0009340 <rtems_semaphore_create+0x1a8>
Objects_Information *information,
Objects_Control *the_object,
Objects_Name name
)
{
_Objects_Set_local_object(
a000930c: e5953008 ldr r3, [r5, #8]
a0009310: e1d510b8 ldrh r1, [r5, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0009314: e592201c ldr r2, [r2, #28]
a0009318: e7825101 str r5, [r2, r1, lsl #2]
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
a000931c: e585700c str r7, [r5, #12]
&_Semaphore_Information,
&the_semaphore->Object,
(Objects_Name) name
);
*id = the_semaphore->Object.id;
a0009320: e5863000 str r3, [r6]
the_semaphore->Object.id,
name,
0 /* Not used */
);
#endif
_Thread_Enable_dispatch();
a0009324: eb0008db bl a000b698 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0009328: e3a00000 mov r0, #0
a000932c: ea000000 b a0009334 <rtems_semaphore_create+0x19c>
}
if ( _Attributes_Is_inherit_priority( attribute_set ) &&
_Attributes_Is_priority_ceiling( attribute_set ) )
return RTEMS_NOT_DEFINED;
a0009330: e3a0000b mov r0, #11 <== NOT EXECUTED
0 /* Not used */
);
#endif
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
a0009334: e28dd018 add sp, sp, #24
a0009338: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc}
a0009344 <rtems_semaphore_delete>:
#endif
rtems_status_code rtems_semaphore_delete(
rtems_id id
)
{
a0009344: e92d4011 push {r0, r4, lr}
a0009348: e1a01000 mov r1, r0
Objects_Id id,
Objects_Locations *location
)
{
return (Semaphore_Control *)
_Objects_Get( &_Semaphore_Information, id, location );
a000934c: e1a0200d mov r2, sp
a0009350: e59f0084 ldr r0, [pc, #132] ; a00093dc <rtems_semaphore_delete+0x98>
a0009354: eb0005f3 bl a000ab28 <_Objects_Get>
register Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _Semaphore_Get( id, &location );
switch ( location ) {
a0009358: e59d3000 ldr r3, [sp]
a000935c: e1a04000 mov r4, r0
a0009360: e3530000 cmp r3, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0009364: 13a00004 movne r0, #4
{
register Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _Semaphore_Get( id, &location );
switch ( location ) {
a0009368: 1a00001a bne a00093d8 <rtems_semaphore_delete+0x94>
*/
RTEMS_INLINE_ROUTINE bool _Attributes_Is_counting_semaphore(
rtems_attribute attribute_set
)
{
return ((attribute_set & RTEMS_SEMAPHORE_CLASS) == RTEMS_COUNTING_SEMAPHORE);
a000936c: e5941010 ldr r1, [r4, #16]
case OBJECTS_LOCAL:
if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) {
a0009370: e2111030 ands r1, r1, #48 ; 0x30
a0009374: 0a00000c beq a00093ac <rtems_semaphore_delete+0x68>
if ( _CORE_mutex_Is_locked( &the_semaphore->Core_control.mutex ) &&
a0009378: e5943064 ldr r3, [r4, #100] ; 0x64
a000937c: e3530000 cmp r3, #0
a0009380: 1a000004 bne a0009398 <rtems_semaphore_delete+0x54>
a0009384: e3510020 cmp r1, #32
a0009388: 0a000002 beq a0009398 <rtems_semaphore_delete+0x54>
!_Attributes_Is_simple_binary_semaphore(
the_semaphore->attribute_set ) ) {
_Thread_Enable_dispatch();
a000938c: eb0008c1 bl a000b698 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_RESOURCE_IN_USE;
a0009390: e3a0000c mov r0, #12 <== NOT EXECUTED
a0009394: ea00000f b a00093d8 <rtems_semaphore_delete+0x94> <== NOT EXECUTED
}
_CORE_mutex_Flush(
a0009398: e2840014 add r0, r4, #20
a000939c: e3a01000 mov r1, #0
a00093a0: e3a02004 mov r2, #4
a00093a4: eb000286 bl a0009dc4 <_CORE_mutex_Flush>
a00093a8: ea000002 b a00093b8 <rtems_semaphore_delete+0x74>
&the_semaphore->Core_control.mutex,
SEMAPHORE_MP_OBJECT_WAS_DELETED,
CORE_MUTEX_WAS_DELETED
);
} else {
_CORE_semaphore_Flush(
a00093ac: e2840014 add r0, r4, #20
a00093b0: e3a02002 mov r2, #2
a00093b4: eb000344 bl a000a0cc <_CORE_semaphore_Flush>
SEMAPHORE_MP_OBJECT_WAS_DELETED,
CORE_SEMAPHORE_WAS_DELETED
);
}
_Objects_Close( &_Semaphore_Information, &the_semaphore->Object );
a00093b8: e59f001c ldr r0, [pc, #28] ; a00093dc <rtems_semaphore_delete+0x98>
a00093bc: e1a01004 mov r1, r4
a00093c0: eb0004d9 bl a000a72c <_Objects_Close>
*/
RTEMS_INLINE_ROUTINE void _Semaphore_Free (
Semaphore_Control *the_semaphore
)
{
_Objects_Free( &_Semaphore_Information, &the_semaphore->Object );
a00093c4: e59f0010 ldr r0, [pc, #16] ; a00093dc <rtems_semaphore_delete+0x98>
a00093c8: e1a01004 mov r1, r4
a00093cc: eb00057d bl a000a9c8 <_Objects_Free>
0, /* Not used */
0 /* Not used */
);
}
#endif
_Thread_Enable_dispatch();
a00093d0: eb0008b0 bl a000b698 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a00093d4: e3a00000 mov r0, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a00093d8: e8bd8018 pop {r3, r4, pc}
a0012414 <rtems_semaphore_flush>:
#endif
rtems_status_code rtems_semaphore_flush(
rtems_id id
)
{
a0012414: e92d4001 push {r0, lr}
a0012418: e1a01000 mov r1, r0
a001241c: e1a0200d mov r2, sp
a0012420: e59f0044 ldr r0, [pc, #68] ; a001246c <rtems_semaphore_flush+0x58>
a0012424: ebffe62d bl a000bce0 <_Objects_Get>
register Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _Semaphore_Get( id, &location );
switch ( location ) {
a0012428: e59d3000 ldr r3, [sp]
a001242c: e3530000 cmp r3, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0012430: 13a00004 movne r0, #4
{
register Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _Semaphore_Get( id, &location );
switch ( location ) {
a0012434: 1a00000b bne a0012468 <rtems_semaphore_flush+0x54>
*/
RTEMS_INLINE_ROUTINE bool _Attributes_Is_counting_semaphore(
rtems_attribute attribute_set
)
{
return ((attribute_set & RTEMS_SEMAPHORE_CLASS) == RTEMS_COUNTING_SEMAPHORE);
a0012438: e5901010 ldr r1, [r0, #16]
a001243c: e2800014 add r0, r0, #20
case OBJECTS_LOCAL:
if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) {
a0012440: e2111030 ands r1, r1, #48 ; 0x30
a0012444: 0a000003 beq a0012458 <rtems_semaphore_flush+0x44>
_CORE_mutex_Flush(
a0012448: e1a01003 mov r1, r3
a001244c: e3a02001 mov r2, #1
a0012450: ebffe2e8 bl a000aff8 <_CORE_mutex_Flush>
a0012454: ea000001 b a0012460 <rtems_semaphore_flush+0x4c>
&the_semaphore->Core_control.mutex,
SEND_OBJECT_WAS_DELETED,
CORE_MUTEX_STATUS_UNSATISFIED_NOWAIT
);
} else {
_CORE_semaphore_Flush(
a0012458: e3a02001 mov r2, #1 <== NOT EXECUTED
a001245c: ebffe3a7 bl a000b300 <_CORE_semaphore_Flush> <== NOT EXECUTED
&the_semaphore->Core_control.semaphore,
SEND_OBJECT_WAS_DELETED,
CORE_SEMAPHORE_STATUS_UNSATISFIED_NOWAIT
);
}
_Thread_Enable_dispatch();
a0012460: ebffe8fc bl a000c858 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0012464: e3a00000 mov r0, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0012468: e8bd8008 pop {r3, pc}
a00093e0 <rtems_semaphore_obtain>:
rtems_status_code rtems_semaphore_obtain(
rtems_id id,
rtems_option option_set,
rtems_interval timeout
)
{
a00093e0: e92d40f7 push {r0, r1, r2, r4, r5, r6, r7, lr}
a00093e4: e1a04000 mov r4, r0
Objects_Locations *location,
ISR_Level *level
)
{
return (Semaphore_Control *)
_Objects_Get_isr_disable( &_Semaphore_Information, id, location, level );
a00093e8: e28d3004 add r3, sp, #4
a00093ec: e1a06001 mov r6, r1
a00093f0: e1a05002 mov r5, r2
a00093f4: e59f00ec ldr r0, [pc, #236] ; a00094e8 <rtems_semaphore_obtain+0x108>
a00093f8: e1a01004 mov r1, r4
a00093fc: e28d2008 add r2, sp, #8
a0009400: eb0005ad bl a000aabc <_Objects_Get_isr_disable>
register Semaphore_Control *the_semaphore;
Objects_Locations location;
ISR_Level level;
the_semaphore = _Semaphore_Get_interrupt_disable( id, &location, &level );
switch ( location ) {
a0009404: e59d3008 ldr r3, [sp, #8]
a0009408: e3530000 cmp r3, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000940c: 13a00004 movne r0, #4
register Semaphore_Control *the_semaphore;
Objects_Locations location;
ISR_Level level;
the_semaphore = _Semaphore_Get_interrupt_disable( id, &location, &level );
switch ( location ) {
a0009410: 1a000033 bne a00094e4 <rtems_semaphore_obtain+0x104>
a0009414: e5903010 ldr r3, [r0, #16]
a0009418: e59f70cc ldr r7, [pc, #204] ; a00094ec <rtems_semaphore_obtain+0x10c>
case OBJECTS_LOCAL:
if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) {
a000941c: e2132030 ands r2, r3, #48 ; 0x30
a0009420: 0a00000b beq a0009454 <rtems_semaphore_obtain+0x74>
_CORE_mutex_Seize(
a0009424: e59d3004 ldr r3, [sp, #4]
*/
RTEMS_INLINE_ROUTINE bool _Options_Is_no_wait (
rtems_option option_set
)
{
return (option_set & RTEMS_NO_WAIT) ? true : false;
a0009428: e2062001 and r2, r6, #1
a000942c: e2800014 add r0, r0, #20
a0009430: e58d3000 str r3, [sp]
a0009434: e1a01004 mov r1, r4
a0009438: e1a03005 mov r3, r5
a000943c: e2222001 eor r2, r2, #1
a0009440: eb0002a8 bl a0009ee8 <_CORE_mutex_Seize>
((_Options_Is_no_wait( option_set )) ? false : true),
timeout,
level
);
return _Semaphore_Translate_core_mutex_return_code(
_Thread_Executing->Wait.return_code );
a0009444: e5973004 ldr r3, [r7, #4]
id,
((_Options_Is_no_wait( option_set )) ? false : true),
timeout,
level
);
return _Semaphore_Translate_core_mutex_return_code(
a0009448: e5930034 ldr r0, [r3, #52] ; 0x34
a000944c: eb000047 bl a0009570 <_Semaphore_Translate_core_mutex_return_code>
a0009450: ea000023 b a00094e4 <rtems_semaphore_obtain+0x104>
{
Thread_Control *executing;
/* disabled when you get here */
executing = _Thread_Executing;
a0009454: e5973004 ldr r3, [r7, #4]
executing->Wait.return_code = CORE_SEMAPHORE_STATUS_SUCCESSFUL;
a0009458: e5832034 str r2, [r3, #52] ; 0x34
if ( the_semaphore->count != 0 ) {
a000945c: e590205c ldr r2, [r0, #92] ; 0x5c
a0009460: e3520000 cmp r2, #0
a0009464: 0a000004 beq a000947c <rtems_semaphore_obtain+0x9c>
the_semaphore->count -= 1;
a0009468: e2422001 sub r2, r2, #1
a000946c: e580205c str r2, [r0, #92] ; 0x5c
a0009470: e59d3004 ldr r3, [sp, #4]
a0009474: e129f003 msr CPSR_fc, r3
a0009478: ea000015 b a00094d4 <rtems_semaphore_obtain+0xf4>
_ISR_Enable( *level_p );
return;
}
if ( !wait ) {
a000947c: e3160001 tst r6, #1
a0009480: 0a000004 beq a0009498 <rtems_semaphore_obtain+0xb8>
a0009484: e59d2004 ldr r2, [sp, #4] <== NOT EXECUTED
a0009488: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
_ISR_Enable( *level_p );
executing->Wait.return_code = CORE_SEMAPHORE_STATUS_UNSATISFIED_NOWAIT;
a000948c: e3a02001 mov r2, #1 <== NOT EXECUTED
a0009490: e5832034 str r2, [r3, #52] ; 0x34 <== NOT EXECUTED
a0009494: ea00000e b a00094d4 <rtems_semaphore_obtain+0xf4> <== NOT EXECUTED
a0009498: e59f2050 ldr r2, [pc, #80] ; a00094f0 <rtems_semaphore_obtain+0x110>
a000949c: e5921000 ldr r1, [r2]
a00094a0: e2811001 add r1, r1, #1
a00094a4: e5821000 str r1, [r2]
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a00094a8: e3a02001 mov r2, #1
a00094ac: e5802044 str r2, [r0, #68] ; 0x44
return;
}
_Thread_Disable_dispatch();
_Thread_queue_Enter_critical_section( &the_semaphore->Wait_queue );
executing->Wait.queue = &the_semaphore->Wait_queue;
a00094b0: e2800014 add r0, r0, #20
a00094b4: e5830044 str r0, [r3, #68] ; 0x44
executing->Wait.id = id;
a00094b8: e5834020 str r4, [r3, #32]
a00094bc: e59d3004 ldr r3, [sp, #4]
a00094c0: e129f003 msr CPSR_fc, r3
_ISR_Enable( *level_p );
_Thread_queue_Enqueue( &the_semaphore->Wait_queue, timeout );
a00094c4: e59f2028 ldr r2, [pc, #40] ; a00094f4 <rtems_semaphore_obtain+0x114>
a00094c8: e1a01005 mov r1, r5
a00094cc: eb00099a bl a000bb3c <_Thread_queue_Enqueue_with_handler>
_Thread_Enable_dispatch();
a00094d0: eb000870 bl a000b698 <_Thread_Enable_dispatch>
((_Options_Is_no_wait( option_set )) ? false : true),
timeout,
&level
);
return _Semaphore_Translate_core_semaphore_return_code(
_Thread_Executing->Wait.return_code );
a00094d4: e59f3010 ldr r3, [pc, #16] ; a00094ec <rtems_semaphore_obtain+0x10c>
a00094d8: e5933004 ldr r3, [r3, #4]
id,
((_Options_Is_no_wait( option_set )) ? false : true),
timeout,
&level
);
return _Semaphore_Translate_core_semaphore_return_code(
a00094dc: e5930034 ldr r0, [r3, #52] ; 0x34
a00094e0: eb000026 bl a0009580 <_Semaphore_Translate_core_semaphore_return_code>
break;
}
return RTEMS_INVALID_ID;
}
a00094e4: e8bd80fe pop {r1, r2, r3, r4, r5, r6, r7, pc}
a001753c <rtems_signal_send>:
rtems_status_code rtems_signal_send(
rtems_id id,
rtems_signal_set signal_set
)
{
a001753c: e92d4011 push {r0, r4, lr}
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
ASR_Information *asr;
if ( !signal_set )
a0017540: e2514000 subs r4, r1, #0
return RTEMS_INVALID_NUMBER;
a0017544: 03a0000a moveq r0, #10
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
ASR_Information *asr;
if ( !signal_set )
a0017548: 0a000028 beq a00175f0 <rtems_signal_send+0xb4>
return RTEMS_INVALID_NUMBER;
the_thread = _Thread_Get( id, &location );
a001754c: e1a0100d mov r1, sp
a0017550: eb0010d9 bl a001b8bc <_Thread_Get>
switch ( location ) {
a0017554: e59d3000 ldr r3, [sp]
a0017558: e3530000 cmp r3, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a001755c: 13a00004 movne r0, #4
if ( !signal_set )
return RTEMS_INVALID_NUMBER;
the_thread = _Thread_Get( id, &location );
switch ( location ) {
a0017560: 1a000022 bne a00175f0 <rtems_signal_send+0xb4>
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
a0017564: e59030f8 ldr r3, [r0, #248] ; 0xf8
asr = &api->Signal;
if ( ! _ASR_Is_null_handler( asr->handler ) ) {
a0017568: e593200c ldr r2, [r3, #12]
a001756c: e3520000 cmp r2, #0
a0017570: 0a00001c beq a00175e8 <rtems_signal_send+0xac>
if ( asr->is_enabled ) {
a0017574: e5d32008 ldrb r2, [r3, #8]
a0017578: e3520000 cmp r2, #0
a001757c: 0a00000f beq a00175c0 <rtems_signal_send+0x84>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0017580: e10f2000 mrs r2, CPSR
a0017584: e3821080 orr r1, r2, #128 ; 0x80
a0017588: e129f001 msr CPSR_fc, r1
)
{
ISR_Level _level;
_ISR_Disable( _level );
*signal_set |= signals;
a001758c: e5931014 ldr r1, [r3, #20]
a0017590: e1814004 orr r4, r1, r4
a0017594: e5834014 str r4, [r3, #20]
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0017598: e129f002 msr CPSR_fc, r2
_ASR_Post_signals( signal_set, &asr->signals_posted );
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
a001759c: e59f3050 ldr r3, [pc, #80] ; a00175f4 <rtems_signal_send+0xb8>
a00175a0: e5932000 ldr r2, [r3]
a00175a4: e3520000 cmp r2, #0
a00175a8: 0a00000b beq a00175dc <rtems_signal_send+0xa0>
a00175ac: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED
a00175b0: e1500002 cmp r0, r2 <== NOT EXECUTED
_Thread_Dispatch_necessary = true;
a00175b4: 03a02001 moveq r2, #1 <== NOT EXECUTED
a00175b8: 05c32010 strbeq r2, [r3, #16] <== NOT EXECUTED
a00175bc: ea000006 b a00175dc <rtems_signal_send+0xa0> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a00175c0: e10f2000 mrs r2, CPSR <== NOT EXECUTED
a00175c4: e3821080 orr r1, r2, #128 ; 0x80 <== NOT EXECUTED
a00175c8: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED
a00175cc: e5931018 ldr r1, [r3, #24] <== NOT EXECUTED
a00175d0: e1814004 orr r4, r1, r4 <== NOT EXECUTED
a00175d4: e5834018 str r4, [r3, #24] <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a00175d8: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
} else {
_ASR_Post_signals( signal_set, &asr->signals_pending );
}
_Thread_Enable_dispatch();
a00175dc: eb0010ad bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a00175e0: e3a00000 mov r0, #0
a00175e4: ea000001 b a00175f0 <rtems_signal_send+0xb4>
}
_Thread_Enable_dispatch();
a00175e8: eb0010aa bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_NOT_DEFINED;
a00175ec: e3a0000b mov r0, #11
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a00175f0: e8bd8018 pop {r3, r4, pc}
a000b5e0 <rtems_task_get_note>:
rtems_status_code rtems_task_get_note(
rtems_id id,
uint32_t notepad,
uint32_t *note
)
{
a000b5e0: e92d4071 push {r0, r4, r5, r6, lr}
a000b5e4: e1a05002 mov r5, r2
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
if ( !rtems_configuration_get_notepads_enabled() )
a000b5e8: e59f209c ldr r2, [pc, #156] ; a000b68c <rtems_task_get_note+0xac>
rtems_status_code rtems_task_get_note(
rtems_id id,
uint32_t notepad,
uint32_t *note
)
{
a000b5ec: e1a03000 mov r3, r0
a000b5f0: e1a04001 mov r4, r1
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
if ( !rtems_configuration_get_notepads_enabled() )
a000b5f4: e5d22004 ldrb r2, [r2, #4]
a000b5f8: e3520000 cmp r2, #0
return RTEMS_NOT_CONFIGURED;
a000b5fc: 03a00016 moveq r0, #22
{
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
if ( !rtems_configuration_get_notepads_enabled() )
a000b600: 0a000020 beq a000b688 <rtems_task_get_note+0xa8>
return RTEMS_NOT_CONFIGURED;
if ( !note )
a000b604: e3550000 cmp r5, #0
return RTEMS_INVALID_ADDRESS;
a000b608: 03a00009 moveq r0, #9
RTEMS_API_Control *api;
if ( !rtems_configuration_get_notepads_enabled() )
return RTEMS_NOT_CONFIGURED;
if ( !note )
a000b60c: 0a00001d beq a000b688 <rtems_task_get_note+0xa8>
/*
* NOTE: There is no check for < RTEMS_NOTEPAD_FIRST because that would
* be checking an unsigned number for being negative.
*/
if ( notepad > RTEMS_NOTEPAD_LAST )
a000b610: e351000f cmp r1, #15
return RTEMS_INVALID_NUMBER;
a000b614: 83a0000a movhi r0, #10
/*
* NOTE: There is no check for < RTEMS_NOTEPAD_FIRST because that would
* be checking an unsigned number for being negative.
*/
if ( notepad > RTEMS_NOTEPAD_LAST )
a000b618: 8a00001a bhi a000b688 <rtems_task_get_note+0xa8>
/*
* Optimize the most likely case to avoid the Thread_Dispatch.
*/
if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ||
a000b61c: e3530000 cmp r3, #0
a000b620: 0a000004 beq a000b638 <rtems_task_get_note+0x58>
_Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) {
a000b624: e59f2064 ldr r2, [pc, #100] ; a000b690 <rtems_task_get_note+0xb0>
a000b628: e5922004 ldr r2, [r2, #4]
/*
* Optimize the most likely case to avoid the Thread_Dispatch.
*/
if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ||
a000b62c: e5922008 ldr r2, [r2, #8]
a000b630: e1530002 cmp r3, r2
a000b634: 1a000007 bne a000b658 <rtems_task_get_note+0x78>
_Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) {
api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ];
a000b638: e59f3050 ldr r3, [pc, #80] ; a000b690 <rtems_task_get_note+0xb0>
*note = api->Notepads[ notepad ];
a000b63c: e2844008 add r4, r4, #8
return RTEMS_SUCCESSFUL;
a000b640: e3a00000 mov r0, #0
* Optimize the most likely case to avoid the Thread_Dispatch.
*/
if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ||
_Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) {
api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ];
a000b644: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
*note = api->Notepads[ notepad ];
a000b648: e59330f8 ldr r3, [r3, #248] ; 0xf8 <== NOT EXECUTED
a000b64c: e7933104 ldr r3, [r3, r4, lsl #2] <== NOT EXECUTED
a000b650: e5853000 str r3, [r5] <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a000b654: ea00000b b a000b688 <rtems_task_get_note+0xa8> <== NOT EXECUTED
}
the_thread = _Thread_Get( id, &location );
a000b658: e1a0100d mov r1, sp
a000b65c: eb00089f bl a000d8e0 <_Thread_Get>
switch ( location ) {
a000b660: e59d6000 ldr r6, [sp]
a000b664: e3560000 cmp r6, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000b668: 13a00004 movne r0, #4
*note = api->Notepads[ notepad ];
return RTEMS_SUCCESSFUL;
}
the_thread = _Thread_Get( id, &location );
switch ( location ) {
a000b66c: 1a000005 bne a000b688 <rtems_task_get_note+0xa8>
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
*note = api->Notepads[ notepad ];
a000b670: e59030f8 ldr r3, [r0, #248] ; 0xf8
a000b674: e2844008 add r4, r4, #8
a000b678: e7933104 ldr r3, [r3, r4, lsl #2]
a000b67c: e5853000 str r3, [r5]
_Thread_Enable_dispatch();
a000b680: eb00088d bl a000d8bc <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000b684: e1a00006 mov r0, r6
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a000b688: e8bd8078 pop {r3, r4, r5, r6, pc}
a0009754 <rtems_task_ident>:
rtems_id *id
)
{
Objects_Name_or_id_lookup_errors status;
if ( !id )
a0009754: e2523000 subs r3, r2, #0
rtems_status_code rtems_task_ident(
rtems_name name,
uint32_t node,
rtems_id *id
)
{
a0009758: e92d4010 push {r4, lr}
a000975c: e1a0c000 mov ip, r0
a0009760: e1a04001 mov r4, r1
Objects_Name_or_id_lookup_errors status;
if ( !id )
a0009764: 0a00000d beq a00097a0 <rtems_task_ident+0x4c>
return RTEMS_INVALID_ADDRESS;
if ( name == OBJECTS_ID_OF_SELF ) {
a0009768: e3500000 cmp r0, #0
a000976c: 1a000004 bne a0009784 <rtems_task_ident+0x30>
*id = _Thread_Executing->Object.id;
a0009770: e59f2030 ldr r2, [pc, #48] ; a00097a8 <rtems_task_ident+0x54>
a0009774: e5922004 ldr r2, [r2, #4]
a0009778: e5922008 ldr r2, [r2, #8]
a000977c: e5832000 str r2, [r3]
return RTEMS_SUCCESSFUL;
a0009780: e8bd8010 pop {r4, pc}
}
status = _Objects_Name_to_id_u32( &_RTEMS_tasks_Information, name, node, id );
a0009784: e59f0020 ldr r0, [pc, #32] ; a00097ac <rtems_task_ident+0x58>
a0009788: e1a0100c mov r1, ip
a000978c: e1a02004 mov r2, r4
a0009790: eb000542 bl a000aca0 <_Objects_Name_to_id_u32>
return _Status_Object_name_errors_to_status[ status ];
a0009794: e59f3014 ldr r3, [pc, #20] ; a00097b0 <rtems_task_ident+0x5c>
a0009798: e7930100 ldr r0, [r3, r0, lsl #2]
a000979c: e8bd8010 pop {r4, pc}
)
{
Objects_Name_or_id_lookup_errors status;
if ( !id )
return RTEMS_INVALID_ADDRESS;
a00097a0: e3a00009 mov r0, #9 <== NOT EXECUTED
}
status = _Objects_Name_to_id_u32( &_RTEMS_tasks_Information, name, node, id );
return _Status_Object_name_errors_to_status[ status ];
}
a00097a4: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a001794c <rtems_task_is_suspended>:
*/
rtems_status_code rtems_task_is_suspended(
rtems_id id
)
{
a001794c: e92d4011 push {r0, r4, lr}
register Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
a0017950: e1a0100d mov r1, sp
a0017954: eb000fd8 bl a001b8bc <_Thread_Get>
switch ( location ) {
a0017958: e59d3000 ldr r3, [sp]
a001795c: e3530000 cmp r3, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0017960: 13a00004 movne r0, #4
{
register Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
switch ( location ) {
a0017964: 1a000007 bne a0017988 <rtems_task_is_suspended+0x3c>
*/
RTEMS_INLINE_ROUTINE bool _States_Is_suspended (
States_Control the_states
)
{
return (the_states & STATES_SUSPENDED);
a0017968: e5904010 ldr r4, [r0, #16]
case OBJECTS_LOCAL:
if ( !_States_Is_suspended( the_thread->current_state ) ) {
a001796c: e2144002 ands r4, r4, #2 <== NOT EXECUTED
a0017970: 1a000002 bne a0017980 <rtems_task_is_suspended+0x34> <== NOT EXECUTED
_Thread_Enable_dispatch();
a0017974: eb000fc7 bl a001b898 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a0017978: e1a00004 mov r0, r4 <== NOT EXECUTED
a001797c: ea000001 b a0017988 <rtems_task_is_suspended+0x3c> <== NOT EXECUTED
}
_Thread_Enable_dispatch();
a0017980: eb000fc4 bl a001b898 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_ALREADY_SUSPENDED;
a0017984: e3a0000f mov r0, #15 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0017988: e8bd8018 pop {r3, r4, pc}
a0010bf8 <rtems_task_mode>:
rtems_status_code rtems_task_mode(
rtems_mode mode_set,
rtems_mode mask,
rtems_mode *previous_mode_set
)
{
a0010bf8: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr}
ASR_Information *asr;
bool is_asr_enabled = false;
bool needs_asr_dispatching = false;
rtems_mode old_mode;
if ( !previous_mode_set )
a0010bfc: e252a000 subs sl, r2, #0
rtems_status_code rtems_task_mode(
rtems_mode mode_set,
rtems_mode mask,
rtems_mode *previous_mode_set
)
{
a0010c00: e1a04000 mov r4, r0
a0010c04: e1a05001 mov r5, r1
ASR_Information *asr;
bool is_asr_enabled = false;
bool needs_asr_dispatching = false;
rtems_mode old_mode;
if ( !previous_mode_set )
a0010c08: 0a00004f beq a0010d4c <rtems_task_mode+0x154>
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
a0010c0c: e59f3144 ldr r3, [pc, #324] ; a0010d58 <rtems_task_mode+0x160>
a0010c10: e5937004 ldr r7, [r3, #4]
api = executing->API_Extensions[ THREAD_API_RTEMS ];
a0010c14: e59760f8 ldr r6, [r7, #248] ; 0xf8
asr = &api->Signal;
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
a0010c18: e5d78074 ldrb r8, [r7, #116] ; 0x74
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
a0010c1c: e597307c ldr r3, [r7, #124] ; 0x7c
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
a0010c20: e5d69008 ldrb r9, [r6, #8]
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
a0010c24: e3580000 cmp r8, #0
a0010c28: 03a08c01 moveq r8, #256 ; 0x100
a0010c2c: 13a08000 movne r8, #0
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
a0010c30: e3530000 cmp r3, #0
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
a0010c34: 13888c02 orrne r8, r8, #512 ; 0x200
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
a0010c38: e3590000 cmp r9, #0
a0010c3c: 03a09b01 moveq r9, #1024 ; 0x400
a0010c40: 13a09000 movne r9, #0
old_mode |= _ISR_Get_level();
a0010c44: ebffefd5 bl a000cba0 <_CPU_ISR_Get_level>
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
a0010c48: e1899000 orr r9, r9, r0
old_mode |= _ISR_Get_level();
a0010c4c: e1898008 orr r8, r9, r8
*previous_mode_set = old_mode;
/*
* These are generic thread scheduling characteristics.
*/
if ( mask & RTEMS_PREEMPT_MASK )
a0010c50: e3150c01 tst r5, #256 ; 0x100
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
old_mode |= _ISR_Get_level();
*previous_mode_set = old_mode;
a0010c54: e58a8000 str r8, [sl]
/*
* These are generic thread scheduling characteristics.
*/
if ( mask & RTEMS_PREEMPT_MASK )
a0010c58: 0a000003 beq a0010c6c <rtems_task_mode+0x74>
executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
a0010c5c: e3140c01 tst r4, #256 ; 0x100
a0010c60: 13a03000 movne r3, #0
a0010c64: 03a03001 moveq r3, #1
a0010c68: e5c73074 strb r3, [r7, #116] ; 0x74
if ( mask & RTEMS_TIMESLICE_MASK ) {
a0010c6c: e3150c02 tst r5, #512 ; 0x200
a0010c70: 0a000006 beq a0010c90 <rtems_task_mode+0x98>
if ( _Modes_Is_timeslice(mode_set) ) {
a0010c74: e2143c02 ands r3, r4, #512 ; 0x200
executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
a0010c78: 13a03001 movne r3, #1
a0010c7c: 1587307c strne r3, [r7, #124] ; 0x7c
executing->cpu_time_budget = _Thread_Ticks_per_timeslice;
a0010c80: 159f30d4 ldrne r3, [pc, #212] ; a0010d5c <rtems_task_mode+0x164>
} else
executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
a0010c84: 0587307c streq r3, [r7, #124] ; 0x7c
executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
if ( mask & RTEMS_TIMESLICE_MASK ) {
if ( _Modes_Is_timeslice(mode_set) ) {
executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
executing->cpu_time_budget = _Thread_Ticks_per_timeslice;
a0010c88: 15933000 ldrne r3, [r3]
a0010c8c: 15873078 strne r3, [r7, #120] ; 0x78
}
/*
* Set the new interrupt level
*/
if ( mask & RTEMS_INTERRUPT_MASK )
a0010c90: e3150080 tst r5, #128 ; 0x80
a0010c94: 0a000001 beq a0010ca0 <rtems_task_mode+0xa8>
*/
RTEMS_INLINE_ROUTINE void _Modes_Set_interrupt_level (
Modes_Control mode_set
)
{
_ISR_Set_level( _Modes_Get_interrupt_level( mode_set ) );
a0010c98: e2040080 and r0, r4, #128 ; 0x80
a0010c9c: ebffefba bl a000cb8c <_CPU_ISR_Set_level>
* This is specific to the RTEMS API
*/
is_asr_enabled = false;
needs_asr_dispatching = false;
if ( mask & RTEMS_ASR_MASK ) {
a0010ca0: e2150b01 ands r0, r5, #1024 ; 0x400
a0010ca4: 0a000013 beq a0010cf8 <rtems_task_mode+0x100>
is_asr_enabled = _Modes_Is_asr_disabled( mode_set ) ? false : true;
if ( is_asr_enabled != asr->is_enabled ) {
a0010ca8: e5d62008 ldrb r2, [r6, #8]
* Output:
* *previous_mode_set - previous mode set
* always return RTEMS_SUCCESSFUL;
*/
rtems_status_code rtems_task_mode(
a0010cac: e3140b01 tst r4, #1024 ; 0x400
a0010cb0: 13a03000 movne r3, #0
a0010cb4: 03a03001 moveq r3, #1
is_asr_enabled = false;
needs_asr_dispatching = false;
if ( mask & RTEMS_ASR_MASK ) {
is_asr_enabled = _Modes_Is_asr_disabled( mode_set ) ? false : true;
if ( is_asr_enabled != asr->is_enabled ) {
a0010cb8: e1520003 cmp r2, r3
/*
* This is specific to the RTEMS API
*/
is_asr_enabled = false;
needs_asr_dispatching = false;
a0010cbc: 03a00000 moveq r0, #0
if ( mask & RTEMS_ASR_MASK ) {
is_asr_enabled = _Modes_Is_asr_disabled( mode_set ) ? false : true;
if ( is_asr_enabled != asr->is_enabled ) {
a0010cc0: 0a00000c beq a0010cf8 <rtems_task_mode+0x100>
asr->is_enabled = is_asr_enabled;
a0010cc4: e5c63008 strb r3, [r6, #8]
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0010cc8: e10f3000 mrs r3, CPSR
a0010ccc: e3832080 orr r2, r3, #128 ; 0x80
a0010cd0: e129f002 msr CPSR_fc, r2
{
rtems_signal_set _signals;
ISR_Level _level;
_ISR_Disable( _level );
_signals = information->signals_pending;
a0010cd4: e5962018 ldr r2, [r6, #24]
information->signals_pending = information->signals_posted;
a0010cd8: e5961014 ldr r1, [r6, #20]
information->signals_posted = _signals;
a0010cdc: e5862014 str r2, [r6, #20]
rtems_signal_set _signals;
ISR_Level _level;
_ISR_Disable( _level );
_signals = information->signals_pending;
information->signals_pending = information->signals_posted;
a0010ce0: e5861018 str r1, [r6, #24]
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0010ce4: e129f003 msr CPSR_fc, r3
_ASR_Swap_signals( asr );
if ( _ASR_Are_signals_pending( asr ) ) {
a0010ce8: e5960014 ldr r0, [r6, #20]
/*
* This is specific to the RTEMS API
*/
is_asr_enabled = false;
needs_asr_dispatching = false;
a0010cec: e3500000 cmp r0, #0
a0010cf0: 13a00001 movne r0, #1
a0010cf4: 03a00000 moveq r0, #0
needs_asr_dispatching = true;
}
}
}
if ( _System_state_Is_up( _System_state_Get() ) ) {
a0010cf8: e59f3060 ldr r3, [pc, #96] ; a0010d60 <rtems_task_mode+0x168>
a0010cfc: e5933000 ldr r3, [r3]
a0010d00: e3530003 cmp r3, #3
if (_Thread_Evaluate_is_dispatch_needed( needs_asr_dispatching ) )
_Thread_Dispatch();
}
return RTEMS_SUCCESSFUL;
a0010d04: 13a00000 movne r0, #0
needs_asr_dispatching = true;
}
}
}
if ( _System_state_Is_up( _System_state_Get() ) ) {
a0010d08: 1a000011 bne a0010d54 <rtems_task_mode+0x15c>
bool are_signals_pending
)
{
Thread_Control *executing;
executing = _Thread_Executing;
a0010d0c: e59f2044 ldr r2, [pc, #68] ; a0010d58 <rtems_task_mode+0x160>
if ( are_signals_pending ||
a0010d10: e3500000 cmp r0, #0
bool are_signals_pending
)
{
Thread_Control *executing;
executing = _Thread_Executing;
a0010d14: e5923004 ldr r3, [r2, #4]
if ( are_signals_pending ||
a0010d18: 1a000005 bne a0010d34 <rtems_task_mode+0x13c>
a0010d1c: e5922008 ldr r2, [r2, #8]
a0010d20: e1530002 cmp r3, r2
a0010d24: 0a00000a beq a0010d54 <rtems_task_mode+0x15c>
(!_Thread_Is_heir( executing ) && executing->is_preemptible) ) {
a0010d28: e5d33074 ldrb r3, [r3, #116] ; 0x74
a0010d2c: e3530000 cmp r3, #0
a0010d30: 0a000007 beq a0010d54 <rtems_task_mode+0x15c>
_Thread_Dispatch_necessary = true;
a0010d34: e59f301c ldr r3, [pc, #28] ; a0010d58 <rtems_task_mode+0x160>
a0010d38: e3a02001 mov r2, #1
a0010d3c: e5c32010 strb r2, [r3, #16]
if (_Thread_Evaluate_is_dispatch_needed( needs_asr_dispatching ) )
_Thread_Dispatch();
a0010d40: ebffea10 bl a000b588 <_Thread_Dispatch>
}
return RTEMS_SUCCESSFUL;
a0010d44: e3a00000 mov r0, #0
a0010d48: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc}
bool is_asr_enabled = false;
bool needs_asr_dispatching = false;
rtems_mode old_mode;
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
a0010d4c: e3a00009 mov r0, #9 <== NOT EXECUTED
a0010d50: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED
if (_Thread_Evaluate_is_dispatch_needed( needs_asr_dispatching ) )
_Thread_Dispatch();
}
return RTEMS_SUCCESSFUL;
}
a0010d54: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc}
a000c914 <rtems_task_resume>:
*/
rtems_status_code rtems_task_resume(
rtems_id id
)
{
a000c914: e92d4011 push {r0, r4, lr}
register Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
a000c918: e1a0100d mov r1, sp
a000c91c: eb0007b5 bl a000e7f8 <_Thread_Get>
switch ( location ) {
a000c920: e59d4000 ldr r4, [sp]
)
{
register Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
a000c924: e1a03000 mov r3, r0
switch ( location ) {
a000c928: e3540000 cmp r4, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000c92c: 13a00004 movne r0, #4
{
register Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
switch ( location ) {
a000c930: 1a000009 bne a000c95c <rtems_task_resume+0x48>
*/
RTEMS_INLINE_ROUTINE bool _States_Is_suspended (
States_Control the_states
)
{
return (the_states & STATES_SUSPENDED);
a000c934: e5933010 ldr r3, [r3, #16]
case OBJECTS_LOCAL:
if ( _States_Is_suspended( the_thread->current_state ) ) {
a000c938: e3130002 tst r3, #2
a000c93c: 0a000004 beq a000c954 <rtems_task_resume+0x40>
_Thread_Resume( the_thread, true );
a000c940: e3a01001 mov r1, #1
a000c944: eb0009ae bl a000f004 <_Thread_Resume>
_Thread_Enable_dispatch();
a000c948: eb0007a1 bl a000e7d4 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000c94c: e1a00004 mov r0, r4
a000c950: ea000001 b a000c95c <rtems_task_resume+0x48>
}
_Thread_Enable_dispatch();
a000c954: eb00079e bl a000e7d4 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_INCORRECT_STATE;
a000c958: e3a0000e mov r0, #14 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a000c95c: e8bd8018 pop {r3, r4, pc}
a000b774 <rtems_task_set_note>:
rtems_status_code rtems_task_set_note(
rtems_id id,
uint32_t notepad,
uint32_t note
)
{
a000b774: e92d4071 push {r0, r4, r5, r6, lr}
a000b778: e1a05002 mov r5, r2
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
if ( !rtems_configuration_get_notepads_enabled() )
a000b77c: e59f2088 ldr r2, [pc, #136] ; a000b80c <rtems_task_set_note+0x98>
rtems_status_code rtems_task_set_note(
rtems_id id,
uint32_t notepad,
uint32_t note
)
{
a000b780: e1a03000 mov r3, r0
a000b784: e1a04001 mov r4, r1
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
if ( !rtems_configuration_get_notepads_enabled() )
a000b788: e5d22004 ldrb r2, [r2, #4]
a000b78c: e3520000 cmp r2, #0
return RTEMS_NOT_CONFIGURED;
a000b790: 03a00016 moveq r0, #22
{
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
if ( !rtems_configuration_get_notepads_enabled() )
a000b794: 0a00001b beq a000b808 <rtems_task_set_note+0x94>
/*
* NOTE: There is no check for < RTEMS_NOTEPAD_FIRST because that would
* be checking an unsigned number for being negative.
*/
if ( notepad > RTEMS_NOTEPAD_LAST )
a000b798: e351000f cmp r1, #15
return RTEMS_INVALID_NUMBER;
a000b79c: 83a0000a movhi r0, #10
/*
* NOTE: There is no check for < RTEMS_NOTEPAD_FIRST because that would
* be checking an unsigned number for being negative.
*/
if ( notepad > RTEMS_NOTEPAD_LAST )
a000b7a0: 8a000018 bhi a000b808 <rtems_task_set_note+0x94>
/*
* Optimize the most likely case to avoid the Thread_Dispatch.
*/
if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ||
a000b7a4: e3530000 cmp r3, #0
a000b7a8: 0a000004 beq a000b7c0 <rtems_task_set_note+0x4c>
_Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) {
a000b7ac: e59f205c ldr r2, [pc, #92] ; a000b810 <rtems_task_set_note+0x9c>
a000b7b0: e5922004 ldr r2, [r2, #4]
/*
* Optimize the most likely case to avoid the Thread_Dispatch.
*/
if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ||
a000b7b4: e5922008 ldr r2, [r2, #8]
a000b7b8: e1530002 cmp r3, r2
a000b7bc: 1a000006 bne a000b7dc <rtems_task_set_note+0x68>
_Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) {
api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ];
a000b7c0: e59f3048 ldr r3, [pc, #72] ; a000b810 <rtems_task_set_note+0x9c>
api->Notepads[ notepad ] = note;
a000b7c4: e2844008 add r4, r4, #8 <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a000b7c8: e3a00000 mov r0, #0 <== NOT EXECUTED
* Optimize the most likely case to avoid the Thread_Dispatch.
*/
if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ||
_Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) {
api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ];
a000b7cc: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
api->Notepads[ notepad ] = note;
a000b7d0: e59330f8 ldr r3, [r3, #248] ; 0xf8 <== NOT EXECUTED
a000b7d4: e7835104 str r5, [r3, r4, lsl #2] <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a000b7d8: ea00000a b a000b808 <rtems_task_set_note+0x94> <== NOT EXECUTED
}
the_thread = _Thread_Get( id, &location );
a000b7dc: e1a0100d mov r1, sp
a000b7e0: eb00083e bl a000d8e0 <_Thread_Get>
switch ( location ) {
a000b7e4: e59d6000 ldr r6, [sp]
a000b7e8: e3560000 cmp r6, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000b7ec: 13a00004 movne r0, #4
api->Notepads[ notepad ] = note;
return RTEMS_SUCCESSFUL;
}
the_thread = _Thread_Get( id, &location );
switch ( location ) {
a000b7f0: 1a000004 bne a000b808 <rtems_task_set_note+0x94>
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
api->Notepads[ notepad ] = note;
a000b7f4: e59030f8 ldr r3, [r0, #248] ; 0xf8
a000b7f8: e2844008 add r4, r4, #8
a000b7fc: e7835104 str r5, [r3, r4, lsl #2]
_Thread_Enable_dispatch();
a000b800: eb00082d bl a000d8bc <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000b804: e1a00006 mov r0, r6
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a000b808: e8bd8078 pop {r3, r4, r5, r6, pc}
a000d9c4 <rtems_task_set_priority>:
rtems_status_code rtems_task_set_priority(
rtems_id id,
rtems_task_priority new_priority,
rtems_task_priority *old_priority
)
{
a000d9c4: e92d4031 push {r0, r4, r5, lr}
register Thread_Control *the_thread;
Objects_Locations location;
if ( new_priority != RTEMS_CURRENT_PRIORITY &&
a000d9c8: e2514000 subs r4, r1, #0
rtems_status_code rtems_task_set_priority(
rtems_id id,
rtems_task_priority new_priority,
rtems_task_priority *old_priority
)
{
a000d9cc: e1a05002 mov r5, r2
register Thread_Control *the_thread;
Objects_Locations location;
if ( new_priority != RTEMS_CURRENT_PRIORITY &&
a000d9d0: 0a000004 beq a000d9e8 <rtems_task_set_priority+0x24>
RTEMS_INLINE_ROUTINE bool _RTEMS_tasks_Priority_is_valid (
rtems_task_priority the_priority
)
{
return ( ( the_priority >= RTEMS_MINIMUM_PRIORITY ) &&
( the_priority <= RTEMS_MAXIMUM_PRIORITY ) );
a000d9d4: e59f3074 ldr r3, [pc, #116] ; a000da50 <rtems_task_set_priority+0x8c>
a000d9d8: e5d33000 ldrb r3, [r3]
a000d9dc: e1540003 cmp r4, r3
!_RTEMS_tasks_Priority_is_valid( new_priority ) )
return RTEMS_INVALID_PRIORITY;
a000d9e0: 83a00013 movhi r0, #19
)
{
register Thread_Control *the_thread;
Objects_Locations location;
if ( new_priority != RTEMS_CURRENT_PRIORITY &&
a000d9e4: 8a000018 bhi a000da4c <rtems_task_set_priority+0x88>
!_RTEMS_tasks_Priority_is_valid( new_priority ) )
return RTEMS_INVALID_PRIORITY;
if ( !old_priority )
a000d9e8: e3550000 cmp r5, #0
return RTEMS_INVALID_ADDRESS;
a000d9ec: 03a00009 moveq r0, #9
if ( new_priority != RTEMS_CURRENT_PRIORITY &&
!_RTEMS_tasks_Priority_is_valid( new_priority ) )
return RTEMS_INVALID_PRIORITY;
if ( !old_priority )
a000d9f0: 0a000015 beq a000da4c <rtems_task_set_priority+0x88>
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get( id, &location );
a000d9f4: e1a0100d mov r1, sp
a000d9f8: eb000834 bl a000fad0 <_Thread_Get>
switch ( location ) {
a000d9fc: e59d3000 ldr r3, [sp]
a000da00: e3530000 cmp r3, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000da04: 13a00004 movne r0, #4
if ( !old_priority )
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get( id, &location );
switch ( location ) {
a000da08: 1a00000f bne a000da4c <rtems_task_set_priority+0x88>
case OBJECTS_LOCAL:
/* XXX need helper to "convert" from core priority */
*old_priority = the_thread->current_priority;
a000da0c: e5903014 ldr r3, [r0, #20]
if ( new_priority != RTEMS_CURRENT_PRIORITY ) {
a000da10: e3540000 cmp r4, #0
the_thread = _Thread_Get( id, &location );
switch ( location ) {
case OBJECTS_LOCAL:
/* XXX need helper to "convert" from core priority */
*old_priority = the_thread->current_priority;
a000da14: e5853000 str r3, [r5]
if ( new_priority != RTEMS_CURRENT_PRIORITY ) {
a000da18: 0a000009 beq a000da44 <rtems_task_set_priority+0x80>
the_thread->real_priority = new_priority;
if ( the_thread->resource_count == 0 ||
a000da1c: e590301c ldr r3, [r0, #28]
case OBJECTS_LOCAL:
/* XXX need helper to "convert" from core priority */
*old_priority = the_thread->current_priority;
if ( new_priority != RTEMS_CURRENT_PRIORITY ) {
the_thread->real_priority = new_priority;
a000da20: e5804018 str r4, [r0, #24]
if ( the_thread->resource_count == 0 ||
a000da24: e3530000 cmp r3, #0
a000da28: 0a000002 beq a000da38 <rtems_task_set_priority+0x74>
a000da2c: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED
a000da30: e1530004 cmp r3, r4 <== NOT EXECUTED
a000da34: 9a000002 bls a000da44 <rtems_task_set_priority+0x80> <== NOT EXECUTED
the_thread->current_priority > new_priority )
_Thread_Change_priority( the_thread, new_priority, false );
a000da38: e1a01004 mov r1, r4
a000da3c: e3a02000 mov r2, #0
a000da40: eb0006f3 bl a000f614 <_Thread_Change_priority>
}
_Thread_Enable_dispatch();
a000da44: eb000818 bl a000faac <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000da48: e3a00000 mov r0, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a000da4c: e8bd8038 pop {r3, r4, r5, pc}
a0009834 <rtems_task_start>:
rtems_status_code rtems_task_start(
rtems_id id,
rtems_task_entry entry_point,
rtems_task_argument argument
)
{
a0009834: e92d4073 push {r0, r1, r4, r5, r6, lr}
register Thread_Control *the_thread;
Objects_Locations location;
if ( entry_point == NULL )
a0009838: e2515000 subs r5, r1, #0
rtems_status_code rtems_task_start(
rtems_id id,
rtems_task_entry entry_point,
rtems_task_argument argument
)
{
a000983c: e1a06002 mov r6, r2
register Thread_Control *the_thread;
Objects_Locations location;
if ( entry_point == NULL )
return RTEMS_INVALID_ADDRESS;
a0009840: 03a00009 moveq r0, #9
)
{
register Thread_Control *the_thread;
Objects_Locations location;
if ( entry_point == NULL )
a0009844: 0a000011 beq a0009890 <rtems_task_start+0x5c>
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get( id, &location );
a0009848: e28d1004 add r1, sp, #4
a000984c: eb00079a bl a000b6bc <_Thread_Get>
switch ( location ) {
a0009850: e59d4004 ldr r4, [sp, #4]
a0009854: e3540000 cmp r4, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0009858: 13a00004 movne r0, #4
if ( entry_point == NULL )
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get( id, &location );
switch ( location ) {
a000985c: 1a00000b bne a0009890 <rtems_task_start+0x5c>
case OBJECTS_LOCAL:
if ( _Thread_Start(
a0009860: e1a01004 mov r1, r4
a0009864: e1a02005 mov r2, r5
a0009868: e1a03004 mov r3, r4
a000986c: e58d6000 str r6, [sp]
a0009870: eb000a08 bl a000c098 <_Thread_Start>
a0009874: e3500000 cmp r0, #0
a0009878: 0a000002 beq a0009888 <rtems_task_start+0x54>
the_thread, THREAD_START_NUMERIC, entry_point, NULL, argument ) ) {
_Thread_Enable_dispatch();
a000987c: eb000785 bl a000b698 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0009880: e1a00004 mov r0, r4
a0009884: ea000001 b a0009890 <rtems_task_start+0x5c>
}
_Thread_Enable_dispatch();
a0009888: eb000782 bl a000b698 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_INCORRECT_STATE;
a000988c: e3a0000e mov r0, #14 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0009890: e8bd807c pop {r2, r3, r4, r5, r6, pc}
a000cb78 <rtems_task_suspend>:
*/
rtems_status_code rtems_task_suspend(
rtems_id id
)
{
a000cb78: e92d4011 push {r0, r4, lr}
register Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
a000cb7c: e1a0100d mov r1, sp
a000cb80: eb000785 bl a000e99c <_Thread_Get>
switch ( location ) {
a000cb84: e59d2000 ldr r2, [sp]
)
{
register Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
a000cb88: e1a03000 mov r3, r0
switch ( location ) {
a000cb8c: e3520000 cmp r2, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000cb90: 13a00004 movne r0, #4
{
register Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
switch ( location ) {
a000cb94: 1a000008 bne a000cbbc <rtems_task_suspend+0x44>
*/
RTEMS_INLINE_ROUTINE bool _States_Is_suspended (
States_Control the_states
)
{
return (the_states & STATES_SUSPENDED);
a000cb98: e5934010 ldr r4, [r3, #16]
case OBJECTS_LOCAL:
if ( !_States_Is_suspended( the_thread->current_state ) ) {
a000cb9c: e2144002 ands r4, r4, #2
a000cba0: 1a000003 bne a000cbb4 <rtems_task_suspend+0x3c>
_Thread_Suspend( the_thread );
a000cba4: eb000a06 bl a000f3c4 <_Thread_Suspend>
_Thread_Enable_dispatch();
a000cba8: eb000772 bl a000e978 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000cbac: e1a00004 mov r0, r4
a000cbb0: ea000001 b a000cbbc <rtems_task_suspend+0x44>
}
_Thread_Enable_dispatch();
a000cbb4: eb00076f bl a000e978 <_Thread_Enable_dispatch>
return RTEMS_ALREADY_SUSPENDED;
a000cbb8: e3a0000f mov r0, #15
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a000cbbc: e8bd8018 pop {r3, r4, pc}
a000a550 <rtems_task_variable_add>:
rtems_status_code rtems_task_variable_add(
rtems_id tid,
void **ptr,
void (*dtor)(void *)
)
{
a000a550: e92d40f1 push {r0, r4, r5, r6, r7, lr}
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp, *new;
if ( !ptr )
a000a554: e2514000 subs r4, r1, #0
rtems_status_code rtems_task_variable_add(
rtems_id tid,
void **ptr,
void (*dtor)(void *)
)
{
a000a558: e1a05002 mov r5, r2
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp, *new;
if ( !ptr )
return RTEMS_INVALID_ADDRESS;
a000a55c: 03a00009 moveq r0, #9
{
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp, *new;
if ( !ptr )
a000a560: 0a000023 beq a000a5f4 <rtems_task_variable_add+0xa4>
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get (tid, &location);
a000a564: e1a0100d mov r1, sp
a000a568: eb0007d5 bl a000c4c4 <_Thread_Get>
switch (location) {
a000a56c: e59d3000 ldr r3, [sp]
rtems_task_variable_t *tvp, *new;
if ( !ptr )
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get (tid, &location);
a000a570: e1a07000 mov r7, r0
switch (location) {
a000a574: e3530000 cmp r3, #0
case OBJECTS_LOCAL:
/*
* Figure out if the variable is already in this task's list.
*/
tvp = the_thread->task_variables;
a000a578: 05906104 ldreq r6, [r0, #260] ; 0x104
if ( !ptr )
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get (tid, &location);
switch (location) {
a000a57c: 0a000008 beq a000a5a4 <rtems_task_variable_add+0x54>
a000a580: ea00001a b a000a5f0 <rtems_task_variable_add+0xa0>
/*
* Figure out if the variable is already in this task's list.
*/
tvp = the_thread->task_variables;
while (tvp) {
if (tvp->ptr == ptr) {
a000a584: e5963004 ldr r3, [r6, #4] <== NOT EXECUTED
a000a588: e1530004 cmp r3, r4 <== NOT EXECUTED
a000a58c: 1a000003 bne a000a5a0 <rtems_task_variable_add+0x50> <== NOT EXECUTED
tvp->dtor = dtor;
a000a590: e5865010 str r5, [r6, #16] <== NOT EXECUTED
_Thread_Enable_dispatch();
a000a594: eb0007c1 bl a000c4a0 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a000a598: e3a00000 mov r0, #0 <== NOT EXECUTED
a000a59c: ea000014 b a000a5f4 <rtems_task_variable_add+0xa4> <== NOT EXECUTED
}
tvp = (rtems_task_variable_t *)tvp->next;
a000a5a0: e5966000 ldr r6, [r6] <== NOT EXECUTED
case OBJECTS_LOCAL:
/*
* Figure out if the variable is already in this task's list.
*/
tvp = the_thread->task_variables;
while (tvp) {
a000a5a4: e3560000 cmp r6, #0
a000a5a8: 1afffff5 bne a000a584 <rtems_task_variable_add+0x34>
/*
* Now allocate memory for this task variable.
*/
new = (rtems_task_variable_t *)
_Workspace_Allocate(sizeof(rtems_task_variable_t));
a000a5ac: e3a00014 mov r0, #20
a000a5b0: eb000c00 bl a000d5b8 <_Workspace_Allocate>
if (new == NULL) {
a000a5b4: e3500000 cmp r0, #0
a000a5b8: 1a000002 bne a000a5c8 <rtems_task_variable_add+0x78>
_Thread_Enable_dispatch();
a000a5bc: eb0007b7 bl a000c4a0 <_Thread_Enable_dispatch>
return RTEMS_NO_MEMORY;
a000a5c0: e3a0001a mov r0, #26
a000a5c4: ea00000a b a000a5f4 <rtems_task_variable_add+0xa4>
}
new->gval = *ptr;
a000a5c8: e5943000 ldr r3, [r4]
new->ptr = ptr;
a000a5cc: e5804004 str r4, [r0, #4]
new->dtor = dtor;
a000a5d0: e5805010 str r5, [r0, #16]
_Workspace_Allocate(sizeof(rtems_task_variable_t));
if (new == NULL) {
_Thread_Enable_dispatch();
return RTEMS_NO_MEMORY;
}
new->gval = *ptr;
a000a5d4: e5803008 str r3, [r0, #8]
new->ptr = ptr;
new->dtor = dtor;
new->next = (struct rtems_task_variable_tt *)the_thread->task_variables;
a000a5d8: e5973104 ldr r3, [r7, #260] ; 0x104
a000a5dc: e5803000 str r3, [r0]
the_thread->task_variables = new;
a000a5e0: e5870104 str r0, [r7, #260] ; 0x104
_Thread_Enable_dispatch();
a000a5e4: eb0007ad bl a000c4a0 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000a5e8: e1a00006 mov r0, r6
a000a5ec: ea000000 b a000a5f4 <rtems_task_variable_add+0xa4>
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000a5f0: e3a00004 mov r0, #4
}
a000a5f4: e8bd80f8 pop {r3, r4, r5, r6, r7, pc}
a000a5f8 <rtems_task_variable_delete>:
rtems_status_code rtems_task_variable_delete(
rtems_id tid,
void **ptr
)
{
a000a5f8: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp, *prev;
if ( !ptr )
a000a5fc: e2514000 subs r4, r1, #0 <== NOT EXECUTED
a000a600: 0a000016 beq a000a660 <rtems_task_variable_delete+0x68> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
prev = NULL;
the_thread = _Thread_Get (tid, &location);
a000a604: e1a0100d mov r1, sp <== NOT EXECUTED
a000a608: eb0007ad bl a000c4c4 <_Thread_Get> <== NOT EXECUTED
switch (location) {
a000a60c: e59d3000 ldr r3, [sp] <== NOT EXECUTED
a000a610: e3530000 cmp r3, #0 <== NOT EXECUTED
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
a000a614: 05901104 ldreq r1, [r0, #260] ; 0x104 <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
prev = NULL;
the_thread = _Thread_Get (tid, &location);
switch (location) {
a000a618: 0a00000d beq a000a654 <rtems_task_variable_delete+0x5c> <== NOT EXECUTED
a000a61c: ea000011 b a000a668 <rtems_task_variable_delete+0x70> <== NOT EXECUTED
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
if (tvp->ptr == ptr) {
a000a620: e5912004 ldr r2, [r1, #4] <== NOT EXECUTED
a000a624: e1520004 cmp r2, r4 <== NOT EXECUTED
a000a628: 1a000007 bne a000a64c <rtems_task_variable_delete+0x54> <== NOT EXECUTED
a000a62c: e5912000 ldr r2, [r1] <== NOT EXECUTED
if (prev)
a000a630: e3530000 cmp r3, #0 <== NOT EXECUTED
prev->next = tvp->next;
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
a000a634: 05802104 streq r2, [r0, #260] ; 0x104 <== NOT EXECUTED
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
if (tvp->ptr == ptr) {
if (prev)
prev->next = tvp->next;
a000a638: 15832000 strne r2, [r3] <== NOT EXECUTED
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
_RTEMS_Tasks_Invoke_task_variable_dtor( the_thread, tvp );
a000a63c: eb000028 bl a000a6e4 <_RTEMS_Tasks_Invoke_task_variable_dtor><== NOT EXECUTED
_Thread_Enable_dispatch();
a000a640: eb000796 bl a000c4a0 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a000a644: e3a00000 mov r0, #0 <== NOT EXECUTED
a000a648: ea000007 b a000a66c <rtems_task_variable_delete+0x74> <== NOT EXECUTED
}
prev = tvp;
tvp = (rtems_task_variable_t *)tvp->next;
a000a64c: e1a03001 mov r3, r1 <== NOT EXECUTED
a000a650: e5911000 ldr r1, [r1] <== NOT EXECUTED
the_thread = _Thread_Get (tid, &location);
switch (location) {
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
a000a654: e3510000 cmp r1, #0 <== NOT EXECUTED
a000a658: 1afffff0 bne a000a620 <rtems_task_variable_delete+0x28> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
}
prev = tvp;
tvp = (rtems_task_variable_t *)tvp->next;
}
_Thread_Enable_dispatch();
a000a65c: eb00078f bl a000c4a0 <_Thread_Enable_dispatch> <== NOT EXECUTED
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp, *prev;
if ( !ptr )
return RTEMS_INVALID_ADDRESS;
a000a660: e3a00009 mov r0, #9 <== NOT EXECUTED
a000a664: ea000000 b a000a66c <rtems_task_variable_delete+0x74> <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000a668: e3a00004 mov r0, #4 <== NOT EXECUTED
}
a000a66c: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000a670 <rtems_task_variable_get>:
rtems_status_code rtems_task_variable_get(
rtems_id tid,
void **ptr,
void **result
)
{
a000a670: e92d4031 push {r0, r4, r5, lr}
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp;
if ( !ptr )
a000a674: e2515000 subs r5, r1, #0
rtems_status_code rtems_task_variable_get(
rtems_id tid,
void **ptr,
void **result
)
{
a000a678: e1a04002 mov r4, r2
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp;
if ( !ptr )
a000a67c: 0a000014 beq a000a6d4 <rtems_task_variable_get+0x64>
return RTEMS_INVALID_ADDRESS;
if ( !result )
a000a680: e3520000 cmp r2, #0
a000a684: 0a000012 beq a000a6d4 <rtems_task_variable_get+0x64>
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get (tid, &location);
a000a688: e1a0100d mov r1, sp
a000a68c: eb00078c bl a000c4c4 <_Thread_Get>
switch (location) {
a000a690: e59d3000 ldr r3, [sp]
a000a694: e3530000 cmp r3, #0
case OBJECTS_LOCAL:
/*
* Figure out if the variable is in this task's list.
*/
tvp = the_thread->task_variables;
a000a698: 05903104 ldreq r3, [r0, #260] ; 0x104
if ( !result )
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get (tid, &location);
switch (location) {
a000a69c: 0a000009 beq a000a6c8 <rtems_task_variable_get+0x58>
a000a6a0: ea00000d b a000a6dc <rtems_task_variable_get+0x6c>
/*
* Figure out if the variable is in this task's list.
*/
tvp = the_thread->task_variables;
while (tvp) {
if (tvp->ptr == ptr) {
a000a6a4: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED
a000a6a8: e1520005 cmp r2, r5 <== NOT EXECUTED
a000a6ac: 1a000004 bne a000a6c4 <rtems_task_variable_get+0x54> <== NOT EXECUTED
/*
* Should this return the current (i.e not the
* saved) value if `tid' is the current task?
*/
*result = tvp->tval;
a000a6b0: e593300c ldr r3, [r3, #12] <== NOT EXECUTED
a000a6b4: e5843000 str r3, [r4] <== NOT EXECUTED
_Thread_Enable_dispatch();
a000a6b8: eb000778 bl a000c4a0 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a000a6bc: e3a00000 mov r0, #0 <== NOT EXECUTED
a000a6c0: ea000006 b a000a6e0 <rtems_task_variable_get+0x70> <== NOT EXECUTED
}
tvp = (rtems_task_variable_t *)tvp->next;
a000a6c4: e5933000 ldr r3, [r3] <== NOT EXECUTED
case OBJECTS_LOCAL:
/*
* Figure out if the variable is in this task's list.
*/
tvp = the_thread->task_variables;
while (tvp) {
a000a6c8: e3530000 cmp r3, #0 <== NOT EXECUTED
a000a6cc: 1afffff4 bne a000a6a4 <rtems_task_variable_get+0x34> <== NOT EXECUTED
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
tvp = (rtems_task_variable_t *)tvp->next;
}
_Thread_Enable_dispatch();
a000a6d0: eb000772 bl a000c4a0 <_Thread_Enable_dispatch> <== NOT EXECUTED
if ( !ptr )
return RTEMS_INVALID_ADDRESS;
if ( !result )
return RTEMS_INVALID_ADDRESS;
a000a6d4: e3a00009 mov r0, #9
a000a6d8: ea000000 b a000a6e0 <rtems_task_variable_get+0x70>
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a000a6dc: e3a00004 mov r0, #4
}
a000a6e0: e8bd8038 pop {r3, r4, r5, pc}
a000aad4 <rtems_task_wake_when>:
rtems_time_of_day *time_buffer
)
{
Watchdog_Interval seconds;
if ( !_TOD_Is_set )
a000aad4: e59f30c8 ldr r3, [pc, #200] ; a000aba4 <rtems_task_wake_when+0xd0>
*/
rtems_status_code rtems_task_wake_when(
rtems_time_of_day *time_buffer
)
{
a000aad8: e92d40f0 push {r4, r5, r6, r7, lr}
Watchdog_Interval seconds;
if ( !_TOD_Is_set )
a000aadc: e5d33000 ldrb r3, [r3]
*/
rtems_status_code rtems_task_wake_when(
rtems_time_of_day *time_buffer
)
{
a000aae0: e1a05000 mov r5, r0
Watchdog_Interval seconds;
if ( !_TOD_Is_set )
a000aae4: e3530000 cmp r3, #0
a000aae8: 0a000025 beq a000ab84 <rtems_task_wake_when+0xb0>
return RTEMS_NOT_DEFINED;
if ( !time_buffer )
a000aaec: e3500000 cmp r0, #0
a000aaf0: 0a000025 beq a000ab8c <rtems_task_wake_when+0xb8>
return RTEMS_INVALID_ADDRESS;
time_buffer->ticks = 0;
a000aaf4: e3a04000 mov r4, #0
a000aaf8: e5804018 str r4, [r0, #24]
if ( !_TOD_Validate( time_buffer ) )
a000aafc: ebfffd1a bl a0009f6c <_TOD_Validate>
a000ab00: e1500004 cmp r0, r4
a000ab04: 0a000022 beq a000ab94 <rtems_task_wake_when+0xc0>
return RTEMS_INVALID_CLOCK;
seconds = _TOD_To_seconds( time_buffer );
a000ab08: e1a00005 mov r0, r5
a000ab0c: ebfffcf3 bl a0009ee0 <_TOD_To_seconds>
if ( seconds <= _TOD_Seconds_since_epoch() )
a000ab10: e59f6090 ldr r6, [pc, #144] ; a000aba8 <rtems_task_wake_when+0xd4>
time_buffer->ticks = 0;
if ( !_TOD_Validate( time_buffer ) )
return RTEMS_INVALID_CLOCK;
seconds = _TOD_To_seconds( time_buffer );
a000ab14: e1a05000 mov r5, r0
if ( seconds <= _TOD_Seconds_since_epoch() )
a000ab18: e5963000 ldr r3, [r6]
a000ab1c: e1500003 cmp r0, r3
a000ab20: 9a00001d bls a000ab9c <rtems_task_wake_when+0xc8>
a000ab24: e59f3080 ldr r3, [pc, #128] ; a000abac <rtems_task_wake_when+0xd8>
a000ab28: e5932000 ldr r2, [r3]
a000ab2c: e2822001 add r2, r2, #1
a000ab30: e5832000 str r2, [r3]
return RTEMS_INVALID_CLOCK;
_Thread_Disable_dispatch();
_Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_TIME );
a000ab34: e59f7074 ldr r7, [pc, #116] ; a000abb0 <rtems_task_wake_when+0xdc>
a000ab38: e3a01010 mov r1, #16
a000ab3c: e5970004 ldr r0, [r7, #4]
a000ab40: eb000999 bl a000d1ac <_Thread_Set_state>
_Watchdog_Initialize(
&_Thread_Executing->Timer,
a000ab44: e5971004 ldr r1, [r7, #4]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a000ab48: e59f2064 ldr r2, [pc, #100] ; a000abb4 <rtems_task_wake_when+0xe0>
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog );
a000ab4c: e59f0064 ldr r0, [pc, #100] ; a000abb8 <rtems_task_wake_when+0xe4>
if ( seconds <= _TOD_Seconds_since_epoch() )
return RTEMS_INVALID_CLOCK;
_Thread_Disable_dispatch();
_Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_TIME );
_Watchdog_Initialize(
a000ab50: e5913008 ldr r3, [r1, #8]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a000ab54: e5812064 str r2, [r1, #100] ; 0x64
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a000ab58: e5814050 str r4, [r1, #80] ; 0x50
the_watchdog->routine = routine;
the_watchdog->id = id;
a000ab5c: e5813068 str r3, [r1, #104] ; 0x68
&_Thread_Executing->Timer,
_Thread_Delay_ended,
_Thread_Executing->Object.id,
NULL
);
_Watchdog_Insert_seconds(
a000ab60: e5963000 ldr r3, [r6]
the_watchdog->user_data = user_data;
a000ab64: e581406c str r4, [r1, #108] ; 0x6c
a000ab68: e0635005 rsb r5, r3, r5
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a000ab6c: e5815054 str r5, [r1, #84] ; 0x54
_Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog );
a000ab70: e2811048 add r1, r1, #72 ; 0x48
a000ab74: eb000b27 bl a000d818 <_Watchdog_Insert>
&_Thread_Executing->Timer,
seconds - _TOD_Seconds_since_epoch()
);
_Thread_Enable_dispatch();
a000ab78: eb000776 bl a000c958 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a000ab7c: e1a00004 mov r0, r4 <== NOT EXECUTED
a000ab80: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
)
{
Watchdog_Interval seconds;
if ( !_TOD_Is_set )
return RTEMS_NOT_DEFINED;
a000ab84: e3a0000b mov r0, #11 <== NOT EXECUTED
a000ab88: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
if ( !time_buffer )
return RTEMS_INVALID_ADDRESS;
a000ab8c: e3a00009 mov r0, #9 <== NOT EXECUTED
a000ab90: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
time_buffer->ticks = 0;
if ( !_TOD_Validate( time_buffer ) )
return RTEMS_INVALID_CLOCK;
a000ab94: e3a00014 mov r0, #20 <== NOT EXECUTED
a000ab98: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
seconds = _TOD_To_seconds( time_buffer );
if ( seconds <= _TOD_Seconds_since_epoch() )
return RTEMS_INVALID_CLOCK;
a000ab9c: e3a00014 mov r0, #20 <== NOT EXECUTED
&_Thread_Executing->Timer,
seconds - _TOD_Seconds_since_epoch()
);
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
a000aba0: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
a0009d78 <rtems_timer_create>:
rtems_status_code rtems_timer_create(
rtems_name name,
rtems_id *id
)
{
a0009d78: e92d40f0 push {r4, r5, r6, r7, lr}
Timer_Control *the_timer;
if ( !rtems_is_name_valid( name ) )
a0009d7c: e2506000 subs r6, r0, #0
rtems_status_code rtems_timer_create(
rtems_name name,
rtems_id *id
)
{
a0009d80: e1a04001 mov r4, r1
Timer_Control *the_timer;
if ( !rtems_is_name_valid( name ) )
a0009d84: 0a00001d beq a0009e00 <rtems_timer_create+0x88>
return RTEMS_INVALID_NAME;
if ( !id )
a0009d88: e3510000 cmp r1, #0
a0009d8c: 0a00001d beq a0009e08 <rtems_timer_create+0x90>
a0009d90: e59f3078 ldr r3, [pc, #120] ; a0009e10 <rtems_timer_create+0x98>
a0009d94: e5932000 ldr r2, [r3]
a0009d98: e2822001 add r2, r2, #1
a0009d9c: e5832000 str r2, [r3]
* This function allocates a timer control block from
* the inactive chain of free timer control blocks.
*/
RTEMS_INLINE_ROUTINE Timer_Control *_Timer_Allocate( void )
{
return (Timer_Control *) _Objects_Allocate( &_Timer_Information );
a0009da0: e59f506c ldr r5, [pc, #108] ; a0009e14 <rtems_timer_create+0x9c>
a0009da4: e1a00005 mov r0, r5
a0009da8: eb0003b6 bl a000ac88 <_Objects_Allocate>
_Thread_Disable_dispatch(); /* to prevent deletion */
the_timer = _Timer_Allocate();
if ( !the_timer ) {
a0009dac: e3500000 cmp r0, #0
a0009db0: 1a000002 bne a0009dc0 <rtems_timer_create+0x48>
_Thread_Enable_dispatch();
a0009db4: eb00078c bl a000bbec <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_TOO_MANY;
a0009db8: e3a00005 mov r0, #5 <== NOT EXECUTED
a0009dbc: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
}
the_timer->the_class = TIMER_DORMANT;
a0009dc0: e3a03004 mov r3, #4
a0009dc4: e5803038 str r3, [r0, #56] ; 0x38
Objects_Information *information,
Objects_Control *the_object,
Objects_Name name
)
{
_Objects_Set_local_object(
a0009dc8: e1d010b8 ldrh r1, [r0, #8]
a0009dcc: e5903008 ldr r3, [r0, #8]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
a0009dd0: e595201c ldr r2, [r5, #28]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a0009dd4: e3a07000 mov r7, #0
a0009dd8: e5807018 str r7, [r0, #24]
the_watchdog->routine = routine;
a0009ddc: e580702c str r7, [r0, #44] ; 0x2c
the_watchdog->id = id;
a0009de0: e5807030 str r7, [r0, #48] ; 0x30
the_watchdog->user_data = user_data;
a0009de4: e5807034 str r7, [r0, #52] ; 0x34
a0009de8: e7820101 str r0, [r2, r1, lsl #2]
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
a0009dec: e580600c str r6, [r0, #12]
&_Timer_Information,
&the_timer->Object,
(Objects_Name) name
);
*id = the_timer->Object.id;
a0009df0: e5843000 str r3, [r4]
_Thread_Enable_dispatch();
a0009df4: eb00077c bl a000bbec <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0009df8: e1a00007 mov r0, r7
a0009dfc: e8bd80f0 pop {r4, r5, r6, r7, pc}
)
{
Timer_Control *the_timer;
if ( !rtems_is_name_valid( name ) )
return RTEMS_INVALID_NAME;
a0009e00: e3a00003 mov r0, #3 <== NOT EXECUTED
a0009e04: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
if ( !id )
return RTEMS_INVALID_ADDRESS;
a0009e08: e3a00009 mov r0, #9 <== NOT EXECUTED
);
*id = the_timer->Object.id;
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
a0009e0c: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
a0009e18 <rtems_timer_fire_after>:
rtems_id id,
rtems_interval ticks,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a0009e18: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr}
Timer_Control *the_timer;
Objects_Locations location;
ISR_Level level;
if ( ticks == 0 )
a0009e1c: e2516000 subs r6, r1, #0
rtems_id id,
rtems_interval ticks,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a0009e20: e1a04000 mov r4, r0
a0009e24: e1a05002 mov r5, r2
a0009e28: e1a07003 mov r7, r3
Timer_Control *the_timer;
Objects_Locations location;
ISR_Level level;
if ( ticks == 0 )
return RTEMS_INVALID_NUMBER;
a0009e2c: 03a0000a moveq r0, #10
{
Timer_Control *the_timer;
Objects_Locations location;
ISR_Level level;
if ( ticks == 0 )
a0009e30: 0a000022 beq a0009ec0 <rtems_timer_fire_after+0xa8>
return RTEMS_INVALID_NUMBER;
if ( !routine )
a0009e34: e3520000 cmp r2, #0
return RTEMS_INVALID_ADDRESS;
a0009e38: 03a00009 moveq r0, #9
ISR_Level level;
if ( ticks == 0 )
return RTEMS_INVALID_NUMBER;
if ( !routine )
a0009e3c: 0a00001f beq a0009ec0 <rtems_timer_fire_after+0xa8>
Objects_Id id,
Objects_Locations *location
)
{
return (Timer_Control *)
_Objects_Get( &_Timer_Information, id, location );
a0009e40: e59f007c ldr r0, [pc, #124] ; a0009ec4 <rtems_timer_fire_after+0xac>
a0009e44: e1a01004 mov r1, r4
a0009e48: e1a0200d mov r2, sp
a0009e4c: eb0004ae bl a000b10c <_Objects_Get>
return RTEMS_INVALID_ADDRESS;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0009e50: e59d3000 ldr r3, [sp]
a0009e54: e1a08000 mov r8, r0
a0009e58: e3530000 cmp r3, #0
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0009e5c: 13a00004 movne r0, #4
if ( !routine )
return RTEMS_INVALID_ADDRESS;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0009e60: 1a000016 bne a0009ec0 <rtems_timer_fire_after+0xa8>
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
a0009e64: e288a010 add sl, r8, #16
a0009e68: e1a0000a mov r0, sl
a0009e6c: eb000b3e bl a000cb6c <_Watchdog_Remove>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0009e70: e10f2000 mrs r2, CPSR
a0009e74: e3823080 orr r3, r2, #128 ; 0x80
a0009e78: e129f003 msr CPSR_fc, r3
/*
* Check to see if the watchdog has just been inserted by a
* higher priority interrupt. If so, abandon this insert.
*/
if ( the_timer->Ticker.state != WATCHDOG_INACTIVE ) {
a0009e7c: e5983018 ldr r3, [r8, #24]
a0009e80: e3530000 cmp r3, #0
a0009e84: 0a000001 beq a0009e90 <rtems_timer_fire_after+0x78>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0009e88: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
a0009e8c: ea000009 b a0009eb8 <rtems_timer_fire_after+0xa0> <== NOT EXECUTED
/*
* OK. Now we now the timer was not rescheduled by an interrupt
* so we can atomically initialize it as in use.
*/
the_timer->the_class = TIMER_INTERVAL;
a0009e90: e5883038 str r3, [r8, #56] ; 0x38
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a0009e94: e5883018 str r3, [r8, #24]
the_watchdog->routine = routine;
a0009e98: e588502c str r5, [r8, #44] ; 0x2c
the_watchdog->id = id;
a0009e9c: e5884030 str r4, [r8, #48] ; 0x30
the_watchdog->user_data = user_data;
a0009ea0: e5887034 str r7, [r8, #52] ; 0x34
a0009ea4: e129f002 msr CPSR_fc, r2
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a0009ea8: e59f0018 ldr r0, [pc, #24] ; a0009ec8 <rtems_timer_fire_after+0xb0>
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a0009eac: e588601c str r6, [r8, #28]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a0009eb0: e1a0100a mov r1, sl
a0009eb4: eb000ad4 bl a000ca0c <_Watchdog_Insert>
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
_ISR_Enable( level );
_Watchdog_Insert_ticks( &the_timer->Ticker, ticks );
_Thread_Enable_dispatch();
a0009eb8: eb00074b bl a000bbec <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0009ebc: e3a00000 mov r0, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0009ec0: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc}
a00180d4 <rtems_timer_fire_when>:
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00180d4: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr}
a00180d8: e1a08003 mov r8, r3
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
if ( !_TOD_Is_set )
a00180dc: e59f30c4 ldr r3, [pc, #196] ; a00181a8 <rtems_timer_fire_when+0xd4>
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00180e0: e1a04000 mov r4, r0
a00180e4: e1a06001 mov r6, r1
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
if ( !_TOD_Is_set )
a00180e8: e5d33000 ldrb r3, [r3]
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00180ec: e1a05002 mov r5, r2
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
if ( !_TOD_Is_set )
a00180f0: e3530000 cmp r3, #0
return RTEMS_NOT_DEFINED;
a00180f4: 03a0000b moveq r0, #11
{
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
if ( !_TOD_Is_set )
a00180f8: 0a000029 beq a00181a4 <rtems_timer_fire_when+0xd0>
return RTEMS_NOT_DEFINED;
if ( !_TOD_Validate( wall_time ) )
a00180fc: e1a00001 mov r0, r1
a0018100: ebfff53b bl a00155f4 <_TOD_Validate>
a0018104: e3500000 cmp r0, #0
a0018108: 0a000024 beq a00181a0 <rtems_timer_fire_when+0xcc>
return RTEMS_INVALID_CLOCK;
if ( !routine )
a001810c: e3550000 cmp r5, #0
return RTEMS_INVALID_ADDRESS;
a0018110: 03a00009 moveq r0, #9
return RTEMS_NOT_DEFINED;
if ( !_TOD_Validate( wall_time ) )
return RTEMS_INVALID_CLOCK;
if ( !routine )
a0018114: 0a000022 beq a00181a4 <rtems_timer_fire_when+0xd0>
return RTEMS_INVALID_ADDRESS;
seconds = _TOD_To_seconds( wall_time );
a0018118: e1a00006 mov r0, r6
a001811c: ebfff511 bl a0015568 <_TOD_To_seconds>
if ( seconds <= _TOD_Seconds_since_epoch() )
a0018120: e59f7084 ldr r7, [pc, #132] ; a00181ac <rtems_timer_fire_when+0xd8>
return RTEMS_INVALID_CLOCK;
if ( !routine )
return RTEMS_INVALID_ADDRESS;
seconds = _TOD_To_seconds( wall_time );
a0018124: e1a06000 mov r6, r0
if ( seconds <= _TOD_Seconds_since_epoch() )
a0018128: e5973000 ldr r3, [r7]
a001812c: e1500003 cmp r0, r3
a0018130: 9a00001a bls a00181a0 <rtems_timer_fire_when+0xcc>
a0018134: e59f0074 ldr r0, [pc, #116] ; a00181b0 <rtems_timer_fire_when+0xdc>
a0018138: e1a01004 mov r1, r4
a001813c: e1a0200d mov r2, sp
a0018140: eb000af8 bl a001ad28 <_Objects_Get>
return RTEMS_INVALID_CLOCK;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0018144: e59da000 ldr sl, [sp]
a0018148: e1a09000 mov r9, r0
a001814c: e35a0000 cmp sl, #0
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0018150: 13a00004 movne r0, #4
seconds = _TOD_To_seconds( wall_time );
if ( seconds <= _TOD_Seconds_since_epoch() )
return RTEMS_INVALID_CLOCK;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0018154: 1a000012 bne a00181a4 <rtems_timer_fire_when+0xd0>
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
a0018158: e289b010 add fp, r9, #16
a001815c: e1a0000b mov r0, fp
a0018160: eb00126f bl a001cb24 <_Watchdog_Remove>
the_timer->the_class = TIMER_TIME_OF_DAY;
a0018164: e3a03002 mov r3, #2
a0018168: e5893038 str r3, [r9, #56] ; 0x38
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
_Watchdog_Insert_seconds(
a001816c: e5973000 ldr r3, [r7]
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog );
a0018170: e59f003c ldr r0, [pc, #60] ; a00181b4 <rtems_timer_fire_when+0xe0>
a0018174: e1a0100b mov r1, fp
a0018178: e0636006 rsb r6, r3, r6
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a001817c: e589a018 str sl, [r9, #24]
the_watchdog->routine = routine;
a0018180: e589502c str r5, [r9, #44] ; 0x2c
the_watchdog->id = id;
a0018184: e5894030 str r4, [r9, #48] ; 0x30
the_watchdog->user_data = user_data;
a0018188: e5898034 str r8, [r9, #52] ; 0x34
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a001818c: e589601c str r6, [r9, #28]
_Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog );
a0018190: eb00120b bl a001c9c4 <_Watchdog_Insert>
&the_timer->Ticker,
seconds - _TOD_Seconds_since_epoch()
);
_Thread_Enable_dispatch();
a0018194: eb000dbf bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a0018198: e1a0000a mov r0, sl
a001819c: ea000000 b a00181a4 <rtems_timer_fire_when+0xd0>
if ( !routine )
return RTEMS_INVALID_ADDRESS;
seconds = _TOD_To_seconds( wall_time );
if ( seconds <= _TOD_Seconds_since_epoch() )
return RTEMS_INVALID_CLOCK;
a00181a0: e3a00014 mov r0, #20 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a00181a4: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc}
a00181b8 <rtems_timer_get_information>:
rtems_status_code rtems_timer_get_information(
rtems_id id,
rtems_timer_information *the_info
)
{
a00181b8: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
Timer_Control *the_timer;
Objects_Locations location;
if ( !the_info )
a00181bc: e2514000 subs r4, r1, #0 <== NOT EXECUTED
rtems_status_code rtems_timer_get_information(
rtems_id id,
rtems_timer_information *the_info
)
{
a00181c0: e1a03000 mov r3, r0 <== NOT EXECUTED
Timer_Control *the_timer;
Objects_Locations location;
if ( !the_info )
return RTEMS_INVALID_ADDRESS;
a00181c4: 03a00009 moveq r0, #9 <== NOT EXECUTED
)
{
Timer_Control *the_timer;
Objects_Locations location;
if ( !the_info )
a00181c8: 0a000011 beq a0018214 <rtems_timer_get_information+0x5c> <== NOT EXECUTED
a00181cc: e59f0044 ldr r0, [pc, #68] ; a0018218 <rtems_timer_get_information+0x60><== NOT EXECUTED
a00181d0: e1a01003 mov r1, r3 <== NOT EXECUTED
a00181d4: e1a0200d mov r2, sp <== NOT EXECUTED
a00181d8: eb000ad2 bl a001ad28 <_Objects_Get> <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a00181dc: e59d5000 ldr r5, [sp] <== NOT EXECUTED
a00181e0: e3550000 cmp r5, #0 <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a00181e4: 13a00004 movne r0, #4 <== NOT EXECUTED
if ( !the_info )
return RTEMS_INVALID_ADDRESS;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a00181e8: 1a000009 bne a0018214 <rtems_timer_get_information+0x5c> <== NOT EXECUTED
case OBJECTS_LOCAL:
the_info->the_class = the_timer->the_class;
a00181ec: e5903038 ldr r3, [r0, #56] ; 0x38 <== NOT EXECUTED
a00181f0: e5843000 str r3, [r4] <== NOT EXECUTED
the_info->initial = the_timer->Ticker.initial;
a00181f4: e590301c ldr r3, [r0, #28] <== NOT EXECUTED
a00181f8: e5843004 str r3, [r4, #4] <== NOT EXECUTED
the_info->start_time = the_timer->Ticker.start_time;
a00181fc: e5903024 ldr r3, [r0, #36] ; 0x24 <== NOT EXECUTED
a0018200: e5843008 str r3, [r4, #8] <== NOT EXECUTED
the_info->stop_time = the_timer->Ticker.stop_time;
a0018204: e5903028 ldr r3, [r0, #40] ; 0x28 <== NOT EXECUTED
a0018208: e584300c str r3, [r4, #12] <== NOT EXECUTED
_Thread_Enable_dispatch();
a001820c: eb000da1 bl a001b898 <_Thread_Enable_dispatch> <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
a0018210: e1a00005 mov r0, r5 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0018214: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a001824c <rtems_timer_reset>:
*/
rtems_status_code rtems_timer_reset(
rtems_id id
)
{
a001824c: e92d4071 push {r0, r4, r5, r6, lr}
a0018250: e1a01000 mov r1, r0
a0018254: e1a0200d mov r2, sp
a0018258: e59f0078 ldr r0, [pc, #120] ; a00182d8 <rtems_timer_reset+0x8c>
a001825c: eb000ab1 bl a001ad28 <_Objects_Get>
Timer_Control *the_timer;
Objects_Locations location;
rtems_status_code status = RTEMS_SUCCESSFUL;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0018260: e59d5000 ldr r5, [sp]
a0018264: e1a06000 mov r6, r0
a0018268: e3550000 cmp r5, #0
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a001826c: 13a04004 movne r4, #4
Timer_Control *the_timer;
Objects_Locations location;
rtems_status_code status = RTEMS_SUCCESSFUL;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0018270: 1a000016 bne a00182d0 <rtems_timer_reset+0x84>
case OBJECTS_LOCAL:
if ( the_timer->the_class == TIMER_INTERVAL ) {
a0018274: e5904038 ldr r4, [r0, #56] ; 0x38
a0018278: e3540000 cmp r4, #0
a001827c: 1a000006 bne a001829c <rtems_timer_reset+0x50>
_Watchdog_Remove( &the_timer->Ticker );
a0018280: e2806010 add r6, r0, #16
a0018284: e1a00006 mov r0, r6
a0018288: eb001225 bl a001cb24 <_Watchdog_Remove>
_Watchdog_Insert( &_Watchdog_Ticks_chain, &the_timer->Ticker );
a001828c: e59f0048 ldr r0, [pc, #72] ; a00182dc <rtems_timer_reset+0x90>
a0018290: e1a01006 mov r1, r6
a0018294: eb0011ca bl a001c9c4 <_Watchdog_Insert>
a0018298: ea00000b b a00182cc <rtems_timer_reset+0x80>
} else if ( the_timer->the_class == TIMER_INTERVAL_ON_TASK ) {
a001829c: e3540001 cmp r4, #1 <== NOT EXECUTED
/*
* Must be dormant or time of day timer (e.g. TIMER_DORMANT,
* TIMER_TIME_OF_DAY, or TIMER_TIME_OF_DAY_ON_TASK). We
* can only reset active interval timers.
*/
status = RTEMS_NOT_DEFINED;
a00182a0: 13a0400b movne r4, #11 <== NOT EXECUTED
case OBJECTS_LOCAL:
if ( the_timer->the_class == TIMER_INTERVAL ) {
_Watchdog_Remove( &the_timer->Ticker );
_Watchdog_Insert( &_Watchdog_Ticks_chain, &the_timer->Ticker );
} else if ( the_timer->the_class == TIMER_INTERVAL_ON_TASK ) {
a00182a4: 1a000008 bne a00182cc <rtems_timer_reset+0x80> <== NOT EXECUTED
Timer_server_Control *timer_server = _Timer_server;
a00182a8: e59f3030 ldr r3, [pc, #48] ; a00182e0 <rtems_timer_reset+0x94><== NOT EXECUTED
if ( !timer_server ) {
_Thread_Enable_dispatch();
return RTEMS_INCORRECT_STATE;
}
#endif
_Watchdog_Remove( &the_timer->Ticker );
a00182ac: e2800010 add r0, r0, #16 <== NOT EXECUTED
case OBJECTS_LOCAL:
if ( the_timer->the_class == TIMER_INTERVAL ) {
_Watchdog_Remove( &the_timer->Ticker );
_Watchdog_Insert( &_Watchdog_Ticks_chain, &the_timer->Ticker );
} else if ( the_timer->the_class == TIMER_INTERVAL_ON_TASK ) {
Timer_server_Control *timer_server = _Timer_server;
a00182b0: e5934000 ldr r4, [r3] <== NOT EXECUTED
if ( !timer_server ) {
_Thread_Enable_dispatch();
return RTEMS_INCORRECT_STATE;
}
#endif
_Watchdog_Remove( &the_timer->Ticker );
a00182b4: eb00121a bl a001cb24 <_Watchdog_Remove> <== NOT EXECUTED
(*timer_server->schedule_operation)( timer_server, the_timer );
a00182b8: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED
a00182bc: e1a00004 mov r0, r4 <== NOT EXECUTED
a00182c0: e1a01006 mov r1, r6 <== NOT EXECUTED
a00182c4: e12fff33 blx r3 <== NOT EXECUTED
rtems_id id
)
{
Timer_Control *the_timer;
Objects_Locations location;
rtems_status_code status = RTEMS_SUCCESSFUL;
a00182c8: e1a04005 mov r4, r5 <== NOT EXECUTED
* TIMER_TIME_OF_DAY, or TIMER_TIME_OF_DAY_ON_TASK). We
* can only reset active interval timers.
*/
status = RTEMS_NOT_DEFINED;
}
_Thread_Enable_dispatch();
a00182cc: eb000d71 bl a001b898 <_Thread_Enable_dispatch>
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a00182d0: e1a00004 mov r0, r4
a00182d4: e8bd8078 pop {r3, r4, r5, r6, pc}
a00182e4 <rtems_timer_server_fire_after>:
rtems_id id,
rtems_interval ticks,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00182e4: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr}
a00182e8: e1a08003 mov r8, r3
Timer_Control *the_timer;
Objects_Locations location;
ISR_Level level;
Timer_server_Control *timer_server = _Timer_server;
a00182ec: e59f30b8 ldr r3, [pc, #184] ; a00183ac <rtems_timer_server_fire_after+0xc8>
rtems_id id,
rtems_interval ticks,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00182f0: e1a05000 mov r5, r0
a00182f4: e1a04001 mov r4, r1
Timer_Control *the_timer;
Objects_Locations location;
ISR_Level level;
Timer_server_Control *timer_server = _Timer_server;
a00182f8: e5937000 ldr r7, [r3]
rtems_id id,
rtems_interval ticks,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00182fc: e1a06002 mov r6, r2
Timer_Control *the_timer;
Objects_Locations location;
ISR_Level level;
Timer_server_Control *timer_server = _Timer_server;
if ( !timer_server )
a0018300: e3570000 cmp r7, #0
return RTEMS_INCORRECT_STATE;
a0018304: 03a0000e moveq r0, #14
Timer_Control *the_timer;
Objects_Locations location;
ISR_Level level;
Timer_server_Control *timer_server = _Timer_server;
if ( !timer_server )
a0018308: 0a000026 beq a00183a8 <rtems_timer_server_fire_after+0xc4>
return RTEMS_INCORRECT_STATE;
if ( !routine )
a001830c: e3520000 cmp r2, #0
return RTEMS_INVALID_ADDRESS;
a0018310: 03a00009 moveq r0, #9
Timer_server_Control *timer_server = _Timer_server;
if ( !timer_server )
return RTEMS_INCORRECT_STATE;
if ( !routine )
a0018314: 0a000023 beq a00183a8 <rtems_timer_server_fire_after+0xc4>
return RTEMS_INVALID_ADDRESS;
if ( ticks == 0 )
a0018318: e3510000 cmp r1, #0
return RTEMS_INVALID_NUMBER;
a001831c: 03a0000a moveq r0, #10
return RTEMS_INCORRECT_STATE;
if ( !routine )
return RTEMS_INVALID_ADDRESS;
if ( ticks == 0 )
a0018320: 0a000020 beq a00183a8 <rtems_timer_server_fire_after+0xc4>
a0018324: e59f0084 ldr r0, [pc, #132] ; a00183b0 <rtems_timer_server_fire_after+0xcc>
a0018328: e1a01005 mov r1, r5
a001832c: e1a0200d mov r2, sp
a0018330: eb000a7c bl a001ad28 <_Objects_Get>
return RTEMS_INVALID_NUMBER;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0018334: e59d3000 ldr r3, [sp]
a0018338: e1a0a000 mov sl, r0
a001833c: e3530000 cmp r3, #0
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0018340: 13a00004 movne r0, #4
if ( ticks == 0 )
return RTEMS_INVALID_NUMBER;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0018344: 1a000017 bne a00183a8 <rtems_timer_server_fire_after+0xc4>
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
a0018348: e28a0010 add r0, sl, #16
a001834c: eb0011f4 bl a001cb24 <_Watchdog_Remove>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0018350: e10f3000 mrs r3, CPSR
a0018354: e3832080 orr r2, r3, #128 ; 0x80
a0018358: e129f002 msr CPSR_fc, r2
/*
* Check to see if the watchdog has just been inserted by a
* higher priority interrupt. If so, abandon this insert.
*/
if ( the_timer->Ticker.state != WATCHDOG_INACTIVE ) {
a001835c: e59a2018 ldr r2, [sl, #24]
a0018360: e3520000 cmp r2, #0
a0018364: 0a000001 beq a0018370 <rtems_timer_server_fire_after+0x8c>
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0018368: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
a001836c: ea00000b b a00183a0 <rtems_timer_server_fire_after+0xbc> <== NOT EXECUTED
/*
* OK. Now we now the timer was not rescheduled by an interrupt
* so we can atomically initialize it as in use.
*/
the_timer->the_class = TIMER_INTERVAL_ON_TASK;
a0018370: e3a01001 mov r1, #1
a0018374: e58a1038 str r1, [sl, #56] ; 0x38
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a0018378: e58a2018 str r2, [sl, #24]
the_watchdog->routine = routine;
a001837c: e58a602c str r6, [sl, #44] ; 0x2c
the_watchdog->id = id;
a0018380: e58a5030 str r5, [sl, #48] ; 0x30
the_watchdog->user_data = user_data;
a0018384: e58a8034 str r8, [sl, #52] ; 0x34
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = ticks;
a0018388: e58a401c str r4, [sl, #28]
a001838c: e129f003 msr CPSR_fc, r3
_ISR_Enable( level );
(*timer_server->schedule_operation)( timer_server, the_timer );
a0018390: e5973004 ldr r3, [r7, #4]
a0018394: e1a00007 mov r0, r7
a0018398: e1a0100a mov r1, sl
a001839c: e12fff33 blx r3
_Thread_Enable_dispatch();
a00183a0: eb000d3c bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a00183a4: e3a00000 mov r0, #0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a00183a8: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc}
a00183b4 <rtems_timer_server_fire_when>:
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00183b4: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr}
a00183b8: e1a0a003 mov sl, r3
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
Timer_server_Control *timer_server = _Timer_server;
a00183bc: e59f30d8 ldr r3, [pc, #216] ; a001849c <rtems_timer_server_fire_when+0xe8>
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00183c0: e1a04000 mov r4, r0
a00183c4: e1a07001 mov r7, r1
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
Timer_server_Control *timer_server = _Timer_server;
a00183c8: e5936000 ldr r6, [r3]
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
a00183cc: e1a05002 mov r5, r2
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
Timer_server_Control *timer_server = _Timer_server;
if ( !timer_server )
a00183d0: e3560000 cmp r6, #0
return RTEMS_INCORRECT_STATE;
a00183d4: 03a0000e moveq r0, #14
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
Timer_server_Control *timer_server = _Timer_server;
if ( !timer_server )
a00183d8: 0a00002e beq a0018498 <rtems_timer_server_fire_when+0xe4>
return RTEMS_INCORRECT_STATE;
if ( !_TOD_Is_set )
a00183dc: e59f30bc ldr r3, [pc, #188] ; a00184a0 <rtems_timer_server_fire_when+0xec>
a00183e0: e5d33000 ldrb r3, [r3]
a00183e4: e3530000 cmp r3, #0
return RTEMS_NOT_DEFINED;
a00183e8: 03a0000b moveq r0, #11
Timer_server_Control *timer_server = _Timer_server;
if ( !timer_server )
return RTEMS_INCORRECT_STATE;
if ( !_TOD_Is_set )
a00183ec: 0a000029 beq a0018498 <rtems_timer_server_fire_when+0xe4>
return RTEMS_NOT_DEFINED;
if ( !routine )
a00183f0: e3520000 cmp r2, #0
return RTEMS_INVALID_ADDRESS;
a00183f4: 03a00009 moveq r0, #9
return RTEMS_INCORRECT_STATE;
if ( !_TOD_Is_set )
return RTEMS_NOT_DEFINED;
if ( !routine )
a00183f8: 0a000026 beq a0018498 <rtems_timer_server_fire_when+0xe4>
return RTEMS_INVALID_ADDRESS;
if ( !_TOD_Validate( wall_time ) )
a00183fc: e1a00001 mov r0, r1
a0018400: ebfff47b bl a00155f4 <_TOD_Validate>
a0018404: e3500000 cmp r0, #0
a0018408: 0a000021 beq a0018494 <rtems_timer_server_fire_when+0xe0>
return RTEMS_INVALID_CLOCK;
seconds = _TOD_To_seconds( wall_time );
a001840c: e1a00007 mov r0, r7
a0018410: ebfff454 bl a0015568 <_TOD_To_seconds>
if ( seconds <= _TOD_Seconds_since_epoch() )
a0018414: e59f8088 ldr r8, [pc, #136] ; a00184a4 <rtems_timer_server_fire_when+0xf0>
return RTEMS_INVALID_ADDRESS;
if ( !_TOD_Validate( wall_time ) )
return RTEMS_INVALID_CLOCK;
seconds = _TOD_To_seconds( wall_time );
a0018418: e1a07000 mov r7, r0
if ( seconds <= _TOD_Seconds_since_epoch() )
a001841c: e5983000 ldr r3, [r8]
a0018420: e1500003 cmp r0, r3
a0018424: 9a00001a bls a0018494 <rtems_timer_server_fire_when+0xe0>
a0018428: e59f0078 ldr r0, [pc, #120] ; a00184a8 <rtems_timer_server_fire_when+0xf4>
a001842c: e1a01004 mov r1, r4
a0018430: e1a0200d mov r2, sp
a0018434: eb000a3b bl a001ad28 <_Objects_Get>
return RTEMS_INVALID_CLOCK;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0018438: e59d9000 ldr r9, [sp]
a001843c: e1a0b000 mov fp, r0
a0018440: e3590000 cmp r9, #0
#endif
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
a0018444: 13a00004 movne r0, #4
seconds = _TOD_To_seconds( wall_time );
if ( seconds <= _TOD_Seconds_since_epoch() )
return RTEMS_INVALID_CLOCK;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
a0018448: 1a000012 bne a0018498 <rtems_timer_server_fire_when+0xe4>
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
a001844c: e28b0010 add r0, fp, #16
a0018450: eb0011b3 bl a001cb24 <_Watchdog_Remove>
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
a0018454: e3a03003 mov r3, #3
a0018458: e58b3038 str r3, [fp, #56] ; 0x38
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
a001845c: e5983000 ldr r3, [r8]
(*timer_server->schedule_operation)( timer_server, the_timer );
a0018460: e1a00006 mov r0, r6
a0018464: e1a0100b mov r1, fp
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
a0018468: e0637007 rsb r7, r3, r7
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a001846c: e58b9018 str r9, [fp, #24]
(*timer_server->schedule_operation)( timer_server, the_timer );
a0018470: e5963004 ldr r3, [r6, #4]
the_watchdog->routine = routine;
a0018474: e58b502c str r5, [fp, #44] ; 0x2c
the_watchdog->id = id;
a0018478: e58b4030 str r4, [fp, #48] ; 0x30
the_watchdog->user_data = user_data;
a001847c: e58ba034 str sl, [fp, #52] ; 0x34
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
a0018480: e58b701c str r7, [fp, #28]
(*timer_server->schedule_operation)( timer_server, the_timer );
a0018484: e12fff33 blx r3
_Thread_Enable_dispatch();
a0018488: eb000d02 bl a001b898 <_Thread_Enable_dispatch>
return RTEMS_SUCCESSFUL;
a001848c: e1a00009 mov r0, r9
a0018490: ea000000 b a0018498 <rtems_timer_server_fire_when+0xe4>
if ( !_TOD_Validate( wall_time ) )
return RTEMS_INVALID_CLOCK;
seconds = _TOD_To_seconds( wall_time );
if ( seconds <= _TOD_Seconds_since_epoch() )
return RTEMS_INVALID_CLOCK;
a0018494: e3a00014 mov r0, #20 <== NOT EXECUTED
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
a0018498: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc}
a0009da8 <sched_get_priority_max>:
int sched_get_priority_max(
int policy
)
{
switch ( policy ) {
a0009da8: e3500004 cmp r0, #4
#include <rtems/posix/priority.h>
int sched_get_priority_max(
int policy
)
{
a0009dac: e52de004 push {lr} ; (str lr, [sp, #-4]!)
switch ( policy ) {
a0009db0: 8a000003 bhi a0009dc4 <sched_get_priority_max+0x1c>
a0009db4: e3a03001 mov r3, #1
a0009db8: e1a00013 lsl r0, r3, r0
a0009dbc: e3100017 tst r0, #23
a0009dc0: 1a000004 bne a0009dd8 <sched_get_priority_max+0x30>
case SCHED_RR:
case SCHED_SPORADIC:
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
a0009dc4: eb00206c bl a0011f7c <__errno>
a0009dc8: e3a03016 mov r3, #22
a0009dcc: e5803000 str r3, [r0] <== NOT EXECUTED
a0009dd0: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009dd4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
}
return POSIX_SCHEDULER_MAXIMUM_PRIORITY;
a0009dd8: e59f3008 ldr r3, [pc, #8] ; a0009de8 <sched_get_priority_max+0x40>
a0009ddc: e5d30000 ldrb r0, [r3]
a0009de0: e2400001 sub r0, r0, #1
}
a0009de4: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a0009dec <sched_get_priority_min>:
int sched_get_priority_min(
int policy
)
{
switch ( policy ) {
a0009dec: e3500004 cmp r0, #4
#include <rtems/posix/priority.h>
int sched_get_priority_min(
int policy
)
{
a0009df0: e52de004 push {lr} ; (str lr, [sp, #-4]!)
switch ( policy ) {
a0009df4: 8a000003 bhi a0009e08 <sched_get_priority_min+0x1c>
a0009df8: e3a03001 mov r3, #1
a0009dfc: e1a00013 lsl r0, r3, r0
a0009e00: e3100017 tst r0, #23
a0009e04: 1a000004 bne a0009e1c <sched_get_priority_min+0x30>
case SCHED_RR:
case SCHED_SPORADIC:
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
a0009e08: eb00205b bl a0011f7c <__errno> <== NOT EXECUTED
a0009e0c: e3a03016 mov r3, #22 <== NOT EXECUTED
a0009e10: e5803000 str r3, [r0] <== NOT EXECUTED
a0009e14: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009e18: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
}
return POSIX_SCHEDULER_MINIMUM_PRIORITY;
a0009e1c: e1a00003 mov r0, r3
}
a0009e20: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a000934c <sched_getparam>:
int sched_getparam(
pid_t pid __attribute__((unused)),
struct sched_param *param __attribute__((unused))
)
{
a000934c: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a0009350: eb0021a9 bl a00119fc <__errno> <== NOT EXECUTED
a0009354: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a0009358: e5803000 str r3, [r0] <== NOT EXECUTED
}
a000935c: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009360: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a0009364 <sched_getscheduler>:
#include <rtems/posix/time.h>
int sched_getscheduler(
pid_t pid __attribute__((unused))
)
{
a0009364: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a0009368: eb0021a3 bl a00119fc <__errno> <== NOT EXECUTED
a000936c: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a0009370: e5803000 str r3, [r0] <== NOT EXECUTED
}
a0009374: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009378: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a0009e24 <sched_rr_get_interval>:
int sched_rr_get_interval(
pid_t pid,
struct timespec *interval
)
{
a0009e24: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
/*
* Only supported for the "calling process" (i.e. this node).
*/
if ( pid && pid != getpid() )
a0009e28: e2505000 subs r5, r0, #0 <== NOT EXECUTED
int sched_rr_get_interval(
pid_t pid,
struct timespec *interval
)
{
a0009e2c: e1a04001 mov r4, r1 <== NOT EXECUTED
/*
* Only supported for the "calling process" (i.e. this node).
*/
if ( pid && pid != getpid() )
a0009e30: 0a000005 beq a0009e4c <sched_rr_get_interval+0x28> <== NOT EXECUTED
a0009e34: ebfff341 bl a0006b40 <getpid> <== NOT EXECUTED
a0009e38: e1550000 cmp r5, r0 <== NOT EXECUTED
a0009e3c: 0a000002 beq a0009e4c <sched_rr_get_interval+0x28> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ESRCH );
a0009e40: eb00204d bl a0011f7c <__errno> <== NOT EXECUTED
a0009e44: e3a03003 mov r3, #3 <== NOT EXECUTED
a0009e48: ea000003 b a0009e5c <sched_rr_get_interval+0x38> <== NOT EXECUTED
if ( !interval )
a0009e4c: e3540000 cmp r4, #0 <== NOT EXECUTED
a0009e50: 1a000004 bne a0009e68 <sched_rr_get_interval+0x44> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
a0009e54: eb002048 bl a0011f7c <__errno> <== NOT EXECUTED
a0009e58: e3a03016 mov r3, #22 <== NOT EXECUTED
a0009e5c: e5803000 str r3, [r0] <== NOT EXECUTED
a0009e60: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009e64: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
_Timespec_From_ticks( _Thread_Ticks_per_timeslice, interval );
a0009e68: e59f3010 ldr r3, [pc, #16] ; a0009e80 <sched_rr_get_interval+0x5c><== NOT EXECUTED
a0009e6c: e1a01004 mov r1, r4 <== NOT EXECUTED
a0009e70: e5930000 ldr r0, [r3] <== NOT EXECUTED
a0009e74: eb000d24 bl a000d30c <_Timespec_From_ticks> <== NOT EXECUTED
return 0;
a0009e78: e3a00000 mov r0, #0 <== NOT EXECUTED
}
a0009e7c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
a000937c <sched_setparam>:
int sched_setparam(
pid_t pid __attribute__((unused)),
const struct sched_param *param __attribute__((unused))
)
{
a000937c: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a0009380: eb00219d bl a00119fc <__errno> <== NOT EXECUTED
a0009384: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a0009388: e5803000 str r3, [r0] <== NOT EXECUTED
}
a000938c: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009390: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a0009394 <sched_setscheduler>:
int sched_setscheduler(
pid_t pid __attribute__((unused)),
int policy __attribute__((unused)),
const struct sched_param *param __attribute__((unused))
)
{
a0009394: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a0009398: eb002197 bl a00119fc <__errno> <== NOT EXECUTED
a000939c: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a00093a0: e5803000 str r3, [r0] <== NOT EXECUTED
}
a00093a4: e3e00000 mvn r0, #0 <== NOT EXECUTED
a00093a8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a000c2e0 <sem_close>:
*/
int sem_close(
sem_t *sem
)
{
a000c2e0: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
a000c2e4: e1a03000 mov r3, r0 <== NOT EXECUTED
sem_t *id,
Objects_Locations *location
)
{
return (POSIX_Semaphore_Control *)
_Objects_Get( &_POSIX_Semaphore_Information, (Objects_Id)*id, location );
a000c2e8: e5931000 ldr r1, [r3] <== NOT EXECUTED
a000c2ec: e59f0040 ldr r0, [pc, #64] ; a000c334 <sem_close+0x54> <== NOT EXECUTED
a000c2f0: e1a0200d mov r2, sp <== NOT EXECUTED
a000c2f4: eb00081c bl a000e36c <_Objects_Get> <== NOT EXECUTED
register POSIX_Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _POSIX_Semaphore_Get( sem, &location );
switch ( location ) {
a000c2f8: e59d4000 ldr r4, [sp] <== NOT EXECUTED
a000c2fc: e3540000 cmp r4, #0 <== NOT EXECUTED
a000c300: 1a000006 bne a000c320 <sem_close+0x40> <== NOT EXECUTED
case OBJECTS_LOCAL:
the_semaphore->open_count -= 1;
a000c304: e5902018 ldr r2, [r0, #24] <== NOT EXECUTED
a000c308: e2422001 sub r2, r2, #1 <== NOT EXECUTED
a000c30c: e5802018 str r2, [r0, #24] <== NOT EXECUTED
_POSIX_Semaphore_Delete( the_semaphore );
a000c310: eb00186d bl a00124cc <_POSIX_Semaphore_Delete> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c314: eb000aef bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000c318: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c31c: ea000003 b a000c330 <sem_close+0x50> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a000c320: eb0023cd bl a001525c <__errno> <== NOT EXECUTED
a000c324: e3a03016 mov r3, #22 <== NOT EXECUTED
a000c328: e5803000 str r3, [r0] <== NOT EXECUTED
a000c32c: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000c330: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000c338 <sem_destroy>:
*/
int sem_destroy(
sem_t *sem
)
{
a000c338: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
a000c33c: e1a03000 mov r3, r0 <== NOT EXECUTED
a000c340: e1a0200d mov r2, sp <== NOT EXECUTED
a000c344: e59f0048 ldr r0, [pc, #72] ; a000c394 <sem_destroy+0x5c> <== NOT EXECUTED
a000c348: e5931000 ldr r1, [r3] <== NOT EXECUTED
a000c34c: eb000806 bl a000e36c <_Objects_Get> <== NOT EXECUTED
register POSIX_Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _POSIX_Semaphore_Get( sem, &location );
switch ( location ) {
a000c350: e59d2000 ldr r2, [sp] <== NOT EXECUTED
a000c354: e3520000 cmp r2, #0 <== NOT EXECUTED
a000c358: 1a000008 bne a000c380 <sem_destroy+0x48> <== NOT EXECUTED
case OBJECTS_LOCAL:
/*
* Undefined operation on a named semaphore.
*/
if ( the_semaphore->named == true ) {
a000c35c: e5d04014 ldrb r4, [r0, #20] <== NOT EXECUTED
a000c360: e3540000 cmp r4, #0 <== NOT EXECUTED
a000c364: 0a000001 beq a000c370 <sem_destroy+0x38> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c368: eb000ada bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
a000c36c: ea000003 b a000c380 <sem_destroy+0x48> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
}
_POSIX_Semaphore_Delete( the_semaphore );
a000c370: eb001855 bl a00124cc <_POSIX_Semaphore_Delete> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c374: eb000ad7 bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000c378: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c37c: ea000003 b a000c390 <sem_destroy+0x58> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a000c380: eb0023b5 bl a001525c <__errno> <== NOT EXECUTED
a000c384: e3a03016 mov r3, #22 <== NOT EXECUTED
a000c388: e5803000 str r3, [r0] <== NOT EXECUTED
a000c38c: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000c390: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000c398 <sem_getvalue>:
int sem_getvalue(
sem_t *sem,
int *sval
)
{
a000c398: e92d4031 push {r0, r4, r5, lr}
a000c39c: e1a03000 mov r3, r0
a000c3a0: e1a04001 mov r4, r1
a000c3a4: e59f003c ldr r0, [pc, #60] ; a000c3e8 <sem_getvalue+0x50>
a000c3a8: e5931000 ldr r1, [r3]
a000c3ac: e1a0200d mov r2, sp
a000c3b0: eb0007ed bl a000e36c <_Objects_Get>
register POSIX_Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _POSIX_Semaphore_Get( sem, &location );
switch ( location ) {
a000c3b4: e59d5000 ldr r5, [sp]
a000c3b8: e3550000 cmp r5, #0
a000c3bc: 1a000004 bne a000c3d4 <sem_getvalue+0x3c>
case OBJECTS_LOCAL:
*sval = _CORE_semaphore_Get_count( &the_semaphore->Semaphore );
a000c3c0: e5903064 ldr r3, [r0, #100] ; 0x64
a000c3c4: e5843000 str r3, [r4]
_Thread_Enable_dispatch();
a000c3c8: eb000ac2 bl a000eed8 <_Thread_Enable_dispatch>
return 0;
a000c3cc: e1a00005 mov r0, r5
a000c3d0: ea000003 b a000c3e4 <sem_getvalue+0x4c>
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a000c3d4: eb0023a0 bl a001525c <__errno> <== NOT EXECUTED
a000c3d8: e3a03016 mov r3, #22 <== NOT EXECUTED
a000c3dc: e5803000 str r3, [r0] <== NOT EXECUTED
a000c3e0: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000c3e4: e8bd8038 pop {r3, r4, r5, pc}
a000c42c <sem_open>:
int oflag,
...
/* mode_t mode, */
/* unsigned int value */
)
{
a000c42c: e92d000e push {r1, r2, r3} <== NOT EXECUTED
a000c430: e92d41ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, lr} <== NOT EXECUTED
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
a000c434: e59f30e4 ldr r3, [pc, #228] ; a000c520 <sem_open+0xf4> <== NOT EXECUTED
a000c438: e59d4028 ldr r4, [sp, #40] ; 0x28 <== NOT EXECUTED
a000c43c: e1a06000 mov r6, r0 <== NOT EXECUTED
a000c440: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000c444: e2822001 add r2, r2, #1 <== NOT EXECUTED
a000c448: e5832000 str r2, [r3] <== NOT EXECUTED
POSIX_Semaphore_Control *the_semaphore;
Objects_Locations location;
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
a000c44c: e2147c02 ands r7, r4, #512 ; 0x200 <== NOT EXECUTED
va_start(arg, oflag);
mode = (mode_t) va_arg( arg, unsigned int );
value = va_arg( arg, unsigned int );
a000c450: 128d3034 addne r3, sp, #52 ; 0x34 <== NOT EXECUTED
va_end(arg);
}
status = _POSIX_Semaphore_Name_to_id( name, &the_semaphore_id );
a000c454: e28d1008 add r1, sp, #8 <== NOT EXECUTED
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
va_start(arg, oflag);
mode = (mode_t) va_arg( arg, unsigned int );
value = va_arg( arg, unsigned int );
a000c458: 158d300c strne r3, [sp, #12] <== NOT EXECUTED
a000c45c: 159d5030 ldrne r5, [sp, #48] ; 0x30 <== NOT EXECUTED
/* unsigned int value */
)
{
va_list arg;
mode_t mode;
unsigned int value = 0;
a000c460: 01a05007 moveq r5, r7 <== NOT EXECUTED
mode = (mode_t) va_arg( arg, unsigned int );
value = va_arg( arg, unsigned int );
va_end(arg);
}
status = _POSIX_Semaphore_Name_to_id( name, &the_semaphore_id );
a000c464: eb00182d bl a0012520 <_POSIX_Semaphore_Name_to_id> <== NOT EXECUTED
* and we can just return a pointer to the id. Otherwise we may
* need to check to see if this is a "semaphore does not exist"
* or some other miscellaneous error on the name.
*/
if ( status ) {
a000c468: e2508000 subs r8, r0, #0 <== NOT EXECUTED
a000c46c: 0a000007 beq a000c490 <sem_open+0x64> <== NOT EXECUTED
/*
* Unless provided a valid name that did not already exist
* and we are willing to create then it is an error.
*/
if ( !( status == ENOENT && (oflag & O_CREAT) ) ) {
a000c470: e3580002 cmp r8, #2 <== NOT EXECUTED
a000c474: 1a000001 bne a000c480 <sem_open+0x54> <== NOT EXECUTED
a000c478: e3570000 cmp r7, #0 <== NOT EXECUTED
a000c47c: 1a000017 bne a000c4e0 <sem_open+0xb4> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c480: eb000a94 bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one_cast( status, sem_t * );
a000c484: eb002374 bl a001525c <__errno> <== NOT EXECUTED
a000c488: e5808000 str r8, [r0] <== NOT EXECUTED
a000c48c: ea000006 b a000c4ac <sem_open+0x80> <== NOT EXECUTED
/*
* Check for existence with creation.
*/
if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {
a000c490: e2044c0a and r4, r4, #2560 ; 0xa00 <== NOT EXECUTED
a000c494: e3540c0a cmp r4, #2560 ; 0xa00 <== NOT EXECUTED
a000c498: 1a000005 bne a000c4b4 <sem_open+0x88> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c49c: eb000a8d bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one_cast( EEXIST, sem_t * );
a000c4a0: eb00236d bl a001525c <__errno> <== NOT EXECUTED
a000c4a4: e3a03011 mov r3, #17 <== NOT EXECUTED
a000c4a8: e5803000 str r3, [r0] <== NOT EXECUTED
a000c4ac: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000c4b0: ea000016 b a000c510 <sem_open+0xe4> <== NOT EXECUTED
a000c4b4: e59d1008 ldr r1, [sp, #8] <== NOT EXECUTED
a000c4b8: e1a0200d mov r2, sp <== NOT EXECUTED
a000c4bc: e59f0060 ldr r0, [pc, #96] ; a000c524 <sem_open+0xf8> <== NOT EXECUTED
a000c4c0: eb0007a9 bl a000e36c <_Objects_Get> <== NOT EXECUTED
}
the_semaphore = _POSIX_Semaphore_Get( &the_semaphore_id, &location );
the_semaphore->open_count += 1;
a000c4c4: e5903018 ldr r3, [r0, #24] <== NOT EXECUTED
if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one_cast( EEXIST, sem_t * );
}
the_semaphore = _POSIX_Semaphore_Get( &the_semaphore_id, &location );
a000c4c8: e58d0004 str r0, [sp, #4] <== NOT EXECUTED
the_semaphore->open_count += 1;
a000c4cc: e2833001 add r3, r3, #1 <== NOT EXECUTED
a000c4d0: e5803018 str r3, [r0, #24] <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c4d4: eb000a7f bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c4d8: eb000a7e bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
goto return_id;
a000c4dc: ea000009 b a000c508 <sem_open+0xdc> <== NOT EXECUTED
/*
* At this point, the semaphore does not exist and everything has been
* checked. We should go ahead and create a semaphore.
*/
status =_POSIX_Semaphore_Create_support(
a000c4e0: e3a01000 mov r1, #0 <== NOT EXECUTED
a000c4e4: e1a02005 mov r2, r5 <== NOT EXECUTED
a000c4e8: e28d3004 add r3, sp, #4 <== NOT EXECUTED
a000c4ec: e1a00006 mov r0, r6 <== NOT EXECUTED
a000c4f0: eb0017b8 bl a00123d8 <_POSIX_Semaphore_Create_support> <== NOT EXECUTED
a000c4f4: e1a04000 mov r4, r0 <== NOT EXECUTED
/*
* errno was set by Create_support, so don't set it again.
*/
_Thread_Enable_dispatch();
a000c4f8: eb000a76 bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
if ( status == -1 )
a000c4fc: e3740001 cmn r4, #1 <== NOT EXECUTED
return SEM_FAILED;
a000c500: 01a00004 moveq r0, r4 <== NOT EXECUTED
* errno was set by Create_support, so don't set it again.
*/
_Thread_Enable_dispatch();
if ( status == -1 )
a000c504: 0a000001 beq a000c510 <sem_open+0xe4> <== NOT EXECUTED
return_id:
#if defined(RTEMS_USE_16_BIT_OBJECT)
the_semaphore->Semaphore_id = the_semaphore->Object.id;
id = &the_semaphore->Semaphore_id;
#else
id = (sem_t *)&the_semaphore->Object.id;
a000c508: e59d0004 ldr r0, [sp, #4] <== NOT EXECUTED
a000c50c: e2800008 add r0, r0, #8 <== NOT EXECUTED
#endif
return id;
}
a000c510: e28dd010 add sp, sp, #16 <== NOT EXECUTED
a000c514: e8bd41f0 pop {r4, r5, r6, r7, r8, lr} <== NOT EXECUTED
a000c518: e28dd00c add sp, sp, #12 <== NOT EXECUTED
a000c51c: e12fff1e bx lr <== NOT EXECUTED
a000c528 <sem_post>:
*/
int sem_post(
sem_t *sem
)
{
a000c528: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
a000c52c: e1a03000 mov r3, r0 <== NOT EXECUTED
a000c530: e5931000 ldr r1, [r3] <== NOT EXECUTED
a000c534: e59f0044 ldr r0, [pc, #68] ; a000c580 <sem_post+0x58> <== NOT EXECUTED
a000c538: e1a0200d mov r2, sp <== NOT EXECUTED
a000c53c: eb00078a bl a000e36c <_Objects_Get> <== NOT EXECUTED
register POSIX_Semaphore_Control *the_semaphore;
Objects_Locations location;
the_semaphore = _POSIX_Semaphore_Get( sem, &location );
switch ( location ) {
a000c540: e59d4000 ldr r4, [sp] <== NOT EXECUTED
a000c544: e1a03000 mov r3, r0 <== NOT EXECUTED
a000c548: e3540000 cmp r4, #0 <== NOT EXECUTED
a000c54c: 1a000006 bne a000c56c <sem_post+0x44> <== NOT EXECUTED
case OBJECTS_LOCAL:
_CORE_semaphore_Surrender(
a000c550: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED
a000c554: e1a02004 mov r2, r4 <== NOT EXECUTED
a000c558: e280001c add r0, r0, #28 <== NOT EXECUTED
a000c55c: eb0004f9 bl a000d948 <_CORE_semaphore_Surrender> <== NOT EXECUTED
NULL /* XXX need to define a routine to handle this case */
#else
NULL
#endif
);
_Thread_Enable_dispatch();
a000c560: eb000a5c bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000c564: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c568: ea000003 b a000c57c <sem_post+0x54> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a000c56c: eb00233a bl a001525c <__errno> <== NOT EXECUTED
a000c570: e3a03016 mov r3, #22 <== NOT EXECUTED
a000c574: e5803000 str r3, [r0] <== NOT EXECUTED
a000c578: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a000c57c: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000c584 <sem_timedwait>:
int sem_timedwait(
sem_t *sem,
const struct timespec *abstime
)
{
a000c584: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
a000c588: e1a04000 mov r4, r0 <== NOT EXECUTED
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
a000c58c: e1a00001 mov r0, r1 <== NOT EXECUTED
a000c590: e1a0100d mov r1, sp <== NOT EXECUTED
a000c594: eb001513 bl a00119e8 <_POSIX_Absolute_timeout_to_ticks> <== NOT EXECUTED
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
lock_status = _POSIX_Semaphore_Wait_support( sem, do_wait, ticks );
a000c598: e59d2000 ldr r2, [sp] <== NOT EXECUTED
a000c59c: e3500003 cmp r0, #3 <== NOT EXECUTED
a000c5a0: 13a01000 movne r1, #0 <== NOT EXECUTED
a000c5a4: 03a01001 moveq r1, #1 <== NOT EXECUTED
a000c5a8: e1a00004 mov r0, r4 <== NOT EXECUTED
a000c5ac: eb0017fe bl a00125ac <_POSIX_Semaphore_Wait_support> <== NOT EXECUTED
lock_status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )
rtems_set_errno_and_return_minus_one( ETIMEDOUT );
}
return lock_status;
}
a000c5b0: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
a000c5b4 <sem_trywait>:
int sem_trywait(
sem_t *sem
)
{
return _POSIX_Semaphore_Wait_support(sem, false, THREAD_QUEUE_WAIT_FOREVER);
a000c5b4: e3a01000 mov r1, #0 <== NOT EXECUTED
a000c5b8: e1a02001 mov r2, r1 <== NOT EXECUTED
a000c5bc: ea0017fa b a00125ac <_POSIX_Semaphore_Wait_support> <== NOT EXECUTED
a000c5c0 <sem_unlink>:
a000c5c0: e59f3060 ldr r3, [pc, #96] ; a000c628 <sem_unlink+0x68> <== NOT EXECUTED
*/
int sem_unlink(
const char *name
)
{
a000c5c4: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
a000c5c8: e5932000 ldr r2, [r3] <== NOT EXECUTED
a000c5cc: e2822001 add r2, r2, #1 <== NOT EXECUTED
a000c5d0: e5832000 str r2, [r3] <== NOT EXECUTED
register POSIX_Semaphore_Control *the_semaphore;
sem_t the_semaphore_id;
_Thread_Disable_dispatch();
status = _POSIX_Semaphore_Name_to_id( name, &the_semaphore_id );
a000c5d4: e1a0100d mov r1, sp <== NOT EXECUTED
a000c5d8: eb0017d0 bl a0012520 <_POSIX_Semaphore_Name_to_id> <== NOT EXECUTED
if ( status != 0 ) {
a000c5dc: e2504000 subs r4, r0, #0 <== NOT EXECUTED
a000c5e0: 0a000004 beq a000c5f8 <sem_unlink+0x38> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c5e4: eb000a3b bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( status );
a000c5e8: eb00231b bl a001525c <__errno> <== NOT EXECUTED
a000c5ec: e5804000 str r4, [r0] <== NOT EXECUTED
a000c5f0: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000c5f4: ea00000a b a000c624 <sem_unlink+0x64> <== NOT EXECUTED
_POSIX_Semaphore_Namespace_remove( the_semaphore );
_POSIX_Semaphore_Delete( the_semaphore );
_Thread_Enable_dispatch();
return 0;
}
a000c5f8: e59f002c ldr r0, [pc, #44] ; a000c62c <sem_unlink+0x6c> <== NOT EXECUTED
*/
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return NULL;
#endif
return information->local_table[ index ];
a000c5fc: e1dd20b0 ldrh r2, [sp] <== NOT EXECUTED
a000c600: e590301c ldr r3, [r0, #28] <== NOT EXECUTED
if ( status != 0 ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( status );
}
the_semaphore = (POSIX_Semaphore_Control *) _Objects_Get_local_object(
a000c604: e7935102 ldr r5, [r3, r2, lsl #2] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _POSIX_Semaphore_Namespace_remove (
POSIX_Semaphore_Control *the_semaphore
)
{
_Objects_Namespace_remove(
a000c608: e1a01005 mov r1, r5 <== NOT EXECUTED
&_POSIX_Semaphore_Information,
_Objects_Get_index( the_semaphore_id )
);
the_semaphore->linked = false;
a000c60c: e5c54015 strb r4, [r5, #21] <== NOT EXECUTED
a000c610: eb0007a7 bl a000e4b4 <_Objects_Namespace_remove> <== NOT EXECUTED
_POSIX_Semaphore_Namespace_remove( the_semaphore );
_POSIX_Semaphore_Delete( the_semaphore );
a000c614: e1a00005 mov r0, r5 <== NOT EXECUTED
a000c618: eb0017ab bl a00124cc <_POSIX_Semaphore_Delete> <== NOT EXECUTED
_Thread_Enable_dispatch();
a000c61c: eb000a2d bl a000eed8 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000c620: e1a00004 mov r0, r4 <== NOT EXECUTED
}
a000c624: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
a000c630 <sem_wait>:
int sem_wait(
sem_t *sem
)
{
return _POSIX_Semaphore_Wait_support( sem, true, THREAD_QUEUE_WAIT_FOREVER );
a000c630: e3a01001 mov r1, #1 <== NOT EXECUTED
a000c634: e3a02000 mov r2, #0 <== NOT EXECUTED
a000c638: ea0017db b a00125ac <_POSIX_Semaphore_Wait_support> <== NOT EXECUTED
a0009258 <setitimer>:
int which,
const struct itimerval *value,
struct itimerval *ovalue
)
{
if ( !value )
a0009258: e3510000 cmp r1, #0
int setitimer(
int which,
const struct itimerval *value,
struct itimerval *ovalue
)
{
a000925c: e52de004 push {lr} ; (str lr, [sp, #-4]!)
if ( !value )
a0009260: 0a000001 beq a000926c <setitimer+0x14>
rtems_set_errno_and_return_minus_one( EFAULT );
if ( !ovalue )
a0009264: e3520000 cmp r2, #0
a0009268: 1a000002 bne a0009278 <setitimer+0x20>
rtems_set_errno_and_return_minus_one( EFAULT );
a000926c: eb002191 bl a00118b8 <__errno>
a0009270: e3a0300e mov r3, #14
a0009274: ea000006 b a0009294 <setitimer+0x3c>
switch ( which ) {
a0009278: e3500002 cmp r0, #2
a000927c: 8a000002 bhi a000928c <setitimer+0x34>
case ITIMER_REAL:
case ITIMER_VIRTUAL:
case ITIMER_PROF:
rtems_set_errno_and_return_minus_one( ENOSYS );
a0009280: eb00218c bl a00118b8 <__errno>
a0009284: e3a03058 mov r3, #88 ; 0x58
a0009288: ea000001 b a0009294 <setitimer+0x3c> <== NOT EXECUTED
default:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a000928c: eb002189 bl a00118b8 <__errno>
a0009290: e3a03016 mov r3, #22
a0009294: e5803000 str r3, [r0]
}
a0009298: e3e00000 mvn r0, #0
a000929c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a0009cb0 <sigaction>:
struct sigaction *oact
)
{
ISR_Level level;
if ( oact )
a0009cb0: e3520000 cmp r2, #0
int sigaction(
int sig,
const struct sigaction *act,
struct sigaction *oact
)
{
a0009cb4: e92d40f0 push {r4, r5, r6, r7, lr}
a0009cb8: e1a04000 mov r4, r0
a0009cbc: e1a05001 mov r5, r1
ISR_Level level;
if ( oact )
a0009cc0: 0a00000a beq a0009cf0 <sigaction+0x40>
*oact = _POSIX_signals_Vectors[ sig ];
a0009cc4: e3a0300c mov r3, #12
a0009cc8: e0030394 mul r3, r4, r3
a0009ccc: e59f00dc ldr r0, [pc, #220] ; a0009db0 <sigaction+0x100>
a0009cd0: e0801003 add r1, r0, r3
a0009cd4: e7900003 ldr r0, [r0, r3]
a0009cd8: e1a03002 mov r3, r2
a0009cdc: e4830004 str r0, [r3], #4
a0009ce0: e5910004 ldr r0, [r1, #4]
a0009ce4: e5820004 str r0, [r2, #4]
a0009ce8: e5912008 ldr r2, [r1, #8]
a0009cec: e5832004 str r2, [r3, #4]
if ( !sig )
a0009cf0: e3540000 cmp r4, #0
a0009cf4: 0a000004 beq a0009d0c <sigaction+0x5c>
static inline bool is_valid_signo(
int signo
)
{
return ((signo) >= 1 && (signo) <= 32 );
a0009cf8: e2443001 sub r3, r4, #1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(sig) )
a0009cfc: e353001f cmp r3, #31
a0009d00: 8a000001 bhi a0009d0c <sigaction+0x5c>
*
* NOTE: Solaris documentation claims to "silently enforce" this which
* contradicts the POSIX specification.
*/
if ( sig == SIGKILL )
a0009d04: e3540009 cmp r4, #9
a0009d08: 1a000004 bne a0009d20 <sigaction+0x70>
rtems_set_errno_and_return_minus_one( EINVAL );
a0009d0c: eb002188 bl a0012334 <__errno>
a0009d10: e3a03016 mov r3, #22 <== NOT EXECUTED
a0009d14: e5803000 str r3, [r0] <== NOT EXECUTED
a0009d18: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009d1c: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
/*
* Evaluate the new action structure and set the global signal vector
* appropriately.
*/
if ( act ) {
a0009d20: e3550000 cmp r5, #0
a0009d24: 0a00001f beq a0009da8 <sigaction+0xf8>
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a0009d28: e10f7000 mrs r7, CPSR
a0009d2c: e3873080 orr r3, r7, #128 ; 0x80
a0009d30: e129f003 msr CPSR_fc, r3
* Unless the user is installing the default signal actions, then
* we can just copy the provided sigaction structure into the vectors.
*/
_ISR_Disable( level );
if ( act->sa_handler == SIG_DFL ) {
a0009d34: e5953008 ldr r3, [r5, #8]
a0009d38: e59f6070 ldr r6, [pc, #112] ; a0009db0 <sigaction+0x100>
a0009d3c: e3530000 cmp r3, #0
a0009d40: 1a000009 bne a0009d6c <sigaction+0xbc>
_POSIX_signals_Vectors[ sig ] = _POSIX_signals_Default_vectors[ sig ];
a0009d44: e283300c add r3, r3, #12
a0009d48: e0040493 mul r4, r3, r4
a0009d4c: e59f1060 ldr r1, [pc, #96] ; a0009db4 <sigaction+0x104>
a0009d50: e0863004 add r3, r6, r4
a0009d54: e0812004 add r2, r1, r4
a0009d58: e7911004 ldr r1, [r1, r4]
a0009d5c: e7861004 str r1, [r6, r4]
a0009d60: e9920006 ldmib r2, {r1, r2}
a0009d64: e9830006 stmib r3, {r1, r2}
a0009d68: ea00000b b a0009d9c <sigaction+0xec>
} else {
_POSIX_signals_Clear_process_signals( sig );
a0009d6c: e1a00004 mov r0, r4
a0009d70: eb0015cd bl a000f4ac <_POSIX_signals_Clear_process_signals>
_POSIX_signals_Vectors[ sig ] = *act;
a0009d74: e3a0300c mov r3, #12
a0009d78: e0040493 mul r4, r3, r4
a0009d7c: e1a03005 mov r3, r5
a0009d80: e4931004 ldr r1, [r3], #4
a0009d84: e0862004 add r2, r6, r4
a0009d88: e7861004 str r1, [r6, r4]
a0009d8c: e5951004 ldr r1, [r5, #4]
a0009d90: e5821004 str r1, [r2, #4]
a0009d94: e5933004 ldr r3, [r3, #4]
a0009d98: e5823008 str r3, [r2, #8]
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a0009d9c: e129f007 msr CPSR_fc, r7
* now (signals not posted when SIG_IGN).
* + If we are now ignoring a signal that was previously pending,
* we clear the pending signal indicator.
*/
return 0;
a0009da0: e3a00000 mov r0, #0
a0009da4: e8bd80f0 pop {r4, r5, r6, r7, pc}
a0009da8: e1a00005 mov r0, r5
}
a0009dac: e8bd80f0 pop {r4, r5, r6, r7, pc}
a0009db8 <sigaddset>:
int sigaddset(
sigset_t *set,
int signo
)
{
if ( !set )
a0009db8: e3500000 cmp r0, #0
int sigaddset(
sigset_t *set,
int signo
)
{
a0009dbc: e52de004 push {lr} ; (str lr, [sp, #-4]!)
if ( !set )
a0009dc0: 0a000004 beq a0009dd8 <sigaddset+0x20>
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !signo )
a0009dc4: e3510000 cmp r1, #0
a0009dc8: 0a000002 beq a0009dd8 <sigaddset+0x20>
a0009dcc: e2411001 sub r1, r1, #1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(signo) )
a0009dd0: e351001f cmp r1, #31
a0009dd4: 9a000004 bls a0009dec <sigaddset+0x34>
rtems_set_errno_and_return_minus_one( EINVAL );
a0009dd8: eb002155 bl a0012334 <__errno> <== NOT EXECUTED
a0009ddc: e3a03016 mov r3, #22 <== NOT EXECUTED
a0009de0: e5803000 str r3, [r0] <== NOT EXECUTED
a0009de4: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009de8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
*set |= signo_to_mask(signo);
a0009dec: e5903000 ldr r3, [r0]
a0009df0: e3a02001 mov r2, #1
a0009df4: e1831112 orr r1, r3, r2, lsl r1
a0009df8: e5801000 str r1, [r0]
return 0;
a0009dfc: e3a00000 mov r0, #0
}
a0009e00: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a000bfd0 <sigdelset>:
int sigdelset(
sigset_t *set,
int signo
)
{
if ( !set )
a000bfd0: e3500000 cmp r0, #0
int sigdelset(
sigset_t *set,
int signo
)
{
a000bfd4: e52de004 push {lr} ; (str lr, [sp, #-4]!)
if ( !set )
a000bfd8: 0a000004 beq a000bff0 <sigdelset+0x20>
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !signo )
a000bfdc: e3510000 cmp r1, #0
a000bfe0: 0a00000d beq a000c01c <sigdelset+0x4c>
a000bfe4: e2411001 sub r1, r1, #1
return 0;
if ( !is_valid_signo(signo) )
a000bfe8: e351001f cmp r1, #31
a000bfec: 9a000004 bls a000c004 <sigdelset+0x34>
rtems_set_errno_and_return_minus_one( EINVAL );
a000bff0: eb0021af bl a00146b4 <__errno>
a000bff4: e3a03016 mov r3, #22
a000bff8: e5803000 str r3, [r0] <== NOT EXECUTED
a000bffc: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000c000: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
*set &= ~signo_to_mask(signo);
a000c004: e5903000 ldr r3, [r0]
a000c008: e3a02001 mov r2, #1
a000c00c: e1c31112 bic r1, r3, r2, lsl r1
a000c010: e5801000 str r1, [r0]
return 0;
a000c014: e3a00000 mov r0, #0
a000c018: e49df004 pop {pc} ; (ldr pc, [sp], #4)
{
if ( !set )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !signo )
return 0;
a000c01c: e1a00001 mov r0, r1 <== NOT EXECUTED
if ( !is_valid_signo(signo) )
rtems_set_errno_and_return_minus_one( EINVAL );
*set &= ~signo_to_mask(signo);
return 0;
}
a000c020: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a000e844 <sigemptyset>:
int sigemptyset(
sigset_t *set
)
{
if ( !set )
a000e844: e2503000 subs r3, r0, #0
#include <rtems/seterr.h>
int sigemptyset(
sigset_t *set
)
{
a000e848: e52de004 push {lr} ; (str lr, [sp, #-4]!)
if ( !set )
a000e84c: 1a000004 bne a000e864 <sigemptyset+0x20>
rtems_set_errno_and_return_minus_one( EINVAL );
a000e850: eb000a22 bl a00110e0 <__errno> <== NOT EXECUTED
a000e854: e3a03016 mov r3, #22 <== NOT EXECUTED
a000e858: e5803000 str r3, [r0] <== NOT EXECUTED
a000e85c: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000e860: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
*set = 0;
a000e864: e3a00000 mov r0, #0
a000e868: e5830000 str r0, [r3]
return 0;
}
a000e86c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a000c050 <sigfillset>:
int sigfillset(
sigset_t *set
)
{
if ( !set )
a000c050: e3500000 cmp r0, #0
#include <rtems/seterr.h>
int sigfillset(
sigset_t *set
)
{
a000c054: e52de004 push {lr} ; (str lr, [sp, #-4]!)
if ( !set )
a000c058: 1a000004 bne a000c070 <sigfillset+0x20>
rtems_set_errno_and_return_minus_one( EINVAL );
a000c05c: eb002194 bl a00146b4 <__errno> <== NOT EXECUTED
a000c060: e3a03016 mov r3, #22 <== NOT EXECUTED
a000c064: e5803000 str r3, [r0] <== NOT EXECUTED
a000c068: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000c06c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
*set = SIGNAL_ALL_MASK;
a000c070: e3e03000 mvn r3, #0
a000c074: e5803000 str r3, [r0]
return 0;
a000c078: e3a00000 mov r0, #0
}
a000c07c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a000c080 <sigismember>:
int sigismember(
const sigset_t *set,
int signo
)
{
if ( !set )
a000c080: e3500000 cmp r0, #0
int sigismember(
const sigset_t *set,
int signo
)
{
a000c084: e52de004 push {lr} ; (str lr, [sp, #-4]!)
if ( !set )
a000c088: 0a000004 beq a000c0a0 <sigismember+0x20>
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !signo )
a000c08c: e3510000 cmp r1, #0
a000c090: 0a00000d beq a000c0cc <sigismember+0x4c>
a000c094: e2411001 sub r1, r1, #1
return 0;
if ( !is_valid_signo(signo) )
a000c098: e351001f cmp r1, #31
a000c09c: 9a000004 bls a000c0b4 <sigismember+0x34>
rtems_set_errno_and_return_minus_one( EINVAL );
a000c0a0: eb002183 bl a00146b4 <__errno>
a000c0a4: e3a03016 mov r3, #22
a000c0a8: e5803000 str r3, [r0] <== NOT EXECUTED
a000c0ac: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000c0b0: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
if ( *set & signo_to_mask(signo) )
a000c0b4: e5903000 ldr r3, [r0]
const sigset_t *set,
int signo
)
{
if ( !set )
rtems_set_errno_and_return_minus_one( EINVAL );
a000c0b8: e3a02001 mov r2, #1
a000c0bc: e0133112 ands r3, r3, r2, lsl r1
a000c0c0: 03a00000 moveq r0, #0
a000c0c4: 13a00001 movne r0, #1
a000c0c8: e49df004 pop {pc} ; (ldr pc, [sp], #4)
if ( !signo )
return 0;
a000c0cc: e1a00001 mov r0, r1
if ( *set & signo_to_mask(signo) )
return 1;
return 0;
}
a000c0d0: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a0009e30 <sigpending>:
sigset_t *set
)
{
POSIX_API_Control *api;
if ( !set )
a0009e30: e3500000 cmp r0, #0
#include <rtems/seterr.h>
int sigpending(
sigset_t *set
)
{
a0009e34: e52de004 push {lr} ; (str lr, [sp, #-4]!)
POSIX_API_Control *api;
if ( !set )
a0009e38: 1a000004 bne a0009e50 <sigpending+0x20>
rtems_set_errno_and_return_minus_one( EINVAL );
a0009e3c: eb00213c bl a0012334 <__errno> <== NOT EXECUTED
a0009e40: e3a03016 mov r3, #22 <== NOT EXECUTED
a0009e44: e5803000 str r3, [r0] <== NOT EXECUTED
a0009e48: e3e00000 mvn r0, #0 <== NOT EXECUTED
a0009e4c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0009e50: e59f3020 ldr r3, [pc, #32] ; a0009e78 <sigpending+0x48>
*set = api->signals_pending | _POSIX_signals_Pending;
a0009e54: e59f2020 ldr r2, [pc, #32] ; a0009e7c <sigpending+0x4c>
POSIX_API_Control *api;
if ( !set )
rtems_set_errno_and_return_minus_one( EINVAL );
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
a0009e58: e5933004 ldr r3, [r3, #4]
*set = api->signals_pending | _POSIX_signals_Pending;
a0009e5c: e5922000 ldr r2, [r2]
a0009e60: e59330fc ldr r3, [r3, #252] ; 0xfc
a0009e64: e59330d4 ldr r3, [r3, #212] ; 0xd4
a0009e68: e1823003 orr r3, r2, r3
a0009e6c: e5803000 str r3, [r0]
return 0;
a0009e70: e3a00000 mov r0, #0
}
a0009e74: e49df004 pop {pc} ; (ldr pc, [sp], #4)
a000c128 <sigqueue>:
int sigqueue(
pid_t pid,
int signo,
const union sigval value
)
{
a000c128: e92d4001 push {r0, lr} <== NOT EXECUTED
a000c12c: e28d3004 add r3, sp, #4 <== NOT EXECUTED
a000c130: e5232004 str r2, [r3, #-4]! <== NOT EXECUTED
return killinfo( pid, signo, &value );
a000c134: e1a0200d mov r2, sp <== NOT EXECUTED
a000c138: eb0015e3 bl a00118cc <killinfo> <== NOT EXECUTED
}
a000c13c: e8bd8008 pop {r3, pc} <== NOT EXECUTED
a000c140 <sigsuspend>:
#include <rtems/seterr.h>
int sigsuspend(
const sigset_t *sigmask
)
{
a000c140: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED
a000c144: e1a05000 mov r5, r0 <== NOT EXECUTED
/*
* We use SIG_BLOCK and not SIG_SETMASK because there may be
* signals which might be pending, which might get caught here.
* We want the signals to be caught inside sigtimedwait.
*/
status = sigprocmask( SIG_BLOCK, sigmask, &saved_signals_blocked );
a000c148: e28d4004 add r4, sp, #4 <== NOT EXECUTED
a000c14c: e1a01005 mov r1, r5 <== NOT EXECUTED
a000c150: e1a02004 mov r2, r4 <== NOT EXECUTED
a000c154: e3a00001 mov r0, #1 <== NOT EXECUTED
a000c158: ebfffff1 bl a000c124 <sigprocmask> <== NOT EXECUTED
current_unblocked_signals = ~(*sigmask);
a000c15c: e5953000 ldr r3, [r5] <== NOT EXECUTED
a000c160: e28d0008 add r0, sp, #8 <== NOT EXECUTED
status = sigtimedwait( ¤t_unblocked_signals, NULL, NULL );
a000c164: e3a01000 mov r1, #0 <== NOT EXECUTED
* signals which might be pending, which might get caught here.
* We want the signals to be caught inside sigtimedwait.
*/
status = sigprocmask( SIG_BLOCK, sigmask, &saved_signals_blocked );
current_unblocked_signals = ~(*sigmask);
a000c168: e1e03003 mvn r3, r3 <== NOT EXECUTED
a000c16c: e5203008 str r3, [r0, #-8]! <== NOT EXECUTED
status = sigtimedwait( ¤t_unblocked_signals, NULL, NULL );
a000c170: e1a02001 mov r2, r1 <== NOT EXECUTED
a000c174: e1a0000d mov r0, sp <== NOT EXECUTED
a000c178: eb00001a bl a000c1e8 <sigtimedwait> <== NOT EXECUTED
(void) sigprocmask( SIG_SETMASK, &saved_signals_blocked, NULL );
a000c17c: e3a00000 mov r0, #0 <== NOT EXECUTED
a000c180: e1a01004 mov r1, r4 <== NOT EXECUTED
a000c184: e1a02000 mov r2, r0 <== NOT EXECUTED
a000c188: ebffffe5 bl a000c124 <sigprocmask> <== NOT EXECUTED
*/
#if defined(RTEMS_DEBUG)
assert( status != -1 );
#endif
rtems_set_errno_and_return_minus_one( EINTR );
a000c18c: eb002148 bl a00146b4 <__errno> <== NOT EXECUTED
a000c190: e3a03004 mov r3, #4 <== NOT EXECUTED
a000c194: e5803000 str r3, [r0] <== NOT EXECUTED
}
a000c198: e3e00000 mvn r0, #0 <== NOT EXECUTED
a000c19c: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED
a000a17c <sigtimedwait>:
int sigtimedwait(
const sigset_t *set,
siginfo_t *info,
const struct timespec *timeout
)
{
a000a17c: e92d45ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, sl, lr}
ISR_Level level;
/*
* Error check parameters before disabling interrupts.
*/
if ( !set )
a000a180: e2506000 subs r6, r0, #0
int sigtimedwait(
const sigset_t *set,
siginfo_t *info,
const struct timespec *timeout
)
{
a000a184: e1a04001 mov r4, r1
a000a188: e1a05002 mov r5, r2
ISR_Level level;
/*
* Error check parameters before disabling interrupts.
*/
if ( !set )
a000a18c: 0a000009 beq a000a1b8 <sigtimedwait+0x3c>
/* NOTE: This is very specifically a RELATIVE not ABSOLUTE time
* in the Open Group specification.
*/
interval = 0;
if ( timeout ) {
a000a190: e3520000 cmp r2, #0
a000a194: 0a00000a beq a000a1c4 <sigtimedwait+0x48>
if ( !_Timespec_Is_valid( timeout ) )
a000a198: e1a00002 mov r0, r2
a000a19c: eb000d4a bl a000d6cc <_Timespec_Is_valid>
a000a1a0: e3500000 cmp r0, #0
a000a1a4: 0a000003 beq a000a1b8 <sigtimedwait+0x3c>
rtems_set_errno_and_return_minus_one( EINVAL );
interval = _Timespec_To_ticks( timeout );
a000a1a8: e1a00005 mov r0, r5
a000a1ac: eb000d69 bl a000d758 <_Timespec_To_ticks>
if ( !interval )
a000a1b0: e2501000 subs r1, r0, #0
a000a1b4: 1a000003 bne a000a1c8 <sigtimedwait+0x4c>
rtems_set_errno_and_return_minus_one( EINVAL );
a000a1b8: eb002206 bl a00129d8 <__errno>
a000a1bc: e3a03016 mov r3, #22
a000a1c0: ea000057 b a000a324 <sigtimedwait+0x1a8>
/* NOTE: This is very specifically a RELATIVE not ABSOLUTE time
* in the Open Group specification.
*/
interval = 0;
a000a1c4: e1a01002 mov r1, r2
* Initialize local variables.
*/
the_info = ( info ) ? info : &signal_information;
the_thread = _Thread_Executing;
a000a1c8: e59f3168 ldr r3, [pc, #360] ; a000a338 <sigtimedwait+0x1bc>
/*
* Initialize local variables.
*/
the_info = ( info ) ? info : &signal_information;
a000a1cc: e3540000 cmp r4, #0
a000a1d0: 028d4004 addeq r4, sp, #4
the_thread = _Thread_Executing;
a000a1d4: e5933004 ldr r3, [r3, #4]
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
a000a1d8: e59380fc ldr r8, [r3, #252] ; 0xfc
static inline uint32_t arm_interrupt_disable( void )
{
uint32_t arm_switch_reg;
uint32_t level;
asm volatile (
a000a1dc: e10f7000 mrs r7, CPSR
a000a1e0: e3872080 orr r2, r7, #128 ; 0x80
a000a1e4: e129f002 msr CPSR_fc, r2
*/
/* API signals pending? */
_ISR_Disable( level );
if ( *set & api->signals_pending ) {
a000a1e8: e5962000 ldr r2, [r6]
a000a1ec: e59800d4 ldr r0, [r8, #212] ; 0xd4
a000a1f0: e012a000 ands sl, r2, r0
a000a1f4: 0a00000e beq a000a234 <sigtimedwait+0xb8>
/* XXX real info later */
the_info->si_signo = _POSIX_signals_Get_lowest( api->signals_pending );
a000a1f8: ebffffcd bl a000a134 <_POSIX_signals_Get_lowest> <== NOT EXECUTED
_POSIX_signals_Clear_signals(
a000a1fc: e3a03000 mov r3, #0 <== NOT EXECUTED
/* API signals pending? */
_ISR_Disable( level );
if ( *set & api->signals_pending ) {
/* XXX real info later */
the_info->si_signo = _POSIX_signals_Get_lowest( api->signals_pending );
a000a200: e5840000 str r0, [r4] <== NOT EXECUTED
a000a204: e1a01000 mov r1, r0 <== NOT EXECUTED
_POSIX_signals_Clear_signals(
a000a208: e1a02004 mov r2, r4 <== NOT EXECUTED
a000a20c: e1a00008 mov r0, r8 <== NOT EXECUTED
a000a210: e58d3000 str r3, [sp] <== NOT EXECUTED
a000a214: eb00167d bl a000fc10 <_POSIX_signals_Clear_signals> <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level )
{
ARM_SWITCH_REGISTERS;
asm volatile (
a000a218: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED
false,
false
);
_ISR_Enable( level );
the_info->si_code = SI_USER;
a000a21c: e3a03001 mov r3, #1 <== NOT EXECUTED
a000a220: e5843004 str r3, [r4, #4] <== NOT EXECUTED
the_info->si_value.sival_int = 0;
a000a224: e3a03000 mov r3, #0 <== NOT EXECUTED
a000a228: e5843008 str r3, [r4, #8] <== NOT EXECUTED
return the_info->si_signo;
a000a22c: e5945000 ldr r5, [r4] <== NOT EXECUTED
a000a230: ea00003d b a000a32c <sigtimedwait+0x1b0> <== NOT EXECUTED
}
/* Process pending signals? */
if ( *set & _POSIX_signals_Pending ) {
a000a234: e59f0100 ldr r0, [pc, #256] ; a000a33c <sigtimedwait+0x1c0>
a000a238: e5900000 ldr r0, [r0]
a000a23c: e1120000 tst r2, r0
a000a240: 0a00000e beq a000a280 <sigtimedwait+0x104>
signo = _POSIX_signals_Get_lowest( _POSIX_signals_Pending );
a000a244: ebffffba bl a000a134 <_POSIX_signals_Get_lowest> <== NOT EXECUTED
a000a248: e1a05000 mov r5, r0 <== NOT EXECUTED
_POSIX_signals_Clear_signals( api, signo, the_info, true, false );
a000a24c: e1a01005 mov r1, r5 <== NOT EXECUTED
a000a250: e1a00008 mov r0, r8 <== NOT EXECUTED
a000a254: e1a02004 mov r2, r4 <== NOT EXECUTED
a000a258: e3a03001 mov r3, #1 <== NOT EXECUTED
a000a25c: e58da000 str sl, [sp] <== NOT EXECUTED
a000a260: eb00166a bl a000fc10 <_POSIX_signals_Clear_signals> <== NOT EXECUTED
a000a264: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED
_ISR_Enable( level );
the_info->si_signo = signo;
the_info->si_code = SI_USER;
a000a268: e3a03001 mov r3, #1 <== NOT EXECUTED
a000a26c: e5843004 str r3, [r4, #4] <== NOT EXECUTED
the_info->si_value.sival_int = 0;
a000a270: e3a03000 mov r3, #0 <== NOT EXECUTED
if ( *set & _POSIX_signals_Pending ) {
signo = _POSIX_signals_Get_lowest( _POSIX_signals_Pending );
_POSIX_signals_Clear_signals( api, signo, the_info, true, false );
_ISR_Enable( level );
the_info->si_signo = signo;
a000a274: e5845000 str r5, [r4] <== NOT EXECUTED
the_info->si_code = SI_USER;
the_info->si_value.sival_int = 0;
a000a278: e5843008 str r3, [r4, #8] <== NOT EXECUTED
return signo;
a000a27c: ea00002a b a000a32c <sigtimedwait+0x1b0> <== NOT EXECUTED
}
the_info->si_signo = -1;
a000a280: e3e02000 mvn r2, #0
a000a284: e5842000 str r2, [r4]
a000a288: e59f20b0 ldr r2, [pc, #176] ; a000a340 <sigtimedwait+0x1c4>
a000a28c: e5920000 ldr r0, [r2]
a000a290: e2800001 add r0, r0, #1
a000a294: e5820000 str r0, [r2]
_Thread_Disable_dispatch();
the_thread->Wait.queue = &_POSIX_signals_Wait_queue;
the_thread->Wait.return_code = EINTR;
a000a298: e3a00004 mov r0, #4
a000a29c: e5830034 str r0, [r3, #52] ; 0x34
the_thread->Wait.option = *set;
a000a2a0: e5960000 ldr r0, [r6]
}
the_info->si_signo = -1;
_Thread_Disable_dispatch();
the_thread->Wait.queue = &_POSIX_signals_Wait_queue;
a000a2a4: e59f2098 ldr r2, [pc, #152] ; a000a344 <sigtimedwait+0x1c8>
the_thread->Wait.return_code = EINTR;
the_thread->Wait.option = *set;
the_thread->Wait.return_argument = the_info;
a000a2a8: e5834028 str r4, [r3, #40] ; 0x28
the_info->si_signo = -1;
_Thread_Disable_dispatch();
the_thread->Wait.queue = &_POSIX_signals_Wait_queue;
the_thread->Wait.return_code = EINTR;
the_thread->Wait.option = *set;
a000a2ac: e5830030 str r0, [r3, #48] ; 0x30
}
the_info->si_signo = -1;
_Thread_Disable_dispatch();
the_thread->Wait.queue = &_POSIX_signals_Wait_queue;
a000a2b0: e5832044 str r2, [r3, #68] ; 0x44
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
a000a2b4: e3a03001 mov r3, #1
a000a2b8: e5823030 str r3, [r2, #48] ; 0x30
a000a2bc: e129f007 msr CPSR_fc, r7
the_thread->Wait.return_code = EINTR;
the_thread->Wait.option = *set;
the_thread->Wait.return_argument = the_info;
_Thread_queue_Enter_critical_section( &_POSIX_signals_Wait_queue );
_ISR_Enable( level );
_Thread_queue_Enqueue( &_POSIX_signals_Wait_queue, interval );
a000a2c0: e59f007c ldr r0, [pc, #124] ; a000a344 <sigtimedwait+0x1c8>
a000a2c4: e59f207c ldr r2, [pc, #124] ; a000a348 <sigtimedwait+0x1cc>
a000a2c8: eb000b54 bl a000d020 <_Thread_queue_Enqueue_with_handler>
_Thread_Enable_dispatch();
a000a2cc: eb000a2a bl a000cb7c <_Thread_Enable_dispatch>
/*
* When the thread is set free by a signal, it is need to eliminate
* the signal.
*/
_POSIX_signals_Clear_signals( api, the_info->si_signo, the_info, false, false );
a000a2d0: e3a03000 mov r3, #0 <== NOT EXECUTED
a000a2d4: e58d3000 str r3, [sp] <== NOT EXECUTED
a000a2d8: e1a00008 mov r0, r8 <== NOT EXECUTED
a000a2dc: e5941000 ldr r1, [r4] <== NOT EXECUTED
a000a2e0: e1a02004 mov r2, r4 <== NOT EXECUTED
a000a2e4: eb001649 bl a000fc10 <_POSIX_signals_Clear_signals> <== NOT EXECUTED
/* Set errno only if return code is not EINTR or
* if EINTR was caused by a signal being caught, which
* was not in our set.
*/
if ( (_Thread_Executing->Wait.return_code != EINTR)
a000a2e8: e59f3048 ldr r3, [pc, #72] ; a000a338 <sigtimedwait+0x1bc> <== NOT EXECUTED
a000a2ec: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
a000a2f0: e5933034 ldr r3, [r3, #52] ; 0x34 <== NOT EXECUTED
a000a2f4: e3530004 cmp r3, #4 <== NOT EXECUTED
a000a2f8: 1a000005 bne a000a314 <sigtimedwait+0x198> <== NOT EXECUTED
|| !(*set & signo_to_mask( the_info->si_signo )) ) {
a000a2fc: e5945000 ldr r5, [r4] <== NOT EXECUTED
a000a300: e5963000 ldr r3, [r6] <== NOT EXECUTED
a000a304: e3a01001 mov r1, #1 <== NOT EXECUTED
a000a308: e2452001 sub r2, r5, #1 <== NOT EXECUTED
a000a30c: e0133211 ands r3, r3, r1, lsl r2 <== NOT EXECUTED
a000a310: 1a000005 bne a000a32c <sigtimedwait+0x1b0> <== NOT EXECUTED
errno = _Thread_Executing->Wait.return_code;
a000a314: eb0021af bl a00129d8 <__errno> <== NOT EXECUTED
a000a318: e59f3018 ldr r3, [pc, #24] ; a000a338 <sigtimedwait+0x1bc> <== NOT EXECUTED
a000a31c: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED
a000a320: e5933034 ldr r3, [r3, #52] ; 0x34 <== NOT EXECUTED
a000a324: e5803000 str r3, [r0]
return -1;
a000a328: e3e05000 mvn r5, #0
}
return the_info->si_signo;
}
a000a32c: e1a00005 mov r0, r5
a000a330: e28dd010 add sp, sp, #16
a000a334: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
a000c3c0 <sigwait>:
int sigwait(
const sigset_t *set,
int *sig
)
{
a000c3c0: e92d4010 push {r4, lr}
a000c3c4: e1a04001 mov r4, r1
int status;
status = sigtimedwait( set, NULL, NULL );
a000c3c8: e3a01000 mov r1, #0
a000c3cc: e1a02001 mov r2, r1
a000c3d0: ebffff84 bl a000c1e8 <sigtimedwait>
if ( status != -1 ) {
a000c3d4: e3700001 cmn r0, #1
a000c3d8: 0a000004 beq a000c3f0 <sigwait+0x30>
if ( sig )
a000c3dc: e3540000 cmp r4, #0 <== NOT EXECUTED
a000c3e0: 0a000005 beq a000c3fc <sigwait+0x3c> <== NOT EXECUTED
*sig = status;
a000c3e4: e5840000 str r0, [r4] <== NOT EXECUTED
return 0;
a000c3e8: e3a00000 mov r0, #0 <== NOT EXECUTED
a000c3ec: e8bd8010 pop {r4, pc} <== NOT EXECUTED
}
return errno;
a000c3f0: eb0020af bl a00146b4 <__errno>
a000c3f4: e5900000 ldr r0, [r0]
a000c3f8: e8bd8010 pop {r4, pc}
status = sigtimedwait( set, NULL, NULL );
if ( status != -1 ) {
if ( sig )
*sig = status;
return 0;
a000c3fc: e1a00004 mov r0, r4 <== NOT EXECUTED
}
return errno;
}
a000c400: e8bd8010 pop {r4, pc} <== NOT EXECUTED
a00099e4 <timer_delete>:
int timer_delete(
timer_t timerid
)
{
a00099e4: e92d4031 push {r0, r4, r5, lr}
a00099e8: e1a01000 mov r1, r0
timer_t id,
Objects_Locations *location
)
{
return (POSIX_Timer_Control *)
_Objects_Get( &_POSIX_Timer_Information, (Objects_Id) id, location );
a00099ec: e1a0200d mov r2, sp
a00099f0: e59f0058 ldr r0, [pc, #88] ; a0009a50 <timer_delete+0x6c>
a00099f4: eb000806 bl a000ba14 <_Objects_Get>
*/
POSIX_Timer_Control *ptimer;
Objects_Locations location;
ptimer = _POSIX_Timer_Get( timerid, &location );
switch ( location ) {
a00099f8: e59d5000 ldr r5, [sp]
a00099fc: e1a04000 mov r4, r0
a0009a00: e3550000 cmp r5, #0
a0009a04: 1a00000c bne a0009a3c <timer_delete+0x58>
case OBJECTS_LOCAL:
_Objects_Close( &_POSIX_Timer_Information, &ptimer->Object );
a0009a08: e1a01004 mov r1, r4 <== NOT EXECUTED
a0009a0c: e59f003c ldr r0, [pc, #60] ; a0009a50 <timer_delete+0x6c> <== NOT EXECUTED
a0009a10: eb000700 bl a000b618 <_Objects_Close> <== NOT EXECUTED
ptimer->state = POSIX_TIMER_STATE_FREE;
a0009a14: e3a03001 mov r3, #1 <== NOT EXECUTED
a0009a18: e5c4303c strb r3, [r4, #60] ; 0x3c <== NOT EXECUTED
(void) _Watchdog_Remove( &ptimer->Timer );
a0009a1c: e2840010 add r0, r4, #16 <== NOT EXECUTED
a0009a20: eb000ed8 bl a000d588 <_Watchdog_Remove> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _POSIX_Timer_Free (
POSIX_Timer_Control *the_timer
)
{
_Objects_Free( &_POSIX_Timer_Information, &the_timer->Object );
a0009a24: e59f0024 ldr r0, [pc, #36] ; a0009a50 <timer_delete+0x6c> <== NOT EXECUTED
a0009a28: e1a01004 mov r1, r4 <== NOT EXECUTED
a0009a2c: eb0007a0 bl a000b8b4 <_Objects_Free> <== NOT EXECUTED
_POSIX_Timer_Free( ptimer );
_Thread_Enable_dispatch();
a0009a30: eb000aaf bl a000c4f4 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a0009a34: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009a38: ea000003 b a0009a4c <timer_delete+0x68> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a0009a3c: eb00231a bl a00126ac <__errno>
a0009a40: e3a03016 mov r3, #22
a0009a44: e5803000 str r3, [r0]
a0009a48: e3e00000 mvn r0, #0
}
a0009a4c: e8bd8038 pop {r3, r4, r5, pc}
a000a6d8 <timer_getoverrun>:
* its execution, _POSIX_Timer_TSR will have to set this counter to 0.
*/
int timer_getoverrun(
timer_t timerid
)
{
a000a6d8: e92d4011 push {r0, r4, lr}
a000a6dc: e1a01000 mov r1, r0
timer_t id,
Objects_Locations *location
)
{
return (POSIX_Timer_Control *)
_Objects_Get( &_POSIX_Timer_Information, (Objects_Id) id, location );
a000a6e0: e1a0200d mov r2, sp
a000a6e4: e59f0034 ldr r0, [pc, #52] ; a000a720 <timer_getoverrun+0x48>
a000a6e8: eb0007ea bl a000c698 <_Objects_Get>
int overrun;
POSIX_Timer_Control *ptimer;
Objects_Locations location;
ptimer = _POSIX_Timer_Get( timerid, &location );
switch ( location ) {
a000a6ec: e59d3000 ldr r3, [sp]
a000a6f0: e3530000 cmp r3, #0
a000a6f4: 1a000003 bne a000a708 <timer_getoverrun+0x30>
case OBJECTS_LOCAL:
overrun = ptimer->overrun;
a000a6f8: e5904068 ldr r4, [r0, #104] ; 0x68
ptimer->overrun = 0;
a000a6fc: e5803068 str r3, [r0, #104] ; 0x68
_Thread_Enable_dispatch();
a000a700: eb000a9c bl a000d178 <_Thread_Enable_dispatch>
return overrun;
a000a704: ea000003 b a000a718 <timer_getoverrun+0x40>
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a000a708: eb00222d bl a0012fc4 <__errno>
a000a70c: e3a03016 mov r3, #22
a000a710: e5803000 str r3, [r0]
a000a714: e3e04000 mvn r4, #0
}
a000a718: e1a00004 mov r0, r4
a000a71c: e8bd8018 pop {r3, r4, pc}
a000a724 <timer_gettime>:
int timer_gettime(
timer_t timerid,
struct itimerspec *value
)
{
a000a724: e92d4077 push {r0, r1, r2, r4, r5, r6, lr}
POSIX_Timer_Control *ptimer;
Objects_Locations location;
struct timespec current_time;
Watchdog_Interval left;
if ( !value )
a000a728: e2514000 subs r4, r1, #0
int timer_gettime(
timer_t timerid,
struct itimerspec *value
)
{
a000a72c: e1a05000 mov r5, r0
POSIX_Timer_Control *ptimer;
Objects_Locations location;
struct timespec current_time;
Watchdog_Interval left;
if ( !value )
a000a730: 0a000017 beq a000a794 <timer_gettime+0x70>
rtems_set_errno_and_return_minus_one( EINVAL );
/* Reads the current time */
_TOD_Get( ¤t_time );
a000a734: e1a0000d mov r0, sp
a000a738: eb000558 bl a000bca0 <_TOD_Get> <== NOT EXECUTED
a000a73c: e1a01005 mov r1, r5 <== NOT EXECUTED
a000a740: e59f0060 ldr r0, [pc, #96] ; a000a7a8 <timer_gettime+0x84> <== NOT EXECUTED
a000a744: e28d2008 add r2, sp, #8 <== NOT EXECUTED
a000a748: eb0007d2 bl a000c698 <_Objects_Get> <== NOT EXECUTED
ptimer = _POSIX_Timer_Get( timerid, &location );
switch ( location ) {
a000a74c: e59d6008 ldr r6, [sp, #8] <== NOT EXECUTED
a000a750: e1a05000 mov r5, r0 <== NOT EXECUTED
a000a754: e3560000 cmp r6, #0 <== NOT EXECUTED
a000a758: 1a00000d bne a000a794 <timer_gettime+0x70> <== NOT EXECUTED
case OBJECTS_LOCAL:
/* Calculates the time left before the timer finishes */
left =
(ptimer->Timer.start_time + ptimer->Timer.initial) - /* expire */
a000a75c: e59f3048 ldr r3, [pc, #72] ; a000a7ac <timer_gettime+0x88> <== NOT EXECUTED
a000a760: e5952024 ldr r2, [r5, #36] ; 0x24 <== NOT EXECUTED
a000a764: e590001c ldr r0, [r0, #28] <== NOT EXECUTED
a000a768: e5933000 ldr r3, [r3] <== NOT EXECUTED
_Watchdog_Ticks_since_boot; /* now */
_Timespec_From_ticks( left, &value->it_value );
a000a76c: e2841008 add r1, r4, #8 <== NOT EXECUTED
case OBJECTS_LOCAL:
/* Calculates the time left before the timer finishes */
left =
(ptimer->Timer.start_time + ptimer->Timer.initial) - /* expire */
a000a770: e0800002 add r0, r0, r2 <== NOT EXECUTED
_Watchdog_Ticks_since_boot; /* now */
_Timespec_From_ticks( left, &value->it_value );
a000a774: e0630000 rsb r0, r3, r0 <== NOT EXECUTED
a000a778: eb000d52 bl a000dcc8 <_Timespec_From_ticks> <== NOT EXECUTED
value->it_interval = ptimer->timer_data.it_interval;
a000a77c: e2853054 add r3, r5, #84 ; 0x54 <== NOT EXECUTED
a000a780: e893000c ldm r3, {r2, r3} <== NOT EXECUTED
a000a784: e884000c stm r4, {r2, r3} <== NOT EXECUTED
_Thread_Enable_dispatch();
a000a788: eb000a7a bl a000d178 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a000a78c: e1a00006 mov r0, r6 <== NOT EXECUTED
a000a790: ea000003 b a000a7a4 <timer_gettime+0x80> <== NOT EXECUTED
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a000a794: eb00220a bl a0012fc4 <__errno>
a000a798: e3a03016 mov r3, #22
a000a79c: e5803000 str r3, [r0]
a000a7a0: e3e00000 mvn r0, #0
}
a000a7a4: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc}
a0009460 <timer_settime>:
timer_t timerid,
int flags,
const struct itimerspec *value,
struct itimerspec *ovalue
)
{
a0009460: e92d41f0 push {r4, r5, r6, r7, r8, lr}
Objects_Locations location;
bool activated;
uint32_t initial_period;
struct itimerspec normalize;
if ( !value )
a0009464: e2525000 subs r5, r2, #0
timer_t timerid,
int flags,
const struct itimerspec *value,
struct itimerspec *ovalue
)
{
a0009468: e24dd020 sub sp, sp, #32
a000946c: e1a08000 mov r8, r0
a0009470: e1a07001 mov r7, r1
a0009474: e1a04003 mov r4, r3
Objects_Locations location;
bool activated;
uint32_t initial_period;
struct itimerspec normalize;
if ( !value )
a0009478: 0a000056 beq a00095d8 <timer_settime+0x178>
/*
* First, it verifies if the structure "value" is correct
* if the number of nanoseconds is not correct return EINVAL
*/
if ( !_Timespec_Is_valid( &(value->it_value) ) ) {
a000947c: e2850008 add r0, r5, #8
a0009480: eb000dcc bl a000cbb8 <_Timespec_Is_valid>
a0009484: e3500000 cmp r0, #0
a0009488: 0a000052 beq a00095d8 <timer_settime+0x178>
rtems_set_errno_and_return_minus_one( EINVAL );
}
if ( !_Timespec_Is_valid( &(value->it_interval) ) ) {
a000948c: e1a00005 mov r0, r5
a0009490: eb000dc8 bl a000cbb8 <_Timespec_Is_valid>
a0009494: e3500000 cmp r0, #0
a0009498: 0a00004e beq a00095d8 <timer_settime+0x178>
rtems_set_errno_and_return_minus_one( EINVAL );
}
if ( flags != TIMER_ABSTIME && flags != POSIX_TIMER_RELATIVE ) {
a000949c: e3570000 cmp r7, #0
a00094a0: 13570004 cmpne r7, #4
a00094a4: 1a00004b bne a00095d8 <timer_settime+0x178>
rtems_set_errno_and_return_minus_one( EINVAL );
}
normalize = *value;
a00094a8: e28d6004 add r6, sp, #4
/* Convert absolute to relative time */
if (flags == TIMER_ABSTIME) {
a00094ac: e3570004 cmp r7, #4
if ( flags != TIMER_ABSTIME && flags != POSIX_TIMER_RELATIVE ) {
rtems_set_errno_and_return_minus_one( EINVAL );
}
normalize = *value;
a00094b0: e895000f ldm r5, {r0, r1, r2, r3}
a00094b4: e886000f stm r6, {r0, r1, r2, r3}
/* Convert absolute to relative time */
if (flags == TIMER_ABSTIME) {
a00094b8: 1a00000c bne a00094f0 <timer_settime+0x90>
struct timespec now;
_TOD_Get( &now );
a00094bc: e28d7014 add r7, sp, #20
a00094c0: e1a00007 mov r0, r7
/* Check for seconds in the past */
if ( _Timespec_Greater_than( &now, &normalize.it_value ) )
a00094c4: e2866008 add r6, r6, #8
normalize = *value;
/* Convert absolute to relative time */
if (flags == TIMER_ABSTIME) {
struct timespec now;
_TOD_Get( &now );
a00094c8: eb0005a9 bl a000ab74 <_TOD_Get>
/* Check for seconds in the past */
if ( _Timespec_Greater_than( &now, &normalize.it_value ) )
a00094cc: e1a00007 mov r0, r7
a00094d0: e1a01006 mov r1, r6
a00094d4: eb000da9 bl a000cb80 <_Timespec_Greater_than>
a00094d8: e3500000 cmp r0, #0
a00094dc: 1a00003d bne a00095d8 <timer_settime+0x178>
rtems_set_errno_and_return_minus_one( EINVAL );
_Timespec_Subtract( &now, &normalize.it_value, &normalize.it_value );
a00094e0: e1a00007 mov r0, r7
a00094e4: e1a01006 mov r1, r6
a00094e8: e1a02006 mov r2, r6
a00094ec: eb000dc2 bl a000cbfc <_Timespec_Subtract>
timer_t id,
Objects_Locations *location
)
{
return (POSIX_Timer_Control *)
_Objects_Get( &_POSIX_Timer_Information, (Objects_Id) id, location );
a00094f0: e59f00f8 ldr r0, [pc, #248] ; a00095f0 <timer_settime+0x190>
a00094f4: e1a01008 mov r1, r8
a00094f8: e28d201c add r2, sp, #28
a00094fc: eb000813 bl a000b550 <_Objects_Get>
* something with the structure of times of the timer: to stop, start
* or start it again
*/
ptimer = _POSIX_Timer_Get( timerid, &location );
switch ( location ) {
a0009500: e59d301c ldr r3, [sp, #28]
a0009504: e1a06000 mov r6, r0
a0009508: e3530000 cmp r3, #0
a000950c: 1a000031 bne a00095d8 <timer_settime+0x178>
case OBJECTS_LOCAL:
/* First, it verifies if the timer must be stopped */
if ( normalize.it_value.tv_sec == 0 && normalize.it_value.tv_nsec == 0 ) {
a0009510: e59d300c ldr r3, [sp, #12]
a0009514: e3530000 cmp r3, #0
a0009518: 1a00000f bne a000955c <timer_settime+0xfc>
a000951c: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED
a0009520: e3530000 cmp r3, #0 <== NOT EXECUTED
a0009524: 1a00000c bne a000955c <timer_settime+0xfc> <== NOT EXECUTED
/* Stop the timer */
(void) _Watchdog_Remove( &ptimer->Timer );
a0009528: e2800010 add r0, r0, #16 <== NOT EXECUTED
a000952c: eb000ed2 bl a000d07c <_Watchdog_Remove> <== NOT EXECUTED
/* The old data of the timer are returned */
if ( ovalue )
a0009530: e3540000 cmp r4, #0 <== NOT EXECUTED
*ovalue = ptimer->timer_data;
a0009534: 12863054 addne r3, r6, #84 ; 0x54 <== NOT EXECUTED
a0009538: 1893000f ldmne r3, {r0, r1, r2, r3} <== NOT EXECUTED
a000953c: 1884000f stmne r4, {r0, r1, r2, r3} <== NOT EXECUTED
/* The new data are set */
ptimer->timer_data = normalize;
a0009540: e286c054 add ip, r6, #84 ; 0x54 <== NOT EXECUTED
a0009544: e28d3004 add r3, sp, #4 <== NOT EXECUTED
a0009548: e893000f ldm r3, {r0, r1, r2, r3} <== NOT EXECUTED
a000954c: e88c000f stm ip, {r0, r1, r2, r3} <== NOT EXECUTED
/* Indicates that the timer is created and stopped */
ptimer->state = POSIX_TIMER_STATE_CREATE_STOP;
a0009550: e3a03004 mov r3, #4 <== NOT EXECUTED
a0009554: e5c6303c strb r3, [r6, #60] ; 0x3c <== NOT EXECUTED
a0009558: ea00001b b a00095cc <timer_settime+0x16c> <== NOT EXECUTED
_Thread_Enable_dispatch();
return 0;
}
/* Convert from seconds and nanoseconds to ticks */
ptimer->ticks = _Timespec_To_ticks( &value->it_interval );
a000955c: e1a00005 mov r0, r5
a0009560: eb000db7 bl a000cc44 <_Timespec_To_ticks>
a0009564: e5860064 str r0, [r6, #100] ; 0x64
initial_period = _Timespec_To_ticks( &normalize.it_value );
a0009568: e28d000c add r0, sp, #12
a000956c: eb000db4 bl a000cc44 <_Timespec_To_ticks>
activated = _POSIX_Timer_Insert_helper(
a0009570: e58d6000 str r6, [sp]
return 0;
}
/* Convert from seconds and nanoseconds to ticks */
ptimer->ticks = _Timespec_To_ticks( &value->it_interval );
initial_period = _Timespec_To_ticks( &normalize.it_value );
a0009574: e1a01000 mov r1, r0
activated = _POSIX_Timer_Insert_helper(
a0009578: e5962008 ldr r2, [r6, #8]
a000957c: e2860010 add r0, r6, #16
a0009580: e59f306c ldr r3, [pc, #108] ; a00095f4 <timer_settime+0x194>
a0009584: eb0017a9 bl a000f430 <_POSIX_Timer_Insert_helper>
initial_period,
ptimer->Object.id,
_POSIX_Timer_TSR,
ptimer
);
if ( !activated ) {
a0009588: e2505000 subs r5, r0, #0
a000958c: 1a000002 bne a000959c <timer_settime+0x13c>
_Thread_Enable_dispatch();
a0009590: eb000aa6 bl a000c030 <_Thread_Enable_dispatch> <== NOT EXECUTED
return 0;
a0009594: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009598: ea000012 b a00095e8 <timer_settime+0x188> <== NOT EXECUTED
/*
* The timer has been started and is running. So we return the
* old ones in "ovalue"
*/
if ( ovalue )
a000959c: e3540000 cmp r4, #0
*ovalue = ptimer->timer_data;
a00095a0: 12863054 addne r3, r6, #84 ; 0x54
a00095a4: 1893000f ldmne r3, {r0, r1, r2, r3}
a00095a8: 1884000f stmne r4, {r0, r1, r2, r3}
ptimer->timer_data = normalize;
a00095ac: e286c054 add ip, r6, #84 ; 0x54
a00095b0: e28d3004 add r3, sp, #4
a00095b4: e893000f ldm r3, {r0, r1, r2, r3}
a00095b8: e88c000f stm ip, {r0, r1, r2, r3}
/* Indicate that the time is running */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
a00095bc: e3a03003 mov r3, #3
a00095c0: e5c6303c strb r3, [r6, #60] ; 0x3c
_TOD_Get( &ptimer->time );
a00095c4: e286006c add r0, r6, #108 ; 0x6c
a00095c8: eb000569 bl a000ab74 <_TOD_Get>
_Thread_Enable_dispatch();
a00095cc: eb000a97 bl a000c030 <_Thread_Enable_dispatch>
return 0;
a00095d0: e3a00000 mov r0, #0
a00095d4: ea000003 b a00095e8 <timer_settime+0x188>
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
a00095d8: eb00220c bl a0011e10 <__errno> <== NOT EXECUTED
a00095dc: e3a03016 mov r3, #22 <== NOT EXECUTED
a00095e0: e5803000 str r3, [r0] <== NOT EXECUTED
a00095e4: e3e00000 mvn r0, #0 <== NOT EXECUTED
}
a00095e8: e28dd020 add sp, sp, #32
a00095ec: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
a00092c8 <ualarm>:
useconds_t ualarm(
useconds_t useconds,
useconds_t interval
)
{
a00092c8: e92d4073 push {r0, r1, r4, r5, r6, lr} <== NOT EXECUTED
/*
* Initialize the timer used to implement alarm().
*/
if ( !the_timer->routine ) {
a00092cc: e59f60d0 ldr r6, [pc, #208] ; a00093a4 <ualarm+0xdc> <== NOT EXECUTED
useconds_t ualarm(
useconds_t useconds,
useconds_t interval
)
{
a00092d0: e1a05000 mov r5, r0 <== NOT EXECUTED
/*
* Initialize the timer used to implement alarm().
*/
if ( !the_timer->routine ) {
a00092d4: e596401c ldr r4, [r6, #28] <== NOT EXECUTED
a00092d8: e3540000 cmp r4, #0 <== NOT EXECUTED
a00092dc: 1a000005 bne a00092f8 <ualarm+0x30> <== NOT EXECUTED
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a00092e0: e59f30c0 ldr r3, [pc, #192] ; a00093a8 <ualarm+0xe0> <== NOT EXECUTED
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
a00092e4: e5864008 str r4, [r6, #8] <== NOT EXECUTED
the_watchdog->routine = routine;
the_watchdog->id = id;
a00092e8: e5864020 str r4, [r6, #32] <== NOT EXECUTED
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
a00092ec: e586301c str r3, [r6, #28] <== NOT EXECUTED
the_watchdog->id = id;
the_watchdog->user_data = user_data;
a00092f0: e5864024 str r4, [r6, #36] ; 0x24 <== NOT EXECUTED
a00092f4: ea000013 b a0009348 <ualarm+0x80> <== NOT EXECUTED
_Watchdog_Initialize( the_timer, _POSIX_signals_Ualarm_TSR, 0, NULL );
} else {
Watchdog_States state;
state = _Watchdog_Remove( the_timer );
a00092f8: e1a00006 mov r0, r6 <== NOT EXECUTED
a00092fc: eb000e5f bl a000cc80 <_Watchdog_Remove> <== NOT EXECUTED
if ( (state == WATCHDOG_ACTIVE) || (state == WATCHDOG_REMOVE_IT) ) {
a0009300: e2400002 sub r0, r0, #2 <== NOT EXECUTED
a0009304: e3500001 cmp r0, #1 <== NOT EXECUTED
useconds_t ualarm(
useconds_t useconds,
useconds_t interval
)
{
useconds_t remaining = 0;
a0009308: 83a04000 movhi r4, #0 <== NOT EXECUTED
_Watchdog_Initialize( the_timer, _POSIX_signals_Ualarm_TSR, 0, NULL );
} else {
Watchdog_States state;
state = _Watchdog_Remove( the_timer );
if ( (state == WATCHDOG_ACTIVE) || (state == WATCHDOG_REMOVE_IT) ) {
a000930c: 8a00000d bhi a0009348 <ualarm+0x80> <== NOT EXECUTED
* boot. Since alarm() is dealing in seconds, we must account for
* this.
*/
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
a0009310: e596300c ldr r3, [r6, #12] <== NOT EXECUTED
a0009314: e5960014 ldr r0, [r6, #20] <== NOT EXECUTED
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
a0009318: e1a0100d mov r1, sp <== NOT EXECUTED
remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND;
a000931c: e59f4088 ldr r4, [pc, #136] ; a00093ac <ualarm+0xe4> <== NOT EXECUTED
* boot. Since alarm() is dealing in seconds, we must account for
* this.
*/
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
a0009320: e0800003 add r0, r0, r3 <== NOT EXECUTED
a0009324: e5963018 ldr r3, [r6, #24] <== NOT EXECUTED
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
a0009328: e0630000 rsb r0, r3, r0 <== NOT EXECUTED
a000932c: eb000cf9 bl a000c718 <_Timespec_From_ticks> <== NOT EXECUTED
remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND;
a0009330: e59d3000 ldr r3, [sp] <== NOT EXECUTED
remaining += tp.tv_nsec / 1000;
a0009334: e59d0004 ldr r0, [sp, #4] <== NOT EXECUTED
a0009338: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND;
a000933c: e0040493 mul r4, r3, r4 <== NOT EXECUTED
remaining += tp.tv_nsec / 1000;
a0009340: eb0034f8 bl a0016728 <__aeabi_idiv> <== NOT EXECUTED
a0009344: e0804004 add r4, r0, r4 <== NOT EXECUTED
/*
* If useconds is non-zero, then the caller wants to schedule
* the alarm repeatedly at that interval. If the interval is
* less than a single clock tick, then fudge it to a clock tick.
*/
if ( useconds ) {
a0009348: e3550000 cmp r5, #0 <== NOT EXECUTED
a000934c: 0a000012 beq a000939c <ualarm+0xd4> <== NOT EXECUTED
Watchdog_Interval ticks;
tp.tv_sec = useconds / TOD_MICROSECONDS_PER_SECOND;
a0009350: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009354: e59f1050 ldr r1, [pc, #80] ; a00093ac <ualarm+0xe4> <== NOT EXECUTED
a0009358: eb0034ac bl a0016610 <__aeabi_uidiv> <== NOT EXECUTED
tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000;
a000935c: e59f1048 ldr r1, [pc, #72] ; a00093ac <ualarm+0xe4> <== NOT EXECUTED
* less than a single clock tick, then fudge it to a clock tick.
*/
if ( useconds ) {
Watchdog_Interval ticks;
tp.tv_sec = useconds / TOD_MICROSECONDS_PER_SECOND;
a0009360: e58d0000 str r0, [sp] <== NOT EXECUTED
tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000;
a0009364: e1a00005 mov r0, r5 <== NOT EXECUTED
a0009368: eb003540 bl a0016870 <__umodsi3> <== NOT EXECUTED
a000936c: e3a03ffa mov r3, #1000 ; 0x3e8 <== NOT EXECUTED
a0009370: e0030390 mul r3, r0, r3 <== NOT EXECUTED
ticks = _Timespec_To_ticks( &tp );
a0009374: e1a0000d mov r0, sp <== NOT EXECUTED
*/
if ( useconds ) {
Watchdog_Interval ticks;
tp.tv_sec = useconds / TOD_MICROSECONDS_PER_SECOND;
tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000;
a0009378: e58d3004 str r3, [sp, #4] <== NOT EXECUTED
ticks = _Timespec_To_ticks( &tp );
a000937c: eb000d09 bl a000c7a8 <_Timespec_To_ticks> <== NOT EXECUTED
if ( ticks == 0 )
ticks = 1;
_Watchdog_Insert_ticks( the_timer, _Timespec_To_ticks( &tp ) );
a0009380: e1a0000d mov r0, sp <== NOT EXECUTED
a0009384: eb000d07 bl a000c7a8 <_Timespec_To_ticks> <== NOT EXECUTED
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
a0009388: e59f1014 ldr r1, [pc, #20] ; a00093a4 <ualarm+0xdc> <== NOT EXECUTED
if ( useconds ) {
Watchdog_Interval ticks;
tp.tv_sec = useconds / TOD_MICROSECONDS_PER_SECOND;
tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000;
ticks = _Timespec_To_ticks( &tp );
a000938c: e1a0500d mov r5, sp <== NOT EXECUTED
a0009390: e581000c str r0, [r1, #12] <== NOT EXECUTED
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
a0009394: e59f0014 ldr r0, [pc, #20] ; a00093b0 <ualarm+0xe8> <== NOT EXECUTED
a0009398: eb000de0 bl a000cb20 <_Watchdog_Insert> <== NOT EXECUTED
_Watchdog_Insert_ticks( the_timer, _Timespec_To_ticks( &tp ) );
}
return remaining;
}
a000939c: e1a00004 mov r0, r4 <== NOT EXECUTED
a00093a0: e8bd807c pop {r2, r3, r4, r5, r6, pc} <== NOT EXECUTED
a00093ac <vfork>:
#include <unistd.h>
pid_t vfork(void)
{
return -1;
}
a00093ac: e3e00000 mvn r0, #0 <== NOT EXECUTED
a00093b0: e12fff1e bx lr <== NOT EXECUTED
a00093b4 <wait>:
#include <rtems/seterr.h>
int wait(
int *stat_loc
)
{
a00093b4: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a00093b8: eb00218f bl a00119fc <__errno> <== NOT EXECUTED
a00093bc: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a00093c0: e5803000 str r3, [r0] <== NOT EXECUTED
}
a00093c4: e3e00000 mvn r0, #0 <== NOT EXECUTED
a00093c8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
a00093cc <waitpid>:
int waitpid(
pid_t pid,
int *stat_loc,
int options
)
{
a00093cc: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSYS );
a00093d0: eb002189 bl a00119fc <__errno> <== NOT EXECUTED
a00093d4: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED
a00093d8: e5803000 str r3, [r0] <== NOT EXECUTED
}
a00093dc: e3e00000 mvn r0, #0 <== NOT EXECUTED
a00093e0: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED