=============================================================================== a000f974 : /** * We should ensure the ticks not be truncated by integer division. We * need to have it be greater than or equal to the requested time. It * should not be shorter. */ microseconds_per_tick = rtems_configuration_get_microseconds_per_tick(); a000f974: e59f3030 ldr r3, [pc, #48] ; a000f9ac <== NOT EXECUTED #include uint32_t TOD_MICROSECONDS_TO_TICKS( uint32_t microseconds ) { a000f978: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED /** * We should ensure the ticks not be truncated by integer division. We * need to have it be greater than or equal to the requested time. It * should not be shorter. */ microseconds_per_tick = rtems_configuration_get_microseconds_per_tick(); a000f97c: e593500c ldr r5, [r3, #12] <== NOT EXECUTED #include uint32_t TOD_MICROSECONDS_TO_TICKS( uint32_t microseconds ) { a000f980: e1a06000 mov r6, r0 <== NOT EXECUTED * We should ensure the ticks not be truncated by integer division. We * need to have it be greater than or equal to the requested time. It * should not be shorter. */ microseconds_per_tick = rtems_configuration_get_microseconds_per_tick(); ticks = microseconds / microseconds_per_tick; a000f984: e1a01005 mov r1, r5 <== NOT EXECUTED a000f988: eb004d9b bl a0022ffc <__aeabi_uidiv> <== NOT EXECUTED if ( (microseconds % microseconds_per_tick) != 0 ) a000f98c: e1a01005 mov r1, r5 <== NOT EXECUTED * We should ensure the ticks not be truncated by integer division. We * need to have it be greater than or equal to the requested time. It * should not be shorter. */ microseconds_per_tick = rtems_configuration_get_microseconds_per_tick(); ticks = microseconds / microseconds_per_tick; a000f990: e1a04000 mov r4, r0 <== NOT EXECUTED if ( (microseconds % microseconds_per_tick) != 0 ) a000f994: e1a00006 mov r0, r6 <== NOT EXECUTED a000f998: eb004ddd bl a0023114 <__umodsi3> <== NOT EXECUTED a000f99c: e3500000 cmp r0, #0 <== NOT EXECUTED ticks += 1; a000f9a0: 12844001 addne r4, r4, #1 <== NOT EXECUTED return ticks; } a000f9a4: e1a00004 mov r0, r4 <== NOT EXECUTED a000f9a8: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED =============================================================================== a000d028 <_CORE_RWLock_Obtain_for_reading>: Objects_Id id, bool wait, Watchdog_Interval timeout, CORE_RWLock_API_mp_support_callout api_rwlock_mp_support ) { a000d028: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} a000d02c: e1a08003 mov r8, r3 ISR_Level level; Thread_Control *executing = _Thread_Executing; a000d030: e59f30a4 ldr r3, [pc, #164] ; a000d0dc <_CORE_RWLock_Obtain_for_reading+0xb4> Objects_Id id, bool wait, Watchdog_Interval timeout, CORE_RWLock_API_mp_support_callout api_rwlock_mp_support ) { a000d034: e1a04000 mov r4, r0 a000d038: e1a05001 mov r5, r1 ISR_Level level; Thread_Control *executing = _Thread_Executing; a000d03c: e5936008 ldr r6, [r3, #8] Objects_Id id, bool wait, Watchdog_Interval timeout, CORE_RWLock_API_mp_support_callout api_rwlock_mp_support ) { a000d040: e202a0ff and sl, r2, #255 ; 0xff uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000d044: e10f7000 mrs r7, CPSR a000d048: e3873080 orr r3, r7, #128 ; 0x80 a000d04c: e129f003 msr CPSR_fc, r3 * 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 ) { a000d050: e590c044 ldr ip, [r0, #68] ; 0x44 a000d054: e35c0000 cmp ip, #0 case CORE_RWLOCK_UNLOCKED: the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING; a000d058: 03a03001 moveq r3, #1 a000d05c: 05803044 streq r3, [r0, #68] ; 0x44 * 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 ) { a000d060: 0a000004 beq a000d078 <_CORE_RWLock_Obtain_for_reading+0x50> a000d064: e35c0001 cmp ip, #1 a000d068: 1a000008 bne a000d090 <_CORE_RWLock_Obtain_for_reading+0x68> 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 ); a000d06c: eb0008ab bl a000f320 <_Thread_queue_First> <== NOT EXECUTED if ( !waiter ) { a000d070: e3500000 cmp r0, #0 <== NOT EXECUTED a000d074: 1a000005 bne a000d090 <_CORE_RWLock_Obtain_for_reading+0x68><== NOT EXECUTED the_rwlock->number_of_readers += 1; a000d078: e5943048 ldr r3, [r4, #72] ; 0x48 a000d07c: e2833001 add r3, r3, #1 a000d080: e5843048 str r3, [r4, #72] ; 0x48 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000d084: e129f007 msr CPSR_fc, r7 _ISR_Enable( level ); executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL; a000d088: e3a03000 mov r3, #0 a000d08c: ea000003 b a000d0a0 <_CORE_RWLock_Obtain_for_reading+0x78> /* * If the thread is not willing to wait, then return immediately. */ if ( !wait ) { a000d090: e35a0000 cmp sl, #0 a000d094: 1a000003 bne a000d0a8 <_CORE_RWLock_Obtain_for_reading+0x80> a000d098: e129f007 msr CPSR_fc, r7 _ISR_Enable( level ); executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE; a000d09c: e3a03002 mov r3, #2 a000d0a0: e5863034 str r3, [r6, #52] ; 0x34 return; a000d0a4: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} a000d0a8: e3a03001 mov r3, #1 a000d0ac: e5843030 str r3, [r4, #48] ; 0x30 */ _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; a000d0b0: e3a03000 mov r3, #0 /* * 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; a000d0b4: e5864044 str r4, [r6, #68] ; 0x44 executing->Wait.id = id; a000d0b8: e5865020 str r5, [r6, #32] executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_READ; a000d0bc: e5863030 str r3, [r6, #48] ; 0x30 executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL; a000d0c0: e5863034 str r3, [r6, #52] ; 0x34 a000d0c4: e129f007 msr CPSR_fc, r7 _ISR_Enable( level ); _Thread_queue_Enqueue_with_handler( a000d0c8: e59f2010 ldr r2, [pc, #16] ; a000d0e0 <_CORE_RWLock_Obtain_for_reading+0xb8> a000d0cc: e1a00004 mov r0, r4 a000d0d0: e1a01008 mov r1, r8 timeout, _CORE_RWLock_Timeout ); /* return to API level so it can dispatch and we block */ } a000d0d4: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr} 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( a000d0d8: ea0007bd b a000efd4 <_Thread_queue_Enqueue_with_handler> =============================================================================== a000d170 <_CORE_RWLock_Release>: CORE_RWLock_Status _CORE_RWLock_Release( CORE_RWLock_Control *the_rwlock ) { ISR_Level level; Thread_Control *executing = _Thread_Executing; a000d170: e59f30d8 ldr r3, [pc, #216] ; a000d250 <_CORE_RWLock_Release+0xe0> #include CORE_RWLock_Status _CORE_RWLock_Release( CORE_RWLock_Control *the_rwlock ) { a000d174: e92d4010 push {r4, lr} ISR_Level level; Thread_Control *executing = _Thread_Executing; a000d178: e5932008 ldr r2, [r3, #8] #include CORE_RWLock_Status _CORE_RWLock_Release( CORE_RWLock_Control *the_rwlock ) { a000d17c: e1a04000 mov r4, r0 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000d180: e10f3000 mrs r3, CPSR a000d184: e3831080 orr r1, r3, #128 ; 0x80 a000d188: e129f001 msr CPSR_fc, r1 * 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){ a000d18c: e5901044 ldr r1, [r0, #68] ; 0x44 a000d190: e3510000 cmp r1, #0 a000d194: 1a000003 bne a000d1a8 <_CORE_RWLock_Release+0x38> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000d198: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED _ISR_Enable( level ); executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE; a000d19c: e3a03002 mov r3, #2 <== NOT EXECUTED a000d1a0: e5823034 str r3, [r2, #52] ; 0x34 <== NOT EXECUTED return CORE_RWLOCK_SUCCESSFUL; a000d1a4: ea000027 b a000d248 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED } if ( the_rwlock->current_state == CORE_RWLOCK_LOCKED_FOR_READING ) { a000d1a8: e3510001 cmp r1, #1 a000d1ac: 1a000006 bne a000d1cc <_CORE_RWLock_Release+0x5c> the_rwlock->number_of_readers -= 1; a000d1b0: e5901048 ldr r1, [r0, #72] ; 0x48 a000d1b4: e2411001 sub r1, r1, #1 if ( the_rwlock->number_of_readers != 0 ) { a000d1b8: e3510000 cmp r1, #0 _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; a000d1bc: e5801048 str r1, [r0, #72] ; 0x48 if ( the_rwlock->number_of_readers != 0 ) { a000d1c0: 0a000001 beq a000d1cc <_CORE_RWLock_Release+0x5c> a000d1c4: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED /* must be unlocked again */ _ISR_Enable( level ); return CORE_RWLOCK_SUCCESSFUL; a000d1c8: ea00001e b a000d248 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED } } /* CORE_RWLOCK_LOCKED_FOR_WRITING or READING with readers */ executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL; a000d1cc: e3a01000 mov r1, #0 a000d1d0: e5821034 str r1, [r2, #52] ; 0x34 /* * Implicitly transition to "unlocked" and find another thread interested * in obtaining this rwlock. */ the_rwlock->current_state = CORE_RWLOCK_UNLOCKED; a000d1d4: e5841044 str r1, [r4, #68] ; 0x44 a000d1d8: e129f003 msr CPSR_fc, r3 _ISR_Enable( level ); next = _Thread_queue_Dequeue( &the_rwlock->Wait_queue ); a000d1dc: e1a00004 mov r0, r4 a000d1e0: eb000724 bl a000ee78 <_Thread_queue_Dequeue> if ( next ) { a000d1e4: e3500000 cmp r0, #0 a000d1e8: 0a000016 beq a000d248 <_CORE_RWLock_Release+0xd8> if ( next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE ) { a000d1ec: e5903030 ldr r3, [r0, #48] ; 0x30 a000d1f0: e3530001 cmp r3, #1 the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_WRITING; a000d1f4: 03a03002 moveq r3, #2 a000d1f8: 05843044 streq r3, [r4, #68] ; 0x44 _ISR_Enable( level ); next = _Thread_queue_Dequeue( &the_rwlock->Wait_queue ); if ( next ) { if ( next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE ) { a000d1fc: 0a000011 beq a000d248 <_CORE_RWLock_Release+0xd8> } /* * Must be CORE_RWLOCK_THREAD_WAITING_FOR_READING */ the_rwlock->number_of_readers += 1; a000d200: e5943048 ldr r3, [r4, #72] ; 0x48 <== NOT EXECUTED a000d204: e2833001 add r3, r3, #1 <== NOT EXECUTED a000d208: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING; a000d20c: e3a03001 mov r3, #1 <== NOT EXECUTED a000d210: 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 ); a000d214: e1a00004 mov r0, r4 <== NOT EXECUTED a000d218: eb000840 bl a000f320 <_Thread_queue_First> <== NOT EXECUTED if ( !next || a000d21c: e2501000 subs r1, r0, #0 <== NOT EXECUTED a000d220: 0a000008 beq a000d248 <_CORE_RWLock_Release+0xd8> <== NOT EXECUTED a000d224: e5913030 ldr r3, [r1, #48] ; 0x30 <== NOT EXECUTED a000d228: e3530001 cmp r3, #1 <== NOT EXECUTED a000d22c: 0a000005 beq a000d248 <_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; a000d230: e5943048 ldr r3, [r4, #72] ; 0x48 <== NOT EXECUTED _Thread_queue_Extract( &the_rwlock->Wait_queue, next ); a000d234: 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; a000d238: e2833001 add r3, r3, #1 <== NOT EXECUTED a000d23c: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED _Thread_queue_Extract( &the_rwlock->Wait_queue, next ); a000d240: eb0007ef bl a000f204 <_Thread_queue_Extract> <== NOT EXECUTED } a000d244: eafffff2 b a000d214 <_CORE_RWLock_Release+0xa4> <== NOT EXECUTED } /* indentation is to match _ISR_Disable at top */ return CORE_RWLOCK_SUCCESSFUL; } a000d248: e3a00000 mov r0, #0 a000d24c: e8bd8010 pop {r4, pc} =============================================================================== a000d254 <_CORE_RWLock_Timeout>: void _CORE_RWLock_Timeout( Objects_Id id, void *ignored ) { a000d254: e92d4001 push {r0, lr} <== NOT EXECUTED Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); a000d258: e1a0100d mov r1, sp <== NOT EXECUTED a000d25c: eb000639 bl a000eb48 <_Thread_Get> <== NOT EXECUTED switch ( location ) { a000d260: e59d3000 ldr r3, [sp] <== NOT EXECUTED a000d264: e3530000 cmp r3, #0 <== NOT EXECUTED a000d268: 1a000004 bne a000d280 <_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 ); a000d26c: eb000865 bl a000f408 <_Thread_queue_Process_timeout> <== NOT EXECUTED * * This routine decrements the thread dispatch level. */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000d270: e59f300c ldr r3, [pc, #12] ; a000d284 <_CORE_RWLock_Timeout+0x30><== NOT EXECUTED a000d274: e5932000 ldr r2, [r3] <== NOT EXECUTED --level; a000d278: e2422001 sub r2, r2, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a000d27c: e5832000 str r2, [r3] <== NOT EXECUTED _Thread_Unnest_dispatch(); break; } } a000d280: e8bd8008 pop {r3, pc} <== NOT EXECUTED =============================================================================== a0019d54 <_CORE_message_queue_Broadcast>: { Thread_Control *the_thread; uint32_t number_broadcasted; Thread_Wait_information *waitp; if ( size > the_message_queue->maximum_message_size ) { a0019d54: 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 ) { a0019d58: 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 ) { a0019d5c: 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 ) { a0019d60: e1a06000 mov r6, r0 a0019d64: e1a0a001 mov sl, r1 a0019d68: e1a07002 mov r7, r2 a0019d6c: 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 ) { a0019d70: 8a000013 bhi a0019dc4 <_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 ) { a0019d74: e5905048 ldr r5, [r0, #72] ; 0x48 a0019d78: e3550000 cmp r5, #0 a0019d7c: 0a000009 beq a0019da8 <_CORE_message_queue_Broadcast+0x54> *count = 0; a0019d80: e3a00000 mov r0, #0 a0019d84: e5880000 str r0, [r8] return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL; a0019d88: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} const void *source, void *destination, size_t size ) { memcpy(destination, source, size); a0019d8c: e594002c ldr r0, [r4, #44] ; 0x2c a0019d90: e1a0100a mov r1, sl a0019d94: e1a02007 mov r2, r7 a0019d98: eb002064 bl a0021f30 buffer, waitp->return_argument_second.mutable_object, size ); *(size_t *) the_thread->Wait.return_argument = size; a0019d9c: 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; a0019da0: e2855001 add r5, r5, #1 buffer, waitp->return_argument_second.mutable_object, size ); *(size_t *) the_thread->Wait.return_argument = size; a0019da4: 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 = a0019da8: e1a00006 mov r0, r6 a0019dac: eb000b88 bl a001cbd4 <_Thread_queue_Dequeue> a0019db0: e2504000 subs r4, r0, #0 a0019db4: 1afffff4 bne a0019d8c <_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; a0019db8: e5885000 str r5, [r8] return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL; a0019dbc: e1a00004 mov r0, r4 a0019dc0: 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; a0019dc4: e3a00001 mov r0, #1 <== NOT EXECUTED #endif } *count = number_broadcasted; return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL; } a0019dc8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED =============================================================================== a0012ae4 <_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 ) { a0012ae4: e92d40f0 push {r4, r5, r6, r7, lr} /* * Check if allocated_message_size is aligned to uintptr-size boundary. * If not, it will increase allocated_message_size to multiplicity of pointer * size. */ if (allocated_message_size & (sizeof(uintptr_t) - 1)) { a0012ae8: 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 ) { a0012aec: e1a04000 mov r4, r0 size_t message_buffering_required = 0; size_t allocated_message_size; the_message_queue->maximum_pending_messages = maximum_pending_messages; the_message_queue->number_of_pending_messages = 0; a0012af0: 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 ) { a0012af4: e1a07001 mov r7, r1 a0012af8: e1a05002 mov r5, r2 size_t message_buffering_required = 0; size_t allocated_message_size; the_message_queue->maximum_pending_messages = maximum_pending_messages; a0012afc: e5842044 str r2, [r4, #68] ; 0x44 the_message_queue->number_of_pending_messages = 0; a0012b00: e5840048 str r0, [r4, #72] ; 0x48 the_message_queue->maximum_message_size = maximum_message_size; a0012b04: 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; a0012b08: e5840060 str r0, [r4, #96] ; 0x60 the_message_queue->notify_argument = the_argument; a0012b0c: e5840064 str r0, [r4, #100] ; 0x64 /* * Check if allocated_message_size is aligned to uintptr-size boundary. * If not, it will increase allocated_message_size to multiplicity of pointer * size. */ if (allocated_message_size & (sizeof(uintptr_t) - 1)) { a0012b10: 01a06003 moveq r6, r3 a0012b14: 0a000003 beq a0012b28 <_CORE_message_queue_Initialize+0x44> allocated_message_size += sizeof(uintptr_t); a0012b18: e2836004 add r6, r3, #4 allocated_message_size &= ~(sizeof(uintptr_t) - 1); a0012b1c: e3c66003 bic r6, r6, #3 /* * Check for an overflow. It can occur while increasing allocated_message_size * to multiplicity of uintptr_t above. */ if (allocated_message_size < maximum_message_size) a0012b20: e1560003 cmp r6, r3 a0012b24: 3a000021 bcc a0012bb0 <_CORE_message_queue_Initialize+0xcc> /* * Calculate how much total memory is required for message buffering and * check for overflow on the multiplication. */ if ( !size_t_mult32_with_overflow( a0012b28: e2866014 add r6, r6, #20 size_t a, size_t b, size_t *c ) { long long x = (long long)a*b; a0012b2c: e0810695 umull r0, r1, r5, r6 if ( x > SIZE_MAX ) a0012b30: e3e02000 mvn r2, #0 a0012b34: e3a03000 mov r3, #0 a0012b38: e1520000 cmp r2, r0 a0012b3c: e0d3c001 sbcs ip, r3, r1 a0012b40: ba000018 blt a0012ba8 <_CORE_message_queue_Initialize+0xc4> /* * Attempt to allocate the message memory */ the_message_queue->message_buffers = (CORE_message_queue_Buffer *) _Workspace_Allocate( message_buffering_required ); a0012b44: eb000b75 bl a0015920 <_Workspace_Allocate> if (the_message_queue->message_buffers == 0) a0012b48: e3500000 cmp r0, #0 /* * Attempt to allocate the message memory */ the_message_queue->message_buffers = (CORE_message_queue_Buffer *) _Workspace_Allocate( message_buffering_required ); a0012b4c: e1a01000 mov r1, r0 return false; /* * Attempt to allocate the message memory */ the_message_queue->message_buffers = (CORE_message_queue_Buffer *) a0012b50: e584005c str r0, [r4, #92] ; 0x5c _Workspace_Allocate( message_buffering_required ); if (the_message_queue->message_buffers == 0) a0012b54: 0a000015 beq a0012bb0 <_CORE_message_queue_Initialize+0xcc> /* * Initialize the pool of inactive messages, pending messages, * and set of waiting threads. */ _Chain_Initialize ( a0012b58: e2840068 add r0, r4, #104 ; 0x68 a0012b5c: e1a02005 mov r2, r5 a0012b60: e1a03006 mov r3, r6 a0012b64: ebffffce bl a0012aa4 <_Chain_Initialize> allocated_message_size + sizeof( CORE_message_queue_Buffer_control ) ); _Chain_Initialize_empty( &the_message_queue->Pending_messages ); _Thread_queue_Initialize( a0012b68: e5971000 ldr r1, [r7] 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 ); a0012b6c: e2843050 add r3, r4, #80 ; 0x50 a0012b70: e2842054 add r2, r4, #84 ; 0x54 head->next = tail; head->previous = NULL; tail->previous = head; a0012b74: e5843058 str r3, [r4, #88] ; 0x58 a0012b78: e2413001 sub r3, r1, #1 a0012b7c: e2731000 rsbs r1, r3, #0 ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); head->next = tail; a0012b80: e5842050 str r2, [r4, #80] ; 0x50 head->previous = NULL; a0012b84: e3a02000 mov r2, #0 a0012b88: e5842054 str r2, [r4, #84] ; 0x54 a0012b8c: e1a00004 mov r0, r4 a0012b90: e0a11003 adc r1, r1, r3 a0012b94: e3a02080 mov r2, #128 ; 0x80 a0012b98: e3a03006 mov r3, #6 a0012b9c: eb000965 bl a0015138 <_Thread_queue_Initialize> THREAD_QUEUE_DISCIPLINE_PRIORITY : THREAD_QUEUE_DISCIPLINE_FIFO, STATES_WAITING_FOR_MESSAGE, CORE_MESSAGE_QUEUE_STATUS_TIMEOUT ); return true; a0012ba0: e3a00001 mov r0, #1 a0012ba4: e8bd80f0 pop {r4, r5, r6, r7, pc} */ if ( !size_t_mult32_with_overflow( (size_t) maximum_pending_messages, allocated_message_size + sizeof(CORE_message_queue_Buffer_control), &message_buffering_required ) ) return false; a0012ba8: e3a00000 mov r0, #0 <== NOT EXECUTED a0012bac: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED STATES_WAITING_FOR_MESSAGE, CORE_MESSAGE_QUEUE_STATUS_TIMEOUT ); return true; } a0012bb0: e8bd80f0 pop {r4, r5, r6, r7, pc} =============================================================================== a0017aec <_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 ) { a0017aec: 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 ) { a0017af0: e92d4010 push {r4, lr} a0017af4: 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 ) { a0017af8: 1a00000e bne a0017b38 <_CORE_message_queue_Insert_message+0x4c> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0017afc: e10fc000 mrs ip, CPSR a0017b00: e38c3080 orr r3, ip, #128 ; 0x80 a0017b04: e129f003 msr CPSR_fc, r3 _ISR_Disable( level ); SET_NOTIFY(); a0017b08: e5903048 ldr r3, [r0, #72] ; 0x48 RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected( Chain_Control *the_chain, Chain_Node *the_node ) { Chain_Node *tail = _Chain_Tail( the_chain ); a0017b0c: e2804054 add r4, r0, #84 ; 0x54 #include #include #include #include void _CORE_message_queue_Insert_message( a0017b10: e2732001 rsbs r2, r3, #1 _ISR_Enable( level ); #else if ( submit_type == CORE_MESSAGE_QUEUE_SEND_REQUEST ) { _ISR_Disable( level ); SET_NOTIFY(); the_message_queue->number_of_pending_messages++; a0017b14: e2833001 add r3, r3, #1 a0017b18: e5803048 str r3, [r0, #72] ; 0x48 Chain_Node *old_last = tail->previous; a0017b1c: e5903058 ldr r3, [r0, #88] ; 0x58 the_node->next = tail; a0017b20: e5814000 str r4, [r1] tail->previous = the_node; a0017b24: e5801058 str r1, [r0, #88] ; 0x58 #include #include #include #include void _CORE_message_queue_Insert_message( a0017b28: 33a02000 movcc r2, #0 old_last->next = the_node; a0017b2c: e5831000 str r1, [r3] the_node->previous = old_last; a0017b30: e5813004 str r3, [r1, #4] a0017b34: ea000011 b a0017b80 <_CORE_message_queue_Insert_message+0x94> _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 ) { a0017b38: e3520102 cmp r2, #-2147483648 ; 0x80000000 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a0017b3c: 15903050 ldrne r3, [r0, #80] ; 0x50 RTEMS_INLINE_ROUTINE bool _Chain_Is_tail( const Chain_Control *the_chain, const Chain_Node *the_node ) { return (the_node == _Chain_Immutable_tail( the_chain )); a0017b40: 1280c054 addne ip, r0, #84 ; 0x54 a0017b44: 1a000013 bne a0017b98 <_CORE_message_queue_Insert_message+0xac> a0017b48: e10fc000 mrs ip, CPSR a0017b4c: e38c3080 orr r3, ip, #128 ; 0x80 a0017b50: e129f003 msr CPSR_fc, r3 _ISR_Disable( level ); SET_NOTIFY(); a0017b54: e5903048 ldr r3, [r0, #72] ; 0x48 #include #include #include #include void _CORE_message_queue_Insert_message( a0017b58: e2732001 rsbs r2, r3, #1 _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++; a0017b5c: e2833001 add r3, r3, #1 a0017b60: e5803048 str r3, [r0, #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); a0017b64: e2803050 add r3, r0, #80 ; 0x50 Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; a0017b68: e5813004 str r3, [r1, #4] before_node = after_node->next; a0017b6c: e5903050 ldr r3, [r0, #80] ; 0x50 #include #include #include #include void _CORE_message_queue_Insert_message( a0017b70: 33a02000 movcc r2, #0 after_node->next = the_node; a0017b74: e5801050 str r1, [r0, #80] ; 0x50 the_node->next = before_node; before_node->previous = the_node; a0017b78: e5831004 str r1, [r3, #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; a0017b7c: e5813000 str r3, [r1] static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0017b80: e129f00c msr CPSR_fc, ip a0017b84: ea000014 b a0017bdc <_CORE_message_queue_Insert_message+0xf0> this_message = (CORE_message_queue_Buffer_control *) the_node; this_priority = _CORE_message_queue_Get_message_priority(this_message); if ( this_priority <= the_priority ) { a0017b88: e5934008 ldr r4, [r3, #8] <== NOT EXECUTED a0017b8c: e1540002 cmp r4, r2 <== NOT EXECUTED a0017b90: ca000002 bgt a0017ba0 <_CORE_message_queue_Insert_message+0xb4><== NOT EXECUTED the_node = the_node->next; a0017b94: e5933000 ldr r3, [r3] <== 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 ) ) { a0017b98: e153000c cmp r3, ip a0017b9c: 1afffff9 bne a0017b88 <_CORE_message_queue_Insert_message+0x9c> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0017ba0: e10f4000 mrs r4, CPSR a0017ba4: e3842080 orr r2, r4, #128 ; 0x80 a0017ba8: e129f002 msr CPSR_fc, r2 continue; } break; } _ISR_Disable( level ); SET_NOTIFY(); a0017bac: e590c048 ldr ip, [r0, #72] ; 0x48 the_message_queue->number_of_pending_messages++; _Chain_Insert_unprotected( the_node->previous, &the_message->Node ); a0017bb0: e5933004 ldr r3, [r3, #4] #include #include #include #include void _CORE_message_queue_Insert_message( a0017bb4: e27c2001 rsbs r2, ip, #1 } break; } _ISR_Disable( level ); SET_NOTIFY(); the_message_queue->number_of_pending_messages++; a0017bb8: e28cc001 add ip, ip, #1 a0017bbc: e580c048 str ip, [r0, #72] ; 0x48 ) { Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; a0017bc0: e593c000 ldr ip, [r3] Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; a0017bc4: e5813004 str r3, [r1, #4] before_node = after_node->next; after_node->next = the_node; a0017bc8: e5831000 str r1, [r3] #include #include #include #include void _CORE_message_queue_Insert_message( a0017bcc: 33a02000 movcc r2, #0 the_node->next = before_node; a0017bd0: e581c000 str ip, [r1] before_node->previous = the_node; a0017bd4: e58c1004 str r1, [ip, #4] static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0017bd8: e129f004 msr CPSR_fc, r4 /* * 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 ) a0017bdc: e3520000 cmp r2, #0 a0017be0: 0a000004 beq a0017bf8 <_CORE_message_queue_Insert_message+0x10c> a0017be4: e5903060 ldr r3, [r0, #96] ; 0x60 a0017be8: e3530000 cmp r3, #0 a0017bec: 0a000001 beq a0017bf8 <_CORE_message_queue_Insert_message+0x10c> (*the_message_queue->notify_handler)(the_message_queue->notify_argument); a0017bf0: e5900064 ldr r0, [r0, #100] ; 0x64 <== NOT EXECUTED a0017bf4: e12fff33 blx r3 <== NOT EXECUTED a0017bf8: e8bd8010 pop {r4, pc} =============================================================================== a0012bb4 <_CORE_message_queue_Seize>: void *buffer, size_t *size_p, bool wait, Watchdog_Interval timeout ) { a0012bb4: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} a0012bb8: e1a04000 mov r4, r0 ISR_Level level; CORE_message_queue_Buffer_control *the_message; Thread_Control *executing; executing = _Thread_Executing; a0012bbc: e59f0110 ldr r0, [pc, #272] ; a0012cd4 <_CORE_message_queue_Seize+0x120> executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL; a0012bc0: e3a05000 mov r5, #0 void *buffer, size_t *size_p, bool wait, Watchdog_Interval timeout ) { a0012bc4: e59dc020 ldr ip, [sp, #32] ISR_Level level; CORE_message_queue_Buffer_control *the_message; Thread_Control *executing; executing = _Thread_Executing; a0012bc8: e5900008 ldr r0, [r0, #8] void *buffer, size_t *size_p, bool wait, Watchdog_Interval timeout ) { a0012bcc: e5dd801c ldrb r8, [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; a0012bd0: e5805034 str r5, [r0, #52] ; 0x34 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0012bd4: e10f6000 mrs r6, CPSR a0012bd8: e3865080 orr r5, r6, #128 ; 0x80 a0012bdc: e129f005 msr CPSR_fc, r5 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a0012be0: e1a07004 mov r7, r4 a0012be4: e5b75050 ldr r5, [r7, #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 ); a0012be8: e284a054 add sl, r4, #84 ; 0x54 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) a0012bec: e155000a cmp r5, sl a0012bf0: 0a000025 beq a0012c8c <_CORE_message_queue_Seize+0xd8> Chain_Control *the_chain ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *old_first = head->next; Chain_Node *new_first = old_first->next; a0012bf4: e5951000 ldr r1, [r5] head->next = new_first; a0012bf8: e5841050 str r1, [r4, #80] ; 0x50 new_first->previous = head; a0012bfc: e5817004 str r7, [r1, #4] _ISR_Disable( level ); the_message = _CORE_message_queue_Get_pending_message( the_message_queue ); if ( the_message != NULL ) { the_message_queue->number_of_pending_messages -= 1; a0012c00: e5941048 ldr r1, [r4, #72] ; 0x48 a0012c04: e2411001 sub r1, r1, #1 a0012c08: e5841048 str r1, [r4, #72] ; 0x48 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0012c0c: e129f006 msr CPSR_fc, r6 _ISR_Enable( level ); *size_p = the_message->Contents.size; a0012c10: e595100c ldr r1, [r5, #12] _Thread_Executing->Wait.count = a0012c14: e5950008 ldr r0, [r5, #8] _CORE_message_queue_Get_message_priority( the_message ); _CORE_message_queue_Copy_buffer( the_message->Contents.buffer, a0012c18: 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; a0012c1c: e5831000 str r1, [r3] _Thread_Executing->Wait.count = a0012c20: e59f10ac ldr r1, [pc, #172] ; a0012cd4 <_CORE_message_queue_Seize+0x120> a0012c24: e5911008 ldr r1, [r1, #8] a0012c28: e5810024 str r0, [r1, #36] ; 0x24 const void *source, void *destination, size_t size ) { memcpy(destination, source, size); a0012c2c: e1a00002 mov r0, r2 a0012c30: e1a01006 mov r1, r6 a0012c34: e5932000 ldr r2, [r3] a0012c38: eb001e6b bl a001a5ec * 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 ); a0012c3c: e1a00004 mov r0, r4 a0012c40: eb000843 bl a0014d54 <_Thread_queue_Dequeue> if ( !the_thread ) { a0012c44: e2503000 subs r3, r0, #0 a0012c48: 1a000003 bne a0012c5c <_CORE_message_queue_Seize+0xa8> 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 ); a0012c4c: e2840068 add r0, r4, #104 ; 0x68 a0012c50: 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 ); } a0012c54: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr} a0012c58: eaffff79 b a0012a44 <_Chain_Append> CORE_message_queue_Buffer_control *the_message, int priority ) { #if defined(RTEMS_SCORE_COREMSG_ENABLE_MESSAGE_PRIORITY) the_message->priority = priority; a0012c5c: e5932024 ldr r2, [r3, #36] ; 0x24 <== NOT EXECUTED const void *source, void *destination, size_t size ) { memcpy(destination, source, size); a0012c60: 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; a0012c64: 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; a0012c68: e5932030 ldr r2, [r3, #48] ; 0x30 <== NOT EXECUTED a0012c6c: e585200c str r2, [r5, #12] <== NOT EXECUTED const void *source, void *destination, size_t size ) { memcpy(destination, source, size); a0012c70: e593102c ldr r1, [r3, #44] ; 0x2c <== NOT EXECUTED a0012c74: eb001e5c bl a001a5ec <== NOT EXECUTED the_thread->Wait.return_argument_second.immutable_object, the_message->Contents.buffer, the_message->Contents.size ); _CORE_message_queue_Insert_message( a0012c78: e5952008 ldr r2, [r5, #8] <== NOT EXECUTED a0012c7c: e1a00004 mov r0, r4 <== NOT EXECUTED a0012c80: 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 ); } a0012c84: 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( a0012c88: ea001397 b a0017aec <_CORE_message_queue_Insert_message> <== NOT EXECUTED return; } #endif } if ( !wait ) { a0012c8c: e3580000 cmp r8, #0 a0012c90: 1a000003 bne a0012ca4 <_CORE_message_queue_Seize+0xf0> a0012c94: e129f006 msr CPSR_fc, r6 _ISR_Enable( level ); executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_NOWAIT; a0012c98: e3a03004 mov r3, #4 a0012c9c: 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 ); } a0012ca0: 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; a0012ca4: e3a05001 mov r5, #1 a0012ca8: 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; a0012cac: e5804044 str r4, [r0, #68] ; 0x44 executing->Wait.id = id; a0012cb0: e5801020 str r1, [r0, #32] executing->Wait.return_argument_second.mutable_object = buffer; a0012cb4: e580202c str r2, [r0, #44] ; 0x2c executing->Wait.return_argument = size_p; a0012cb8: e5803028 str r3, [r0, #40] ; 0x28 a0012cbc: 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 ); a0012cc0: e59f2010 ldr r2, [pc, #16] ; a0012cd8 <_CORE_message_queue_Seize+0x124> a0012cc4: e1a00004 mov r0, r4 a0012cc8: e1a0100c mov r1, ip } a0012ccc: 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 ); a0012cd0: ea000876 b a0014eb0 <_Thread_queue_Enqueue_with_handler> =============================================================================== a0012cdc <_CORE_message_queue_Submit>: #endif CORE_message_queue_Submit_types submit_type, bool wait, Watchdog_Interval timeout ) { a0012cdc: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} a0012ce0: e1a09003 mov r9, r3 CORE_message_queue_Buffer_control *the_message; Thread_Control *the_thread; if ( size > the_message_queue->maximum_message_size ) { a0012ce4: e590304c ldr r3, [r0, #76] ; 0x4c #endif CORE_message_queue_Submit_types submit_type, bool wait, Watchdog_Interval timeout ) { a0012ce8: e1a04000 mov r4, r0 a0012cec: e1a08001 mov r8, r1 CORE_message_queue_Buffer_control *the_message; Thread_Control *the_thread; if ( size > the_message_queue->maximum_message_size ) { a0012cf0: e1520003 cmp r2, r3 #endif CORE_message_queue_Submit_types submit_type, bool wait, Watchdog_Interval timeout ) { a0012cf4: e1a05002 mov r5, r2 a0012cf8: e59d6028 ldr r6, [sp, #40] ; 0x28 a0012cfc: 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 ) { a0012d00: 8a000036 bhi a0012de0 <_CORE_message_queue_Submit+0x104> } /* * Is there a thread currently waiting on this message queue? */ if ( the_message_queue->number_of_pending_messages == 0 ) { a0012d04: e590a048 ldr sl, [r0, #72] ; 0x48 a0012d08: e35a0000 cmp sl, #0 a0012d0c: 1a00000b bne a0012d40 <_CORE_message_queue_Submit+0x64> the_thread = _Thread_queue_Dequeue( &the_message_queue->Wait_queue ); a0012d10: eb00080f bl a0014d54 <_Thread_queue_Dequeue> if ( the_thread ) { a0012d14: e2507000 subs r7, r0, #0 a0012d18: 0a000008 beq a0012d40 <_CORE_message_queue_Submit+0x64> a0012d1c: e597002c ldr r0, [r7, #44] ; 0x2c a0012d20: e1a01008 mov r1, r8 a0012d24: e1a02005 mov r2, r5 a0012d28: eb001e2f bl a001a5ec _CORE_message_queue_Copy_buffer( buffer, the_thread->Wait.return_argument_second.mutable_object, size ); *(size_t *) the_thread->Wait.return_argument = size; a0012d2c: 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; a0012d30: 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; a0012d34: e5835000 str r5, [r3] the_thread->Wait.count = (uint32_t) submit_type; a0012d38: 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; a0012d3c: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} RTEMS_INLINE_ROUTINE CORE_message_queue_Buffer_control * _CORE_message_queue_Allocate_message_buffer ( CORE_message_queue_Control *the_message_queue ) { return (CORE_message_queue_Buffer_control *) a0012d40: e2840068 add r0, r4, #104 ; 0x68 a0012d44: ebffff49 bl a0012a70 <_Chain_Get> * No one waiting on the message queue at this time, so attempt to * queue the message up for a future receive. */ the_message = _CORE_message_queue_Allocate_message_buffer( the_message_queue ); if ( the_message ) { a0012d48: e2507000 subs r7, r0, #0 a0012d4c: 0a00000b beq a0012d80 <_CORE_message_queue_Submit+0xa4> const void *source, void *destination, size_t size ) { memcpy(destination, source, size); a0012d50: e1a01008 mov r1, r8 a0012d54: e1a02005 mov r2, r5 a0012d58: e2870010 add r0, r7, #16 a0012d5c: eb001e22 bl a001a5ec size ); the_message->Contents.size = size; _CORE_message_queue_Set_message_priority( the_message, submit_type ); _CORE_message_queue_Insert_message( a0012d60: e1a00004 mov r0, r4 _CORE_message_queue_Copy_buffer( buffer, the_message->Contents.buffer, size ); the_message->Contents.size = size; a0012d64: 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; a0012d68: e5876008 str r6, [r7, #8] _CORE_message_queue_Set_message_priority( the_message, submit_type ); _CORE_message_queue_Insert_message( a0012d6c: e1a01007 mov r1, r7 a0012d70: e1a02006 mov r2, r6 a0012d74: eb00135c bl a0017aec <_CORE_message_queue_Insert_message> the_message_queue, the_message, submit_type ); return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL; a0012d78: e3a00000 mov r0, #0 a0012d7c: 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 ) { a0012d80: e35b0000 cmp fp, #0 <== NOT EXECUTED a0012d84: 0a000017 beq a0012de8 <_CORE_message_queue_Submit+0x10c> <== 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() ) { a0012d88: e59f3068 ldr r3, [pc, #104] ; a0012df8 <_CORE_message_queue_Submit+0x11c><== NOT EXECUTED a0012d8c: e5932000 ldr r2, [r3] <== NOT EXECUTED a0012d90: e3520000 cmp r2, #0 <== NOT EXECUTED a0012d94: 1a000015 bne a0012df0 <_CORE_message_queue_Submit+0x114> <== 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; a0012d98: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0012d9c: e10f2000 mrs r2, CPSR <== NOT EXECUTED a0012da0: e3821080 orr r1, r2, #128 ; 0x80 <== NOT EXECUTED a0012da4: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED a0012da8: e3a01001 mov r1, #1 <== NOT EXECUTED a0012dac: 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; a0012db0: e5834044 str r4, [r3, #68] ; 0x44 <== NOT EXECUTED executing->Wait.id = id; a0012db4: e5839020 str r9, [r3, #32] <== NOT EXECUTED executing->Wait.return_argument_second.immutable_object = buffer; a0012db8: e583802c str r8, [r3, #44] ; 0x2c <== NOT EXECUTED executing->Wait.option = (uint32_t) size; a0012dbc: e5835030 str r5, [r3, #48] ; 0x30 <== NOT EXECUTED executing->Wait.count = submit_type; a0012dc0: e5836024 str r6, [r3, #36] ; 0x24 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0012dc4: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED _ISR_Enable( level ); _Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout ); a0012dc8: e59f202c ldr r2, [pc, #44] ; a0012dfc <_CORE_message_queue_Submit+0x120><== NOT EXECUTED a0012dcc: e1a00004 mov r0, r4 <== NOT EXECUTED a0012dd0: e59d1030 ldr r1, [sp, #48] ; 0x30 <== NOT EXECUTED a0012dd4: eb000835 bl a0014eb0 <_Thread_queue_Enqueue_with_handler> <== NOT EXECUTED } return CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT; a0012dd8: e3a00007 mov r0, #7 <== NOT EXECUTED a0012ddc: 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; a0012de0: e3a00001 mov r0, #1 <== NOT EXECUTED a0012de4: 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; a0012de8: e3a00002 mov r0, #2 <== NOT EXECUTED a0012dec: 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; a0012df0: e3a00003 mov r0, #3 <== NOT EXECUTED _Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout ); } return CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT; #endif } a0012df4: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED =============================================================================== a000adf0 <_CORE_mutex_Surrender>: #else Objects_Id id __attribute__((unused)), CORE_mutex_API_mp_support_callout api_mutex_mp_support __attribute__((unused)) #endif ) { a000adf0: e92d4030 push {r4, r5, lr} a000adf4: 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 ) { a000adf8: e5d43044 ldrb r3, [r4, #68] ; 0x44 ) { Thread_Control *the_thread; Thread_Control *holder; holder = the_mutex->holder; a000adfc: 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 ) { a000ae00: e3530000 cmp r3, #0 a000ae04: 0a000004 beq a000ae1c <_CORE_mutex_Surrender+0x2c> RTEMS_INLINE_ROUTINE bool _Thread_Is_executing ( const Thread_Control *the_thread ) { return ( the_thread == _Thread_Executing ); a000ae08: e59f30f0 ldr r3, [pc, #240] ; a000af00 <_CORE_mutex_Surrender+0x110> if ( !_Thread_Is_executing( holder ) ) a000ae0c: e5933008 ldr r3, [r3, #8] a000ae10: e1500003 cmp r0, r3 return CORE_MUTEX_STATUS_NOT_OWNER_OF_RESOURCE; a000ae14: 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 ) ) a000ae18: 1a000036 bne a000aef8 <_CORE_mutex_Surrender+0x108> return CORE_MUTEX_STATUS_NOT_OWNER_OF_RESOURCE; } /* XXX already unlocked -- not right status */ if ( !the_mutex->nest_count ) a000ae1c: e5945054 ldr r5, [r4, #84] ; 0x54 a000ae20: e3550000 cmp r5, #0 a000ae24: 0a000033 beq a000aef8 <_CORE_mutex_Surrender+0x108> return CORE_MUTEX_STATUS_SUCCESSFUL; the_mutex->nest_count--; a000ae28: e2455001 sub r5, r5, #1 if ( the_mutex->nest_count != 0 ) { a000ae2c: e3550000 cmp r5, #0 /* XXX already unlocked -- not right status */ if ( !the_mutex->nest_count ) return CORE_MUTEX_STATUS_SUCCESSFUL; the_mutex->nest_count--; a000ae30: 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; a000ae34: 13a05000 movne r5, #0 if ( !the_mutex->nest_count ) return CORE_MUTEX_STATUS_SUCCESSFUL; the_mutex->nest_count--; if ( the_mutex->nest_count != 0 ) { a000ae38: 1a00002e bne a000aef8 <_CORE_mutex_Surrender+0x108> a000ae3c: 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 ) || a000ae40: e3530002 cmp r3, #2 a000ae44: 0a000001 beq a000ae50 <_CORE_mutex_Surrender+0x60> a000ae48: e3530003 cmp r3, #3 a000ae4c: 1a00000a bne a000ae7c <_CORE_mutex_Surrender+0x8c> _CORE_mutex_Pop_priority( the_mutex, holder ); if ( pop_status != CORE_MUTEX_STATUS_SUCCESSFUL ) return pop_status; holder->resource_count--; a000ae50: e590301c ldr r3, [r0, #28] a000ae54: 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 && a000ae58: e3530000 cmp r3, #0 _CORE_mutex_Pop_priority( the_mutex, holder ); if ( pop_status != CORE_MUTEX_STATUS_SUCCESSFUL ) return pop_status; holder->resource_count--; a000ae5c: 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 && a000ae60: 1a000005 bne a000ae7c <_CORE_mutex_Surrender+0x8c> holder->real_priority != holder->current_priority ) { a000ae64: 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 && a000ae68: e5903014 ldr r3, [r0, #20] a000ae6c: e1510003 cmp r1, r3 a000ae70: 0a000001 beq a000ae7c <_CORE_mutex_Surrender+0x8c> holder->real_priority != holder->current_priority ) { _Thread_Change_priority( holder, holder->real_priority, true ); a000ae74: e3a02001 mov r2, #1 a000ae78: eb00053f bl a000c37c <_Thread_Change_priority> } } the_mutex->holder = NULL; a000ae7c: e3a05000 mov r5, #0 a000ae80: e584505c str r5, [r4, #92] ; 0x5c the_mutex->holder_id = 0; a000ae84: 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 ) ) ) { a000ae88: e1a00004 mov r0, r4 a000ae8c: eb000727 bl a000cb30 <_Thread_queue_Dequeue> a000ae90: e3a02001 mov r2, #1 a000ae94: e2503000 subs r3, r0, #0 } break; } } } else the_mutex->lock = CORE_MUTEX_UNLOCKED; a000ae98: 05842050 streq r2, [r4, #80] ; 0x50 return CORE_MUTEX_STATUS_SUCCESSFUL; a000ae9c: 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 ) ) ) { a000aea0: 0a000014 beq a000aef8 <_CORE_mutex_Surrender+0x108> } else #endif { the_mutex->holder = the_thread; the_mutex->holder_id = the_thread->Object.id; a000aea4: e5931008 ldr r1, [r3, #8] the_mutex->nest_count = 1; a000aea8: e5842054 str r2, [r4, #84] ; 0x54 switch ( the_mutex->Attributes.discipline ) { a000aeac: e5942048 ldr r2, [r4, #72] ; 0x48 } else #endif { the_mutex->holder = the_thread; a000aeb0: e584305c str r3, [r4, #92] ; 0x5c the_mutex->holder_id = the_thread->Object.id; a000aeb4: e5841060 str r1, [r4, #96] ; 0x60 the_mutex->nest_count = 1; switch ( the_mutex->Attributes.discipline ) { a000aeb8: 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++; a000aebc: 0593201c ldreq r2, [r3, #28] a000aec0: 02822001 addeq r2, r2, #1 a000aec4: 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 ) { a000aec8: 0a00000a beq a000aef8 <_CORE_mutex_Surrender+0x108> a000aecc: e3520003 cmp r2, #3 a000aed0: 1a000008 bne a000aef8 <_CORE_mutex_Surrender+0x108> _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++; a000aed4: e593201c ldr r2, [r3, #28] <== NOT EXECUTED if (the_mutex->Attributes.priority_ceiling < a000aed8: 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++; a000aedc: e2822001 add r2, r2, #1 <== NOT EXECUTED a000aee0: e583201c str r2, [r3, #28] <== NOT EXECUTED if (the_mutex->Attributes.priority_ceiling < a000aee4: e5933014 ldr r3, [r3, #20] <== NOT EXECUTED a000aee8: e1510003 cmp r1, r3 <== NOT EXECUTED a000aeec: 2a000001 bcs a000aef8 <_CORE_mutex_Surrender+0x108> <== NOT EXECUTED the_thread->current_priority){ _Thread_Change_priority( a000aef0: e1a02005 mov r2, r5 <== NOT EXECUTED a000aef4: eb000520 bl a000c37c <_Thread_Change_priority> <== NOT EXECUTED } } else the_mutex->lock = CORE_MUTEX_UNLOCKED; return CORE_MUTEX_STATUS_SUCCESSFUL; } a000aef8: e1a00005 mov r0, r5 a000aefc: e8bd8030 pop {r4, r5, pc} =============================================================================== a000b7bc <_CORE_spinlock_Release>: uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000b7bc: e10f3000 mrs r3, CPSR a000b7c0: e3832080 orr r2, r3, #128 ; 0x80 a000b7c4: e129f002 msr CPSR_fc, r2 _ISR_Disable( level ); /* * It must locked before it can be unlocked. */ if ( the_spinlock->lock == CORE_SPINLOCK_UNLOCKED ) { a000b7c8: e5902004 ldr r2, [r0, #4] a000b7cc: e3520000 cmp r2, #0 a000b7d0: 1a000002 bne a000b7e0 <_CORE_spinlock_Release+0x24> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000b7d4: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED _ISR_Enable( level ); return CORE_SPINLOCK_NOT_LOCKED; a000b7d8: e3a00006 mov r0, #6 <== NOT EXECUTED a000b7dc: 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 ) { a000b7e0: e59f2040 ldr r2, [pc, #64] ; a000b828 <_CORE_spinlock_Release+0x6c> a000b7e4: e590100c ldr r1, [r0, #12] a000b7e8: e5922008 ldr r2, [r2, #8] a000b7ec: e5922008 ldr r2, [r2, #8] a000b7f0: e1510002 cmp r1, r2 a000b7f4: 0a000002 beq a000b804 <_CORE_spinlock_Release+0x48> a000b7f8: e129f003 msr CPSR_fc, r3 _ISR_Enable( level ); return CORE_SPINLOCK_NOT_HOLDER; a000b7fc: e3a00002 mov r0, #2 a000b800: e12fff1e bx lr } /* * Let it be unlocked. */ the_spinlock->users -= 1; a000b804: e5902008 ldr r2, [r0, #8] <== NOT EXECUTED a000b808: e2422001 sub r2, r2, #1 <== NOT EXECUTED a000b80c: e5802008 str r2, [r0, #8] <== NOT EXECUTED the_spinlock->lock = CORE_SPINLOCK_UNLOCKED; a000b810: e3a02000 mov r2, #0 <== NOT EXECUTED a000b814: e5802004 str r2, [r0, #4] <== NOT EXECUTED the_spinlock->holder = 0; a000b818: e580200c str r2, [r0, #12] <== NOT EXECUTED a000b81c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED _ISR_Enable( level ); return CORE_SPINLOCK_SUCCESSFUL; a000b820: e3a00000 mov r0, #0 <== NOT EXECUTED } a000b824: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000b82c <_CORE_spinlock_Wait>: CORE_spinlock_Status _CORE_spinlock_Wait( CORE_spinlock_Control *the_spinlock, bool wait, Watchdog_Interval timeout ) { a000b82c: e92d4070 push {r4, r5, r6, lr} a000b830: e1a04000 mov r4, r0 a000b834: e20160ff and r6, r1, #255 ; 0xff uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000b838: e10f2000 mrs r2, CPSR a000b83c: e3823080 orr r3, r2, #128 ; 0x80 a000b840: e129f003 msr CPSR_fc, r3 a000b844: e1a03002 mov r3, 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) && a000b848: e5901004 ldr r1, [r0, #4] a000b84c: e3510001 cmp r1, #1 a000b850: 1a000008 bne a000b878 <_CORE_spinlock_Wait+0x4c> (the_spinlock->holder == _Thread_Executing->Object.id) ) { a000b854: e59f10a0 ldr r1, [pc, #160] ; a000b8fc <_CORE_spinlock_Wait+0xd0> a000b858: e590000c ldr r0, [r0, #12] a000b85c: e5911008 ldr r1, [r1, #8] #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) && a000b860: e5911008 ldr r1, [r1, #8] a000b864: e1500001 cmp r0, r1 a000b868: 1a000002 bne a000b878 <_CORE_spinlock_Wait+0x4c> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000b86c: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED (the_spinlock->holder == _Thread_Executing->Object.id) ) { _ISR_Enable( level ); return CORE_SPINLOCK_HOLDER_RELOCKING; a000b870: e3a00001 mov r0, #1 <== NOT EXECUTED a000b874: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED } the_spinlock->users += 1; a000b878: e5942008 ldr r2, [r4, #8] * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000b87c: e59f507c ldr r5, [pc, #124] ; a000b900 <_CORE_spinlock_Wait+0xd4> a000b880: e2822001 add r2, r2, #1 a000b884: e5842008 str r2, [r4, #8] for ( ;; ) { if ( the_spinlock->lock == CORE_SPINLOCK_UNLOCKED ) { a000b888: e5942004 ldr r2, [r4, #4] a000b88c: e3520000 cmp r2, #0 a000b890: 1a000008 bne a000b8b8 <_CORE_spinlock_Wait+0x8c> the_spinlock->lock = CORE_SPINLOCK_LOCKED; a000b894: e3a02001 mov r2, #1 a000b898: e5842004 str r2, [r4, #4] the_spinlock->holder = _Thread_Executing->Object.id; a000b89c: e59f2058 ldr r2, [pc, #88] ; a000b8fc <_CORE_spinlock_Wait+0xd0> a000b8a0: e5922008 ldr r2, [r2, #8] a000b8a4: e5922008 ldr r2, [r2, #8] a000b8a8: e584200c str r2, [r4, #12] a000b8ac: e129f003 msr CPSR_fc, r3 _ISR_Enable( level ); return CORE_SPINLOCK_SUCCESSFUL; a000b8b0: e3a00000 mov r0, #0 a000b8b4: e8bd8070 pop {r4, r5, r6, pc} } /* * Spinlock is unavailable. If not willing to wait, return. */ if ( !wait ) { a000b8b8: e3560000 cmp r6, #0 a000b8bc: 1a000005 bne a000b8d8 <_CORE_spinlock_Wait+0xac> the_spinlock->users -= 1; a000b8c0: e5942008 ldr r2, [r4, #8] a000b8c4: e2422001 sub r2, r2, #1 a000b8c8: e5842008 str r2, [r4, #8] a000b8cc: e129f003 msr CPSR_fc, r3 _ISR_Enable( level ); return CORE_SPINLOCK_UNAVAILABLE; a000b8d0: e3a00005 mov r0, #5 a000b8d4: e8bd8070 pop {r4, r5, r6, pc} a000b8d8: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED */ _ISR_Enable( level ); /* An ISR could occur here */ _Thread_Enable_dispatch(); a000b8dc: eb0005fb bl a000d0d0 <_Thread_Enable_dispatch> <== NOT EXECUTED a000b8e0: e5953000 ldr r3, [r5] <== NOT EXECUTED ++level; a000b8e4: e2833001 add r3, r3, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a000b8e8: e5853000 str r3, [r5] <== NOT EXECUTED uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000b8ec: e10f3000 mrs r3, CPSR <== NOT EXECUTED a000b8f0: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED a000b8f4: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED /* Reenter the critical sections so we can attempt the lock again. */ _Thread_Disable_dispatch(); _ISR_Disable( level ); } a000b8f8: eaffffe2 b a000b888 <_CORE_spinlock_Wait+0x5c> <== NOT EXECUTED =============================================================================== a000b31c <_Chain_Get_with_empty_check>: bool _Chain_Get_with_empty_check( Chain_Control *chain, Chain_Node **node ) { a000b31c: e92d4010 push {r4, lr} <== NOT EXECUTED uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000b320: e10f4000 mrs r4, CPSR <== NOT EXECUTED a000b324: e3843080 orr r3, r4, #128 ; 0x80 <== NOT EXECUTED a000b328: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED ) { bool is_empty_now = true; Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); Chain_Node *old_first = head->next; a000b32c: e5902000 ldr r2, [r0] <== NOT EXECUTED Chain_Node **the_node ) { bool is_empty_now = true; Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); a000b330: e280c004 add ip, r0, #4 <== NOT EXECUTED Chain_Node *old_first = head->next; if ( old_first != tail ) { a000b334: e152000c cmp r2, ip <== NOT EXECUTED *the_node = old_first; is_empty_now = new_first == tail; } else *the_node = NULL; a000b338: 03a03000 moveq r3, #0 <== NOT EXECUTED a000b33c: 05813000 streq r3, [r1] <== NOT EXECUTED RTEMS_INLINE_ROUTINE bool _Chain_Get_with_empty_check_unprotected( Chain_Control *the_chain, Chain_Node **the_node ) { bool is_empty_now = true; a000b340: 03a00001 moveq r0, #1 <== NOT EXECUTED Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); Chain_Node *old_first = head->next; if ( old_first != tail ) { a000b344: 0a000006 beq a000b364 <_Chain_Get_with_empty_check+0x48> <== NOT EXECUTED Chain_Node *new_first = old_first->next; a000b348: e5923000 ldr r3, [r2] <== NOT EXECUTED head->next = new_first; a000b34c: e5803000 str r3, [r0] <== NOT EXECUTED new_first->previous = head; a000b350: e5830004 str r0, [r3, #4] <== NOT EXECUTED *the_node = old_first; is_empty_now = new_first == tail; a000b354: e06c3003 rsb r3, ip, r3 <== NOT EXECUTED a000b358: e2730000 rsbs r0, r3, #0 <== NOT EXECUTED Chain_Node *new_first = old_first->next; head->next = new_first; new_first->previous = head; *the_node = old_first; a000b35c: e5812000 str r2, [r1] <== NOT EXECUTED is_empty_now = new_first == tail; a000b360: e0a00003 adc r0, r0, r3 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000b364: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED _ISR_Disable( level ); is_empty_now = _Chain_Get_with_empty_check_unprotected( chain, node ); _ISR_Enable( level ); return is_empty_now; } a000b368: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a0009bd8 <_Event_Seize>: Thread_Control *executing, Event_Control *event, Thread_blocking_operation_States *sync_state, States_Control wait_state ) { a0009bd8: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} a0009bdc: e59d401c ldr r4, [sp, #28] rtems_event_set seized_events; rtems_event_set pending_events; ISR_Level level; Thread_blocking_operation_States current_sync_state; executing->Wait.return_code = RTEMS_SUCCESSFUL; a0009be0: e3a0c000 mov ip, #0 Thread_Control *executing, Event_Control *event, Thread_blocking_operation_States *sync_state, States_Control wait_state ) { a0009be4: e59da020 ldr sl, [sp, #32] a0009be8: e59d5024 ldr r5, [sp, #36] ; 0x24 a0009bec: e59d6028 ldr r6, [sp, #40] ; 0x28 rtems_event_set seized_events; rtems_event_set pending_events; ISR_Level level; Thread_blocking_operation_States current_sync_state; executing->Wait.return_code = RTEMS_SUCCESSFUL; a0009bf0: e584c034 str ip, [r4, #52] ; 0x34 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0009bf4: e10f7000 mrs r7, CPSR a0009bf8: e387c080 orr ip, r7, #128 ; 0x80 a0009bfc: e129f00c msr CPSR_fc, ip _ISR_Disable( level ); pending_events = event->pending_events; a0009c00: e59a8000 ldr r8, [sl] seized_events = _Event_sets_Get( pending_events, event_in ); if ( !_Event_sets_Is_empty( seized_events ) && a0009c04: e010c008 ands ip, r0, r8 a0009c08: 0a000007 beq a0009c2c <_Event_Seize+0x54> a0009c0c: e15c0000 cmp ip, r0 a0009c10: 0a000001 beq a0009c1c <_Event_Seize+0x44> (seized_events == event_in || _Options_Is_any( option_set )) ) { a0009c14: e3110002 tst r1, #2 <== NOT EXECUTED a0009c18: 0a000003 beq a0009c2c <_Event_Seize+0x54> <== 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) ); a0009c1c: e1c8800c bic r8, r8, ip event->pending_events = a0009c20: e58a8000 str r8, [sl] static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0009c24: e129f007 msr CPSR_fc, r7 a0009c28: ea000004 b a0009c40 <_Event_Seize+0x68> _ISR_Enable( level ); *event_out = seized_events; return; } if ( _Options_Is_no_wait( option_set ) ) { a0009c2c: e3110001 tst r1, #1 a0009c30: 0a000004 beq a0009c48 <_Event_Seize+0x70> a0009c34: e129f007 msr CPSR_fc, r7 _ISR_Enable( level ); executing->Wait.return_code = RTEMS_UNSATISFIED; a0009c38: e3a0200d mov r2, #13 a0009c3c: e5842034 str r2, [r4, #52] ; 0x34 *event_out = seized_events; a0009c40: e583c000 str ip, [r3] return; a0009c44: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} * NOTE: Since interrupts are disabled, this isn't that much of an * issue but better safe than sorry. */ executing->Wait.option = option_set; executing->Wait.count = event_in; executing->Wait.return_argument = event_out; a0009c48: e5843028 str r3, [r4, #40] ; 0x28 *sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; a0009c4c: e3a03001 mov r3, #1 * 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 = option_set; a0009c50: e5841030 str r1, [r4, #48] ; 0x30 executing->Wait.count = event_in; a0009c54: e5840024 str r0, [r4, #36] ; 0x24 executing->Wait.return_argument = event_out; *sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; a0009c58: e5853000 str r3, [r5] a0009c5c: e129f007 msr CPSR_fc, r7 _ISR_Enable( level ); if ( ticks ) { a0009c60: e3520000 cmp r2, #0 a0009c64: 0a00000a beq a0009c94 <_Event_Seize+0xbc> Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a0009c68: e3a01000 mov r1, #0 _Watchdog_Initialize( a0009c6c: e5943008 ldr r3, [r4, #8] a0009c70: e5841050 str r1, [r4, #80] ; 0x50 the_watchdog->routine = routine; a0009c74: e59f1058 ldr r1, [pc, #88] ; a0009cd4 <_Event_Seize+0xfc> the_watchdog->id = id; a0009c78: e5843068 str r3, [r4, #104] ; 0x68 the_watchdog->user_data = user_data; a0009c7c: e584506c str r5, [r4, #108] ; 0x6c Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a0009c80: e5841064 str r1, [r4, #100] ; 0x64 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a0009c84: e5842054 str r2, [r4, #84] ; 0x54 _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a0009c88: e59f0048 ldr r0, [pc, #72] ; a0009cd8 <_Event_Seize+0x100> a0009c8c: e2841048 add r1, r4, #72 ; 0x48 a0009c90: eb000db6 bl a000d370 <_Watchdog_Insert> sync_state ); _Watchdog_Insert_ticks( &executing->Timer, ticks ); } _Thread_Set_state( executing, wait_state ); a0009c94: e1a00004 mov r0, r4 a0009c98: e1a01006 mov r1, r6 a0009c9c: eb000ce0 bl a000d024 <_Thread_Set_state> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0009ca0: e10f2000 mrs r2, CPSR a0009ca4: e3823080 orr r3, r2, #128 ; 0x80 a0009ca8: e129f003 msr CPSR_fc, r3 _ISR_Disable( level ); current_sync_state = *sync_state; a0009cac: e5950000 ldr r0, [r5] *sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; a0009cb0: e3a03000 mov r3, #0 a0009cb4: e5853000 str r3, [r5] if ( current_sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) { a0009cb8: e3500001 cmp r0, #1 a0009cbc: 1a000001 bne a0009cc8 <_Event_Seize+0xf0> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0009cc0: e129f002 msr CPSR_fc, r2 a0009cc4: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} * The blocking thread was satisfied by an ISR or timed out. * * WARNING! Entering with interrupts disabled and returning with interrupts * enabled! */ _Thread_blocking_operation_Cancel( current_sync_state, executing, level ); a0009cc8: e1a01004 mov r1, r4 <== NOT EXECUTED } a0009ccc: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr} <== NOT EXECUTED * The blocking thread was satisfied by an ISR or timed out. * * WARNING! Entering with interrupts disabled and returning with interrupts * enabled! */ _Thread_blocking_operation_Cancel( current_sync_state, executing, level ); a0009cd0: ea000996 b a000c330 <_Thread_blocking_operation_Cancel> <== NOT EXECUTED =============================================================================== a0009d28 <_Event_Surrender>: rtems_event_set event_in, Event_Control *event, Thread_blocking_operation_States *sync_state, States_Control wait_state ) { a0009d28: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} a0009d2c: e59d801c ldr r8, [sp, #28] rtems_event_set pending_events; rtems_event_set event_condition; rtems_event_set seized_events; rtems_option option_set; option_set = the_thread->Wait.option; a0009d30: e5906030 ldr r6, [r0, #48] ; 0x30 rtems_event_set event_in, Event_Control *event, Thread_blocking_operation_States *sync_state, States_Control wait_state ) { a0009d34: e1a04000 mov r4, r0 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0009d38: e10f0000 mrs r0, CPSR a0009d3c: e380c080 orr ip, r0, #128 ; 0x80 a0009d40: e129f00c msr CPSR_fc, ip RTEMS_INLINE_ROUTINE void _Event_sets_Post( rtems_event_set the_new_events, rtems_event_set *the_event_set ) { *the_event_set |= the_new_events; a0009d44: e592c000 ldr ip, [r2] a0009d48: e181100c orr r1, r1, ip a0009d4c: e5821000 str r1, [r2] option_set = the_thread->Wait.option; _ISR_Disable( level ); _Event_sets_Post( event_in, &event->pending_events ); pending_events = event->pending_events; event_condition = the_thread->Wait.count; a0009d50: e5945024 ldr r5, [r4, #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 ) ) { a0009d54: e011c005 ands ip, r1, r5 a0009d58: 0a000035 beq a0009e34 <_Event_Surrender+0x10c> /* * 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() && a0009d5c: e59f70d8 ldr r7, [pc, #216] ; a0009e3c <_Event_Surrender+0x114> a0009d60: e597a000 ldr sl, [r7] a0009d64: e35a0000 cmp sl, #0 a0009d68: 0a000013 beq a0009dbc <_Event_Surrender+0x94> a0009d6c: e5977008 ldr r7, [r7, #8] <== NOT EXECUTED a0009d70: e1540007 cmp r4, r7 <== NOT EXECUTED a0009d74: 1a000010 bne a0009dbc <_Event_Surrender+0x94> <== NOT EXECUTED _Thread_Is_executing( the_thread ) && ((*sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) || a0009d78: e5937000 ldr r7, [r3] <== NOT EXECUTED a0009d7c: e2477001 sub r7, r7, #1 <== 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 ) && a0009d80: e3570001 cmp r7, #1 <== NOT EXECUTED a0009d84: 8a00000c bhi a0009dbc <_Event_Surrender+0x94> <== NOT EXECUTED ((*sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) || (*sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) { if ( seized_events == event_condition || _Options_Is_any(option_set) ) { a0009d88: e15c0005 cmp ip, r5 <== NOT EXECUTED a0009d8c: 0a000001 beq a0009d98 <_Event_Surrender+0x70> <== NOT EXECUTED a0009d90: e3160002 tst r6, #2 <== NOT EXECUTED a0009d94: 0a000026 beq a0009e34 <_Event_Surrender+0x10c> <== 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) ); a0009d98: e1c1100c bic r1, r1, ip <== NOT EXECUTED event->pending_events = _Event_sets_Clear( a0009d9c: e5821000 str r1, [r2] <== NOT EXECUTED pending_events, seized_events ); the_thread->Wait.count = 0; a0009da0: e3a02000 mov r2, #0 <== NOT EXECUTED a0009da4: e5842024 str r2, [r4, #36] ; 0x24 <== NOT EXECUTED *(rtems_event_set *)the_thread->Wait.return_argument = seized_events; a0009da8: e5942028 ldr r2, [r4, #40] ; 0x28 <== NOT EXECUTED a0009dac: e582c000 str ip, [r2] <== NOT EXECUTED *sync_state = THREAD_BLOCKING_OPERATION_SATISFIED; a0009db0: e3a02003 mov r2, #3 <== NOT EXECUTED a0009db4: e5832000 str r2, [r3] <== NOT EXECUTED a0009db8: ea00001d b a0009e34 <_Event_Surrender+0x10c> <== NOT EXECUTED RTEMS_INLINE_ROUTINE bool _States_Are_set ( States_Control the_states, States_Control mask ) { return ( (the_states & mask) != STATES_READY); a0009dbc: e5943010 ldr r3, [r4, #16] } /* * Otherwise, this is a normal send to another thread */ if ( _States_Are_set( the_thread->current_state, wait_state ) ) { a0009dc0: e1180003 tst r8, r3 a0009dc4: 0a00001a beq a0009e34 <_Event_Surrender+0x10c> if ( seized_events == event_condition || _Options_Is_any( option_set ) ) { a0009dc8: e15c0005 cmp ip, r5 a0009dcc: 0a000001 beq a0009dd8 <_Event_Surrender+0xb0> a0009dd0: e3160002 tst r6, #2 <== NOT EXECUTED a0009dd4: 0a000016 beq a0009e34 <_Event_Surrender+0x10c> <== NOT EXECUTED a0009dd8: e1c1100c bic r1, r1, ip event->pending_events = _Event_sets_Clear( pending_events, seized_events ); the_thread->Wait.count = 0; a0009ddc: e3a03000 mov r3, #0 /* * Otherwise, this is a normal send to another thread */ if ( _States_Are_set( the_thread->current_state, wait_state ) ) { if ( seized_events == event_condition || _Options_Is_any( option_set ) ) { event->pending_events = _Event_sets_Clear( a0009de0: e5821000 str r1, [r2] pending_events, seized_events ); the_thread->Wait.count = 0; a0009de4: e5843024 str r3, [r4, #36] ; 0x24 *(rtems_event_set *)the_thread->Wait.return_argument = seized_events; a0009de8: e5943028 ldr r3, [r4, #40] ; 0x28 a0009dec: e583c000 str ip, [r3] static inline void arm_interrupt_flash( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0009df0: e10f3000 mrs r3, CPSR a0009df4: e129f000 msr CPSR_fc, r0 a0009df8: e129f003 msr CPSR_fc, r3 _ISR_Flash( level ); if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { a0009dfc: e5943050 ldr r3, [r4, #80] ; 0x50 a0009e00: e3530002 cmp r3, #2 a0009e04: 0a000001 beq a0009e10 <_Event_Surrender+0xe8> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0009e08: e129f000 msr CPSR_fc, r0 a0009e0c: ea000004 b a0009e24 <_Event_Surrender+0xfc> RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_REMOVE_IT; a0009e10: e3a03003 mov r3, #3 a0009e14: e5843050 str r3, [r4, #80] ; 0x50 a0009e18: e129f000 msr CPSR_fc, r0 _ISR_Enable( level ); _Thread_Unblock( the_thread ); } else { _Watchdog_Deactivate( &the_thread->Timer ); _ISR_Enable( level ); (void) _Watchdog_Remove( &the_thread->Timer ); a0009e1c: e2840048 add r0, r4, #72 ; 0x48 a0009e20: eb000da9 bl a000d4cc <_Watchdog_Remove> RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); a0009e24: e59f1014 ldr r1, [pc, #20] ; a0009e40 <_Event_Surrender+0x118> a0009e28: e1a00004 mov r0, r4 } return; } } _ISR_Enable( level ); } a0009e2c: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr} a0009e30: ea00098d b a000c46c <_Thread_Clear_state> a0009e34: e129f000 msr CPSR_fc, r0 a0009e38: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} =============================================================================== a0009e44 <_Event_Timeout>: void _Event_Timeout( Objects_Id id, void *arg ) { a0009e44: e92d4011 push {r0, r4, lr} <== NOT EXECUTED a0009e48: e1a04001 mov r4, r1 <== NOT EXECUTED ISR_Level level; Thread_blocking_operation_States *sync_state; sync_state = arg; the_thread = _Thread_Get( id, &location ); a0009e4c: e1a0100d mov r1, sp <== NOT EXECUTED a0009e50: eb000a6a bl a000c800 <_Thread_Get> <== NOT EXECUTED switch ( location ) { a0009e54: e59d3000 ldr r3, [sp] <== NOT EXECUTED a0009e58: e3530000 cmp r3, #0 <== NOT EXECUTED a0009e5c: 1a000014 bne a0009eb4 <_Event_Timeout+0x70> <== NOT EXECUTED uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0009e60: e10f2000 mrs r2, CPSR <== NOT EXECUTED a0009e64: e3821080 orr r1, r2, #128 ; 0x80 <== NOT EXECUTED a0009e68: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED _ISR_Enable( level ); return; } #endif the_thread->Wait.count = 0; a0009e6c: 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 ); a0009e70: e59f3040 ldr r3, [pc, #64] ; a0009eb8 <_Event_Timeout+0x74><== NOT EXECUTED if ( _Thread_Is_executing( the_thread ) ) { a0009e74: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED a0009e78: e1500003 cmp r0, r3 <== NOT EXECUTED a0009e7c: 1a000003 bne a0009e90 <_Event_Timeout+0x4c> <== NOT EXECUTED if ( *sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) a0009e80: e5943000 ldr r3, [r4] <== NOT EXECUTED a0009e84: e3530001 cmp r3, #1 <== NOT EXECUTED *sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT; a0009e88: 03a03002 moveq r3, #2 <== NOT EXECUTED a0009e8c: 05843000 streq r3, [r4] <== NOT EXECUTED } the_thread->Wait.return_code = RTEMS_TIMEOUT; a0009e90: e3a03006 mov r3, #6 <== NOT EXECUTED a0009e94: e5803034 str r3, [r0, #52] ; 0x34 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0009e98: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); a0009e9c: e59f1018 ldr r1, [pc, #24] ; a0009ebc <_Event_Timeout+0x78><== NOT EXECUTED a0009ea0: eb000971 bl a000c46c <_Thread_Clear_state> <== NOT EXECUTED * * This routine decrements the thread dispatch level. */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0009ea4: e59f3014 ldr r3, [pc, #20] ; a0009ec0 <_Event_Timeout+0x7c><== NOT EXECUTED a0009ea8: e5932000 ldr r2, [r3] <== NOT EXECUTED --level; a0009eac: e2422001 sub r2, r2, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a0009eb0: e5832000 str r2, [r3] <== NOT EXECUTED case OBJECTS_REMOTE: /* impossible */ #endif case OBJECTS_ERROR: break; } } a0009eb4: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED =============================================================================== a000f8d0 <_Heap_Allocate_aligned_with_boundary>: Heap_Control *heap, uintptr_t alloc_size, uintptr_t alignment, uintptr_t boundary ) { a000f8d0: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} a000f8d4: 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; a000f8d8: e5902010 ldr r2, [r0, #16] Heap_Control *heap, uintptr_t alloc_size, uintptr_t alignment, uintptr_t boundary ) { a000f8dc: e24dd01c sub sp, sp, #28 a000f8e0: 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 ) { a000f8e4: e2913004 adds r3, r1, #4 Heap_Control *heap, uintptr_t alloc_size, uintptr_t alignment, uintptr_t boundary ) { a000f8e8: e1a05000 mov r5, r0 a000f8ec: 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; a000f8f0: 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 ) { a000f8f4: e58d300c str r3, [sp, #12] a000f8f8: 2a00006a bcs a000faa8 <_Heap_Allocate_aligned_with_boundary+0x1d8> /* Integer overflow occured */ return NULL; } if ( boundary != 0 ) { a000f8fc: e35b0000 cmp fp, #0 a000f900: 0a000003 beq a000f914 <_Heap_Allocate_aligned_with_boundary+0x44> if ( boundary < alloc_size ) { a000f904: e15b0001 cmp fp, r1 <== NOT EXECUTED a000f908: 3a000066 bcc a000faa8 <_Heap_Allocate_aligned_with_boundary+0x1d8><== NOT EXECUTED return NULL; } if ( alignment == 0 ) { alignment = page_size; a000f90c: e3580000 cmp r8, #0 <== NOT EXECUTED a000f910: 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 a000f914: e59d2000 ldr r2, [sp] + HEAP_BLOCK_HEADER_SIZE + page_size - 1; uintptr_t alloc_end = block_end + HEAP_ALLOC_BONUS; a000f918: e2663004 rsb r3, r6, #4 return &heap->free_list; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap ) { return _Heap_Free_list_head(heap)->next; a000f91c: 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 a000f920: 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 ) { a000f924: 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 a000f928: e58d2014 str r2, [sp, #20] + HEAP_BLOCK_HEADER_SIZE + page_size - 1; uintptr_t alloc_end = block_end + HEAP_ALLOC_BONUS; a000f92c: 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 ) { a000f930: ea000048 b a000fa58 <_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 ) { a000f934: e59a4004 ldr r4, [sl, #4] a000f938: e59d200c ldr r2, [sp, #12] a000f93c: e1540002 cmp r4, r2 a000f940: 9a00003f bls a000fa44 <_Heap_Allocate_aligned_with_boundary+0x174> if ( alignment == 0 ) { a000f944: e3580000 cmp r8, #0 RTEMS_INLINE_ROUTINE uintptr_t _Heap_Alloc_area_of_block( const Heap_Block *block ) { return (uintptr_t) block + HEAP_BLOCK_HEADER_SIZE; a000f948: 028a4008 addeq r4, sl, #8 a000f94c: 0a00003d beq a000fa48 <_Heap_Allocate_aligned_with_boundary+0x178> a000f950: e28a2008 add r2, sl, #8 uintptr_t alignment, uintptr_t boundary ) { uintptr_t const page_size = heap->page_size; uintptr_t const min_block_size = heap->min_block_size; a000f954: e5953014 ldr r3, [r5, #20] a000f958: e58d2008 str r2, [sp, #8] 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; a000f95c: e59d2014 ldr r2, [sp, #20] uintptr_t alignment, uintptr_t boundary ) { uintptr_t const page_size = heap->page_size; uintptr_t const min_block_size = heap->min_block_size; a000f960: e58d3004 str r3, [sp, #4] - 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; a000f964: e3c44001 bic r4, r4, #1 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; a000f968: e0639002 rsb r9, r3, r2 uintptr_t alloc_end = block_end + HEAP_ALLOC_BONUS; uintptr_t alloc_begin = alloc_end - alloc_size; a000f96c: e59d3018 ldr r3, [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; a000f970: 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 a000f974: 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; a000f978: e0834004 add r4, r3, r4 RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down( uintptr_t value, uintptr_t alignment ) { return value - (value % alignment); a000f97c: e1a00004 mov r0, r4 a000f980: e1a01008 mov r1, r8 a000f984: eb002c1b bl a001a9f8 <__umodsi3> a000f988: 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 ) { a000f98c: e1540009 cmp r4, r9 a000f990: 9a000003 bls a000f9a4 <_Heap_Allocate_aligned_with_boundary+0xd4> a000f994: e1a00009 mov r0, r9 <== NOT EXECUTED a000f998: e1a01008 mov r1, r8 <== NOT EXECUTED a000f99c: eb002c15 bl a001a9f8 <__umodsi3> <== NOT EXECUTED a000f9a0: e0604009 rsb r4, r0, r9 <== NOT EXECUTED } alloc_end = alloc_begin + alloc_size; /* Ensure boundary constaint */ if ( boundary != 0 ) { a000f9a4: e35b0000 cmp fp, #0 a000f9a8: 0a000014 beq a000fa00 <_Heap_Allocate_aligned_with_boundary+0x130> uintptr_t const boundary_floor = alloc_begin_floor + alloc_size; a000f9ac: e59d2008 ldr r2, [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; a000f9b0: e0849006 add r9, r4, r6 <== NOT EXECUTED /* Ensure boundary constaint */ if ( boundary != 0 ) { uintptr_t const boundary_floor = alloc_begin_floor + alloc_size; a000f9b4: e0822006 add r2, r2, r6 <== NOT EXECUTED a000f9b8: e58d2010 str r2, [sp, #16] <== NOT EXECUTED a000f9bc: ea000008 b a000f9e4 <_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 ) { a000f9c0: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED a000f9c4: e1500003 cmp r0, r3 <== NOT EXECUTED a000f9c8: 3a00001d bcc a000fa44 <_Heap_Allocate_aligned_with_boundary+0x174><== NOT EXECUTED return 0; } alloc_begin = boundary_line - alloc_size; a000f9cc: e0664000 rsb r4, r6, r0 <== NOT EXECUTED a000f9d0: e1a00004 mov r0, r4 <== NOT EXECUTED a000f9d4: e1a01008 mov r1, r8 <== NOT EXECUTED a000f9d8: eb002c06 bl a001a9f8 <__umodsi3> <== NOT EXECUTED a000f9dc: e0604004 rsb r4, r0, r4 <== NOT EXECUTED alloc_begin = _Heap_Align_down( alloc_begin, alignment ); alloc_end = alloc_begin + alloc_size; a000f9e0: e0849006 add r9, r4, r6 <== NOT EXECUTED a000f9e4: e1a00009 mov r0, r9 <== NOT EXECUTED a000f9e8: e1a0100b mov r1, fp <== NOT EXECUTED a000f9ec: eb002c01 bl a001a9f8 <__umodsi3> <== NOT EXECUTED a000f9f0: 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 ) { a000f9f4: e1500009 cmp r0, r9 <== NOT EXECUTED a000f9f8: 31540000 cmpcc r4, r0 <== NOT EXECUTED a000f9fc: 3affffef bcc a000f9c0 <_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 ) { a000fa00: e59d2008 ldr r2, [sp, #8] a000fa04: e1540002 cmp r4, r2 a000fa08: 3a00000d bcc a000fa44 <_Heap_Allocate_aligned_with_boundary+0x174> a000fa0c: e1a00004 mov r0, r4 a000fa10: e59d1000 ldr r1, [sp] a000fa14: eb002bf7 bl a001a9f8 <__umodsi3> a000fa18: e3e09007 mvn r9, #7 a000fa1c: e06a9009 rsb r9, sl, r9 if ( free_size >= min_block_size || free_size == 0 ) { return alloc_begin; } } return 0; a000fa20: 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); a000fa24: 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 ) { a000fa28: e0603009 rsb r3, r0, r9 return alloc_begin; } } return 0; a000fa2c: e1590000 cmp r9, r0 a000fa30: 11530002 cmpne r3, r2 a000fa34: 33a09000 movcc r9, #0 a000fa38: 23a09001 movcs r9, #1 a000fa3c: 31a04009 movcc r4, r9 a000fa40: ea000000 b a000fa48 <_Heap_Allocate_aligned_with_boundary+0x178> /* * 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 ) { a000fa44: e3a04000 mov r4, #0 } /* Statistics */ ++search_count; if ( alloc_begin != 0 ) { a000fa48: e3540000 cmp r4, #0 ); } } /* Statistics */ ++search_count; a000fa4c: e2877001 add r7, r7, #1 if ( alloc_begin != 0 ) { a000fa50: 1a000004 bne a000fa68 <_Heap_Allocate_aligned_with_boundary+0x198> break; } block = block->next; a000fa54: 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 ) { a000fa58: e15a0005 cmp sl, r5 a000fa5c: 1affffb4 bne a000f934 <_Heap_Allocate_aligned_with_boundary+0x64> a000fa60: e3a04000 mov r4, #0 a000fa64: ea00000a b a000fa94 <_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; a000fa68: e5953048 ldr r3, [r5, #72] ; 0x48 stats->searches += search_count; block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size ); a000fa6c: e1a00005 mov r0, r5 a000fa70: e1a0100a mov r1, sl search_again = _Heap_Protection_free_delayed_blocks( heap, alloc_begin ); } while ( search_again ); if ( alloc_begin != 0 ) { /* Statistics */ ++stats->allocs; a000fa74: e2833001 add r3, r3, #1 a000fa78: e5853048 str r3, [r5, #72] ; 0x48 stats->searches += search_count; a000fa7c: e595304c ldr r3, [r5, #76] ; 0x4c block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size ); a000fa80: e1a02004 mov r2, r4 } while ( search_again ); if ( alloc_begin != 0 ) { /* Statistics */ ++stats->allocs; stats->searches += search_count; a000fa84: e0833007 add r3, r3, r7 a000fa88: e585304c str r3, [r5, #76] ; 0x4c block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size ); a000fa8c: e1a03006 mov r3, r6 a000fa90: ebffee2f bl a000b354 <_Heap_Block_allocate> boundary ); } /* Statistics */ if ( stats->max_search < search_count ) { a000fa94: e5953044 ldr r3, [r5, #68] ; 0x44 stats->max_search = search_count; } return (void *) alloc_begin; a000fa98: e1a00004 mov r0, r4 boundary ); } /* Statistics */ if ( stats->max_search < search_count ) { a000fa9c: e1530007 cmp r3, r7 stats->max_search = search_count; a000faa0: 35857044 strcc r7, [r5, #68] ; 0x44 } return (void *) alloc_begin; a000faa4: ea000000 b a000faac <_Heap_Allocate_aligned_with_boundary+0x1dc> return NULL; } if ( boundary != 0 ) { if ( boundary < alloc_size ) { return NULL; a000faa8: e3a00000 mov r0, #0 if ( stats->max_search < search_count ) { stats->max_search = search_count; } return (void *) alloc_begin; } a000faac: e28dd01c add sp, sp, #28 a000fab0: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} =============================================================================== a000b354 <_Heap_Block_allocate>: Heap_Control *heap, Heap_Block *block, uintptr_t alloc_begin, uintptr_t alloc_size ) { a000b354: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} - 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; a000b358: 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; a000b35c: e2426008 sub r6, r2, #8 a000b360: e1a04001 mov r4, r1 a000b364: 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; a000b368: 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; a000b36c: 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); a000b370: e0849001 add r9, r4, r1 Heap_Control *heap, Heap_Block *block, uintptr_t alloc_begin, uintptr_t alloc_size ) { a000b374: 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; a000b378: e5990004 ldr r0, [r9, #4] Heap_Block *free_list_anchor = NULL; _HAssert( alloc_area_begin <= alloc_begin ); if ( _Heap_Is_free( block ) ) { a000b37c: 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 ); a000b380: 11a08005 movne r8, r5 Heap_Block *free_list_anchor = NULL; _HAssert( alloc_area_begin <= alloc_begin ); if ( _Heap_Is_free( block ) ) { a000b384: 1a00000c bne a000b3bc <_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; a000b388: e5940008 ldr r0, [r4, #8] free_list_anchor = block->prev; a000b38c: e594800c ldr r8, [r4, #12] Heap_Block *prev = block->prev; prev->next = next; a000b390: e5880008 str r0, [r8, #8] next->prev = prev; a000b394: e580800c str r8, [r0, #12] _Heap_Free_list_remove( block ); /* Statistics */ --stats->free_blocks; a000b398: e5950038 ldr r0, [r5, #56] ; 0x38 a000b39c: e2400001 sub r0, r0, #1 a000b3a0: e5850038 str r0, [r5, #56] ; 0x38 ++stats->used_blocks; a000b3a4: e5950040 ldr r0, [r5, #64] ; 0x40 a000b3a8: e2800001 add r0, r0, #1 a000b3ac: e5850040 str r0, [r5, #64] ; 0x40 stats->free_size -= _Heap_Block_size( block ); a000b3b0: e5950030 ldr r0, [r5, #48] ; 0x30 a000b3b4: e0611000 rsb r1, r1, r0 a000b3b8: e5851030 str r1, [r5, #48] ; 0x30 } else { free_list_anchor = _Heap_Free_list_head( heap ); } if ( alloc_area_offset < heap->page_size ) { a000b3bc: e5951010 ldr r1, [r5, #16] a000b3c0: e1530001 cmp r3, r1 a000b3c4: 2a000005 bcs a000b3e0 <_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 ); a000b3c8: e1a00005 mov r0, r5 a000b3cc: e1a01004 mov r1, r4 a000b3d0: e1a02008 mov r2, r8 a000b3d4: e0833007 add r3, r3, r7 a000b3d8: ebffff2e bl a000b098 <_Heap_Block_split> a000b3dc: ea000021 b a000b468 <_Heap_Block_allocate+0x114> RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down( uintptr_t value, uintptr_t alignment ) { return value - (value % alignment); a000b3e0: e1a00002 mov r0, r2 a000b3e4: eb003d83 bl a001a9f8 <__umodsi3> _HAssert( block_size >= heap->min_block_size ); _HAssert( new_block_size >= heap->min_block_size ); /* Statistics */ stats->free_size += block_size; a000b3e8: 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); a000b3ec: 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; a000b3f0: 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; a000b3f4: e0822003 add r2, r2, r3 if ( _Heap_Is_prev_used( block ) ) { a000b3f8: 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; a000b3fc: 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; a000b400: e5852030 str r2, [r5, #48] ; 0x30 if ( _Heap_Is_prev_used( block ) ) { a000b404: 0a000009 beq a000b430 <_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; a000b408: e5982008 ldr r2, [r8, #8] new_block->next = next; new_block->prev = block_before; a000b40c: e584800c str r8, [r4, #12] Heap_Block *new_block ) { Heap_Block *next = block_before->next; new_block->next = next; a000b410: e5842008 str r2, [r4, #8] new_block->prev = block_before; block_before->next = new_block; next->prev = new_block; a000b414: e582400c str r4, [r2, #12] _Heap_Free_list_insert_after( free_list_anchor, block ); free_list_anchor = block; /* Statistics */ ++stats->free_blocks; a000b418: 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; a000b41c: e5884008 str r4, [r8, #8] a000b420: e2822001 add r2, r2, #1 a000b424: e5852038 str r2, [r5, #56] ; 0x38 a000b428: e1a02004 mov r2, r4 a000b42c: ea000005 b a000b448 <_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); a000b430: e5942000 ldr r2, [r4] <== NOT EXECUTED a000b434: 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; a000b438: e5942004 ldr r2, [r4, #4] <== NOT EXECUTED a000b43c: 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; a000b440: e0833002 add r3, r3, r2 <== NOT EXECUTED a000b444: e1a02008 mov r2, r8 <== NOT EXECUTED } block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED; a000b448: e3831001 orr r1, r3, #1 a000b44c: e5841004 str r1, [r4, #4] new_block->prev_size = block_size; new_block->size_and_flag = new_block_size; _Heap_Block_split( heap, new_block, free_list_anchor, alloc_size ); a000b450: e1a00005 mov r0, r5 } block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED; new_block->prev_size = block_size; new_block->size_and_flag = new_block_size; a000b454: e8860208 stm r6, {r3, r9} _Heap_Block_split( heap, new_block, free_list_anchor, alloc_size ); a000b458: e1a01006 mov r1, r6 a000b45c: e1a03007 mov r3, r7 a000b460: ebffff0c bl a000b098 <_Heap_Block_split> a000b464: e1a04006 mov r4, r6 alloc_size ); } /* Statistics */ if ( stats->min_free_size > stats->free_size ) { a000b468: e5953030 ldr r3, [r5, #48] ; 0x30 a000b46c: e5952034 ldr r2, [r5, #52] ; 0x34 } _Heap_Protection_block_initialize( heap, block ); return block; } a000b470: e1a00004 mov r0, r4 alloc_size ); } /* Statistics */ if ( stats->min_free_size > stats->free_size ) { a000b474: e1520003 cmp r2, r3 stats->min_free_size = stats->free_size; a000b478: 85853034 strhi r3, [r5, #52] ; 0x34 } _Heap_Protection_block_initialize( heap, block ); return block; } a000b47c: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== a000b098 <_Heap_Block_split>: Heap_Control *heap, Heap_Block *block, Heap_Block *free_list_anchor, uintptr_t alloc_size ) { a000b098: 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; a000b09c: e5908014 ldr r8, [r0, #20] uintptr_t alloc_size ) { Heap_Statistics *const stats = &heap->stats; uintptr_t const page_size = heap->page_size; a000b0a0: e590a010 ldr sl, [r0, #16] Heap_Control *heap, Heap_Block *block, Heap_Block *free_list_anchor, uintptr_t alloc_size ) { a000b0a4: 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; a000b0a8: 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; a000b0ac: e153000b cmp r3, fp a000b0b0: 21a0b003 movcs fp, r3 uintptr_t const block_size = _Heap_Block_size( block ); uintptr_t const used_size = a000b0b4: e28bb008 add fp, fp, #8 - 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; a000b0b8: e5919004 ldr r9, [r1, #4] Heap_Control *heap, Heap_Block *block, Heap_Block *free_list_anchor, uintptr_t alloc_size ) { a000b0bc: e1a04000 mov r4, r0 RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_up( uintptr_t value, uintptr_t alignment ) { uintptr_t remainder = value % alignment; a000b0c0: e1a0100a mov r1, sl a000b0c4: e1a0000b mov r0, fp a000b0c8: e1a06002 mov r6, r2 a000b0cc: eb003e49 bl a001a9f8 <__umodsi3> a000b0d0: e3c97001 bic r7, r9, #1 if ( remainder != 0 ) { a000b0d4: 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; a000b0d8: e2872004 add r2, r7, #4 return value - remainder + alignment; a000b0dc: 108ba00a addne sl, fp, sl } else { return value; a000b0e0: 01a0a00b moveq sl, fp uintptr_t const free_size_limit = min_block_size + HEAP_ALLOC_BONUS; a000b0e4: 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; a000b0e8: e06bb002 rsb fp, fp, r2 ) { uintptr_t remainder = value % alignment; if ( remainder != 0 ) { return value - remainder + alignment; a000b0ec: 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); a000b0f0: 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 ) { a000b0f4: 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; a000b0f8: 35932004 ldrcc r2, [r3, #4] a000b0fc: 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 ) { a000b100: 3a000023 bcc a000b194 <_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; a000b104: 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; a000b108: 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; a000b10c: 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); a000b110: 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; a000b114: e18aa009 orr sl, sl, r9 a000b118: 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; a000b11c: e0811007 add r1, r1, r7 a000b120: 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; a000b124: e5931004 ldr r1, [r3, #4] a000b128: e3c11001 bic r1, r1, #1 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; a000b12c: e0830001 add r0, r3, r1 a000b130: e5900004 ldr r0, [r0, #4] if ( _Heap_Is_used( next_block ) ) { a000b134: e3100001 tst r0, #1 a000b138: 0a000008 beq a000b160 <_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; a000b13c: e5961008 ldr r1, [r6, #8] new_block->next = next; new_block->prev = block_before; a000b140: e582600c str r6, [r2, #12] Heap_Block *new_block ) { Heap_Block *next = block_before->next; new_block->next = next; a000b144: e5821008 str r1, [r2, #8] new_block->prev = block_before; block_before->next = new_block; next->prev = new_block; a000b148: e581200c str r2, [r1, #12] _Heap_Free_list_insert_after( free_list_anchor, free_block ); /* Statistics */ ++stats->free_blocks; a000b14c: 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; a000b150: e5862008 str r2, [r6, #8] a000b154: e2811001 add r1, r1, #1 a000b158: e5841038 str r1, [r4, #56] ; 0x38 a000b15c: ea000007 b a000b180 <_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; a000b160: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED Heap_Block *prev = old_block->prev; a000b164: 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; a000b168: e0877001 add r7, r7, r1 <== NOT EXECUTED new_block->next = next; a000b16c: e5820008 str r0, [r2, #8] <== NOT EXECUTED new_block->prev = prev; a000b170: e582300c str r3, [r2, #12] <== NOT EXECUTED next->prev = new_block; prev->next = new_block; a000b174: 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; a000b178: 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); a000b17c: 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; a000b180: e3871001 orr r1, r7, #1 a000b184: e5821004 str r1, [r2, #4] next_block->prev_size = free_block_size; next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED; a000b188: 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; a000b18c: e5837000 str r7, [r3] next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED; a000b190: e3c22001 bic r2, r2, #1 _Heap_Protection_block_initialize( heap, free_block ); } else { next_block->size_and_flag |= HEAP_PREV_BLOCK_USED; a000b194: e5832004 str r2, [r3, #4] a000b198: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} =============================================================================== a000fb20 <_Heap_Extend>: Heap_Control *heap, void *extend_area_begin_ptr, uintptr_t extend_area_size, uintptr_t unused __attribute__((unused)) ) { a000fb20: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} a000fb24: e1a05001 mov r5, r1 Heap_Statistics *const stats = &heap->stats; Heap_Block *const first_block = heap->first_block; a000fb28: e5901020 ldr r1, [r0, #32] Heap_Control *heap, void *extend_area_begin_ptr, uintptr_t extend_area_size, uintptr_t unused __attribute__((unused)) ) { a000fb2c: e24dd024 sub sp, sp, #36 ; 0x24 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; a000fb30: e5903010 ldr r3, [r0, #16] uintptr_t extend_area_size, uintptr_t unused __attribute__((unused)) ) { Heap_Statistics *const stats = &heap->stats; Heap_Block *const first_block = heap->first_block; a000fb34: e58d1010 str r1, [sp, #16] Heap_Block *extend_last_block = NULL; 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; a000fb38: 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; a000fb3c: 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 ) { a000fb40: e0956002 adds r6, r5, r2 Heap_Control *heap, void *extend_area_begin_ptr, uintptr_t extend_area_size, uintptr_t unused __attribute__((unused)) ) { a000fb44: 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; a000fb48: 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; a000fb4c: e58d801c str r8, [sp, #28] Heap_Block *extend_last_block = NULL; uintptr_t const page_size = heap->page_size; uintptr_t const min_block_size = heap->min_block_size; a000fb50: 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; a000fb54: 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; a000fb58: e58d1018 str r1, [sp, #24] 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 0; a000fb5c: 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 ) { a000fb60: 2a00009a bcs a000fdd0 <_Heap_Extend+0x2b0> return 0; } extend_area_ok = _Heap_Get_first_and_last_block( a000fb64: e28d101c add r1, sp, #28 a000fb68: e58d1000 str r1, [sp] a000fb6c: e28d1020 add r1, sp, #32 a000fb70: e58d1004 str r1, [sp, #4] a000fb74: e1a00005 mov r0, r5 a000fb78: e1a01002 mov r1, r2 a000fb7c: e59d2014 ldr r2, [sp, #20] a000fb80: ebffed9c bl a000b1f8 <_Heap_Get_first_and_last_block> page_size, min_block_size, &extend_first_block, &extend_last_block ); if (!extend_area_ok ) { a000fb84: e3500000 cmp r0, #0 a000fb88: 0a000090 beq a000fdd0 <_Heap_Extend+0x2b0> a000fb8c: e59da010 ldr sl, [sp, #16] a000fb90: e1a07008 mov r7, r8 a000fb94: e1a09008 mov r9, r8 return 0; } do { uintptr_t const sub_area_begin = (start_block != first_block) ? (uintptr_t) start_block : heap->area_begin; a000fb98: e5941018 ldr r1, [r4, #24] a000fb9c: e1a03008 mov r3, r8 a000fba0: e1a0c004 mov ip, r4 a000fba4: ea000000 b a000fbac <_Heap_Extend+0x8c> a000fba8: e1a0100a mov r1, sl <== NOT EXECUTED uintptr_t const sub_area_end = start_block->prev_size; a000fbac: e59a4000 ldr r4, [sl] Heap_Block *const end_block = _Heap_Block_of_alloc_area( sub_area_end, page_size ); if ( a000fbb0: e1560001 cmp r6, r1 a000fbb4: 93a00000 movls r0, #0 a000fbb8: 83a00001 movhi r0, #1 a000fbbc: e1550004 cmp r5, r4 a000fbc0: 23a00000 movcs r0, #0 a000fbc4: e3500000 cmp r0, #0 a000fbc8: 1a00007f bne a000fdcc <_Heap_Extend+0x2ac> sub_area_end > extend_area_begin && extend_area_end > sub_area_begin ) { return 0; } if ( extend_area_end == sub_area_begin ) { a000fbcc: e1560001 cmp r6, r1 a000fbd0: 01a0300a moveq r3, sl a000fbd4: 0a000001 beq a000fbe0 <_Heap_Extend+0xc0> merge_below_block = start_block; } else if ( extend_area_end < sub_area_end ) { a000fbd8: e1560004 cmp r6, r4 a000fbdc: 31a0900a movcc r9, sl RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down( uintptr_t value, uintptr_t alignment ) { return value - (value % alignment); a000fbe0: e1a00004 mov r0, r4 a000fbe4: e59d1014 ldr r1, [sp, #20] a000fbe8: e58d300c str r3, [sp, #12] a000fbec: e58dc008 str ip, [sp, #8] a000fbf0: eb002c49 bl a001ad1c <__umodsi3> a000fbf4: e244b008 sub fp, r4, #8 link_below_block = start_block; } if ( sub_area_end == extend_area_begin ) { a000fbf8: 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); a000fbfc: e060000b rsb r0, r0, fp a000fc00: e59d300c ldr r3, [sp, #12] a000fc04: 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 ) a000fc08: 01a07000 moveq r7, r0 start_block->prev_size = extend_area_end; a000fc0c: 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 ) { a000fc10: 0a000000 beq a000fc18 <_Heap_Extend+0xf8> a000fc14: 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; a000fc18: 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 ); a000fc1c: e59d2010 ldr r2, [sp, #16] a000fc20: 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); a000fc24: e080a00a add sl, r0, sl a000fc28: e15a0002 cmp sl, r2 a000fc2c: 1affffdd bne a000fba8 <_Heap_Extend+0x88> a000fc30: e1a02009 mov r2, r9 a000fc34: e1a09003 mov r9, r3 if ( extend_area_begin < heap->area_begin ) { a000fc38: e59c3018 ldr r3, [ip, #24] a000fc3c: e1a0400c mov r4, ip a000fc40: e1550003 cmp r5, r3 heap->area_begin = extend_area_begin; a000fc44: 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 ) { a000fc48: 3a000002 bcc a000fc58 <_Heap_Extend+0x138> heap->area_begin = extend_area_begin; } else if ( heap->area_end < extend_area_end ) { a000fc4c: e59c301c ldr r3, [ip, #28] <== NOT EXECUTED a000fc50: e1530006 cmp r3, r6 <== NOT EXECUTED heap->area_end = extend_area_end; a000fc54: 358c601c strcc r6, [ip, #28] <== NOT EXECUTED } extend_first_block_size = (uintptr_t) extend_last_block - (uintptr_t) extend_first_block; a000fc58: e59d101c ldr r1, [sp, #28] a000fc5c: e59d3020 ldr r3, [sp, #32] extend_first_block->prev_size = extend_area_end; a000fc60: 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 = a000fc64: 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; a000fc68: e380c001 orr ip, r0, #1 _Heap_Protection_block_initialize( heap, extend_first_block ); extend_last_block->prev_size = extend_first_block_size; a000fc6c: e5830000 str r0, [r3] extend_last_block->size_and_flag = 0; a000fc70: 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 = a000fc74: 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; a000fc78: e5830004 str r0, [r3, #4] _Heap_Protection_block_initialize( heap, extend_last_block ); if ( (uintptr_t) extend_first_block < (uintptr_t) heap->first_block ) { a000fc7c: e5940020 ldr r0, [r4, #32] a000fc80: e1500001 cmp r0, r1 heap->first_block = extend_first_block; a000fc84: 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 ) { a000fc88: 8a000002 bhi a000fc98 <_Heap_Extend+0x178> heap->first_block = extend_first_block; } else if ( (uintptr_t) extend_last_block > (uintptr_t) heap->last_block ) { a000fc8c: e5941024 ldr r1, [r4, #36] ; 0x24 <== NOT EXECUTED a000fc90: e1510003 cmp r1, r3 <== NOT EXECUTED heap->last_block = extend_last_block; a000fc94: 35843024 strcc r3, [r4, #36] ; 0x24 <== NOT EXECUTED } if ( merge_below_block != NULL ) { a000fc98: e3590000 cmp r9, #0 a000fc9c: 0a000010 beq a000fce4 <_Heap_Extend+0x1c4> Heap_Control *heap, uintptr_t extend_area_begin, Heap_Block *first_block ) { uintptr_t const page_size = heap->page_size; a000fca0: 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 ); a000fca4: 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; a000fca8: e1a00005 mov r0, r5 <== NOT EXECUTED a000fcac: e1a0100a mov r1, sl <== NOT EXECUTED a000fcb0: eb002c19 bl a001ad1c <__umodsi3> <== NOT EXECUTED if ( remainder != 0 ) { a000fcb4: e3500000 cmp r0, #0 <== NOT EXECUTED return value - remainder + alignment; a000fcb8: 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; a000fcbc: e5993000 ldr r3, [r9] <== NOT EXECUTED a000fcc0: 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 = a000fcc4: 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; a000fcc8: 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 = a000fccc: 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; a000fcd0: e3833001 orr r3, r3, #1 <== NOT EXECUTED a000fcd4: e5053004 str r3, [r5, #-4] <== NOT EXECUTED _Heap_Free_block( heap, new_first_block ); a000fcd8: e1a00004 mov r0, r4 <== NOT EXECUTED a000fcdc: ebffff7a bl a000facc <_Heap_Free_block> <== NOT EXECUTED a000fce0: ea000004 b a000fcf8 <_Heap_Extend+0x1d8> <== 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 ) { a000fce4: e3520000 cmp r2, #0 _Heap_Link_below( a000fce8: 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; a000fcec: 10632002 rsbne r2, r3, r2 a000fcf0: 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 = a000fcf4: 15832004 strne r2, [r3, #4] link_below_block, extend_last_block ); } if ( merge_above_block != NULL ) { a000fcf8: e3570000 cmp r7, #0 a000fcfc: 0a000012 beq a000fd4c <_Heap_Extend+0x22c> ) { 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, a000fd00: 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( a000fd04: 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); a000fd08: e5941010 ldr r1, [r4, #16] <== NOT EXECUTED a000fd0c: e1a00006 mov r0, r6 <== NOT EXECUTED a000fd10: eb002c01 bl a001ad1c <__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) a000fd14: e5972004 ldr r2, [r7, #4] <== NOT EXECUTED a000fd18: 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 = a000fd1c: e0863007 add r3, r6, r7 <== NOT EXECUTED (last_block->size_and_flag - last_block_new_size) a000fd20: e0662002 rsb r2, r6, r2 <== NOT EXECUTED | HEAP_PREV_BLOCK_USED; a000fd24: 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 = a000fd28: 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; a000fd2c: 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 ); a000fd30: e1a00004 mov r0, r4 <== NOT EXECUTED a000fd34: e1a01007 mov r1, r7 <== NOT EXECUTED a000fd38: e2033001 and r3, r3, #1 <== NOT EXECUTED block->size_and_flag = size | flag; a000fd3c: e1866003 orr r6, r6, r3 <== NOT EXECUTED a000fd40: e5876004 str r6, [r7, #4] <== NOT EXECUTED a000fd44: ebffff60 bl a000facc <_Heap_Free_block> <== NOT EXECUTED a000fd48: ea00000b b a000fd7c <_Heap_Extend+0x25c> <== NOT EXECUTED ); } if ( merge_above_block != NULL ) { _Heap_Merge_above( heap, merge_above_block, extend_area_end ); } else if ( link_above_block != NULL ) { a000fd4c: e3580000 cmp r8, #0 a000fd50: 0a000009 beq a000fd7c <_Heap_Extend+0x25c> 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; a000fd54: 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 ); a000fd58: e59d101c ldr r1, [sp, #28] <== 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( a000fd5c: e59d3020 ldr r3, [sp, #32] <== NOT EXECUTED a000fd60: 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 ); a000fd64: e0681001 rsb r1, r8, r1 <== NOT EXECUTED block->size_and_flag = size | flag; a000fd68: e1812002 orr r2, r1, r2 <== NOT EXECUTED a000fd6c: e5882004 str r2, [r8, #4] <== NOT EXECUTED last_block->size_and_flag |= HEAP_PREV_BLOCK_USED; a000fd70: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED a000fd74: e3822001 orr r2, r2, #1 <== NOT EXECUTED a000fd78: e5832004 str r2, [r3, #4] <== NOT EXECUTED extend_first_block, extend_last_block ); } if ( merge_below_block == NULL && merge_above_block == NULL ) { a000fd7c: e3570000 cmp r7, #0 a000fd80: 03590000 cmpeq r9, #0 a000fd84: 1a000002 bne a000fd94 <_Heap_Extend+0x274> _Heap_Free_block( heap, extend_first_block ); a000fd88: e1a00004 mov r0, r4 a000fd8c: e59d101c ldr r1, [sp, #28] a000fd90: ebffff4d bl a000facc <_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 a000fd94: 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( a000fd98: e5941020 ldr r1, [r4, #32] } _Heap_Set_last_block_size( heap ); extended_size = stats->free_size - free_size; a000fd9c: e5940030 ldr r0, [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; a000fda0: 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( a000fda4: 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; a000fda8: e2022001 and r2, r2, #1 block->size_and_flag = size | flag; a000fdac: e1812002 orr r2, r1, r2 a000fdb0: e5832004 str r2, [r3, #4] a000fdb4: e59d3018 ldr r3, [sp, #24] a000fdb8: e0630000 rsb r0, r3, r0 /* Statistics */ stats->size += extended_size; a000fdbc: e594302c ldr r3, [r4, #44] ; 0x2c a000fdc0: e0833000 add r3, r3, r0 a000fdc4: e584302c str r3, [r4, #44] ; 0x2c return extended_size; a000fdc8: ea000000 b a000fdd0 <_Heap_Extend+0x2b0> _Heap_Block_of_alloc_area( sub_area_end, page_size ); if ( sub_area_end > extend_area_begin && extend_area_end > sub_area_begin ) { return 0; a000fdcc: e3a00000 mov r0, #0 <== NOT EXECUTED /* Statistics */ stats->size += extended_size; return extended_size; } a000fdd0: e28dd024 add sp, sp, #36 ; 0x24 a000fdd4: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} =============================================================================== a000f734 <_Heap_No_extend>: uintptr_t unused_2 __attribute__((unused)), uintptr_t unused_3 __attribute__((unused)) ) { return 0; } a000f734: e3a00000 mov r0, #0 <== NOT EXECUTED a000f738: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000fca4 <_Heap_Resize_block>: void *alloc_begin_ptr, uintptr_t new_alloc_size, uintptr_t *old_size, uintptr_t *new_size ) { a000fca4: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} a000fca8: e1a04000 mov r4, r0 RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down( uintptr_t value, uintptr_t alignment ) { return value - (value % alignment); a000fcac: e241a008 sub sl, r1, #8 a000fcb0: e1a00001 mov r0, r1 a000fcb4: e1a05001 mov r5, r1 a000fcb8: e5941010 ldr r1, [r4, #16] a000fcbc: e1a08003 mov r8, r3 a000fcc0: e1a07002 mov r7, r2 a000fcc4: eb002b4b bl a001a9f8 <__umodsi3> a000fcc8: 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; a000fccc: e3a03000 mov r3, #0 a000fcd0: e5883000 str r3, [r8] *new_size = 0; a000fcd4: 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; a000fcd8: 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); a000fcdc: 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; a000fce0: e1530001 cmp r3, r1 a000fce4: 8a000039 bhi a000fdd0 <_Heap_Resize_block+0x12c> a000fce8: e5943024 ldr r3, [r4, #36] ; 0x24 a000fcec: e1530001 cmp r3, r1 a000fcf0: 3a000038 bcc a000fdd8 <_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; a000fcf4: 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; a000fcf8: e265c004 rsb ip, r5, #4 a000fcfc: 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; a000fd00: e0812003 add r2, r1, r3 a000fd04: e5920004 ldr r0, [r2, #4] uintptr_t alloc_size = block_end - alloc_begin + HEAP_ALLOC_BONUS; a000fd08: e08cc002 add ip, ip, r2 a000fd0c: e3c00001 bic r0, r0, #1 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; a000fd10: e082a000 add sl, r2, r0 a000fd14: 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; a000fd18: e588c000 str ip, [r8] RTEMS_INLINE_ROUTINE bool _Heap_Is_free( const Heap_Block *block ) { return !_Heap_Is_used( block ); a000fd1c: e31a0001 tst sl, #1 a000fd20: 13a0a000 movne sl, #0 a000fd24: 03a0a001 moveq sl, #1 if ( next_block_is_free ) { a000fd28: e35a0000 cmp sl, #0 block_size += next_block_size; alloc_size += next_block_size; a000fd2c: 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; a000fd30: 10833000 addne r3, r3, r0 alloc_size += next_block_size; } if ( new_alloc_size > alloc_size ) { a000fd34: e157000c cmp r7, ip a000fd38: 8a000022 bhi a000fdc8 <_Heap_Resize_block+0x124> return HEAP_RESIZE_UNSATISFIED; } if ( next_block_is_free ) { a000fd3c: e35a0000 cmp sl, #0 a000fd40: 0a000011 beq a000fd8c <_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; a000fd44: e591c004 ldr ip, [r1, #4] <== NOT EXECUTED a000fd48: e20cc001 and ip, ip, #1 <== NOT EXECUTED block->size_and_flag = size | flag; a000fd4c: e183c00c orr ip, r3, ip <== NOT EXECUTED a000fd50: 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; a000fd54: e592c008 ldr ip, [r2, #8] <== NOT EXECUTED Heap_Block *prev = block->prev; a000fd58: 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); a000fd5c: 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; a000fd60: e582c008 str ip, [r2, #8] <== NOT EXECUTED next->prev = prev; a000fd64: 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; a000fd68: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED a000fd6c: e3822001 orr r2, r2, #1 <== NOT EXECUTED a000fd70: e5832004 str r2, [r3, #4] <== NOT EXECUTED /* Statistics */ --stats->free_blocks; a000fd74: e5943038 ldr r3, [r4, #56] ; 0x38 <== NOT EXECUTED a000fd78: e2433001 sub r3, r3, #1 <== NOT EXECUTED a000fd7c: e5843038 str r3, [r4, #56] ; 0x38 <== NOT EXECUTED stats->free_size -= next_block_size; a000fd80: e5943030 ldr r3, [r4, #48] ; 0x30 <== NOT EXECUTED a000fd84: e0600003 rsb r0, r0, r3 <== NOT EXECUTED a000fd88: e5840030 str r0, [r4, #48] ; 0x30 <== NOT EXECUTED } block = _Heap_Block_allocate( heap, block, alloc_begin, new_alloc_size ); a000fd8c: e1a02005 mov r2, r5 a000fd90: e1a03007 mov r3, r7 a000fd94: e1a00004 mov r0, r4 a000fd98: ebffed6d bl a000b354 <_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; a000fd9c: e5903004 ldr r3, [r0, #4] a000fda0: 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); a000fda4: 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; a000fda8: e0655003 rsb r5, r5, r3 a000fdac: e0800005 add r0, r0, r5 a000fdb0: e5860000 str r0, [r6] /* Statistics */ ++stats->resizes; a000fdb4: e5943054 ldr r3, [r4, #84] ; 0x54 return HEAP_RESIZE_SUCCESSFUL; a000fdb8: 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; a000fdbc: e2833001 add r3, r3, #1 a000fdc0: e5843054 str r3, [r4, #84] ; 0x54 a000fdc4: 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; a000fdc8: e3a00001 mov r0, #1 *old_size = 0; *new_size = 0; if ( _Heap_Is_block_in_heap( heap, block ) ) { _Heap_Protection_block_check( heap, block ); return _Heap_Resize_block_checked( a000fdcc: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} new_alloc_size, old_size, new_size ); } return HEAP_RESIZE_FATAL_ERROR; a000fdd0: e3a00002 mov r0, #2 <== NOT EXECUTED a000fdd4: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED a000fdd8: e3a00002 mov r0, #2 <== NOT EXECUTED } a000fddc: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED =============================================================================== a000be3c <_Heap_Walk>: bool _Heap_Walk( Heap_Control *heap, int source, bool dump ) { a000be3c: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} uintptr_t const page_size = heap->page_size; a000be40: e590c010 ldr ip, [r0, #16] bool _Heap_Walk( Heap_Control *heap, int source, bool dump ) { a000be44: 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; a000be48: e59f34b4 ldr r3, [pc, #1204] ; a000c304 <_Heap_Walk+0x4c8> a000be4c: e59f84b4 ldr r8, [pc, #1204] ; a000c308 <_Heap_Walk+0x4cc> Heap_Control *heap, int source, bool dump ) { uintptr_t const page_size = heap->page_size; a000be50: e58dc020 str ip, [sp, #32] uintptr_t const min_block_size = heap->min_block_size; a000be54: e590c014 ldr ip, [r0, #20] 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; a000be58: e31200ff tst r2, #255 ; 0xff a000be5c: 11a08003 movne r8, r3 if ( !_System_state_Is_up( _System_state_Get() ) ) { a000be60: e59f34a4 ldr r3, [pc, #1188] ; a000c30c <_Heap_Walk+0x4d0> int source, bool dump ) { uintptr_t const page_size = heap->page_size; uintptr_t const min_block_size = heap->min_block_size; a000be64: e58dc028 str ip, [sp, #40] ; 0x28 Heap_Block *const first_block = heap->first_block; a000be68: e590c020 ldr ip, [r0, #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() ) ) { a000be6c: e5933000 ldr r3, [r3] bool _Heap_Walk( Heap_Control *heap, int source, bool dump ) { a000be70: e1a05000 mov r5, r0 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; a000be74: e58dc024 str ip, [sp, #36] ; 0x24 Heap_Block *const last_block = heap->last_block; a000be78: e590c024 ldr ip, [r0, #36] ; 0x24 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() ) ) { a000be7c: e3530003 cmp r3, #3 bool _Heap_Walk( Heap_Control *heap, int source, bool dump ) { a000be80: e1a04001 mov r4, r1 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; Heap_Block *const last_block = heap->last_block; a000be84: e58dc02c str ip, [sp, #44] ; 0x2c 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() ) ) { a000be88: 1a000112 bne a000c2d8 <_Heap_Walk+0x49c> 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)( a000be8c: e59dc028 ldr ip, [sp, #40] ; 0x28 a000be90: e59f2478 ldr r2, [pc, #1144] ; a000c310 <_Heap_Walk+0x4d4> a000be94: e58dc000 str ip, [sp] a000be98: e5903018 ldr r3, [r0, #24] a000be9c: e59dc024 ldr ip, [sp, #36] ; 0x24 a000bea0: e58d3004 str r3, [sp, #4] a000bea4: e590301c ldr r3, [r0, #28] a000bea8: e58dc00c str ip, [sp, #12] a000beac: e59dc02c ldr ip, [sp, #44] ; 0x2c a000beb0: e58d3008 str r3, [sp, #8] a000beb4: e58dc010 str ip, [sp, #16] a000beb8: e5903008 ldr r3, [r0, #8] a000bebc: e58d3014 str r3, [sp, #20] a000bec0: e590300c ldr r3, [r0, #12] a000bec4: e1a00001 mov r0, r1 a000bec8: e3a01000 mov r1, #0 a000becc: e58d3018 str r3, [sp, #24] a000bed0: e59d3020 ldr r3, [sp, #32] a000bed4: e12fff38 blx r8 heap->area_begin, heap->area_end, first_block, last_block, first_free_block, last_free_block ); if ( page_size == 0 ) { a000bed8: e59dc020 ldr ip, [sp, #32] a000bedc: e35c0000 cmp ip, #0 a000bee0: 1a000005 bne a000befc <_Heap_Walk+0xc0> (*printer)( source, true, "page size is zero\n" ); a000bee4: e1a00004 mov r0, r4 a000bee8: e3a01001 mov r1, #1 a000beec: e59f2420 ldr r2, [pc, #1056] ; a000c314 <_Heap_Walk+0x4d8> a000bef0: e12fff38 blx r8 if ( !_System_state_Is_up( _System_state_Get() ) ) { return true; } if ( !_Heap_Walk_check_control( source, printer, heap ) ) { return false; a000bef4: e59d6020 ldr r6, [sp, #32] a000bef8: ea0000f7 b a000c2dc <_Heap_Walk+0x4a0> (*printer)( source, true, "page size is zero\n" ); return false; } if ( !_Addresses_Is_aligned( (void *) page_size ) ) { a000befc: e59dc020 ldr ip, [sp, #32] a000bf00: e21c7007 ands r7, ip, #7 (*printer)( a000bf04: 11a00004 movne r0, r4 a000bf08: 13a01001 movne r1, #1 a000bf0c: 159f2404 ldrne r2, [pc, #1028] ; a000c318 <_Heap_Walk+0x4dc> a000bf10: 11a0300c movne r3, ip a000bf14: 1a0000f7 bne a000c2f8 <_Heap_Walk+0x4bc> RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned( uintptr_t value, uintptr_t alignment ) { return (value % alignment) == 0; a000bf18: e59d0028 ldr r0, [sp, #40] ; 0x28 a000bf1c: e59d1020 ldr r1, [sp, #32] a000bf20: ebffe435 bl a0004ffc <__umodsi3> ); return false; } if ( !_Heap_Is_aligned( min_block_size, page_size ) ) { a000bf24: e2506000 subs r6, r0, #0 a000bf28: 0a000005 beq a000bf44 <_Heap_Walk+0x108> (*printer)( a000bf2c: e1a00004 mov r0, r4 a000bf30: e3a01001 mov r1, #1 a000bf34: e59f23e0 ldr r2, [pc, #992] ; a000c31c <_Heap_Walk+0x4e0> a000bf38: e59d3028 ldr r3, [sp, #40] ; 0x28 a000bf3c: e12fff38 blx r8 a000bf40: ea000023 b a000bfd4 <_Heap_Walk+0x198> a000bf44: e59dc024 ldr ip, [sp, #36] ; 0x24 a000bf48: e59d1020 ldr r1, [sp, #32] a000bf4c: e28c0008 add r0, ip, #8 a000bf50: ebffe429 bl a0004ffc <__umodsi3> ); return false; } if ( a000bf54: e2507000 subs r7, r0, #0 !_Heap_Is_aligned( _Heap_Alloc_area_of_block( first_block ), page_size ) ) { (*printer)( a000bf58: 11a00004 movne r0, r4 a000bf5c: 13a01001 movne r1, #1 a000bf60: 159f23b8 ldrne r2, [pc, #952] ; a000c320 <_Heap_Walk+0x4e4> a000bf64: 159d3024 ldrne r3, [sp, #36] ; 0x24 a000bf68: 1a00003f bne a000c06c <_Heap_Walk+0x230> 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; a000bf6c: e59dc024 ldr ip, [sp, #36] ; 0x24 a000bf70: e59c6004 ldr r6, [ip, #4] ); return false; } if ( !_Heap_Is_prev_used( first_block ) ) { a000bf74: e2166001 ands r6, r6, #1 (*printer)( a000bf78: 01a00004 moveq r0, r4 a000bf7c: 03a01001 moveq r1, #1 a000bf80: 059f239c ldreq r2, [pc, #924] ; a000c324 <_Heap_Walk+0x4e8> a000bf84: 0a000009 beq a000bfb0 <_Heap_Walk+0x174> - 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; a000bf88: e59dc02c ldr ip, [sp, #44] ; 0x2c a000bf8c: e59ca004 ldr sl, [ip, #4] a000bf90: 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); a000bf94: e08ca00a add sl, ip, sl 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; a000bf98: e59a6004 ldr r6, [sl, #4] ); return false; } if ( _Heap_Is_free( last_block ) ) { a000bf9c: e2166001 ands r6, r6, #1 a000bfa0: 1a000004 bne a000bfb8 <_Heap_Walk+0x17c> (*printer)( a000bfa4: e59f237c ldr r2, [pc, #892] ; a000c328 <_Heap_Walk+0x4ec> <== NOT EXECUTED a000bfa8: e1a00004 mov r0, r4 <== NOT EXECUTED a000bfac: e3a01001 mov r1, #1 <== NOT EXECUTED a000bfb0: e12fff38 blx r8 <== NOT EXECUTED a000bfb4: ea0000c8 b a000c2dc <_Heap_Walk+0x4a0> <== NOT EXECUTED ); return false; } if ( a000bfb8: e59dc024 ldr ip, [sp, #36] ; 0x24 a000bfbc: e15a000c cmp sl, ip a000bfc0: 0a000005 beq a000bfdc <_Heap_Walk+0x1a0> _Heap_Block_at( last_block, _Heap_Block_size( last_block ) ) != first_block ) { (*printer)( a000bfc4: e1a00004 mov r0, r4 <== NOT EXECUTED a000bfc8: e3a01001 mov r1, #1 <== NOT EXECUTED a000bfcc: e59f2358 ldr r2, [pc, #856] ; a000c32c <_Heap_Walk+0x4f0> <== NOT EXECUTED a000bfd0: e12fff38 blx r8 <== NOT EXECUTED if ( !_System_state_Is_up( _System_state_Get() ) ) { return true; } if ( !_Heap_Walk_check_control( source, printer, heap ) ) { return false; a000bfd4: e1a06007 mov r6, r7 a000bfd8: ea0000bf b a000c2dc <_Heap_Walk+0x4a0> int source, Heap_Walk_printer printer, Heap_Control *heap ) { uintptr_t const page_size = heap->page_size; a000bfdc: e5957010 ldr r7, [r5, #16] return &heap->free_list; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap ) { return _Heap_Free_list_head(heap)->next; a000bfe0: e5959008 ldr r9, [r5, #8] const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap ); a000bfe4: e1a0b005 mov fp, r5 a000bfe8: ea000030 b a000c0b0 <_Heap_Walk+0x274> 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; a000bfec: e5953020 ldr r3, [r5, #32] a000bff0: e1530009 cmp r3, r9 a000bff4: 83a06000 movhi r6, #0 a000bff8: 8a000003 bhi a000c00c <_Heap_Walk+0x1d0> a000bffc: e5956024 ldr r6, [r5, #36] ; 0x24 a000c000: e1560009 cmp r6, r9 a000c004: 33a06000 movcc r6, #0 a000c008: 23a06001 movcs r6, #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 ) ) { a000c00c: e21660ff ands r6, r6, #255 ; 0xff (*printer)( a000c010: 01a00004 moveq r0, r4 a000c014: 03a01001 moveq r1, #1 a000c018: 059f2310 ldreq r2, [pc, #784] ; a000c330 <_Heap_Walk+0x4f4> a000c01c: 0a000011 beq a000c068 <_Heap_Walk+0x22c> RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned( uintptr_t value, uintptr_t alignment ) { return (value % alignment) == 0; a000c020: e2890008 add r0, r9, #8 a000c024: e1a01007 mov r1, r7 a000c028: ebffe3f3 bl a0004ffc <__umodsi3> ); return false; } if ( a000c02c: e2506000 subs r6, r0, #0 !_Heap_Is_aligned( _Heap_Alloc_area_of_block( free_block ), page_size ) ) { (*printer)( a000c030: 11a00004 movne r0, r4 a000c034: 13a01001 movne r1, #1 a000c038: 159f22f4 ldrne r2, [pc, #756] ; a000c334 <_Heap_Walk+0x4f8> a000c03c: 11a03009 movne r3, r9 a000c040: 1a0000ac bne a000c2f8 <_Heap_Walk+0x4bc> - 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; a000c044: e5993004 ldr r3, [r9, #4] a000c048: e3c33001 bic r3, r3, #1 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; a000c04c: e0893003 add r3, r9, r3 a000c050: e593c004 ldr ip, [r3, #4] ); return false; } if ( _Heap_Is_used( free_block ) ) { a000c054: e21cc001 ands ip, ip, #1 a000c058: 0a000005 beq a000c074 <_Heap_Walk+0x238> (*printer)( a000c05c: e59f22d4 ldr r2, [pc, #724] ; a000c338 <_Heap_Walk+0x4fc> <== NOT EXECUTED a000c060: e1a00004 mov r0, r4 <== NOT EXECUTED a000c064: e3a01001 mov r1, #1 <== NOT EXECUTED a000c068: e1a03009 mov r3, r9 <== NOT EXECUTED a000c06c: e12fff38 blx r8 <== NOT EXECUTED a000c070: ea000099 b a000c2dc <_Heap_Walk+0x4a0> <== NOT EXECUTED ); return false; } if ( free_block->prev != prev_block ) { a000c074: e599300c ldr r3, [r9, #12] a000c078: e153000b cmp r3, fp a000c07c: 0a000009 beq a000c0a8 <_Heap_Walk+0x26c> (*printer)( a000c080: e58d3000 str r3, [sp] <== NOT EXECUTED a000c084: e58dc01c str ip, [sp, #28] <== NOT EXECUTED a000c088: e1a00004 mov r0, r4 <== NOT EXECUTED a000c08c: e3a01001 mov r1, #1 <== NOT EXECUTED a000c090: e59f22a4 ldr r2, [pc, #676] ; a000c33c <_Heap_Walk+0x500> <== NOT EXECUTED a000c094: e1a03009 mov r3, r9 <== NOT EXECUTED a000c098: e12fff38 blx r8 <== NOT EXECUTED if ( !_System_state_Is_up( _System_state_Get() ) ) { return true; } if ( !_Heap_Walk_check_control( source, printer, heap ) ) { return false; a000c09c: e59dc01c ldr ip, [sp, #28] <== NOT EXECUTED a000c0a0: e1a0600c mov r6, ip <== NOT EXECUTED a000c0a4: ea00008c b a000c2dc <_Heap_Walk+0x4a0> <== NOT EXECUTED return false; } prev_block = free_block; free_block = free_block->next; a000c0a8: e1a0b009 mov fp, r9 a000c0ac: e5999008 ldr r9, [r9, #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 ) { a000c0b0: e1590005 cmp r9, r5 a000c0b4: 1affffcc bne a000bfec <_Heap_Walk+0x1b0> a000c0b8: ea000000 b a000c0c0 <_Heap_Walk+0x284> block->prev_size ); } block = next_block; } while ( block != first_block ); a000c0bc: e1a0a009 mov sl, r9 - 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; a000c0c0: e59a6004 ldr r6, [sl, #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; a000c0c4: e5953020 ldr r3, [r5, #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; a000c0c8: e3c6b001 bic fp, r6, #1 RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at( const Heap_Block *block, uintptr_t offset ) { return (Heap_Block *) ((uintptr_t) block + offset); a000c0cc: e08a900b add r9, sl, fp 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; a000c0d0: e1530009 cmp r3, r9 a000c0d4: 83a03000 movhi r3, #0 a000c0d8: 8a000003 bhi a000c0ec <_Heap_Walk+0x2b0> a000c0dc: e5953024 ldr r3, [r5, #36] ; 0x24 a000c0e0: e1530009 cmp r3, r9 a000c0e4: 33a03000 movcc r3, #0 a000c0e8: 23a03001 movcs r3, #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 ) ) { a000c0ec: e21330ff ands r3, r3, #255 ; 0xff a000c0f0: 1a000007 bne a000c114 <_Heap_Walk+0x2d8> a000c0f4: e1a06003 mov r6, r3 <== NOT EXECUTED (*printer)( a000c0f8: e58d9000 str r9, [sp] <== NOT EXECUTED a000c0fc: e1a00004 mov r0, r4 <== NOT EXECUTED a000c100: e3a01001 mov r1, #1 <== NOT EXECUTED a000c104: e59f2234 ldr r2, [pc, #564] ; a000c340 <_Heap_Walk+0x504> <== NOT EXECUTED a000c108: e1a0300a mov r3, sl <== NOT EXECUTED a000c10c: e12fff38 blx r8 <== NOT EXECUTED "block 0x%08x: next block 0x%08x not in heap\n", block, next_block ); return false; a000c110: ea000071 b a000c2dc <_Heap_Walk+0x4a0> <== 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; a000c114: e59dc02c ldr ip, [sp, #44] ; 0x2c RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned( uintptr_t value, uintptr_t alignment ) { return (value % alignment) == 0; a000c118: e1a0000b mov r0, fp a000c11c: e59d1020 ldr r1, [sp, #32] a000c120: e05a700c subs r7, sl, ip a000c124: 13a07001 movne r7, #1 a000c128: ebffe3b3 bl a0004ffc <__umodsi3> ); return false; } if ( !_Heap_Is_aligned( block_size, page_size ) && is_not_last_block ) { a000c12c: e3500000 cmp r0, #0 a000c130: 0a000005 beq a000c14c <_Heap_Walk+0x310> a000c134: e3570000 cmp r7, #0 <== NOT EXECUTED (*printer)( a000c138: 158db000 strne fp, [sp] <== NOT EXECUTED a000c13c: 11a00004 movne r0, r4 <== NOT EXECUTED a000c140: 13a01001 movne r1, #1 <== NOT EXECUTED a000c144: 159f21f8 ldrne r2, [pc, #504] ; a000c344 <_Heap_Walk+0x508><== NOT EXECUTED a000c148: 1a000013 bne a000c19c <_Heap_Walk+0x360> <== NOT EXECUTED ); return false; } if ( block_size < min_block_size && is_not_last_block ) { a000c14c: e59dc028 ldr ip, [sp, #40] ; 0x28 a000c150: e15b000c cmp fp, ip a000c154: 2a000008 bcs a000c17c <_Heap_Walk+0x340> a000c158: e3570000 cmp r7, #0 <== NOT EXECUTED a000c15c: 0a000006 beq a000c17c <_Heap_Walk+0x340> <== NOT EXECUTED (*printer)( a000c160: e88d1800 stm sp, {fp, ip} <== NOT EXECUTED a000c164: e1a00004 mov r0, r4 <== NOT EXECUTED a000c168: e3a01001 mov r1, #1 <== NOT EXECUTED a000c16c: e59f21d4 ldr r2, [pc, #468] ; a000c348 <_Heap_Walk+0x50c> <== NOT EXECUTED a000c170: e1a0300a mov r3, sl <== NOT EXECUTED a000c174: e12fff38 blx r8 <== NOT EXECUTED a000c178: ea00005f b a000c2fc <_Heap_Walk+0x4c0> <== NOT EXECUTED ); return false; } if ( next_block_begin <= block_begin && is_not_last_block ) { a000c17c: e159000a cmp r9, sl a000c180: 8a000008 bhi a000c1a8 <_Heap_Walk+0x36c> a000c184: e3570000 cmp r7, #0 a000c188: 0a000006 beq a000c1a8 <_Heap_Walk+0x36c> (*printer)( a000c18c: e59f21b8 ldr r2, [pc, #440] ; a000c34c <_Heap_Walk+0x510> <== NOT EXECUTED a000c190: e58d9000 str r9, [sp] <== NOT EXECUTED a000c194: e1a00004 mov r0, r4 <== NOT EXECUTED a000c198: e3a01001 mov r1, #1 <== NOT EXECUTED a000c19c: e1a0300a mov r3, sl <== NOT EXECUTED a000c1a0: e12fff38 blx r8 <== NOT EXECUTED a000c1a4: ea000054 b a000c2fc <_Heap_Walk+0x4c0> <== 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; a000c1a8: e5993004 ldr r3, [r9, #4] a000c1ac: e2066001 and r6, r6, #1 ); return false; } if ( !_Heap_Is_prev_used( next_block ) ) { a000c1b0: e3130001 tst r3, #1 a000c1b4: 1a000034 bne a000c28c <_Heap_Walk+0x450> 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 ? a000c1b8: e59a200c ldr r2, [sl, #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)( a000c1bc: e5953008 ldr r3, [r5, #8] return _Heap_Free_list_head(heap)->next; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_last( Heap_Control *heap ) { return _Heap_Free_list_tail(heap)->prev; a000c1c0: e595100c ldr r1, [r5, #12] a000c1c4: e1520003 cmp r2, r3 a000c1c8: 059f0180 ldreq r0, [pc, #384] ; a000c350 <_Heap_Walk+0x514> a000c1cc: 0a000003 beq a000c1e0 <_Heap_Walk+0x3a4> block, block_size, block->prev, block->prev == first_free_block ? " (= first free)" : (block->prev == free_list_head ? " (= head)" : ""), a000c1d0: e59f317c ldr r3, [pc, #380] ; a000c354 <_Heap_Walk+0x518> a000c1d4: e1520005 cmp r2, r5 a000c1d8: e59f0178 ldr r0, [pc, #376] ; a000c358 <_Heap_Walk+0x51c> a000c1dc: 11a00003 movne r0, r3 block->next, block->next == last_free_block ? a000c1e0: e59a3008 ldr r3, [sl, #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)( a000c1e4: e1530001 cmp r3, r1 a000c1e8: 059f116c ldreq r1, [pc, #364] ; a000c35c <_Heap_Walk+0x520> a000c1ec: 0a000003 beq a000c200 <_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)" : "") a000c1f0: e59fc168 ldr ip, [pc, #360] ; a000c360 <_Heap_Walk+0x524> a000c1f4: e1530005 cmp r3, r5 a000c1f8: e59f1154 ldr r1, [pc, #340] ; a000c354 <_Heap_Walk+0x518> a000c1fc: 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)( a000c200: e58d2004 str r2, [sp, #4] a000c204: e58d0008 str r0, [sp, #8] a000c208: e58d300c str r3, [sp, #12] a000c20c: e58d1010 str r1, [sp, #16] a000c210: e1a0300a mov r3, sl a000c214: e58db000 str fp, [sp] a000c218: e1a00004 mov r0, r4 a000c21c: e3a01000 mov r1, #0 a000c220: e59f213c ldr r2, [pc, #316] ; a000c364 <_Heap_Walk+0x528> a000c224: e12fff38 blx r8 block->next == last_free_block ? " (= last free)" : (block->next == free_list_tail ? " (= tail)" : "") ); if ( block_size != next_block->prev_size ) { a000c228: e5993000 ldr r3, [r9] a000c22c: e15b0003 cmp fp, r3 a000c230: 0a000007 beq a000c254 <_Heap_Walk+0x418> (*printer)( a000c234: e98d0208 stmib sp, {r3, r9} <== NOT EXECUTED a000c238: e58db000 str fp, [sp] <== NOT EXECUTED a000c23c: e1a00004 mov r0, r4 <== NOT EXECUTED a000c240: e3a01001 mov r1, #1 <== NOT EXECUTED a000c244: e59f211c ldr r2, [pc, #284] ; a000c368 <_Heap_Walk+0x52c> <== NOT EXECUTED a000c248: e1a0300a mov r3, sl <== NOT EXECUTED a000c24c: e12fff38 blx r8 <== NOT EXECUTED a000c250: ea000029 b a000c2fc <_Heap_Walk+0x4c0> <== NOT EXECUTED ); return false; } if ( !prev_used ) { a000c254: e3560000 cmp r6, #0 (*printer)( a000c258: 01a00004 moveq r0, r4 a000c25c: 03a01001 moveq r1, #1 a000c260: 059f2104 ldreq r2, [pc, #260] ; a000c36c <_Heap_Walk+0x530> a000c264: 01a0300a moveq r3, sl a000c268: 0affff7f beq a000c06c <_Heap_Walk+0x230> return &heap->free_list; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap ) { return _Heap_Free_list_head(heap)->next; a000c26c: e5953008 ldr r3, [r5, #8] a000c270: ea000002 b a000c280 <_Heap_Walk+0x444> { 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 ) { a000c274: e153000a cmp r3, sl a000c278: 0a000013 beq a000c2cc <_Heap_Walk+0x490> return true; } free_block = free_block->next; a000c27c: 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 ) { a000c280: e1530005 cmp r3, r5 a000c284: 1afffffa bne a000c274 <_Heap_Walk+0x438> a000c288: ea000016 b a000c2e8 <_Heap_Walk+0x4ac> <== 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) { a000c28c: e3560000 cmp r6, #0 (*printer)( a000c290: e58db000 str fp, [sp] if ( !_Heap_Is_prev_used( next_block ) ) { if ( !_Heap_Walk_check_free_block( source, printer, heap, block ) ) { return false; } } else if (prev_used) { a000c294: 0a000005 beq a000c2b0 <_Heap_Walk+0x474> (*printer)( a000c298: e1a00004 mov r0, r4 a000c29c: e3a01000 mov r1, #0 a000c2a0: e59f20c8 ldr r2, [pc, #200] ; a000c370 <_Heap_Walk+0x534> a000c2a4: e1a0300a mov r3, sl a000c2a8: e12fff38 blx r8 a000c2ac: ea000006 b a000c2cc <_Heap_Walk+0x490> "block 0x%08x: size %u\n", block, block_size ); } else { (*printer)( a000c2b0: e59a3000 ldr r3, [sl] a000c2b4: e1a00004 mov r0, r4 a000c2b8: e1a01006 mov r1, r6 a000c2bc: e58d3004 str r3, [sp, #4] a000c2c0: e59f20ac ldr r2, [pc, #172] ; a000c374 <_Heap_Walk+0x538> a000c2c4: e1a0300a mov r3, sl a000c2c8: e12fff38 blx r8 block->prev_size ); } block = next_block; } while ( block != first_block ); a000c2cc: e59dc024 ldr ip, [sp, #36] ; 0x24 a000c2d0: e159000c cmp r9, ip a000c2d4: 1affff78 bne a000c0bc <_Heap_Walk+0x280> 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; a000c2d8: e3a06001 mov r6, #1 block = next_block; } while ( block != first_block ); return true; } a000c2dc: e1a00006 mov r0, r6 a000c2e0: e28dd030 add sp, sp, #48 ; 0x30 a000c2e4: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} return false; } if ( !_Heap_Walk_is_in_free_list( heap, block ) ) { (*printer)( a000c2e8: e59f2088 ldr r2, [pc, #136] ; a000c378 <_Heap_Walk+0x53c> <== NOT EXECUTED a000c2ec: e1a00004 mov r0, r4 <== NOT EXECUTED a000c2f0: e3a01001 mov r1, #1 <== NOT EXECUTED a000c2f4: e1a0300a mov r3, sl <== NOT EXECUTED a000c2f8: e12fff38 blx r8 return false; } if ( !_Heap_Is_prev_used( next_block ) ) { if ( !_Heap_Walk_check_free_block( source, printer, heap, block ) ) { return false; a000c2fc: e3a06000 mov r6, #0 a000c300: eafffff5 b a000c2dc <_Heap_Walk+0x4a0> =============================================================================== a000bdf8 <_Heap_Walk_print>: static void _Heap_Walk_print( int source, bool error, const char *fmt, ... ) { a000bdf8: e92d000c push {r2, r3} <== NOT EXECUTED a000bdfc: e92d4001 push {r0, lr} <== NOT EXECUTED a000be00: e1a03000 mov r3, r0 <== NOT EXECUTED va_list ap; if ( error ) { a000be04: e31100ff tst r1, #255 ; 0xff <== NOT EXECUTED printk( "FAIL[%d]: ", source ); a000be08: 159f0024 ldrne r0, [pc, #36] ; a000be34 <_Heap_Walk_print+0x3c><== NOT EXECUTED } else { printk( "PASS[%d]: ", source ); a000be0c: 059f0024 ldreq r0, [pc, #36] ; a000be38 <_Heap_Walk_print+0x40><== NOT EXECUTED a000be10: e1a01003 mov r1, r3 <== NOT EXECUTED a000be14: ebffee66 bl a00077b4 <== NOT EXECUTED } va_start( ap, fmt ); a000be18: e28d100c add r1, sp, #12 <== NOT EXECUTED vprintk( fmt, ap ); a000be1c: e59d0008 ldr r0, [sp, #8] <== NOT EXECUTED printk( "FAIL[%d]: ", source ); } else { printk( "PASS[%d]: ", source ); } va_start( ap, fmt ); a000be20: e58d1000 str r1, [sp] <== NOT EXECUTED vprintk( fmt, ap ); a000be24: ebfff7ef bl a0009de8 <== NOT EXECUTED va_end( ap ); } a000be28: e8bd4008 pop {r3, lr} <== NOT EXECUTED a000be2c: e28dd008 add sp, sp, #8 <== NOT EXECUTED a000be30: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000b480 <_Internal_error_Occurred>: void _Internal_error_Occurred( Internal_errors_Source the_source, bool is_internal, Internal_errors_t the_error ) { a000b480: e92d4007 push {r0, r1, r2, lr} a000b484: e20160ff and r6, r1, #255 ; 0xff a000b488: e1a04000 mov r4, r0 Internal_errors_Source source, bool is_internal, Internal_errors_t error ) { User_extensions_Fatal_context ctx = { source, is_internal, error }; a000b48c: e58d0000 str r0, [sp] _User_extensions_Iterate( &ctx, _User_extensions_Fatal_visitor ); a000b490: e59f1040 ldr r1, [pc, #64] ; a000b4d8 <_Internal_error_Occurred+0x58> a000b494: e1a0000d mov r0, sp a000b498: e1a05002 mov r5, r2 Internal_errors_Source source, bool is_internal, Internal_errors_t error ) { User_extensions_Fatal_context ctx = { source, is_internal, error }; a000b49c: e58d2008 str r2, [sp, #8] a000b4a0: e5cd6004 strb r6, [sp, #4] _User_extensions_Iterate( &ctx, _User_extensions_Fatal_visitor ); a000b4a4: eb000771 bl a000d270 <_User_extensions_Iterate> _User_extensions_Fatal( the_source, is_internal, the_error ); _Internal_errors_What_happened.the_source = the_source; a000b4a8: e59f302c ldr r3, [pc, #44] ; a000b4dc <_Internal_error_Occurred+0x5c><== NOT EXECUTED RTEMS_INLINE_ROUTINE void _System_state_Set ( System_state_Codes state ) { _System_state_Current = state; a000b4ac: e3a02005 mov r2, #5 <== NOT EXECUTED a000b4b0: e5834000 str r4, [r3] <== NOT EXECUTED _Internal_errors_What_happened.is_internal = is_internal; a000b4b4: e5c36004 strb r6, [r3, #4] <== NOT EXECUTED _Internal_errors_What_happened.the_error = the_error; a000b4b8: e5835008 str r5, [r3, #8] <== NOT EXECUTED a000b4bc: e59f301c ldr r3, [pc, #28] ; a000b4e0 <_Internal_error_Occurred+0x60><== NOT EXECUTED a000b4c0: e5832000 str r2, [r3] <== NOT EXECUTED uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000b4c4: e10f2000 mrs r2, CPSR <== NOT EXECUTED a000b4c8: e3823080 orr r3, r2, #128 ; 0x80 <== NOT EXECUTED a000b4cc: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED _System_state_Set( SYSTEM_STATE_FAILED ); _CPU_Fatal_halt( the_error ); a000b4d0: e1a00005 mov r0, r5 <== NOT EXECUTED a000b4d4: eafffffe b a000b4d4 <_Internal_error_Occurred+0x54> <== NOT EXECUTED =============================================================================== a000b8c0 <_Objects_Get_information>: Objects_Information *_Objects_Get_information( Objects_APIs the_api, uint16_t the_class ) { a000b8c0: e1a01801 lsl r1, r1, #16 a000b8c4: e92d4030 push {r4, r5, lr} Objects_Information *info; int the_class_api_maximum; if ( !the_class ) a000b8c8: e1b05821 lsrs r5, r1, #16 Objects_Information *_Objects_Get_information( Objects_APIs the_api, uint16_t the_class ) { a000b8cc: e1a04000 mov r4, r0 Objects_Information *info; int the_class_api_maximum; if ( !the_class ) a000b8d0: 0a00000f beq a000b914 <_Objects_Get_information+0x54> /* * 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 ); a000b8d4: eb001167 bl a000fe78 <_Objects_API_maximum_class> if ( the_class_api_maximum == 0 ) a000b8d8: e3500000 cmp r0, #0 a000b8dc: 0a00000f beq a000b920 <_Objects_Get_information+0x60> return NULL; if ( the_class > (uint32_t) the_class_api_maximum ) a000b8e0: e1550000 cmp r5, r0 a000b8e4: 8a00000c bhi a000b91c <_Objects_Get_information+0x5c> return NULL; if ( !_Objects_Information_table[ the_api ] ) a000b8e8: e59f3034 ldr r3, [pc, #52] ; a000b924 <_Objects_Get_information+0x64> a000b8ec: e7930104 ldr r0, [r3, r4, lsl #2] a000b8f0: e3500000 cmp r0, #0 a000b8f4: 0a000009 beq a000b920 <_Objects_Get_information+0x60> return NULL; info = _Objects_Information_table[ the_api ][ the_class ]; a000b8f8: e7900105 ldr r0, [r0, r5, lsl #2] if ( !info ) a000b8fc: e3500000 cmp r0, #0 a000b900: 0a000006 beq a000b920 <_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 ) a000b904: e1d031b0 ldrh r3, [r0, #16] return NULL; a000b908: e3530000 cmp r3, #0 a000b90c: 03a00000 moveq r0, #0 a000b910: e8bd8030 pop {r4, r5, pc} { Objects_Information *info; int the_class_api_maximum; if ( !the_class ) return NULL; a000b914: e1a00005 mov r0, r5 <== NOT EXECUTED a000b918: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED 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 ) return NULL; a000b91c: e3a00000 mov r0, #0 <== NOT EXECUTED if ( info->maximum == 0 ) return NULL; #endif return info; } a000b920: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a000b928 <_Objects_Get_isr_disable>: { Objects_Control *the_object; uint32_t index; ISR_Level level; index = id - information->minimum_id + 1; a000b928: e590c008 ldr ip, [r0, #8] Objects_Information *information, Objects_Id id, Objects_Locations *location, ISR_Level *level_p ) { a000b92c: e92d4010 push {r4, lr} Objects_Control *the_object; uint32_t index; ISR_Level level; index = id - information->minimum_id + 1; a000b930: e26cc001 rsb ip, ip, #1 a000b934: e08c1001 add r1, ip, r1 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000b938: e10f4000 mrs r4, CPSR a000b93c: e384c080 orr ip, r4, #128 ; 0x80 a000b940: e129f00c msr CPSR_fc, ip _ISR_Disable( level ); if ( information->maximum >= index ) { a000b944: e1d0c1b0 ldrh ip, [r0, #16] a000b948: e15c0001 cmp ip, r1 a000b94c: 3a00000b bcc a000b980 <_Objects_Get_isr_disable+0x58> if ( (the_object = information->local_table[ index ]) != NULL ) { a000b950: e590001c ldr r0, [r0, #28] a000b954: e7900101 ldr r0, [r0, r1, lsl #2] a000b958: e3500000 cmp r0, #0 a000b95c: 0a000003 beq a000b970 <_Objects_Get_isr_disable+0x48> *location = OBJECTS_LOCAL; a000b960: e3a01000 mov r1, #0 a000b964: e5821000 str r1, [r2] *level_p = level; a000b968: e5834000 str r4, [r3] return the_object; a000b96c: e8bd8010 pop {r4, pc} static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000b970: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED } _ISR_Enable( level ); *location = OBJECTS_ERROR; a000b974: e3a03001 mov r3, #1 <== NOT EXECUTED a000b978: e5823000 str r3, [r2] <== NOT EXECUTED return NULL; a000b97c: e8bd8010 pop {r4, pc} <== NOT EXECUTED a000b980: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED } _ISR_Enable( level ); *location = OBJECTS_ERROR; a000b984: e3a03001 mov r3, #1 <== NOT EXECUTED a000b988: 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; a000b98c: e3a00000 mov r0, #0 <== NOT EXECUTED #endif } a000b990: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000f1b4 <_Objects_Id_to_name>: Objects_Name_or_id_lookup_errors _Objects_Id_to_name ( Objects_Id id, Objects_Name *name ) { a000f1b4: e92d4031 push {r0, r4, r5, lr} a000f1b8: e1a05001 mov r5, r1 /* * Caller is trusted for name != NULL. */ tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id; a000f1bc: e2501000 subs r1, r0, #0 a000f1c0: 059f3078 ldreq r3, [pc, #120] ; a000f240 <_Objects_Id_to_name+0x8c> a000f1c4: 05933008 ldreq r3, [r3, #8] a000f1c8: 05931008 ldreq r1, [r3, #8] a000f1cc: e1a03c21 lsr r3, r1, #24 a000f1d0: 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 ) a000f1d4: e2432001 sub r2, r3, #1 a000f1d8: e3520002 cmp r2, #2 a000f1dc: 8a000010 bhi a000f224 <_Objects_Id_to_name+0x70> a000f1e0: ea000011 b a000f22c <_Objects_Id_to_name+0x78> */ RTEMS_INLINE_ROUTINE uint32_t _Objects_Get_class( Objects_Id id ) { return (uint32_t) a000f1e4: 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 ]; a000f1e8: e7930102 ldr r0, [r3, r2, lsl #2] if ( !information ) a000f1ec: e3500000 cmp r0, #0 a000f1f0: 0a00000b beq a000f224 <_Objects_Id_to_name+0x70> return OBJECTS_INVALID_ID; #if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES) if ( information->is_string ) a000f1f4: e5d04038 ldrb r4, [r0, #56] ; 0x38 a000f1f8: e3540000 cmp r4, #0 a000f1fc: 1a000008 bne a000f224 <_Objects_Id_to_name+0x70> return OBJECTS_INVALID_ID; #endif the_object = _Objects_Get( information, tmpId, &ignored_location ); a000f200: e1a0200d mov r2, sp a000f204: ebffffd0 bl a000f14c <_Objects_Get> if ( !the_object ) a000f208: e3500000 cmp r0, #0 a000f20c: 0a000004 beq a000f224 <_Objects_Id_to_name+0x70> return OBJECTS_INVALID_ID; *name = the_object->name; a000f210: e590300c ldr r3, [r0, #12] a000f214: e5853000 str r3, [r5] _Thread_Enable_dispatch(); a000f218: eb000383 bl a001002c <_Thread_Enable_dispatch> return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL; a000f21c: e1a00004 mov r0, r4 a000f220: ea000000 b a000f228 <_Objects_Id_to_name+0x74> 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; a000f224: e3a00003 mov r0, #3 return OBJECTS_INVALID_ID; *name = the_object->name; _Thread_Enable_dispatch(); return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL; } a000f228: 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 ] ) a000f22c: e59f2010 ldr r2, [pc, #16] ; a000f244 <_Objects_Id_to_name+0x90> a000f230: e7923103 ldr r3, [r2, r3, lsl #2] a000f234: e3530000 cmp r3, #0 a000f238: 1affffe9 bne a000f1e4 <_Objects_Id_to_name+0x30> a000f23c: eafffff8 b a000f224 <_Objects_Id_to_name+0x70> <== NOT EXECUTED =============================================================================== a000baf8 <_Objects_Name_to_id_u32>: Objects_Name name_for_mp; #endif /* ASSERT: information->is_string == false */ if ( !id ) a000baf8: e3530000 cmp r3, #0 Objects_Information *information, uint32_t name, uint32_t node, Objects_Id *id ) { a000bafc: e92d4030 push {r4, r5, lr} Objects_Name name_for_mp; #endif /* ASSERT: information->is_string == false */ if ( !id ) a000bb00: 0a00001a beq a000bb70 <_Objects_Name_to_id_u32+0x78> return OBJECTS_INVALID_ADDRESS; if ( name == 0 ) a000bb04: e3510000 cmp r1, #0 a000bb08: 0a00001a beq a000bb78 <_Objects_Name_to_id_u32+0x80> return OBJECTS_INVALID_NAME; search_local_node = false; if ( information->maximum != 0 && a000bb0c: e1d041b0 ldrh r4, [r0, #16] a000bb10: e3540000 cmp r4, #0 a000bb14: 0a000019 beq a000bb80 <_Objects_Name_to_id_u32+0x88> a000bb18: e3720106 cmn r2, #-2147483647 ; 0x80000001 a000bb1c: 13520000 cmpne r2, #0 a000bb20: 03a02001 moveq r2, #1 a000bb24: 0a00000e beq a000bb64 <_Objects_Name_to_id_u32+0x6c> (node == OBJECTS_SEARCH_ALL_NODES || node == OBJECTS_SEARCH_LOCAL_NODE || a000bb28: e3520001 cmp r2, #1 a000bb2c: 1a000011 bne a000bb78 <_Objects_Name_to_id_u32+0x80> a000bb30: ea00000b b a000bb64 <_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 ]; a000bb34: e590c01c ldr ip, [r0, #28] a000bb38: e79cc102 ldr ip, [ip, r2, lsl #2] if ( !the_object ) a000bb3c: e35c0000 cmp ip, #0 a000bb40: 0a000006 beq a000bb60 <_Objects_Name_to_id_u32+0x68> continue; if ( name == the_object->name.name_u32 ) { a000bb44: e59c500c ldr r5, [ip, #12] a000bb48: e1510005 cmp r1, r5 a000bb4c: 1a000003 bne a000bb60 <_Objects_Name_to_id_u32+0x68> *id = the_object->id; a000bb50: e59c2008 ldr r2, [ip, #8] return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL; a000bb54: 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; a000bb58: e5832000 str r2, [r3] return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL; a000bb5c: 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++ ) { a000bb60: e2822001 add r2, r2, #1 a000bb64: e1520004 cmp r2, r4 a000bb68: 9afffff1 bls a000bb34 <_Objects_Name_to_id_u32+0x3c> a000bb6c: ea000001 b a000bb78 <_Objects_Name_to_id_u32+0x80> <== NOT EXECUTED #endif /* ASSERT: information->is_string == false */ if ( !id ) return OBJECTS_INVALID_ADDRESS; a000bb70: e3a00002 mov r0, #2 <== NOT EXECUTED a000bb74: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED if ( name == 0 ) return OBJECTS_INVALID_NAME; a000bb78: e3a00001 mov r0, #1 <== NOT EXECUTED a000bb7c: 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; a000bb80: e3a00001 mov r0, #1 #endif } a000bb84: e8bd8030 pop {r4, r5, pc} =============================================================================== a000bcac <_Objects_Set_name>: bool _Objects_Set_name( Objects_Information *information, Objects_Control *the_object, const char *name ) { a000bcac: e92d41f0 push {r4, r5, r6, r7, r8, lr} a000bcb0: e1a05000 mov r5, r0 a000bcb4: e1a06001 mov r6, r1 size_t length; const char *s; s = name; length = strnlen( name, information->name_length ); a000bcb8: e1a00002 mov r0, r2 a000bcbc: e1d513ba ldrh r1, [r5, #58] ; 0x3a bool _Objects_Set_name( Objects_Information *information, Objects_Control *the_object, const char *name ) { a000bcc0: e1a08002 mov r8, r2 size_t length; const char *s; s = name; length = strnlen( name, information->name_length ); a000bcc4: eb001eeb bl a0013878 #if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES) if ( information->is_string ) { a000bcc8: e5d53038 ldrb r3, [r5, #56] ; 0x38 { size_t length; const char *s; s = name; length = strnlen( name, information->name_length ); a000bccc: e1a04000 mov r4, r0 #if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES) if ( information->is_string ) { a000bcd0: e3530000 cmp r3, #0 a000bcd4: 0a00000e beq a000bd14 <_Objects_Set_name+0x68> char *d; d = _Workspace_Allocate( length + 1 ); a000bcd8: e2800001 add r0, r0, #1 a000bcdc: eb0006fe bl a000d8dc <_Workspace_Allocate> if ( !d ) a000bce0: e2505000 subs r5, r0, #0 a000bce4: 0a00001d beq a000bd60 <_Objects_Set_name+0xb4> return false; _Workspace_Free( (void *)the_object->name.name_p ); a000bce8: e596000c ldr r0, [r6, #12] the_object->name.name_p = NULL; a000bcec: e3a07000 mov r7, #0 d = _Workspace_Allocate( length + 1 ); if ( !d ) return false; _Workspace_Free( (void *)the_object->name.name_p ); a000bcf0: eb0006ff bl a000d8f4 <_Workspace_Free> the_object->name.name_p = NULL; a000bcf4: e586700c str r7, [r6, #12] strncpy( d, name, length ); a000bcf8: e1a00005 mov r0, r5 a000bcfc: e1a01008 mov r1, r8 a000bd00: e1a02004 mov r2, r4 a000bd04: eb001ea6 bl a00137a4 d[length] = '\0'; a000bd08: e7c57004 strb r7, [r5, r4] the_object->name.name_p = d; a000bd0c: e586500c str r5, [r6, #12] a000bd10: ea000010 b a000bd58 <_Objects_Set_name+0xac> } else #endif { the_object->name.name_u32 = _Objects_Build_name( a000bd14: e3500001 cmp r0, #1 <== NOT EXECUTED a000bd18: 85d83001 ldrbhi r3, [r8, #1] <== NOT EXECUTED a000bd1c: e5d82000 ldrb r2, [r8] <== NOT EXECUTED a000bd20: 93a03602 movls r3, #2097152 ; 0x200000 <== NOT EXECUTED a000bd24: 81a03803 lslhi r3, r3, #16 <== NOT EXECUTED a000bd28: e1a02c02 lsl r2, r2, #24 <== NOT EXECUTED a000bd2c: e3500002 cmp r0, #2 <== NOT EXECUTED a000bd30: e1832002 orr r2, r3, r2 <== NOT EXECUTED a000bd34: 85d83002 ldrbhi r3, [r8, #2] <== NOT EXECUTED a000bd38: 93a03a02 movls r3, #8192 ; 0x2000 <== NOT EXECUTED a000bd3c: 81a03403 lslhi r3, r3, #8 <== NOT EXECUTED a000bd40: e3500003 cmp r0, #3 <== NOT EXECUTED a000bd44: e1822003 orr r2, r2, r3 <== NOT EXECUTED a000bd48: 85d83003 ldrbhi r3, [r8, #3] <== NOT EXECUTED a000bd4c: 93a03020 movls r3, #32 <== NOT EXECUTED a000bd50: e1823003 orr r3, r2, r3 <== NOT EXECUTED a000bd54: e586300c str r3, [r6, #12] <== NOT EXECUTED ((3 < length) ? s[ 3 ] : ' ') ); } return true; a000bd58: e3a00001 mov r0, #1 a000bd5c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} if ( information->is_string ) { char *d; d = _Workspace_Allocate( length + 1 ); if ( !d ) return false; a000bd60: e1a00005 mov r0, r5 ); } return true; } a000bd64: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a000ac54 <_POSIX_Condition_variables_Get>: POSIX_Condition_variables_Control *_POSIX_Condition_variables_Get ( pthread_cond_t *cond, Objects_Locations *location ) { a000ac54: e92d4030 push {r4, r5, lr} int status; if ( !cond ) { a000ac58: e2505000 subs r5, r0, #0 POSIX_Condition_variables_Control *_POSIX_Condition_variables_Get ( pthread_cond_t *cond, Objects_Locations *location ) { a000ac5c: e1a04001 mov r4, r1 int status; if ( !cond ) { a000ac60: 1a000003 bne a000ac74 <_POSIX_Condition_variables_Get+0x20> *location = OBJECTS_ERROR; a000ac64: e3a03001 mov r3, #1 <== NOT EXECUTED a000ac68: e5813000 str r3, [r1] <== NOT EXECUTED return (POSIX_Condition_variables_Control *) 0; a000ac6c: e1a00005 mov r0, r5 <== NOT EXECUTED a000ac70: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED } if ( *cond == PTHREAD_COND_INITIALIZER ) { a000ac74: e5953000 ldr r3, [r5] a000ac78: e3730001 cmn r3, #1 a000ac7c: 1a000007 bne a000aca0 <_POSIX_Condition_variables_Get+0x4c> /* * Do an "auto-create" here. */ status = pthread_cond_init( cond, 0 ); a000ac80: e3a01000 mov r1, #0 a000ac84: eb00000b bl a000acb8 if ( status ) { a000ac88: e3500000 cmp r0, #0 a000ac8c: 0a000003 beq a000aca0 <_POSIX_Condition_variables_Get+0x4c> *location = OBJECTS_ERROR; a000ac90: e3a03001 mov r3, #1 a000ac94: e5843000 str r3, [r4] return (POSIX_Condition_variables_Control *) 0; a000ac98: e3a00000 mov r0, #0 a000ac9c: e8bd8030 pop {r4, r5, pc} } /* * Now call Objects_Get() */ return (POSIX_Condition_variables_Control *)_Objects_Get( a000aca0: e59f000c ldr r0, [pc, #12] ; a000acb4 <_POSIX_Condition_variables_Get+0x60> a000aca4: e5951000 ldr r1, [r5] a000aca8: e1a02004 mov r2, r4 &_POSIX_Condition_variables_Information, (Objects_Id) *cond, location ); } a000acac: e8bd4030 pop {r4, r5, lr} } /* * Now call Objects_Get() */ return (POSIX_Condition_variables_Control *)_Objects_Get( a000acb0: ea000ae4 b a000d848 <_Objects_Get> =============================================================================== a000ae2c <_POSIX_Condition_variables_Wait_support>: pthread_cond_t *cond, pthread_mutex_t *mutex, Watchdog_Interval timeout, bool already_timedout ) { a000ae2c: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr} a000ae30: e1a05000 mov r5, r0 a000ae34: 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 ) ) { a000ae38: e1a00001 mov r0, r1 a000ae3c: e1a0100d mov r1, sp pthread_cond_t *cond, pthread_mutex_t *mutex, Watchdog_Interval timeout, bool already_timedout ) { a000ae40: e1a07002 mov r7, r2 a000ae44: 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 ) ) { a000ae48: eb000055 bl a000afa4 <_POSIX_Mutex_Get> a000ae4c: e3500000 cmp r0, #0 a000ae50: 0a000031 beq a000af1c <_POSIX_Condition_variables_Wait_support+0xf0> * * This routine decrements the thread dispatch level. */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000ae54: e59f30cc ldr r3, [pc, #204] ; a000af28 <_POSIX_Condition_variables_Wait_support+0xfc> return EINVAL; } _Thread_Unnest_dispatch(); the_cond = _POSIX_Condition_variables_Get( cond, &location ); a000ae58: e1a00005 mov r0, r5 a000ae5c: e1a0100d mov r1, sp a000ae60: e5932000 ldr r2, [r3] --level; a000ae64: e2422001 sub r2, r2, #1 _Thread_Dispatch_disable_level = level; a000ae68: e5832000 str r2, [r3] a000ae6c: ebffff78 bl a000ac54 <_POSIX_Condition_variables_Get> switch ( location ) { a000ae70: e59d3000 ldr r3, [sp] return EINVAL; } _Thread_Unnest_dispatch(); the_cond = _POSIX_Condition_variables_Get( cond, &location ); a000ae74: e1a0a000 mov sl, r0 switch ( location ) { a000ae78: e3530000 cmp r3, #0 a000ae7c: 1a000026 bne a000af1c <_POSIX_Condition_variables_Wait_support+0xf0> case OBJECTS_LOCAL: if ( the_cond->Mutex && ( the_cond->Mutex != *mutex ) ) { a000ae80: e5903014 ldr r3, [r0, #20] a000ae84: e3530000 cmp r3, #0 a000ae88: 0a000004 beq a000aea0 <_POSIX_Condition_variables_Wait_support+0x74> a000ae8c: e5942000 ldr r2, [r4] <== NOT EXECUTED a000ae90: e1530002 cmp r3, r2 <== NOT EXECUTED a000ae94: 0a000001 beq a000aea0 <_POSIX_Condition_variables_Wait_support+0x74><== NOT EXECUTED _Thread_Enable_dispatch(); a000ae98: eb000dd9 bl a000e604 <_Thread_Enable_dispatch> <== NOT EXECUTED a000ae9c: ea00001e b a000af1c <_POSIX_Condition_variables_Wait_support+0xf0><== NOT EXECUTED return EINVAL; } (void) pthread_mutex_unlock( mutex ); a000aea0: e1a00004 mov r0, r4 a000aea4: eb0000e3 bl a000b238 _Thread_Enable_dispatch(); return EINVAL; } */ if ( !already_timedout ) { a000aea8: e3580000 cmp r8, #0 a000aeac: 1a000013 bne a000af00 <_POSIX_Condition_variables_Wait_support+0xd4> the_cond->Mutex = *mutex; a000aeb0: e5943000 ldr r3, [r4] _Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0; a000aeb4: e59f6070 ldr r6, [pc, #112] ; a000af2c <_POSIX_Condition_variables_Wait_support+0x100> _Thread_Executing->Wait.queue = &the_cond->Wait_queue; a000aeb8: e28a0018 add r0, sl, #24 return EINVAL; } */ if ( !already_timedout ) { the_cond->Mutex = *mutex; a000aebc: 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; a000aec0: e3a03001 mov r3, #1 a000aec4: e58a3048 str r3, [sl, #72] ; 0x48 _Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0; a000aec8: e5963008 ldr r3, [r6, #8] _Thread_Executing->Wait.queue = &the_cond->Wait_queue; _Thread_Executing->Wait.id = *cond; _Thread_queue_Enqueue( &the_cond->Wait_queue, timeout ); a000aecc: 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; a000aed0: e5838034 str r8, [r3, #52] ; 0x34 _Thread_Executing->Wait.queue = &the_cond->Wait_queue; _Thread_Executing->Wait.id = *cond; a000aed4: 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; a000aed8: e5830044 str r0, [r3, #68] ; 0x44 _Thread_Executing->Wait.id = *cond; a000aedc: e5832020 str r2, [r3, #32] _Thread_queue_Enqueue( &the_cond->Wait_queue, timeout ); a000aee0: e59f2048 ldr r2, [pc, #72] ; a000af30 <_POSIX_Condition_variables_Wait_support+0x104> a000aee4: eb000ef1 bl a000eab0 <_Thread_queue_Enqueue_with_handler> _Thread_Enable_dispatch(); a000aee8: eb000dc5 bl a000e604 <_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; a000aeec: e5963008 ldr r3, [r6, #8] <== NOT EXECUTED a000aef0: e5935034 ldr r5, [r3, #52] ; 0x34 <== NOT EXECUTED if ( status == EINTR ) status = 0; a000aef4: e3550004 cmp r5, #4 <== NOT EXECUTED a000aef8: 03a05000 moveq r5, #0 <== NOT EXECUTED a000aefc: ea000001 b a000af08 <_POSIX_Condition_variables_Wait_support+0xdc><== NOT EXECUTED } else { _Thread_Enable_dispatch(); a000af00: eb000dbf bl a000e604 <_Thread_Enable_dispatch> <== NOT EXECUTED status = ETIMEDOUT; a000af04: e3a05074 mov r5, #116 ; 0x74 <== NOT EXECUTED /* * When we get here the dispatch disable level is 0. */ mutex_status = pthread_mutex_lock( mutex ); a000af08: e1a00004 mov r0, r4 <== NOT EXECUTED a000af0c: eb0000aa bl a000b1bc <== NOT EXECUTED if ( mutex_status ) return EINVAL; a000af10: e3500000 cmp r0, #0 <== NOT EXECUTED a000af14: 13a05016 movne r5, #22 <== NOT EXECUTED a000af18: ea000000 b a000af20 <_POSIX_Condition_variables_Wait_support+0xf4><== NOT EXECUTED #endif case OBJECTS_ERROR: break; } return EINVAL; a000af1c: e3a05016 mov r5, #22 <== NOT EXECUTED } a000af20: e1a00005 mov r0, r5 <== NOT EXECUTED a000af24: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED =============================================================================== a00111f0 <_POSIX_Keys_Run_destructors>: */ void _POSIX_Keys_Run_destructors( Thread_Control *thread ) { a00111f0: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} Objects_Maximum thread_index = _Objects_Get_index( thread->Object.id ); a00111f4: e5906008 ldr r6, [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; a00111f8: e59f5080 ldr r5, [pc, #128] ; a0011280 <_POSIX_Keys_Run_destructors+0x90> a00111fc: e1a07c26 lsr r7, r6, #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 ]; a0011200: e1a06806 lsl r6, r6, #16 a0011204: e2077007 and r7, r7, #7 a0011208: e1a06726 lsr r6, r6, #14 Objects_Maximum index = 0; Objects_Maximum max = _POSIX_Keys_Information.maximum; done = true; for ( index = 1 ; index <= max ; ++index ) { a001120c: 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; a0011210: e1d5a1b0 ldrh sl, [r5, #16] done = true; a0011214: e1a02004 mov r2, r4 if ( key != NULL && key->destructor != NULL ) { void *value = key->Values [ thread_api ][ thread_index ]; if ( value != NULL ) { key->Values [ thread_api ][ thread_index ] = NULL; a0011218: e3a08000 mov r8, #0 Objects_Maximum index = 0; Objects_Maximum max = _POSIX_Keys_Information.maximum; done = true; for ( index = 1 ; index <= max ; ++index ) { a001121c: ea000012 b a001126c <_POSIX_Keys_Run_destructors+0x7c> POSIX_Keys_Control *key = (POSIX_Keys_Control *) a0011220: e595301c ldr r3, [r5, #28] a0011224: e7933104 ldr r3, [r3, r4, lsl #2] _POSIX_Keys_Information.local_table [ index ]; if ( key != NULL && key->destructor != NULL ) { a0011228: e3530000 cmp r3, #0 a001122c: 0a00000b beq a0011260 <_POSIX_Keys_Run_destructors+0x70> a0011230: e5931010 ldr r1, [r3, #16] a0011234: e3510000 cmp r1, #0 a0011238: 0a000008 beq a0011260 <_POSIX_Keys_Run_destructors+0x70> void *value = key->Values [ thread_api ][ thread_index ]; a001123c: e2871005 add r1, r7, #5 <== NOT EXECUTED a0011240: e7931101 ldr r1, [r3, r1, lsl #2] <== NOT EXECUTED a0011244: e7910006 ldr r0, [r1, r6] <== NOT EXECUTED if ( value != NULL ) { a0011248: e3500000 cmp r0, #0 <== NOT EXECUTED a001124c: 0a000003 beq a0011260 <_POSIX_Keys_Run_destructors+0x70> <== NOT EXECUTED key->Values [ thread_api ][ thread_index ] = NULL; a0011250: e7818006 str r8, [r1, r6] <== NOT EXECUTED (*key->destructor)( value ); a0011254: e5933010 ldr r3, [r3, #16] <== NOT EXECUTED a0011258: e12fff33 blx r3 <== NOT EXECUTED done = false; a001125c: e3a02000 mov r2, #0 <== NOT EXECUTED Objects_Maximum index = 0; Objects_Maximum max = _POSIX_Keys_Information.maximum; done = true; for ( index = 1 ; index <= max ; ++index ) { a0011260: e2844001 add r4, r4, #1 a0011264: e1a04804 lsl r4, r4, #16 a0011268: e1a04824 lsr r4, r4, #16 a001126c: e154000a cmp r4, sl a0011270: 9affffea bls a0011220 <_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 ) { a0011274: e3520000 cmp r2, #0 a0011278: 0affffe3 beq a001120c <_POSIX_Keys_Run_destructors+0x1c> done = false; } } } } } a001127c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} =============================================================================== a0010998 <_POSIX_Message_queue_Create_support>: size_t name_len, int pshared, struct mq_attr *attr_ptr, POSIX_Message_queue_Control **message_queue ) { a0010998: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} a001099c: e1a09002 mov r9, r2 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a00109a0: e59f2124 ldr r2, [pc, #292] ; a0010acc <_POSIX_Message_queue_Create_support+0x134> a00109a4: e1a07001 mov r7, r1 a00109a8: e1a06000 mov r6, r0 a00109ac: e5921000 ldr r1, [r2] ++level; a00109b0: e2811001 add r1, r1, #1 _Thread_Dispatch_disable_level = level; a00109b4: e5821000 str r1, [r2] * 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 ) { a00109b8: e3530000 cmp r3, #0 a00109bc: 0a000009 beq a00109e8 <_POSIX_Message_queue_Create_support+0x50> attr.mq_maxmsg = 10; attr.mq_msgsize = 16; } else { if ( attr_ptr->mq_maxmsg <= 0 ){ a00109c0: e593a004 ldr sl, [r3, #4] a00109c4: e35a0000 cmp sl, #0 a00109c8: da000002 ble a00109d8 <_POSIX_Message_queue_Create_support+0x40> _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( EINVAL ); } if ( attr_ptr->mq_msgsize <= 0 ){ a00109cc: e5938008 ldr r8, [r3, #8] a00109d0: e3580000 cmp r8, #0 a00109d4: ca000005 bgt a00109f0 <_POSIX_Message_queue_Create_support+0x58> _Thread_Enable_dispatch(); a00109d8: ebfff667 bl a000e37c <_Thread_Enable_dispatch> rtems_set_errno_and_return_minus_one( EINVAL ); a00109dc: eb000b49 bl a0013708 <__errno> a00109e0: e3a03016 mov r3, #22 a00109e4: ea00002c b a0010a9c <_POSIX_Message_queue_Create_support+0x104> * 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; a00109e8: 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; a00109ec: e3a0a00a mov sl, #10 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control *_POSIX_Message_queue_Allocate( void ) { return (POSIX_Message_queue_Control *) a00109f0: e59f50d8 ldr r5, [pc, #216] ; a0010ad0 <_POSIX_Message_queue_Create_support+0x138> a00109f4: e1a00005 mov r0, r5 a00109f8: ebfff190 bl a000d040 <_Objects_Allocate> attr = *attr_ptr; } the_mq = _POSIX_Message_queue_Allocate(); if ( !the_mq ) { a00109fc: e2504000 subs r4, r0, #0 a0010a00: 1a000003 bne a0010a14 <_POSIX_Message_queue_Create_support+0x7c> _Thread_Enable_dispatch(); a0010a04: ebfff65c bl a000e37c <_Thread_Enable_dispatch> rtems_set_errno_and_return_minus_one( ENFILE ); a0010a08: eb000b3e bl a0013708 <__errno> a0010a0c: e3a03017 mov r3, #23 a0010a10: ea000021 b a0010a9c <_POSIX_Message_queue_Create_support+0x104> /* * Make a copy of the user's string for name just in case it was * dynamically constructed. */ name = _Workspace_String_duplicate( name_arg, name_len ); a0010a14: e1a01007 mov r1, r7 a0010a18: e1a00006 mov r0, r6 a0010a1c: eb0005d5 bl a0012178 <_Workspace_String_duplicate> if ( !name ) { a0010a20: e2507000 subs r7, r0, #0 a0010a24: 1a000006 bne a0010a44 <_POSIX_Message_queue_Create_support+0xac> RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Free ( POSIX_Message_queue_Control *the_mq ) { _Objects_Free( &_POSIX_Message_queue_Information, &the_mq->Object ); a0010a28: e1a00005 mov r0, r5 a0010a2c: e1a01004 mov r1, r4 a0010a30: ebfff251 bl a000d37c <_Objects_Free> _POSIX_Message_queue_Free( the_mq ); _Thread_Enable_dispatch(); a0010a34: ebfff650 bl a000e37c <_Thread_Enable_dispatch> rtems_set_errno_and_return_minus_one( ENOMEM ); a0010a38: eb000b32 bl a0013708 <__errno> a0010a3c: e3a0300c mov r3, #12 a0010a40: ea000015 b a0010a9c <_POSIX_Message_queue_Create_support+0x104> } the_mq->process_shared = pshared; the_mq->named = true; a0010a44: e3a03001 mov r3, #1 * * 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; a0010a48: e3a06000 mov r6, #0 _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( ENOMEM ); } the_mq->process_shared = pshared; the_mq->named = true; a0010a4c: e5c43014 strb r3, [r4, #20] the_mq->open_count = 1; a0010a50: e5843018 str r3, [r4, #24] the_mq->linked = true; a0010a54: e5c43015 strb r3, [r4, #21] _POSIX_Message_queue_Free( the_mq ); _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( ENOMEM ); } the_mq->process_shared = pshared; a0010a58: e5849010 str r9, [r4, #16] * * 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; a0010a5c: e584605c str r6, [r4, #92] ; 0x5c if ( !_CORE_message_queue_Initialize( a0010a60: e284001c add r0, r4, #28 a0010a64: e284105c add r1, r4, #92 ; 0x5c a0010a68: e1a0200a mov r2, sl a0010a6c: e1a03008 mov r3, r8 a0010a70: eb0002f8 bl a0011658 <_CORE_message_queue_Initialize> a0010a74: e1500006 cmp r0, r6 a0010a78: 1a00000a bne a0010aa8 <_POSIX_Message_queue_Create_support+0x110> a0010a7c: e1a01004 mov r1, r4 <== NOT EXECUTED a0010a80: e1a00005 mov r0, r5 <== NOT EXECUTED a0010a84: ebfff23c bl a000d37c <_Objects_Free> <== NOT EXECUTED attr.mq_maxmsg, attr.mq_msgsize ) ) { _POSIX_Message_queue_Free( the_mq ); _Workspace_Free(name); a0010a88: e1a00007 mov r0, r7 <== NOT EXECUTED a0010a8c: ebfffa30 bl a000f354 <_Workspace_Free> <== NOT EXECUTED _Thread_Enable_dispatch(); a0010a90: ebfff639 bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSPC ); a0010a94: eb000b1b bl a0013708 <__errno> <== NOT EXECUTED a0010a98: e3a0301c mov r3, #28 <== NOT EXECUTED a0010a9c: e5803000 str r3, [r0] a0010aa0: e3e00000 mvn r0, #0 a0010aa4: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a0010aa8: e595301c ldr r3, [r5, #28] Objects_Information *information, Objects_Control *the_object, const char *name ) { _Objects_Set_local_object( a0010aac: e1d420b8 ldrh r2, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a0010ab0: e7834102 str r4, [r3, r2, lsl #2] &_POSIX_Message_queue_Information, &the_mq->Object, name ); *message_queue = the_mq; a0010ab4: e59d3020 ldr r3, [sp, #32] the_object ); #if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES) /* ASSERT: information->is_string */ the_object->name.name_p = name; a0010ab8: e584700c str r7, [r4, #12] a0010abc: e5834000 str r4, [r3] _Thread_Enable_dispatch(); a0010ac0: ebfff62d bl a000e37c <_Thread_Enable_dispatch> return 0; a0010ac4: e1a00006 mov r0, r6 } a0010ac8: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== a000ef50 <_POSIX_Message_queue_Notify_handler>: */ static void _POSIX_Message_queue_Notify_handler( void *user_data ) { a000ef50: e92d4010 push {r4, lr} <== NOT EXECUTED a000ef54: e1a04000 mov r4, r0 <== NOT EXECUTED POSIX_Message_queue_Control *the_mq; the_mq = user_data; kill( getpid(), the_mq->notification.sigev_signo ); a000ef58: eb00182d bl a0015014 <== NOT EXECUTED a000ef5c: e5941094 ldr r1, [r4, #148] ; 0x94 <== NOT EXECUTED a000ef60: eb001a2f bl a0015824 <== 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; a000ef64: e3a03000 mov r3, #0 <== NOT EXECUTED a000ef68: e584307c str r3, [r4, #124] ; 0x7c <== NOT EXECUTED the_message_queue->notify_argument = the_argument; a000ef6c: e5843080 str r3, [r4, #128] ; 0x80 <== NOT EXECUTED _CORE_message_queue_Set_notify( &the_mq->Message_queue, NULL, NULL ); } a000ef70: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000f1c4 <_POSIX_Message_queue_Receive_support>: size_t msg_len, unsigned int *msg_prio, bool wait, Watchdog_Interval timeout ) { a000f1c4: e92d41ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, lr} a000f1c8: e1a05000 mov r5, r0 a000f1cc: e1a06001 mov r6, r1 a000f1d0: e1a07002 mov r7, r2 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( a000f1d4: e59f0100 ldr r0, [pc, #256] ; a000f2dc <_POSIX_Message_queue_Receive_support+0x118> a000f1d8: e1a01005 mov r1, r5 a000f1dc: e28d2008 add r2, sp, #8 a000f1e0: e1a04003 mov r4, r3 a000f1e4: e5dd8028 ldrb r8, [sp, #40] ; 0x28 a000f1e8: eb000c46 bl a0012308 <_Objects_Get> Objects_Locations location; size_t length_out; bool do_wait; the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location ); switch ( location ) { a000f1ec: e59d3008 ldr r3, [sp, #8] a000f1f0: e3530000 cmp r3, #0 a000f1f4: 1a000032 bne a000f2c4 <_POSIX_Message_queue_Receive_support+0x100> case OBJECTS_LOCAL: if ( (the_mq_fd->oflag & O_ACCMODE) == O_WRONLY ) { a000f1f8: e5903014 ldr r3, [r0, #20] a000f1fc: e2032003 and r2, r3, #3 a000f200: e3520001 cmp r2, #1 a000f204: 1a000001 bne a000f210 <_POSIX_Message_queue_Receive_support+0x4c> _Thread_Enable_dispatch(); a000f208: eb000fd1 bl a0013154 <_Thread_Enable_dispatch> <== NOT EXECUTED a000f20c: ea00002c b a000f2c4 <_POSIX_Message_queue_Receive_support+0x100><== NOT EXECUTED rtems_set_errno_and_return_minus_one( EBADF ); } the_mq = the_mq_fd->Queue; a000f210: e5900010 ldr r0, [r0, #16] if ( msg_len < the_mq->Message_queue.maximum_message_size ) { a000f214: e5902068 ldr r2, [r0, #104] ; 0x68 a000f218: e1570002 cmp r7, r2 a000f21c: 2a000003 bcs a000f230 <_POSIX_Message_queue_Receive_support+0x6c> _Thread_Enable_dispatch(); a000f220: eb000fcb bl a0013154 <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EMSGSIZE ); a000f224: eb0025dd bl a00189a0 <__errno> <== NOT EXECUTED a000f228: e3a0307a mov r3, #122 ; 0x7a <== NOT EXECUTED a000f22c: ea000026 b a000f2cc <_POSIX_Message_queue_Receive_support+0x108><== NOT EXECUTED /* * Now if something goes wrong, we return a "length" of -1 * to indicate an error. */ length_out = -1; a000f230: e3e02000 mvn r2, #0 /* * A timed receive with a bad time will do a poll regardless. */ if ( wait ) a000f234: e3580000 cmp r8, #0 /* * Now if something goes wrong, we return a "length" of -1 * to indicate an error. */ length_out = -1; a000f238: e58d200c str r2, [sp, #12] /* * A timed receive with a bad time will do a poll regardless. */ if ( wait ) a000f23c: 0a000002 beq a000f24c <_POSIX_Message_queue_Receive_support+0x88> do_wait = (the_mq_fd->oflag & O_NONBLOCK) ? false : true; a000f240: e3130901 tst r3, #16384 ; 0x4000 a000f244: 13a08000 movne r8, #0 a000f248: 03a08001 moveq r8, #1 do_wait = wait; /* * Now perform the actual message receive */ _CORE_message_queue_Seize( a000f24c: e59d302c ldr r3, [sp, #44] ; 0x2c a000f250: e280001c add r0, r0, #28 a000f254: e1a01005 mov r1, r5 a000f258: e58d3004 str r3, [sp, #4] a000f25c: e1a02006 mov r2, r6 a000f260: e28d300c add r3, sp, #12 a000f264: e58d8000 str r8, [sp] a000f268: eb000810 bl a00112b0 <_CORE_message_queue_Seize> &length_out, do_wait, timeout ); _Thread_Enable_dispatch(); a000f26c: eb000fb8 bl a0013154 <_Thread_Enable_dispatch> if (msg_prio) { a000f270: e3540000 cmp r4, #0 a000f274: e59f3064 ldr r3, [pc, #100] ; a000f2e0 <_POSIX_Message_queue_Receive_support+0x11c> a000f278: 0a000004 beq a000f290 <_POSIX_Message_queue_Receive_support+0xcc> *msg_prio = _POSIX_Message_queue_Priority_from_core( _Thread_Executing->Wait.count a000f27c: e5932008 ldr r2, [r3, #8] RTEMS_INLINE_ROUTINE unsigned int _POSIX_Message_queue_Priority_from_core( CORE_message_queue_Submit_types priority ) { /* absolute value without a library dependency */ return (unsigned int) ((priority >= 0) ? priority : -priority); a000f280: e5922024 ldr r2, [r2, #36] ; 0x24 a000f284: e3520000 cmp r2, #0 a000f288: b2622000 rsblt r2, r2, #0 timeout ); _Thread_Enable_dispatch(); if (msg_prio) { *msg_prio = _POSIX_Message_queue_Priority_from_core( a000f28c: e5842000 str r2, [r4] _Thread_Executing->Wait.count ); } if ( !_Thread_Executing->Wait.return_code ) a000f290: e5933008 ldr r3, [r3, #8] a000f294: e5933034 ldr r3, [r3, #52] ; 0x34 a000f298: e3530000 cmp r3, #0 return length_out; a000f29c: 059d000c ldreq r0, [sp, #12] *msg_prio = _POSIX_Message_queue_Priority_from_core( _Thread_Executing->Wait.count ); } if ( !_Thread_Executing->Wait.return_code ) a000f2a0: 0a00000b beq a000f2d4 <_POSIX_Message_queue_Receive_support+0x110> return length_out; rtems_set_errno_and_return_minus_one( a000f2a4: eb0025bd bl a00189a0 <__errno> <== NOT EXECUTED a000f2a8: e59f3030 ldr r3, [pc, #48] ; a000f2e0 <_POSIX_Message_queue_Receive_support+0x11c><== NOT EXECUTED a000f2ac: e1a04000 mov r4, r0 <== NOT EXECUTED a000f2b0: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED a000f2b4: e5930034 ldr r0, [r3, #52] ; 0x34 <== NOT EXECUTED a000f2b8: eb00009c bl a000f530 <_POSIX_Message_queue_Translate_core_message_queue_return_code><== NOT EXECUTED a000f2bc: e5840000 str r0, [r4] <== NOT EXECUTED a000f2c0: ea000002 b a000f2d0 <_POSIX_Message_queue_Receive_support+0x10c><== NOT EXECUTED #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EBADF ); a000f2c4: eb0025b5 bl a00189a0 <__errno> <== NOT EXECUTED a000f2c8: e3a03009 mov r3, #9 <== NOT EXECUTED a000f2cc: e5803000 str r3, [r0] <== NOT EXECUTED a000f2d0: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000f2d4: e28dd010 add sp, sp, #16 a000f2d8: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a000f2fc <_POSIX_Message_queue_Send_support>: size_t msg_len, unsigned int msg_prio, bool wait, Watchdog_Interval timeout ) { a000f2fc: 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 ) a000f300: e3530020 cmp r3, #32 size_t msg_len, unsigned int msg_prio, bool wait, Watchdog_Interval timeout ) { a000f304: e24dd014 sub sp, sp, #20 a000f308: e1a04000 mov r4, r0 a000f30c: e1a06001 mov r6, r1 a000f310: e1a05002 mov r5, r2 a000f314: e1a07003 mov r7, r3 a000f318: 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 ) a000f31c: 9a000002 bls a000f32c <_POSIX_Message_queue_Send_support+0x30> rtems_set_errno_and_return_minus_one( EINVAL ); a000f320: eb00259e bl a00189a0 <__errno> <== NOT EXECUTED a000f324: e3a03016 mov r3, #22 <== NOT EXECUTED a000f328: ea00002d b a000f3e4 <_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( a000f32c: e59f00c0 ldr r0, [pc, #192] ; a000f3f4 <_POSIX_Message_queue_Send_support+0xf8> a000f330: e1a01004 mov r1, r4 a000f334: e28d2010 add r2, sp, #16 a000f338: eb000bf2 bl a0012308 <_Objects_Get> the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location ); switch ( location ) { a000f33c: e59d3010 ldr r3, [sp, #16] a000f340: e3530000 cmp r3, #0 a000f344: 1a000024 bne a000f3dc <_POSIX_Message_queue_Send_support+0xe0> case OBJECTS_LOCAL: if ( (the_mq_fd->oflag & O_ACCMODE) == O_RDONLY ) { a000f348: e5903014 ldr r3, [r0, #20] a000f34c: e3130003 tst r3, #3 a000f350: 1a000001 bne a000f35c <_POSIX_Message_queue_Send_support+0x60> _Thread_Enable_dispatch(); a000f354: eb000f7e bl a0013154 <_Thread_Enable_dispatch> <== NOT EXECUTED a000f358: ea00001f b a000f3dc <_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 ) a000f35c: 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; a000f360: e5900010 ldr r0, [r0, #16] /* * A timed receive with a bad time will do a poll regardless. */ if ( wait ) a000f364: 0a000002 beq a000f374 <_POSIX_Message_queue_Send_support+0x78> do_wait = (the_mq_fd->oflag & O_NONBLOCK) ? false : true; a000f368: e3130901 tst r3, #16384 ; 0x4000 a000f36c: 13a08000 movne r8, #0 a000f370: 03a08001 moveq r8, #1 do_wait = wait; /* * Now perform the actual message receive */ msg_status = _CORE_message_queue_Submit( a000f374: e3a03000 mov r3, #0 a000f378: e58d3000 str r3, [sp] a000f37c: e59d3030 ldr r3, [sp, #48] ; 0x30 a000f380: e1a01006 mov r1, r6 a000f384: e1a02005 mov r2, r5 a000f388: e58d300c str r3, [sp, #12] RTEMS_INLINE_ROUTINE CORE_message_queue_Submit_types _POSIX_Message_queue_Priority_to_core( unsigned int priority ) { return (CORE_message_queue_Submit_types) priority * -1; a000f38c: e2677000 rsb r7, r7, #0 a000f390: e1a03004 mov r3, r4 a000f394: e280001c add r0, r0, #28 a000f398: e98d0180 stmib sp, {r7, r8} a000f39c: eb00080d bl a00113d8 <_CORE_message_queue_Submit> a000f3a0: e1a04000 mov r4, r0 _POSIX_Message_queue_Priority_to_core( msg_prio ), do_wait, timeout /* no timeout */ ); _Thread_Enable_dispatch(); a000f3a4: eb000f6a bl a0013154 <_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 ) a000f3a8: e3540007 cmp r4, #7 msg_status = _Thread_Executing->Wait.return_code; a000f3ac: 059f3044 ldreq r3, [pc, #68] ; a000f3f8 <_POSIX_Message_queue_Send_support+0xfc> a000f3b0: 05933008 ldreq r3, [r3, #8] a000f3b4: 05934034 ldreq r4, [r3, #52] ; 0x34 if ( !msg_status ) a000f3b8: e3540000 cmp r4, #0 return msg_status; a000f3bc: 01a00004 moveq r0, r4 */ if ( msg_status == CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT ) msg_status = _Thread_Executing->Wait.return_code; if ( !msg_status ) a000f3c0: 0a000009 beq a000f3ec <_POSIX_Message_queue_Send_support+0xf0> return msg_status; rtems_set_errno_and_return_minus_one( a000f3c4: eb002575 bl a00189a0 <__errno> <== NOT EXECUTED a000f3c8: e1a05000 mov r5, r0 <== NOT EXECUTED a000f3cc: e1a00004 mov r0, r4 <== NOT EXECUTED a000f3d0: eb000056 bl a000f530 <_POSIX_Message_queue_Translate_core_message_queue_return_code><== NOT EXECUTED a000f3d4: e5850000 str r0, [r5] <== NOT EXECUTED a000f3d8: ea000002 b a000f3e8 <_POSIX_Message_queue_Send_support+0xec><== NOT EXECUTED #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EBADF ); a000f3dc: eb00256f bl a00189a0 <__errno> <== NOT EXECUTED a000f3e0: e3a03009 mov r3, #9 <== NOT EXECUTED a000f3e4: e5803000 str r3, [r0] <== NOT EXECUTED a000f3e8: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000f3ec: e28dd014 add sp, sp, #20 a000f3f0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a000f530 <_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]; } a000f530: e59f3004 ldr r3, [pc, #4] ; a000f53c <_POSIX_Message_queue_Translate_core_message_queue_return_code+0xc><== NOT EXECUTED a000f534: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED a000f538: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000bf88 <_POSIX_Mutex_Get>: POSIX_Mutex_Control *_POSIX_Mutex_Get ( pthread_mutex_t *mutex, Objects_Locations *location ) { a000bf88: e92d4030 push {r4, r5, lr} ___POSIX_Mutex_Get_support_error_check( mutex, location ); a000bf8c: e2505000 subs r5, r0, #0 POSIX_Mutex_Control *_POSIX_Mutex_Get ( pthread_mutex_t *mutex, Objects_Locations *location ) { a000bf90: e1a04001 mov r4, r1 ___POSIX_Mutex_Get_support_error_check( mutex, location ); a000bf94: 1a000003 bne a000bfa8 <_POSIX_Mutex_Get+0x20> a000bf98: e3a03001 mov r3, #1 <== NOT EXECUTED a000bf9c: e5813000 str r3, [r1] <== NOT EXECUTED a000bfa0: e1a00005 mov r0, r5 <== NOT EXECUTED a000bfa4: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED ___POSIX_Mutex_Get_support_auto_initialization( mutex, location ); a000bfa8: e5953000 ldr r3, [r5] a000bfac: e3730001 cmn r3, #1 a000bfb0: 1a000007 bne a000bfd4 <_POSIX_Mutex_Get+0x4c> a000bfb4: e3a01000 mov r1, #0 a000bfb8: eb000039 bl a000c0a4 a000bfbc: e3500000 cmp r0, #0 a000bfc0: 0a000003 beq a000bfd4 <_POSIX_Mutex_Get+0x4c> a000bfc4: e3a03001 mov r3, #1 a000bfc8: e5843000 str r3, [r4] a000bfcc: e3a00000 mov r0, #0 a000bfd0: e8bd8030 pop {r4, r5, pc} return (POSIX_Mutex_Control *) a000bfd4: e59f000c ldr r0, [pc, #12] ; a000bfe8 <_POSIX_Mutex_Get+0x60> a000bfd8: e5951000 ldr r1, [r5] a000bfdc: e1a02004 mov r2, r4 _Objects_Get( &_POSIX_Mutex_Information, (Objects_Id) *mutex, location ); } a000bfe0: 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 *) a000bfe4: ea000aee b a000eba4 <_Objects_Get> =============================================================================== a000bfec <_POSIX_Mutex_Get_interrupt_disable>: POSIX_Mutex_Control *_POSIX_Mutex_Get_interrupt_disable ( pthread_mutex_t *mutex, Objects_Locations *location, ISR_Level *level ) { a000bfec: e92d4070 push {r4, r5, r6, lr} ___POSIX_Mutex_Get_support_error_check( mutex, location ); a000bff0: e2506000 subs r6, r0, #0 POSIX_Mutex_Control *_POSIX_Mutex_Get_interrupt_disable ( pthread_mutex_t *mutex, Objects_Locations *location, ISR_Level *level ) { a000bff4: e1a04001 mov r4, r1 a000bff8: e1a05002 mov r5, r2 ___POSIX_Mutex_Get_support_error_check( mutex, location ); a000bffc: 1a000003 bne a000c010 <_POSIX_Mutex_Get_interrupt_disable+0x24> a000c000: e3a03001 mov r3, #1 <== NOT EXECUTED a000c004: e5813000 str r3, [r1] <== NOT EXECUTED a000c008: e1a00006 mov r0, r6 <== NOT EXECUTED a000c00c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED ___POSIX_Mutex_Get_support_auto_initialization( mutex, location ); a000c010: e5963000 ldr r3, [r6] a000c014: e3730001 cmn r3, #1 a000c018: 1a000007 bne a000c03c <_POSIX_Mutex_Get_interrupt_disable+0x50> a000c01c: e3a01000 mov r1, #0 a000c020: eb00001f bl a000c0a4 a000c024: e3500000 cmp r0, #0 a000c028: 0a000003 beq a000c03c <_POSIX_Mutex_Get_interrupt_disable+0x50> a000c02c: e3a03001 mov r3, #1 a000c030: e5843000 str r3, [r4] a000c034: e3a00000 mov r0, #0 a000c038: e8bd8070 pop {r4, r5, r6, pc} return (POSIX_Mutex_Control *) _Objects_Get_isr_disable( a000c03c: e59f0010 ldr r0, [pc, #16] ; a000c054 <_POSIX_Mutex_Get_interrupt_disable+0x68> a000c040: e5961000 ldr r1, [r6] a000c044: e1a02004 mov r2, r4 a000c048: e1a03005 mov r3, r5 &_POSIX_Mutex_Information, (Objects_Id) *mutex, location, level ); } a000c04c: 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( a000c050: ea000ab8 b a000eb38 <_Objects_Get_isr_disable> =============================================================================== a000a8ac <_POSIX_Name_to_id>: Objects_Information *information, const char *name, Objects_Id *id, size_t *len ) { a000a8ac: e92d41f0 push {r4, r5, r6, r7, r8, lr} int eno = EINVAL; size_t n = 0; if ( name != NULL && name [0] != '\0' ) { a000a8b0: e2518000 subs r8, r1, #0 Objects_Information *information, const char *name, Objects_Id *id, size_t *len ) { a000a8b4: e1a04000 mov r4, r0 a000a8b8: e1a07002 mov r7, r2 a000a8bc: e1a06003 mov r6, r3 int eno = EINVAL; size_t n = 0; if ( name != NULL && name [0] != '\0' ) { a000a8c0: 0a000011 beq a000a90c <_POSIX_Name_to_id+0x60> a000a8c4: e5d85000 ldrb r5, [r8] a000a8c8: e3550000 cmp r5, #0 a000a8cc: 0a00000f beq a000a910 <_POSIX_Name_to_id+0x64> n = strnlen( name, NAME_MAX ); a000a8d0: e1a00008 mov r0, r8 a000a8d4: e3a010ff mov r1, #255 ; 0xff a000a8d8: eb0029ae bl a0014f98 if ( n < NAME_MAX ) { a000a8dc: e35000fe cmp r0, #254 ; 0xfe { int eno = EINVAL; size_t n = 0; if ( name != NULL && name [0] != '\0' ) { n = strnlen( name, NAME_MAX ); a000a8e0: e1a05000 mov r5, r0 eno = 0; } else { eno = ENOENT; } } else { eno = ENAMETOOLONG; a000a8e4: 83a0005b movhi r0, #91 ; 0x5b size_t n = 0; if ( name != NULL && name [0] != '\0' ) { n = strnlen( name, NAME_MAX ); if ( n < NAME_MAX ) { a000a8e8: 8a000009 bhi a000a914 <_POSIX_Name_to_id+0x68> Objects_Name_or_id_lookup_errors status = _Objects_Name_to_id_string( a000a8ec: e1a00004 mov r0, r4 a000a8f0: e1a01008 mov r1, r8 a000a8f4: e1a02007 mov r2, r7 a000a8f8: eb000b50 bl a000d640 <_Objects_Name_to_id_string> name, id ); if ( status == OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL ) { eno = 0; a000a8fc: e3500000 cmp r0, #0 a000a900: 13a00002 movne r0, #2 a000a904: 03a00000 moveq r0, #0 a000a908: ea000001 b a000a914 <_POSIX_Name_to_id+0x68> Objects_Id *id, size_t *len ) { int eno = EINVAL; size_t n = 0; a000a90c: e1a05008 mov r5, r8 <== NOT EXECUTED const char *name, Objects_Id *id, size_t *len ) { int eno = EINVAL; a000a910: e3a00016 mov r0, #22 <== NOT EXECUTED } else { eno = ENAMETOOLONG; } } *len = n; a000a914: e5865000 str r5, [r6] return eno; } a000a918: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a0010050 <_POSIX_Priority_Is_valid>: bool _POSIX_Priority_Is_valid( int priority ) { return ((priority >= POSIX_SCHEDULER_MINIMUM_PRIORITY) && a0010050: e3500000 cmp r0, #0 a0010054: da000005 ble a0010070 <_POSIX_Priority_Is_valid+0x20> (priority <= POSIX_SCHEDULER_MAXIMUM_PRIORITY)); a0010058: e59f3018 ldr r3, [pc, #24] ; a0010078 <_POSIX_Priority_Is_valid+0x28> a001005c: e5d33000 ldrb r3, [r3] #endif #include #include bool _POSIX_Priority_Is_valid( a0010060: e1530000 cmp r3, r0 a0010064: d3a00000 movle r0, #0 a0010068: c3a00001 movgt r0, #1 a001006c: e12fff1e bx lr int priority ) { return ((priority >= POSIX_SCHEDULER_MINIMUM_PRIORITY) && a0010070: e3a00000 mov r0, #0 <== NOT EXECUTED (priority <= POSIX_SCHEDULER_MAXIMUM_PRIORITY)); } a0010074: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a001103c <_POSIX_Semaphore_Create_support>: POSIX_Semaphore_Control *the_semaphore; CORE_semaphore_Attributes *the_sem_attr; char *name; /* Sharing semaphores among processes is not currently supported */ if (pshared != 0) a001103c: e3520000 cmp r2, #0 size_t name_len, int pshared, unsigned int value, POSIX_Semaphore_Control **the_sem ) { a0011040: e92d40f0 push {r4, r5, r6, r7, lr} a0011044: e1a04000 mov r4, r0 a0011048: e1a06001 mov r6, r1 a001104c: e1a07003 mov r7, r3 POSIX_Semaphore_Control *the_semaphore; CORE_semaphore_Attributes *the_sem_attr; char *name; /* Sharing semaphores among processes is not currently supported */ if (pshared != 0) a0011050: 0a000002 beq a0011060 <_POSIX_Semaphore_Create_support+0x24> rtems_set_errno_and_return_minus_one( ENOSYS ); a0011054: eb0009ab bl a0013708 <__errno> a0011058: e3a03058 mov r3, #88 ; 0x58 a001105c: ea000018 b a00110c4 <_POSIX_Semaphore_Create_support+0x88> * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0011060: e59f30d8 ldr r3, [pc, #216] ; a0011140 <_POSIX_Semaphore_Create_support+0x104> a0011064: e5932000 ldr r2, [r3] ++level; a0011068: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a001106c: e5832000 str r2, [r3] * _POSIX_Semaphore_Allocate */ RTEMS_INLINE_ROUTINE POSIX_Semaphore_Control *_POSIX_Semaphore_Allocate( void ) { return (POSIX_Semaphore_Control *) a0011070: e59f00cc ldr r0, [pc, #204] ; a0011144 <_POSIX_Semaphore_Create_support+0x108> a0011074: ebffeff1 bl a000d040 <_Objects_Allocate> _Thread_Disable_dispatch(); the_semaphore = _POSIX_Semaphore_Allocate(); if ( !the_semaphore ) { a0011078: e2505000 subs r5, r0, #0 a001107c: 1a000003 bne a0011090 <_POSIX_Semaphore_Create_support+0x54> _Thread_Enable_dispatch(); a0011080: ebfff4bd bl a000e37c <_Thread_Enable_dispatch> rtems_set_errno_and_return_minus_one( ENOSPC ); a0011084: eb00099f bl a0013708 <__errno> a0011088: e3a0301c mov r3, #28 a001108c: ea00000c b a00110c4 <_POSIX_Semaphore_Create_support+0x88> /* * Make a copy of the user's string for name just in case it was * dynamically constructed. */ if ( name_arg != NULL ) { a0011090: e3540000 cmp r4, #0 a0011094: 0a00000d beq a00110d0 <_POSIX_Semaphore_Create_support+0x94> name = _Workspace_String_duplicate( name_arg, name_len ); a0011098: e1a00004 mov r0, r4 a001109c: e1a01006 mov r1, r6 a00110a0: eb000434 bl a0012178 <_Workspace_String_duplicate> if ( !name ) { a00110a4: e2504000 subs r4, r0, #0 a00110a8: 1a000008 bne a00110d0 <_POSIX_Semaphore_Create_support+0x94> RTEMS_INLINE_ROUTINE void _POSIX_Semaphore_Free ( POSIX_Semaphore_Control *the_semaphore ) { _Objects_Free( &_POSIX_Semaphore_Information, &the_semaphore->Object ); a00110ac: e59f0090 ldr r0, [pc, #144] ; a0011144 <_POSIX_Semaphore_Create_support+0x108><== NOT EXECUTED a00110b0: e1a01005 mov r1, r5 <== NOT EXECUTED a00110b4: ebfff0b0 bl a000d37c <_Objects_Free> <== NOT EXECUTED _POSIX_Semaphore_Free( the_semaphore ); _Thread_Enable_dispatch(); a00110b8: ebfff4af bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOMEM ); a00110bc: eb000991 bl a0013708 <__errno> <== NOT EXECUTED a00110c0: e3a0300c mov r3, #12 <== NOT EXECUTED a00110c4: e5803000 str r3, [r0] a00110c8: e3e00000 mvn r0, #0 a00110cc: e8bd80f0 pop {r4, r5, r6, r7, pc} } } else { name = NULL; } the_semaphore->process_shared = pshared; a00110d0: e3a03000 mov r3, #0 if ( name ) { a00110d4: e1540003 cmp r4, r3 } } else { name = NULL; } the_semaphore->process_shared = pshared; a00110d8: e5853010 str r3, [r5, #16] if ( name ) { the_semaphore->named = true; a00110dc: 13a03001 movne r3, #1 a00110e0: 15c53014 strbne r3, [r5, #20] the_semaphore->open_count = 1; a00110e4: 15853018 strne r3, [r5, #24] the_semaphore->linked = true; a00110e8: 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; a00110ec: e3a06000 mov r6, #0 /* * This effectively disables limit checking. */ the_sem_attr->maximum_count = 0xFFFFFFFF; a00110f0: e3e03000 mvn r3, #0 _CORE_semaphore_Initialize( &the_semaphore->Semaphore, the_sem_attr, value ); a00110f4: 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; a00110f8: 05c54014 strbeq r4, [r5, #20] the_semaphore->open_count = 0; a00110fc: 05854018 streq r4, [r5, #24] the_semaphore->linked = false; a0011100: 05c54015 strbeq r4, [r5, #21] the_sem_attr->discipline = CORE_SEMAPHORE_DISCIPLINES_FIFO; /* * This effectively disables limit checking. */ the_sem_attr->maximum_count = 0xFFFFFFFF; a0011104: e585305c str r3, [r5, #92] ; 0x5c _CORE_semaphore_Initialize( &the_semaphore->Semaphore, the_sem_attr, value ); a0011108: e285105c add r1, r5, #92 ; 0x5c a001110c: e1a02007 mov r2, r7 * 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; a0011110: 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 ); a0011114: ebffee46 bl a000ca34 <_CORE_semaphore_Initialize> #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a0011118: e59f3024 ldr r3, [pc, #36] ; a0011144 <_POSIX_Semaphore_Create_support+0x108> Objects_Information *information, Objects_Control *the_object, const char *name ) { _Objects_Set_local_object( a001111c: e1d520b8 ldrh r2, [r5, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a0011120: e593301c ldr r3, [r3, #28] a0011124: e7835102 str r5, [r3, r2, lsl #2] &_POSIX_Semaphore_Information, &the_semaphore->Object, name ); *the_sem = the_semaphore; a0011128: e59d3014 ldr r3, [sp, #20] the_object ); #if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES) /* ASSERT: information->is_string */ the_object->name.name_p = name; a001112c: e585400c str r4, [r5, #12] a0011130: e5835000 str r5, [r3] _Thread_Enable_dispatch(); a0011134: ebfff490 bl a000e37c <_Thread_Enable_dispatch> return 0; a0011138: e1a00006 mov r0, r6 } a001113c: e8bd80f0 pop {r4, r5, r6, r7, pc} =============================================================================== a0010160 <_POSIX_Semaphore_Wait_support>: int _POSIX_Semaphore_Wait_support( sem_t *sem, bool blocking, Watchdog_Interval timeout ) { a0010160: e92d4031 push {r0, r4, r5, lr} a0010164: e1a03000 mov r3, r0 a0010168: e1a04002 mov r4, r2 a001016c: e20150ff and r5, r1, #255 ; 0xff RTEMS_INLINE_ROUTINE POSIX_Semaphore_Control *_POSIX_Semaphore_Get ( sem_t *id, Objects_Locations *location ) { return (POSIX_Semaphore_Control *) a0010170: e1a0200d mov r2, sp a0010174: e5931000 ldr r1, [r3] a0010178: e59f006c ldr r0, [pc, #108] ; a00101ec <_POSIX_Semaphore_Wait_support+0x8c> a001017c: ebfff0bb bl a000c470 <_Objects_Get> POSIX_Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _POSIX_Semaphore_Get( sem, &location ); switch ( location ) { a0010180: e59d2000 ldr r2, [sp] a0010184: e1a03000 mov r3, r0 a0010188: e3520000 cmp r2, #0 a001018c: 1a000011 bne a00101d8 <_POSIX_Semaphore_Wait_support+0x78> case OBJECTS_LOCAL: _CORE_semaphore_Seize( a0010190: e5931008 ldr r1, [r3, #8] a0010194: e1a03004 mov r3, r4 blocking, timeout ); _Thread_Enable_dispatch(); if ( !_Thread_Executing->Wait.return_code ) a0010198: e59f4050 ldr r4, [pc, #80] ; a00101f0 <_POSIX_Semaphore_Wait_support+0x90> the_semaphore = _POSIX_Semaphore_Get( sem, &location ); switch ( location ) { case OBJECTS_LOCAL: _CORE_semaphore_Seize( a001019c: e280001c add r0, r0, #28 a00101a0: e1a02005 mov r2, r5 a00101a4: eb000188 bl a00107cc <_CORE_semaphore_Seize> &the_semaphore->Semaphore, the_semaphore->Object.id, blocking, timeout ); _Thread_Enable_dispatch(); a00101a8: ebfff41f bl a000d22c <_Thread_Enable_dispatch> if ( !_Thread_Executing->Wait.return_code ) a00101ac: e5943008 ldr r3, [r4, #8] a00101b0: e5930034 ldr r0, [r3, #52] ; 0x34 a00101b4: e3500000 cmp r0, #0 a00101b8: 0a00000a beq a00101e8 <_POSIX_Semaphore_Wait_support+0x88> return 0; rtems_set_errno_and_return_minus_one( a00101bc: eb00090b bl a00125f0 <__errno> a00101c0: e5943008 ldr r3, [r4, #8] a00101c4: e1a05000 mov r5, r0 a00101c8: e5930034 ldr r0, [r3, #52] ; 0x34 a00101cc: eb00083d bl a00122c8 <_POSIX_Semaphore_Translate_core_semaphore_return_code> a00101d0: e5850000 str r0, [r5] a00101d4: ea000002 b a00101e4 <_POSIX_Semaphore_Wait_support+0x84> #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a00101d8: eb000904 bl a00125f0 <__errno> <== NOT EXECUTED a00101dc: e3a03016 mov r3, #22 <== NOT EXECUTED a00101e0: e5803000 str r3, [r0] <== NOT EXECUTED a00101e4: e3e00000 mvn r0, #0 } a00101e8: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000ed34 <_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 ]; a000ed34: e59030f4 ldr r3, [r0, #244] ; 0xf4 if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE && a000ed38: e59320d8 ldr r2, [r3, #216] ; 0xd8 a000ed3c: e3520000 cmp r2, #0 a000ed40: 1a00000b bne a000ed74 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x40> a000ed44: e59320dc ldr r2, [r3, #220] ; 0xdc a000ed48: e3520001 cmp r2, #1 a000ed4c: 1a000008 bne a000ed74 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x40> thread_support->cancelability_type == PTHREAD_CANCEL_ASYNCHRONOUS && a000ed50: e59330e0 ldr r3, [r3, #224] ; 0xe0 <== NOT EXECUTED a000ed54: e3530000 cmp r3, #0 <== NOT EXECUTED a000ed58: 0a000005 beq a000ed74 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x40><== NOT EXECUTED * * This routine decrements the thread dispatch level. */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000ed5c: e59f3014 ldr r3, [pc, #20] ; a000ed78 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x44><== NOT EXECUTED thread_support->cancelation_requested ) { _Thread_Unnest_dispatch(); _POSIX_Thread_Exit( the_thread, PTHREAD_CANCELED ); a000ed60: e3e01000 mvn r1, #0 <== NOT EXECUTED a000ed64: e5932000 ldr r2, [r3] <== NOT EXECUTED --level; a000ed68: e2422001 sub r2, r2, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a000ed6c: e5832000 str r2, [r3] <== NOT EXECUTED a000ed70: ea0001b6 b a000f450 <_POSIX_Thread_Exit> <== NOT EXECUTED } else _Thread_Enable_dispatch(); a000ed74: eafff6ef b a000c938 <_Thread_Enable_dispatch> =============================================================================== a0011488 <_POSIX_Thread_Exit>: void _POSIX_Thread_Exit( Thread_Control *the_thread, void *value_ptr ) { a0011488: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} a001148c: e1a04000 mov r4, r0 Objects_Information *the_information; Thread_Control *unblocked; POSIX_API_Control *api; the_information = _Objects_Get_information_id( the_thread->Object.id ); a0011490: e5900008 ldr r0, [r0, #8] void _POSIX_Thread_Exit( Thread_Control *the_thread, void *value_ptr ) { a0011494: e1a0a001 mov sl, r1 Objects_Information *the_information; Thread_Control *unblocked; POSIX_API_Control *api; the_information = _Objects_Get_information_id( the_thread->Object.id ); a0011498: ebffe903 bl a000b8ac <_Objects_Get_information_id> * are ready to be switched out. Otherwise, an ISR could * occur and preempt us out while we still hold the * allocator mutex. */ _RTEMS_Lock_allocator(); a001149c: e59f60b4 ldr r6, [pc, #180] ; a0011558 <_POSIX_Thread_Exit+0xd0> * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a00114a0: e59f50b4 ldr r5, [pc, #180] ; a001155c <_POSIX_Thread_Exit+0xd4> { Objects_Information *the_information; Thread_Control *unblocked; POSIX_API_Control *api; the_information = _Objects_Get_information_id( the_thread->Object.id ); a00114a4: e1a07000 mov r7, r0 * are ready to be switched out. Otherwise, an ISR could * occur and preempt us out while we still hold the * allocator mutex. */ _RTEMS_Lock_allocator(); a00114a8: e5960000 ldr r0, [r6] Thread_Control *unblocked; POSIX_API_Control *api; the_information = _Objects_Get_information_id( the_thread->Object.id ); api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a00114ac: e59480f4 ldr r8, [r4, #244] ; 0xf4 * are ready to be switched out. Otherwise, an ISR could * occur and preempt us out while we still hold the * allocator mutex. */ _RTEMS_Lock_allocator(); a00114b0: ebffe57b bl a000aaa4 <_API_Mutex_Lock> a00114b4: e5953000 ldr r3, [r5] ++level; a00114b8: e2833001 add r3, r3, #1 _Thread_Dispatch_disable_level = level; a00114bc: e5853000 str r3, [r5] the_thread->Wait.return_argument = value_ptr; /* * Process join */ if ( api->detachstate == PTHREAD_CREATE_JOINABLE ) { a00114c0: e5983040 ldr r3, [r8, #64] ; 0x40 */ _RTEMS_Lock_allocator(); _Thread_Disable_dispatch(); the_thread->Wait.return_argument = value_ptr; a00114c4: e584a028 str sl, [r4, #40] ; 0x28 /* * Process join */ if ( api->detachstate == PTHREAD_CREATE_JOINABLE ) { a00114c8: e3530001 cmp r3, #1 a00114cc: 1a000016 bne a001152c <_POSIX_Thread_Exit+0xa4> unblocked = _Thread_queue_Dequeue( &api->Join_List ); a00114d0: e2888044 add r8, r8, #68 ; 0x44 a00114d4: e1a00008 mov r0, r8 a00114d8: ebffed94 bl a000cb30 <_Thread_queue_Dequeue> if ( unblocked ) { a00114dc: e3500000 cmp r0, #0 a00114e0: 0a000006 beq a0011500 <_POSIX_Thread_Exit+0x78> do { *(void **)unblocked->Wait.return_argument = value_ptr; a00114e4: e5903028 ldr r3, [r0, #40] ; 0x28 } while ( (unblocked = _Thread_queue_Dequeue( &api->Join_List )) ); a00114e8: e1a00008 mov r0, r8 */ if ( api->detachstate == PTHREAD_CREATE_JOINABLE ) { unblocked = _Thread_queue_Dequeue( &api->Join_List ); if ( unblocked ) { do { *(void **)unblocked->Wait.return_argument = value_ptr; a00114ec: e583a000 str sl, [r3] } while ( (unblocked = _Thread_queue_Dequeue( &api->Join_List )) ); a00114f0: ebffed8e bl a000cb30 <_Thread_queue_Dequeue> a00114f4: e3500000 cmp r0, #0 a00114f8: 1afffff9 bne a00114e4 <_POSIX_Thread_Exit+0x5c> a00114fc: ea00000a b a001152c <_POSIX_Thread_Exit+0xa4> } else { _Thread_Set_state( a0011500: e59f1058 ldr r1, [pc, #88] ; a0011560 <_POSIX_Thread_Exit+0xd8> a0011504: e1a00004 mov r0, r4 a0011508: ebffeec5 bl a000d024 <_Thread_Set_state> the_thread, STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT ); _RTEMS_Unlock_allocator(); a001150c: e5960000 ldr r0, [r6] a0011510: ebffe57c bl a000ab08 <_API_Mutex_Unlock> _Thread_Enable_dispatch(); a0011514: ebffecb1 bl a000c7e0 <_Thread_Enable_dispatch> /* now waiting for thread to arrive */ _RTEMS_Lock_allocator(); a0011518: e5960000 ldr r0, [r6] <== NOT EXECUTED a001151c: ebffe560 bl a000aaa4 <_API_Mutex_Lock> <== NOT EXECUTED * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0011520: e5953000 ldr r3, [r5] <== NOT EXECUTED ++level; a0011524: e2833001 add r3, r3, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a0011528: e5853000 str r3, [r5] <== NOT EXECUTED } /* * Now shut down the thread */ _Thread_Close( the_information, the_thread ); a001152c: e1a00007 mov r0, r7 a0011530: e1a01004 mov r1, r4 a0011534: ebffebdd bl a000c4b0 <_Thread_Close> RTEMS_INLINE_ROUTINE void _POSIX_Threads_Free ( Thread_Control *the_pthread ) { _Objects_Free( &_POSIX_Threads_Information, &the_pthread->Object ); a0011538: e1a01004 mov r1, r4 a001153c: e59f0020 ldr r0, [pc, #32] ; a0011564 <_POSIX_Thread_Exit+0xdc> a0011540: ebffe8bb bl a000b834 <_Objects_Free> _POSIX_Threads_Free( the_thread ); _RTEMS_Unlock_allocator(); a0011544: e59f300c ldr r3, [pc, #12] ; a0011558 <_POSIX_Thread_Exit+0xd0> a0011548: e5930000 ldr r0, [r3] a001154c: ebffe56d bl a000ab08 <_API_Mutex_Unlock> _Thread_Enable_dispatch(); } a0011550: e8bd45f0 pop {r4, r5, r6, r7, r8, sl, lr} _Thread_Close( the_information, the_thread ); _POSIX_Threads_Free( the_thread ); _RTEMS_Unlock_allocator(); _Thread_Enable_dispatch(); a0011554: eaffeca1 b a000c7e0 <_Thread_Enable_dispatch> =============================================================================== a000efd0 <_POSIX_Threads_Delete_extension>: */ static void _POSIX_Threads_Delete_extension( Thread_Control *executing __attribute__((unused)), Thread_Control *deleted ) { a000efd0: 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 ]; a000efd4: e59150f4 ldr r5, [r1, #244] ; 0xf4 */ static void _POSIX_Threads_Delete_extension( Thread_Control *executing __attribute__((unused)), Thread_Control *deleted ) { a000efd8: e1a04001 mov r4, r1 api = deleted->API_Extensions[ THREAD_API_POSIX ]; /* * Run the POSIX cancellation handlers */ _POSIX_Threads_cancel_run( deleted ); a000efdc: e1a00001 mov r0, r1 a000efe0: eb00086b bl a0011194 <_POSIX_Threads_cancel_run> /* * Run all the key destructors */ _POSIX_Keys_Run_destructors( deleted ); a000efe4: e1a00004 mov r0, r4 a000efe8: eb000880 bl a00111f0 <_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 )) ) a000efec: 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; a000eff0: e5947028 ldr r7, [r4, #40] ; 0x28 while ( (the_thread = _Thread_queue_Dequeue( &api->Join_List )) ) a000eff4: ea000001 b a000f000 <_POSIX_Threads_Delete_extension+0x30> *(void **)the_thread->Wait.return_argument = value_ptr; a000eff8: e5903028 ldr r3, [r0, #40] ; 0x28 <== NOT EXECUTED a000effc: e5837000 str r7, [r3] <== NOT EXECUTED /* * 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 )) ) a000f000: e1a00006 mov r0, r6 a000f004: ebfff6c9 bl a000cb30 <_Thread_queue_Dequeue> a000f008: e3500000 cmp r0, #0 a000f00c: 1afffff9 bne a000eff8 <_POSIX_Threads_Delete_extension+0x28> *(void **)the_thread->Wait.return_argument = value_ptr; if ( api->schedpolicy == SCHED_SPORADIC ) a000f010: e5953084 ldr r3, [r5, #132] ; 0x84 a000f014: e3530004 cmp r3, #4 a000f018: 1a000001 bne a000f024 <_POSIX_Threads_Delete_extension+0x54> (void) _Watchdog_Remove( &api->Sporadic_timer ); a000f01c: e28500a8 add r0, r5, #168 ; 0xa8 <== NOT EXECUTED a000f020: ebfff929 bl a000d4cc <_Watchdog_Remove> <== NOT EXECUTED deleted->API_Extensions[ THREAD_API_POSIX ] = NULL; a000f024: e3a03000 mov r3, #0 _Workspace_Free( api ); a000f028: 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; a000f02c: e58430f4 str r3, [r4, #244] ; 0xf4 _Workspace_Free( api ); } a000f030: 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; _Workspace_Free( api ); a000f034: eafff9b6 b a000d714 <_Workspace_Free> =============================================================================== a000f1c8 <_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 */ a000f1c8: e3e01000 mvn r1, #0 <== NOT EXECUTED ) { POSIX_API_Control *api; uint32_t new_priority; api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a000f1cc: e59020f4 ldr r2, [r0, #244] ; 0xf4 <== 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 */ a000f1d0: e5801074 str r1, [r0, #116] ; 0x74 <== NOT EXECUTED a000f1d4: e59f102c ldr r1, [pc, #44] ; a000f208 <_POSIX_Threads_Sporadic_budget_callout+0x40><== NOT EXECUTED a000f1d8: e592208c ldr r2, [r2, #140] ; 0x8c <== NOT EXECUTED a000f1dc: e5d11000 ldrb r1, [r1] <== NOT EXECUTED a000f1e0: 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 ) { a000f1e4: 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; a000f1e8: 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 ) { a000f1ec: e3520000 cmp r2, #0 <== NOT EXECUTED a000f1f0: 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 ) { a000f1f4: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED a000f1f8: e1530001 cmp r3, r1 <== NOT EXECUTED a000f1fc: 212fff1e bxcs lr <== NOT EXECUTED _Thread_Change_priority( the_thread, new_priority, true ); a000f200: e3a02001 mov r2, #1 <== NOT EXECUTED a000f204: eafff45c b a000c37c <_Thread_Change_priority> <== NOT EXECUTED =============================================================================== a0011194 <_POSIX_Threads_cancel_run>: #include void _POSIX_Threads_cancel_run( Thread_Control *the_thread ) { a0011194: 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 ]; a0011198: e59050f4 ldr r5, [r0, #244] ; 0xf4 handler_stack = &thread_support->Cancellation_Handlers; thread_support->cancelability_state = PTHREAD_CANCEL_DISABLE; a001119c: e3a03001 mov r3, #1 a00111a0: 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 ); a00111a4: e28560e8 add r6, r5, #232 ; 0xe8 while ( !_Chain_Is_empty( handler_stack ) ) { a00111a8: ea00000c b a00111e0 <_POSIX_Threads_cancel_run+0x4c> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a00111ac: e10f1000 mrs r1, CPSR <== NOT EXECUTED a00111b0: e3813080 orr r3, r1, #128 ; 0x80 <== NOT EXECUTED a00111b4: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED _ISR_Disable( level ); handler = (POSIX_Cancel_Handler_control *) a00111b8: e59540ec ldr r4, [r5, #236] ; 0xec <== NOT EXECUTED { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; a00111bc: e894000c ldm r4, {r2, r3} <== NOT EXECUTED next->previous = previous; a00111c0: e5823004 str r3, [r2, #4] <== NOT EXECUTED previous->next = next; a00111c4: e5832000 str r2, [r3] <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a00111c8: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED _Chain_Tail( handler_stack )->previous; _Chain_Extract_unprotected( &handler->Node ); _ISR_Enable( level ); (*handler->routine)( handler->arg ); a00111cc: e594000c ldr r0, [r4, #12] <== NOT EXECUTED a00111d0: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED a00111d4: e12fff33 blx r3 <== NOT EXECUTED _Workspace_Free( handler ); a00111d8: e1a00004 mov r0, r4 <== NOT EXECUTED a00111dc: ebfff14c bl a000d714 <_Workspace_Free> <== NOT EXECUTED handler_stack = &thread_support->Cancellation_Handlers; thread_support->cancelability_state = PTHREAD_CANCEL_DISABLE; while ( !_Chain_Is_empty( handler_stack ) ) { a00111e0: e59530e4 ldr r3, [r5, #228] ; 0xe4 a00111e4: e1530006 cmp r3, r6 a00111e8: 1affffef bne a00111ac <_POSIX_Threads_cancel_run+0x18> (*handler->routine)( handler->arg ); _Workspace_Free( handler ); } } a00111ec: e8bd8070 pop {r4, r5, r6, pc} =============================================================================== a000f9e8 <_POSIX_Timer_Insert_helper>: Watchdog_Interval ticks, Objects_Id id, Watchdog_Service_routine_entry TSR, void *arg ) { a000f9e8: e92d41f0 push {r4, r5, r6, r7, r8, lr} a000f9ec: e1a04000 mov r4, r0 a000f9f0: e1a05001 mov r5, r1 a000f9f4: e1a07002 mov r7, r2 a000f9f8: e1a08003 mov r8, r3 ISR_Level level; (void) _Watchdog_Remove( timer ); a000f9fc: ebfff839 bl a000dae8 <_Watchdog_Remove> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000fa00: e10f6000 mrs r6, CPSR a000fa04: e3863080 orr r3, r6, #128 ; 0x80 a000fa08: 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 ) { a000fa0c: e5943008 ldr r3, [r4, #8] a000fa10: e3530000 cmp r3, #0 a000fa14: 0a000002 beq a000fa24 <_POSIX_Timer_Insert_helper+0x3c> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000fa18: e129f006 msr CPSR_fc, r6 <== NOT EXECUTED _ISR_Enable( level ); return false; a000fa1c: e3a00000 mov r0, #0 <== NOT EXECUTED a000fa20: 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; a000fa24: e5843008 str r3, [r4, #8] the_watchdog->routine = routine; the_watchdog->id = id; the_watchdog->user_data = user_data; a000fa28: e59d3018 ldr r3, [sp, #24] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a000fa2c: e584801c str r8, [r4, #28] the_watchdog->id = id; a000fa30: e5847020 str r7, [r4, #32] the_watchdog->user_data = user_data; a000fa34: e5843024 str r3, [r4, #36] ; 0x24 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a000fa38: e584500c str r5, [r4, #12] _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a000fa3c: e59f0010 ldr r0, [pc, #16] ; a000fa54 <_POSIX_Timer_Insert_helper+0x6c> a000fa40: e1a01004 mov r1, r4 a000fa44: ebfff7d0 bl a000d98c <_Watchdog_Insert> a000fa48: 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; a000fa4c: e3a00001 mov r0, #1 } a000fa50: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a0009e80 <_POSIX_Timer_TSR>: bool activated; ptimer = (POSIX_Timer_Control *)data; /* Increment the number of expirations. */ ptimer->overrun = ptimer->overrun + 1; a0009e80: 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) { a0009e84: e92d40d7 push {r0, r1, r2, r4, r6, r7, lr} <== NOT EXECUTED bool activated; ptimer = (POSIX_Timer_Control *)data; /* Increment the number of expirations. */ ptimer->overrun = ptimer->overrun + 1; a0009e88: e2833001 add r3, r3, #1 <== NOT EXECUTED a0009e8c: e5813068 str r3, [r1, #104] ; 0x68 <== NOT EXECUTED /* The timer must be reprogrammed */ if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) || a0009e90: 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) { a0009e94: 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 ) || a0009e98: e3530000 cmp r3, #0 <== NOT EXECUTED a0009e9c: 1a000003 bne a0009eb0 <_POSIX_Timer_TSR+0x30> <== NOT EXECUTED a0009ea0: e5913058 ldr r3, [r1, #88] ; 0x58 <== NOT EXECUTED a0009ea4: 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; a0009ea8: 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 ) || a0009eac: 0a000018 beq a0009f14 <_POSIX_Timer_TSR+0x94> <== NOT EXECUTED ( ptimer->timer_data.it_interval.tv_nsec != 0 ) ) { activated = _POSIX_Timer_Insert_helper( a0009eb0: e2840010 add r0, r4, #16 <== NOT EXECUTED a0009eb4: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED a0009eb8: e5942008 ldr r2, [r4, #8] <== NOT EXECUTED a0009ebc: e59f306c ldr r3, [pc, #108] ; a0009f30 <_POSIX_Timer_TSR+0xb0><== NOT EXECUTED a0009ec0: e58d4000 str r4, [sp] <== NOT EXECUTED a0009ec4: eb0016c7 bl a000f9e8 <_POSIX_Timer_Insert_helper> <== NOT EXECUTED ptimer->ticks, ptimer->Object.id, _POSIX_Timer_TSR, ptimer ); if ( !activated ) a0009ec8: e3500000 cmp r0, #0 <== NOT EXECUTED a0009ecc: 0a000016 beq a0009f2c <_POSIX_Timer_TSR+0xac> <== NOT EXECUTED ) { Timestamp_Control tod_as_timestamp; Timestamp_Control *tod_as_timestamp_ptr; tod_as_timestamp_ptr = a0009ed0: e59f105c ldr r1, [pc, #92] ; a0009f34 <_POSIX_Timer_TSR+0xb4><== NOT EXECUTED a0009ed4: e28d0004 add r0, sp, #4 <== NOT EXECUTED a0009ed8: eb00058b bl a000b50c <_TOD_Get_with_nanoseconds> <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0009edc: e59f2054 ldr r2, [pc, #84] ; a0009f38 <_POSIX_Timer_TSR+0xb8><== NOT EXECUTED /* After the signal handler returns, the count of expirations of the * timer must be set to 0. */ ptimer->overrun = 0; } a0009ee0: e89000c0 ldm r0, {r6, r7} <== NOT EXECUTED a0009ee4: e3a03000 mov r3, #0 <== NOT EXECUTED a0009ee8: e1a00006 mov r0, r6 <== NOT EXECUTED a0009eec: e1a01007 mov r1, r7 <== NOT EXECUTED a0009ef0: eb00483e bl a001bff0 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a0009ef4: e3a03000 mov r3, #0 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0009ef8: e584006c str r0, [r4, #108] ; 0x6c <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a0009efc: e1a01007 mov r1, r7 <== NOT EXECUTED a0009f00: e1a00006 mov r0, r6 <== NOT EXECUTED a0009f04: e59f202c ldr r2, [pc, #44] ; a0009f38 <_POSIX_Timer_TSR+0xb8><== NOT EXECUTED a0009f08: eb004973 bl a001c4dc <__moddi3> <== NOT EXECUTED /* Store the time when the timer was started again */ _TOD_Get( &ptimer->time ); /* The state really did not change but just to be safe */ ptimer->state = POSIX_TIMER_STATE_CREATE_RUN; a0009f0c: e3a03003 mov r3, #3 <== NOT EXECUTED a0009f10: e5840070 str r0, [r4, #112] ; 0x70 <== NOT EXECUTED } else { /* Indicates that the timer is stopped */ ptimer->state = POSIX_TIMER_STATE_CREATE_STOP; a0009f14: 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 ) ) { a0009f18: e5940038 ldr r0, [r4, #56] ; 0x38 <== NOT EXECUTED a0009f1c: e5941044 ldr r1, [r4, #68] ; 0x44 <== NOT EXECUTED a0009f20: eb0015a3 bl a000f5b4 <== NOT EXECUTED } /* After the signal handler returns, the count of expirations of the * timer must be set to 0. */ ptimer->overrun = 0; a0009f24: e3a03000 mov r3, #0 <== NOT EXECUTED a0009f28: e5843068 str r3, [r4, #104] ; 0x68 <== NOT EXECUTED } a0009f2c: e8bd80de pop {r1, r2, r3, r4, r6, r7, pc} <== NOT EXECUTED =============================================================================== a000ee54 <_POSIX_signals_Abnormal_termination_handler>: sigset_t _POSIX_signals_Pending; void _POSIX_signals_Abnormal_termination_handler( int signo __attribute__((unused)) ) { a000ee54: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED exit( 1 ); a000ee58: e3a00001 mov r0, #1 <== NOT EXECUTED a000ee5c: eb000ab2 bl a001192c <== NOT EXECUTED =============================================================================== a000bb6c <_POSIX_signals_Alarm_TSR>: static void _POSIX_signals_Alarm_TSR( Objects_Id id __attribute__((unused)), void *argument __attribute__((unused)) ) { a000bb6c: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED kill( getpid(), SIGALRM ); a000bb70: ebfff28b bl a00085a4 <== NOT EXECUTED a000bb74: e3a0100e mov r1, #14 <== NOT EXECUTED /* XXX can't print from an ISR, should this be fatal? */ } a000bb78: e49de004 pop {lr} ; (ldr lr, [sp], #4) <== NOT EXECUTED static void _POSIX_signals_Alarm_TSR( Objects_Id id __attribute__((unused)), void *argument __attribute__((unused)) ) { kill( getpid(), SIGALRM ); a000bb7c: ea00004d b a000bcb8 <== NOT EXECUTED =============================================================================== a0011368 <_POSIX_signals_Clear_signals>: int signo, siginfo_t *info, bool is_global, bool check_blocked ) { a0011368: e92d40f0 push {r4, r5, r6, r7, lr} a001136c: e5ddc014 ldrb ip, [sp, #20] a0011370: e1a04001 mov r4, r1 a0011374: 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 ) a0011378: e35c0000 cmp ip, #0 static inline sigset_t signo_to_mask( uint32_t sig ) { return 1u << (sig - 1); a001137c: e2412001 sub r2, r1, #1 a0011380: e3a01001 mov r1, #1 a0011384: e1a01211 lsl r1, r1, r2 signals_blocked = ~api->signals_blocked; a0011388: 159020d0 ldrne r2, [r0, #208] ; 0xd0 int signo, siginfo_t *info, bool is_global, bool check_blocked ) { a001138c: e20330ff and r3, r3, #255 ; 0xff */ if ( check_blocked ) signals_blocked = ~api->signals_blocked; else signals_blocked = SIGNAL_ALL_MASK; a0011390: 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; a0011394: 11e02002 mvnne r2, r2 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0011398: e10f7000 mrs r7, CPSR a001139c: e387c080 orr ip, r7, #128 ; 0x80 a00113a0: 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 ) { a00113a4: e3530000 cmp r3, #0 a00113a8: 0a000028 beq a0011450 <_POSIX_signals_Clear_signals+0xe8> if ( mask & (_POSIX_signals_Pending & signals_blocked) ) { a00113ac: e59f30c4 ldr r3, [pc, #196] ; a0011478 <_POSIX_signals_Clear_signals+0x110> a00113b0: e5930000 ldr r0, [r3] a00113b4: e0011000 and r1, r1, r0 a00113b8: e0110002 ands r0, r1, r2 a00113bc: 0a00002b beq a0011470 <_POSIX_signals_Clear_signals+0x108> if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) { a00113c0: e3a0300c mov r3, #12 a00113c4: e0030394 mul r3, r4, r3 a00113c8: e59f20ac ldr r2, [pc, #172] ; a001147c <_POSIX_signals_Clear_signals+0x114> a00113cc: e7922003 ldr r2, [r2, r3] a00113d0: e3520002 cmp r2, #2 a00113d4: 1a00001a bne a0011444 <_POSIX_signals_Clear_signals+0xdc> psiginfo = (POSIX_signals_Siginfo_node *) _Chain_Get_unprotected( &_POSIX_signals_Siginfo[ signo ] ); a00113d8: e59f20a0 ldr r2, [pc, #160] ; a0011480 <_POSIX_signals_Clear_signals+0x118> */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a00113dc: e7926003 ldr r6, [r2, r3] a00113e0: e0820003 add r0, r2, r3 RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); a00113e4: e2801004 add r1, r0, #4 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) a00113e8: 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; a00113ec: 15961000 ldrne r1, [r6] ) { if ( !_Chain_Is_empty(the_chain)) return _Chain_Get_first_unprotected(the_chain); else return NULL; a00113f0: 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; a00113f4: 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; a00113f8: 17821003 strne r1, [r2, r3] _POSIX_signals_Clear_process_signals( signo ); a00113fc: e1a00004 mov r0, r4 a0011400: eb000121 bl a001188c <_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 ) { a0011404: e3560000 cmp r6, #0 a0011408: 0a00000d beq a0011444 <_POSIX_signals_Clear_signals+0xdc> *info = psiginfo->Info; a001140c: e5962008 ldr r2, [r6, #8] <== NOT EXECUTED a0011410: e1a03005 mov r3, r5 <== NOT EXECUTED a0011414: e4832004 str r2, [r3], #4 <== NOT EXECUTED a0011418: e596200c ldr r2, [r6, #12] <== NOT EXECUTED a001141c: e5852004 str r2, [r5, #4] <== NOT EXECUTED a0011420: e5962010 ldr r2, [r6, #16] <== NOT EXECUTED a0011424: 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; a0011428: e59f3054 ldr r3, [pc, #84] ; a0011484 <_POSIX_signals_Clear_signals+0x11c><== NOT EXECUTED a001142c: e5932008 ldr r2, [r3, #8] <== NOT EXECUTED the_node->next = tail; a0011430: e2831004 add r1, r3, #4 <== NOT EXECUTED a0011434: e5861000 str r1, [r6] <== NOT EXECUTED tail->previous = the_node; a0011438: e5836008 str r6, [r3, #8] <== NOT EXECUTED old_last->next = the_node; a001143c: e5826000 str r6, [r2] <== NOT EXECUTED the_node->previous = old_last; a0011440: e5862004 str r2, [r6, #4] <== NOT EXECUTED &psiginfo->Node ); } else do_callout = false; } _POSIX_signals_Clear_process_signals( signo ); a0011444: e1a00004 mov r0, r4 a0011448: eb00010f bl a001188c <_POSIX_signals_Clear_process_signals> a001144c: ea000006 b a001146c <_POSIX_signals_Clear_signals+0x104> do_callout = true; } } else { if ( mask & (api->signals_pending & signals_blocked) ) { a0011450: e590c0d4 ldr ip, [r0, #212] ; 0xd4 a0011454: e001400c and r4, r1, ip a0011458: e1140002 tst r4, r2 bool do_callout; POSIX_signals_Siginfo_node *psiginfo; mask = signo_to_mask( signo ); do_callout = false; a001145c: 01a00003 moveq r0, r3 } _POSIX_signals_Clear_process_signals( signo ); do_callout = true; } } else { if ( mask & (api->signals_pending & signals_blocked) ) { a0011460: 0a000002 beq a0011470 <_POSIX_signals_Clear_signals+0x108> api->signals_pending &= ~mask; a0011464: e1cc1001 bic r1, ip, r1 a0011468: e58010d4 str r1, [r0, #212] ; 0xd4 do_callout = true; a001146c: e3a00001 mov r0, #1 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0011470: e129f007 msr CPSR_fc, r7 } } _ISR_Enable( level ); return do_callout; } a0011474: e8bd80f0 pop {r4, r5, r6, r7, pc} =============================================================================== a000ac74 <_POSIX_signals_Get_lowest>: sigset_t set ) { int signo; for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) { a000ac74: e3a0301b mov r3, #27 <== NOT EXECUTED static inline sigset_t signo_to_mask( uint32_t sig ) { return 1u << (sig - 1); a000ac78: e3a02001 mov r2, #1 <== NOT EXECUTED #include #include #include #include static int _POSIX_signals_Get_lowest( a000ac7c: e2431001 sub r1, r3, #1 <== NOT EXECUTED ) { int signo; for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) { if ( set & signo_to_mask( signo ) ) { a000ac80: e0101112 ands r1, r0, r2, lsl r1 <== NOT EXECUTED a000ac84: 1a00000a bne a000acb4 <_POSIX_signals_Get_lowest+0x40> <== NOT EXECUTED sigset_t set ) { int signo; for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) { a000ac88: e2833001 add r3, r3, #1 <== NOT EXECUTED a000ac8c: e3530020 cmp r3, #32 <== NOT EXECUTED a000ac90: 1afffff9 bne a000ac7c <_POSIX_signals_Get_lowest+0x8> <== NOT EXECUTED a000ac94: e3a03001 mov r3, #1 <== NOT EXECUTED a000ac98: e1a02003 mov r2, r3 <== NOT EXECUTED #include #include #include #include static int _POSIX_signals_Get_lowest( a000ac9c: 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 ) ) { a000aca0: e0101112 ands r1, r0, r2, lsl r1 <== NOT EXECUTED a000aca4: 1a000002 bne a000acb4 <_POSIX_signals_Get_lowest+0x40> <== NOT EXECUTED */ #if (SIGHUP != 1) #error "Assumption that SIGHUP==1 violated!!" #endif for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) { a000aca8: e2833001 add r3, r3, #1 <== NOT EXECUTED a000acac: e353001b cmp r3, #27 <== NOT EXECUTED a000acb0: 1afffff9 bne a000ac9c <_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; } a000acb4: e1a00003 mov r0, r3 <== NOT EXECUTED a000acb8: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000ed8c <_POSIX_signals_Post_switch_hook>: /* * We need to ensure that if the signal handler executes a call * which overwrites the unblocking status, we restore it. */ hold_errno = _Thread_Executing->Wait.return_code; a000ed8c: e59f30b8 ldr r3, [pc, #184] ; a000ee4c <_POSIX_signals_Post_switch_hook+0xc0> */ static void _POSIX_signals_Post_switch_hook( Thread_Control *the_thread ) { a000ed90: e92d40f0 push {r4, r5, r6, r7, lr} POSIX_API_Control *api; int signo; ISR_Level level; int hold_errno; api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a000ed94: e59040f4 ldr r4, [r0, #244] ; 0xf4 /* * We need to ensure that if the signal handler executes a call * which overwrites the unblocking status, we restore it. */ hold_errno = _Thread_Executing->Wait.return_code; a000ed98: e5933008 ldr r3, [r3, #8] /* * api may be NULL in case of a thread close in progress */ if ( !api ) a000ed9c: e3540000 cmp r4, #0 /* * We need to ensure that if the signal handler executes a call * which overwrites the unblocking status, we restore it. */ hold_errno = _Thread_Executing->Wait.return_code; a000eda0: e5936034 ldr r6, [r3, #52] ; 0x34 /* * api may be NULL in case of a thread close in progress */ if ( !api ) a000eda4: 0a000027 beq a000ee48 <_POSIX_signals_Post_switch_hook+0xbc> * processed at all. No point in doing this loop otherwise. */ while (1) { _ISR_Disable( level ); if ( !(~api->signals_blocked & (api->signals_pending | _POSIX_signals_Pending)) ) { a000eda8: e59f70a0 ldr r7, [pc, #160] ; a000ee50 <_POSIX_signals_Post_switch_hook+0xc4> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000edac: e10f3000 mrs r3, CPSR a000edb0: e3832080 orr r2, r3, #128 ; 0x80 a000edb4: e129f002 msr CPSR_fc, r2 a000edb8: e5971000 ldr r1, [r7] a000edbc: e59420d4 ldr r2, [r4, #212] ; 0xd4 a000edc0: e1812002 orr r2, r1, r2 * The first thing done is to check there are any signals to be * processed at all. No point in doing this loop otherwise. */ while (1) { _ISR_Disable( level ); if ( !(~api->signals_blocked & a000edc4: e59410d0 ldr r1, [r4, #208] ; 0xd0 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000edc8: e129f003 msr CPSR_fc, r3 a000edcc: e1d21001 bics r1, r2, r1 a000edd0: 1a000003 bne a000ede4 <_POSIX_signals_Post_switch_hook+0x58> _POSIX_signals_Check_signal( api, signo, false ); _POSIX_signals_Check_signal( api, signo, true ); } } _Thread_Executing->Wait.return_code = hold_errno; a000edd4: e59f3070 ldr r3, [pc, #112] ; a000ee4c <_POSIX_signals_Post_switch_hook+0xc0> a000edd8: e5933008 ldr r3, [r3, #8] a000eddc: e5836034 str r6, [r3, #52] ; 0x34 a000ede0: e8bd80f0 pop {r4, r5, r6, r7, pc} _ISR_Enable( level ); break; } _ISR_Enable( level ); for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) { a000ede4: e3a0501b mov r5, #27 _POSIX_signals_Check_signal( api, signo, false ); a000ede8: e1a01005 mov r1, r5 a000edec: e3a02000 mov r2, #0 a000edf0: e1a00004 mov r0, r4 a000edf4: eb000922 bl a0011284 <_POSIX_signals_Check_signal> _POSIX_signals_Check_signal( api, signo, true ); a000edf8: e1a01005 mov r1, r5 a000edfc: e1a00004 mov r0, r4 a000ee00: e3a02001 mov r2, #1 _ISR_Enable( level ); break; } _ISR_Enable( level ); for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) { a000ee04: e2855001 add r5, r5, #1 _POSIX_signals_Check_signal( api, signo, false ); _POSIX_signals_Check_signal( api, signo, true ); a000ee08: eb00091d bl a0011284 <_POSIX_signals_Check_signal> _ISR_Enable( level ); break; } _ISR_Enable( level ); for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) { a000ee0c: e3550020 cmp r5, #32 a000ee10: 1afffff4 bne a000ede8 <_POSIX_signals_Post_switch_hook+0x5c> a000ee14: e3a05001 mov r5, #1 _POSIX_signals_Check_signal( api, signo, true ); } /* Unfortunately - nothing like __SIGFIRSTNOTRT in newlib signal .h */ for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) { _POSIX_signals_Check_signal( api, signo, false ); a000ee18: e1a01005 mov r1, r5 a000ee1c: e3a02000 mov r2, #0 a000ee20: e1a00004 mov r0, r4 a000ee24: eb000916 bl a0011284 <_POSIX_signals_Check_signal> _POSIX_signals_Check_signal( api, signo, true ); a000ee28: e1a01005 mov r1, r5 a000ee2c: e1a00004 mov r0, r4 a000ee30: e3a02001 mov r2, #1 _POSIX_signals_Check_signal( api, signo, false ); _POSIX_signals_Check_signal( api, signo, true ); } /* Unfortunately - nothing like __SIGFIRSTNOTRT in newlib signal .h */ for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) { a000ee34: e2855001 add r5, r5, #1 _POSIX_signals_Check_signal( api, signo, false ); _POSIX_signals_Check_signal( api, signo, true ); a000ee38: eb000911 bl a0011284 <_POSIX_signals_Check_signal> _POSIX_signals_Check_signal( api, signo, false ); _POSIX_signals_Check_signal( api, signo, true ); } /* Unfortunately - nothing like __SIGFIRSTNOTRT in newlib signal .h */ for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) { a000ee3c: e355001b cmp r5, #27 a000ee40: 1afffff4 bne a000ee18 <_POSIX_signals_Post_switch_hook+0x8c> a000ee44: eaffffd8 b a000edac <_POSIX_signals_Post_switch_hook+0x20> a000ee48: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED =============================================================================== a0009e00 <_POSIX_signals_Ualarm_TSR>: static void _POSIX_signals_Ualarm_TSR( Objects_Id id __attribute__((unused)), void *argument __attribute__((unused)) ) { a0009e00: e92d4010 push {r4, lr} <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Watchdog_Reset( Watchdog_Control *the_watchdog ) { (void) _Watchdog_Remove( the_watchdog ); a0009e04: e59f4020 ldr r4, [pc, #32] ; a0009e2c <_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 ); a0009e08: ebfff1d7 bl a000656c <== NOT EXECUTED a0009e0c: e3a0100e mov r1, #14 <== NOT EXECUTED a0009e10: ebffff6f bl a0009bd4 <== NOT EXECUTED a0009e14: e1a00004 mov r0, r4 <== NOT EXECUTED a0009e18: eb000ee4 bl a000d9b0 <_Watchdog_Remove> <== NOT EXECUTED _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a0009e1c: e59f000c ldr r0, [pc, #12] ; a0009e30 <_POSIX_signals_Ualarm_TSR+0x30><== NOT EXECUTED a0009e20: e1a01004 mov r1, r4 <== NOT EXECUTED /* * If the reset interval is non-zero, reschedule ourselves. */ _Watchdog_Reset( &_POSIX_signals_Ualarm_timer ); } a0009e24: e8bd4010 pop {r4, lr} <== NOT EXECUTED a0009e28: ea000e89 b a000d854 <_Watchdog_Insert> <== NOT EXECUTED =============================================================================== a001ce50 <_POSIX_signals_Unblock_thread>: bool _POSIX_signals_Unblock_thread( Thread_Control *the_thread, int signo, siginfo_t *info ) { a001ce50: 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 ) ) { a001ce54: e5903010 ldr r3, [r0, #16] a001ce58: e59f5110 ldr r5, [pc, #272] ; a001cf70 <_POSIX_signals_Unblock_thread+0x120> a001ce5c: e59f810c ldr r8, [pc, #268] ; a001cf70 <_POSIX_signals_Unblock_thread+0x120> a001ce60: e241c001 sub ip, r1, #1 a001ce64: e0035005 and r5, r3, r5 a001ce68: e3a06001 mov r6, #1 a001ce6c: e1550008 cmp r5, r8 bool _POSIX_signals_Unblock_thread( Thread_Control *the_thread, int signo, siginfo_t *info ) { a001ce70: e1a04000 mov r4, r0 POSIX_API_Control *api; sigset_t mask; siginfo_t *the_info = NULL; api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a001ce74: e59070f4 ldr r7, [r0, #244] ; 0xf4 a001ce78: e1a0cc16 lsl ip, r6, ip /* * Is the thread is specifically waiting for a signal? */ if ( _States_Is_interruptible_signal( the_thread->current_state ) ) { a001ce7c: 1a000019 bne a001cee8 <_POSIX_signals_Unblock_thread+0x98> if ( (the_thread->Wait.option & mask) || (~api->signals_blocked & mask) ) { a001ce80: e5903030 ldr r3, [r0, #48] ; 0x30 <== NOT EXECUTED a001ce84: e11c0003 tst ip, r3 <== NOT EXECUTED a001ce88: 1a000002 bne a001ce98 <_POSIX_signals_Unblock_thread+0x48> <== NOT EXECUTED a001ce8c: e59750d0 ldr r5, [r7, #208] ; 0xd0 <== NOT EXECUTED a001ce90: e1dc5005 bics r5, ip, r5 <== NOT EXECUTED a001ce94: 0a000033 beq a001cf68 <_POSIX_signals_Unblock_thread+0x118><== NOT EXECUTED the_thread->Wait.return_code = EINTR; a001ce98: e3a03004 mov r3, #4 <== NOT EXECUTED the_info = (siginfo_t *) the_thread->Wait.return_argument; if ( !info ) { a001ce9c: 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; a001cea0: e5843034 str r3, [r4, #52] ; 0x34 <== NOT EXECUTED the_info = (siginfo_t *) the_thread->Wait.return_argument; a001cea4: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED if ( !info ) { the_info->si_signo = signo; a001cea8: 05831000 streq r1, [r3] <== NOT EXECUTED the_info->si_code = SI_USER; a001ceac: 03a01001 moveq r1, #1 <== NOT EXECUTED the_info->si_value.sival_int = 0; a001ceb0: 09830006 stmibeq r3, {r1, r2} <== NOT EXECUTED a001ceb4: 0a000007 beq a001ced8 <_POSIX_signals_Unblock_thread+0x88> <== NOT EXECUTED } else { *the_info = *info; a001ceb8: e1a00002 mov r0, r2 <== NOT EXECUTED a001cebc: e490c004 ldr ip, [r0], #4 <== NOT EXECUTED a001cec0: e1a01003 mov r1, r3 <== NOT EXECUTED a001cec4: e481c004 str ip, [r1], #4 <== NOT EXECUTED a001cec8: e5922004 ldr r2, [r2, #4] <== NOT EXECUTED a001cecc: e5832004 str r2, [r3, #4] <== NOT EXECUTED a001ced0: e5903004 ldr r3, [r0, #4] <== NOT EXECUTED a001ced4: e5813004 str r3, [r1, #4] <== NOT EXECUTED } _Thread_queue_Extract_with_proxy( the_thread ); a001ced8: e1a00004 mov r0, r4 <== NOT EXECUTED a001cedc: ebffbff6 bl a000cebc <_Thread_queue_Extract_with_proxy> <== NOT EXECUTED return true; a001cee0: e3a05001 mov r5, #1 <== NOT EXECUTED a001cee4: ea00001f b a001cf68 <_POSIX_signals_Unblock_thread+0x118> <== NOT EXECUTED } /* * Thread is not waiting due to a sigwait. */ if ( ~api->signals_blocked & mask ) { a001cee8: e59750d0 ldr r5, [r7, #208] ; 0xd0 a001ceec: e1dc5005 bics r5, ip, r5 a001cef0: 0a00001c beq a001cf68 <_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 ) ) { a001cef4: e2135201 ands r5, r3, #268435456 ; 0x10000000 a001cef8: 0a000010 beq a001cf40 <_POSIX_signals_Unblock_thread+0xf0> */ RTEMS_INLINE_ROUTINE bool _States_Is_waiting_on_thread_queue ( States_Control the_states ) { return (the_states & STATES_WAITING_ON_THREAD_QUEUE); a001cefc: e59f5070 ldr r5, [pc, #112] ; a001cf74 <_POSIX_signals_Unblock_thread+0x124> the_thread->Wait.return_code = EINTR; a001cf00: e3a02004 mov r2, #4 a001cf04: e5802034 str r2, [r0, #52] ; 0x34 a001cf08: e0035005 and r5, r3, r5 /* * 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) ) a001cf0c: e3550000 cmp r5, #0 a001cf10: 0a000002 beq a001cf20 <_POSIX_signals_Unblock_thread+0xd0> _Thread_queue_Extract_with_proxy( the_thread ); a001cf14: ebffbfe8 bl a000cebc <_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; a001cf18: e3a05000 mov r5, #0 <== NOT EXECUTED a001cf1c: ea000011 b a001cf68 <_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) ) { a001cf20: e2133008 ands r3, r3, #8 a001cf24: 0a00000e beq a001cf64 <_POSIX_signals_Unblock_thread+0x114> (void) _Watchdog_Remove( &the_thread->Timer ); a001cf28: e2800048 add r0, r0, #72 ; 0x48 a001cf2c: ebffc166 bl a000d4cc <_Watchdog_Remove> RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); a001cf30: e1a00004 mov r0, r4 a001cf34: e59f103c ldr r1, [pc, #60] ; a001cf78 <_POSIX_signals_Unblock_thread+0x128> a001cf38: ebffbd4b bl a000c46c <_Thread_Clear_state> a001cf3c: ea000009 b a001cf68 <_POSIX_signals_Unblock_thread+0x118> _Thread_Unblock( the_thread ); } } else if ( the_thread->current_state == STATES_READY ) { a001cf40: e3530000 cmp r3, #0 <== NOT EXECUTED a001cf44: 1a000007 bne a001cf68 <_POSIX_signals_Unblock_thread+0x118><== NOT EXECUTED if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) ) a001cf48: e59f202c ldr r2, [pc, #44] ; a001cf7c <_POSIX_signals_Unblock_thread+0x12c><== NOT EXECUTED a001cf4c: e5925000 ldr r5, [r2] <== NOT EXECUTED a001cf50: e3550000 cmp r5, #0 <== NOT EXECUTED a001cf54: 0a000003 beq a001cf68 <_POSIX_signals_Unblock_thread+0x118><== NOT EXECUTED a001cf58: e5921008 ldr r1, [r2, #8] <== NOT EXECUTED a001cf5c: e1500001 cmp r0, r1 <== NOT EXECUTED _Thread_Dispatch_necessary = true; a001cf60: 05c26004 strbeq r6, [r2, #4] <== NOT EXECUTED } } return false; a001cf64: e1a05003 mov r5, r3 <== NOT EXECUTED } a001cf68: e1a00005 mov r0, r5 a001cf6c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a0010b08 <_Protected_heap_Get_information>: bool _Protected_heap_Get_information( Heap_Control *the_heap, Heap_Information_block *the_info ) { a0010b08: e92d4070 push {r4, r5, r6, lr} if ( !the_heap ) a0010b0c: e2506000 subs r6, r0, #0 bool _Protected_heap_Get_information( Heap_Control *the_heap, Heap_Information_block *the_info ) { a0010b10: e1a05001 mov r5, r1 if ( !the_heap ) a0010b14: 0a00000b beq a0010b48 <_Protected_heap_Get_information+0x40> return false; if ( !the_info ) a0010b18: e3510000 cmp r1, #0 a0010b1c: 0a00000b beq a0010b50 <_Protected_heap_Get_information+0x48> return false; _RTEMS_Lock_allocator(); a0010b20: e59f4030 ldr r4, [pc, #48] ; a0010b58 <_Protected_heap_Get_information+0x50> a0010b24: e5940000 ldr r0, [r4] a0010b28: ebfff82c bl a000ebe0 <_API_Mutex_Lock> _Heap_Get_information( the_heap, the_info ); a0010b2c: e1a00006 mov r0, r6 a0010b30: e1a01005 mov r1, r5 a0010b34: eb00101d bl a0014bb0 <_Heap_Get_information> _RTEMS_Unlock_allocator(); a0010b38: e5940000 ldr r0, [r4] a0010b3c: ebfff840 bl a000ec44 <_API_Mutex_Unlock> return true; a0010b40: e3a00001 mov r0, #1 a0010b44: e8bd8070 pop {r4, r5, r6, pc} Heap_Control *the_heap, Heap_Information_block *the_info ) { if ( !the_heap ) return false; a0010b48: e1a00006 mov r0, r6 <== NOT EXECUTED a0010b4c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED if ( !the_info ) return false; a0010b50: e1a00001 mov r0, r1 <== NOT EXECUTED _RTEMS_Lock_allocator(); _Heap_Get_information( the_heap, the_info ); _RTEMS_Unlock_allocator(); return true; } a0010b54: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED =============================================================================== a0010bb8 <_Protected_heap_Walk>: * This routine returns true if thread dispatch indicates * that we are in a critical section. */ RTEMS_INLINE_ROUTINE bool _Thread_Dispatch_in_critical_section(void) { if ( _Thread_Dispatch_disable_level == 0 ) a0010bb8: e59f3054 ldr r3, [pc, #84] ; a0010c14 <_Protected_heap_Walk+0x5c><== NOT EXECUTED bool _Protected_heap_Walk( Heap_Control *the_heap, int source, bool do_dump ) { a0010bbc: e92d40f0 push {r4, r5, r6, r7, lr} <== NOT EXECUTED a0010bc0: e5933000 ldr r3, [r3] <== NOT EXECUTED a0010bc4: e1a06000 mov r6, r0 <== NOT EXECUTED a0010bc8: e1a05001 mov r5, r1 <== NOT EXECUTED a0010bcc: e3530000 cmp r3, #0 <== NOT EXECUTED a0010bd0: e20270ff and r7, r2, #255 ; 0xff <== NOT EXECUTED a0010bd4: 1a00000b bne a0010c08 <_Protected_heap_Walk+0x50> <== NOT EXECUTED * a critical section, it should be safe to walk it unlocked. * * NOTE: Dispatching is also disabled during initialization. */ if ( _Thread_Dispatch_in_critical_section() == false ) { _RTEMS_Lock_allocator(); a0010bd8: e59f4038 ldr r4, [pc, #56] ; a0010c18 <_Protected_heap_Walk+0x60><== NOT EXECUTED a0010bdc: e5940000 ldr r0, [r4] <== NOT EXECUTED a0010be0: ebfff7fe bl a000ebe0 <_API_Mutex_Lock> <== NOT EXECUTED status = _Heap_Walk( the_heap, source, do_dump ); a0010be4: e1a01005 mov r1, r5 <== NOT EXECUTED a0010be8: e1a02007 mov r2, r7 <== NOT EXECUTED a0010bec: e1a00006 mov r0, r6 <== NOT EXECUTED a0010bf0: ebfffc2e bl a000fcb0 <_Heap_Walk> <== NOT EXECUTED a0010bf4: e1a05000 mov r5, r0 <== NOT EXECUTED _RTEMS_Unlock_allocator(); a0010bf8: e5940000 ldr r0, [r4] <== NOT EXECUTED a0010bfc: ebfff810 bl a000ec44 <_API_Mutex_Unlock> <== NOT EXECUTED } else { status = _Heap_Walk( the_heap, source, do_dump ); } return status; } a0010c00: e1a00005 mov r0, r5 <== NOT EXECUTED a0010c04: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED if ( _Thread_Dispatch_in_critical_section() == false ) { _RTEMS_Lock_allocator(); status = _Heap_Walk( the_heap, source, do_dump ); _RTEMS_Unlock_allocator(); } else { status = _Heap_Walk( the_heap, source, do_dump ); a0010c08: e1a02007 mov r2, r7 <== NOT EXECUTED } return status; } a0010c0c: e8bd40f0 pop {r4, r5, r6, r7, lr} <== NOT EXECUTED if ( _Thread_Dispatch_in_critical_section() == false ) { _RTEMS_Lock_allocator(); status = _Heap_Walk( the_heap, source, do_dump ); _RTEMS_Unlock_allocator(); } else { status = _Heap_Walk( the_heap, source, do_dump ); a0010c10: eafffc26 b a000fcb0 <_Heap_Walk> <== NOT EXECUTED =============================================================================== a000c898 <_RBTree_Sibling>: */ RTEMS_INLINE_ROUTINE RBTree_Node *_RBTree_Sibling( const RBTree_Node *the_node ) { if(!the_node) return NULL; a000c898: e2502000 subs r2, r0, #0 a000c89c: 01a00002 moveq r0, r2 a000c8a0: 012fff1e bxeq lr if(!(the_node->parent)) return NULL; a000c8a4: e5923000 ldr r3, [r2] a000c8a8: e3530000 cmp r3, #0 a000c8ac: 0a000006 beq a000c8cc <_RBTree_Sibling+0x34> if(!(the_node->parent->parent)) return NULL; a000c8b0: e5930000 ldr r0, [r3] a000c8b4: e3500000 cmp r0, #0 a000c8b8: 012fff1e bxeq lr if(the_node == the_node->parent->child[RBT_LEFT]) a000c8bc: e5930004 ldr r0, [r3, #4] a000c8c0: e1520000 cmp r2, r0 return the_node->parent->child[RBT_RIGHT]; a000c8c4: 05930008 ldreq r0, [r3, #8] a000c8c8: e12fff1e bx lr RTEMS_INLINE_ROUTINE RBTree_Node *_RBTree_Sibling( const RBTree_Node *the_node ) { if(!the_node) return NULL; if(!(the_node->parent)) return NULL; a000c8cc: e1a00003 mov r0, r3 <== NOT EXECUTED if(the_node == the_node->parent->child[RBT_LEFT]) return the_node->parent->child[RBT_RIGHT]; else return the_node->parent->child[RBT_LEFT]; } a000c8d0: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000f574 <_RTEMS_tasks_Delete_extension>: /* * Free per task variable memory */ tvp = deleted->task_variables; deleted->task_variables = NULL; a000f574: e3a03000 mov r3, #0 static void _RTEMS_tasks_Delete_extension( Thread_Control *executing, Thread_Control *deleted ) { a000f578: e92d4070 push {r4, r5, r6, lr} /* * Free per task variable memory */ tvp = deleted->task_variables; a000f57c: e59160fc ldr r6, [r1, #252] ; 0xfc static void _RTEMS_tasks_Delete_extension( Thread_Control *executing, Thread_Control *deleted ) { a000f580: e1a04001 mov r4, r1 /* * Free per task variable memory */ tvp = deleted->task_variables; deleted->task_variables = NULL; a000f584: e58130fc str r3, [r1, #252] ; 0xfc while (tvp) { a000f588: ea000004 b a000f5a0 <_RTEMS_tasks_Delete_extension+0x2c> next = (rtems_task_variable_t *)tvp->next; _RTEMS_Tasks_Invoke_task_variable_dtor( deleted, tvp ); a000f58c: e1a01006 mov r1, r6 <== NOT EXECUTED a000f590: e1a00004 mov r0, r4 <== NOT EXECUTED */ tvp = deleted->task_variables; deleted->task_variables = NULL; while (tvp) { next = (rtems_task_variable_t *)tvp->next; a000f594: e5965000 ldr r5, [r6] <== NOT EXECUTED _RTEMS_Tasks_Invoke_task_variable_dtor( deleted, tvp ); a000f598: eb00003d bl a000f694 <_RTEMS_Tasks_Invoke_task_variable_dtor><== NOT EXECUTED tvp = next; a000f59c: e1a06005 mov r6, r5 <== NOT EXECUTED * Free per task variable memory */ tvp = deleted->task_variables; deleted->task_variables = NULL; while (tvp) { a000f5a0: e3560000 cmp r6, #0 a000f5a4: 1afffff8 bne a000f58c <_RTEMS_tasks_Delete_extension+0x18> /* * Free API specific memory */ (void) _Workspace_Free( deleted->API_Extensions[ THREAD_API_RTEMS ] ); a000f5a8: e59400f0 ldr r0, [r4, #240] ; 0xf0 a000f5ac: ebfff858 bl a000d714 <_Workspace_Free> deleted->API_Extensions[ THREAD_API_RTEMS ] = NULL; a000f5b0: e58460f0 str r6, [r4, #240] ; 0xf0 } a000f5b4: e8bd8070 pop {r4, r5, r6, pc} =============================================================================== a000f500 <_RTEMS_tasks_Switch_extension>: /* * Per Task Variables */ tvp = executing->task_variables; a000f500: e59030fc ldr r3, [r0, #252] ; 0xfc while (tvp) { a000f504: ea000005 b a000f520 <_RTEMS_tasks_Switch_extension+0x20> tvp->tval = *tvp->ptr; a000f508: e5932004 ldr r2, [r3, #4] a000f50c: e5920000 ldr r0, [r2] a000f510: e583000c str r0, [r3, #12] *tvp->ptr = tvp->gval; a000f514: e5930008 ldr r0, [r3, #8] a000f518: e5820000 str r0, [r2] tvp = (rtems_task_variable_t *)tvp->next; a000f51c: e5933000 ldr r3, [r3] /* * Per Task Variables */ tvp = executing->task_variables; while (tvp) { a000f520: e3530000 cmp r3, #0 a000f524: 1afffff7 bne a000f508 <_RTEMS_tasks_Switch_extension+0x8> tvp->tval = *tvp->ptr; *tvp->ptr = tvp->gval; tvp = (rtems_task_variable_t *)tvp->next; } tvp = heir->task_variables; a000f528: e59130fc ldr r3, [r1, #252] ; 0xfc while (tvp) { a000f52c: ea000005 b a000f548 <_RTEMS_tasks_Switch_extension+0x48> tvp->gval = *tvp->ptr; a000f530: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED a000f534: e5921000 ldr r1, [r2] <== NOT EXECUTED a000f538: e5831008 str r1, [r3, #8] <== NOT EXECUTED *tvp->ptr = tvp->tval; a000f53c: e593100c ldr r1, [r3, #12] <== NOT EXECUTED a000f540: e5821000 str r1, [r2] <== NOT EXECUTED tvp = (rtems_task_variable_t *)tvp->next; a000f544: e5933000 ldr r3, [r3] <== NOT EXECUTED *tvp->ptr = tvp->gval; tvp = (rtems_task_variable_t *)tvp->next; } tvp = heir->task_variables; while (tvp) { a000f548: e3530000 cmp r3, #0 a000f54c: 1afffff7 bne a000f530 <_RTEMS_tasks_Switch_extension+0x30> tvp->gval = *tvp->ptr; *tvp->ptr = tvp->tval; tvp = (rtems_task_variable_t *)tvp->next; } } a000f550: e12fff1e bx lr =============================================================================== a0032ac0 <_Rate_monotonic_Timeout>: void _Rate_monotonic_Timeout( Objects_Id id, void *ignored ) { a0032ac0: e92d4011 push {r0, r4, lr} <== NOT EXECUTED a0032ac4: e1a01000 mov r1, r0 <== NOT EXECUTED a0032ac8: e1a0200d mov r2, sp <== NOT EXECUTED a0032acc: e59f0088 ldr r0, [pc, #136] ; a0032b5c <_Rate_monotonic_Timeout+0x9c><== NOT EXECUTED a0032ad0: ebff65c8 bl a000c1f8 <_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 ) { a0032ad4: e59d3000 ldr r3, [sp] <== NOT EXECUTED a0032ad8: e1a04000 mov r4, r0 <== NOT EXECUTED a0032adc: e3530000 cmp r3, #0 <== NOT EXECUTED a0032ae0: 1a00001c bne a0032b58 <_Rate_monotonic_Timeout+0x98> <== NOT EXECUTED case OBJECTS_LOCAL: the_thread = the_period->owner; a0032ae4: 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); a0032ae8: e5903010 ldr r3, [r0, #16] <== NOT EXECUTED if ( _States_Is_waiting_for_period( the_thread->current_state ) && a0032aec: e3130901 tst r3, #16384 ; 0x4000 <== NOT EXECUTED a0032af0: 0a000006 beq a0032b10 <_Rate_monotonic_Timeout+0x50> <== NOT EXECUTED a0032af4: e5902020 ldr r2, [r0, #32] <== NOT EXECUTED a0032af8: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED a0032afc: e1520003 cmp r2, r3 <== NOT EXECUTED a0032b00: 1a000002 bne a0032b10 <_Rate_monotonic_Timeout+0x50> <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); a0032b04: e59f1054 ldr r1, [pc, #84] ; a0032b60 <_Rate_monotonic_Timeout+0xa0><== NOT EXECUTED a0032b08: ebff684c bl a000cc40 <_Thread_Clear_state> <== NOT EXECUTED a0032b0c: ea000006 b a0032b2c <_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 ) { a0032b10: e5943038 ldr r3, [r4, #56] ; 0x38 <== NOT EXECUTED a0032b14: 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; a0032b18: 13a03004 movne r3, #4 <== NOT EXECUTED a0032b1c: 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 ) { a0032b20: 1a000008 bne a0032b48 <_Rate_monotonic_Timeout+0x88> <== NOT EXECUTED the_period->state = RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING; a0032b24: e3a03003 mov r3, #3 <== NOT EXECUTED a0032b28: e5843038 str r3, [r4, #56] ; 0x38 <== NOT EXECUTED _Rate_monotonic_Initiate_statistics( the_period ); a0032b2c: e1a00004 mov r0, r4 <== NOT EXECUTED a0032b30: ebffff54 bl a0032888 <_Rate_monotonic_Initiate_statistics> <== NOT EXECUTED Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a0032b34: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a0032b38: e59f0024 ldr r0, [pc, #36] ; a0032b64 <_Rate_monotonic_Timeout+0xa4><== NOT EXECUTED a0032b3c: e2841010 add r1, r4, #16 <== NOT EXECUTED Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a0032b40: e584301c str r3, [r4, #28] <== NOT EXECUTED _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a0032b44: ebff6bfe bl a000db44 <_Watchdog_Insert> <== NOT EXECUTED * * This routine decrements the thread dispatch level. */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0032b48: e59f3018 ldr r3, [pc, #24] ; a0032b68 <_Rate_monotonic_Timeout+0xa8><== NOT EXECUTED a0032b4c: e5932000 ldr r2, [r3] <== NOT EXECUTED --level; a0032b50: e2422001 sub r2, r2, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a0032b54: e5832000 str r2, [r3] <== NOT EXECUTED case OBJECTS_REMOTE: /* impossible */ #endif case OBJECTS_ERROR: break; } } a0032b58: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED =============================================================================== a000db1c <_Scheduler_CBS_Budget_callout>: Priority_Control new_priority; Scheduler_CBS_Per_thread *sched_info; Scheduler_CBS_Server_id server_id; /* Put violating task to background until the end of period. */ new_priority = the_thread->Start.initial_priority; a000db1c: e59010ac ldr r1, [r0, #172] ; 0xac <== NOT EXECUTED if ( the_thread->real_priority != new_priority ) a000db20: e5903018 ldr r3, [r0, #24] <== NOT EXECUTED Scheduler_CBS_Server **_Scheduler_CBS_Server_list; void _Scheduler_CBS_Budget_callout( Thread_Control *the_thread ) { a000db24: e92d4011 push {r0, r4, lr} <== NOT EXECUTED Scheduler_CBS_Per_thread *sched_info; Scheduler_CBS_Server_id server_id; /* Put violating task to background until the end of period. */ new_priority = the_thread->Start.initial_priority; if ( the_thread->real_priority != new_priority ) a000db28: e1530001 cmp r3, r1 <== NOT EXECUTED the_thread->real_priority = new_priority; if ( the_thread->current_priority != new_priority ) a000db2c: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED Scheduler_CBS_Server_id server_id; /* Put violating task to background until the end of period. */ new_priority = the_thread->Start.initial_priority; if ( the_thread->real_priority != new_priority ) the_thread->real_priority = new_priority; a000db30: 15801018 strne r1, [r0, #24] <== NOT EXECUTED Scheduler_CBS_Server **_Scheduler_CBS_Server_list; void _Scheduler_CBS_Budget_callout( Thread_Control *the_thread ) { a000db34: e1a04000 mov r4, r0 <== NOT EXECUTED /* Put violating task to background until the end of period. */ new_priority = the_thread->Start.initial_priority; if ( the_thread->real_priority != new_priority ) the_thread->real_priority = new_priority; if ( the_thread->current_priority != new_priority ) a000db38: e1530001 cmp r3, r1 <== NOT EXECUTED a000db3c: 0a000001 beq a000db48 <_Scheduler_CBS_Budget_callout+0x2c> <== NOT EXECUTED _Thread_Change_priority(the_thread, new_priority, true); a000db40: e3a02001 mov r2, #1 <== NOT EXECUTED a000db44: eb000165 bl a000e0e0 <_Thread_Change_priority> <== NOT EXECUTED /* Invoke callback function if any. */ sched_info = (Scheduler_CBS_Per_thread *) the_thread->scheduler_info; a000db48: e5944088 ldr r4, [r4, #136] ; 0x88 <== NOT EXECUTED if ( sched_info->cbs_server->cbs_budget_overrun ) { a000db4c: e5943018 ldr r3, [r4, #24] <== NOT EXECUTED a000db50: e593200c ldr r2, [r3, #12] <== NOT EXECUTED a000db54: e3520000 cmp r2, #0 <== NOT EXECUTED a000db58: 0a000006 beq a000db78 <_Scheduler_CBS_Budget_callout+0x5c> <== NOT EXECUTED _Scheduler_CBS_Get_server_id( a000db5c: e5930000 ldr r0, [r3] <== NOT EXECUTED a000db60: e1a0100d mov r1, sp <== NOT EXECUTED a000db64: ebffffd5 bl a000dac0 <_Scheduler_CBS_Get_server_id> <== NOT EXECUTED sched_info->cbs_server->task_id, &server_id ); sched_info->cbs_server->cbs_budget_overrun( server_id ); a000db68: e5943018 ldr r3, [r4, #24] <== NOT EXECUTED a000db6c: e59d0000 ldr r0, [sp] <== NOT EXECUTED a000db70: e593300c ldr r3, [r3, #12] <== NOT EXECUTED a000db74: e12fff33 blx r3 <== NOT EXECUTED } } a000db78: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED =============================================================================== a000d748 <_Scheduler_CBS_Create_server>: ) { unsigned int i; Scheduler_CBS_Server *the_server; if ( params->budget <= 0 || a000d748: e5903004 ldr r3, [r0, #4] int _Scheduler_CBS_Create_server ( Scheduler_CBS_Parameters *params, Scheduler_CBS_Budget_overrun budget_overrun_callback, rtems_id *server_id ) { a000d74c: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} unsigned int i; Scheduler_CBS_Server *the_server; if ( params->budget <= 0 || a000d750: e3530000 cmp r3, #0 int _Scheduler_CBS_Create_server ( Scheduler_CBS_Parameters *params, Scheduler_CBS_Budget_overrun budget_overrun_callback, rtems_id *server_id ) { a000d754: e1a04000 mov r4, r0 a000d758: e1a05001 mov r5, r1 a000d75c: e1a0a002 mov sl, r2 unsigned int i; Scheduler_CBS_Server *the_server; if ( params->budget <= 0 || a000d760: da000023 ble a000d7f4 <_Scheduler_CBS_Create_server+0xac> a000d764: e5903000 ldr r3, [r0] a000d768: e3530000 cmp r3, #0 a000d76c: da000020 ble a000d7f4 <_Scheduler_CBS_Create_server+0xac> params->deadline <= 0 || params->budget >= SCHEDULER_EDF_PRIO_MSB || params->deadline >= SCHEDULER_EDF_PRIO_MSB ) return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; for ( i = 0; i<_Scheduler_CBS_Maximum_servers; i++ ) { a000d770: e59f308c ldr r3, [pc, #140] ; a000d804 <_Scheduler_CBS_Create_server+0xbc> if ( !_Scheduler_CBS_Server_list[i] ) a000d774: e3a06000 mov r6, #0 params->deadline <= 0 || params->budget >= SCHEDULER_EDF_PRIO_MSB || params->deadline >= SCHEDULER_EDF_PRIO_MSB ) return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; for ( i = 0; i<_Scheduler_CBS_Maximum_servers; i++ ) { a000d778: e5932000 ldr r2, [r3] a000d77c: e59f3084 ldr r3, [pc, #132] ; a000d808 <_Scheduler_CBS_Create_server+0xc0> a000d780: e5933000 ldr r3, [r3] a000d784: ea00000f b a000d7c8 <_Scheduler_CBS_Create_server+0x80> if ( !_Scheduler_CBS_Server_list[i] ) a000d788: e4937004 ldr r7, [r3], #4 a000d78c: e3570000 cmp r7, #0 a000d790: 1a00000b bne a000d7c4 <_Scheduler_CBS_Create_server+0x7c> if ( i == _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_FULL; *server_id = i; _Scheduler_CBS_Server_list[*server_id] = (Scheduler_CBS_Server *) a000d794: e59f806c ldr r8, [pc, #108] ; a000d808 <_Scheduler_CBS_Create_server+0xc0> } if ( i == _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_FULL; *server_id = i; a000d798: e58a6000 str r6, [sl] _Scheduler_CBS_Server_list[*server_id] = (Scheduler_CBS_Server *) _Workspace_Allocate( sizeof(Scheduler_CBS_Server) ); a000d79c: e3a00010 mov r0, #16 if ( i == _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_FULL; *server_id = i; _Scheduler_CBS_Server_list[*server_id] = (Scheduler_CBS_Server *) a000d7a0: e5989000 ldr r9, [r8] _Workspace_Allocate( sizeof(Scheduler_CBS_Server) ); a000d7a4: eb00072d bl a000f460 <_Workspace_Allocate> if ( i == _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_FULL; *server_id = i; _Scheduler_CBS_Server_list[*server_id] = (Scheduler_CBS_Server *) a000d7a8: e7890106 str r0, [r9, r6, lsl #2] _Workspace_Allocate( sizeof(Scheduler_CBS_Server) ); the_server = _Scheduler_CBS_Server_list[*server_id]; a000d7ac: e59a2000 ldr r2, [sl] a000d7b0: e5983000 ldr r3, [r8] a000d7b4: e7933102 ldr r3, [r3, r2, lsl #2] if ( !the_server ) a000d7b8: e3530000 cmp r3, #0 a000d7bc: 1a000005 bne a000d7d8 <_Scheduler_CBS_Create_server+0x90> a000d7c0: ea00000d b a000d7fc <_Scheduler_CBS_Create_server+0xb4> <== NOT EXECUTED params->deadline <= 0 || params->budget >= SCHEDULER_EDF_PRIO_MSB || params->deadline >= SCHEDULER_EDF_PRIO_MSB ) return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; for ( i = 0; i<_Scheduler_CBS_Maximum_servers; i++ ) { a000d7c4: e2866001 add r6, r6, #1 a000d7c8: e1560002 cmp r6, r2 a000d7cc: 1affffed bne a000d788 <_Scheduler_CBS_Create_server+0x40> if ( !_Scheduler_CBS_Server_list[i] ) break; } if ( i == _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_FULL; a000d7d0: e3e00019 mvn r0, #25 a000d7d4: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} the_server = _Scheduler_CBS_Server_list[*server_id]; if ( !the_server ) return SCHEDULER_CBS_ERROR_NO_MEMORY; the_server->parameters = *params; the_server->task_id = -1; a000d7d8: e3e02000 mvn r2, #0 _Workspace_Allocate( sizeof(Scheduler_CBS_Server) ); the_server = _Scheduler_CBS_Server_list[*server_id]; if ( !the_server ) return SCHEDULER_CBS_ERROR_NO_MEMORY; the_server->parameters = *params; a000d7dc: e8940003 ldm r4, {r0, r1} the_server->task_id = -1; a000d7e0: e5832000 str r2, [r3] _Workspace_Allocate( sizeof(Scheduler_CBS_Server) ); the_server = _Scheduler_CBS_Server_list[*server_id]; if ( !the_server ) return SCHEDULER_CBS_ERROR_NO_MEMORY; the_server->parameters = *params; a000d7e4: e9830003 stmib r3, {r0, r1} the_server->task_id = -1; the_server->cbs_budget_overrun = budget_overrun_callback; a000d7e8: e583500c str r5, [r3, #12] return SCHEDULER_CBS_OK; a000d7ec: e1a00007 mov r0, r7 a000d7f0: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} if ( params->budget <= 0 || params->deadline <= 0 || params->budget >= SCHEDULER_EDF_PRIO_MSB || params->deadline >= SCHEDULER_EDF_PRIO_MSB ) return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; a000d7f4: e3e00011 mvn r0, #17 a000d7f8: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} *server_id = i; _Scheduler_CBS_Server_list[*server_id] = (Scheduler_CBS_Server *) _Workspace_Allocate( sizeof(Scheduler_CBS_Server) ); the_server = _Scheduler_CBS_Server_list[*server_id]; if ( !the_server ) return SCHEDULER_CBS_ERROR_NO_MEMORY; a000d7fc: e3e00010 mvn r0, #16 <== NOT EXECUTED the_server->parameters = *params; the_server->task_id = -1; the_server->cbs_budget_overrun = budget_overrun_callback; return SCHEDULER_CBS_OK; } a000d800: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED =============================================================================== a000d960 <_Scheduler_CBS_Get_execution_time>: ) { Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) a000d960: e59f3090 ldr r3, [pc, #144] ; a000d9f8 <_Scheduler_CBS_Get_execution_time+0x98> int _Scheduler_CBS_Get_execution_time ( Scheduler_CBS_Server_id server_id, time_t *exec_time, time_t *abs_time ) { a000d964: e92d40f1 push {r0, r4, r5, r6, r7, lr} Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) a000d968: e5933000 ldr r3, [r3] int _Scheduler_CBS_Get_execution_time ( Scheduler_CBS_Server_id server_id, time_t *exec_time, time_t *abs_time ) { a000d96c: e1a04000 mov r4, r0 a000d970: e1a05001 mov r5, r1 Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) a000d974: e1500003 cmp r0, r3 return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; a000d978: 23e00011 mvncs r0, #17 ) { Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) a000d97c: 2a00001c bcs a000d9f4 <_Scheduler_CBS_Get_execution_time+0x94> return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; if ( !_Scheduler_CBS_Server_list[server_id] ) a000d980: e59f6074 ldr r6, [pc, #116] ; a000d9fc <_Scheduler_CBS_Get_execution_time+0x9c> a000d984: e5963000 ldr r3, [r6] a000d988: e7933104 ldr r3, [r3, r4, lsl #2] a000d98c: e3530000 cmp r3, #0 return SCHEDULER_CBS_ERROR_NOSERVER; a000d990: 03e00018 mvneq r0, #24 Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; if ( !_Scheduler_CBS_Server_list[server_id] ) a000d994: 0a000016 beq a000d9f4 <_Scheduler_CBS_Get_execution_time+0x94> return SCHEDULER_CBS_ERROR_NOSERVER; if ( _Scheduler_CBS_Server_list[server_id]->task_id == -1 ) { a000d998: e5930000 ldr r0, [r3] a000d99c: e3700001 cmn r0, #1 *exec_time = 0; a000d9a0: 03a00000 moveq r0, #0 a000d9a4: 05810000 streq r0, [r1] if ( server_id >= _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; if ( !_Scheduler_CBS_Server_list[server_id] ) return SCHEDULER_CBS_ERROR_NOSERVER; if ( _Scheduler_CBS_Server_list[server_id]->task_id == -1 ) { a000d9a8: 0a000011 beq a000d9f4 <_Scheduler_CBS_Get_execution_time+0x94> *exec_time = 0; return SCHEDULER_CBS_OK; } the_thread = _Thread_Get( a000d9ac: e1a0100d mov r1, sp <== NOT EXECUTED a000d9b0: eb0002eb bl a000e564 <_Thread_Get> <== NOT EXECUTED _Scheduler_CBS_Server_list[server_id]->task_id, &location ); /* The routine _Thread_Get may disable dispatch and not enable again. */ if ( the_thread ) { a000d9b4: e2507000 subs r7, r0, #0 <== NOT EXECUTED a000d9b8: 0a000008 beq a000d9e0 <_Scheduler_CBS_Get_execution_time+0x80><== NOT EXECUTED _Thread_Enable_dispatch(); a000d9bc: eb0002e0 bl a000e544 <_Thread_Enable_dispatch> <== NOT EXECUTED *exec_time = _Scheduler_CBS_Server_list[server_id]->parameters.budget - a000d9c0: e5963000 ldr r3, [r6] <== NOT EXECUTED the_thread->cpu_time_budget; } else { *exec_time = _Scheduler_CBS_Server_list[server_id]->parameters.budget; } return SCHEDULER_CBS_OK; a000d9c4: e3a00000 mov r0, #0 <== NOT EXECUTED &location ); /* The routine _Thread_Get may disable dispatch and not enable again. */ if ( the_thread ) { _Thread_Enable_dispatch(); *exec_time = _Scheduler_CBS_Server_list[server_id]->parameters.budget - a000d9c8: e7933104 ldr r3, [r3, r4, lsl #2] <== NOT EXECUTED a000d9cc: e5932008 ldr r2, [r3, #8] <== NOT EXECUTED a000d9d0: e5973074 ldr r3, [r7, #116] ; 0x74 <== NOT EXECUTED a000d9d4: e0633002 rsb r3, r3, r2 <== NOT EXECUTED a000d9d8: e5853000 str r3, [r5] <== NOT EXECUTED a000d9dc: ea000004 b a000d9f4 <_Scheduler_CBS_Get_execution_time+0x94><== NOT EXECUTED the_thread->cpu_time_budget; } else { *exec_time = _Scheduler_CBS_Server_list[server_id]->parameters.budget; a000d9e0: e5963000 ldr r3, [r6] <== NOT EXECUTED } return SCHEDULER_CBS_OK; a000d9e4: e1a00007 mov r0, r7 <== NOT EXECUTED _Thread_Enable_dispatch(); *exec_time = _Scheduler_CBS_Server_list[server_id]->parameters.budget - the_thread->cpu_time_budget; } else { *exec_time = _Scheduler_CBS_Server_list[server_id]->parameters.budget; a000d9e8: e7933104 ldr r3, [r3, r4, lsl #2] <== NOT EXECUTED a000d9ec: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED a000d9f0: e5853000 str r3, [r5] <== NOT EXECUTED } return SCHEDULER_CBS_OK; } a000d9f4: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} =============================================================================== a000da48 <_Scheduler_CBS_Get_remaining_budget>: ) { Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) a000da48: e59f3068 ldr r3, [pc, #104] ; a000dab8 <_Scheduler_CBS_Get_remaining_budget+0x70> int _Scheduler_CBS_Get_remaining_budget ( Scheduler_CBS_Server_id server_id, time_t *remaining_budget ) { a000da4c: e92d4031 push {r0, r4, r5, lr} Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) a000da50: e5933000 ldr r3, [r3] int _Scheduler_CBS_Get_remaining_budget ( Scheduler_CBS_Server_id server_id, time_t *remaining_budget ) { a000da54: e1a04001 mov r4, r1 Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) a000da58: e1500003 cmp r0, r3 return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; a000da5c: 23e00011 mvncs r0, #17 ) { Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) a000da60: 2a000013 bcs a000dab4 <_Scheduler_CBS_Get_remaining_budget+0x6c> return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; if ( !_Scheduler_CBS_Server_list[server_id] ) a000da64: e59f3050 ldr r3, [pc, #80] ; a000dabc <_Scheduler_CBS_Get_remaining_budget+0x74> a000da68: e5933000 ldr r3, [r3] a000da6c: e7933100 ldr r3, [r3, r0, lsl #2] a000da70: e3530000 cmp r3, #0 return SCHEDULER_CBS_ERROR_NOSERVER; a000da74: 03e00018 mvneq r0, #24 Objects_Locations location; Thread_Control *the_thread; if ( server_id >= _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; if ( !_Scheduler_CBS_Server_list[server_id] ) a000da78: 0a00000d beq a000dab4 <_Scheduler_CBS_Get_remaining_budget+0x6c> return SCHEDULER_CBS_ERROR_NOSERVER; if ( _Scheduler_CBS_Server_list[server_id]->task_id == -1 ) { a000da7c: e5930000 ldr r0, [r3] a000da80: e3700001 cmn r0, #1 *remaining_budget = _Scheduler_CBS_Server_list[server_id]->parameters.budget; a000da84: 05933008 ldreq r3, [r3, #8] if ( server_id >= _Scheduler_CBS_Maximum_servers ) return SCHEDULER_CBS_ERROR_INVALID_PARAMETER; if ( !_Scheduler_CBS_Server_list[server_id] ) return SCHEDULER_CBS_ERROR_NOSERVER; if ( _Scheduler_CBS_Server_list[server_id]->task_id == -1 ) { a000da88: 0a000007 beq a000daac <_Scheduler_CBS_Get_remaining_budget+0x64> *remaining_budget = _Scheduler_CBS_Server_list[server_id]->parameters.budget; return SCHEDULER_CBS_OK; } the_thread = _Thread_Get( a000da8c: e1a0100d mov r1, sp <== NOT EXECUTED a000da90: eb0002b3 bl a000e564 <_Thread_Get> <== NOT EXECUTED _Scheduler_CBS_Server_list[server_id]->task_id, &location ); /* The routine _Thread_Get may disable dispatch and not enable again. */ if ( the_thread ) { a000da94: e2505000 subs r5, r0, #0 <== NOT EXECUTED _Thread_Enable_dispatch(); *remaining_budget = the_thread->cpu_time_budget; } else { *remaining_budget = 0; a000da98: 05845000 streq r5, [r4] <== NOT EXECUTED } return SCHEDULER_CBS_OK; a000da9c: 01a00005 moveq r0, r5 <== NOT EXECUTED the_thread = _Thread_Get( _Scheduler_CBS_Server_list[server_id]->task_id, &location ); /* The routine _Thread_Get may disable dispatch and not enable again. */ if ( the_thread ) { a000daa0: 0a000003 beq a000dab4 <_Scheduler_CBS_Get_remaining_budget+0x6c><== NOT EXECUTED _Thread_Enable_dispatch(); a000daa4: eb0002a6 bl a000e544 <_Thread_Enable_dispatch> <== NOT EXECUTED *remaining_budget = the_thread->cpu_time_budget; a000daa8: e5953074 ldr r3, [r5, #116] ; 0x74 <== NOT EXECUTED a000daac: e5843000 str r3, [r4] } else { *remaining_budget = 0; } return SCHEDULER_CBS_OK; a000dab0: e3a00000 mov r0, #0 } a000dab4: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000db7c <_Scheduler_CBS_Initialize>: int _Scheduler_CBS_Initialize(void) { a000db7c: e92d4010 push {r4, lr} unsigned int i; _Scheduler_CBS_Server_list = (Scheduler_CBS_Server **) _Workspace_Allocate( a000db80: e59f4050 ldr r4, [pc, #80] ; a000dbd8 <_Scheduler_CBS_Initialize+0x5c> a000db84: e5940000 ldr r0, [r4] a000db88: e1a00100 lsl r0, r0, #2 a000db8c: eb000633 bl a000f460 <_Workspace_Allocate> a000db90: e59f3044 ldr r3, [pc, #68] ; a000dbdc <_Scheduler_CBS_Initialize+0x60> _Scheduler_CBS_Maximum_servers * sizeof(Scheduler_CBS_Server*) ); if ( !_Scheduler_CBS_Server_list ) a000db94: e3500000 cmp r0, #0 return SCHEDULER_CBS_ERROR_NO_MEMORY; for (i = 0; i<_Scheduler_CBS_Maximum_servers; i++) { a000db98: 15941000 ldrne r1, [r4] } int _Scheduler_CBS_Initialize(void) { unsigned int i; _Scheduler_CBS_Server_list = (Scheduler_CBS_Server **) _Workspace_Allocate( a000db9c: e5830000 str r0, [r3] a000dba0: e1a00003 mov r0, r3 _Scheduler_CBS_Maximum_servers * sizeof(Scheduler_CBS_Server*) ); if ( !_Scheduler_CBS_Server_list ) return SCHEDULER_CBS_ERROR_NO_MEMORY; for (i = 0; i<_Scheduler_CBS_Maximum_servers; i++) { a000dba4: 13a03000 movne r3, #0 a000dba8: 11a02003 movne r2, r3 int _Scheduler_CBS_Initialize(void) { unsigned int i; _Scheduler_CBS_Server_list = (Scheduler_CBS_Server **) _Workspace_Allocate( _Scheduler_CBS_Maximum_servers * sizeof(Scheduler_CBS_Server*) ); if ( !_Scheduler_CBS_Server_list ) a000dbac: 1a000003 bne a000dbc0 <_Scheduler_CBS_Initialize+0x44> a000dbb0: ea000006 b a000dbd0 <_Scheduler_CBS_Initialize+0x54> <== NOT EXECUTED return SCHEDULER_CBS_ERROR_NO_MEMORY; for (i = 0; i<_Scheduler_CBS_Maximum_servers; i++) { _Scheduler_CBS_Server_list[i] = NULL; a000dbb4: e590c000 ldr ip, [r0] a000dbb8: e78c2103 str r2, [ip, r3, lsl #2] unsigned int i; _Scheduler_CBS_Server_list = (Scheduler_CBS_Server **) _Workspace_Allocate( _Scheduler_CBS_Maximum_servers * sizeof(Scheduler_CBS_Server*) ); if ( !_Scheduler_CBS_Server_list ) return SCHEDULER_CBS_ERROR_NO_MEMORY; for (i = 0; i<_Scheduler_CBS_Maximum_servers; i++) { a000dbbc: e2833001 add r3, r3, #1 a000dbc0: e1530001 cmp r3, r1 a000dbc4: 1afffffa bne a000dbb4 <_Scheduler_CBS_Initialize+0x38> _Scheduler_CBS_Server_list[i] = NULL; } return SCHEDULER_CBS_OK; a000dbc8: e3a00000 mov r0, #0 a000dbcc: e8bd8010 pop {r4, pc} { unsigned int i; _Scheduler_CBS_Server_list = (Scheduler_CBS_Server **) _Workspace_Allocate( _Scheduler_CBS_Maximum_servers * sizeof(Scheduler_CBS_Server*) ); if ( !_Scheduler_CBS_Server_list ) return SCHEDULER_CBS_ERROR_NO_MEMORY; a000dbd0: e3e00010 mvn r0, #16 <== NOT EXECUTED for (i = 0; i<_Scheduler_CBS_Maximum_servers; i++) { _Scheduler_CBS_Server_list[i] = NULL; } return SCHEDULER_CBS_OK; } a000dbd4: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000c6e0 <_Scheduler_CBS_Release_job>: { Priority_Control new_priority; Scheduler_CBS_Per_thread *sched_info = (Scheduler_CBS_Per_thread *) the_thread->scheduler_info; Scheduler_CBS_Server *serv_info = (Scheduler_CBS_Server *) sched_info->cbs_server; a000c6e0: e5903088 ldr r3, [r0, #136] ; 0x88 <== NOT EXECUTED if (deadline) { a000c6e4: e3510000 cmp r1, #0 <== NOT EXECUTED ) { Priority_Control new_priority; Scheduler_CBS_Per_thread *sched_info = (Scheduler_CBS_Per_thread *) the_thread->scheduler_info; Scheduler_CBS_Server *serv_info = a000c6e8: e5933018 ldr r3, [r3, #24] <== NOT EXECUTED (Scheduler_CBS_Server *) sched_info->cbs_server; if (deadline) { a000c6ec: 0a00000a beq a000c71c <_Scheduler_CBS_Release_job+0x3c> <== NOT EXECUTED a000c6f0: e59f2044 ldr r2, [pc, #68] ; a000c73c <_Scheduler_CBS_Release_job+0x5c><== NOT EXECUTED /* Initializing or shifting deadline. */ if (serv_info) a000c6f4: e3530000 cmp r3, #0 <== NOT EXECUTED new_priority = (_Watchdog_Ticks_since_boot + serv_info->parameters.deadline) & ~SCHEDULER_EDF_PRIO_MSB; else new_priority = (_Watchdog_Ticks_since_boot + deadline) a000c6f8: 05923000 ldreq r3, [r2] <== NOT EXECUTED a000c6fc: 00811003 addeq r1, r1, r3 <== NOT EXECUTED a000c700: 03c11102 biceq r1, r1, #-2147483648 ; 0x80000000 <== NOT EXECUTED Scheduler_CBS_Server *serv_info = (Scheduler_CBS_Server *) sched_info->cbs_server; if (deadline) { /* Initializing or shifting deadline. */ if (serv_info) a000c704: 0a000009 beq a000c730 <_Scheduler_CBS_Release_job+0x50> <== NOT EXECUTED new_priority = (_Watchdog_Ticks_since_boot + serv_info->parameters.deadline) a000c708: e5921000 ldr r1, [r2] <== NOT EXECUTED a000c70c: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED a000c710: e0811002 add r1, r1, r2 <== NOT EXECUTED a000c714: e3c11102 bic r1, r1, #-2147483648 ; 0x80000000 <== NOT EXECUTED a000c718: ea000002 b a000c728 <_Scheduler_CBS_Release_job+0x48> <== NOT EXECUTED /* Switch back to background priority. */ new_priority = the_thread->Start.initial_priority; } /* Budget replenishment for the next job. */ if (serv_info) a000c71c: e3530000 cmp r3, #0 <== NOT EXECUTED new_priority = (_Watchdog_Ticks_since_boot + deadline) & ~SCHEDULER_EDF_PRIO_MSB; } else { /* Switch back to background priority. */ new_priority = the_thread->Start.initial_priority; a000c720: e59010ac ldr r1, [r0, #172] ; 0xac <== NOT EXECUTED } /* Budget replenishment for the next job. */ if (serv_info) a000c724: 0a000001 beq a000c730 <_Scheduler_CBS_Release_job+0x50> <== NOT EXECUTED the_thread->cpu_time_budget = serv_info->parameters.budget; a000c728: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED a000c72c: e5803074 str r3, [r0, #116] ; 0x74 <== NOT EXECUTED the_thread->real_priority = new_priority; _Thread_Change_priority(the_thread, new_priority, true); a000c730: e3a02001 mov r2, #1 <== NOT EXECUTED /* Budget replenishment for the next job. */ if (serv_info) the_thread->cpu_time_budget = serv_info->parameters.budget; the_thread->real_priority = new_priority; a000c734: e5801018 str r1, [r0, #24] <== NOT EXECUTED _Thread_Change_priority(the_thread, new_priority, true); a000c738: ea00010f b a000cb7c <_Thread_Change_priority> <== NOT EXECUTED =============================================================================== a000c740 <_Scheduler_CBS_Unblock>: #include void _Scheduler_CBS_Unblock( Thread_Control *the_thread ) { a000c740: e92d4030 push {r4, r5, lr} a000c744: e1a04000 mov r4, r0 Scheduler_CBS_Per_thread *sched_info; Scheduler_CBS_Server *serv_info; Priority_Control new_priority; _Scheduler_EDF_Enqueue(the_thread); a000c748: eb00003f bl a000c84c <_Scheduler_EDF_Enqueue> /* TODO: flash critical section? */ sched_info = (Scheduler_CBS_Per_thread *) the_thread->scheduler_info; serv_info = (Scheduler_CBS_Server *) sched_info->cbs_server; a000c74c: e5943088 ldr r3, [r4, #136] ; 0x88 a000c750: e5933018 ldr r3, [r3, #24] * Late unblock rule for deadline-driven tasks. The remaining time to * deadline must be sufficient to serve the remaining computation time * without increased utilization of this task. It might cause a deadline * miss of another task. */ if (serv_info) { a000c754: e3530000 cmp r3, #0 a000c758: 0a000013 beq a000c7ac <_Scheduler_CBS_Unblock+0x6c> time_t deadline = serv_info->parameters.deadline; time_t budget = serv_info->parameters.budget; time_t deadline_left = the_thread->cpu_time_budget; time_t budget_left = the_thread->real_priority - a000c75c: e59f1098 ldr r1, [pc, #152] ; a000c7fc <_Scheduler_CBS_Unblock+0xbc><== NOT EXECUTED a000c760: e5942018 ldr r2, [r4, #24] <== NOT EXECUTED _Watchdog_Ticks_since_boot; if ( deadline*budget_left > budget*deadline_left ) { a000c764: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED */ if (serv_info) { time_t deadline = serv_info->parameters.deadline; time_t budget = serv_info->parameters.budget; time_t deadline_left = the_thread->cpu_time_budget; time_t budget_left = the_thread->real_priority - a000c768: e5911000 ldr r1, [r1] <== NOT EXECUTED _Watchdog_Ticks_since_boot; if ( deadline*budget_left > budget*deadline_left ) { a000c76c: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED */ if (serv_info) { time_t deadline = serv_info->parameters.deadline; time_t budget = serv_info->parameters.budget; time_t deadline_left = the_thread->cpu_time_budget; time_t budget_left = the_thread->real_priority - a000c770: e0611002 rsb r1, r1, r2 <== NOT EXECUTED _Watchdog_Ticks_since_boot; if ( deadline*budget_left > budget*deadline_left ) { a000c774: e0010190 mul r1, r0, r1 <== NOT EXECUTED a000c778: e5940074 ldr r0, [r4, #116] ; 0x74 <== NOT EXECUTED a000c77c: e0030390 mul r3, r0, r3 <== NOT EXECUTED a000c780: e1510003 cmp r1, r3 <== NOT EXECUTED a000c784: da000008 ble a000c7ac <_Scheduler_CBS_Unblock+0x6c> <== NOT EXECUTED /* Put late unblocked task to background until the end of period. */ new_priority = the_thread->Start.initial_priority; a000c788: e59410ac ldr r1, [r4, #172] ; 0xac <== NOT EXECUTED if ( the_thread->real_priority != new_priority ) the_thread->real_priority = new_priority; if ( the_thread->current_priority != new_priority ) a000c78c: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED _Watchdog_Ticks_since_boot; if ( deadline*budget_left > budget*deadline_left ) { /* Put late unblocked task to background until the end of period. */ new_priority = the_thread->Start.initial_priority; if ( the_thread->real_priority != new_priority ) a000c790: e1520001 cmp r2, r1 <== NOT EXECUTED the_thread->real_priority = new_priority; a000c794: 15841018 strne r1, [r4, #24] <== NOT EXECUTED if ( the_thread->current_priority != new_priority ) a000c798: e1530001 cmp r3, r1 <== NOT EXECUTED a000c79c: 0a000002 beq a000c7ac <_Scheduler_CBS_Unblock+0x6c> <== NOT EXECUTED _Thread_Change_priority(the_thread, new_priority, true); a000c7a0: e1a00004 mov r0, r4 <== NOT EXECUTED a000c7a4: e3a02001 mov r2, #1 <== NOT EXECUTED a000c7a8: eb0000f3 bl a000cb7c <_Thread_Change_priority> <== NOT EXECUTED * a context switch. * Pseudo-ISR case: * Even if the thread isn't preemptible, if the new heir is * a pseudo-ISR system task, we need to do a context switch. */ if ( _Scheduler_Is_priority_higher_than( the_thread->current_priority, a000c7ac: e59f504c ldr r5, [pc, #76] ; a000c800 <_Scheduler_CBS_Unblock+0xc0> a000c7b0: e59f304c ldr r3, [pc, #76] ; a000c804 <_Scheduler_CBS_Unblock+0xc4> a000c7b4: e5940014 ldr r0, [r4, #20] a000c7b8: e595200c ldr r2, [r5, #12] a000c7bc: e5933030 ldr r3, [r3, #48] ; 0x30 a000c7c0: e5921014 ldr r1, [r2, #20] a000c7c4: e12fff33 blx r3 a000c7c8: e3500000 cmp r0, #0 a000c7cc: da000009 ble a000c7f8 <_Scheduler_CBS_Unblock+0xb8> _Thread_Heir->current_priority)) { _Thread_Heir = the_thread; if ( _Thread_Executing->is_preemptible || a000c7d0: e5953008 ldr r3, [r5, #8] * Even if the thread isn't preemptible, if the new heir is * a pseudo-ISR system task, we need to do a context switch. */ if ( _Scheduler_Is_priority_higher_than( the_thread->current_priority, _Thread_Heir->current_priority)) { _Thread_Heir = the_thread; a000c7d4: e585400c str r4, [r5, #12] if ( _Thread_Executing->is_preemptible || a000c7d8: e5d33070 ldrb r3, [r3, #112] ; 0x70 a000c7dc: e3530000 cmp r3, #0 a000c7e0: 1a000002 bne a000c7f0 <_Scheduler_CBS_Unblock+0xb0> a000c7e4: e5943014 ldr r3, [r4, #20] a000c7e8: e3530000 cmp r3, #0 a000c7ec: 1a000001 bne a000c7f8 <_Scheduler_CBS_Unblock+0xb8> the_thread->current_priority == 0 ) _Thread_Dispatch_necessary = true; a000c7f0: e3a03001 mov r3, #1 a000c7f4: e5c53004 strb r3, [r5, #4] a000c7f8: e8bd8030 pop {r4, r5, pc} =============================================================================== a000c848 <_Scheduler_EDF_Enqueue_first>: void _Scheduler_EDF_Enqueue_first( Thread_Control *the_thread ) { _Scheduler_EDF_Enqueue(the_thread); a000c848: eaffffff b a000c84c <_Scheduler_EDF_Enqueue> <== NOT EXECUTED =============================================================================== a000c7fc <_Scheduler_EDF_Release_job>: uint32_t deadline ) { Priority_Control new_priority; if (deadline) { a000c7fc: e3510000 cmp r1, #0 <== NOT EXECUTED /* Initializing or shifting deadline. */ new_priority = (_Watchdog_Ticks_since_boot + deadline) a000c800: 159f3018 ldrne r3, [pc, #24] ; a000c820 <_Scheduler_EDF_Release_job+0x24><== NOT EXECUTED & ~SCHEDULER_EDF_PRIO_MSB; } else { /* Switch back to background priority. */ new_priority = the_thread->Start.initial_priority; a000c804: 059010ac ldreq r1, [r0, #172] ; 0xac <== NOT EXECUTED } the_thread->real_priority = new_priority; _Thread_Change_priority(the_thread, new_priority, true); a000c808: e3a02001 mov r2, #1 <== NOT EXECUTED { Priority_Control new_priority; if (deadline) { /* Initializing or shifting deadline. */ new_priority = (_Watchdog_Ticks_since_boot + deadline) a000c80c: 15933000 ldrne r3, [r3] <== NOT EXECUTED a000c810: 10811003 addne r1, r1, r3 <== NOT EXECUTED a000c814: 13c11102 bicne r1, r1, #-2147483648 ; 0x80000000 <== NOT EXECUTED else { /* Switch back to background priority. */ new_priority = the_thread->Start.initial_priority; } the_thread->real_priority = new_priority; a000c818: e5801018 str r1, [r0, #24] <== NOT EXECUTED _Thread_Change_priority(the_thread, new_priority, true); a000c81c: ea0000ac b a000cad4 <_Thread_Change_priority> <== NOT EXECUTED =============================================================================== a000c0e8 <_Scheduler_priority_Tick>: void _Scheduler_priority_Tick( void ) { Thread_Control *executing; executing = _Thread_Executing; a000c0e8: e59f3090 ldr r3, [pc, #144] ; a000c180 <_Scheduler_priority_Tick+0x98> #include #include void _Scheduler_priority_Tick( void ) { a000c0ec: e92d4010 push {r4, lr} Thread_Control *executing; executing = _Thread_Executing; a000c0f0: e5934008 ldr r4, [r3, #8] /* * If the thread is not preemptible or is not ready, then * just return. */ if ( !executing->is_preemptible ) a000c0f4: e5d43070 ldrb r3, [r4, #112] ; 0x70 a000c0f8: e3530000 cmp r3, #0 a000c0fc: 0a00001e beq a000c17c <_Scheduler_priority_Tick+0x94> return; if ( !_States_Is_ready( executing->current_state ) ) a000c100: e5943010 ldr r3, [r4, #16] a000c104: e3530000 cmp r3, #0 a000c108: 1a00001b bne a000c17c <_Scheduler_priority_Tick+0x94> /* * The cpu budget algorithm determines what happens next. */ switch ( executing->budget_algorithm ) { a000c10c: e5943078 ldr r3, [r4, #120] ; 0x78 a000c110: e3530001 cmp r3, #1 a000c114: 3a000018 bcc a000c17c <_Scheduler_priority_Tick+0x94> a000c118: e3530002 cmp r3, #2 <== NOT EXECUTED a000c11c: 9a000002 bls a000c12c <_Scheduler_priority_Tick+0x44> <== NOT EXECUTED a000c120: e3530003 cmp r3, #3 <== NOT EXECUTED a000c124: 1a000014 bne a000c17c <_Scheduler_priority_Tick+0x94> <== NOT EXECUTED a000c128: ea00000b b a000c15c <_Scheduler_priority_Tick+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 ) { a000c12c: e5943074 ldr r3, [r4, #116] ; 0x74 <== NOT EXECUTED a000c130: e2433001 sub r3, r3, #1 <== NOT EXECUTED a000c134: e3530000 cmp r3, #0 <== NOT EXECUTED a000c138: e5843074 str r3, [r4, #116] ; 0x74 <== NOT EXECUTED a000c13c: ca00000e bgt a000c17c <_Scheduler_priority_Tick+0x94> <== NOT EXECUTED * always operates on the scheduler that 'owns' the currently executing * thread. */ RTEMS_INLINE_ROUTINE void _Scheduler_Yield( void ) { _Scheduler.Operations.yield(); a000c140: e59f303c ldr r3, [pc, #60] ; a000c184 <_Scheduler_priority_Tick+0x9c><== NOT EXECUTED a000c144: e593300c ldr r3, [r3, #12] <== NOT EXECUTED a000c148: 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; a000c14c: e59f3034 ldr r3, [pc, #52] ; a000c188 <_Scheduler_priority_Tick+0xa0><== NOT EXECUTED a000c150: e5933000 ldr r3, [r3] <== NOT EXECUTED a000c154: e5843074 str r3, [r4, #116] ; 0x74 <== NOT EXECUTED a000c158: 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 ) a000c15c: e5943074 ldr r3, [r4, #116] ; 0x74 <== NOT EXECUTED a000c160: e2433001 sub r3, r3, #1 <== NOT EXECUTED a000c164: e3530000 cmp r3, #0 <== NOT EXECUTED a000c168: e5843074 str r3, [r4, #116] ; 0x74 <== NOT EXECUTED a000c16c: 1a000002 bne a000c17c <_Scheduler_priority_Tick+0x94> <== NOT EXECUTED (*executing->budget_callout)( executing ); a000c170: e594307c ldr r3, [r4, #124] ; 0x7c <== NOT EXECUTED a000c174: e1a00004 mov r0, r4 <== NOT EXECUTED a000c178: e12fff33 blx r3 <== NOT EXECUTED a000c17c: e8bd8010 pop {r4, pc} =============================================================================== a000c7a4 <_Scheduler_simple_Ready_queue_enqueue_first>: { Chain_Control *ready; Chain_Node *the_node; Thread_Control *current; ready = (Chain_Control *)_Scheduler.information; a000c7a4: e59f3038 ldr r3, [pc, #56] ; a000c7e4 <_Scheduler_simple_Ready_queue_enqueue_first+0x40> */ for ( the_node = _Chain_First(ready) ; ; the_node = the_node->next ) { current = (Thread_Control *) the_node; /* break when AT HEAD OF (or PAST) our priority */ if ( the_thread->current_priority <= current->current_priority ) { a000c7a8: e5902014 ldr r2, [r0, #20] */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000c7ac: e5933000 ldr r3, [r3] a000c7b0: e5933000 ldr r3, [r3] a000c7b4: e5931014 ldr r1, [r3, #20] a000c7b8: e1520001 cmp r2, r1 a000c7bc: 8a000006 bhi a000c7dc <_Scheduler_simple_Ready_queue_enqueue_first+0x38> current = (Thread_Control *)current->Object.Node.previous; a000c7c0: e5933004 ldr r3, [r3, #4] ) { Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; a000c7c4: e5932000 ldr r2, [r3] Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; a000c7c8: e5803004 str r3, [r0, #4] before_node = after_node->next; after_node->next = the_node; a000c7cc: e5830000 str r0, [r3] the_node->next = before_node; before_node->previous = the_node; a000c7d0: e5820004 str r0, [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; a000c7d4: e5802000 str r2, [r0] } } /* enqueue */ _Chain_Insert_unprotected( (Chain_Node *)current, &the_thread->Object.Node ); } a000c7d8: e12fff1e bx lr * Do NOT need to check for end of chain because there is always * at least one task on the ready chain -- the IDLE task. It can * never block, should never attempt to obtain a semaphore or mutex, * and thus will always be there. */ for ( the_node = _Chain_First(ready) ; ; the_node = the_node->next ) { a000c7dc: e5933000 ldr r3, [r3] <== NOT EXECUTED /* break when AT HEAD OF (or PAST) our priority */ if ( the_thread->current_priority <= current->current_priority ) { current = (Thread_Control *)current->Object.Node.previous; break; } } a000c7e0: eafffff3 b a000c7b4 <_Scheduler_simple_Ready_queue_enqueue_first+0x10><== NOT EXECUTED =============================================================================== a00272a4 <_TOD_Get_uptime_as_timespec>: #include void _TOD_Get_uptime_as_timespec( struct timespec *uptime ) { a00272a4: e92d40d3 push {r0, r1, r4, r6, r7, lr} <== NOT EXECUTED a00272a8: e1a04000 mov r4, r0 <== NOT EXECUTED a00272ac: e59f103c ldr r1, [pc, #60] ; a00272f0 <_TOD_Get_uptime_as_timespec+0x4c><== NOT EXECUTED a00272b0: e1a0000d mov r0, sp <== NOT EXECUTED a00272b4: ebff914b bl a000b7e8 <_TOD_Get_with_nanoseconds> <== NOT EXECUTED Timestamp_Control uptime_ts; /* assume time checked for NULL by caller */ _TOD_Get_uptime( &uptime_ts ); _Timestamp_To_timespec( &uptime_ts, uptime ); a00272b8: e89d00c0 ldm sp, {r6, r7} <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00272bc: e59f2030 ldr r2, [pc, #48] ; a00272f4 <_TOD_Get_uptime_as_timespec+0x50><== NOT EXECUTED a00272c0: e3a03000 mov r3, #0 <== NOT EXECUTED a00272c4: e1a00006 mov r0, r6 <== NOT EXECUTED a00272c8: e1a01007 mov r1, r7 <== NOT EXECUTED a00272cc: eb00a263 bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00272d0: e1a01007 mov r1, r7 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00272d4: e5840000 str r0, [r4] <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00272d8: e59f2014 ldr r2, [pc, #20] ; a00272f4 <_TOD_Get_uptime_as_timespec+0x50><== NOT EXECUTED a00272dc: e1a00006 mov r0, r6 <== NOT EXECUTED a00272e0: e3a03000 mov r3, #0 <== NOT EXECUTED a00272e4: eb00a398 bl a005014c <__moddi3> <== NOT EXECUTED a00272e8: e5840004 str r0, [r4, #4] <== NOT EXECUTED } a00272ec: e8bd80dc pop {r2, r3, r4, r6, r7, pc} <== NOT EXECUTED =============================================================================== a000b000 <_TOD_Tickle_ticks>: void _TOD_Tickle_ticks( void ) { Timestamp_Control tick; uint32_t nanoseconds_per_tick; nanoseconds_per_tick = rtems_configuration_get_nanoseconds_per_tick(); a000b000: e59f3078 ldr r3, [pc, #120] ; a000b080 <_TOD_Tickle_ticks+0x80> #include #include #include void _TOD_Tickle_ticks( void ) { a000b004: e92d4030 push {r4, r5, lr} Timestamp_Control tick; uint32_t nanoseconds_per_tick; nanoseconds_per_tick = rtems_configuration_get_nanoseconds_per_tick(); a000b008: e5932010 ldr r2, [r3, #16] /* Convert the tick quantum to a timestamp */ _Timestamp_Set( &tick, 0, nanoseconds_per_tick ); /* Update the counter of ticks since boot */ _Watchdog_Ticks_since_boot += 1; a000b00c: e59f3070 ldr r3, [pc, #112] ; a000b084 <_TOD_Tickle_ticks+0x84> uint32_t nanoseconds_per_tick; nanoseconds_per_tick = rtems_configuration_get_nanoseconds_per_tick(); /* Convert the tick quantum to a timestamp */ _Timestamp_Set( &tick, 0, nanoseconds_per_tick ); a000b010: e3a01000 mov r1, #0 /* Update the counter of ticks since boot */ _Watchdog_Ticks_since_boot += 1; a000b014: e593c000 ldr ip, [r3] a000b018: e28cc001 add ip, ip, #1 a000b01c: e583c000 str ip, [r3] static inline void _Timestamp64_implementation_Add_to( Timestamp64_Control *_time, const Timestamp64_Control *_add ) { *_time += *_add; a000b020: e59f3060 ldr r3, [pc, #96] ; a000b088 <_TOD_Tickle_ticks+0x88> a000b024: e2835008 add r5, r3, #8 a000b028: e8950030 ldm r5, {r4, r5} a000b02c: e0944002 adds r4, r4, r2 a000b030: e0a55001 adc r5, r5, r1 a000b034: e5834008 str r4, [r3, #8] a000b038: e583500c str r5, [r3, #12] a000b03c: e8930030 ldm r3, {r4, r5} a000b040: e0944002 adds r4, r4, r2 a000b044: e0a55001 adc r5, r5, r1 /* we do not care how much the uptime changed */ /* Update the current TOD */ _Timestamp_Add_to( &_TOD.now, &tick ); _TOD.seconds_trigger += nanoseconds_per_tick; a000b048: e5931010 ldr r1, [r3, #16] a000b04c: e8830030 stm r3, {r4, r5} a000b050: e0821001 add r1, r2, r1 if ( _TOD.seconds_trigger >= 1000000000UL ) { a000b054: e59f2030 ldr r2, [pc, #48] ; a000b08c <_TOD_Tickle_ticks+0x8c> /* we do not care how much the uptime changed */ /* Update the current TOD */ _Timestamp_Add_to( &_TOD.now, &tick ); _TOD.seconds_trigger += nanoseconds_per_tick; a000b058: e5831010 str r1, [r3, #16] if ( _TOD.seconds_trigger >= 1000000000UL ) { a000b05c: e1510002 cmp r1, r2 a000b060: 9a000005 bls a000b07c <_TOD_Tickle_ticks+0x7c> _TOD.seconds_trigger -= 1000000000UL; a000b064: e59f2024 ldr r2, [pc, #36] ; a000b090 <_TOD_Tickle_ticks+0x90><== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void _Watchdog_Tickle_seconds( void ) { _Watchdog_Tickle( &_Watchdog_Seconds_chain ); a000b068: e59f0024 ldr r0, [pc, #36] ; a000b094 <_TOD_Tickle_ticks+0x94><== NOT EXECUTED a000b06c: e0812002 add r2, r1, r2 <== NOT EXECUTED a000b070: e5832010 str r2, [r3, #16] <== NOT EXECUTED _Watchdog_Tickle_seconds(); } } a000b074: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED a000b078: ea00093c b a000d570 <_Watchdog_Tickle> <== NOT EXECUTED a000b07c: e8bd8030 pop {r4, r5, pc} =============================================================================== a000acbc <_TOD_Validate>: }; bool _TOD_Validate( const rtems_time_of_day *the_tod ) { a000acbc: 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) || a000acc0: e2504000 subs r4, r0, #0 a000acc4: 0a000023 beq a000ad58 <_TOD_Validate+0x9c> ) { uint32_t days_in_month; uint32_t ticks_per_second; ticks_per_second = TOD_MICROSECONDS_PER_SECOND / a000acc8: e59f30a8 ldr r3, [pc, #168] ; a000ad78 <_TOD_Validate+0xbc> a000accc: e59f00a8 ldr r0, [pc, #168] ; a000ad7c <_TOD_Validate+0xc0> a000acd0: e593100c ldr r1, [r3, #12] a000acd4: eb0046aa bl a001c784 <__aeabi_uidiv> rtems_configuration_get_microseconds_per_tick(); if ((!the_tod) || a000acd8: e5943018 ldr r3, [r4, #24] a000acdc: e1530000 cmp r3, r0 a000ace0: 2a000020 bcs a000ad68 <_TOD_Validate+0xac> (the_tod->ticks >= ticks_per_second) || a000ace4: e5943014 ldr r3, [r4, #20] a000ace8: e353003b cmp r3, #59 ; 0x3b a000acec: 8a00001d bhi a000ad68 <_TOD_Validate+0xac> (the_tod->second >= TOD_SECONDS_PER_MINUTE) || a000acf0: e5943010 ldr r3, [r4, #16] a000acf4: e353003b cmp r3, #59 ; 0x3b a000acf8: 8a00001a bhi a000ad68 <_TOD_Validate+0xac> (the_tod->minute >= TOD_MINUTES_PER_HOUR) || a000acfc: e594300c ldr r3, [r4, #12] a000ad00: e3530017 cmp r3, #23 a000ad04: 8a000017 bhi a000ad68 <_TOD_Validate+0xac> (the_tod->hour >= TOD_HOURS_PER_DAY) || (the_tod->month == 0) || a000ad08: 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) || a000ad0c: e3530000 cmp r3, #0 a000ad10: 0a000012 beq a000ad60 <_TOD_Validate+0xa4> (the_tod->month == 0) || a000ad14: e353000c cmp r3, #12 a000ad18: 8a000012 bhi a000ad68 <_TOD_Validate+0xac> (the_tod->month > TOD_MONTHS_PER_YEAR) || (the_tod->year < TOD_BASE_YEAR) || a000ad1c: 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) || a000ad20: e59f1058 ldr r1, [pc, #88] ; a000ad80 <_TOD_Validate+0xc4> a000ad24: e1520001 cmp r2, r1 a000ad28: 9a000010 bls a000ad70 <_TOD_Validate+0xb4> (the_tod->year < TOD_BASE_YEAR) || (the_tod->day == 0) ) a000ad2c: 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) || a000ad30: e3500000 cmp r0, #0 a000ad34: 0a00000e beq a000ad74 <_TOD_Validate+0xb8> (the_tod->day == 0) ) return false; if ( (the_tod->year % 4) == 0 ) a000ad38: e3120003 tst r2, #3 a000ad3c: e59f2040 ldr r2, [pc, #64] ; a000ad84 <_TOD_Validate+0xc8> days_in_month = _TOD_Days_per_month[ 1 ][ the_tod->month ]; a000ad40: 0283300d addeq r3, r3, #13 else days_in_month = _TOD_Days_per_month[ 0 ][ the_tod->month ]; a000ad44: e7924103 ldr r4, [r2, r3, lsl #2] const uint32_t _TOD_Days_per_month[ 2 ][ 13 ] = { { 0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }, { 0, 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 } }; bool _TOD_Validate( a000ad48: e1500004 cmp r0, r4 a000ad4c: 83a00000 movhi r0, #0 a000ad50: 93a00001 movls r0, #1 a000ad54: 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; a000ad58: e1a00004 mov r0, r4 <== NOT EXECUTED a000ad5c: e8bd8010 pop {r4, pc} <== NOT EXECUTED a000ad60: e1a00003 mov r0, r3 <== NOT EXECUTED a000ad64: e8bd8010 pop {r4, pc} <== NOT EXECUTED a000ad68: e3a00000 mov r0, #0 <== NOT EXECUTED a000ad6c: e8bd8010 pop {r4, pc} <== NOT EXECUTED a000ad70: e3a00000 mov r0, #0 <== NOT EXECUTED if ( the_tod->day > days_in_month ) return false; return true; } a000ad74: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000c4b0 <_Thread_Close>: RTEMS_INLINE_ROUTINE void _Objects_Invalidate_Id( Objects_Information *information, Objects_Control *the_object ) { _Objects_Set_local_object( a000c4b0: e1d120b8 ldrh r2, [r1, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000c4b4: e590301c ldr r3, [r0, #28] void _Thread_Close( Objects_Information *information, Thread_Control *the_thread ) { a000c4b8: e92d4070 push {r4, r5, r6, lr} a000c4bc: e1a04001 mov r4, r1 a000c4c0: e3a01000 mov r1, #0 a000c4c4: e7831102 str r1, [r3, r2, lsl #2] a000c4c8: e1a06000 mov r6, r0 * * This routine decrements the thread dispatch level. */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000c4cc: e59f508c ldr r5, [pc, #140] ; a000c560 <_Thread_Close+0xb0> return ctx.ok; } static inline void _User_extensions_Thread_delete( Thread_Control *deleted ) { _User_extensions_Iterate( a000c4d0: e1a00004 mov r0, r4 a000c4d4: e59f1088 ldr r1, [pc, #136] ; a000c564 <_Thread_Close+0xb4> a000c4d8: e5953000 ldr r3, [r5] --level; a000c4dc: e2433001 sub r3, r3, #1 _Thread_Dispatch_disable_level = level; a000c4e0: e5853000 str r3, [r5] a000c4e4: eb000361 bl a000d270 <_User_extensions_Iterate> * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000c4e8: e5953000 ldr r3, [r5] ++level; a000c4ec: e2833001 add r3, r3, #1 _Thread_Dispatch_disable_level = level; a000c4f0: e5853000 str r3, [r5] /* * 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 ); a000c4f4: e1a00006 mov r0, r6 a000c4f8: e1a01004 mov r1, r4 a000c4fc: ebfffc1f bl a000b580 <_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 ); a000c500: e1a00004 mov r0, r4 a000c504: e3a01001 mov r1, #1 a000c508: eb0002c5 bl a000d024 <_Thread_Set_state> if ( !_Thread_queue_Extract_with_proxy( the_thread ) ) { a000c50c: e1a00004 mov r0, r4 a000c510: eb000269 bl a000cebc <_Thread_queue_Extract_with_proxy> a000c514: e3500000 cmp r0, #0 a000c518: 1a000004 bne a000c530 <_Thread_Close+0x80> if ( _Watchdog_Is_active( &the_thread->Timer ) ) a000c51c: e5943050 ldr r3, [r4, #80] ; 0x50 a000c520: e3530002 cmp r3, #2 a000c524: 1a000001 bne a000c530 <_Thread_Close+0x80> (void) _Watchdog_Remove( &the_thread->Timer ); a000c528: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED a000c52c: eb0003e6 bl a000d4cc <_Watchdog_Remove> <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void _Scheduler_Free( Thread_Control *the_thread ) { return _Scheduler.Operations.free( the_thread ); a000c530: e59f3030 ldr r3, [pc, #48] ; a000c568 <_Thread_Close+0xb8> a000c534: e1a00004 mov r0, r4 /* * 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; a000c538: e3a05000 mov r5, #0 a000c53c: e593301c ldr r3, [r3, #28] a000c540: 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 ); a000c544: e1a00004 mov r0, r4 a000c548: eb0002e5 bl a000d0e4 <_Thread_Stack_Free> the_thread->Start.stack = NULL; a000c54c: e58450bc str r5, [r4, #188] ; 0xbc _Workspace_Free( the_thread->extensions ); a000c550: e59400f8 ldr r0, [r4, #248] ; 0xf8 a000c554: eb00046e bl a000d714 <_Workspace_Free> the_thread->extensions = NULL; a000c558: e58450f8 str r5, [r4, #248] ; 0xf8 } a000c55c: e8bd8070 pop {r4, r5, r6, pc} =============================================================================== a000c800 <_Thread_Get>: Thread_Control *_Thread_Get ( Objects_Id id, Objects_Locations *location ) { a000c800: 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 ) ) { a000c804: e2501000 subs r1, r0, #0 a000c808: 1a000007 bne a000c82c <_Thread_Get+0x2c> * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000c80c: e59f3074 ldr r3, [pc, #116] ; a000c888 <_Thread_Get+0x88> a000c810: e5930000 ldr r0, [r3] ++level; a000c814: e2800001 add r0, r0, #1 _Thread_Dispatch_disable_level = level; a000c818: e5830000 str r0, [r3] _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; a000c81c: e59f3068 ldr r3, [pc, #104] ; a000c88c <_Thread_Get+0x8c> 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; a000c820: e5821000 str r1, [r2] tp = _Thread_Executing; a000c824: e5930008 ldr r0, [r3, #8] goto done; a000c828: 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); a000c82c: e1a00c21 lsr r0, r1, #24 a000c830: 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 ) a000c834: e2403001 sub r3, r0, #1 a000c838: e3530002 cmp r3, #2 a000c83c: 9a00000d bls a000c878 <_Thread_Get+0x78> goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ *location = OBJECTS_ERROR; a000c840: e3a03001 mov r3, #1 a000c844: 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; a000c848: e3a00000 mov r0, #0 } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ *location = OBJECTS_ERROR; goto done; a000c84c: e12fff1e bx lr } api_information = _Objects_Information_table[ the_api ]; a000c850: e59fc038 ldr ip, [pc, #56] ; a000c890 <_Thread_Get+0x90> a000c854: e79c0100 ldr r0, [ip, r0, lsl #2] * There is no way for this to happen if POSIX is enabled. But there * is actually a test case in sp43 for this which trips it whether or * not POSIX is enabled. So in the interest of safety, this is left * on in all configurations. */ if ( !api_information ) { a000c858: e3500000 cmp r0, #0 a000c85c: 0a000002 beq a000c86c <_Thread_Get+0x6c> *location = OBJECTS_ERROR; goto done; } information = api_information[ the_class ]; a000c860: e5900004 ldr r0, [r0, #4] if ( !information ) { a000c864: e3500000 cmp r0, #0 a000c868: 1a000001 bne a000c874 <_Thread_Get+0x74> *location = OBJECTS_ERROR; a000c86c: e5823000 str r3, [r2] <== NOT EXECUTED goto done; a000c870: e12fff1e bx lr <== NOT EXECUTED } tp = (Thread_Control *) _Objects_Get( information, id, location ); a000c874: eafffc46 b a000b994 <_Objects_Get> */ RTEMS_INLINE_ROUTINE uint32_t _Objects_Get_class( Objects_Id id ) { return (uint32_t) a000c878: 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 :) */ a000c87c: e3530001 cmp r3, #1 a000c880: 0afffff2 beq a000c850 <_Thread_Get+0x50> a000c884: eaffffed b a000c840 <_Thread_Get+0x40> <== NOT EXECUTED =============================================================================== a0010900 <_Thread_Reset>: Thread_Control *the_thread, void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { the_thread->resource_count = 0; a0010900: e3a03000 mov r3, #0 void _Thread_Reset( Thread_Control *the_thread, void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { a0010904: e92d4010 push {r4, lr} the_thread->resource_count = 0; a0010908: e580301c str r3, [r0, #28] the_thread->is_preemptible = the_thread->Start.is_preemptible; a001090c: e5d0309c ldrb r3, [r0, #156] ; 0x9c 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; a0010910: e5801094 str r1, [r0, #148] ; 0x94 the_thread->Start.numeric_argument = numeric_argument; a0010914: e5802098 str r2, [r0, #152] ; 0x98 void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { the_thread->resource_count = 0; the_thread->is_preemptible = the_thread->Start.is_preemptible; a0010918: e5c03070 strb r3, [r0, #112] ; 0x70 the_thread->budget_algorithm = the_thread->Start.budget_algorithm; a001091c: e59030a0 ldr r3, [r0, #160] ; 0xa0 void _Thread_Reset( Thread_Control *the_thread, void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { a0010920: 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; a0010924: e5803078 str r3, [r0, #120] ; 0x78 the_thread->budget_callout = the_thread->Start.budget_callout; a0010928: e59030a4 ldr r3, [r0, #164] ; 0xa4 a001092c: e580307c str r3, [r0, #124] ; 0x7c the_thread->Start.pointer_argument = pointer_argument; the_thread->Start.numeric_argument = numeric_argument; if ( !_Thread_queue_Extract_with_proxy( the_thread ) ) { a0010930: ebfff33b bl a000d624 <_Thread_queue_Extract_with_proxy> a0010934: e3500000 cmp r0, #0 a0010938: 1a000004 bne a0010950 <_Thread_Reset+0x50> if ( _Watchdog_Is_active( &the_thread->Timer ) ) a001093c: e5943050 ldr r3, [r4, #80] ; 0x50 a0010940: e3530002 cmp r3, #2 a0010944: 1a000001 bne a0010950 <_Thread_Reset+0x50> (void) _Watchdog_Remove( &the_thread->Timer ); a0010948: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED a001094c: ebfff4d7 bl a000dcb0 <_Watchdog_Remove> <== NOT EXECUTED } if ( the_thread->current_priority != the_thread->Start.initial_priority ) { a0010950: e59410ac ldr r1, [r4, #172] ; 0xac a0010954: e5943014 ldr r3, [r4, #20] a0010958: e1530001 cmp r3, r1 a001095c: 0a000003 beq a0010970 <_Thread_Reset+0x70> the_thread->real_priority = the_thread->Start.initial_priority; _Thread_Set_priority( the_thread, the_thread->Start.initial_priority ); a0010960: 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; a0010964: e5841018 str r1, [r4, #24] _Thread_Set_priority( the_thread, the_thread->Start.initial_priority ); } } a0010968: 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 ); a001096c: eafff39e b a000d7ec <_Thread_Set_priority> a0010970: e8bd8010 pop {r4, pc} =============================================================================== a000d144 <_Thread_Start>: */ RTEMS_INLINE_ROUTINE bool _States_Is_dormant ( States_Control the_states ) { return (the_states & STATES_DORMANT); a000d144: e590c010 ldr ip, [r0, #16] Thread_Start_types the_prototype, void *entry_point, void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { a000d148: e92d4010 push {r4, lr} if ( _States_Is_dormant( the_thread->current_state ) ) { a000d14c: e21cc001 ands ip, ip, #1 Thread_Start_types the_prototype, void *entry_point, void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { a000d150: e1a04000 mov r4, r0 if ( _States_Is_dormant( the_thread->current_state ) ) { a000d154: 0a00000c beq a000d18c <_Thread_Start+0x48> the_thread->Start.entry_point = (Thread_Entry) entry_point; the_thread->Start.prototype = the_prototype; the_thread->Start.pointer_argument = pointer_argument; a000d158: e5803094 str r3, [r0, #148] ; 0x94 the_thread->Start.numeric_argument = numeric_argument; a000d15c: 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; a000d160: e580208c str r2, [r0, #140] ; 0x8c the_thread->Start.prototype = the_prototype; a000d164: e5801090 str r1, [r0, #144] ; 0x90 the_thread->Start.pointer_argument = pointer_argument; the_thread->Start.numeric_argument = numeric_argument; a000d168: e5803098 str r3, [r0, #152] ; 0x98 _Thread_Load_environment( the_thread ); a000d16c: eb000b48 bl a000fe94 <_Thread_Load_environment> _Thread_Ready( the_thread ); a000d170: e1a00004 mov r0, r4 a000d174: eb000bdc bl a00100ec <_Thread_Ready> ); } static inline void _User_extensions_Thread_start( Thread_Control *started ) { _User_extensions_Iterate( a000d178: e1a00004 mov r0, r4 a000d17c: e59f1010 ldr r1, [pc, #16] ; a000d194 <_Thread_Start+0x50> a000d180: eb00003a bl a000d270 <_User_extensions_Iterate> _User_extensions_Thread_start( the_thread ); return true; a000d184: e3a00001 mov r0, #1 a000d188: e8bd8010 pop {r4, pc} } return false; a000d18c: e1a0000c mov r0, ip <== NOT EXECUTED } a000d190: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000c330 <_Thread_blocking_operation_Cancel>: #endif /* * The thread is not waiting on anything after this completes. */ the_thread->Wait.queue = NULL; a000c330: e3a03000 mov r3, #0 <== NOT EXECUTED Thread_blocking_operation_States sync_state __attribute__((unused)), #endif Thread_Control *the_thread, ISR_Level level ) { a000c334: e92d4010 push {r4, lr} <== NOT EXECUTED #endif /* * The thread is not waiting on anything after this completes. */ the_thread->Wait.queue = NULL; a000c338: 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 ) ) { a000c33c: e5913050 ldr r3, [r1, #80] ; 0x50 <== NOT EXECUTED Thread_blocking_operation_States sync_state __attribute__((unused)), #endif Thread_Control *the_thread, ISR_Level level ) { a000c340: 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 ) ) { a000c344: e3530002 cmp r3, #2 <== NOT EXECUTED a000c348: 1a000005 bne a000c364 <_Thread_blocking_operation_Cancel+0x34><== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_REMOVE_IT; a000c34c: e3a03003 mov r3, #3 <== NOT EXECUTED a000c350: e5813050 str r3, [r1, #80] ; 0x50 <== NOT EXECUTED a000c354: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED _Watchdog_Deactivate( &the_thread->Timer ); _ISR_Enable( level ); (void) _Watchdog_Remove( &the_thread->Timer ); a000c358: e2810048 add r0, r1, #72 ; 0x48 <== NOT EXECUTED a000c35c: eb00045a bl a000d4cc <_Watchdog_Remove> <== NOT EXECUTED a000c360: ea000000 b a000c368 <_Thread_blocking_operation_Cancel+0x38><== NOT EXECUTED a000c364: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); a000c368: e59f1008 ldr r1, [pc, #8] ; a000c378 <_Thread_blocking_operation_Cancel+0x48><== NOT EXECUTED a000c36c: 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 } a000c370: e8bd4010 pop {r4, lr} <== NOT EXECUTED a000c374: ea00003c b a000c46c <_Thread_Clear_state> <== NOT EXECUTED =============================================================================== a000fee0 <_Thread_queue_Dequeue_fifo>: #include Thread_Control *_Thread_queue_Dequeue_fifo( Thread_queue_Control *the_thread_queue ) { a000fee0: e92d4010 push {r4, lr} uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000fee4: e10f3000 mrs r3, CPSR a000fee8: e3832080 orr r2, r3, #128 ; 0x80 a000feec: e129f002 msr CPSR_fc, r2 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000fef0: e1a02000 mov r2, r0 a000fef4: e4924004 ldr r4, [r2], #4 ISR_Level level; Thread_Control *the_thread; _ISR_Disable( level ); if ( !_Chain_Is_empty( &the_thread_queue->Queues.Fifo ) ) { a000fef8: e1540002 cmp r4, r2 a000fefc: 0a000012 beq a000ff4c <_Thread_queue_Dequeue_fifo+0x6c> Chain_Control *the_chain ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *old_first = head->next; Chain_Node *new_first = old_first->next; a000ff00: e5942000 ldr r2, [r4] head->next = new_first; a000ff04: e5802000 str r2, [r0] new_first->previous = head; a000ff08: e5820004 str r0, [r2, #4] the_thread = (Thread_Control *) _Chain_Get_first_unprotected( &the_thread_queue->Queues.Fifo ); the_thread->Wait.queue = NULL; a000ff0c: e3a02000 mov r2, #0 a000ff10: e5842044 str r2, [r4, #68] ; 0x44 if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { a000ff14: e5942050 ldr r2, [r4, #80] ; 0x50 a000ff18: e3520002 cmp r2, #2 a000ff1c: 0a000001 beq a000ff28 <_Thread_queue_Dequeue_fifo+0x48> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000ff20: e129f003 msr CPSR_fc, r3 a000ff24: ea000004 b a000ff3c <_Thread_queue_Dequeue_fifo+0x5c> RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_REMOVE_IT; a000ff28: e3a02003 mov r2, #3 <== NOT EXECUTED a000ff2c: e5842050 str r2, [r4, #80] ; 0x50 <== NOT EXECUTED a000ff30: 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 ); a000ff34: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED a000ff38: ebfff563 bl a000d4cc <_Watchdog_Remove> <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); a000ff3c: e1a00004 mov r0, r4 a000ff40: e59f1014 ldr r1, [pc, #20] ; a000ff5c <_Thread_queue_Dequeue_fifo+0x7c> a000ff44: ebfff148 bl a000c46c <_Thread_Clear_state> a000ff48: ea000001 b a000ff54 <_Thread_queue_Dequeue_fifo+0x74> a000ff4c: e129f003 msr CPSR_fc, r3 return the_thread; } _ISR_Enable( level ); return NULL; a000ff50: e3a04000 mov r4, #0 } a000ff54: e1a00004 mov r0, r4 a000ff58: e8bd8010 pop {r4, pc} =============================================================================== a000cb94 <_Thread_queue_Dequeue_priority>: #include Thread_Control *_Thread_queue_Dequeue_priority( Thread_queue_Control *the_thread_queue ) { a000cb94: e92d4030 push {r4, r5, lr} uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000cb98: e10f2000 mrs r2, CPSR a000cb9c: e3823080 orr r3, r2, #128 ; 0x80 a000cba0: e129f003 msr CPSR_fc, r3 Chain_Node *last_node; Chain_Node *next_node; Chain_Node *previous_node; _ISR_Disable( level ); for( index=0 ; a000cba4: e3a03000 mov r3, #0 index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ; index++ ) { if ( !_Chain_Is_empty( &the_thread_queue->Queues.Priority[ index ] ) ) { a000cba8: e3a0c00c mov ip, #12 a000cbac: e001039c mul r1, ip, r3 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000cbb0: e7904001 ldr r4, [r0, r1] a000cbb4: e0805001 add r5, r0, r1 RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); a000cbb8: e2851004 add r1, r5, #4 a000cbbc: e1540001 cmp r4, r1 a000cbc0: 0a000008 beq a000cbe8 <_Thread_queue_Dequeue_priority+0x54> */ _ISR_Enable( level ); return NULL; dequeue: the_thread->Wait.queue = NULL; a000cbc4: e3a03000 mov r3, #0 a000cbc8: e5843044 str r3, [r4, #68] ; 0x44 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000cbcc: e5943038 ldr r3, [r4, #56] ; 0x38 RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); a000cbd0: e284c03c add ip, r4, #60 ; 0x3c new_first_node = _Chain_First( &the_thread->Wait.Block2n ); new_first_thread = (Thread_Control *) new_first_node; next_node = the_thread->Object.Node.next; a000cbd4: e5941000 ldr r1, [r4] previous_node = the_thread->Object.Node.previous; if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { a000cbd8: 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; previous_node = the_thread->Object.Node.previous; a000cbdc: e5940004 ldr r0, [r4, #4] if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { a000cbe0: 1a000006 bne a000cc00 <_Thread_queue_Dequeue_priority+0x6c> a000cbe4: ea000016 b a000cc44 <_Thread_queue_Dequeue_priority+0xb0> Chain_Node *previous_node; _ISR_Disable( level ); for( index=0 ; index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ; index++ ) { a000cbe8: e2833001 add r3, r3, #1 Chain_Node *last_node; Chain_Node *next_node; Chain_Node *previous_node; _ISR_Disable( level ); for( index=0 ; a000cbec: e3530004 cmp r3, #4 a000cbf0: 1affffed bne a000cbac <_Thread_queue_Dequeue_priority+0x18> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000cbf4: e129f002 msr CPSR_fc, r2 /* * We did not find a thread to unblock. */ _ISR_Enable( level ); return NULL; a000cbf8: e3a04000 mov r4, #0 a000cbfc: ea00001f b a000cc80 <_Thread_queue_Dequeue_priority+0xec> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Last( Chain_Control *the_chain ) { return _Chain_Tail( the_chain )->previous; a000cc00: e594c040 ldr ip, [r4, #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; a000cc04: e593e000 ldr lr, [r3] <== NOT EXECUTED previous_node->next = new_first_node; next_node->previous = new_first_node; a000cc08: e5813004 str r3, [r1, #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; a000cc0c: e5803000 str r3, [r0] <== NOT EXECUTED next_node->previous = new_first_node; new_first_node->next = next_node; new_first_node->previous = previous_node; a000cc10: 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; a000cc14: e5831000 str r1, [r3] <== NOT EXECUTED new_first_node->previous = previous_node; if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) { a000cc18: e5940038 ldr r0, [r4, #56] ; 0x38 <== NOT EXECUTED a000cc1c: e5941040 ldr r1, [r4, #64] ; 0x40 <== NOT EXECUTED a000cc20: e1500001 cmp r0, r1 <== NOT EXECUTED a000cc24: 0a000008 beq a000cc4c <_Thread_queue_Dequeue_priority+0xb8><== NOT EXECUTED /* > two threads on 2-n */ head = _Chain_Head( &new_first_thread->Wait.Block2n ); a000cc28: e2831038 add r1, r3, #56 ; 0x38 <== NOT EXECUTED tail = _Chain_Tail( &new_first_thread->Wait.Block2n ); new_second_node->previous = head; head->next = new_second_node; a000cc2c: 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; a000cc30: e58e1004 str r1, [lr, #4] <== NOT EXECUTED head->next = new_second_node; tail->previous = last_node; a000cc34: 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 ); a000cc38: 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; a000cc3c: e58c3000 str r3, [ip] <== NOT EXECUTED a000cc40: ea000001 b a000cc4c <_Thread_queue_Dequeue_priority+0xb8> <== NOT EXECUTED } } else { previous_node->next = next_node; a000cc44: e5801000 str r1, [r0] next_node->previous = previous_node; a000cc48: e5810004 str r0, [r1, #4] } if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { a000cc4c: e5943050 ldr r3, [r4, #80] ; 0x50 a000cc50: e3530002 cmp r3, #2 a000cc54: 0a000001 beq a000cc60 <_Thread_queue_Dequeue_priority+0xcc> a000cc58: e129f002 msr CPSR_fc, r2 a000cc5c: ea000004 b a000cc74 <_Thread_queue_Dequeue_priority+0xe0> RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_REMOVE_IT; a000cc60: e3a03003 mov r3, #3 <== NOT EXECUTED a000cc64: e5843050 str r3, [r4, #80] ; 0x50 <== NOT EXECUTED a000cc68: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED _ISR_Enable( level ); _Thread_Unblock( the_thread ); } else { _Watchdog_Deactivate( &the_thread->Timer ); _ISR_Enable( level ); (void) _Watchdog_Remove( &the_thread->Timer ); a000cc6c: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED a000cc70: eb000215 bl a000d4cc <_Watchdog_Remove> <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); a000cc74: e1a00004 mov r0, r4 a000cc78: e59f1008 ldr r1, [pc, #8] ; a000cc88 <_Thread_queue_Dequeue_priority+0xf4> a000cc7c: ebfffdfa bl a000c46c <_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 ); } a000cc80: e1a00004 mov r0, r4 a000cc84: e8bd8030 pop {r4, r5, pc} =============================================================================== a000ff60 <_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 ) { a000ff60: e92d4010 push {r4, lr} a000ff64: e1a03000 mov r3, r0 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000ff68: e10fc000 mrs ip, CPSR a000ff6c: e38c0080 orr r0, ip, #128 ; 0x80 a000ff70: e129f000 msr CPSR_fc, r0 Thread_blocking_operation_States sync_state; ISR_Level level; _ISR_Disable( level ); sync_state = the_thread_queue->sync_state; a000ff74: e5930030 ldr r0, [r3, #48] ; 0x30 the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; a000ff78: e3a04000 mov r4, #0 a000ff7c: e5834030 str r4, [r3, #48] ; 0x30 if (sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED) { a000ff80: e3500001 cmp r0, #1 a000ff84: 1a000008 bne a000ffac <_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; a000ff88: 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 ); a000ff8c: e2834004 add r4, r3, #4 Chain_Node *old_last = tail->previous; the_node->next = tail; tail->previous = the_node; a000ff90: e5831008 str r1, [r3, #8] ) { Chain_Node *tail = _Chain_Tail( the_chain ); Chain_Node *old_last = tail->previous; the_node->next = tail; a000ff94: e5814000 str r4, [r1] tail->previous = the_node; old_last->next = the_node; the_node->previous = old_last; a000ff98: 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; a000ff9c: e5821000 str r1, [r2] _Chain_Append_unprotected( &the_thread_queue->Queues.Fifo, &the_thread->Object.Node ); the_thread->Wait.queue = the_thread_queue; a000ffa0: e5813044 str r3, [r1, #68] ; 0x44 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000ffa4: e129f00c msr CPSR_fc, ip the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; a000ffa8: 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; a000ffac: e582c000 str ip, [r2] <== NOT EXECUTED return sync_state; } a000ffb0: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000cd2c <_Thread_queue_Enqueue_priority>: 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 ); a000cd2c: e281c03c add ip, r1, #60 ; 0x3c head->next = tail; a000cd30: e581c038 str ip, [r1, #56] ; 0x38 head->previous = NULL; a000cd34: e3a0c000 mov ip, #0 a000cd38: e581c03c str ip, [r1, #60] ; 0x3c Priority_Control priority; States_Control block_state; _Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; a000cd3c: 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 ); a000cd40: 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 ) { a000cd44: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} head->next = tail; head->previous = NULL; tail->previous = head; a000cd48: 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 ]; a000cd4c: e3a0500c mov r5, #12 RTEMS_INLINE_ROUTINE uint32_t _Thread_queue_Header_number ( Priority_Control the_priority ) { return (the_priority / TASK_QUEUE_DATA_PRIORITIES_PER_HEADER); a000cd50: e1a0332c lsr r3, ip, #6 block_state = the_thread_queue->state; if ( _Thread_queue_Is_reverse_search( priority ) ) a000cd54: e31c0020 tst ip, #32 _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 ]; a000cd58: e0250593 mla r5, r3, r5, r0 block_state = the_thread_queue->state; a000cd5c: e5908038 ldr r8, [r0, #56] ; 0x38 the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; a000cd60: 159fa150 ldrne sl, [pc, #336] ; a000ceb8 <_Thread_queue_Enqueue_priority+0x18c> 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; if ( _Thread_queue_Is_reverse_search( priority ) ) a000cd64: 1a000022 bne a000cdf4 <_Thread_queue_Enqueue_priority+0xc8> RTEMS_INLINE_ROUTINE bool _Chain_Is_tail( const Chain_Control *the_chain, const Chain_Node *the_node ) { return (the_node == _Chain_Immutable_tail( the_chain )); a000cd68: e285a004 add sl, r5, #4 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000cd6c: e10f4000 mrs r4, CPSR a000cd70: e3843080 orr r3, r4, #128 ; 0x80 a000cd74: e129f003 msr CPSR_fc, r3 a000cd78: e1a06004 mov r6, r4 goto restart_reverse_search; restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; a000cd7c: e3e07000 mvn r7, #0 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000cd80: e5953000 ldr r3, [r5] _ISR_Disable( level ); search_thread = (Thread_Control *) _Chain_First( header ); while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) { a000cd84: ea00000b b a000cdb8 <_Thread_queue_Enqueue_priority+0x8c> search_priority = search_thread->current_priority; a000cd88: e5937014 ldr r7, [r3, #20] if ( priority <= search_priority ) a000cd8c: e15c0007 cmp ip, r7 a000cd90: 9a00000a bls a000cdc0 <_Thread_queue_Enqueue_priority+0x94> static inline void arm_interrupt_flash( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000cd94: e10f9000 mrs r9, CPSR a000cd98: e129f004 msr CPSR_fc, r4 a000cd9c: e129f009 msr CPSR_fc, r9 RTEMS_INLINE_ROUTINE bool _States_Are_set ( States_Control the_states, States_Control mask ) { return ( (the_states & mask) != STATES_READY); a000cda0: e5939010 ldr r9, [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) ) { a000cda4: e1180009 tst r8, r9 a000cda8: 1a000001 bne a000cdb4 <_Thread_queue_Enqueue_priority+0x88> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000cdac: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED a000cdb0: eaffffed b a000cd6c <_Thread_queue_Enqueue_priority+0x40> <== NOT EXECUTED _ISR_Enable( level ); goto restart_forward_search; } search_thread = a000cdb4: 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 ) ) { a000cdb8: e153000a cmp r3, sl a000cdbc: 1afffff1 bne a000cd88 <_Thread_queue_Enqueue_priority+0x5c> } search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state != a000cdc0: e5905030 ldr r5, [r0, #48] ; 0x30 a000cdc4: e3550001 cmp r5, #1 a000cdc8: 1a000037 bne a000ceac <_Thread_queue_Enqueue_priority+0x180> THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; a000cdcc: e3a02000 mov r2, #0 if ( priority == search_priority ) a000cdd0: e15c0007 cmp ip, r7 if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; a000cdd4: e5802030 str r2, [r0, #48] ; 0x30 if ( priority == search_priority ) a000cdd8: 0a000029 beq a000ce84 <_Thread_queue_Enqueue_priority+0x158> goto equal_priority; search_node = (Chain_Node *) search_thread; previous_node = search_node->previous; a000cddc: e5932004 ldr r2, [r3, #4] the_node = (Chain_Node *) the_thread; the_node->next = search_node; a000cde0: e5813000 str r3, [r1] the_node->previous = previous_node; a000cde4: e5812004 str r2, [r1, #4] previous_node->next = the_node; a000cde8: e5821000 str r1, [r2] search_node->previous = the_node; a000cdec: e5831004 str r1, [r3, #4] a000cdf0: ea000020 b a000ce78 <_Thread_queue_Enqueue_priority+0x14c> the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; a000cdf4: e5da7000 ldrb r7, [sl] a000cdf8: e2877001 add r7, r7, #1 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000cdfc: e10f4000 mrs r4, CPSR a000ce00: e3843080 orr r3, r4, #128 ; 0x80 a000ce04: e129f003 msr CPSR_fc, r3 a000ce08: e1a06004 mov r6, r4 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Last( Chain_Control *the_chain ) { return _Chain_Tail( the_chain )->previous; a000ce0c: e5953008 ldr r3, [r5, #8] _ISR_Disable( level ); search_thread = (Thread_Control *) _Chain_Last( header ); while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) { a000ce10: ea00000b b a000ce44 <_Thread_queue_Enqueue_priority+0x118> search_priority = search_thread->current_priority; a000ce14: e5937014 ldr r7, [r3, #20] if ( priority >= search_priority ) a000ce18: e15c0007 cmp ip, r7 a000ce1c: 2a00000a bcs a000ce4c <_Thread_queue_Enqueue_priority+0x120> static inline void arm_interrupt_flash( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000ce20: e10f9000 mrs r9, CPSR <== NOT EXECUTED a000ce24: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED a000ce28: e129f009 msr CPSR_fc, r9 <== NOT EXECUTED a000ce2c: e5939010 ldr r9, [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) ) { a000ce30: e1180009 tst r8, r9 <== NOT EXECUTED a000ce34: 1a000001 bne a000ce40 <_Thread_queue_Enqueue_priority+0x114><== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000ce38: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED a000ce3c: eaffffec b a000cdf4 <_Thread_queue_Enqueue_priority+0xc8> <== NOT EXECUTED _ISR_Enable( level ); goto restart_reverse_search; } search_thread = (Thread_Control *) a000ce40: 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 ) ) { a000ce44: e1530005 cmp r3, r5 a000ce48: 1afffff1 bne a000ce14 <_Thread_queue_Enqueue_priority+0xe8> } search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state != a000ce4c: e5905030 ldr r5, [r0, #48] ; 0x30 a000ce50: e3550001 cmp r5, #1 a000ce54: 1a000014 bne a000ceac <_Thread_queue_Enqueue_priority+0x180> THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; a000ce58: e3a02000 mov r2, #0 if ( priority == search_priority ) a000ce5c: e15c0007 cmp ip, r7 if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; a000ce60: e5802030 str r2, [r0, #48] ; 0x30 if ( priority == search_priority ) a000ce64: 0a000006 beq a000ce84 <_Thread_queue_Enqueue_priority+0x158> goto equal_priority; search_node = (Chain_Node *) search_thread; next_node = search_node->next; a000ce68: e5932000 ldr r2, [r3] the_node = (Chain_Node *) the_thread; the_node->next = next_node; the_node->previous = search_node; a000ce6c: e881000c stm r1, {r2, r3} search_node->next = the_node; a000ce70: e5831000 str r1, [r3] next_node->previous = the_node; a000ce74: e5821004 str r1, [r2, #4] the_thread->Wait.queue = the_thread_queue; a000ce78: e5810044 str r0, [r1, #68] ; 0x44 a000ce7c: e129f004 msr CPSR_fc, r4 a000ce80: ea000007 b a000cea4 <_Thread_queue_Enqueue_priority+0x178> _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 ); previous_node = search_node->previous; a000ce84: 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 ); a000ce88: e283c03c add ip, r3, #60 ; 0x3c <== NOT EXECUTED previous_node = search_node->previous; the_node = (Chain_Node *) the_thread; the_node->next = search_node; a000ce8c: e581c000 str ip, [r1] <== NOT EXECUTED the_node->previous = previous_node; a000ce90: e5812004 str r2, [r1, #4] <== NOT EXECUTED previous_node->next = the_node; a000ce94: e5821000 str r1, [r2] <== NOT EXECUTED search_node->previous = the_node; a000ce98: e5831040 str r1, [r3, #64] ; 0x40 <== NOT EXECUTED the_thread->Wait.queue = the_thread_queue; a000ce9c: e5810044 str r0, [r1, #68] ; 0x44 <== NOT EXECUTED a000cea0: e129f006 msr CPSR_fc, r6 <== NOT EXECUTED _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; a000cea4: e3a00001 mov r0, #1 a000cea8: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, 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; a000ceac: e5826000 str r6, [r2] <== NOT EXECUTED return the_thread_queue->sync_state; a000ceb0: e5900030 ldr r0, [r0, #48] ; 0x30 <== NOT EXECUTED } a000ceb4: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED =============================================================================== a000cc8c <_Thread_queue_Enqueue_with_handler>: Thread_queue_Control *, Thread_Control *, ISR_Level * ); the_thread = _Thread_Executing; a000cc8c: e59f3088 ldr r3, [pc, #136] ; a000cd1c <_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 ) { a000cc90: e92d40f1 push {r0, r4, r5, r6, r7, lr} Thread_queue_Control *, Thread_Control *, ISR_Level * ); the_thread = _Thread_Executing; a000cc94: e5934008 ldr r4, [r3, #8] void _Thread_queue_Enqueue_with_handler( Thread_queue_Control *the_thread_queue, Watchdog_Interval timeout, Thread_queue_Timeout_callout handler ) { a000cc98: e1a05000 mov r5, r0 a000cc9c: 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 ); a000cca0: e1a00004 mov r0, r4 a000cca4: 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 ) { a000cca8: 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 ); a000ccac: eb0000dc bl a000d024 <_Thread_Set_state> /* * If the thread wants to timeout, then schedule its timer. */ if ( timeout ) { a000ccb0: e3560000 cmp r6, #0 a000ccb4: 0a000009 beq a000cce0 <_Thread_queue_Enqueue_with_handler+0x54> _Watchdog_Initialize( a000ccb8: e5942008 ldr r2, [r4, #8] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a000ccbc: e3a03000 mov r3, #0 a000ccc0: e5843050 str r3, [r4, #80] ; 0x50 the_watchdog->routine = routine; a000ccc4: e5847064 str r7, [r4, #100] ; 0x64 the_watchdog->id = id; a000ccc8: e5842068 str r2, [r4, #104] ; 0x68 the_watchdog->user_data = user_data; a000cccc: e584306c str r3, [r4, #108] ; 0x6c Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a000ccd0: e5846054 str r6, [r4, #84] ; 0x54 _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a000ccd4: e59f0044 ldr r0, [pc, #68] ; a000cd20 <_Thread_queue_Enqueue_with_handler+0x94> a000ccd8: e2841048 add r1, r4, #72 ; 0x48 a000ccdc: eb0001a3 bl a000d370 <_Watchdog_Insert> } /* * Now enqueue the thread per the discipline for this thread queue. */ if ( the_thread_queue->discipline == THREAD_QUEUE_DISCIPLINE_PRIORITY ) a000cce0: e5951034 ldr r1, [r5, #52] ; 0x34 enqueue_p = _Thread_queue_Enqueue_priority; a000cce4: e59f2038 ldr r2, [pc, #56] ; a000cd24 <_Thread_queue_Enqueue_with_handler+0x98> a000cce8: e59f3038 ldr r3, [pc, #56] ; a000cd28 <_Thread_queue_Enqueue_with_handler+0x9c> a000ccec: e3510001 cmp r1, #1 a000ccf0: 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 ); a000ccf4: e1a00005 mov r0, r5 a000ccf8: e1a01004 mov r1, r4 a000ccfc: e1a0200d mov r2, sp a000cd00: e12fff33 blx r3 if ( sync_state != THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) a000cd04: e3500001 cmp r0, #1 a000cd08: 0a000002 beq a000cd18 <_Thread_queue_Enqueue_with_handler+0x8c> _Thread_blocking_operation_Cancel( sync_state, the_thread, level ); a000cd0c: e1a01004 mov r1, r4 <== NOT EXECUTED a000cd10: e59d2000 ldr r2, [sp] <== NOT EXECUTED a000cd14: ebfffd85 bl a000c330 <_Thread_blocking_operation_Cancel> <== NOT EXECUTED } a000cd18: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} =============================================================================== a00117d8 <_Thread_queue_Extract_fifo>: void _Thread_queue_Extract_fifo( Thread_queue_Control *the_thread_queue __attribute__((unused)), Thread_Control *the_thread ) { a00117d8: e92d4010 push {r4, lr} a00117dc: e1a04001 mov r4, r1 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a00117e0: e10f3000 mrs r3, CPSR a00117e4: e3832080 orr r2, r3, #128 ; 0x80 a00117e8: e129f002 msr CPSR_fc, r2 a00117ec: e59f2060 ldr r2, [pc, #96] ; a0011854 <_Thread_queue_Extract_fifo+0x7c> a00117f0: e5911010 ldr r1, [r1, #16] a00117f4: e0012002 and r2, r1, r2 ISR_Level level; _ISR_Disable( level ); if ( !_States_Is_waiting_on_thread_queue( the_thread->current_state ) ) { a00117f8: e3520000 cmp r2, #0 a00117fc: 1a000001 bne a0011808 <_Thread_queue_Extract_fifo+0x30> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0011800: 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 } a0011804: e8bd8010 pop {r4, pc} { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; a0011808: e8940006 ldm r4, {r1, r2} next->previous = previous; a001180c: e5812004 str r2, [r1, #4] previous->next = next; a0011810: e5821000 str r1, [r2] return; } _Chain_Extract_unprotected( &the_thread->Object.Node ); the_thread->Wait.queue = NULL; a0011814: e3a02000 mov r2, #0 a0011818: e5842044 str r2, [r4, #68] ; 0x44 if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { a001181c: e5942050 ldr r2, [r4, #80] ; 0x50 a0011820: e3520002 cmp r2, #2 a0011824: 0a000001 beq a0011830 <_Thread_queue_Extract_fifo+0x58> a0011828: e129f003 msr CPSR_fc, r3 a001182c: ea000004 b a0011844 <_Thread_queue_Extract_fifo+0x6c> a0011830: e3a02003 mov r2, #3 <== NOT EXECUTED a0011834: e5842050 str r2, [r4, #80] ; 0x50 <== NOT EXECUTED a0011838: 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 ); a001183c: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED a0011840: ebffef21 bl a000d4cc <_Watchdog_Remove> <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); a0011844: e59f100c ldr r1, [pc, #12] ; a0011858 <_Thread_queue_Extract_fifo+0x80> a0011848: e1a00004 mov r0, r4 #if defined(RTEMS_MULTIPROCESSING) if ( !_Objects_Is_local_id( the_thread->Object.id ) ) _Thread_MP_Free_proxy( the_thread ); #endif } a001184c: e8bd4010 pop {r4, lr} a0011850: eaffeb05 b a000c46c <_Thread_Clear_state> =============================================================================== a000ffcc <_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 ) { a000ffcc: e92d4070 push {r4, r5, r6, lr} a000ffd0: e20220ff and r2, r2, #255 ; 0xff a000ffd4: e1a04001 mov r4, r1 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000ffd8: e10f1000 mrs r1, CPSR a000ffdc: e3813080 orr r3, r1, #128 ; 0x80 a000ffe0: 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); a000ffe4: e59f30ac ldr r3, [pc, #172] ; a0010098 <_Thread_queue_Extract_priority_helper+0xcc> a000ffe8: e5940010 ldr r0, [r4, #16] a000ffec: 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 ) ) { a000fff0: e3530000 cmp r3, #0 a000fff4: 0a000017 beq a0010058 <_Thread_queue_Extract_priority_helper+0x8c> */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000fff8: e5943038 ldr r3, [r4, #56] ; 0x38 RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); a000fffc: e284503c add r5, r4, #60 ; 0x3c /* * The thread was actually waiting on a thread queue so let's remove it. */ next_node = the_node->next; previous_node = the_node->previous; a0010000: e8941001 ldm r4, {r0, ip} if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { a0010004: e1530005 cmp r3, r5 head->next = new_second_node; tail->previous = last_node; last_node->next = tail; } } else { previous_node->next = next_node; a0010008: 058c0000 streq r0, [ip] next_node->previous = previous_node; a001000c: 0580c004 streq ip, [r0, #4] */ next_node = the_node->next; previous_node = the_node->previous; if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { a0010010: 0a00000e beq a0010050 <_Thread_queue_Extract_priority_helper+0x84> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Last( Chain_Control *the_chain ) { return _Chain_Tail( the_chain )->previous; a0010014: e5945040 ldr r5, [r4, #64] ; 0x40 <== 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; a0010018: e5936000 ldr r6, [r3] <== NOT EXECUTED previous_node->next = new_first_node; next_node->previous = new_first_node; a001001c: 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; a0010020: e58c3000 str r3, [ip] <== NOT EXECUTED next_node->previous = new_first_node; new_first_node->next = next_node; new_first_node->previous = previous_node; a0010024: e8831001 stm r3, {r0, ip} <== NOT EXECUTED if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) { a0010028: e594c038 ldr ip, [r4, #56] ; 0x38 <== NOT EXECUTED a001002c: e5940040 ldr r0, [r4, #64] ; 0x40 <== NOT EXECUTED a0010030: e15c0000 cmp ip, r0 <== NOT EXECUTED a0010034: 0a000005 beq a0010050 <_Thread_queue_Extract_priority_helper+0x84><== NOT EXECUTED /* > two threads on 2-n */ head = _Chain_Head( &new_first_thread->Wait.Block2n ); a0010038: 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; a001003c: 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; a0010040: e5860004 str r0, [r6, #4] <== NOT EXECUTED head->next = new_second_node; tail->previous = last_node; a0010044: 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 ); a0010048: 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; a001004c: e5853000 str r3, [r5] <== NOT EXECUTED /* * If we are not supposed to touch timers or the thread's state, return. */ if ( requeuing ) { a0010050: e3520000 cmp r2, #0 a0010054: 0a000001 beq a0010060 <_Thread_queue_Extract_priority_helper+0x94> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0010058: e129f001 msr CPSR_fc, r1 a001005c: e8bd8070 pop {r4, r5, r6, pc} _ISR_Enable( level ); return; } if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { a0010060: e5943050 ldr r3, [r4, #80] ; 0x50 <== NOT EXECUTED a0010064: e3530002 cmp r3, #2 <== NOT EXECUTED a0010068: 0a000001 beq a0010074 <_Thread_queue_Extract_priority_helper+0xa8><== NOT EXECUTED a001006c: e129f001 msr CPSR_fc, r1 <== NOT EXECUTED a0010070: ea000004 b a0010088 <_Thread_queue_Extract_priority_helper+0xbc><== NOT EXECUTED a0010074: e3a03003 mov r3, #3 <== NOT EXECUTED a0010078: e5843050 str r3, [r4, #80] ; 0x50 <== NOT EXECUTED a001007c: 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 ); a0010080: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED a0010084: ebfff510 bl a000d4cc <_Watchdog_Remove> <== NOT EXECUTED a0010088: e59f100c ldr r1, [pc, #12] ; a001009c <_Thread_queue_Extract_priority_helper+0xd0><== NOT EXECUTED a001008c: 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 } a0010090: e8bd4070 pop {r4, r5, r6, lr} <== NOT EXECUTED a0010094: eafff0f4 b a000c46c <_Thread_Clear_state> <== NOT EXECUTED =============================================================================== a000ed38 <_Thread_queue_First_priority>: Thread_queue_Control *the_thread_queue ) { uint32_t index; for( index=0 ; a000ed38: e3a03000 mov r3, #0 <== NOT EXECUTED index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ; index++ ) { if ( !_Chain_Is_empty( &the_thread_queue->Queues.Priority[ index ] ) ) a000ed3c: e3a0100c mov r1, #12 <== NOT EXECUTED a000ed40: e0020391 mul r2, r1, r3 <== NOT EXECUTED a000ed44: e080c002 add ip, r0, r2 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000ed48: e7902002 ldr r2, [r0, 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 ); a000ed4c: e28cc004 add ip, ip, #4 <== NOT EXECUTED a000ed50: e152000c cmp r2, ip <== NOT EXECUTED a000ed54: 1a000003 bne a000ed68 <_Thread_queue_First_priority+0x30> <== NOT EXECUTED { uint32_t index; for( index=0 ; index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ; index++ ) { a000ed58: e2833001 add r3, r3, #1 <== NOT EXECUTED Thread_queue_Control *the_thread_queue ) { uint32_t index; for( index=0 ; a000ed5c: e3530004 cmp r3, #4 <== NOT EXECUTED a000ed60: 1afffff6 bne a000ed40 <_Thread_queue_First_priority+0x8> <== 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; a000ed64: e3a02000 mov r2, #0 <== NOT EXECUTED } a000ed68: e1a00002 mov r0, r2 <== NOT EXECUTED a000ed6c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a00100a0 <_Thread_queue_Process_timeout>: #include void _Thread_queue_Process_timeout( Thread_Control *the_thread ) { a00100a0: e1a01000 mov r1, r0 <== NOT EXECUTED Thread_queue_Control *the_thread_queue = the_thread->Wait.queue; a00100a4: 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 && a00100a8: e5903030 ldr r3, [r0, #48] ; 0x30 <== NOT EXECUTED a00100ac: e3530000 cmp r3, #0 <== NOT EXECUTED a00100b0: 0a000009 beq a00100dc <_Thread_queue_Process_timeout+0x3c> <== NOT EXECUTED RTEMS_INLINE_ROUTINE bool _Thread_Is_executing ( const Thread_Control *the_thread ) { return ( the_thread == _Thread_Executing ); a00100b4: e59f202c ldr r2, [pc, #44] ; a00100e8 <_Thread_queue_Process_timeout+0x48><== NOT EXECUTED a00100b8: e5922008 ldr r2, [r2, #8] <== NOT EXECUTED a00100bc: e1510002 cmp r1, r2 <== NOT EXECUTED a00100c0: 1a000005 bne a00100dc <_Thread_queue_Process_timeout+0x3c> <== NOT EXECUTED _Thread_Is_executing( the_thread ) ) { if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_SATISFIED ) { a00100c4: e3530003 cmp r3, #3 <== NOT EXECUTED the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status; a00100c8: 1590303c ldrne r3, [r0, #60] ; 0x3c <== NOT EXECUTED a00100cc: 15813034 strne r3, [r1, #52] ; 0x34 <== NOT EXECUTED the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT; a00100d0: 13a03002 movne r3, #2 <== NOT EXECUTED a00100d4: 15803030 strne r3, [r0, #48] ; 0x30 <== NOT EXECUTED a00100d8: e12fff1e bx lr <== NOT EXECUTED } } else { the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status; a00100dc: e590303c ldr r3, [r0, #60] ; 0x3c <== NOT EXECUTED a00100e0: e5813034 str r3, [r1, #52] ; 0x34 <== NOT EXECUTED _Thread_queue_Extract( the_thread->Wait.queue, the_thread ); a00100e4: eaffffb2 b a000ffb4 <_Thread_queue_Extract> <== NOT EXECUTED =============================================================================== a000cfd4 <_Thread_queue_Timeout>: void _Thread_queue_Timeout( Objects_Id id, void *ignored __attribute__((unused)) ) { a000cfd4: e92d4001 push {r0, lr} <== NOT EXECUTED Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); a000cfd8: e1a0100d mov r1, sp <== NOT EXECUTED a000cfdc: ebfffe07 bl a000c800 <_Thread_Get> <== NOT EXECUTED switch ( location ) { a000cfe0: e59d3000 ldr r3, [sp] <== NOT EXECUTED a000cfe4: e3530000 cmp r3, #0 <== NOT EXECUTED a000cfe8: 1a000004 bne a000d000 <_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 ); a000cfec: eb000c2b bl a00100a0 <_Thread_queue_Process_timeout> <== NOT EXECUTED * * This routine decrements the thread dispatch level. */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000cff0: e59f300c ldr r3, [pc, #12] ; a000d004 <_Thread_queue_Timeout+0x30><== NOT EXECUTED a000cff4: e5932000 ldr r2, [r3] <== NOT EXECUTED --level; a000cff8: e2422001 sub r2, r2, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a000cffc: e5832000 str r2, [r3] <== NOT EXECUTED _Thread_Unnest_dispatch(); break; } } a000d000: e8bd8008 pop {r3, pc} <== NOT EXECUTED =============================================================================== a0019124 <_Timer_server_Body>: * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { a0019124: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} a0019128: e24dd01c sub sp, sp, #28 ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); head->next = tail; a001912c: e28d8004 add r8, sp, #4 a0019130: e28d5010 add r5, sp, #16 head->previous = NULL; a0019134: e3a03000 mov r3, #0 ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); head->next = tail; a0019138: e2889004 add r9, r8, #4 a001913c: e2856004 add r6, r5, #4 a0019140: e1a04000 mov r4, r0 a0019144: e58d9004 str r9, [sp, #4] head->previous = NULL; a0019148: e58d3008 str r3, [sp, #8] tail->previous = head; a001914c: e58d800c str r8, [sp, #12] ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); head->next = tail; a0019150: e58d6010 str r6, [sp, #16] head->previous = NULL; a0019154: e58d3014 str r3, [sp, #20] tail->previous = head; a0019158: e58d5018 str r5, [sp, #24] static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot; a001915c: e59f717c ldr r7, [pc, #380] ; a00192e0 <_Timer_server_Body+0x1bc> { /* * 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; a0019160: e5848078 str r8, [r4, #120] ; 0x78 static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot; a0019164: e5973000 ldr r3, [r7] /* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; a0019168: e594103c ldr r1, [r4, #60] ; 0x3c watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); a001916c: e2840030 add r0, r4, #48 ; 0x30 /* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; a0019170: e584303c str r3, [r4, #60] ; 0x3c _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); a0019174: e0611003 rsb r1, r1, r3 a0019178: e1a02005 mov r2, r5 a001917c: eb0010eb bl a001d530 <_Watchdog_Adjust_to_chain> a0019180: e59f315c ldr r3, [pc, #348] ; a00192e4 <_Timer_server_Body+0x1c0> a0019184: e59f215c ldr r2, [pc, #348] ; a00192e8 <_Timer_server_Body+0x1c4> a0019188: e8930003 ldm r3, {r0, r1} a001918c: e3a03000 mov r3, #0 a0019190: eb004f13 bl a002cde4 <__divdi3> Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch(); Watchdog_Interval last_snapshot = watchdogs->last_snapshot; a0019194: e5942074 ldr r2, [r4, #116] ; 0x74 a0019198: e1a0a000 mov sl, r0 /* * 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 ) { a001919c: e1500002 cmp r0, r2 a00191a0: 9a000004 bls a00191b8 <_Timer_server_Body+0x94> /* * 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 ); a00191a4: e062100a rsb r1, r2, sl a00191a8: e2840068 add r0, r4, #104 ; 0x68 a00191ac: e1a02005 mov r2, r5 a00191b0: eb0010de bl a001d530 <_Watchdog_Adjust_to_chain> a00191b4: ea000004 b a00191cc <_Timer_server_Body+0xa8> } else if ( snapshot < last_snapshot ) { a00191b8: 2a000003 bcs a00191cc <_Timer_server_Body+0xa8> /* * 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 ); a00191bc: e2840068 add r0, r4, #104 ; 0x68 <== NOT EXECUTED a00191c0: e3a01001 mov r1, #1 <== NOT EXECUTED a00191c4: e06a2002 rsb r2, sl, r2 <== NOT EXECUTED a00191c8: eb0010b0 bl a001d490 <_Watchdog_Adjust> <== NOT EXECUTED } watchdogs->last_snapshot = snapshot; a00191cc: e584a074 str sl, [r4, #116] ; 0x74 ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) { _Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker ); a00191d0: e284b068 add fp, r4, #104 ; 0x68 Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); a00191d4: e284a030 add sl, r4, #48 ; 0x30 } static void _Timer_server_Process_insertions( Timer_server_Control *ts ) { while ( true ) { Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain ); a00191d8: e5940078 ldr r0, [r4, #120] ; 0x78 a00191dc: eb0002bf bl a0019ce0 <_Chain_Get> if ( timer == NULL ) { a00191e0: e2501000 subs r1, r0, #0 a00191e4: 0a000009 beq a0019210 <_Timer_server_Body+0xec> static void _Timer_server_Insert_timer( Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { a00191e8: e5913038 ldr r3, [r1, #56] ; 0x38 <== NOT EXECUTED a00191ec: e3530001 cmp r3, #1 <== NOT EXECUTED _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); a00191f0: 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 ) { a00191f4: 0a000002 beq a0019204 <_Timer_server_Body+0xe0> <== NOT EXECUTED _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) { a00191f8: e3530003 cmp r3, #3 <== NOT EXECUTED a00191fc: 1afffff5 bne a00191d8 <_Timer_server_Body+0xb4> <== NOT EXECUTED _Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker ); a0019200: e1a0000b mov r0, fp <== NOT EXECUTED a0019204: e2811010 add r1, r1, #16 <== NOT EXECUTED a0019208: eb0010ed bl a001d5c4 <_Watchdog_Insert> <== NOT EXECUTED a001920c: eafffff1 b a00191d8 <_Timer_server_Body+0xb4> <== 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 ); a0019210: e58d1000 str r1, [sp] a0019214: ebffff96 bl a0019074 if ( _Chain_Is_empty( insert_chain ) ) { a0019218: e59d3004 ldr r3, [sp, #4] a001921c: e59d1000 ldr r1, [sp] a0019220: e1530009 cmp r3, r9 a0019224: 1a000006 bne a0019244 <_Timer_server_Body+0x120> ts->insert_chain = NULL; a0019228: e5841078 str r1, [r4, #120] ; 0x78 a001922c: e129f000 msr CPSR_fc, r0 _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 ) ) { a0019230: e59d3010 ldr r3, [sp, #16] a0019234: e1530006 cmp r3, r6 * service routine may remove a watchdog from the chain. */ _ISR_Disable( level ); watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain ); if ( watchdog != NULL ) { watchdog->state = WATCHDOG_INACTIVE; a0019238: 13a07000 movne r7, #0 _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 ) ) { a001923c: 1a000002 bne a001924c <_Timer_server_Body+0x128> a0019240: ea000011 b a001928c <_Timer_server_Body+0x168> a0019244: e129f000 msr CPSR_fc, r0 <== NOT EXECUTED a0019248: eaffffc5 b a0019164 <_Timer_server_Body+0x40> <== NOT EXECUTED /* * It is essential that interrupts are disable here since an interrupt * service routine may remove a watchdog from the chain. */ _ISR_Disable( level ); a001924c: ebffff88 bl a0019074 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a0019250: e59d2010 ldr r2, [sp, #16] */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) a0019254: e1520006 cmp r2, r6 a0019258: 0a000009 beq a0019284 <_Timer_server_Body+0x160> Chain_Control *the_chain ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *old_first = head->next; Chain_Node *new_first = old_first->next; a001925c: e5923000 ldr r3, [r2] head->next = new_first; new_first->previous = head; a0019260: e5835004 str r5, [r3, #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; a0019264: e58d3010 str r3, [sp, #16] watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain ); if ( watchdog != NULL ) { watchdog->state = WATCHDOG_INACTIVE; a0019268: e5827008 str r7, [r2, #8] a001926c: 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 ); a0019270: e592301c ldr r3, [r2, #28] a0019274: e5920020 ldr r0, [r2, #32] a0019278: e5921024 ldr r1, [r2, #36] ; 0x24 a001927c: e12fff33 blx r3 } a0019280: eafffff1 b a001924c <_Timer_server_Body+0x128> a0019284: e129f000 msr CPSR_fc, r0 a0019288: eaffffb3 b a001915c <_Timer_server_Body+0x38> } else { ts->active = false; a001928c: e3a03000 mov r3, #0 a0019290: e5c4307c strb r3, [r4, #124] ; 0x7c * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0019294: e59f3050 ldr r3, [pc, #80] ; a00192ec <_Timer_server_Body+0x1c8> a0019298: e5932000 ldr r2, [r3] ++level; a001929c: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a00192a0: e5832000 str r2, [r3] /* * Block until there is something to do. */ _Thread_Disable_dispatch(); _Thread_Set_state( ts->thread, STATES_DELAYING ); a00192a4: e3a01008 mov r1, #8 a00192a8: e5940000 ldr r0, [r4] a00192ac: eb000fa4 bl a001d144 <_Thread_Set_state> _Timer_server_Reset_interval_system_watchdog( ts ); a00192b0: e1a00004 mov r0, r4 a00192b4: ebffff72 bl a0019084 <_Timer_server_Reset_interval_system_watchdog> _Timer_server_Reset_tod_system_watchdog( ts ); a00192b8: e1a00004 mov r0, r4 a00192bc: ebffff84 bl a00190d4 <_Timer_server_Reset_tod_system_watchdog> _Thread_Enable_dispatch(); a00192c0: eb000d6f bl a001c884 <_Thread_Enable_dispatch> ts->active = true; a00192c4: e3a03001 mov r3, #1 a00192c8: 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 ); a00192cc: e2840008 add r0, r4, #8 a00192d0: eb001112 bl a001d720 <_Watchdog_Remove> static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog ); a00192d4: e2840040 add r0, r4, #64 ; 0x40 a00192d8: eb001110 bl a001d720 <_Watchdog_Remove> a00192dc: eaffff9e b a001915c <_Timer_server_Body+0x38> =============================================================================== a00192f0 <_Timer_server_Schedule_operation_method>: static void _Timer_server_Schedule_operation_method( Timer_server_Control *ts, Timer_Control *timer ) { a00192f0: e92d40f0 push {r4, r5, r6, r7, lr} if ( ts->insert_chain == NULL ) { a00192f4: e5906078 ldr r6, [r0, #120] ; 0x78 static void _Timer_server_Schedule_operation_method( Timer_server_Control *ts, Timer_Control *timer ) { a00192f8: e1a04000 mov r4, r0 a00192fc: e1a05001 mov r5, r1 if ( ts->insert_chain == NULL ) { a0019300: e3560000 cmp r6, #0 a0019304: 1a000041 bne a0019410 <_Timer_server_Schedule_operation_method+0x120> * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0019308: e59f310c ldr r3, [pc, #268] ; a001941c <_Timer_server_Schedule_operation_method+0x12c> a001930c: e5932000 ldr r2, [r3] ++level; a0019310: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a0019314: e5832000 str r2, [r3] * being inserted. This could result in an integer overflow. */ _Thread_Disable_dispatch(); if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { a0019318: e5913038 ldr r3, [r1, #56] ; 0x38 a001931c: e3530001 cmp r3, #1 a0019320: 1a000017 bne a0019384 <_Timer_server_Schedule_operation_method+0x94> /* * We have to advance the last known ticks value of the server and update * the watchdog chain accordingly. */ _ISR_Disable( level ); a0019324: ebffff52 bl a0019074 snapshot = _Watchdog_Ticks_since_boot; a0019328: e59f30f0 ldr r3, [pc, #240] ; a0019420 <_Timer_server_Schedule_operation_method+0x130> RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); a001932c: e284c034 add ip, r4, #52 ; 0x34 a0019330: e5932000 ldr r2, [r3] */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a0019334: e5943030 ldr r3, [r4, #48] ; 0x30 last_snapshot = ts->Interval_watchdogs.last_snapshot; a0019338: e594103c ldr r1, [r4, #60] ; 0x3c if ( !_Chain_Is_empty( &ts->Interval_watchdogs.Chain ) ) { a001933c: e153000c cmp r3, ip a0019340: 0a000004 beq a0019358 <_Timer_server_Schedule_operation_method+0x68> /* * We assume adequate unsigned arithmetic here. */ delta = snapshot - last_snapshot; delta_interval = first_watchdog->delta_interval; a0019344: e593c010 ldr ip, [r3, #16] first_watchdog = _Watchdog_First( &ts->Interval_watchdogs.Chain ); /* * We assume adequate unsigned arithmetic here. */ delta = snapshot - last_snapshot; a0019348: e0611002 rsb r1, r1, r2 delta_interval = first_watchdog->delta_interval; if (delta_interval > delta) { a001934c: e15c0001 cmp ip, r1 delta_interval -= delta; a0019350: 8061600c rsbhi r6, r1, ip } else { delta_interval = 0; } first_watchdog->delta_interval = delta_interval; a0019354: e5836010 str r6, [r3, #16] } ts->Interval_watchdogs.last_snapshot = snapshot; a0019358: e584203c str r2, [r4, #60] ; 0x3c a001935c: e129f000 msr CPSR_fc, r0 _ISR_Enable( level ); _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); a0019360: e2840030 add r0, r4, #48 ; 0x30 a0019364: e2851010 add r1, r5, #16 a0019368: eb001095 bl a001d5c4 <_Watchdog_Insert> if ( !ts->active ) { a001936c: e5d4307c ldrb r3, [r4, #124] ; 0x7c a0019370: e3530000 cmp r3, #0 a0019374: 1a000023 bne a0019408 <_Timer_server_Schedule_operation_method+0x118> _Timer_server_Reset_interval_system_watchdog( ts ); a0019378: e1a00004 mov r0, r4 a001937c: ebffff40 bl a0019084 <_Timer_server_Reset_interval_system_watchdog> a0019380: ea000020 b a0019408 <_Timer_server_Schedule_operation_method+0x118> } } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) { a0019384: e3530003 cmp r3, #3 a0019388: 1a00001e bne a0019408 <_Timer_server_Schedule_operation_method+0x118> /* * We have to advance the last known seconds value of the server and update * the watchdog chain accordingly. */ _ISR_Disable( level ); a001938c: ebffff38 bl a0019074 a0019390: e1a07000 mov r7, r0 a0019394: e59f3088 ldr r3, [pc, #136] ; a0019424 <_Timer_server_Schedule_operation_method+0x134> a0019398: e59f2088 ldr r2, [pc, #136] ; a0019428 <_Timer_server_Schedule_operation_method+0x138> a001939c: e8930003 ldm r3, {r0, r1} a00193a0: e3a03000 mov r3, #0 a00193a4: eb004e8e bl a002cde4 <__divdi3> a00193a8: e5943068 ldr r3, [r4, #104] ; 0x68 RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); a00193ac: e284106c add r1, r4, #108 ; 0x6c snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch(); last_snapshot = ts->TOD_watchdogs.last_snapshot; a00193b0: e5942074 ldr r2, [r4, #116] ; 0x74 if ( !_Chain_Is_empty( &ts->TOD_watchdogs.Chain ) ) { a00193b4: e1530001 cmp r3, r1 a00193b8: 0a000008 beq a00193e0 <_Timer_server_Schedule_operation_method+0xf0> first_watchdog = _Watchdog_First( &ts->TOD_watchdogs.Chain ); delta_interval = first_watchdog->delta_interval; a00193bc: e5931010 ldr r1, [r3, #16] <== NOT EXECUTED if ( snapshot > last_snapshot ) { a00193c0: e1500002 cmp r0, r2 <== NOT EXECUTED } } else { /* * Someone put us in the past. */ delta = last_snapshot - snapshot; a00193c4: 90816002 addls r6, r1, r2 <== NOT EXECUTED delta_interval += delta; a00193c8: 90606006 rsbls r6, r0, 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 ) { a00193cc: 9a000002 bls a00193dc <_Timer_server_Schedule_operation_method+0xec><== NOT EXECUTED /* * We advanced in time. */ delta = snapshot - last_snapshot; a00193d0: e0622000 rsb r2, r2, r0 <== NOT EXECUTED if (delta_interval > delta) { a00193d4: e1510002 cmp r1, r2 <== NOT EXECUTED delta_interval -= delta; a00193d8: 80626001 rsbhi r6, r2, r1 <== NOT EXECUTED * Someone put us in the past. */ delta = last_snapshot - snapshot; delta_interval += delta; } first_watchdog->delta_interval = delta_interval; a00193dc: e5836010 str r6, [r3, #16] <== NOT EXECUTED } ts->TOD_watchdogs.last_snapshot = snapshot; a00193e0: e5840074 str r0, [r4, #116] ; 0x74 a00193e4: e129f007 msr CPSR_fc, r7 _ISR_Enable( level ); _Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker ); a00193e8: e2840068 add r0, r4, #104 ; 0x68 a00193ec: e2851010 add r1, r5, #16 a00193f0: eb001073 bl a001d5c4 <_Watchdog_Insert> if ( !ts->active ) { a00193f4: e5d4307c ldrb r3, [r4, #124] ; 0x7c a00193f8: e3530000 cmp r3, #0 a00193fc: 1a000001 bne a0019408 <_Timer_server_Schedule_operation_method+0x118> _Timer_server_Reset_tod_system_watchdog( ts ); a0019400: e1a00004 mov r0, r4 a0019404: ebffff32 bl a00190d4 <_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 ); } } a0019408: e8bd40f0 pop {r4, r5, r6, r7, lr} if ( !ts->active ) { _Timer_server_Reset_tod_system_watchdog( ts ); } } _Thread_Enable_dispatch(); a001940c: ea000d1c b a001c884 <_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 ); a0019410: e5900078 ldr r0, [r0, #120] ; 0x78 <== NOT EXECUTED } } a0019414: e8bd40f0 pop {r4, r5, r6, r7, 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 ); a0019418: ea000225 b a0019cb4 <_Chain_Append> <== NOT EXECUTED =============================================================================== a000e794 <_Timestamp64_Divide>: const Timestamp64_Control *_lhs, const Timestamp64_Control *_rhs, uint32_t *_ival_percentage, uint32_t *_fval_percentage ) { a000e794: e92d40f0 push {r4, r5, r6, r7, lr} <== NOT EXECUTED a000e798: e1a04002 mov r4, r2 <== NOT EXECUTED a000e79c: e1a05003 mov r5, r3 <== NOT EXECUTED Timestamp64_Control answer; if ( *_rhs == 0 ) { a000e7a0: e891000c ldm r1, {r2, r3} <== NOT EXECUTED a000e7a4: e1921003 orrs r1, r2, r3 <== NOT EXECUTED a000e7a8: 1a000003 bne a000e7bc <_Timestamp64_Divide+0x28> <== NOT EXECUTED *_ival_percentage = 0; a000e7ac: e3a03000 mov r3, #0 <== NOT EXECUTED a000e7b0: e5843000 str r3, [r4] <== NOT EXECUTED *_fval_percentage = 0; a000e7b4: e5853000 str r3, [r5] <== NOT EXECUTED return; a000e7b8: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED * This looks odd but gives the results the proper precision. * * TODO: Rounding on the last digit of the fval. */ answer = (*_lhs * 100000) / *_rhs; a000e7bc: e59fc044 ldr ip, [pc, #68] ; a000e808 <_Timestamp64_Divide+0x74><== NOT EXECUTED a000e7c0: e5906000 ldr r6, [r0] <== NOT EXECUTED a000e7c4: e590e004 ldr lr, [r0, #4] <== NOT EXECUTED a000e7c8: e0810c96 umull r0, r1, r6, ip <== NOT EXECUTED a000e7cc: e0211e9c mla r1, ip, lr, r1 <== NOT EXECUTED a000e7d0: eb003ade bl a001d350 <__divdi3> <== NOT EXECUTED *_ival_percentage = answer / 1000; a000e7d4: e3a02ffa mov r2, #1000 ; 0x3e8 <== NOT EXECUTED a000e7d8: e3a03000 mov r3, #0 <== NOT EXECUTED * This looks odd but gives the results the proper precision. * * TODO: Rounding on the last digit of the fval. */ answer = (*_lhs * 100000) / *_rhs; a000e7dc: e1a07000 mov r7, r0 <== NOT EXECUTED a000e7e0: e1a06001 mov r6, r1 <== NOT EXECUTED *_ival_percentage = answer / 1000; a000e7e4: eb003ad9 bl a001d350 <__divdi3> <== NOT EXECUTED *_fval_percentage = answer % 1000; a000e7e8: e1a01006 mov r1, r6 <== NOT EXECUTED * TODO: Rounding on the last digit of the fval. */ answer = (*_lhs * 100000) / *_rhs; *_ival_percentage = answer / 1000; a000e7ec: e5840000 str r0, [r4] <== NOT EXECUTED *_fval_percentage = answer % 1000; a000e7f0: e3a02ffa mov r2, #1000 ; 0x3e8 <== NOT EXECUTED a000e7f4: e1a00007 mov r0, r7 <== NOT EXECUTED a000e7f8: e3a03000 mov r3, #0 <== NOT EXECUTED a000e7fc: eb003c0e bl a001d83c <__moddi3> <== NOT EXECUTED a000e800: e5850000 str r0, [r5] <== NOT EXECUTED a000e804: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED =============================================================================== a0010bfc <_User_extensions_Remove_set>: #include void _User_extensions_Remove_set ( User_extensions_Control *the_extension ) { a0010bfc: e92d4010 push {r4, lr} a0010c00: e1a04000 mov r4, r0 _Chain_Extract( &the_extension->Node ); a0010c04: eb0012d5 bl a0015760 <_Chain_Extract> /* * If a switch handler is present, remove it. */ if ( the_extension->Callouts.thread_switch != NULL ) a0010c08: e5943024 ldr r3, [r4, #36] ; 0x24 a0010c0c: e3530000 cmp r3, #0 a0010c10: 0a000002 beq a0010c20 <_User_extensions_Remove_set+0x24> _Chain_Extract( &the_extension->Switch.Node ); a0010c14: e2840008 add r0, r4, #8 <== NOT EXECUTED } a0010c18: e8bd4010 pop {r4, lr} <== NOT EXECUTED /* * If a switch handler is present, remove it. */ if ( the_extension->Callouts.thread_switch != NULL ) _Chain_Extract( &the_extension->Switch.Node ); a0010c1c: ea0012cf b a0015760 <_Chain_Extract> <== NOT EXECUTED a0010c20: e8bd8010 pop {r4, pc} =============================================================================== a000ea24 <_Watchdog_Adjust>: void _Watchdog_Adjust( Chain_Control *header, Watchdog_Adjust_directions direction, Watchdog_Interval units ) { a000ea24: e92d40f0 push {r4, r5, r6, r7, lr} a000ea28: e1a04000 mov r4, r0 a000ea2c: e1a05002 mov r5, r2 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000ea30: e10f3000 mrs r3, CPSR a000ea34: e3832080 orr r2, r3, #128 ; 0x80 a000ea38: e129f002 msr CPSR_fc, r2 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000ea3c: e1a06000 mov r6, r0 a000ea40: 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 ) ) { a000ea44: e1520006 cmp r2, r6 a000ea48: 0a00001b beq a000eabc <_Watchdog_Adjust+0x98> switch ( direction ) { a000ea4c: 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; a000ea50: 03a07001 moveq r7, #1 * unmodified across that call. * * Till Straumann, 7/2003 */ if ( !_Chain_Is_empty( header ) ) { switch ( direction ) { a000ea54: 0a000016 beq a000eab4 <_Watchdog_Adjust+0x90> a000ea58: e3510001 cmp r1, #1 <== NOT EXECUTED case WATCHDOG_BACKWARD: _Watchdog_First( header )->delta_interval += units; a000ea5c: 05921010 ldreq r1, [r2, #16] <== NOT EXECUTED a000ea60: 00815005 addeq r5, r1, r5 <== NOT EXECUTED * unmodified across that call. * * Till Straumann, 7/2003 */ if ( !_Chain_Is_empty( header ) ) { switch ( direction ) { a000ea64: 1a000014 bne a000eabc <_Watchdog_Adjust+0x98> <== NOT EXECUTED a000ea68: ea000004 b a000ea80 <_Watchdog_Adjust+0x5c> <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000ea6c: e5942000 ldr r2, [r4] case WATCHDOG_BACKWARD: _Watchdog_First( header )->delta_interval += units; break; case WATCHDOG_FORWARD: while ( units ) { if ( units < _Watchdog_First( header )->delta_interval ) { a000ea70: e5921010 ldr r1, [r2, #16] a000ea74: e1550001 cmp r5, r1 a000ea78: 2a000002 bcs a000ea88 <_Watchdog_Adjust+0x64> _Watchdog_First( header )->delta_interval -= units; a000ea7c: e0655001 rsb r5, r5, r1 <== NOT EXECUTED a000ea80: e5825010 str r5, [r2, #16] <== NOT EXECUTED break; a000ea84: ea00000c b a000eabc <_Watchdog_Adjust+0x98> <== NOT EXECUTED } else { units -= _Watchdog_First( header )->delta_interval; _Watchdog_First( header )->delta_interval = 1; a000ea88: e5827010 str r7, [r2, #16] while ( units ) { if ( units < _Watchdog_First( header )->delta_interval ) { _Watchdog_First( header )->delta_interval -= units; break; } else { units -= _Watchdog_First( header )->delta_interval; a000ea8c: e0615005 rsb r5, r1, r5 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000ea90: e129f003 msr CPSR_fc, r3 _Watchdog_First( header )->delta_interval = 1; _ISR_Enable( level ); _Watchdog_Tickle( header ); a000ea94: e1a00004 mov r0, r4 a000ea98: eb000089 bl a000ecc4 <_Watchdog_Tickle> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000ea9c: e10f3000 mrs r3, CPSR a000eaa0: e3832080 orr r2, r3, #128 ; 0x80 a000eaa4: e129f002 msr CPSR_fc, r2 _ISR_Disable( level ); if ( _Chain_Is_empty( header ) ) a000eaa8: e5942000 ldr r2, [r4] a000eaac: e1520006 cmp r2, r6 a000eab0: 0a000001 beq a000eabc <_Watchdog_Adjust+0x98> switch ( direction ) { case WATCHDOG_BACKWARD: _Watchdog_First( header )->delta_interval += units; break; case WATCHDOG_FORWARD: while ( units ) { a000eab4: e3550000 cmp r5, #0 a000eab8: 1affffeb bne a000ea6c <_Watchdog_Adjust+0x48> static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000eabc: e129f003 msr CPSR_fc, r3 } } _ISR_Enable( level ); } a000eac0: e8bd80f0 pop {r4, r5, r6, r7, pc} =============================================================================== a001d530 <_Watchdog_Adjust_to_chain>: Chain_Control *header, Watchdog_Interval units_arg, Chain_Control *to_fire ) { a001d530: e92d41f0 push {r4, r5, r6, r7, r8, lr} uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a001d534: e10f4000 mrs r4, CPSR a001d538: e3843080 orr r3, r4, #128 ; 0x80 a001d53c: 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; a001d540: 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 ); a001d544: e2805004 add r5, r0, #4 RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected( Chain_Control *the_chain, Chain_Node *the_node ) { Chain_Node *tail = _Chain_Tail( the_chain ); a001d548: e2827004 add r7, r2, #4 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a001d54c: e5903000 ldr r3, [r0] Watchdog_Control *first; _ISR_Disable( level ); while ( 1 ) { if ( _Chain_Is_empty( header ) ) { a001d550: e1530005 cmp r3, r5 a001d554: 0a000018 beq a001d5bc <_Watchdog_Adjust_to_chain+0x8c> /* * If it is longer than "units" until the first element on the chain * fires, then bump it and quit. */ if ( units < first->delta_interval ) { a001d558: e593c010 ldr ip, [r3, #16] a001d55c: e151000c cmp r1, ip first->delta_interval -= units; a001d560: 3061100c rsbcc r1, r1, ip a001d564: 35831010 strcc r1, [r3, #16] break; a001d568: 3a000013 bcc a001d5bc <_Watchdog_Adjust_to_chain+0x8c> /* * 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; a001d56c: e06c1001 rsb r1, ip, r1 first->delta_interval = 0; a001d570: e5838010 str r8, [r3, #16] { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; a001d574: e8931040 ldm r3, {r6, ip} next->previous = previous; a001d578: e586c004 str ip, [r6, #4] previous->next = next; a001d57c: e58c6000 str r6, [ip] Chain_Control *the_chain, Chain_Node *the_node ) { Chain_Node *tail = _Chain_Tail( the_chain ); Chain_Node *old_last = tail->previous; a001d580: e592c008 ldr ip, [r2, #8] the_node->next = tail; a001d584: e5837000 str r7, [r3] tail->previous = the_node; a001d588: e5823008 str r3, [r2, #8] old_last->next = the_node; a001d58c: e58c3000 str r3, [ip] the_node->previous = old_last; a001d590: e583c004 str ip, [r3, #4] static inline void arm_interrupt_flash( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a001d594: e10f3000 mrs r3, CPSR a001d598: e129f004 msr CPSR_fc, r4 a001d59c: e129f003 msr CPSR_fc, r3 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a001d5a0: e5903000 ldr r3, [r0] _Chain_Extract_unprotected( &first->Node ); _Chain_Append_unprotected( to_fire, &first->Node ); _ISR_Flash( level ); if ( _Chain_Is_empty( header ) ) a001d5a4: e1530005 cmp r3, r5 a001d5a8: 0affffe7 beq a001d54c <_Watchdog_Adjust_to_chain+0x1c> break; first = _Watchdog_First( header ); if ( first->delta_interval != 0 ) a001d5ac: e593c010 ldr ip, [r3, #16] <== NOT EXECUTED a001d5b0: e35c0000 cmp ip, #0 <== NOT EXECUTED a001d5b4: 0affffee beq a001d574 <_Watchdog_Adjust_to_chain+0x44> <== NOT EXECUTED a001d5b8: eaffffe3 b a001d54c <_Watchdog_Adjust_to_chain+0x1c> <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a001d5bc: e129f004 msr CPSR_fc, r4 break; } } _ISR_Enable( level ); } a001d5c0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a000e570 <_Watchdog_Report>: void _Watchdog_Report( const char *name, Watchdog_Control *watch ) { a000e570: e92d401f push {r0, r1, r2, r3, r4, lr} <== NOT EXECUTED a000e574: e1a03001 mov r3, r1 <== NOT EXECUTED printk( a000e578: e2501000 subs r1, r0, #0 <== NOT EXECUTED a000e57c: e593000c ldr r0, [r3, #12] <== NOT EXECUTED a000e580: 059f1034 ldreq r1, [pc, #52] ; a000e5bc <_Watchdog_Report+0x4c><== NOT EXECUTED a000e584: 159f2034 ldrne r2, [pc, #52] ; a000e5c0 <_Watchdog_Report+0x50><== NOT EXECUTED a000e588: e88d0009 stm sp, {r0, r3} <== NOT EXECUTED a000e58c: e593001c ldr r0, [r3, #28] <== NOT EXECUTED a000e590: 01a02001 moveq r2, r1 <== NOT EXECUTED a000e594: e58d0008 str r0, [sp, #8] <== NOT EXECUTED a000e598: e5930020 ldr r0, [r3, #32] <== NOT EXECUTED a000e59c: e58d000c str r0, [sp, #12] <== NOT EXECUTED a000e5a0: e5930024 ldr r0, [r3, #36] ; 0x24 <== NOT EXECUTED a000e5a4: e58d0010 str r0, [sp, #16] <== NOT EXECUTED a000e5a8: e5933010 ldr r3, [r3, #16] <== NOT EXECUTED a000e5ac: e59f0010 ldr r0, [pc, #16] ; a000e5c4 <_Watchdog_Report+0x54><== NOT EXECUTED a000e5b0: ebffe530 bl a0007a78 <== NOT EXECUTED watch, watch->routine, watch->id, watch->user_data ); } a000e5b4: e28dd014 add sp, sp, #20 <== NOT EXECUTED a000e5b8: e8bd8000 pop {pc} <== NOT EXECUTED =============================================================================== a000e4f4 <_Watchdog_Report_chain>: void _Watchdog_Report_chain( const char *name, Chain_Control *header ) { a000e4f4: e92d40f0 push {r4, r5, r6, r7, lr} a000e4f8: e1a04000 mov r4, r0 a000e4fc: e1a05001 mov r5, r1 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000e500: e10f6000 mrs r6, CPSR a000e504: e3863080 orr r3, r6, #128 ; 0x80 a000e508: e129f003 msr CPSR_fc, r3 ISR_Level level; Chain_Node *node; _ISR_Disable( level ); printk( "Watchdog Chain: %s %p\n", name, header ); a000e50c: e59f0050 ldr r0, [pc, #80] ; a000e564 <_Watchdog_Report_chain+0x70> a000e510: e1a02005 mov r2, r5 a000e514: e1a01004 mov r1, r4 a000e518: ebffe556 bl a0007a78 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000e51c: e4957004 ldr r7, [r5], #4 if ( !_Chain_Is_empty( header ) ) { a000e520: e1570005 cmp r7, r5 a000e524: 1a000004 bne a000e53c <_Watchdog_Report_chain+0x48> a000e528: ea000009 b a000e554 <_Watchdog_Report_chain+0x60> node != _Chain_Tail(header) ; node = node->next ) { Watchdog_Control *watch = (Watchdog_Control *) node; _Watchdog_Report( NULL, watch ); a000e52c: e1a01007 mov r1, r7 <== NOT EXECUTED a000e530: e3a00000 mov r0, #0 <== NOT EXECUTED a000e534: eb00000d bl a000e570 <_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 ) a000e538: 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 ) ; a000e53c: e1570005 cmp r7, r5 <== NOT EXECUTED a000e540: 1afffff9 bne a000e52c <_Watchdog_Report_chain+0x38> <== NOT EXECUTED { Watchdog_Control *watch = (Watchdog_Control *) node; _Watchdog_Report( NULL, watch ); } printk( "== end of %s \n", name ); a000e544: e59f001c ldr r0, [pc, #28] ; a000e568 <_Watchdog_Report_chain+0x74><== NOT EXECUTED a000e548: e1a01004 mov r1, r4 <== NOT EXECUTED a000e54c: ebffe549 bl a0007a78 <== NOT EXECUTED a000e550: ea000001 b a000e55c <_Watchdog_Report_chain+0x68> <== NOT EXECUTED } else { printk( "Chain is empty\n" ); a000e554: e59f0010 ldr r0, [pc, #16] ; a000e56c <_Watchdog_Report_chain+0x78> a000e558: ebffe546 bl a0007a78 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000e55c: e129f006 msr CPSR_fc, r6 } _ISR_Enable( level ); } a000e560: e8bd80f0 pop {r4, r5, r6, r7, pc} =============================================================================== a000a040 : */ int adjtime( const struct timeval *delta, struct timeval *olddelta ) { a000a040: e92d4373 push {r0, r1, r4, r5, r6, r8, r9, lr} long adjustment; /* * Simple validations */ if ( !delta ) a000a044: e2505000 subs r5, r0, #0 */ int adjtime( const struct timeval *delta, struct timeval *olddelta ) { a000a048: e1a06001 mov r6, r1 long adjustment; /* * Simple validations */ if ( !delta ) a000a04c: 0a000003 beq a000a060 rtems_set_errno_and_return_minus_one( EINVAL ); if ( delta->tv_usec >= TOD_MICROSECONDS_PER_SECOND ) a000a050: e5952004 ldr r2, [r5, #4] a000a054: e59f3128 ldr r3, [pc, #296] ; a000a184 a000a058: e1520003 cmp r2, r3 a000a05c: 9a000004 bls a000a074 rtems_set_errno_and_return_minus_one( EINVAL ); a000a060: eb0020d8 bl a00123c8 <__errno> a000a064: e3a03016 mov r3, #22 a000a068: e5803000 str r3, [r0] a000a06c: e3e00000 mvn r0, #0 a000a070: ea000042 b a000a180 if ( olddelta ) { a000a074: e3510000 cmp r1, #0 <== NOT EXECUTED olddelta->tv_sec = 0; a000a078: 13a03000 movne r3, #0 <== NOT EXECUTED a000a07c: 15813000 strne r3, [r1] <== NOT EXECUTED olddelta->tv_usec = 0; a000a080: 15813004 strne r3, [r1, #4] <== NOT EXECUTED } /* convert delta to microseconds */ adjustment = (delta->tv_sec * TOD_MICROSECONDS_PER_SECOND); adjustment += delta->tv_usec; a000a084: e59f10fc ldr r1, [pc, #252] ; a000a188 <== NOT EXECUTED a000a088: e895000c ldm r5, {r2, r3} <== NOT EXECUTED a000a08c: e0223291 mla r2, r1, r2, r3 <== NOT EXECUTED /* too small to account for */ if ( adjustment < rtems_configuration_get_microseconds_per_tick() ) a000a090: e59f30f4 ldr r3, [pc, #244] ; a000a18c <== NOT EXECUTED a000a094: e593300c ldr r3, [r3, #12] <== NOT EXECUTED a000a098: e1520003 cmp r2, r3 <== NOT EXECUTED a000a09c: 3a000036 bcc a000a17c <== NOT EXECUTED * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000a0a0: e59f30e8 ldr r3, [pc, #232] ; a000a190 <== NOT EXECUTED a000a0a4: e5932000 ldr r2, [r3] <== NOT EXECUTED ++level; a000a0a8: e2822001 add r2, r2, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a000a0ac: e5832000 str r2, [r3] <== NOT EXECUTED ) { Timestamp_Control tod_as_timestamp; Timestamp_Control *tod_as_timestamp_ptr; tod_as_timestamp_ptr = a000a0b0: e59f10dc ldr r1, [pc, #220] ; a000a194 <== NOT EXECUTED a000a0b4: e1a0000d mov r0, sp <== NOT EXECUTED a000a0b8: eb000607 bl a000b8dc <_TOD_Get_with_nanoseconds> <== NOT EXECUTED const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a000a0bc: e59f20d4 ldr r2, [pc, #212] ; a000a198 <== NOT EXECUTED /* set the user's output */ if ( olddelta ) *olddelta = *delta; return 0; } a000a0c0: e8900300 ldm r0, {r8, r9} <== NOT EXECUTED a000a0c4: e3a03000 mov r3, #0 <== NOT EXECUTED a000a0c8: e1a00008 mov r0, r8 <== NOT EXECUTED a000a0cc: e1a01009 mov r1, r9 <== NOT EXECUTED a000a0d0: eb004fca bl a001e000 <__moddi3> <== NOT EXECUTED _Thread_Disable_dispatch(); _TOD_Get( &ts ); ts.tv_sec += delta->tv_sec; ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND; a000a0d4: e5953004 ldr r3, [r5, #4] <== NOT EXECUTED a000a0d8: e3a04ffa mov r4, #1000 ; 0x3e8 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a000a0dc: e59f20b4 ldr r2, [pc, #180] ; a000a198 <== NOT EXECUTED a000a0e0: e0240493 mla r4, r3, r4, r0 <== NOT EXECUTED a000a0e4: e1a01009 mov r1, r9 <== NOT EXECUTED a000a0e8: e3a03000 mov r3, #0 <== NOT EXECUTED a000a0ec: e1a00008 mov r0, r8 <== NOT EXECUTED a000a0f0: eb004e87 bl a001db14 <__divdi3> <== NOT EXECUTED _Thread_Disable_dispatch(); _TOD_Get( &ts ); ts.tv_sec += delta->tv_sec; a000a0f4: e5953000 ldr r3, [r5] <== NOT EXECUTED ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND; /* if adjustment is too much positive */ while ( ts.tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) { a000a0f8: e59f209c ldr r2, [pc, #156] ; a000a19c <== NOT EXECUTED _Thread_Disable_dispatch(); _TOD_Get( &ts ); ts.tv_sec += delta->tv_sec; a000a0fc: e0830000 add r0, r3, r0 <== NOT EXECUTED ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND; /* if adjustment is too much positive */ while ( ts.tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) { a000a100: ea000002 b a000a110 <== NOT EXECUTED int _EXFUN(setitimer, (int __which, const struct itimerval *__value, struct itimerval *__ovalue)); #if defined(__rtems__) /* BSD function used by RTEMS code */ int _EXFUN(adjtime,(const struct timeval *, struct timeval *)); a000a104: e2844331 add r4, r4, #-1006632960 ; 0xc4000000 <== NOT EXECUTED a000a108: e2844865 add r4, r4, #6619136 ; 0x650000 <== NOT EXECUTED a000a10c: e2844c36 add r4, r4, #13824 ; 0x3600 <== NOT EXECUTED a000a110: e1540002 cmp r4, r2 <== NOT EXECUTED a000a114: e1a03000 mov r3, r0 <== NOT EXECUTED a000a118: e2800001 add r0, r0, #1 <== NOT EXECUTED a000a11c: 8afffff8 bhi a000a104 <== 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) ) { a000a120: e59f2078 ldr r2, [pc, #120] ; a000a1a0 <== NOT EXECUTED a000a124: ea000002 b a000a134 <== NOT EXECUTED a000a128: e28445ee add r4, r4, #998244352 ; 0x3b800000 <== NOT EXECUTED a000a12c: e284496b add r4, r4, #1753088 ; 0x1ac000 <== NOT EXECUTED a000a130: e2844c0a add r4, r4, #2560 ; 0xa00 <== NOT EXECUTED a000a134: e1540002 cmp r4, r2 <== NOT EXECUTED a000a138: e1a00003 mov r0, r3 <== NOT EXECUTED a000a13c: e2433001 sub r3, r3, #1 <== NOT EXECUTED a000a140: 9afffff8 bls a000a128 <== NOT EXECUTED Timestamp64_Control *_time, Timestamp64_Control _seconds, Timestamp64_Control _nanoseconds ) { *_time = _seconds * 1000000000L + _nanoseconds; a000a144: e59f104c ldr r1, [pc, #76] ; a000a198 <== NOT EXECUTED const struct timespec *tod_as_timespec ) { Timestamp_Control tod_as_timestamp; _Timestamp_Set( a000a148: e1a02004 mov r2, r4 <== NOT EXECUTED a000a14c: e1a03fc4 asr r3, r4, #31 <== NOT EXECUTED a000a150: e0e32091 smlal r2, r3, r1, r0 <== NOT EXECUTED a000a154: e28d0008 add r0, sp, #8 <== NOT EXECUTED a000a158: e920000c stmdb r0!, {r2, r3} <== NOT EXECUTED &tod_as_timestamp, tod_as_timespec->tv_sec, tod_as_timespec->tv_nsec ); _TOD_Set_with_timestamp( &tod_as_timestamp ); a000a15c: e1a0000d mov r0, sp <== NOT EXECUTED a000a160: eb0005fc bl a000b958 <_TOD_Set_with_timestamp> <== NOT EXECUTED ts.tv_sec--; } _TOD_Set( &ts ); _Thread_Enable_dispatch(); a000a164: eb000bfa bl a000d154 <_Thread_Enable_dispatch> <== NOT EXECUTED /* set the user's output */ if ( olddelta ) a000a168: e3560000 cmp r6, #0 <== NOT EXECUTED *olddelta = *delta; return 0; a000a16c: 01a00006 moveq r0, r6 <== NOT EXECUTED _TOD_Set( &ts ); _Thread_Enable_dispatch(); /* set the user's output */ if ( olddelta ) a000a170: 0a000002 beq a000a180 <== NOT EXECUTED *olddelta = *delta; a000a174: e895000c ldm r5, {r2, r3} <== NOT EXECUTED a000a178: e886000c stm r6, {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; a000a17c: e3a00000 mov r0, #0 <== NOT EXECUTED /* set the user's output */ if ( olddelta ) *olddelta = *delta; return 0; } a000a180: e8bd837c pop {r2, r3, r4, r5, r6, r8, r9, pc} =============================================================================== a000a268 : #include #include #include int aio_cancel(int fildes, struct aiocb *aiocbp) { a000a268: e92d41f0 push {r4, r5, r6, r7, r8, lr} rtems_aio_request_chain *r_chain; int result; pthread_mutex_lock (&aio_request_queue.mutex); a000a26c: e59f4198 ldr r4, [pc, #408] ; a000a40c #include #include #include int aio_cancel(int fildes, struct aiocb *aiocbp) { a000a270: e1a07000 mov r7, r0 a000a274: e1a05001 mov r5, r1 rtems_aio_request_chain *r_chain; int result; pthread_mutex_lock (&aio_request_queue.mutex); a000a278: e1a00004 mov r0, r4 a000a27c: eb000420 bl a000b304 if (fcntl (fildes, F_GETFD) < 0) { a000a280: e1a00007 mov r0, r7 a000a284: e3a01001 mov r1, #1 a000a288: eb001946 bl a00107a8 a000a28c: e3500000 cmp r0, #0 a000a290: aa000004 bge a000a2a8 pthread_mutex_unlock(&aio_request_queue.mutex); a000a294: e1a00004 mov r0, r4 a000a298: eb000438 bl a000b380 rtems_set_errno_and_return_minus_one (EBADF); a000a29c: eb002618 bl a0013b04 <__errno> a000a2a0: e3a03009 mov r3, #9 a000a2a4: ea00002f b a000a368 } /* if aiocbp is NULL remove all request for given file descriptor */ if (aiocbp == NULL) { a000a2a8: e3550000 cmp r5, #0 <== NOT EXECUTED a000a2ac: 1a000026 bne a000a34c <== NOT EXECUTED AIO_printf ("Cancel all requests\n"); r_chain = rtems_aio_search_fd (&aio_request_queue.work_req, fildes, 0); a000a2b0: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED a000a2b4: e1a01007 mov r1, r7 <== NOT EXECUTED a000a2b8: e1a02005 mov r2, r5 <== NOT EXECUTED a000a2bc: eb000154 bl a000a814 <== NOT EXECUTED if (r_chain == NULL) { a000a2c0: e2506000 subs r6, r0, #0 <== NOT EXECUTED a000a2c4: 1a000017 bne a000a328 <== NOT EXECUTED AIO_printf ("Request chain not on [WQ]\n"); if (!rtems_chain_is_empty (&aio_request_queue.idle_req)) { a000a2c8: e5942054 ldr r2, [r4, #84] ; 0x54 <== NOT EXECUTED a000a2cc: e2843058 add r3, r4, #88 ; 0x58 <== NOT EXECUTED a000a2d0: e1520003 cmp r2, r3 <== NOT EXECUTED a000a2d4: 0a00003b beq a000a3c8 <== NOT EXECUTED r_chain = rtems_aio_search_fd (&aio_request_queue.idle_req, fildes, 0); a000a2d8: e2840054 add r0, r4, #84 ; 0x54 <== NOT EXECUTED a000a2dc: e1a01007 mov r1, r7 <== NOT EXECUTED a000a2e0: e1a02006 mov r2, r6 <== NOT EXECUTED a000a2e4: eb00014a bl a000a814 <== NOT EXECUTED if (r_chain == NULL) { a000a2e8: e2505000 subs r5, r0, #0 <== NOT EXECUTED a000a2ec: 0a000035 beq a000a3c8 <== 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); a000a2f0: e285701c add r7, r5, #28 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node ); a000a2f4: eb000a54 bl a000cc4c <_Chain_Extract> <== NOT EXECUTED } AIO_printf ("Request chain on [IQ]\n"); rtems_chain_extract (&r_chain->next_fd); rtems_aio_remove_fd (r_chain); a000a2f8: e1a00005 mov r0, r5 <== NOT EXECUTED a000a2fc: eb00016f bl a000a8c0 <== NOT EXECUTED pthread_mutex_destroy (&r_chain->mutex); a000a300: e1a00007 mov r0, r7 <== NOT EXECUTED a000a304: eb00035c bl a000b07c <== NOT EXECUTED pthread_cond_destroy (&r_chain->mutex); a000a308: e1a00007 mov r0, r7 <== NOT EXECUTED a000a30c: eb00028c bl a000ad44 <== NOT EXECUTED free (r_chain); a000a310: e1a00005 mov r0, r5 <== NOT EXECUTED a000a314: ebfff1b4 bl a00069ec <== NOT EXECUTED pthread_mutex_unlock (&aio_request_queue.mutex); a000a318: e1a00004 mov r0, r4 <== NOT EXECUTED a000a31c: eb000417 bl a000b380 <== NOT EXECUTED return AIO_CANCELED; a000a320: e1a05006 mov r5, r6 <== NOT EXECUTED a000a324: ea000036 b a000a404 <== NOT EXECUTED return AIO_ALLDONE; } AIO_printf ("Request chain on [WQ]\n"); pthread_mutex_lock (&r_chain->mutex); a000a328: e286701c add r7, r6, #28 <== NOT EXECUTED a000a32c: e1a00007 mov r0, r7 <== NOT EXECUTED a000a330: eb0003f3 bl a000b304 <== NOT EXECUTED a000a334: e1a00006 mov r0, r6 <== NOT EXECUTED a000a338: eb000a43 bl a000cc4c <_Chain_Extract> <== NOT EXECUTED rtems_chain_extract (&r_chain->next_fd); rtems_aio_remove_fd (r_chain); a000a33c: e1a00006 mov r0, r6 <== NOT EXECUTED a000a340: eb00015e bl a000a8c0 <== NOT EXECUTED pthread_mutex_unlock (&r_chain->mutex); a000a344: e1a00007 mov r0, r7 <== NOT EXECUTED a000a348: ea00002a b a000a3f8 <== NOT EXECUTED pthread_mutex_unlock (&aio_request_queue.mutex); return AIO_CANCELED; } else { AIO_printf ("Cancel request\n"); if (aiocbp->aio_fildes != fildes) { a000a34c: e5956000 ldr r6, [r5] <== NOT EXECUTED a000a350: e1560007 cmp r6, r7 <== NOT EXECUTED a000a354: 0a000006 beq a000a374 <== NOT EXECUTED pthread_mutex_unlock (&aio_request_queue.mutex); a000a358: e1a00004 mov r0, r4 <== NOT EXECUTED a000a35c: eb000407 bl a000b380 <== NOT EXECUTED rtems_set_errno_and_return_minus_one (EINVAL); a000a360: eb0025e7 bl a0013b04 <__errno> <== NOT EXECUTED a000a364: e3a03016 mov r3, #22 <== NOT EXECUTED a000a368: e5803000 str r3, [r0] a000a36c: e3e05000 mvn r5, #0 a000a370: ea000023 b a000a404 } r_chain = rtems_aio_search_fd (&aio_request_queue.work_req, fildes, 0); a000a374: e2840048 add r0, r4, #72 ; 0x48 <== NOT EXECUTED a000a378: e1a01006 mov r1, r6 <== NOT EXECUTED a000a37c: e3a02000 mov r2, #0 <== NOT EXECUTED a000a380: eb000123 bl a000a814 <== NOT EXECUTED if (r_chain == NULL) { a000a384: e2507000 subs r7, r0, #0 <== NOT EXECUTED a000a388: 1a000012 bne a000a3d8 <== NOT EXECUTED if (!rtems_chain_is_empty (&aio_request_queue.idle_req)) { a000a38c: e5942054 ldr r2, [r4, #84] ; 0x54 <== NOT EXECUTED a000a390: e2843058 add r3, r4, #88 ; 0x58 <== NOT EXECUTED a000a394: e1520003 cmp r2, r3 <== NOT EXECUTED a000a398: 0a00000a beq a000a3c8 <== NOT EXECUTED r_chain = rtems_aio_search_fd (&aio_request_queue.idle_req, fildes, 0); a000a39c: e2840054 add r0, r4, #84 ; 0x54 <== NOT EXECUTED a000a3a0: e1a01006 mov r1, r6 <== NOT EXECUTED a000a3a4: e1a02007 mov r2, r7 <== NOT EXECUTED a000a3a8: eb000119 bl a000a814 <== NOT EXECUTED if (r_chain == NULL) { a000a3ac: e3500000 cmp r0, #0 <== NOT EXECUTED a000a3b0: 0affffe8 beq a000a358 <== 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); a000a3b4: e1a01005 mov r1, r5 <== NOT EXECUTED a000a3b8: e2800008 add r0, r0, #8 <== NOT EXECUTED a000a3bc: eb000151 bl a000a908 <== NOT EXECUTED a000a3c0: e1a05000 mov r5, r0 <== NOT EXECUTED a000a3c4: ea00000c b a000a3fc <== NOT EXECUTED pthread_mutex_unlock (&aio_request_queue.mutex); return result; } else { pthread_mutex_unlock (&aio_request_queue.mutex); a000a3c8: e1a00004 mov r0, r4 <== NOT EXECUTED a000a3cc: eb0003eb bl a000b380 <== NOT EXECUTED return AIO_ALLDONE; a000a3d0: e3a05002 mov r5, #2 <== NOT EXECUTED a000a3d4: ea00000a b a000a404 <== NOT EXECUTED } } AIO_printf ("Request on [WQ]\n"); pthread_mutex_lock (&r_chain->mutex); a000a3d8: e287801c add r8, r7, #28 <== NOT EXECUTED a000a3dc: e1a00008 mov r0, r8 <== NOT EXECUTED a000a3e0: eb0003c7 bl a000b304 <== NOT EXECUTED result = rtems_aio_remove_req (&r_chain->perfd, aiocbp); a000a3e4: e1a01005 mov r1, r5 <== NOT EXECUTED a000a3e8: e2870008 add r0, r7, #8 <== NOT EXECUTED a000a3ec: eb000145 bl a000a908 <== NOT EXECUTED a000a3f0: e1a05000 mov r5, r0 <== NOT EXECUTED pthread_mutex_unlock (&r_chain->mutex); a000a3f4: e1a00008 mov r0, r8 <== NOT EXECUTED a000a3f8: eb0003e0 bl a000b380 <== NOT EXECUTED pthread_mutex_unlock (&aio_request_queue.mutex); a000a3fc: e1a00004 mov r0, r4 <== NOT EXECUTED a000a400: eb0003de bl a000b380 <== NOT EXECUTED return result; } return AIO_ALLDONE; } a000a404: e1a00005 mov r0, r5 a000a408: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a000a418 : ) { rtems_aio_request *req; int mode; if (op != O_SYNC) a000a418: e3500a02 cmp r0, #8192 ; 0x2000 int aio_fsync( int op, struct aiocb *aiocbp ) { a000a41c: e92d4030 push {r4, r5, lr} a000a420: e1a04001 mov r4, r1 rtems_aio_request *req; int mode; if (op != O_SYNC) rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp); a000a424: 13a05016 movne r5, #22 ) { rtems_aio_request *req; int mode; if (op != O_SYNC) a000a428: 1a00000c bne a000a460 rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp); mode = fcntl (aiocbp->aio_fildes, F_GETFL); a000a42c: e5910000 ldr r0, [r1] a000a430: e3a01003 mov r1, #3 a000a434: eb0018db bl a00107a8 if (!(((mode & O_ACCMODE) == O_WRONLY) || ((mode & O_ACCMODE) == O_RDWR))) a000a438: e2000003 and r0, r0, #3 a000a43c: e2400001 sub r0, r0, #1 a000a440: e3500001 cmp r0, #1 rtems_aio_set_errno_return_minus_one (EBADF, aiocbp); a000a444: 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))) a000a448: 8a000004 bhi a000a460 rtems_aio_set_errno_return_minus_one (EBADF, aiocbp); req = malloc (sizeof (rtems_aio_request)); a000a44c: e3a00018 mov r0, #24 <== NOT EXECUTED a000a450: ebfff282 bl a0006e60 <== NOT EXECUTED if (req == NULL) a000a454: e2503000 subs r3, r0, #0 <== NOT EXECUTED a000a458: 1a000007 bne a000a47c <== NOT EXECUTED rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp); a000a45c: e3a0500b mov r5, #11 <== NOT EXECUTED a000a460: e3e03000 mvn r3, #0 a000a464: e5845030 str r5, [r4, #48] ; 0x30 a000a468: e5843034 str r3, [r4, #52] ; 0x34 a000a46c: eb0025a4 bl a0013b04 <__errno> a000a470: e5805000 str r5, [r0] req->aiocbp = aiocbp; req->aiocbp->aio_lio_opcode = LIO_SYNC; return rtems_aio_enqueue (req); } a000a474: e3e00000 mvn r0, #0 a000a478: 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; a000a47c: e5834014 str r4, [r3, #20] <== NOT EXECUTED req->aiocbp->aio_lio_opcode = LIO_SYNC; a000a480: e3a03003 mov r3, #3 <== NOT EXECUTED a000a484: e584302c str r3, [r4, #44] ; 0x2c <== NOT EXECUTED return rtems_aio_enqueue (req); } a000a488: 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); a000a48c: ea000137 b a000a970 <== NOT EXECUTED =============================================================================== a000ab74 : * 0 - otherwise */ int aio_read (struct aiocb *aiocbp) { a000ab74: e92d4030 push {r4, r5, lr} rtems_aio_request *req; int mode; mode = fcntl (aiocbp->aio_fildes, F_GETFL); a000ab78: e3a01003 mov r1, #3 * 0 - otherwise */ int aio_read (struct aiocb *aiocbp) { a000ab7c: e1a04000 mov r4, r0 rtems_aio_request *req; int mode; mode = fcntl (aiocbp->aio_fildes, F_GETFL); a000ab80: e5900000 ldr r0, [r0] a000ab84: eb001707 bl a00107a8 if (!(((mode & O_ACCMODE) == O_RDONLY) || ((mode & O_ACCMODE) == O_RDWR))) a000ab88: e2000003 and r0, r0, #3 a000ab8c: e3500002 cmp r0, #2 a000ab90: 13500000 cmpne r0, #0 rtems_aio_set_errno_return_minus_one (EBADF, aiocbp); a000ab94: 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))) a000ab98: 1a00000d bne a000abd4 rtems_aio_set_errno_return_minus_one (EBADF, aiocbp); if (aiocbp->aio_reqprio < 0 || aiocbp->aio_reqprio > AIO_PRIO_DELTA_MAX) a000ab9c: e5943014 ldr r3, [r4, #20] a000aba0: e3530000 cmp r3, #0 a000aba4: 1a000003 bne a000abb8 rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp); if (aiocbp->aio_offset < 0) a000aba8: e994000c ldmib r4, {r2, r3} a000abac: e3520000 cmp r2, #0 a000abb0: e2d31000 sbcs r1, r3, #0 a000abb4: aa000001 bge a000abc0 rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp); a000abb8: e3a05016 mov r5, #22 a000abbc: ea000004 b a000abd4 req = malloc (sizeof (rtems_aio_request)); a000abc0: e3a00018 mov r0, #24 <== NOT EXECUTED a000abc4: ebfff0a5 bl a0006e60 <== NOT EXECUTED if (req == NULL) a000abc8: e2503000 subs r3, r0, #0 <== NOT EXECUTED a000abcc: 1a000007 bne a000abf0 <== NOT EXECUTED rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp); a000abd0: e3a0500b mov r5, #11 <== NOT EXECUTED a000abd4: e3e03000 mvn r3, #0 a000abd8: e5845030 str r5, [r4, #48] ; 0x30 a000abdc: e5843034 str r3, [r4, #52] ; 0x34 a000abe0: eb0023c7 bl a0013b04 <__errno> a000abe4: e5805000 str r5, [r0] req->aiocbp = aiocbp; req->aiocbp->aio_lio_opcode = LIO_READ; return rtems_aio_enqueue (req); } a000abe8: e3e00000 mvn r0, #0 a000abec: 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; a000abf0: e5834014 str r4, [r3, #20] <== NOT EXECUTED req->aiocbp->aio_lio_opcode = LIO_READ; a000abf4: e3a03001 mov r3, #1 <== NOT EXECUTED a000abf8: e584302c str r3, [r4, #44] ; 0x2c <== NOT EXECUTED return rtems_aio_enqueue (req); } a000abfc: 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); a000ac00: eaffff5a b a000a970 <== NOT EXECUTED =============================================================================== a000ac0c : * 0 - otherwise */ int aio_write (struct aiocb *aiocbp) { a000ac0c: e92d4030 push {r4, r5, lr} rtems_aio_request *req; int mode; mode = fcntl (aiocbp->aio_fildes, F_GETFL); a000ac10: e3a01003 mov r1, #3 * 0 - otherwise */ int aio_write (struct aiocb *aiocbp) { a000ac14: e1a04000 mov r4, r0 rtems_aio_request *req; int mode; mode = fcntl (aiocbp->aio_fildes, F_GETFL); a000ac18: e5900000 ldr r0, [r0] a000ac1c: eb0016e1 bl a00107a8 if (!(((mode & O_ACCMODE) == O_WRONLY) || ((mode & O_ACCMODE) == O_RDWR))) a000ac20: e2000003 and r0, r0, #3 a000ac24: e2400001 sub r0, r0, #1 a000ac28: e3500001 cmp r0, #1 rtems_aio_set_errno_return_minus_one (EBADF, aiocbp); a000ac2c: 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))) a000ac30: 8a00000d bhi a000ac6c rtems_aio_set_errno_return_minus_one (EBADF, aiocbp); if (aiocbp->aio_reqprio < 0 || aiocbp->aio_reqprio > AIO_PRIO_DELTA_MAX) a000ac34: e5943014 ldr r3, [r4, #20] a000ac38: e3530000 cmp r3, #0 a000ac3c: 1a000003 bne a000ac50 rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp); if (aiocbp->aio_offset < 0) a000ac40: e994000c ldmib r4, {r2, r3} a000ac44: e3520000 cmp r2, #0 a000ac48: e2d31000 sbcs r1, r3, #0 a000ac4c: aa000001 bge a000ac58 rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp); a000ac50: e3a05016 mov r5, #22 a000ac54: ea000004 b a000ac6c req = malloc (sizeof (rtems_aio_request)); a000ac58: e3a00018 mov r0, #24 a000ac5c: ebfff07f bl a0006e60 if (req == NULL) a000ac60: e2503000 subs r3, r0, #0 a000ac64: 1a000007 bne a000ac88 rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp); a000ac68: e3a0500b mov r5, #11 <== NOT EXECUTED a000ac6c: e3e03000 mvn r3, #0 a000ac70: e5845030 str r5, [r4, #48] ; 0x30 a000ac74: e5843034 str r3, [r4, #52] ; 0x34 a000ac78: eb0023a1 bl a0013b04 <__errno> a000ac7c: e5805000 str r5, [r0] req->aiocbp = aiocbp; req->aiocbp->aio_lio_opcode = LIO_WRITE; return rtems_aio_enqueue (req); } a000ac80: e3e00000 mvn r0, #0 a000ac84: 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; a000ac88: e5834014 str r4, [r3, #20] req->aiocbp->aio_lio_opcode = LIO_WRITE; a000ac8c: e3a03002 mov r3, #2 a000ac90: e584302c str r3, [r4, #44] ; 0x2c return rtems_aio_enqueue (req); } a000ac94: 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); a000ac98: eaffff34 b a000a970 =============================================================================== a000bb80 : } unsigned int alarm( unsigned int seconds ) { a000bb80: e92d4070 push {r4, r5, r6, lr} /* * Initialize the timer used to implement alarm(). */ if ( !the_timer->routine ) { a000bb84: e59f6080 ldr r6, [pc, #128] ; a000bc0c } unsigned int alarm( unsigned int seconds ) { a000bb88: e1a05000 mov r5, r0 /* * Initialize the timer used to implement alarm(). */ if ( !the_timer->routine ) { a000bb8c: e596401c ldr r4, [r6, #28] a000bb90: e3540000 cmp r4, #0 a000bb94: 1a000005 bne a000bbb0 Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a000bb98: e59f3070 ldr r3, [pc, #112] ; a000bc10 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a000bb9c: e5864008 str r4, [r6, #8] the_watchdog->routine = routine; the_watchdog->id = id; a000bba0: e5864020 str r4, [r6, #32] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a000bba4: e586301c str r3, [r6, #28] the_watchdog->id = id; the_watchdog->user_data = user_data; a000bba8: e5864024 str r4, [r6, #36] ; 0x24 a000bbac: ea00000e b a000bbec _Watchdog_Initialize( the_timer, _POSIX_signals_Alarm_TSR, 0, NULL ); } else { Watchdog_States state; state = _Watchdog_Remove( the_timer ); a000bbb0: e1a00006 mov r0, r6 <== NOT EXECUTED a000bbb4: eb0012ea bl a0010764 <_Watchdog_Remove> <== NOT EXECUTED if ( (state == WATCHDOG_ACTIVE) || (state == WATCHDOG_REMOVE_IT) ) { a000bbb8: e2400002 sub r0, r0, #2 <== NOT EXECUTED a000bbbc: e3500001 cmp r0, #1 <== NOT EXECUTED unsigned int alarm( unsigned int seconds ) { unsigned int remaining = 0; a000bbc0: 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) ) { a000bbc4: 8a000008 bhi a000bbec <== 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); a000bbc8: e5962018 ldr r2, [r6, #24] <== NOT EXECUTED a000bbcc: 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 - a000bbd0: e596400c ldr r4, [r6, #12] <== NOT EXECUTED ((the_timer->stop_time - the_timer->start_time) / TOD_TICKS_PER_SECOND); a000bbd4: e0636002 rsb r6, r3, r2 <== NOT EXECUTED a000bbd8: eb00098e bl a000e218 <== NOT EXECUTED a000bbdc: e1a01000 mov r1, r0 <== NOT EXECUTED a000bbe0: e1a00006 mov r0, r6 <== NOT EXECUTED a000bbe4: eb004bbf bl a001eae8 <__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 - a000bbe8: e0604004 rsb r4, r0, r4 <== NOT EXECUTED ((the_timer->stop_time - the_timer->start_time) / TOD_TICKS_PER_SECOND); } } if ( seconds ) a000bbec: e3550000 cmp r5, #0 a000bbf0: 0a000003 beq a000bc04 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a000bbf4: e59f1010 ldr r1, [pc, #16] ; a000bc0c _Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog ); a000bbf8: e59f0014 ldr r0, [pc, #20] ; a000bc14 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a000bbfc: e581500c str r5, [r1, #12] _Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog ); a000bc00: eb001280 bl a0010608 <_Watchdog_Insert> _Watchdog_Insert_seconds( the_timer, seconds ); return remaining; } a000bc04: e1a00004 mov r0, r4 a000bc08: e8bd8070 pop {r4, r5, r6, pc} =============================================================================== a000a4dc : int clock_getres( clockid_t clock_id, struct timespec *res ) { a000a4dc: e92d4030 push {r4, r5, lr} <== NOT EXECUTED if ( !res ) a000a4e0: e2514000 subs r4, r1, #0 <== NOT EXECUTED a000a4e4: 1a000004 bne a000a4fc <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EINVAL ); a000a4e8: eb0020b9 bl a00127d4 <__errno> <== NOT EXECUTED a000a4ec: e3a03016 mov r3, #22 <== NOT EXECUTED a000a4f0: e5803000 str r3, [r0] <== NOT EXECUTED a000a4f4: e3e00000 mvn r0, #0 <== NOT EXECUTED a000a4f8: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED switch ( clock_id ) { a000a4fc: e2400001 sub r0, r0, #1 <== NOT EXECUTED a000a500: e3500002 cmp r0, #2 <== NOT EXECUTED a000a504: 8a000008 bhi a000a52c <== NOT EXECUTED case CLOCK_REALTIME: case CLOCK_PROCESS_CPUTIME_ID: case CLOCK_THREAD_CPUTIME_ID: if ( res ) { res->tv_sec = rtems_configuration_get_microseconds_per_tick() / a000a508: e59f5030 ldr r5, [pc, #48] ; a000a540 <== NOT EXECUTED a000a50c: e59f1030 ldr r1, [pc, #48] ; a000a544 <== NOT EXECUTED a000a510: e595000c ldr r0, [r5, #12] <== NOT EXECUTED a000a514: eb004db1 bl a001dbe0 <__aeabi_uidiv> <== NOT EXECUTED TOD_MICROSECONDS_PER_SECOND; res->tv_nsec = rtems_configuration_get_nanoseconds_per_tick(); a000a518: e5953010 ldr r3, [r5, #16] <== NOT EXECUTED case CLOCK_REALTIME: case CLOCK_PROCESS_CPUTIME_ID: case CLOCK_THREAD_CPUTIME_ID: if ( res ) { res->tv_sec = rtems_configuration_get_microseconds_per_tick() / a000a51c: e5840000 str r0, [r4] <== NOT EXECUTED default: rtems_set_errno_and_return_minus_one( EINVAL ); } return 0; a000a520: e3a00000 mov r0, #0 <== NOT EXECUTED case CLOCK_PROCESS_CPUTIME_ID: case CLOCK_THREAD_CPUTIME_ID: if ( res ) { res->tv_sec = rtems_configuration_get_microseconds_per_tick() / TOD_MICROSECONDS_PER_SECOND; res->tv_nsec = rtems_configuration_get_nanoseconds_per_tick(); a000a524: e5843004 str r3, [r4, #4] <== NOT EXECUTED a000a528: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED } break; default: rtems_set_errno_and_return_minus_one( EINVAL ); a000a52c: eb0020a8 bl a00127d4 <__errno> <== NOT EXECUTED a000a530: e3a03016 mov r3, #22 <== NOT EXECUTED a000a534: e5803000 str r3, [r0] <== NOT EXECUTED a000a538: e3e00000 mvn r0, #0 <== NOT EXECUTED } return 0; } a000a53c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a0009ea0 : int clock_gettime( clockid_t clock_id, struct timespec *tp ) { a0009ea0: e92d40d3 push {r0, r1, r4, r6, r7, lr} if ( !tp ) a0009ea4: e2514000 subs r4, r1, #0 a0009ea8: 0a00001f beq a0009f2c rtems_set_errno_and_return_minus_one( EINVAL ); if ( clock_id == CLOCK_REALTIME ) { a0009eac: e3500001 cmp r0, #1 a0009eb0: 1a000010 bne a0009ef8 ) { Timestamp_Control tod_as_timestamp; Timestamp_Control *tod_as_timestamp_ptr; tod_as_timestamp_ptr = a0009eb4: e59f1084 ldr r1, [pc, #132] ; a0009f40 a0009eb8: e1a0000d mov r0, sp a0009ebc: eb00079e bl a000bd3c <_TOD_Get_with_nanoseconds> static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0009ec0: e59f207c ldr r2, [pc, #124] ; a0009f44 #endif rtems_set_errno_and_return_minus_one( EINVAL ); return 0; } a0009ec4: e89000c0 ldm r0, {r6, r7} a0009ec8: e3a03000 mov r3, #0 a0009ecc: e1a00006 mov r0, r6 a0009ed0: e1a01007 mov r1, r7 a0009ed4: eb005341 bl a001ebe0 <__divdi3> _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a0009ed8: e1a01007 mov r1, r7 static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0009edc: e5840000 str r0, [r4] _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a0009ee0: e59f205c ldr r2, [pc, #92] ; a0009f44 a0009ee4: e1a00006 mov r0, r6 a0009ee8: e3a03000 mov r3, #0 a0009eec: eb005476 bl a001f0cc <__moddi3> a0009ef0: e5840004 str r0, [r4, #4] a0009ef4: ea000005 b a0009f10 if ( clock_id == CLOCK_REALTIME ) { _TOD_Get(tp); return 0; } #ifdef CLOCK_MONOTONIC if ( clock_id == CLOCK_MONOTONIC ) { a0009ef8: e3500004 cmp r0, #4 a0009efc: 0a000001 beq a0009f08 return 0; } #endif #ifdef _POSIX_CPUTIME if ( clock_id == CLOCK_PROCESS_CPUTIME_ID ) { a0009f00: e3500002 cmp r0, #2 a0009f04: 1a000003 bne a0009f18 _TOD_Get_uptime_as_timespec( tp ); a0009f08: e1a00004 mov r0, r4 <== NOT EXECUTED a0009f0c: eb00079b bl a000bd80 <_TOD_Get_uptime_as_timespec> <== NOT EXECUTED return 0; a0009f10: e3a00000 mov r0, #0 a0009f14: ea000008 b a0009f3c } #endif #ifdef _POSIX_THREAD_CPUTIME if ( clock_id == CLOCK_THREAD_CPUTIME_ID ) a0009f18: e3500003 cmp r0, #3 a0009f1c: 1a000002 bne a0009f2c rtems_set_errno_and_return_minus_one( ENOSYS ); a0009f20: eb002295 bl a001297c <__errno> <== NOT EXECUTED a0009f24: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009f28: ea000001 b a0009f34 <== NOT EXECUTED #endif rtems_set_errno_and_return_minus_one( EINVAL ); a0009f2c: eb002292 bl a001297c <__errno> a0009f30: e3a03016 mov r3, #22 a0009f34: e5803000 str r3, [r0] a0009f38: e3e00000 mvn r0, #0 return 0; } a0009f3c: e8bd80dc pop {r2, r3, r4, r6, r7, pc} =============================================================================== a0026340 : int clock_settime( clockid_t clock_id, const struct timespec *tp ) { a0026340: e92d4003 push {r0, r1, lr} if ( !tp ) a0026344: e3510000 cmp r1, #0 a0026348: 0a00001c beq a00263c0 rtems_set_errno_and_return_minus_one( EINVAL ); if ( clock_id == CLOCK_REALTIME ) { a002634c: e3500001 cmp r0, #1 a0026350: 1a000013 bne a00263a4 if ( tp->tv_sec < TOD_SECONDS_1970_THROUGH_1988 ) a0026354: e5912000 ldr r2, [r1] a0026358: e59f3074 ldr r3, [pc, #116] ; a00263d4 a002635c: e1520003 cmp r2, r3 a0026360: 9a000016 bls a00263c0 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0026364: e59f306c ldr r3, [pc, #108] ; a00263d8 a0026368: e5932000 ldr r2, [r3] ++level; a002636c: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a0026370: e5832000 str r2, [r3] const struct timespec *tod_as_timespec ) { Timestamp_Control tod_as_timestamp; _Timestamp_Set( a0026374: e8910003 ldm r1, {r0, r1} a0026378: e1a02001 mov r2, r1 a002637c: e1a03fc1 asr r3, r1, #31 Timestamp64_Control *_time, Timestamp64_Control _seconds, Timestamp64_Control _nanoseconds ) { *_time = _seconds * 1000000000L + _nanoseconds; a0026380: e59f1054 ldr r1, [pc, #84] ; a00263dc a0026384: e0e32091 smlal r2, r3, r1, r0 a0026388: e28d0008 add r0, sp, #8 a002638c: e920000c stmdb r0!, {r2, r3} &tod_as_timestamp, tod_as_timespec->tv_sec, tod_as_timespec->tv_nsec ); _TOD_Set_with_timestamp( &tod_as_timestamp ); a0026390: e1a0000d mov r0, sp a0026394: eb0003d7 bl a00272f8 <_TOD_Set_with_timestamp> rtems_set_errno_and_return_minus_one( EINVAL ); _Thread_Disable_dispatch(); _TOD_Set( tp ); _Thread_Enable_dispatch(); a0026398: ebff9b05 bl a000cfb4 <_Thread_Enable_dispatch> rtems_set_errno_and_return_minus_one( ENOSYS ); #endif else rtems_set_errno_and_return_minus_one( EINVAL ); return 0; a002639c: e3a00000 mov r0, #0 a00263a0: ea00000a b a00263d0 _Thread_Disable_dispatch(); _TOD_Set( tp ); _Thread_Enable_dispatch(); } #ifdef _POSIX_CPUTIME else if ( clock_id == CLOCK_PROCESS_CPUTIME_ID ) a00263a4: e3500002 cmp r0, #2 a00263a8: 0a000001 beq a00263b4 rtems_set_errno_and_return_minus_one( ENOSYS ); #endif #ifdef _POSIX_THREAD_CPUTIME else if ( clock_id == CLOCK_THREAD_CPUTIME_ID ) a00263ac: e3500003 cmp r0, #3 a00263b0: 1a000002 bne a00263c0 rtems_set_errno_and_return_minus_one( ENOSYS ); a00263b4: eb003e8a bl a0035de4 <__errno> <== NOT EXECUTED a00263b8: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a00263bc: ea000001 b a00263c8 <== NOT EXECUTED #endif else rtems_set_errno_and_return_minus_one( EINVAL ); a00263c0: eb003e87 bl a0035de4 <__errno> a00263c4: e3a03016 mov r3, #22 a00263c8: e5803000 str r3, [r0] a00263cc: e3e00000 mvn r0, #0 return 0; } a00263d0: e8bd800c pop {r2, r3, pc} =============================================================================== a0009d18 : #include #include int fork( void ) { a0009d18: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009d1c: eb0020a7 bl a0011fc0 <__errno> <== NOT EXECUTED a0009d20: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009d24: e5803000 str r3, [r0] <== NOT EXECUTED } a0009d28: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009d2c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a001cba4 : int killinfo( pid_t pid, int sig, const union sigval *value ) { a001cba4: e92d47f7 push {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, lr} a001cba8: e1a05000 mov r5, r0 a001cbac: e1a04001 mov r4, r1 a001cbb0: e1a06002 mov r6, r2 POSIX_signals_Siginfo_node *psiginfo; /* * Only supported for the "calling process" (i.e. this node). */ if ( pid != getpid() ) a001cbb4: ebffff80 bl a001c9bc a001cbb8: e1550000 cmp r5, r0 a001cbbc: 0a000002 beq a001cbcc rtems_set_errno_and_return_minus_one( ESRCH ); a001cbc0: ebffd355 bl a001191c <__errno> <== NOT EXECUTED a001cbc4: e3a03003 mov r3, #3 <== NOT EXECUTED a001cbc8: ea00007d b a001cdc4 <== NOT EXECUTED /* * Validate the signal passed. */ if ( !sig ) a001cbcc: e3540000 cmp r4, #0 a001cbd0: 0a000002 beq a001cbe0 static inline bool is_valid_signo( int signo ) { return ((signo) >= 1 && (signo) <= 32 ); a001cbd4: e2445001 sub r5, r4, #1 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !is_valid_signo(sig) ) a001cbd8: e355001f cmp r5, #31 a001cbdc: 9a000002 bls a001cbec rtems_set_errno_and_return_minus_one( EINVAL ); a001cbe0: ebffd34d bl a001191c <__errno> <== NOT EXECUTED a001cbe4: e3a03016 mov r3, #22 <== NOT EXECUTED a001cbe8: ea000075 b a001cdc4 <== NOT EXECUTED /* * If the signal is being ignored, then we are out of here. */ if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN ) a001cbec: e59f3210 ldr r3, [pc, #528] ; a001ce04 a001cbf0: e3a0200c mov r2, #12 a001cbf4: e0233492 mla r3, r2, r4, r3 a001cbf8: e5933008 ldr r3, [r3, #8] a001cbfc: e3530001 cmp r3, #1 a001cc00: 0a00007d beq a001cdfc /* * 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 ) ) a001cc04: e3540008 cmp r4, #8 a001cc08: 13540004 cmpne r4, #4 a001cc0c: 0a000001 beq a001cc18 a001cc10: e354000b cmp r4, #11 a001cc14: 1a000003 bne a001cc28 return pthread_kill( pthread_self(), sig ); a001cc18: eb00010d bl a001d054 <== NOT EXECUTED a001cc1c: e1a01004 mov r1, r4 <== NOT EXECUTED a001cc20: eb0000d6 bl a001cf80 <== NOT EXECUTED a001cc24: ea000075 b a001ce00 <== NOT EXECUTED static inline sigset_t signo_to_mask( uint32_t sig ) { return 1u << (sig - 1); a001cc28: e3a03001 mov r3, #1 * Build up a siginfo structure */ siginfo = &siginfo_struct; siginfo->si_signo = sig; siginfo->si_code = SI_USER; if ( !value ) { a001cc2c: e3560000 cmp r6, #0 /* * Build up a siginfo structure */ siginfo = &siginfo_struct; siginfo->si_signo = sig; siginfo->si_code = SI_USER; a001cc30: e58d3004 str r3, [sp, #4] a001cc34: e1a05513 lsl r5, r3, r5 if ( !value ) { siginfo->si_value.sival_int = 0; } else { siginfo->si_value = *value; a001cc38: 15963000 ldrne r3, [r6] /* * Build up a siginfo structure */ siginfo = &siginfo_struct; siginfo->si_signo = sig; a001cc3c: e58d4000 str r4, [sp] siginfo->si_code = SI_USER; if ( !value ) { siginfo->si_value.sival_int = 0; a001cc40: 058d6008 streq r6, [sp, #8] } else { siginfo->si_value = *value; a001cc44: 158d3008 strne r3, [sp, #8] * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a001cc48: e59f31b8 ldr r3, [pc, #440] ; a001ce08 a001cc4c: e5932000 ldr r2, [r3] ++level; a001cc50: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a001cc54: e5832000 str r2, [r3] */ void _POSIX_signals_Manager_Initialization(void); static inline void _POSIX_signals_Add_post_switch_extension(void) { _API_extensions_Add_post_switch( &_POSIX_signals_Post_switch ); a001cc58: e59f01ac ldr r0, [pc, #428] ; a001ce0c a001cc5c: ebffb75e bl a000a9dc <_API_extensions_Add_post_switch> /* * 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; a001cc60: e59f31a8 ldr r3, [pc, #424] ; a001ce10 a001cc64: e5930008 ldr r0, [r3, #8] api = the_thread->API_Extensions[ THREAD_API_POSIX ]; if ( _POSIX_signals_Is_interested( api, mask ) ) { a001cc68: e59030f4 ldr r3, [r0, #244] ; 0xf4 a001cc6c: e59330d0 ldr r3, [r3, #208] ; 0xd0 a001cc70: e1d53003 bics r3, r5, r3 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a001cc74: 059f3198 ldreq r3, [pc, #408] ; a001ce14 a001cc78: 04930004 ldreq r0, [r3], #4 a001cc7c: 0a000008 beq a001cca4 a001cc80: ea00003b b a001cd74 <== NOT EXECUTED #endif /* * Is this thread is actually blocked waiting for the signal? */ if (the_thread->Wait.option & mask) a001cc84: e5901030 ldr r1, [r0, #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; api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a001cc88: e59020f4 ldr r2, [r0, #244] ; 0xf4 <== NOT EXECUTED #endif /* * Is this thread is actually blocked waiting for the signal? */ if (the_thread->Wait.option & mask) a001cc8c: e1150001 tst r5, r1 <== NOT EXECUTED a001cc90: 1a000037 bne a001cd74 <== NOT EXECUTED /* * Is this thread is blocked waiting for another signal but has * not blocked this one? */ if (~api->signals_blocked & mask) a001cc94: e59220d0 ldr r2, [r2, #208] ; 0xd0 <== NOT EXECUTED a001cc98: e1d52002 bics r2, r5, r2 <== NOT EXECUTED a001cc9c: 1a000034 bne a001cd74 <== 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 ) { a001cca0: e5900000 ldr r0, [r0] <== 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 ); a001cca4: e1500003 cmp r0, r3 a001cca8: 1afffff5 bne a001cc84 * NOTES: * * + rtems internal threads do not receive signals. */ interested = NULL; interested_priority = PRIORITY_MAXIMUM + 1; a001ccac: e59f3164 ldr r3, [pc, #356] ; a001ce18 a001ccb0: e59fc164 ldr ip, [pc, #356] ; a001ce1c * * NOTES: * * + rtems internal threads do not receive signals. */ interested = NULL; a001ccb4: e3a00000 mov r0, #0 interested_priority = PRIORITY_MAXIMUM + 1; a001ccb8: e5d32000 ldrb r2, [r3] */ #define _POSIX_signals_Is_interested( _api, _mask ) \ ( ~(_api)->signals_blocked & (_mask) ) int killinfo( a001ccbc: e28ca008 add sl, ip, #8 * NOTES: * * + rtems internal threads do not receive signals. */ interested = NULL; interested_priority = PRIORITY_MAXIMUM + 1; a001ccc0: 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 ] ) a001ccc4: e5bc3004 ldr r3, [ip, #4]! a001ccc8: e3530000 cmp r3, #0 a001cccc: 0a000024 beq a001cd64 continue; the_info = _Objects_Information_table[ the_api ][ 1 ]; a001ccd0: e5933004 ldr r3, [r3, #4] #endif maximum = the_info->maximum; object_table = the_info->local_table; for ( index = 1 ; index <= maximum ; index++ ) { a001ccd4: e3a0e001 mov lr, #1 */ if ( !the_info ) continue; #endif maximum = the_info->maximum; a001ccd8: e1d391b0 ldrh r9, [r3, #16] a001ccdc: e593601c ldr r6, [r3, #28] object_table = the_info->local_table; for ( index = 1 ; index <= maximum ; index++ ) { a001cce0: ea00001d b a001cd5c the_thread = (Thread_Control *) object_table[ index ]; a001cce4: e5b63004 ldr r3, [r6, #4]! if ( !the_thread ) a001cce8: e3530000 cmp r3, #0 a001ccec: 0a000019 beq a001cd58 /* * If this thread is of lower priority than the interested thread, * go on to the next thread. */ if ( the_thread->current_priority > interested_priority ) a001ccf0: e5931014 ldr r1, [r3, #20] a001ccf4: e1510002 cmp r1, r2 a001ccf8: 8a000016 bhi a001cd58 #if defined(RTEMS_DEBUG) if ( !api ) continue; #endif if ( !_POSIX_signals_Is_interested( api, mask ) ) a001ccfc: e59370f4 ldr r7, [r3, #244] ; 0xf4 a001cd00: e59770d0 ldr r7, [r7, #208] ; 0xd0 a001cd04: e1d57007 bics r7, r5, r7 a001cd08: 0a000012 beq a001cd58 * * 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 ) { a001cd0c: e1510002 cmp r1, r2 <== NOT EXECUTED a001cd10: 3a00000e bcc a001cd50 <== 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 ) ) { a001cd14: e3500000 cmp r0, #0 <== NOT EXECUTED a001cd18: 0a00000e beq a001cd58 <== NOT EXECUTED a001cd1c: e5908010 ldr r8, [r0, #16] <== NOT EXECUTED a001cd20: e3580000 cmp r8, #0 <== NOT EXECUTED a001cd24: 0a00000b beq a001cd58 <== NOT EXECUTED /* preferred ready over blocked */ DEBUG_STEP("5"); if ( _States_Is_ready( the_thread->current_state ) ) { a001cd28: e5937010 ldr r7, [r3, #16] <== NOT EXECUTED a001cd2c: e3570000 cmp r7, #0 <== NOT EXECUTED a001cd30: 0a000006 beq a001cd50 <== NOT EXECUTED continue; } DEBUG_STEP("6"); /* prefer blocked/interruptible over blocked/not interruptible */ if ( !_States_Is_interruptible_by_signal(interested->current_state) ) { a001cd34: e3180201 tst r8, #268435456 ; 0x10000000 <== NOT EXECUTED a001cd38: 1a000006 bne a001cd58 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE bool _States_Is_interruptible_by_signal ( States_Control the_states ) { return (the_states & STATES_INTERRUPTIBLE_BY_SIGNAL); a001cd3c: e2077201 and r7, r7, #268435456 ; 0x10000000 <== NOT EXECUTED DEBUG_STEP("7"); if ( _States_Is_interruptible_by_signal(the_thread->current_state) ) { a001cd40: e3570000 cmp r7, #0 <== NOT EXECUTED a001cd44: 11a02001 movne r2, r1 <== NOT EXECUTED a001cd48: 11a00003 movne r0, r3 <== NOT EXECUTED a001cd4c: ea000001 b a001cd58 <== 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 ) ) { a001cd50: e1a02001 mov r2, r1 <== NOT EXECUTED a001cd54: e1a00003 mov r0, r3 <== NOT EXECUTED #endif maximum = the_info->maximum; object_table = the_info->local_table; for ( index = 1 ; index <= maximum ; index++ ) { a001cd58: e28ee001 add lr, lr, #1 a001cd5c: e15e0009 cmp lr, r9 a001cd60: 9affffdf bls a001cce4 * + 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++) { a001cd64: e15c000a cmp ip, sl a001cd68: 1affffd5 bne a001ccc4 } } } } if ( interested ) { a001cd6c: e3500000 cmp r0, #0 a001cd70: 0a000004 beq a001cd88 /* * 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 ) ) { a001cd74: e1a01004 mov r1, r4 <== NOT EXECUTED a001cd78: e1a0200d mov r2, sp <== NOT EXECUTED a001cd7c: eb000033 bl a001ce50 <_POSIX_signals_Unblock_thread> <== NOT EXECUTED a001cd80: e3500000 cmp r0, #0 <== NOT EXECUTED a001cd84: 1a00001b bne a001cdf8 <== 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 ); a001cd88: e1a00005 mov r0, r5 a001cd8c: eb000025 bl a001ce28 <_POSIX_signals_Set_process_signals> if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) { a001cd90: e3a0300c mov r3, #12 a001cd94: e0040493 mul r4, r3, r4 a001cd98: e59f3064 ldr r3, [pc, #100] ; a001ce04 a001cd9c: e7933004 ldr r3, [r3, r4] a001cda0: e3530002 cmp r3, #2 a001cda4: 1a000013 bne a001cdf8 psiginfo = (POSIX_signals_Siginfo_node *) a001cda8: e59f0070 ldr r0, [pc, #112] ; a001ce20 <== NOT EXECUTED a001cdac: ebffb76d bl a000ab68 <_Chain_Get> <== NOT EXECUTED _Chain_Get( &_POSIX_signals_Inactive_siginfo ); if ( !psiginfo ) { a001cdb0: e2501000 subs r1, r0, #0 <== NOT EXECUTED a001cdb4: 1a000005 bne a001cdd0 <== NOT EXECUTED _Thread_Enable_dispatch(); a001cdb8: ebffbe88 bl a000c7e0 <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EAGAIN ); a001cdbc: ebffd2d6 bl a001191c <__errno> <== NOT EXECUTED a001cdc0: e3a0300b mov r3, #11 <== NOT EXECUTED a001cdc4: e5803000 str r3, [r0] <== NOT EXECUTED a001cdc8: e3e00000 mvn r0, #0 <== NOT EXECUTED a001cdcc: ea00000b b a001ce00 <== NOT EXECUTED } psiginfo->Info = *siginfo; a001cdd0: e59d3000 ldr r3, [sp] <== NOT EXECUTED _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); a001cdd4: e59f0048 ldr r0, [pc, #72] ; a001ce24 <== NOT EXECUTED if ( !psiginfo ) { _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( EAGAIN ); } psiginfo->Info = *siginfo; a001cdd8: e5813008 str r3, [r1, #8] <== NOT EXECUTED a001cddc: e28d3004 add r3, sp, #4 <== NOT EXECUTED a001cde0: e4932004 ldr r2, [r3], #4 <== NOT EXECUTED _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); a001cde4: e0800004 add r0, r0, r4 <== NOT EXECUTED if ( !psiginfo ) { _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( EAGAIN ); } psiginfo->Info = *siginfo; a001cde8: e5933000 ldr r3, [r3] <== NOT EXECUTED a001cdec: e581200c str r2, [r1, #12] <== NOT EXECUTED a001cdf0: e5813010 str r3, [r1, #16] <== NOT EXECUTED _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); a001cdf4: ebffb750 bl a000ab3c <_Chain_Append> <== NOT EXECUTED } DEBUG_STEP("\n"); _Thread_Enable_dispatch(); a001cdf8: ebffbe78 bl a000c7e0 <_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; a001cdfc: e3a00000 mov r0, #0 } DEBUG_STEP("\n"); _Thread_Enable_dispatch(); return 0; } a001ce00: e8bd87fe pop {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== a0009d48 : const void *addr __attribute__((unused)), size_t len __attribute__((unused)), int prot __attribute__((unused)) ) { return 0; } a0009d48: e3a00000 mov r0, #0 <== NOT EXECUTED a0009d4c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000ee08 : */ int mq_close( mqd_t mqdes ) { a000ee08: e92d4031 push {r0, r4, r5, lr} a000ee0c: 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( a000ee10: e1a0200d mov r2, sp a000ee14: e59f005c ldr r0, [pc, #92] ; a000ee78 a000ee18: eb000d3a bl a0012308 <_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 ) { a000ee1c: e59d5000 ldr r5, [sp] a000ee20: e1a04000 mov r4, r0 a000ee24: e3550000 cmp r5, #0 a000ee28: 1a00000d bne a000ee64 * 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; a000ee2c: e5900010 ldr r0, [r0, #16] the_mq->open_count -= 1; a000ee30: e5903018 ldr r3, [r0, #24] a000ee34: e2433001 sub r3, r3, #1 a000ee38: e5803018 str r3, [r0, #24] _POSIX_Message_queue_Delete( the_mq ); a000ee3c: eb00000e bl a000ee7c <_POSIX_Message_queue_Delete> /* * Now close this file descriptor. */ _Objects_Close( a000ee40: e59f0030 ldr r0, [pc, #48] ; a000ee78 a000ee44: e1a01004 mov r1, r4 a000ee48: eb000c29 bl a0011ef4 <_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 ); a000ee4c: e59f0024 ldr r0, [pc, #36] ; a000ee78 a000ee50: e1a01004 mov r1, r4 a000ee54: eb000cd3 bl a00121a8 <_Objects_Free> &_POSIX_Message_queue_Information_fds, &the_mq_fd->Object ); _POSIX_Message_queue_Free_fd( the_mq_fd ); _Thread_Enable_dispatch(); a000ee58: eb0010bd bl a0013154 <_Thread_Enable_dispatch> return 0; a000ee5c: e1a00005 mov r0, r5 a000ee60: ea000003 b a000ee74 /* * OBJECTS_REMOTE: * OBJECTS_ERROR: */ rtems_set_errno_and_return_minus_one( EBADF ); a000ee64: eb0026cd bl a00189a0 <__errno> <== NOT EXECUTED a000ee68: e3a03009 mov r3, #9 <== NOT EXECUTED a000ee6c: e5803000 str r3, [r0] <== NOT EXECUTED a000ee70: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000ee74: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000eed0 : int mq_getattr( mqd_t mqdes, struct mq_attr *mqstat ) { a000eed0: 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; if ( !mqstat ) a000eed4: e2514000 subs r4, r1, #0 <== NOT EXECUTED int mq_getattr( mqd_t mqdes, struct mq_attr *mqstat ) { a000eed8: e1a03000 mov r3, r0 <== NOT EXECUTED POSIX_Message_queue_Control *the_mq; POSIX_Message_queue_Control_fd *the_mq_fd; Objects_Locations location; if ( !mqstat ) a000eedc: 1a000002 bne a000eeec <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EINVAL ); a000eee0: eb0026ae bl a00189a0 <__errno> <== NOT EXECUTED a000eee4: e3a03016 mov r3, #22 <== NOT EXECUTED a000eee8: ea000014 b a000ef40 <== 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( a000eeec: e59f0058 ldr r0, [pc, #88] ; a000ef4c <== NOT EXECUTED a000eef0: e1a01003 mov r1, r3 <== NOT EXECUTED a000eef4: e1a0200d mov r2, sp <== NOT EXECUTED a000eef8: eb000d02 bl a0012308 <_Objects_Get> <== NOT EXECUTED the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location ); switch ( location ) { a000eefc: e59d5000 ldr r5, [sp] <== NOT EXECUTED a000ef00: e3550000 cmp r5, #0 <== NOT EXECUTED a000ef04: 1a00000b bne a000ef38 <== NOT EXECUTED case OBJECTS_LOCAL: the_mq = the_mq_fd->Queue; a000ef08: e5903010 ldr r3, [r0, #16] <== NOT EXECUTED /* * Return the old values. */ mqstat->mq_flags = the_mq_fd->oflag; a000ef0c: e5902014 ldr r2, [r0, #20] <== NOT EXECUTED a000ef10: e5842000 str r2, [r4] <== NOT EXECUTED mqstat->mq_msgsize = the_mq->Message_queue.maximum_message_size; a000ef14: e5932068 ldr r2, [r3, #104] ; 0x68 <== NOT EXECUTED a000ef18: e5842008 str r2, [r4, #8] <== NOT EXECUTED mqstat->mq_maxmsg = the_mq->Message_queue.maximum_pending_messages; a000ef1c: e5932060 ldr r2, [r3, #96] ; 0x60 <== NOT EXECUTED mqstat->mq_curmsgs = the_mq->Message_queue.number_of_pending_messages; a000ef20: e5933064 ldr r3, [r3, #100] ; 0x64 <== NOT EXECUTED /* * Return the old values. */ 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; a000ef24: e5842004 str r2, [r4, #4] <== NOT EXECUTED mqstat->mq_curmsgs = the_mq->Message_queue.number_of_pending_messages; a000ef28: e584300c str r3, [r4, #12] <== NOT EXECUTED _Thread_Enable_dispatch(); a000ef2c: eb001088 bl a0013154 <_Thread_Enable_dispatch> <== NOT EXECUTED return 0; a000ef30: e1a00005 mov r0, r5 <== NOT EXECUTED a000ef34: ea000003 b a000ef48 <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EBADF ); a000ef38: eb002698 bl a00189a0 <__errno> <== NOT EXECUTED a000ef3c: e3a03009 mov r3, #9 <== NOT EXECUTED a000ef40: e5803000 str r3, [r0] <== NOT EXECUTED a000ef44: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000ef48: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a000ef74 : int mq_notify( mqd_t mqdes, const struct sigevent *notification ) { a000ef74: e92d4011 push {r0, r4, lr} a000ef78: e1a03000 mov r3, r0 a000ef7c: e1a04001 mov r4, r1 a000ef80: e59f0088 ldr r0, [pc, #136] ; a000f010 a000ef84: e1a01003 mov r1, r3 a000ef88: e1a0200d mov r2, sp a000ef8c: eb000cdd bl a0012308 <_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 ); switch ( location ) { a000ef90: e59d3000 ldr r3, [sp] a000ef94: e3530000 cmp r3, #0 a000ef98: 1a000017 bne a000effc case OBJECTS_LOCAL: the_mq = the_mq_fd->Queue; if ( notification ) { a000ef9c: e3540000 cmp r4, #0 the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location ); switch ( location ) { case OBJECTS_LOCAL: the_mq = the_mq_fd->Queue; a000efa0: e590c010 ldr ip, [r0, #16] if ( notification ) { a000efa4: 0a00000f beq a000efe8 if ( _CORE_message_queue_Is_notify_enabled( &the_mq->Message_queue ) ) { a000efa8: e59c307c ldr r3, [ip, #124] ; 0x7c a000efac: e3530000 cmp r3, #0 a000efb0: 0a000003 beq a000efc4 _Thread_Enable_dispatch(); a000efb4: eb001066 bl a0013154 <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EBUSY ); a000efb8: eb002678 bl a00189a0 <__errno> <== NOT EXECUTED a000efbc: e3a03010 mov r3, #16 <== NOT EXECUTED a000efc0: ea00000f b a000f004 <== NOT EXECUTED } _CORE_message_queue_Set_notify( &the_mq->Message_queue, NULL, NULL ); the_mq->notification = *notification; a000efc4: e28ce090 add lr, ip, #144 ; 0x90 a000efc8: e8b4000f ldm r4!, {r0, r1, r2, r3} a000efcc: e8ae000f stmia lr!, {r0, r1, r2, r3} a000efd0: e5943000 ldr r3, [r4] a000efd4: e58e3000 str r3, [lr] CORE_message_queue_Control *the_message_queue, CORE_message_queue_Notify_Handler the_handler, void *the_argument ) { the_message_queue->notify_handler = the_handler; a000efd8: e59f3034 ldr r3, [pc, #52] ; a000f014 the_message_queue->notify_argument = the_argument; a000efdc: e58cc080 str ip, [ip, #128] ; 0x80 CORE_message_queue_Control *the_message_queue, CORE_message_queue_Notify_Handler the_handler, void *the_argument ) { the_message_queue->notify_handler = the_handler; a000efe0: e58c307c str r3, [ip, #124] ; 0x7c a000efe4: ea000001 b a000eff0 a000efe8: e58c407c str r4, [ip, #124] ; 0x7c <== NOT EXECUTED the_message_queue->notify_argument = the_argument; a000efec: e58c4080 str r4, [ip, #128] ; 0x80 <== NOT EXECUTED _CORE_message_queue_Set_notify( &the_mq->Message_queue, NULL, NULL ); } _Thread_Enable_dispatch(); a000eff0: eb001057 bl a0013154 <_Thread_Enable_dispatch> return 0; a000eff4: e3a00000 mov r0, #0 a000eff8: ea000003 b a000f00c #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EBADF ); a000effc: eb002667 bl a00189a0 <__errno> <== NOT EXECUTED a000f000: e3a03009 mov r3, #9 <== NOT EXECUTED a000f004: e5803000 str r3, [r0] <== NOT EXECUTED a000f008: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000f00c: e8bd8018 pop {r3, r4, pc} =============================================================================== a000a3d4 : int oflag, ... /* mode_t mode, */ /* struct mq_attr attr */ ) { a000a3d4: e92d000e push {r1, r2, r3} * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000a3d8: e59f317c ldr r3, [pc, #380] ; a000a55c a000a3dc: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} a000a3e0: e5932000 ldr r2, [r3] a000a3e4: e24dd018 sub sp, sp, #24 a000a3e8: e59d6038 ldr r6, [sp, #56] ; 0x38 ++level; a000a3ec: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000a3f0: e5832000 str r2, [r3] a000a3f4: e1a08000 mov r8, r0 */ RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd * _POSIX_Message_queue_Allocate_fd( void ) { return (POSIX_Message_queue_Control_fd *) a000a3f8: e59f5160 ldr r5, [pc, #352] ; a000a560 Objects_Locations location; size_t name_len; _Thread_Disable_dispatch(); if ( oflag & O_CREAT ) { a000a3fc: e2167c02 ands r7, r6, #512 ; 0x200 va_start(arg, oflag); mode = va_arg( arg, mode_t ); attr = va_arg( arg, struct mq_attr * ); a000a400: 128d3044 addne r3, sp, #68 ; 0x44 a000a404: e1a00005 mov r0, r5 a000a408: 158d3004 strne r3, [sp, #4] a000a40c: 159d9040 ldrne r9, [sp, #64] ; 0x40 /* struct mq_attr attr */ ) { va_list arg; mode_t mode; struct mq_attr *attr = NULL; a000a410: 01a09007 moveq r9, r7 a000a414: eb000b09 bl a000d040 <_Objects_Allocate> attr = va_arg( arg, struct mq_attr * ); va_end(arg); } the_mq_fd = _POSIX_Message_queue_Allocate_fd(); if ( !the_mq_fd ) { a000a418: e2504000 subs r4, r0, #0 a000a41c: 1a000003 bne a000a430 _Thread_Enable_dispatch(); a000a420: eb000fd5 bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENFILE ); a000a424: eb0024b7 bl a0013708 <__errno> <== NOT EXECUTED a000a428: e3a03017 mov r3, #23 <== NOT EXECUTED a000a42c: ea00001c b a000a4a4 <== NOT EXECUTED } the_mq_fd->oflag = oflag; a000a430: e5846014 str r6, [r4, #20] const char *name, Objects_Id *id, size_t *len ) { return _POSIX_Name_to_id( &_POSIX_Message_queue_Information, name, id, len ); a000a434: e59f0128 ldr r0, [pc, #296] ; a000a564 a000a438: e1a01008 mov r1, r8 a000a43c: e28d2008 add r2, sp, #8 a000a440: e28d3014 add r3, sp, #20 a000a444: eb000118 bl a000a8ac <_POSIX_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 ) { a000a448: e250a000 subs sl, r0, #0 a000a44c: 0a00000b beq a000a480 /* * 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) ) ) { a000a450: e35a0002 cmp sl, #2 a000a454: 1a000001 bne a000a460 a000a458: e3570000 cmp r7, #0 a000a45c: 1a000021 bne a000a4e8 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 ); a000a460: e59f00f8 ldr r0, [pc, #248] ; a000a560 a000a464: e1a01004 mov r1, r4 a000a468: eb000bc3 bl a000d37c <_Objects_Free> _POSIX_Message_queue_Free_fd( the_mq_fd ); _Thread_Enable_dispatch(); a000a46c: eb000fc2 bl a000e37c <_Thread_Enable_dispatch> rtems_set_errno_and_return_minus_one_cast( status, mqd_t ); a000a470: eb0024a4 bl a0013708 <__errno> a000a474: e580a000 str sl, [r0] a000a478: e3e00000 mvn r0, #0 a000a47c: ea000032 b a000a54c } else { /* name -> ID translation succeeded */ /* * Check for existence with creation. */ if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) { a000a480: e2066c0a and r6, r6, #2560 ; 0xa00 a000a484: e3560c0a cmp r6, #2560 ; 0xa00 a000a488: 1a000007 bne a000a4ac a000a48c: e1a00005 mov r0, r5 <== NOT EXECUTED a000a490: e1a01004 mov r1, r4 <== NOT EXECUTED a000a494: eb000bb8 bl a000d37c <_Objects_Free> <== NOT EXECUTED _POSIX_Message_queue_Free_fd( the_mq_fd ); _Thread_Enable_dispatch(); a000a498: eb000fb7 bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one_cast( EEXIST, mqd_t ); a000a49c: eb002499 bl a0013708 <__errno> <== NOT EXECUTED a000a4a0: e3a03011 mov r3, #17 <== NOT EXECUTED a000a4a4: e5803000 str r3, [r0] <== NOT EXECUTED a000a4a8: eafffff2 b a000a478 <== NOT EXECUTED RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control *_POSIX_Message_queue_Get ( Objects_Id id, Objects_Locations *location ) { return (POSIX_Message_queue_Control *) a000a4ac: e28d2010 add r2, sp, #16 a000a4b0: e59d1008 ldr r1, [sp, #8] a000a4b4: e59f00a8 ldr r0, [pc, #168] ; a000a564 a000a4b8: eb000c07 bl a000d4dc <_Objects_Get> /* * 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; a000a4bc: e5903018 ldr r3, [r0, #24] Objects_Information *information, Objects_Control *the_object, const char *name ) { _Objects_Set_local_object( a000a4c0: e1d420b8 ldrh r2, [r4, #8] /* * 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 ); a000a4c4: e58d000c str r0, [sp, #12] the_mq->open_count += 1; a000a4c8: e2833001 add r3, r3, #1 a000a4cc: e5803018 str r3, [r0, #24] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a4d0: e595301c ldr r3, [r5, #28] the_mq_fd->Queue = the_mq; a000a4d4: e5840010 str r0, [r4, #16] a000a4d8: 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; a000a4dc: e584a00c str sl, [r4, #12] _Objects_Open_string( &_POSIX_Message_queue_Information_fds, &the_mq_fd->Object, NULL ); _Thread_Enable_dispatch(); a000a4e0: eb000fa5 bl a000e37c <_Thread_Enable_dispatch> a000a4e4: ea000016 b a000a544 /* * 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( a000a4e8: e28d300c add r3, sp, #12 a000a4ec: e58d3000 str r3, [sp] a000a4f0: e1a00008 mov r0, r8 a000a4f4: e59d1014 ldr r1, [sp, #20] a000a4f8: e3a02001 mov r2, #1 a000a4fc: e1a03009 mov r3, r9 a000a500: eb001924 bl a0010998 <_POSIX_Message_queue_Create_support> ); /* * errno was set by Create_support, so don't set it again. */ if ( status == -1 ) { a000a504: 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( a000a508: e1a06000 mov r6, r0 ); /* * errno was set by Create_support, so don't set it again. */ if ( status == -1 ) { a000a50c: 1a000005 bne a000a528 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 ); a000a510: e1a00005 mov r0, r5 a000a514: e1a01004 mov r1, r4 a000a518: eb000b97 bl a000d37c <_Objects_Free> _POSIX_Message_queue_Free_fd( the_mq_fd ); _Thread_Enable_dispatch(); a000a51c: eb000f96 bl a000e37c <_Thread_Enable_dispatch> return (mqd_t) -1; a000a520: e1a00006 mov r0, r6 a000a524: ea000008 b a000a54c } the_mq_fd->Queue = the_mq; a000a528: e59d300c ldr r3, [sp, #12] Objects_Information *information, Objects_Control *the_object, const char *name ) { _Objects_Set_local_object( a000a52c: e1d420b8 ldrh r2, [r4, #8] a000a530: e5843010 str r3, [r4, #16] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a534: e595301c ldr r3, [r5, #28] a000a538: 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; a000a53c: e3a03000 mov r3, #0 a000a540: e584300c str r3, [r4, #12] &_POSIX_Message_queue_Information_fds, &the_mq_fd->Object, NULL ); _Thread_Enable_dispatch(); a000a544: eb000f8c bl a000e37c <_Thread_Enable_dispatch> return (mqd_t) the_mq_fd->Object.id; a000a548: e5940008 ldr r0, [r4, #8] } a000a54c: e28dd018 add sp, sp, #24 a000a550: e8bd47f0 pop {r4, r5, r6, r7, r8, r9, sl, lr} a000a554: e28dd00c add sp, sp, #12 a000a558: e12fff1e bx lr =============================================================================== a000f3fc : int mq_setattr( mqd_t mqdes, const struct mq_attr *mqstat, struct mq_attr *omqstat ) { a000f3fc: 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 ) a000f400: e2515000 subs r5, r1, #0 <== NOT EXECUTED int mq_setattr( mqd_t mqdes, const struct mq_attr *mqstat, struct mq_attr *omqstat ) { a000f404: e1a03000 mov r3, r0 <== NOT EXECUTED a000f408: 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 ) a000f40c: 1a000002 bne a000f41c <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EINVAL ); a000f410: eb002562 bl a00189a0 <__errno> <== NOT EXECUTED a000f414: e3a03016 mov r3, #22 <== NOT EXECUTED a000f418: ea000018 b a000f480 <== 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( a000f41c: e1a01003 mov r1, r3 <== NOT EXECUTED a000f420: e59f0064 ldr r0, [pc, #100] ; a000f48c <== NOT EXECUTED a000f424: e1a0200d mov r2, sp <== NOT EXECUTED a000f428: eb000bb6 bl a0012308 <_Objects_Get> <== NOT EXECUTED the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location ); switch ( location ) { a000f42c: e59d3000 ldr r3, [sp] <== NOT EXECUTED a000f430: e3530000 cmp r3, #0 <== NOT EXECUTED a000f434: 1a00000f bne a000f478 <== NOT EXECUTED /* * Return the old values. */ if ( omqstat ) { a000f438: 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; a000f43c: e5903010 ldr r3, [r0, #16] <== NOT EXECUTED /* * Return the old values. */ if ( omqstat ) { a000f440: 0a000007 beq a000f464 <== NOT EXECUTED omqstat->mq_flags = the_mq_fd->oflag; a000f444: e5902014 ldr r2, [r0, #20] <== NOT EXECUTED a000f448: e5842000 str r2, [r4] <== NOT EXECUTED omqstat->mq_msgsize = the_core_mq->maximum_message_size; a000f44c: e5932068 ldr r2, [r3, #104] ; 0x68 <== NOT EXECUTED a000f450: e5842008 str r2, [r4, #8] <== NOT EXECUTED omqstat->mq_maxmsg = the_core_mq->maximum_pending_messages; a000f454: e5932060 ldr r2, [r3, #96] ; 0x60 <== NOT EXECUTED omqstat->mq_curmsgs = the_core_mq->number_of_pending_messages; a000f458: 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; a000f45c: e5842004 str r2, [r4, #4] <== NOT EXECUTED omqstat->mq_curmsgs = the_core_mq->number_of_pending_messages; a000f460: e584300c str r3, [r4, #12] <== NOT EXECUTED } the_mq_fd->oflag = mqstat->mq_flags; a000f464: e5953000 ldr r3, [r5] <== NOT EXECUTED a000f468: e5803014 str r3, [r0, #20] <== NOT EXECUTED _Thread_Enable_dispatch(); a000f46c: eb000f38 bl a0013154 <_Thread_Enable_dispatch> <== NOT EXECUTED return 0; a000f470: e3a00000 mov r0, #0 <== NOT EXECUTED a000f474: ea000003 b a000f488 <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EBADF ); a000f478: eb002548 bl a00189a0 <__errno> <== NOT EXECUTED a000f47c: e3a03009 mov r3, #9 <== NOT EXECUTED a000f480: e5803000 str r3, [r0] <== NOT EXECUTED a000f484: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000f488: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a000f540 : * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000f540: e59f3070 ldr r3, [pc, #112] ; a000f5b8 */ int mq_unlink( const char *name ) { a000f544: e92d4073 push {r0, r1, r4, r5, r6, lr} a000f548: e5932000 ldr r2, [r3] a000f54c: e1a01000 mov r1, r0 ++level; a000f550: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000f554: e5832000 str r2, [r3] const char *name, Objects_Id *id, size_t *len ) { return _POSIX_Name_to_id( &_POSIX_Message_queue_Information, name, id, len ); a000f558: e59f405c ldr r4, [pc, #92] ; a000f5bc a000f55c: e1a0200d mov r2, sp a000f560: e28d3004 add r3, sp, #4 a000f564: e1a00004 mov r0, r4 a000f568: eb000041 bl a000f674 <_POSIX_Name_to_id> size_t name_len; _Thread_Disable_dispatch(); status = _POSIX_Message_queue_Name_to_id( name, &the_mq_id, &name_len ); if ( status != 0 ) { a000f56c: e2505000 subs r5, r0, #0 a000f570: 0a000004 beq a000f588 _Thread_Enable_dispatch(); a000f574: eb000ef6 bl a0013154 <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one( status ); a000f578: eb002508 bl a00189a0 <__errno> <== NOT EXECUTED a000f57c: e5805000 str r5, [r0] <== NOT EXECUTED a000f580: e3e00000 mvn r0, #0 <== NOT EXECUTED a000f584: ea00000a b a000f5b4 <== NOT EXECUTED */ #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return NULL; #endif return information->local_table[ index ]; a000f588: e594301c ldr r3, [r4, #28] a000f58c: e1dd20b0 ldrh r2, [sp] RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Namespace_remove ( POSIX_Message_queue_Control *the_mq ) { _Objects_Namespace_remove( a000f590: e1a00004 mov r0, r4 a000f594: e7936102 ldr r6, [r3, r2, lsl #2] a000f598: e1a01006 mov r1, r6 the_mq = (POSIX_Message_queue_Control *) _Objects_Get_local_object( &_POSIX_Message_queue_Information, _Objects_Get_index( the_mq_id ) ); the_mq->linked = false; a000f59c: e5c65015 strb r5, [r6, #21] a000f5a0: eb000ba7 bl a0012444 <_Objects_Namespace_remove> _POSIX_Message_queue_Namespace_remove( the_mq ); _POSIX_Message_queue_Delete( the_mq ); a000f5a4: e1a00006 mov r0, r6 a000f5a8: ebfffe33 bl a000ee7c <_POSIX_Message_queue_Delete> _Thread_Enable_dispatch(); a000f5ac: eb000ee8 bl a0013154 <_Thread_Enable_dispatch> return 0; a000f5b0: e1a00005 mov r0, r5 } a000f5b4: e8bd807c pop {r2, r3, r4, r5, r6, pc} =============================================================================== a00295bc : int nanosleep( const struct timespec *rqtp, struct timespec *rmtp ) { a00295bc: e92d4070 push {r4, r5, r6, lr} a00295c0: e1a05000 mov r5, r0 a00295c4: 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 ) ) a00295c8: eb000051 bl a0029714 <_Timespec_Is_valid> a00295cc: e3500000 cmp r0, #0 a00295d0: 1a000002 bne a00295e0 rtems_set_errno_and_return_minus_one( EINVAL ); a00295d4: ebffbd3f bl a0018ad8 <__errno> <== NOT EXECUTED a00295d8: e3a03016 mov r3, #22 <== NOT EXECUTED a00295dc: ea00002f b a00296a0 <== NOT EXECUTED ticks = _Timespec_To_ticks( rqtp ); a00295e0: e1a00005 mov r0, r5 a00295e4: ebffb3ba bl a00164d4 <_Timespec_To_ticks> a00295e8: e59f30c8 ldr r3, [pc, #200] ; a00296b8 * 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 ) { a00295ec: e2505000 subs r5, r0, #0 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a00295f0: e5932000 ldr r2, [r3] ++level; a00295f4: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a00295f8: e5832000 str r2, [r3] a00295fc: 1a000008 bne a0029624 * always operates on the scheduler that 'owns' the currently executing * thread. */ RTEMS_INLINE_ROUTINE void _Scheduler_Yield( void ) { _Scheduler.Operations.yield(); a0029600: e59f30b4 ldr r3, [pc, #180] ; a00296bc a0029604: e593300c ldr r3, [r3, #12] a0029608: e12fff33 blx r3 _Thread_Disable_dispatch(); _Scheduler_Yield(); _Thread_Enable_dispatch(); a002960c: ebff9a86 bl a001002c <_Thread_Enable_dispatch> if ( rmtp ) { a0029610: e3540000 cmp r4, #0 rmtp->tv_sec = 0; a0029614: 15845000 strne r5, [r4] rmtp->tv_nsec = 0; a0029618: 15845004 strne r5, [r4, #4] if ( !ticks ) { _Thread_Disable_dispatch(); _Scheduler_Yield(); _Thread_Enable_dispatch(); if ( rmtp ) { a002961c: 1a000023 bne a00296b0 a0029620: ea000021 b a00296ac /* * Block for the desired amount of time */ _Thread_Disable_dispatch(); _Thread_Set_state( a0029624: e59f6094 ldr r6, [pc, #148] ; a00296c0 a0029628: e3a01281 mov r1, #268435464 ; 0x10000008 a002962c: e5960008 ldr r0, [r6, #8] a0029630: ebff9c8e bl a0010870 <_Thread_Set_state> _Thread_Executing, STATES_DELAYING | STATES_INTERRUPTIBLE_BY_SIGNAL ); _Watchdog_Initialize( &_Thread_Executing->Timer, a0029634: e5961008 ldr r1, [r6, #8] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a0029638: e59f0084 ldr r0, [pc, #132] ; a00296c4 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a002963c: e3a03000 mov r3, #0 _Thread_Disable_dispatch(); _Thread_Set_state( _Thread_Executing, STATES_DELAYING | STATES_INTERRUPTIBLE_BY_SIGNAL ); _Watchdog_Initialize( a0029640: e5912008 ldr r2, [r1, #8] a0029644: e5813050 str r3, [r1, #80] ; 0x50 the_watchdog->routine = routine; a0029648: e5810064 str r0, [r1, #100] ; 0x64 the_watchdog->id = id; a002964c: e5812068 str r2, [r1, #104] ; 0x68 the_watchdog->user_data = user_data; a0029650: e581306c str r3, [r1, #108] ; 0x6c Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a0029654: e5815054 str r5, [r1, #84] ; 0x54 _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a0029658: e59f0068 ldr r0, [pc, #104] ; a00296c8 a002965c: e2811048 add r1, r1, #72 ; 0x48 a0029660: ebff9d6f bl a0010c24 <_Watchdog_Insert> _Thread_Delay_ended, _Thread_Executing->Object.id, NULL ); _Watchdog_Insert_ticks( &_Thread_Executing->Timer, ticks ); _Thread_Enable_dispatch(); a0029664: ebff9a70 bl a001002c <_Thread_Enable_dispatch> /* calculate time remaining */ if ( rmtp ) { a0029668: e3540000 cmp r4, #0 a002966c: 0a00000e beq a00296ac ticks -= _Thread_Executing->Timer.stop_time - _Thread_Executing->Timer.start_time; a0029670: e5963008 ldr r3, [r6, #8] _Timespec_From_ticks( ticks, rmtp ); a0029674: e1a01004 mov r1, r4 /* calculate time remaining */ if ( rmtp ) { ticks -= _Thread_Executing->Timer.stop_time - _Thread_Executing->Timer.start_time; a0029678: e593205c ldr r2, [r3, #92] ; 0x5c a002967c: e5933060 ldr r3, [r3, #96] ; 0x60 a0029680: e0633002 rsb r3, r3, r2 _Thread_Enable_dispatch(); /* calculate time remaining */ if ( rmtp ) { ticks -= a0029684: e0835005 add r5, r3, r5 _Thread_Executing->Timer.stop_time - _Thread_Executing->Timer.start_time; _Timespec_From_ticks( ticks, rmtp ); a0029688: e1a00005 mov r0, r5 a002968c: eb00000e bl a00296cc <_Timespec_From_ticks> */ #if defined(RTEMS_POSIX_API) /* * If there is time remaining, then we were interrupted by a signal. */ if ( ticks ) a0029690: e3550000 cmp r5, #0 a0029694: 0a000005 beq a00296b0 rtems_set_errno_and_return_minus_one( EINTR ); a0029698: ebffbd0e bl a0018ad8 <__errno> a002969c: e3a03004 mov r3, #4 a00296a0: e5803000 str r3, [r0] a00296a4: e3e05000 mvn r5, #0 a00296a8: ea000000 b a00296b0 #endif } return 0; a00296ac: e1a05004 mov r5, r4 } a00296b0: e1a00005 mov r0, r5 a00296b4: e8bd8070 pop {r4, r5, r6, pc} =============================================================================== a000bcc0 : /** * 3.4.2 Suspend Process Execution, P1003.1b-1993, p. 81 */ int pause( void ) { a000bcc0: e92d4001 push {r0, lr} <== NOT EXECUTED sigset_t all_signals; int status; (void) sigfillset( &all_signals ); a000bcc4: e1a0000d mov r0, sp <== NOT EXECUTED a000bcc8: eb000300 bl a000c8d0 <== NOT EXECUTED status = sigtimedwait( &all_signals, NULL, NULL ); a000bccc: e3a01000 mov r1, #0 <== NOT EXECUTED a000bcd0: e1a0000d mov r0, sp <== NOT EXECUTED a000bcd4: e1a02001 mov r2, r1 <== NOT EXECUTED a000bcd8: eb000360 bl a000ca60 <== NOT EXECUTED return status; } a000bcdc: e8bd8008 pop {r3, pc} <== NOT EXECUTED =============================================================================== a0009d50 : int pthread_atfork( void (*prepare)(void) __attribute__((unused)), void (*parent)(void) __attribute__((unused)), void (*child)(void) __attribute__((unused)) ) { a0009d50: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009d54: eb002099 bl a0011fc0 <__errno> <== NOT EXECUTED a0009d58: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009d5c: e5803000 str r3, [r0] <== NOT EXECUTED } a0009d60: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009d64: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000e3e8 : int pthread_attr_getdetachstate( const pthread_attr_t *attr, int *detachstate ) { if ( !attr || !attr->is_initialized || !detachstate ) a000e3e8: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000e3ec: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_getdetachstate( const pthread_attr_t *attr, int *detachstate ) { if ( !attr || !attr->is_initialized || !detachstate ) a000e3f0: 012fff1e bxeq lr <== NOT EXECUTED a000e3f4: e5930000 ldr r0, [r3] <== NOT EXECUTED a000e3f8: e3500000 cmp r0, #0 <== NOT EXECUTED a000e3fc: 13510000 cmpne r1, #0 <== NOT EXECUTED return EINVAL; *detachstate = attr->detachstate; a000e400: 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 ) a000e404: 13a00000 movne r0, #0 <== NOT EXECUTED a000e408: 03a00001 moveq r0, #1 <== NOT EXECUTED return EINVAL; a000e40c: 03a00016 moveq r0, #22 <== NOT EXECUTED *detachstate = attr->detachstate; a000e410: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000e414: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e418 : int pthread_attr_getguardsize( const pthread_attr_t *attr, size_t *guardsize ) { if ( !attr || !attr->is_initialized || !guardsize ) a000e418: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000e41c: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_getguardsize( const pthread_attr_t *attr, size_t *guardsize ) { if ( !attr || !attr->is_initialized || !guardsize ) a000e420: 012fff1e bxeq lr <== NOT EXECUTED a000e424: e5930000 ldr r0, [r3] <== NOT EXECUTED a000e428: e3500000 cmp r0, #0 <== NOT EXECUTED a000e42c: 13510000 cmpne r1, #0 <== NOT EXECUTED return EINVAL; *guardsize = attr->guardsize; a000e430: 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 ) a000e434: 13a00000 movne r0, #0 <== NOT EXECUTED a000e438: 03a00001 moveq r0, #1 <== NOT EXECUTED return EINVAL; a000e43c: 03a00016 moveq r0, #22 <== NOT EXECUTED *guardsize = attr->guardsize; a000e440: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000e444: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e448 : int pthread_attr_getinheritsched( const pthread_attr_t *attr, int *inheritsched ) { if ( !attr || !attr->is_initialized || !inheritsched ) a000e448: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000e44c: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_getinheritsched( const pthread_attr_t *attr, int *inheritsched ) { if ( !attr || !attr->is_initialized || !inheritsched ) a000e450: 012fff1e bxeq lr <== NOT EXECUTED a000e454: e5930000 ldr r0, [r3] <== NOT EXECUTED a000e458: e3500000 cmp r0, #0 <== NOT EXECUTED a000e45c: 13510000 cmpne r1, #0 <== NOT EXECUTED return EINVAL; *inheritsched = attr->inheritsched; a000e460: 15933010 ldrne r3, [r3, #16] <== NOT EXECUTED int pthread_attr_getinheritsched( const pthread_attr_t *attr, int *inheritsched ) { if ( !attr || !attr->is_initialized || !inheritsched ) a000e464: 13a00000 movne r0, #0 <== NOT EXECUTED a000e468: 03a00001 moveq r0, #1 <== NOT EXECUTED return EINVAL; a000e46c: 03a00016 moveq r0, #22 <== NOT EXECUTED *inheritsched = attr->inheritsched; a000e470: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000e474: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e478 : int pthread_attr_getschedparam( const pthread_attr_t *attr, struct sched_param *param ) { if ( !attr || !attr->is_initialized || !param ) a000e478: e3500000 cmp r0, #0 <== NOT EXECUTED int pthread_attr_getschedparam( const pthread_attr_t *attr, struct sched_param *param ) { a000e47c: e92d4030 push {r4, r5, lr} <== NOT EXECUTED if ( !attr || !attr->is_initialized || !param ) a000e480: 0a00000d beq a000e4bc <== NOT EXECUTED a000e484: e5905000 ldr r5, [r0] <== NOT EXECUTED a000e488: e3550000 cmp r5, #0 <== NOT EXECUTED a000e48c: 13510000 cmpne r1, #0 <== NOT EXECUTED a000e490: 13a05000 movne r5, #0 <== NOT EXECUTED a000e494: 03a05001 moveq r5, #1 <== NOT EXECUTED a000e498: 0a000009 beq a000e4c4 <== NOT EXECUTED return EINVAL; *param = attr->schedparam; a000e49c: e1a0c001 mov ip, r1 <== NOT EXECUTED a000e4a0: e2804018 add r4, r0, #24 <== NOT EXECUTED a000e4a4: e8b4000f ldm r4!, {r0, r1, r2, r3} <== NOT EXECUTED a000e4a8: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED a000e4ac: e8940007 ldm r4, {r0, r1, r2} <== NOT EXECUTED a000e4b0: e88c0007 stm ip, {r0, r1, r2} <== NOT EXECUTED return 0; a000e4b4: e1a00005 mov r0, r5 <== NOT EXECUTED a000e4b8: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED const pthread_attr_t *attr, struct sched_param *param ) { if ( !attr || !attr->is_initialized || !param ) return EINVAL; a000e4bc: e3a00016 mov r0, #22 <== NOT EXECUTED a000e4c0: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED a000e4c4: e3a00016 mov r0, #22 <== NOT EXECUTED *param = attr->schedparam; return 0; } a000e4c8: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a000e4cc : int pthread_attr_getschedpolicy( const pthread_attr_t *attr, int *policy ) { if ( !attr || !attr->is_initialized || !policy ) a000e4cc: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000e4d0: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_getschedpolicy( const pthread_attr_t *attr, int *policy ) { if ( !attr || !attr->is_initialized || !policy ) a000e4d4: 012fff1e bxeq lr <== NOT EXECUTED a000e4d8: e5930000 ldr r0, [r3] <== NOT EXECUTED a000e4dc: e3500000 cmp r0, #0 <== NOT EXECUTED a000e4e0: 13510000 cmpne r1, #0 <== NOT EXECUTED return EINVAL; *policy = attr->schedpolicy; a000e4e4: 15933014 ldrne r3, [r3, #20] <== NOT EXECUTED int pthread_attr_getschedpolicy( const pthread_attr_t *attr, int *policy ) { if ( !attr || !attr->is_initialized || !policy ) a000e4e8: 13a00000 movne r0, #0 <== NOT EXECUTED a000e4ec: 03a00001 moveq r0, #1 <== NOT EXECUTED return EINVAL; a000e4f0: 03a00016 moveq r0, #22 <== NOT EXECUTED *policy = attr->schedpolicy; a000e4f4: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000e4f8: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e4fc : int pthread_attr_getscope( const pthread_attr_t *attr, int *contentionscope ) { if ( !attr || !attr->is_initialized || !contentionscope ) a000e4fc: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000e500: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_getscope( const pthread_attr_t *attr, int *contentionscope ) { if ( !attr || !attr->is_initialized || !contentionscope ) a000e504: 012fff1e bxeq lr <== NOT EXECUTED a000e508: e5930000 ldr r0, [r3] <== NOT EXECUTED a000e50c: e3500000 cmp r0, #0 <== NOT EXECUTED a000e510: 13510000 cmpne r1, #0 <== NOT EXECUTED return EINVAL; *contentionscope = attr->contentionscope; a000e514: 1593300c ldrne r3, [r3, #12] <== NOT EXECUTED int pthread_attr_getscope( const pthread_attr_t *attr, int *contentionscope ) { if ( !attr || !attr->is_initialized || !contentionscope ) a000e518: 13a00000 movne r0, #0 <== NOT EXECUTED a000e51c: 03a00001 moveq r0, #1 <== NOT EXECUTED return EINVAL; a000e520: 03a00016 moveq r0, #22 <== NOT EXECUTED *contentionscope = attr->contentionscope; a000e524: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000e528: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e55c : const pthread_attr_t *attr, void **stackaddr, size_t *stacksize ) { if ( !attr || !attr->is_initialized || !stackaddr || !stacksize ) a000e55c: e2503000 subs r3, r0, #0 <== NOT EXECUTED a000e560: 0a00000c beq a000e598 <== NOT EXECUTED a000e564: e5930000 ldr r0, [r3] <== NOT EXECUTED a000e568: e3500000 cmp r0, #0 <== NOT EXECUTED a000e56c: 13510000 cmpne r1, #0 <== NOT EXECUTED a000e570: 13a00000 movne r0, #0 <== NOT EXECUTED a000e574: 03a00001 moveq r0, #1 <== NOT EXECUTED a000e578: 0a000006 beq a000e598 <== NOT EXECUTED a000e57c: e3520000 cmp r2, #0 <== NOT EXECUTED a000e580: 0a000006 beq a000e5a0 <== NOT EXECUTED return EINVAL; *stackaddr = attr->stackaddr; a000e584: e593c004 ldr ip, [r3, #4] <== NOT EXECUTED *stacksize = attr->stacksize; a000e588: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED ) { if ( !attr || !attr->is_initialized || !stackaddr || !stacksize ) return EINVAL; *stackaddr = attr->stackaddr; a000e58c: e581c000 str ip, [r1] <== NOT EXECUTED *stacksize = attr->stacksize; a000e590: e5823000 str r3, [r2] <== NOT EXECUTED return 0; a000e594: e12fff1e bx lr <== NOT EXECUTED void **stackaddr, size_t *stacksize ) { if ( !attr || !attr->is_initialized || !stackaddr || !stacksize ) return EINVAL; a000e598: e3a00016 mov r0, #22 <== NOT EXECUTED a000e59c: e12fff1e bx lr <== NOT EXECUTED a000e5a0: e3a00016 mov r0, #22 <== NOT EXECUTED *stackaddr = attr->stackaddr; *stacksize = attr->stacksize; return 0; } a000e5a4: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e52c : int pthread_attr_getstackaddr( const pthread_attr_t *attr, void **stackaddr ) { if ( !attr || !attr->is_initialized || !stackaddr ) a000e52c: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000e530: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_getstackaddr( const pthread_attr_t *attr, void **stackaddr ) { if ( !attr || !attr->is_initialized || !stackaddr ) a000e534: 012fff1e bxeq lr <== NOT EXECUTED a000e538: e5930000 ldr r0, [r3] <== NOT EXECUTED a000e53c: e3500000 cmp r0, #0 <== NOT EXECUTED a000e540: 13510000 cmpne r1, #0 <== NOT EXECUTED return EINVAL; *stackaddr = attr->stackaddr; a000e544: 15933004 ldrne r3, [r3, #4] <== NOT EXECUTED int pthread_attr_getstackaddr( const pthread_attr_t *attr, void **stackaddr ) { if ( !attr || !attr->is_initialized || !stackaddr ) a000e548: 13a00000 movne r0, #0 <== NOT EXECUTED a000e54c: 03a00001 moveq r0, #1 <== NOT EXECUTED return EINVAL; a000e550: 03a00016 moveq r0, #22 <== NOT EXECUTED *stackaddr = attr->stackaddr; a000e554: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000e558: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e5a8 : int pthread_attr_getstacksize( const pthread_attr_t *attr, size_t *stacksize ) { if ( !attr || !attr->is_initialized || !stacksize ) a000e5a8: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000e5ac: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_getstacksize( const pthread_attr_t *attr, size_t *stacksize ) { if ( !attr || !attr->is_initialized || !stacksize ) a000e5b0: 012fff1e bxeq lr <== NOT EXECUTED a000e5b4: e5930000 ldr r0, [r3] <== NOT EXECUTED a000e5b8: e3500000 cmp r0, #0 <== NOT EXECUTED a000e5bc: 13510000 cmpne r1, #0 <== NOT EXECUTED return EINVAL; *stacksize = attr->stacksize; a000e5c0: 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 ) a000e5c4: 13a00000 movne r0, #0 <== NOT EXECUTED a000e5c8: 03a00001 moveq r0, #1 <== NOT EXECUTED return EINVAL; a000e5cc: 03a00016 moveq r0, #22 <== NOT EXECUTED *stacksize = attr->stacksize; a000e5d0: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000e5d4: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e61c : int pthread_attr_setdetachstate( pthread_attr_t *attr, int detachstate ) { if ( !attr || !attr->is_initialized ) a000e61c: e3500000 cmp r0, #0 a000e620: 0a000007 beq a000e644 a000e624: e5903000 ldr r3, [r0] a000e628: e3530000 cmp r3, #0 a000e62c: 0a000004 beq a000e644 return EINVAL; switch ( detachstate ) { a000e630: e3510001 cmp r1, #1 case PTHREAD_CREATE_DETACHED: case PTHREAD_CREATE_JOINABLE: attr->detachstate = detachstate; a000e634: 9580103c strls r1, [r0, #60] ; 0x3c return 0; a000e638: 93a00000 movls r0, #0 ) { if ( !attr || !attr->is_initialized ) return EINVAL; switch ( detachstate ) { a000e63c: 912fff1e bxls lr a000e640: ea000001 b a000e64c <== NOT EXECUTED pthread_attr_t *attr, int detachstate ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000e644: e3a00016 mov r0, #22 <== NOT EXECUTED a000e648: e12fff1e bx lr <== NOT EXECUTED case PTHREAD_CREATE_JOINABLE: attr->detachstate = detachstate; return 0; default: return EINVAL; a000e64c: e3a00016 mov r0, #22 <== NOT EXECUTED } } a000e650: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e654 : int pthread_attr_setguardsize( pthread_attr_t *attr, size_t guardsize ) { if ( !attr || !attr->is_initialized ) a000e654: e3500000 cmp r0, #0 <== NOT EXECUTED return EINVAL; a000e658: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_setguardsize( pthread_attr_t *attr, size_t guardsize ) { if ( !attr || !attr->is_initialized ) a000e65c: 012fff1e bxeq lr <== NOT EXECUTED a000e660: e5903000 ldr r3, [r0] <== NOT EXECUTED a000e664: e3530000 cmp r3, #0 <== NOT EXECUTED return EINVAL; attr->guardsize = guardsize; a000e668: 15801034 strne r1, [r0, #52] ; 0x34 <== NOT EXECUTED pthread_attr_t *attr, size_t guardsize ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000e66c: 03a00016 moveq r0, #22 <== NOT EXECUTED attr->guardsize = guardsize; return 0; a000e670: 13a00000 movne r0, #0 <== NOT EXECUTED } a000e674: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a00101b0 : int pthread_attr_setinheritsched( pthread_attr_t *attr, int inheritsched ) { if ( !attr || !attr->is_initialized ) a00101b0: e3500000 cmp r0, #0 a00101b4: 0a000008 beq a00101dc a00101b8: e5903000 ldr r3, [r0] a00101bc: e3530000 cmp r3, #0 a00101c0: 0a000005 beq a00101dc return EINVAL; switch ( inheritsched ) { a00101c4: e2413001 sub r3, r1, #1 a00101c8: e3530001 cmp r3, #1 case PTHREAD_INHERIT_SCHED: case PTHREAD_EXPLICIT_SCHED: attr->inheritsched = inheritsched; a00101cc: 95801010 strls r1, [r0, #16] return 0; a00101d0: 93a00000 movls r0, #0 ) { if ( !attr || !attr->is_initialized ) return EINVAL; switch ( inheritsched ) { a00101d4: 912fff1e bxls lr a00101d8: ea000001 b a00101e4 <== NOT EXECUTED pthread_attr_t *attr, int inheritsched ) { if ( !attr || !attr->is_initialized ) return EINVAL; a00101dc: e3a00016 mov r0, #22 <== NOT EXECUTED a00101e0: e12fff1e bx lr <== NOT EXECUTED case PTHREAD_EXPLICIT_SCHED: attr->inheritsched = inheritsched; return 0; default: return ENOTSUP; a00101e4: e3a00086 mov r0, #134 ; 0x86 <== NOT EXECUTED } } a00101e8: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e6b4 : int pthread_attr_setschedparam( pthread_attr_t *attr, const struct sched_param *param ) { if ( !attr || !attr->is_initialized || !param ) a000e6b4: e3500000 cmp r0, #0 int pthread_attr_setschedparam( pthread_attr_t *attr, const struct sched_param *param ) { a000e6b8: e92d4030 push {r4, r5, lr} if ( !attr || !attr->is_initialized || !param ) a000e6bc: 0a00000d beq a000e6f8 a000e6c0: e5905000 ldr r5, [r0] a000e6c4: e3550000 cmp r5, #0 a000e6c8: 13510000 cmpne r1, #0 a000e6cc: 13a05000 movne r5, #0 a000e6d0: 03a05001 moveq r5, #1 a000e6d4: 0a000009 beq a000e700 return EINVAL; attr->schedparam = *param; a000e6d8: e280c018 add ip, r0, #24 a000e6dc: e1a04001 mov r4, r1 a000e6e0: e8b4000f ldm r4!, {r0, r1, r2, r3} a000e6e4: e8ac000f stmia ip!, {r0, r1, r2, r3} a000e6e8: e8940007 ldm r4, {r0, r1, r2} a000e6ec: e88c0007 stm ip, {r0, r1, r2} return 0; a000e6f0: e1a00005 mov r0, r5 a000e6f4: e8bd8030 pop {r4, r5, pc} pthread_attr_t *attr, const struct sched_param *param ) { if ( !attr || !attr->is_initialized || !param ) return EINVAL; a000e6f8: e3a00016 mov r0, #22 <== NOT EXECUTED a000e6fc: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED a000e700: e3a00016 mov r0, #22 <== NOT EXECUTED attr->schedparam = *param; return 0; } a000e704: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a000e708 : int pthread_attr_setschedpolicy( pthread_attr_t *attr, int policy ) { if ( !attr || !attr->is_initialized ) a000e708: e3500000 cmp r0, #0 a000e70c: 0a00000b beq a000e740 a000e710: e5903000 ldr r3, [r0] a000e714: e3530000 cmp r3, #0 a000e718: 0a000008 beq a000e740 return EINVAL; switch ( policy ) { a000e71c: e3510004 cmp r1, #4 a000e720: 8a000008 bhi a000e748 a000e724: e3a03001 mov r3, #1 a000e728: e1a03113 lsl r3, r3, r1 a000e72c: e3130017 tst r3, #23 case SCHED_OTHER: case SCHED_FIFO: case SCHED_RR: case SCHED_SPORADIC: attr->schedpolicy = policy; a000e730: 15801014 strne r1, [r0, #20] return 0; a000e734: 13a00000 movne r0, #0 ) { if ( !attr || !attr->is_initialized ) return EINVAL; switch ( policy ) { a000e738: 112fff1e bxne lr a000e73c: ea000001 b a000e748 <== NOT EXECUTED pthread_attr_t *attr, int policy ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000e740: e3a00016 mov r0, #22 <== NOT EXECUTED a000e744: e12fff1e bx lr <== NOT EXECUTED case SCHED_SPORADIC: attr->schedpolicy = policy; return 0; default: return ENOTSUP; a000e748: e3a00086 mov r0, #134 ; 0x86 <== NOT EXECUTED } } a000e74c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e750 : int pthread_attr_setscope( pthread_attr_t *attr, int contentionscope ) { if ( !attr || !attr->is_initialized ) a000e750: e3500000 cmp r0, #0 <== NOT EXECUTED return EINVAL; a000e754: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_attr_setscope( pthread_attr_t *attr, int contentionscope ) { if ( !attr || !attr->is_initialized ) a000e758: 012fff1e bxeq lr <== NOT EXECUTED a000e75c: e5903000 ldr r3, [r0] <== NOT EXECUTED a000e760: e3530000 cmp r3, #0 <== NOT EXECUTED a000e764: 0a000007 beq a000e788 <== NOT EXECUTED return EINVAL; switch ( contentionscope ) { a000e768: e3510000 cmp r1, #0 <== NOT EXECUTED case PTHREAD_SCOPE_PROCESS: attr->contentionscope = contentionscope; a000e76c: 0580100c streq r1, [r0, #12] <== NOT EXECUTED return 0; a000e770: 01a00001 moveq r0, r1 <== NOT EXECUTED ) { if ( !attr || !attr->is_initialized ) return EINVAL; switch ( contentionscope ) { a000e774: 012fff1e bxeq lr <== NOT EXECUTED case PTHREAD_SCOPE_SYSTEM: return ENOTSUP; default: return EINVAL; a000e778: e3510001 cmp r1, #1 <== NOT EXECUTED a000e77c: 03a00086 moveq r0, #134 ; 0x86 <== NOT EXECUTED a000e780: 13a00016 movne r0, #22 <== NOT EXECUTED a000e784: e12fff1e bx lr <== NOT EXECUTED pthread_attr_t *attr, int contentionscope ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000e788: e3a00016 mov r0, #22 <== NOT EXECUTED return ENOTSUP; default: return EINVAL; } } a000e78c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000e7b4 : pthread_attr_t *attr, void *stackaddr, size_t stacksize ) { if ( !attr || !attr->is_initialized ) a000e7b4: e3500000 cmp r0, #0 return EINVAL; a000e7b8: 03a00016 moveq r0, #22 pthread_attr_t *attr, void *stackaddr, size_t stacksize ) { if ( !attr || !attr->is_initialized ) a000e7bc: 012fff1e bxeq lr a000e7c0: e5903000 ldr r3, [r0] a000e7c4: e3530000 cmp r3, #0 a000e7c8: 0a000008 beq a000e7f0 return EINVAL; if (stacksize < PTHREAD_MINIMUM_STACK_SIZE) a000e7cc: e59f3024 ldr r3, [pc, #36] ; a000e7f8 attr->stacksize = PTHREAD_MINIMUM_STACK_SIZE; else attr->stacksize = stacksize; attr->stackaddr = stackaddr; a000e7d0: e5801004 str r1, [r0, #4] ) { if ( !attr || !attr->is_initialized ) return EINVAL; if (stacksize < PTHREAD_MINIMUM_STACK_SIZE) a000e7d4: e5933000 ldr r3, [r3] a000e7d8: e1a03083 lsl r3, r3, #1 attr->stacksize = PTHREAD_MINIMUM_STACK_SIZE; a000e7dc: e1530002 cmp r3, r2 a000e7e0: 25803008 strcs r3, [r0, #8] a000e7e4: 35802008 strcc r2, [r0, #8] else attr->stacksize = stacksize; attr->stackaddr = stackaddr; return 0; a000e7e8: e3a00000 mov r0, #0 a000e7ec: e12fff1e bx lr void *stackaddr, size_t stacksize ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000e7f0: e3a00016 mov r0, #22 <== NOT EXECUTED else attr->stacksize = stacksize; attr->stackaddr = stackaddr; return 0; } a000e7f4: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a00101ec : int pthread_attr_setstacksize( pthread_attr_t *attr, size_t stacksize ) { if ( !attr || !attr->is_initialized ) a00101ec: e3500000 cmp r0, #0 return EINVAL; a00101f0: 03a00016 moveq r0, #22 int pthread_attr_setstacksize( pthread_attr_t *attr, size_t stacksize ) { if ( !attr || !attr->is_initialized ) a00101f4: 012fff1e bxeq lr a00101f8: e5903000 ldr r3, [r0] a00101fc: e3530000 cmp r3, #0 a0010200: 0a000007 beq a0010224 return EINVAL; if (stacksize < PTHREAD_MINIMUM_STACK_SIZE) a0010204: e59f3020 ldr r3, [pc, #32] ; a001022c a0010208: e5933000 ldr r3, [r3] a001020c: e1a03083 lsl r3, r3, #1 a0010210: e1510003 cmp r1, r3 attr->stacksize = PTHREAD_MINIMUM_STACK_SIZE; a0010214: 35803008 strcc r3, [r0, #8] else attr->stacksize = stacksize; a0010218: 25801008 strcs r1, [r0, #8] return 0; a001021c: e3a00000 mov r0, #0 a0010220: e12fff1e bx lr pthread_attr_t *attr, size_t stacksize ) { if ( !attr || !attr->is_initialized ) return EINVAL; a0010224: e3a00016 mov r0, #22 <== NOT EXECUTED if (stacksize < PTHREAD_MINIMUM_STACK_SIZE) attr->stacksize = PTHREAD_MINIMUM_STACK_SIZE; else attr->stacksize = stacksize; return 0; } a0010228: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000a424 : ) { POSIX_Barrier_Control *the_barrier = NULL; Objects_Locations location; if ( !barrier ) a000a424: e2503000 subs r3, r0, #0 * source of the error. */ int pthread_barrier_destroy( pthread_barrier_t *barrier ) { a000a428: e92d4031 push {r0, r4, r5, lr} POSIX_Barrier_Control *the_barrier = NULL; Objects_Locations location; if ( !barrier ) a000a42c: 0a000016 beq a000a48c RTEMS_INLINE_ROUTINE POSIX_Barrier_Control *_POSIX_Barrier_Get ( pthread_barrier_t *barrier, Objects_Locations *location ) { return (POSIX_Barrier_Control *) _Objects_Get( a000a430: e5931000 ldr r1, [r3] a000a434: e59f0058 ldr r0, [pc, #88] ; a000a494 a000a438: e1a0200d mov r2, sp a000a43c: eb00096e bl a000c9fc <_Objects_Get> return EINVAL; the_barrier = _POSIX_Barrier_Get( barrier, &location ); switch ( location ) { a000a440: e59d3000 ldr r3, [sp] a000a444: e1a04000 mov r4, r0 a000a448: e3530000 cmp r3, #0 a000a44c: 1a00000e bne a000a48c case OBJECTS_LOCAL: if ( the_barrier->Barrier.number_of_waiting_threads != 0 ) { a000a450: e5905058 ldr r5, [r0, #88] ; 0x58 a000a454: e3550000 cmp r5, #0 a000a458: 0a000002 beq a000a468 _Thread_Enable_dispatch(); a000a45c: eb000cd5 bl a000d7b8 <_Thread_Enable_dispatch> <== NOT EXECUTED return EBUSY; a000a460: e3a00010 mov r0, #16 <== NOT EXECUTED a000a464: ea000009 b a000a490 <== NOT EXECUTED } _Objects_Close( &_POSIX_Barrier_Information, &the_barrier->Object ); a000a468: e59f0024 ldr r0, [pc, #36] ; a000a494 a000a46c: e1a01004 mov r1, r4 a000a470: eb00085c bl a000c5e8 <_Objects_Close> */ RTEMS_INLINE_ROUTINE void _POSIX_Barrier_Free ( POSIX_Barrier_Control *the_barrier ) { _Objects_Free( &_POSIX_Barrier_Information, &the_barrier->Object ); a000a474: e59f0018 ldr r0, [pc, #24] ; a000a494 a000a478: e1a01004 mov r1, r4 a000a47c: eb000906 bl a000c89c <_Objects_Free> _POSIX_Barrier_Free( the_barrier ); _Thread_Enable_dispatch(); a000a480: eb000ccc bl a000d7b8 <_Thread_Enable_dispatch> return 0; a000a484: e1a00005 mov r0, r5 a000a488: ea000000 b a000a490 #endif case OBJECTS_ERROR: break; } return EINVAL; a000a48c: e3a00016 mov r0, #22 <== NOT EXECUTED } a000a490: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000a498 : int pthread_barrier_init( pthread_barrier_t *barrier, const pthread_barrierattr_t *attr, unsigned int count ) { a000a498: e92d40ff push {r0, r1, r2, r3, r4, r5, r6, r7, lr} const pthread_barrierattr_t *the_attr; /* * Error check parameters */ if ( !barrier ) a000a49c: e2507000 subs r7, r0, #0 int pthread_barrier_init( pthread_barrier_t *barrier, const pthread_barrierattr_t *attr, unsigned int count ) { a000a4a0: e1a04002 mov r4, r2 const pthread_barrierattr_t *the_attr; /* * Error check parameters */ if ( !barrier ) a000a4a4: 0a000026 beq a000a544 return EINVAL; if ( count == 0 ) a000a4a8: e3520000 cmp r2, #0 a000a4ac: 0a000024 beq a000a544 return EINVAL; /* * If the user passed in NULL, use the default attributes */ if ( attr ) { a000a4b0: e3510000 cmp r1, #0 a000a4b4: 1a000002 bne a000a4c4 the_attr = attr; } else { (void) pthread_barrierattr_init( &my_attr ); a000a4b8: e28d0008 add r0, sp, #8 a000a4bc: ebffffc3 bl a000a3d0 the_attr = &my_attr; a000a4c0: e28d1008 add r1, sp, #8 } /* * Now start error checking the attributes that we are going to use */ if ( !the_attr->is_initialized ) a000a4c4: e5913000 ldr r3, [r1] a000a4c8: e3530000 cmp r3, #0 a000a4cc: 0a00001c beq a000a544 return EINVAL; switch ( the_attr->process_shared ) { a000a4d0: e5915004 ldr r5, [r1, #4] a000a4d4: e3550000 cmp r5, #0 a000a4d8: 1a000019 bne a000a544 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000a4dc: e59f306c ldr r3, [pc, #108] ; a000a550 } /* * Convert from POSIX attributes to Core Barrier attributes */ the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE; a000a4e0: e58d5000 str r5, [sp] the_attributes.maximum_count = count; a000a4e4: e58d4004 str r4, [sp, #4] a000a4e8: e5932000 ldr r2, [r3] ++level; a000a4ec: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000a4f0: e5832000 str r2, [r3] * This function allocates a barrier control block from * the inactive chain of free barrier control blocks. */ RTEMS_INLINE_ROUTINE POSIX_Barrier_Control *_POSIX_Barrier_Allocate( void ) { return (POSIX_Barrier_Control *) a000a4f4: e59f6058 ldr r6, [pc, #88] ; a000a554 a000a4f8: e1a00006 mov r0, r6 a000a4fc: eb000817 bl a000c560 <_Objects_Allocate> */ _Thread_Disable_dispatch(); /* prevents deletion */ the_barrier = _POSIX_Barrier_Allocate(); if ( !the_barrier ) { a000a500: e2504000 subs r4, r0, #0 a000a504: 1a000002 bne a000a514 _Thread_Enable_dispatch(); a000a508: eb000caa bl a000d7b8 <_Thread_Enable_dispatch> <== NOT EXECUTED return EAGAIN; a000a50c: e3a0000b mov r0, #11 <== NOT EXECUTED a000a510: ea00000c b a000a548 <== NOT EXECUTED } _CORE_barrier_Initialize( &the_barrier->Barrier, &the_attributes ); a000a514: e2840010 add r0, r4, #16 a000a518: e1a0100d mov r1, sp a000a51c: eb00059d bl a000bb98 <_CORE_barrier_Initialize> #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a520: e596201c ldr r2, [r6, #28] Objects_Information *information, Objects_Control *the_object, uint32_t name ) { _Objects_Set_local_object( a000a524: e5943008 ldr r3, [r4, #8] a000a528: e1d410b8 ldrh r1, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a52c: 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; a000a530: e584500c str r5, [r4, #12] ); /* * Exit the critical section and return the user an operational barrier */ *barrier = the_barrier->Object.id; a000a534: e5873000 str r3, [r7] _Thread_Enable_dispatch(); a000a538: eb000c9e bl a000d7b8 <_Thread_Enable_dispatch> return 0; a000a53c: e1a00005 mov r0, r5 a000a540: ea000000 b a000a548 switch ( the_attr->process_shared ) { case PTHREAD_PROCESS_PRIVATE: /* only supported values */ break; case PTHREAD_PROCESS_SHARED: default: return EINVAL; a000a544: 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; } a000a548: e28dd010 add sp, sp, #16 a000a54c: e8bd80f0 pop {r4, r5, r6, r7, pc} =============================================================================== a000a558 : ) { POSIX_Barrier_Control *the_barrier = NULL; Objects_Locations location; if ( !barrier ) a000a558: e2503000 subs r3, r0, #0 */ int pthread_barrier_wait( pthread_barrier_t *barrier ) { a000a55c: e92d4003 push {r0, r1, lr} POSIX_Barrier_Control *the_barrier = NULL; Objects_Locations location; if ( !barrier ) a000a560: 0a000012 beq a000a5b0 RTEMS_INLINE_ROUTINE POSIX_Barrier_Control *_POSIX_Barrier_Get ( pthread_barrier_t *barrier, Objects_Locations *location ) { return (POSIX_Barrier_Control *) _Objects_Get( a000a564: e5931000 ldr r1, [r3] a000a568: e28d2004 add r2, sp, #4 a000a56c: e59f0044 ldr r0, [pc, #68] ; a000a5b8 a000a570: eb000921 bl a000c9fc <_Objects_Get> return EINVAL; the_barrier = _POSIX_Barrier_Get( barrier, &location ); switch ( location ) { a000a574: e59d3004 ldr r3, [sp, #4] a000a578: e1a02000 mov r2, r0 a000a57c: e3530000 cmp r3, #0 a000a580: 1a00000a bne a000a5b0 case OBJECTS_LOCAL: _CORE_barrier_Wait( a000a584: e58d3000 str r3, [sp] a000a588: e5921008 ldr r1, [r2, #8] a000a58c: e2800010 add r0, r0, #16 a000a590: e3a02001 mov r2, #1 a000a594: eb000589 bl a000bbc0 <_CORE_barrier_Wait> the_barrier->Object.id, true, 0, NULL ); _Thread_Enable_dispatch(); a000a598: eb000c86 bl a000d7b8 <_Thread_Enable_dispatch> return _POSIX_Barrier_Translate_core_barrier_return_code( _Thread_Executing->Wait.return_code ); a000a59c: e59f3018 ldr r3, [pc, #24] ; a000a5bc a000a5a0: e5933008 ldr r3, [r3, #8] true, 0, NULL ); _Thread_Enable_dispatch(); return _POSIX_Barrier_Translate_core_barrier_return_code( a000a5a4: e5930034 ldr r0, [r3, #52] ; 0x34 a000a5a8: eb001644 bl a000fec0 <_POSIX_Barrier_Translate_core_barrier_return_code> a000a5ac: ea000000 b a000a5b4 #endif case OBJECTS_ERROR: break; } return EINVAL; a000a5b0: e3a00016 mov r0, #22 <== NOT EXECUTED } a000a5b4: e8bd800c pop {r2, r3, pc} =============================================================================== a000a384 : int pthread_barrierattr_destroy( pthread_barrierattr_t *attr ) { if ( !attr || attr->is_initialized == false ) a000a384: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000a388: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_barrierattr_destroy( pthread_barrierattr_t *attr ) { if ( !attr || attr->is_initialized == false ) a000a38c: 012fff1e bxeq lr <== NOT EXECUTED a000a390: e5932000 ldr r2, [r3] <== NOT EXECUTED a000a394: e3520000 cmp r2, #0 <== NOT EXECUTED return EINVAL; attr->is_initialized = false; a000a398: 13a00000 movne r0, #0 <== NOT EXECUTED a000a39c: 15830000 strne r0, [r3] <== NOT EXECUTED int pthread_barrierattr_destroy( pthread_barrierattr_t *attr ) { if ( !attr || attr->is_initialized == false ) return EINVAL; a000a3a0: 03a00016 moveq r0, #22 <== NOT EXECUTED attr->is_initialized = false; return 0; } a000a3a4: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000a3a8 : int pthread_barrierattr_getpshared( const pthread_barrierattr_t *attr, int *pshared ) { if ( !attr ) a000a3a8: e3500000 cmp r0, #0 return EINVAL; a000a3ac: 03a00016 moveq r0, #22 int pthread_barrierattr_getpshared( const pthread_barrierattr_t *attr, int *pshared ) { if ( !attr ) a000a3b0: 012fff1e bxeq lr return EINVAL; if ( !attr->is_initialized ) a000a3b4: e5903000 ldr r3, [r0] <== NOT EXECUTED a000a3b8: e3530000 cmp r3, #0 <== NOT EXECUTED return EINVAL; *pshared = attr->process_shared; a000a3bc: 15903004 ldrne r3, [r0, #4] <== NOT EXECUTED { if ( !attr ) return EINVAL; if ( !attr->is_initialized ) return EINVAL; a000a3c0: 03a00016 moveq r0, #22 <== NOT EXECUTED *pshared = attr->process_shared; return 0; a000a3c4: 13a00000 movne r0, #0 <== NOT EXECUTED return EINVAL; if ( !attr->is_initialized ) return EINVAL; *pshared = attr->process_shared; a000a3c8: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000a3cc: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000a3ec : int pthread_barrierattr_setpshared( pthread_barrierattr_t *attr, int pshared ) { if ( !attr ) a000a3ec: e3500000 cmp r0, #0 a000a3f0: 0a000007 beq a000a414 return EINVAL; if ( !attr->is_initialized ) a000a3f4: e5903000 ldr r3, [r0] <== NOT EXECUTED a000a3f8: e3530000 cmp r3, #0 <== NOT EXECUTED a000a3fc: 0a000004 beq a000a414 <== NOT EXECUTED return EINVAL; switch ( pshared ) { a000a400: e3510001 cmp r1, #1 <== NOT EXECUTED case PTHREAD_PROCESS_SHARED: case PTHREAD_PROCESS_PRIVATE: attr->process_shared = pshared; a000a404: 95801004 strls r1, [r0, #4] <== NOT EXECUTED return 0; a000a408: 93a00000 movls r0, #0 <== NOT EXECUTED return EINVAL; if ( !attr->is_initialized ) return EINVAL; switch ( pshared ) { a000a40c: 912fff1e bxls lr <== NOT EXECUTED a000a410: ea000001 b a000a41c <== NOT EXECUTED { if ( !attr ) return EINVAL; if ( !attr->is_initialized ) return EINVAL; a000a414: e3a00016 mov r0, #22 a000a418: e12fff1e bx lr case PTHREAD_PROCESS_PRIVATE: attr->process_shared = pshared; return 0; default: return EINVAL; a000a41c: e3a00016 mov r0, #22 <== NOT EXECUTED } } a000a420: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a00095e4 : * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a00095e4: e59f207c ldr r2, [pc, #124] ; a0009668 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 ]; a00095e8: e59f307c ldr r3, [pc, #124] ; a000966c */ void pthread_cleanup_pop( int execute ) { a00095ec: e92d4070 push {r4, r5, r6, lr} a00095f0: 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 ]; a00095f4: e5933008 ldr r3, [r3, #8] */ void pthread_cleanup_pop( int execute ) { a00095f8: e1a06000 mov r6, r0 ++level; a00095fc: 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 ]; a0009600: e59330f4 ldr r3, [r3, #244] ; 0xf4 _Thread_Dispatch_disable_level = level; a0009604: e5821000 str r1, [r2] uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0009608: e10f4000 mrs r4, CPSR a000960c: e3842080 orr r2, r4, #128 ; 0x80 a0009610: e129f002 msr CPSR_fc, r2 */ _Thread_Disable_dispatch(); _ISR_Disable( level ); if ( _Chain_Is_empty( handler_stack ) ) { a0009614: 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 ); a0009618: e28320e8 add r2, r3, #232 ; 0xe8 a000961c: e1510002 cmp r1, r2 a0009620: 1a000002 bne a0009630 _Thread_Enable_dispatch(); a0009624: eb000a9d bl a000c0a0 <_Thread_Enable_dispatch> <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0009628: e129f004 msr CPSR_fc, r4 <== NOT EXECUTED a000962c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED _ISR_Enable( level ); return; } handler = (POSIX_Cancel_Handler_control *) a0009630: e59300ec ldr r0, [r3, #236] ; 0xec { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; a0009634: e890000c ldm r0, {r2, r3} next->previous = previous; a0009638: e5823004 str r3, [r2, #4] previous->next = next; a000963c: e5832000 str r2, [r3] a0009640: e129f004 msr CPSR_fc, r4 _Chain_Tail( handler_stack )->previous; _Chain_Extract_unprotected( &handler->Node ); _ISR_Enable( level ); tmp_handler = *handler; a0009644: e5904008 ldr r4, [r0, #8] a0009648: e590500c ldr r5, [r0, #12] _Workspace_Free( handler ); a000964c: eb000e3e bl a000cf4c <_Workspace_Free> _Thread_Enable_dispatch(); a0009650: eb000a92 bl a000c0a0 <_Thread_Enable_dispatch> if ( execute ) a0009654: e3560000 cmp r6, #0 a0009658: 0a000001 beq a0009664 (*tmp_handler.routine)( tmp_handler.arg ); a000965c: e1a00005 mov r0, r5 a0009660: e12fff34 blx r4 a0009664: e8bd8070 pop {r4, r5, r6, pc} =============================================================================== a0009d3c : void pthread_cleanup_push( void (*routine)( void * ), void *arg ) { a0009d3c: 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 ) a0009d40: e2505000 subs r5, r0, #0 void pthread_cleanup_push( void (*routine)( void * ), void *arg ) { a0009d44: 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 ) a0009d48: 0a000011 beq a0009d94 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0009d4c: e59f3044 ldr r3, [pc, #68] ; a0009d98 a0009d50: e5932000 ldr r2, [r3] ++level; a0009d54: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a0009d58: e5832000 str r2, [r3] return; _Thread_Disable_dispatch(); handler = _Workspace_Allocate( sizeof( POSIX_Cancel_Handler_control ) ); a0009d5c: e3a00010 mov r0, #16 a0009d60: eb0010e3 bl a000e0f4 <_Workspace_Allocate> if ( handler ) { a0009d64: e2503000 subs r3, r0, #0 a0009d68: 0a000007 beq a0009d8c thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; a0009d6c: e59f2028 ldr r2, [pc, #40] ; a0009d9c handler_stack = &thread_support->Cancellation_Handlers; handler->routine = routine; handler->arg = arg; _Chain_Append( handler_stack, &handler->Node ); a0009d70: 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 ]; a0009d74: e5922008 ldr r2, [r2, #8] handler_stack = &thread_support->Cancellation_Handlers; a0009d78: e59200f4 ldr r0, [r2, #244] ; 0xf4 handler->routine = routine; a0009d7c: e5835008 str r5, [r3, #8] handler->arg = arg; a0009d80: e583400c str r4, [r3, #12] _Chain_Append( handler_stack, &handler->Node ); a0009d84: e28000e4 add r0, r0, #228 ; 0xe4 a0009d88: eb0005e4 bl a000b520 <_Chain_Append> } _Thread_Enable_dispatch(); } a0009d8c: e8bd4030 pop {r4, r5, lr} handler->routine = routine; handler->arg = arg; _Chain_Append( handler_stack, &handler->Node ); } _Thread_Enable_dispatch(); a0009d90: ea000ce7 b a000d134 <_Thread_Enable_dispatch> a0009d94: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a000abf0 : * P1003.1c/Draft 10, p. 87 */ int pthread_cond_destroy( pthread_cond_t *cond ) { a000abf0: e92d4031 push {r0, r4, r5, lr} POSIX_Condition_variables_Control *the_cond; Objects_Locations location; the_cond = _POSIX_Condition_variables_Get( cond, &location ); a000abf4: e1a0100d mov r1, sp a000abf8: eb000015 bl a000ac54 <_POSIX_Condition_variables_Get> switch ( location ) { a000abfc: e59d3000 ldr r3, [sp] ) { POSIX_Condition_variables_Control *the_cond; Objects_Locations location; the_cond = _POSIX_Condition_variables_Get( cond, &location ); a000ac00: e1a04000 mov r4, r0 switch ( location ) { a000ac04: e3530000 cmp r3, #0 #endif case OBJECTS_ERROR: break; } return EINVAL; a000ac08: 13a00016 movne r0, #22 { POSIX_Condition_variables_Control *the_cond; Objects_Locations location; the_cond = _POSIX_Condition_variables_Get( cond, &location ); switch ( location ) { a000ac0c: 1a00000e bne a000ac4c case OBJECTS_LOCAL: if ( _Thread_queue_First( &the_cond->Wait_queue ) ) { a000ac10: e2840018 add r0, r4, #24 a000ac14: eb00103d bl a000ed10 <_Thread_queue_First> a000ac18: e2505000 subs r5, r0, #0 a000ac1c: 0a000002 beq a000ac2c _Thread_Enable_dispatch(); a000ac20: eb000e77 bl a000e604 <_Thread_Enable_dispatch> <== NOT EXECUTED return EBUSY; a000ac24: e3a00010 mov r0, #16 <== NOT EXECUTED a000ac28: ea000007 b a000ac4c <== NOT EXECUTED } _Objects_Close( a000ac2c: e59f001c ldr r0, [pc, #28] ; a000ac50 a000ac30: e1a01004 mov r1, r4 a000ac34: eb0009fe bl a000d434 <_Objects_Close> RTEMS_INLINE_ROUTINE void _POSIX_Condition_variables_Free ( POSIX_Condition_variables_Control *the_condition_variable ) { _Objects_Free( a000ac38: e59f0010 ldr r0, [pc, #16] ; a000ac50 a000ac3c: e1a01004 mov r1, r4 a000ac40: eb000aa8 bl a000d6e8 <_Objects_Free> &_POSIX_Condition_variables_Information, &the_cond->Object ); _POSIX_Condition_variables_Free( the_cond ); _Thread_Enable_dispatch(); a000ac44: eb000e6e bl a000e604 <_Thread_Enable_dispatch> return 0; a000ac48: e1a00005 mov r0, r5 case OBJECTS_ERROR: break; } return EINVAL; } a000ac4c: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000acb8 : */ int pthread_cond_init( pthread_cond_t *cond, const pthread_condattr_t *attr ) { a000acb8: 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; a000acbc: e59f50a8 ldr r5, [pc, #168] ; a000ad6c a000acc0: e3510000 cmp r1, #0 a000acc4: 11a05001 movne r5, r1 /* * Be careful about attributes when global!!! */ if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED ) a000acc8: e5953004 ldr r3, [r5, #4] */ int pthread_cond_init( pthread_cond_t *cond, const pthread_condattr_t *attr ) { a000accc: 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 ) a000acd0: e3530001 cmp r3, #1 a000acd4: 0a000020 beq a000ad5c return EINVAL; if ( !the_attr->is_initialized ) a000acd8: e5953000 ldr r3, [r5] a000acdc: e3530000 cmp r3, #0 a000ace0: 0a00001f beq a000ad64 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000ace4: e59f3084 ldr r3, [pc, #132] ; a000ad70 a000ace8: e5932000 ldr r2, [r3] ++level; a000acec: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000acf0: e5832000 str r2, [r3] */ RTEMS_INLINE_ROUTINE POSIX_Condition_variables_Control *_POSIX_Condition_variables_Allocate( void ) { return (POSIX_Condition_variables_Control *) a000acf4: e59f6078 ldr r6, [pc, #120] ; a000ad74 a000acf8: e1a00006 mov r0, r6 a000acfc: eb0009aa bl a000d3ac <_Objects_Allocate> _Thread_Disable_dispatch(); the_cond = _POSIX_Condition_variables_Allocate(); if ( !the_cond ) { a000ad00: e2504000 subs r4, r0, #0 a000ad04: 1a000002 bne a000ad14 _Thread_Enable_dispatch(); a000ad08: eb000e3d bl a000e604 <_Thread_Enable_dispatch> return ENOMEM; a000ad0c: e3a0000c mov r0, #12 a000ad10: e8bd80f0 pop {r4, r5, r6, r7, pc} } the_cond->process_shared = the_attr->process_shared; a000ad14: e5953004 ldr r3, [r5, #4] the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX; a000ad18: e3a05000 mov r5, #0 _Thread_queue_Initialize( a000ad1c: e2840018 add r0, r4, #24 if ( !the_cond ) { _Thread_Enable_dispatch(); return ENOMEM; } the_cond->process_shared = the_attr->process_shared; a000ad20: e5843010 str r3, [r4, #16] the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX; _Thread_queue_Initialize( a000ad24: e1a01005 mov r1, r5 a000ad28: e59f2048 ldr r2, [pc, #72] ; a000ad78 a000ad2c: e3a03074 mov r3, #116 ; 0x74 return ENOMEM; } the_cond->process_shared = the_attr->process_shared; the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX; a000ad30: e5845014 str r5, [r4, #20] _Thread_queue_Initialize( a000ad34: eb001017 bl a000ed98 <_Thread_queue_Initialize> #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000ad38: e596201c ldr r2, [r6, #28] Objects_Information *information, Objects_Control *the_object, uint32_t name ) { _Objects_Set_local_object( a000ad3c: e5943008 ldr r3, [r4, #8] a000ad40: e1d410b8 ldrh r1, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000ad44: 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; a000ad48: e584500c str r5, [r4, #12] &_POSIX_Condition_variables_Information, &the_cond->Object, 0 ); *cond = the_cond->Object.id; a000ad4c: e5873000 str r3, [r7] _Thread_Enable_dispatch(); a000ad50: eb000e2b bl a000e604 <_Thread_Enable_dispatch> return 0; a000ad54: e1a00005 mov r0, r5 a000ad58: e8bd80f0 pop {r4, r5, r6, r7, pc} /* * Be careful about attributes when global!!! */ if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED ) return EINVAL; a000ad5c: e3a00016 mov r0, #22 <== NOT EXECUTED a000ad60: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED if ( !the_attr->is_initialized ) return EINVAL; a000ad64: e3a00016 mov r0, #22 <== NOT EXECUTED *cond = the_cond->Object.id; _Thread_Enable_dispatch(); return 0; } a000ad68: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED =============================================================================== a000add8 : int pthread_cond_timedwait( pthread_cond_t *cond, pthread_mutex_t *mutex, const struct timespec *abstime ) { a000add8: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED a000addc: e1a05000 mov r5, r0 <== NOT EXECUTED a000ade0: 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); a000ade4: e1a00002 mov r0, r2 <== NOT EXECUTED a000ade8: e1a0100d mov r1, sp <== NOT EXECUTED a000adec: eb000121 bl a000b278 <_POSIX_Absolute_timeout_to_ticks> <== NOT EXECUTED if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID ) a000adf0: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000adf4: 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 ) a000adf8: 0a000007 beq a000ae1c <== NOT EXECUTED return EINVAL; if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST || a000adfc: e2433001 sub r3, r3, #1 <== NOT EXECUTED status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW ) already_timedout = true; return _POSIX_Condition_variables_Wait_support( a000ae00: e3530001 cmp r3, #1 <== NOT EXECUTED a000ae04: e1a00005 mov r0, r5 <== NOT EXECUTED a000ae08: e1a01004 mov r1, r4 <== NOT EXECUTED a000ae0c: e59d2000 ldr r2, [sp] <== NOT EXECUTED a000ae10: 83a03000 movhi r3, #0 <== NOT EXECUTED a000ae14: 93a03001 movls r3, #1 <== NOT EXECUTED a000ae18: eb000003 bl a000ae2c <_POSIX_Condition_variables_Wait_support><== NOT EXECUTED cond, mutex, ticks, already_timedout ); } a000ae1c: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a000ab88 : int pthread_condattr_getpshared( const pthread_condattr_t *attr, int *pshared ) { if ( !attr ) a000ab88: e3500000 cmp r0, #0 <== NOT EXECUTED return EINVAL; *pshared = attr->process_shared; a000ab8c: 15903004 ldrne r3, [r0, #4] <== NOT EXECUTED const pthread_condattr_t *attr, int *pshared ) { if ( !attr ) return EINVAL; a000ab90: 03a00016 moveq r0, #22 <== NOT EXECUTED *pshared = attr->process_shared; return 0; a000ab94: 13a00000 movne r0, #0 <== NOT EXECUTED ) { if ( !attr ) return EINVAL; *pshared = attr->process_shared; a000ab98: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000ab9c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000abc8 : int pthread_condattr_setpshared( pthread_condattr_t *attr, int pshared ) { if ( !attr ) a000abc8: e3500000 cmp r0, #0 <== NOT EXECUTED return EINVAL; a000abcc: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_condattr_setpshared( pthread_condattr_t *attr, int pshared ) { if ( !attr ) a000abd0: 012fff1e bxeq lr <== NOT EXECUTED return EINVAL; switch ( pshared ) { a000abd4: e3510001 cmp r1, #1 <== NOT EXECUTED case PTHREAD_PROCESS_SHARED: case PTHREAD_PROCESS_PRIVATE: attr->process_shared = pshared; a000abd8: 95801004 strls r1, [r0, #4] <== NOT EXECUTED return 0; default: return EINVAL; a000abdc: 83a00016 movhi r0, #22 <== NOT EXECUTED switch ( pshared ) { case PTHREAD_PROCESS_SHARED: case PTHREAD_PROCESS_PRIVATE: attr->process_shared = pshared; return 0; a000abe0: 93a00000 movls r0, #0 <== NOT EXECUTED default: return EINVAL; } } a000abe4: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000a164 : pthread_t *thread, const pthread_attr_t *attr, void *(*start_routine)( void * ), void *arg ) { a000a164: 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 ) a000a168: e3520000 cmp r2, #0 pthread_t *thread, const pthread_attr_t *attr, void *(*start_routine)( void * ), void *arg ) { a000a16c: e24dd04c sub sp, sp, #76 ; 0x4c a000a170: e58d001c str r0, [sp, #28] a000a174: e58d3024 str r3, [sp, #36] ; 0x24 int schedpolicy = SCHED_RR; struct sched_param schedparam; Objects_Name name; int rc; if ( !start_routine ) a000a178: e58d2020 str r2, [sp, #32] return EFAULT; a000a17c: 03a0400e moveq r4, #14 int schedpolicy = SCHED_RR; struct sched_param schedparam; Objects_Name name; int rc; if ( !start_routine ) a000a180: 0a000082 beq a000a390 return EFAULT; the_attr = (attr) ? attr : &_POSIX_Threads_Default_attributes; a000a184: e59f5210 ldr r5, [pc, #528] ; a000a39c a000a188: e3510000 cmp r1, #0 a000a18c: 11a05001 movne r5, r1 if ( !the_attr->is_initialized ) a000a190: e5953000 ldr r3, [r5] a000a194: e3530000 cmp r3, #0 a000a198: 0a00007b beq a000a38c * 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) ) a000a19c: e5953004 ldr r3, [r5, #4] a000a1a0: e3530000 cmp r3, #0 a000a1a4: 0a000004 beq a000a1bc a000a1a8: e59f31f0 ldr r3, [pc, #496] ; a000a3a0 a000a1ac: e5952008 ldr r2, [r5, #8] a000a1b0: e5933000 ldr r3, [r3] a000a1b4: e1520003 cmp r2, r3 a000a1b8: 3a000073 bcc a000a38c * 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 ) { a000a1bc: e5953010 ldr r3, [r5, #16] a000a1c0: e3530001 cmp r3, #1 a000a1c4: 0a000002 beq a000a1d4 a000a1c8: e3530002 cmp r3, #2 a000a1cc: 1a00006e bne a000a38c a000a1d0: ea000006 b a000a1f0 case PTHREAD_INHERIT_SCHED: api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; a000a1d4: e59f31c8 ldr r3, [pc, #456] ; a000a3a4 schedpolicy = api->schedpolicy; schedparam = api->schedparam; a000a1d8: 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 ]; a000a1dc: e5933008 ldr r3, [r3, #8] a000a1e0: e59340f4 ldr r4, [r3, #244] ; 0xf4 schedpolicy = api->schedpolicy; a000a1e4: e594a084 ldr sl, [r4, #132] ; 0x84 schedparam = api->schedparam; a000a1e8: e2844088 add r4, r4, #136 ; 0x88 a000a1ec: ea000002 b a000a1fc break; case PTHREAD_EXPLICIT_SCHED: schedpolicy = the_attr->schedpolicy; a000a1f0: e595a014 ldr sl, [r5, #20] schedparam = the_attr->schedparam; a000a1f4: e28dc028 add ip, sp, #40 ; 0x28 a000a1f8: e2854018 add r4, r5, #24 a000a1fc: e8b4000f ldm r4!, {r0, r1, r2, r3} a000a200: 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 ) a000a204: e595300c ldr r3, [r5, #12] schedparam = api->schedparam; break; case PTHREAD_EXPLICIT_SCHED: schedpolicy = the_attr->schedpolicy; schedparam = the_attr->schedparam; a000a208: e8940007 ldm r4, {r0, r1, r2} a000a20c: 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 ) a000a210: e3530000 cmp r3, #0 return ENOTSUP; a000a214: 13a04086 movne r4, #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 ) a000a218: 1a00005c bne a000a390 return ENOTSUP; /* * Interpret the scheduling parameters. */ if ( !_POSIX_Priority_Is_valid( schedparam.sched_priority ) ) a000a21c: e59d0028 ldr r0, [sp, #40] ; 0x28 a000a220: eb00178a bl a0010050 <_POSIX_Priority_Is_valid> a000a224: e3500000 cmp r0, #0 a000a228: 0a000057 beq a000a38c return EINVAL; core_priority = _POSIX_Priority_To_core( schedparam.sched_priority ); a000a22c: e28d804c add r8, sp, #76 ; 0x4c a000a230: 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); a000a234: e59f316c ldr r3, [pc, #364] ; a000a3a8 /* * Set the core scheduling policy information. */ rc = _POSIX_Thread_Translate_sched_param( a000a238: e1a0000a mov r0, sl a000a23c: e1a01008 mov r1, r8 a000a240: e5d39000 ldrb r9, [r3] a000a244: e28d2044 add r2, sp, #68 ; 0x44 a000a248: e28d3048 add r3, sp, #72 ; 0x48 a000a24c: eb00178a bl a001007c <_POSIX_Thread_Translate_sched_param> schedpolicy, &schedparam, &budget_algorithm, &budget_callout ); if ( rc ) a000a250: e2504000 subs r4, r0, #0 a000a254: 1a00004d bne a000a390 #endif /* * Lock the allocator mutex for protection */ _RTEMS_Lock_allocator(); a000a258: e59f614c ldr r6, [pc, #332] ; a000a3ac a000a25c: e5960000 ldr r0, [r6] a000a260: eb0005ea bl a000ba10 <_API_Mutex_Lock> * _POSIX_Threads_Allocate */ RTEMS_INLINE_ROUTINE Thread_Control *_POSIX_Threads_Allocate( void ) { return (Thread_Control *) _Objects_Allocate( &_POSIX_Threads_Information ); a000a264: e59f0144 ldr r0, [pc, #324] ; a000a3b0 a000a268: eb00087d bl a000c464 <_Objects_Allocate> * Allocate the thread control block. * * NOTE: Global threads are not currently supported. */ the_thread = _POSIX_Threads_Allocate(); if ( !the_thread ) { a000a26c: e2507000 subs r7, r0, #0 a000a270: 0a000019 beq a000a2dc /* * Initialize the core thread for this task. */ name.name_p = NULL; /* posix threads don't have a name by default */ status = _Thread_Initialize( a000a274: e59d2044 ldr r2, [sp, #68] ; 0x44 static inline size_t _POSIX_Threads_Ensure_minimum_stack ( size_t size ) { if ( size >= PTHREAD_MINIMUM_STACK_SIZE ) a000a278: e59f3120 ldr r3, [pc, #288] ; a000a3a0 /* * Initialize the core thread for this task. */ name.name_p = NULL; /* posix threads don't have a name by default */ status = _Thread_Initialize( a000a27c: e595c008 ldr ip, [r5, #8] a000a280: e06b9009 rsb r9, fp, r9 static inline size_t _POSIX_Threads_Ensure_minimum_stack ( size_t size ) { if ( size >= PTHREAD_MINIMUM_STACK_SIZE ) a000a284: 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( a000a288: e58d200c str r2, [sp, #12] a000a28c: e59d2048 ldr r2, [sp, #72] ; 0x48 a000a290: e58d9004 str r9, [sp, #4] a000a294: e3a09001 mov r9, #1 a000a298: e58d4000 str r4, [sp] a000a29c: e58d9008 str r9, [sp, #8] a000a2a0: e58d2010 str r2, [sp, #16] a000a2a4: e58d4014 str r4, [sp, #20] a000a2a8: e58d4018 str r4, [sp, #24] static inline size_t _POSIX_Threads_Ensure_minimum_stack ( size_t size ) { if ( size >= PTHREAD_MINIMUM_STACK_SIZE ) a000a2ac: 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( a000a2b0: e153000c cmp r3, ip a000a2b4: 31a0300c movcc r3, ip a000a2b8: e59f00f0 ldr r0, [pc, #240] ; a000a3b0 a000a2bc: e1a01007 mov r1, r7 a000a2c0: e5952004 ldr r2, [r5, #4] a000a2c4: eb000d29 bl a000d770 <_Thread_Initialize> budget_callout, 0, /* isr level */ name /* posix threads don't have a name */ ); if ( !status ) { a000a2c8: e3500000 cmp r0, #0 a000a2cc: 1a000006 bne a000a2ec RTEMS_INLINE_ROUTINE void _POSIX_Threads_Free ( Thread_Control *the_pthread ) { _Objects_Free( &_POSIX_Threads_Information, &the_pthread->Object ); a000a2d0: e59f00d8 ldr r0, [pc, #216] ; a000a3b0 a000a2d4: e1a01007 mov r1, r7 a000a2d8: eb000930 bl a000c7a0 <_Objects_Free> _POSIX_Threads_Free( the_thread ); _RTEMS_Unlock_allocator(); a000a2dc: e5960000 ldr r0, [r6] a000a2e0: eb0005e3 bl a000ba74 <_API_Mutex_Unlock> return EAGAIN; a000a2e4: e3a0400b mov r4, #11 a000a2e8: ea000028 b a000a390 } /* * finish initializing the per API structure */ api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a000a2ec: e59760f4 ldr r6, [r7, #244] ; 0xf4 api->Attributes = *the_attr; a000a2f0: e1a0e005 mov lr, r5 a000a2f4: e8be000f ldm lr!, {r0, r1, r2, r3} a000a2f8: e1a0c006 mov ip, r6 a000a2fc: e8ac000f stmia ip!, {r0, r1, r2, r3} a000a300: e8be000f ldm lr!, {r0, r1, r2, r3} a000a304: e8ac000f stmia ip!, {r0, r1, r2, r3} a000a308: e8be000f ldm lr!, {r0, r1, r2, r3} a000a30c: e8ac000f stmia ip!, {r0, r1, r2, r3} a000a310: e89e000f ldm lr, {r0, r1, r2, r3} a000a314: e88c000f stm ip, {r0, r1, r2, r3} api->detachstate = the_attr->detachstate; a000a318: e595303c ldr r3, [r5, #60] ; 0x3c api->schedpolicy = schedpolicy; api->schedparam = schedparam; a000a31c: 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; a000a320: e5863040 str r3, [r6, #64] ; 0x40 api->schedpolicy = schedpolicy; api->schedparam = schedparam; a000a324: e8b8000f ldm r8!, {r0, r1, r2, r3} a000a328: e8ac000f stmia ip!, {r0, r1, r2, r3} a000a32c: 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; a000a330: e586a084 str sl, [r6, #132] ; 0x84 api->schedparam = schedparam; a000a334: e88c0007 stm ip, {r0, r1, r2} /* * POSIX threads are allocated and started in one operation. */ status = _Thread_Start( a000a338: e59d3024 ldr r3, [sp, #36] ; 0x24 a000a33c: e1a00007 mov r0, r7 a000a340: e1a01009 mov r1, r9 a000a344: e59d2020 ldr r2, [sp, #32] a000a348: e58d4000 str r4, [sp] a000a34c: eb000f33 bl a000e020 <_Thread_Start> _RTEMS_Unlock_allocator(); return EINVAL; } #endif if ( schedpolicy == SCHED_SPORADIC ) { a000a350: e35a0004 cmp sl, #4 a000a354: 1a000005 bne a000a370 _Watchdog_Insert_ticks( a000a358: e2860090 add r0, r6, #144 ; 0x90 <== NOT EXECUTED a000a35c: eb000f56 bl a000e0bc <_Timespec_To_ticks> <== NOT EXECUTED ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a000a360: e28610a8 add r1, r6, #168 ; 0xa8 <== NOT EXECUTED Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a000a364: e58600b4 str r0, [r6, #180] ; 0xb4 <== NOT EXECUTED _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a000a368: e59f0044 ldr r0, [pc, #68] ; a000a3b4 <== NOT EXECUTED a000a36c: eb000ff1 bl a000e338 <_Watchdog_Insert> <== NOT EXECUTED } /* * Return the id and indicate we successfully created the thread */ *thread = the_thread->Object.id; a000a370: e5973008 ldr r3, [r7, #8] a000a374: e59d201c ldr r2, [sp, #28] a000a378: e5823000 str r3, [r2] _RTEMS_Unlock_allocator(); a000a37c: e59f3028 ldr r3, [pc, #40] ; a000a3ac a000a380: e5930000 ldr r0, [r3] a000a384: eb0005ba bl a000ba74 <_API_Mutex_Unlock> return 0; a000a388: ea000000 b a000a390 /* * Interpret the scheduling parameters. */ if ( !_POSIX_Priority_Is_valid( schedparam.sched_priority ) ) return EINVAL; a000a38c: e3a04016 mov r4, #22 <== NOT EXECUTED */ *thread = the_thread->Object.id; _RTEMS_Unlock_allocator(); return 0; } a000a390: e1a00004 mov r0, r4 a000a394: e28dd04c add sp, sp, #76 ; 0x4c a000a398: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} =============================================================================== a0009d68 : int pthread_getcpuclockid( pthread_t pid, clockid_t *clock_id ) { a0009d68: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009d6c: eb002093 bl a0011fc0 <__errno> <== NOT EXECUTED a0009d70: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009d74: e5803000 str r3, [r0] <== NOT EXECUTED } a0009d78: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009d7c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000ec90 : int pthread_join( pthread_t thread, void **value_ptr ) { a000ec90: e92d40f3 push {r0, r1, r4, r5, r6, r7, lr} RTEMS_INLINE_ROUTINE bool _Thread_Is_executing ( const Thread_Control *the_thread ) { return ( the_thread == _Thread_Executing ); a000ec94: e59f60cc ldr r6, [pc, #204] ; a000ed68 /* * Put ourself on the threads join list */ if ( the_thread->current_state == a000ec98: e59f50cc ldr r5, [pc, #204] ; a000ed6c int pthread_join( pthread_t thread, void **value_ptr ) { a000ec9c: e1a07000 mov r7, r0 a000eca0: e1a04001 mov r4, r1 POSIX_API_Control *api; Objects_Locations location; void *return_pointer; on_EINTR: the_thread = _Thread_Get( thread, &location ); a000eca4: e1a0100d mov r1, sp a000eca8: e1a00007 mov r0, r7 a000ecac: eb000c5a bl a0011e1c <_Thread_Get> switch ( location ) { a000ecb0: e59d1000 ldr r1, [sp] a000ecb4: e3510000 cmp r1, #0 a000ecb8: 1a000026 bne a000ed58 case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a000ecbc: e59020f4 ldr r2, [r0, #244] ; 0xf4 if ( api->detachstate == PTHREAD_CREATE_DETACHED ) { a000ecc0: e592c040 ldr ip, [r2, #64] ; 0x40 a000ecc4: e35c0000 cmp ip, #0 a000ecc8: 1a000002 bne a000ecd8 _Thread_Enable_dispatch(); a000eccc: eb000c4a bl a0011dfc <_Thread_Enable_dispatch> return EINVAL; a000ecd0: e3a00016 mov r0, #22 a000ecd4: ea000022 b a000ed64 a000ecd8: e596c008 ldr ip, [r6, #8] } if ( _Thread_Is_executing( the_thread ) ) { a000ecdc: e150000c cmp r0, ip a000ece0: 1a000002 bne a000ecf0 _Thread_Enable_dispatch(); a000ece4: eb000c44 bl a0011dfc <_Thread_Enable_dispatch> <== NOT EXECUTED return EDEADLK; a000ece8: e3a0002d mov r0, #45 ; 0x2d <== NOT EXECUTED a000ecec: ea00001c b a000ed64 <== NOT EXECUTED /* * Put ourself on the threads join list */ if ( the_thread->current_state == a000ecf0: e590e010 ldr lr, [r0, #16] a000ecf4: e15e0005 cmp lr, r5 a000ecf8: 1a000004 bne a000ed10 (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT) ) { return_pointer = the_thread->Wait.return_argument; a000ecfc: e5903028 ldr r3, [r0, #40] ; 0x28 <== NOT EXECUTED _Thread_Clear_state( a000ed00: e1a01005 mov r1, r5 <== NOT EXECUTED * Put ourself on the threads join list */ if ( the_thread->current_state == (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT) ) { return_pointer = the_thread->Wait.return_argument; a000ed04: e58d3004 str r3, [sp, #4] <== NOT EXECUTED _Thread_Clear_state( a000ed08: eb000b5e bl a0011a88 <_Thread_Clear_state> <== NOT EXECUTED a000ed0c: ea000006 b a000ed2c <== NOT EXECUTED the_thread, (STATES_WAITING_FOR_JOIN_AT_EXIT | STATES_TRANSIENT) ); } else { _Thread_Executing->Wait.return_argument = &return_pointer; a000ed10: e28d3004 add r3, sp, #4 a000ed14: e58c3028 str r3, [ip, #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; a000ed18: e3a03001 mov r3, #1 a000ed1c: e5823074 str r3, [r2, #116] ; 0x74 _Thread_queue_Enter_critical_section( &api->Join_List ); _Thread_queue_Enqueue( &api->Join_List, WATCHDOG_NO_TIMEOUT ); a000ed20: e2820044 add r0, r2, #68 ; 0x44 a000ed24: e59f2044 ldr r2, [pc, #68] ; a000ed70 a000ed28: eb000d5e bl a00122a8 <_Thread_queue_Enqueue_with_handler> } _Thread_Enable_dispatch(); a000ed2c: eb000c32 bl a0011dfc <_Thread_Enable_dispatch> if ( _Thread_Executing->Wait.return_code == EINTR ) a000ed30: e5963008 ldr r3, [r6, #8] a000ed34: e5933034 ldr r3, [r3, #52] ; 0x34 a000ed38: e3530004 cmp r3, #4 a000ed3c: 0affffd8 beq a000eca4 goto on_EINTR; if ( value_ptr ) a000ed40: e3540000 cmp r4, #0 *value_ptr = return_pointer; a000ed44: 159d3004 ldrne r3, [sp, #4] return 0; a000ed48: 13a00000 movne r0, #0 if ( _Thread_Executing->Wait.return_code == EINTR ) goto on_EINTR; if ( value_ptr ) *value_ptr = return_pointer; a000ed4c: 15843000 strne r3, [r4] _Thread_Enable_dispatch(); if ( _Thread_Executing->Wait.return_code == EINTR ) goto on_EINTR; if ( value_ptr ) a000ed50: 1a000003 bne a000ed64 a000ed54: ea000001 b a000ed60 <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } return ESRCH; a000ed58: e3a00003 mov r0, #3 a000ed5c: ea000000 b a000ed64 if ( _Thread_Executing->Wait.return_code == EINTR ) goto on_EINTR; if ( value_ptr ) *value_ptr = return_pointer; return 0; a000ed60: e1a00004 mov r0, r4 <== NOT EXECUTED case OBJECTS_ERROR: break; } return ESRCH; } a000ed64: e8bd80fc pop {r2, r3, r4, r5, r6, r7, pc} =============================================================================== a001cf80 : int pthread_kill( pthread_t thread, int sig ) { a001cf80: e92d41f1 push {r0, r4, r5, r6, r7, r8, lr} POSIX_API_Control *api; Thread_Control *the_thread; Objects_Locations location; if ( !sig ) a001cf84: e2517000 subs r7, r1, #0 a001cf88: 0a000002 beq a001cf98 static inline bool is_valid_signo( int signo ) { return ((signo) >= 1 && (signo) <= 32 ); a001cf8c: e2478001 sub r8, r7, #1 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !is_valid_signo(sig) ) a001cf90: e358001f cmp r8, #31 a001cf94: 9a000002 bls a001cfa4 rtems_set_errno_and_return_minus_one( EINVAL ); a001cf98: ebffd25f bl a001191c <__errno> <== NOT EXECUTED a001cf9c: e3a03016 mov r3, #22 <== NOT EXECUTED a001cfa0: ea000025 b a001d03c <== NOT EXECUTED the_thread = _Thread_Get( thread, &location ); a001cfa4: e1a0100d mov r1, sp a001cfa8: ebffbe14 bl a000c800 <_Thread_Get> switch ( location ) { a001cfac: e59d6000 ldr r6, [sp] rtems_set_errno_and_return_minus_one( EINVAL ); if ( !is_valid_signo(sig) ) rtems_set_errno_and_return_minus_one( EINVAL ); the_thread = _Thread_Get( thread, &location ); a001cfb0: e1a04000 mov r4, r0 switch ( location ) { a001cfb4: e3560000 cmp r6, #0 a001cfb8: 1a00001d bne a001d034 a001cfbc: e59f0084 ldr r0, [pc, #132] ; a001d048 a001cfc0: ebffb685 bl a000a9dc <_API_extensions_Add_post_switch> api = the_thread->API_Extensions[ THREAD_API_POSIX ]; if ( sig ) { if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN ) { a001cfc4: e59f2080 ldr r2, [pc, #128] ; a001d04c a001cfc8: e3a0100c mov r1, #12 * If sig == 0 then just validate arguments */ _POSIX_signals_Add_post_switch_extension(); api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a001cfcc: e59430f4 ldr r3, [r4, #244] ; 0xf4 if ( sig ) { if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN ) { a001cfd0: e0222791 mla r2, r1, r7, r2 a001cfd4: e5922008 ldr r2, [r2, #8] a001cfd8: e3520001 cmp r2, #1 a001cfdc: 1a000002 bne a001cfec _Thread_Enable_dispatch(); a001cfe0: ebffbdfe bl a000c7e0 <_Thread_Enable_dispatch> <== NOT EXECUTED return 0; a001cfe4: e1a00006 mov r0, r6 <== NOT EXECUTED a001cfe8: ea000015 b a001d044 <== NOT EXECUTED } /* XXX critical section */ api->signals_pending |= signo_to_mask( sig ); a001cfec: e59320d4 ldr r2, [r3, #212] ; 0xd4 static inline sigset_t signo_to_mask( uint32_t sig ) { return 1u << (sig - 1); a001cff0: e3a05001 mov r5, #1 (void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL ); a001cff4: e1a00004 mov r0, r4 return 0; } /* XXX critical section */ api->signals_pending |= signo_to_mask( sig ); a001cff8: e1828815 orr r8, r2, r5, lsl r8 (void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL ); a001cffc: e1a01007 mov r1, r7 return 0; } /* XXX critical section */ api->signals_pending |= signo_to_mask( sig ); a001d000: e58380d4 str r8, [r3, #212] ; 0xd4 (void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL ); a001d004: e1a02006 mov r2, r6 a001d008: ebffff90 bl a001ce50 <_POSIX_signals_Unblock_thread> if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) ) a001d00c: e59f303c ldr r3, [pc, #60] ; a001d050 a001d010: e5932000 ldr r2, [r3] a001d014: e3520000 cmp r2, #0 a001d018: 0a000002 beq a001d028 a001d01c: e5932008 ldr r2, [r3, #8] <== NOT EXECUTED a001d020: e1540002 cmp r4, r2 <== NOT EXECUTED _Thread_Dispatch_necessary = true; a001d024: 05c35004 strbeq r5, [r3, #4] <== NOT EXECUTED } _Thread_Enable_dispatch(); a001d028: ebffbdec bl a000c7e0 <_Thread_Enable_dispatch> return 0; a001d02c: e3a00000 mov r0, #0 a001d030: ea000003 b a001d044 #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( ESRCH ); a001d034: ebffd238 bl a001191c <__errno> <== NOT EXECUTED a001d038: e3a03003 mov r3, #3 <== NOT EXECUTED a001d03c: e5803000 str r3, [r0] <== NOT EXECUTED a001d040: e3e00000 mvn r0, #0 <== NOT EXECUTED } a001d044: e8bd81f8 pop {r3, r4, r5, r6, r7, r8, pc} =============================================================================== a000bf18 : */ int pthread_mutex_destroy( pthread_mutex_t *mutex ) { a000bf18: e92d4031 push {r0, r4, r5, lr} register POSIX_Mutex_Control *the_mutex; Objects_Locations location; the_mutex = _POSIX_Mutex_Get( mutex, &location ); a000bf1c: e1a0100d mov r1, sp a000bf20: eb000018 bl a000bf88 <_POSIX_Mutex_Get> switch ( location ) { a000bf24: e59d5000 ldr r5, [sp] ) { register POSIX_Mutex_Control *the_mutex; Objects_Locations location; the_mutex = _POSIX_Mutex_Get( mutex, &location ); a000bf28: e1a04000 mov r4, r0 switch ( location ) { a000bf2c: e3550000 cmp r5, #0 #endif case OBJECTS_ERROR: break; } return EINVAL; a000bf30: 13a00016 movne r0, #22 { register POSIX_Mutex_Control *the_mutex; Objects_Locations location; the_mutex = _POSIX_Mutex_Get( mutex, &location ); switch ( location ) { a000bf34: 1a000011 bne a000bf80 /* * 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 ) ) { a000bf38: e5943064 ldr r3, [r4, #100] ; 0x64 a000bf3c: e3530000 cmp r3, #0 a000bf40: 1a000002 bne a000bf50 _Thread_Enable_dispatch(); a000bf44: eb000e85 bl a000f960 <_Thread_Enable_dispatch> <== NOT EXECUTED return EBUSY; a000bf48: e3a00010 mov r0, #16 <== NOT EXECUTED a000bf4c: ea00000b b a000bf80 <== NOT EXECUTED } _Objects_Close( &_POSIX_Mutex_Information, &the_mutex->Object ); a000bf50: e59f002c ldr r0, [pc, #44] ; a000bf84 a000bf54: e1a01004 mov r1, r4 a000bf58: eb000a0c bl a000e790 <_Objects_Close> _CORE_mutex_Flush( &the_mutex->Mutex, NULL, EINVAL ); a000bf5c: e3a02016 mov r2, #22 a000bf60: e2840014 add r0, r4, #20 a000bf64: e1a01005 mov r1, r5 a000bf68: eb000774 bl a000dd40 <_CORE_mutex_Flush> RTEMS_INLINE_ROUTINE void _POSIX_Mutex_Free ( POSIX_Mutex_Control *the_mutex ) { _Objects_Free( &_POSIX_Mutex_Information, &the_mutex->Object ); a000bf6c: e59f0010 ldr r0, [pc, #16] ; a000bf84 a000bf70: e1a01004 mov r1, r4 a000bf74: eb000ab2 bl a000ea44 <_Objects_Free> _POSIX_Mutex_Free( the_mutex ); _Thread_Enable_dispatch(); a000bf78: eb000e78 bl a000f960 <_Thread_Enable_dispatch> return 0; a000bf7c: e1a00005 mov r0, r5 case OBJECTS_ERROR: break; } return EINVAL; } a000bf80: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000c0a4 : 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; a000c0a4: e59f3130 ldr r3, [pc, #304] ; a000c1dc a000c0a8: e3510000 cmp r1, #0 int pthread_mutex_init( pthread_mutex_t *mutex, const pthread_mutexattr_t *attr ) { a000c0ac: e92d41f0 push {r4, r5, r6, r7, r8, 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; a000c0b0: 11a07001 movne r7, r1 a000c0b4: 01a07003 moveq r7, r3 /* Check for NULL mutex */ if ( !mutex ) a000c0b8: e2506000 subs r6, r0, #0 a000c0bc: 0a000042 beq a000c1cc } } } #endif if ( !the_attr->is_initialized ) a000c0c0: e5973000 ldr r3, [r7] a000c0c4: e3530000 cmp r3, #0 a000c0c8: 0a00003f beq a000c1cc return EINVAL; /* * We only support process private mutexes. */ if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED ) a000c0cc: e5973004 ldr r3, [r7, #4] a000c0d0: e3530001 cmp r3, #1 a000c0d4: 0a00003a beq a000c1c4 return ENOSYS; if ( the_attr->process_shared != PTHREAD_PROCESS_PRIVATE ) a000c0d8: e3530000 cmp r3, #0 a000c0dc: 1a00003a bne a000c1cc return EINVAL; /* * Determine the discipline of the mutex */ switch ( the_attr->protocol ) { a000c0e0: e597800c ldr r8, [r7, #12] a000c0e4: e3580001 cmp r8, #1 a000c0e8: 0a000006 beq a000c108 a000c0ec: e3580002 cmp r8, #2 a000c0f0: 0a000002 beq a000c100 a000c0f4: e3580000 cmp r8, #0 a000c0f8: 1a000033 bne a000c1cc a000c0fc: ea000002 b a000c10c break; case PTHREAD_PRIO_INHERIT: the_discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; break; case PTHREAD_PRIO_PROTECT: the_discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING; a000c100: e3a08003 mov r8, #3 <== NOT EXECUTED break; a000c104: ea000000 b a000c10c <== 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; a000c108: e3a08002 mov r8, #2 <== NOT EXECUTED } /* * Validate the priority ceiling field -- should always be valid. */ if ( !_POSIX_Priority_Is_valid( the_attr->prio_ceiling ) ) a000c10c: e5970008 ldr r0, [r7, #8] a000c110: eb0000d1 bl a000c45c <_POSIX_Priority_Is_valid> a000c114: e3500000 cmp r0, #0 a000c118: 0a00002b beq a000c1cc #if defined(_UNIX98_THREAD_MUTEX_ATTRIBUTES) /* * Validate the mutex type and set appropriate SuperCore mutex * attributes. */ switch ( the_attr->type ) { a000c11c: e5973010 ldr r3, [r7, #16] a000c120: e3530003 cmp r3, #3 a000c124: 8a00002a bhi a000c1d4 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000c128: e59f30b0 ldr r3, [pc, #176] ; a000c1e0 a000c12c: e5932000 ldr r2, [r3] ++level; a000c130: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000c134: 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 ); a000c138: e59f50a4 ldr r5, [pc, #164] ; a000c1e4 a000c13c: e1a00005 mov r0, r5 a000c140: eb000970 bl a000e708 <_Objects_Allocate> */ _Thread_Disable_dispatch(); the_mutex = _POSIX_Mutex_Allocate(); if ( !the_mutex ) { a000c144: e2504000 subs r4, r0, #0 a000c148: 1a000002 bne a000c158 _Thread_Enable_dispatch(); a000c14c: eb000e03 bl a000f960 <_Thread_Enable_dispatch> return EAGAIN; a000c150: e3a0000b mov r0, #11 a000c154: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} } the_mutex->process_shared = the_attr->process_shared; a000c158: e5973004 ldr r3, [r7, #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; a000c15c: e3a02001 mov r2, #1 the_mutex_attr->discipline = the_discipline; /* * Must be initialized to unlocked. */ _CORE_mutex_Initialize( a000c160: e2840014 add r0, r4, #20 if ( !the_mutex ) { _Thread_Enable_dispatch(); return EAGAIN; } the_mutex->process_shared = the_attr->process_shared; a000c164: e5843010 str r3, [r4, #16] the_mutex_attr = &the_mutex->Mutex.Attributes; if ( the_attr->recursive ) the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES; a000c168: e5973014 ldr r3, [r7, #20] else the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR; the_mutex_attr->only_owner_release = true; a000c16c: 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 ) the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES; a000c170: e2733001 rsbs r3, r3, #1 a000c174: 33a03000 movcc r3, #0 if ( !the_mutex ) { _Thread_Enable_dispatch(); return EAGAIN; } the_mutex->process_shared = the_attr->process_shared; a000c178: 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); a000c17c: e59f3064 ldr r3, [pc, #100] ; a000c1e8 a000c180: e5d31000 ldrb r1, [r3] a000c184: e5973008 ldr r3, [r7, #8] else the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR; 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; a000c188: e584805c str r8, [r4, #92] ; 0x5c a000c18c: e0633001 rsb r3, r3, r1 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 = a000c190: e5843060 str r3, [r4, #96] ; 0x60 the_mutex_attr->discipline = the_discipline; /* * Must be initialized to unlocked. */ _CORE_mutex_Initialize( a000c194: e2841054 add r1, r4, #84 ; 0x54 a000c198: eb0006e9 bl a000dd44 <_CORE_mutex_Initialize> #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000c19c: e595201c ldr r2, [r5, #28] Objects_Information *information, Objects_Control *the_object, uint32_t name ) { _Objects_Set_local_object( a000c1a0: e5943008 ldr r3, [r4, #8] a000c1a4: e1d410b8 ldrh r1, [r4, #8] _Objects_Get_index( the_object->id ), the_object ); /* ASSERT: information->is_string == false */ the_object->name.name_u32 = name; a000c1a8: e3a05000 mov r5, #0 #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000c1ac: 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; a000c1b0: e584500c str r5, [r4, #12] CORE_MUTEX_UNLOCKED ); _Objects_Open_u32( &_POSIX_Mutex_Information, &the_mutex->Object, 0 ); *mutex = the_mutex->Object.id; a000c1b4: e5863000 str r3, [r6] _Thread_Enable_dispatch(); a000c1b8: eb000de8 bl a000f960 <_Thread_Enable_dispatch> return 0; a000c1bc: e1a00005 mov r0, r5 a000c1c0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} /* * We only support process private mutexes. */ if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED ) return ENOSYS; a000c1c4: e3a00058 mov r0, #88 ; 0x58 <== NOT EXECUTED a000c1c8: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED /* * Validate the priority ceiling field -- should always be valid. */ if ( !_POSIX_Priority_Is_valid( the_attr->prio_ceiling ) ) return EINVAL; a000c1cc: e3a00016 mov r0, #22 <== NOT EXECUTED a000c1d0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED case PTHREAD_MUTEX_ERRORCHECK: case PTHREAD_MUTEX_DEFAULT: break; default: return EINVAL; a000c1d4: e3a00016 mov r0, #22 <== NOT EXECUTED *mutex = the_mutex->Object.id; _Thread_Enable_dispatch(); return 0; } a000c1d8: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED =============================================================================== a000c258 : int pthread_mutex_setprioceiling( pthread_mutex_t *mutex, int prioceiling, int *old_ceiling ) { a000c258: e92d41f1 push {r0, r4, r5, r6, r7, r8, lr} register POSIX_Mutex_Control *the_mutex; Objects_Locations location; Priority_Control the_priority; if ( !old_ceiling ) a000c25c: e2528000 subs r8, r2, #0 int pthread_mutex_setprioceiling( pthread_mutex_t *mutex, int prioceiling, int *old_ceiling ) { a000c260: e1a04000 mov r4, r0 a000c264: e1a05001 mov r5, r1 register POSIX_Mutex_Control *the_mutex; Objects_Locations location; Priority_Control the_priority; if ( !old_ceiling ) a000c268: 0a00001b beq a000c2dc return EINVAL; if ( !_POSIX_Priority_Is_valid( prioceiling ) ) a000c26c: e1a00001 mov r0, r1 a000c270: eb000079 bl a000c45c <_POSIX_Priority_Is_valid> a000c274: e3500000 cmp r0, #0 a000c278: 0a000017 beq a000c2dc a000c27c: e59f6060 ldr r6, [pc, #96] ; a000c2e4 /* * Must acquire the mutex before we can change it's ceiling. * POSIX says block until we acquire it. */ (void) pthread_mutex_lock( mutex ); a000c280: e1a00004 mov r0, r4 a000c284: e5d67000 ldrb r7, [r6] a000c288: ebffffd7 bl a000c1ec * 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 ); a000c28c: e1a00004 mov r0, r4 a000c290: e1a0100d mov r1, sp a000c294: ebffff3b bl a000bf88 <_POSIX_Mutex_Get> switch ( location ) { a000c298: e59d4000 ldr r4, [sp] * 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 ); a000c29c: e1a03000 mov r3, r0 switch ( location ) { a000c2a0: e3540000 cmp r4, #0 a000c2a4: 1a00000c bne a000c2dc RTEMS_INLINE_ROUTINE int _POSIX_Priority_From_core( Priority_Control priority ) { return (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1); a000c2a8: e5902060 ldr r2, [r0, #96] ; 0x60 a000c2ac: e5d61000 ldrb r1, [r6] RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core( int priority ) { return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1); a000c2b0: e0655007 rsb r5, r5, r7 RTEMS_INLINE_ROUTINE int _POSIX_Priority_From_core( Priority_Control priority ) { return (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1); a000c2b4: e0622001 rsb r2, r2, r1 case OBJECTS_LOCAL: *old_ceiling = _POSIX_Priority_From_core( a000c2b8: e5882000 str r2, [r8] ); the_mutex->Mutex.Attributes.priority_ceiling = the_priority; /* * We are required to unlock the mutex before we return. */ _CORE_mutex_Surrender( a000c2bc: e5931008 ldr r1, [r3, #8] case OBJECTS_LOCAL: *old_ceiling = _POSIX_Priority_From_core( the_mutex->Mutex.Attributes.priority_ceiling ); the_mutex->Mutex.Attributes.priority_ceiling = the_priority; a000c2c0: e5805060 str r5, [r0, #96] ; 0x60 /* * We are required to unlock the mutex before we return. */ _CORE_mutex_Surrender( a000c2c4: e1a02004 mov r2, r4 a000c2c8: e2800014 add r0, r0, #20 a000c2cc: eb000720 bl a000df54 <_CORE_mutex_Surrender> &the_mutex->Mutex, the_mutex->Object.id, NULL ); _Thread_Enable_dispatch(); a000c2d0: eb000da2 bl a000f960 <_Thread_Enable_dispatch> return 0; a000c2d4: e1a00004 mov r0, r4 a000c2d8: ea000000 b a000c2e0 #endif case OBJECTS_ERROR: break; } return EINVAL; a000c2dc: e3a00016 mov r0, #22 <== NOT EXECUTED } a000c2e0: e8bd81f8 pop {r3, r4, r5, r6, r7, r8, pc} =============================================================================== a000c2e8 : */ int pthread_mutex_timedlock( pthread_mutex_t *mutex, const struct timespec *abstime ) { a000c2e8: e92d4071 push {r0, r4, r5, r6, lr} a000c2ec: e1a06000 mov r6, r0 * * 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 ); a000c2f0: e1a00001 mov r0, r1 a000c2f4: e1a0100d mov r1, sp a000c2f8: eb00002a bl a000c3a8 <_POSIX_Absolute_timeout_to_ticks> 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, a000c2fc: e2403003 sub r3, r0, #3 a000c300: e2735000 rsbs r5, r3, #0 a000c304: e0a55003 adc r5, r5, r3 a000c308: e1a04000 mov r4, r0 if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE ) do_wait = false; lock_status = _POSIX_Mutex_Lock_support( mutex, do_wait, ticks ); a000c30c: e1a01005 mov r1, r5 a000c310: e1a00006 mov r0, r6 a000c314: e59d2000 ldr r2, [sp] a000c318: ebffffb6 bl a000c1f8 <_POSIX_Mutex_Lock_support> * 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) ) { a000c31c: e3550000 cmp r5, #0 a000c320: 1a000008 bne a000c348 a000c324: e3500010 cmp r0, #16 a000c328: 1a000006 bne a000c348 if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID ) a000c32c: e3540000 cmp r4, #0 <== NOT EXECUTED return EINVAL; a000c330: 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 ) a000c334: 0a000003 beq a000c348 <== NOT EXECUTED return EINVAL; if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST || a000c338: e2444001 sub r4, r4, #1 <== NOT EXECUTED status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW ) return ETIMEDOUT; a000c33c: e3540001 cmp r4, #1 <== NOT EXECUTED a000c340: 83a00010 movhi r0, #16 <== NOT EXECUTED a000c344: 93a00074 movls r0, #116 ; 0x74 <== NOT EXECUTED } return lock_status; } a000c348: e8bd8078 pop {r3, r4, r5, r6, pc} =============================================================================== a000bd80 : */ int pthread_mutexattr_destroy( pthread_mutexattr_t *attr ) { if ( !attr || !attr->is_initialized ) a000bd80: e2503000 subs r3, r0, #0 <== NOT EXECUTED return EINVAL; a000bd84: 03a00016 moveq r0, #22 <== NOT EXECUTED */ int pthread_mutexattr_destroy( pthread_mutexattr_t *attr ) { if ( !attr || !attr->is_initialized ) a000bd88: 012fff1e bxeq lr <== NOT EXECUTED a000bd8c: e5932000 ldr r2, [r3] <== NOT EXECUTED a000bd90: e3520000 cmp r2, #0 <== NOT EXECUTED return EINVAL; attr->is_initialized = false; a000bd94: 13a00000 movne r0, #0 <== NOT EXECUTED a000bd98: 15830000 strne r0, [r3] <== NOT EXECUTED int pthread_mutexattr_destroy( pthread_mutexattr_t *attr ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000bd9c: 03a00016 moveq r0, #22 <== NOT EXECUTED attr->is_initialized = false; return 0; } a000bda0: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a0009908 : int pthread_mutexattr_gettype( const pthread_mutexattr_t *attr, int *type ) { if ( !attr ) a0009908: e3500000 cmp r0, #0 a000990c: 0a000008 beq a0009934 return EINVAL; if ( !attr->is_initialized ) a0009910: e5903000 ldr r3, [r0] a0009914: e3530000 cmp r3, #0 a0009918: 0a000005 beq a0009934 return EINVAL; if ( !type ) a000991c: e3510000 cmp r1, #0 return EINVAL; *type = attr->type; a0009920: 15903010 ldrne r3, [r0, #16] return 0; a0009924: 13a00000 movne r0, #0 return EINVAL; if ( !type ) return EINVAL; *type = attr->type; a0009928: 15813000 strne r3, [r1] return EINVAL; if ( !attr->is_initialized ) return EINVAL; if ( !type ) a000992c: 112fff1e bxne lr a0009930: ea000001 b a000993c <== NOT EXECUTED { if ( !attr ) return EINVAL; if ( !attr->is_initialized ) return EINVAL; a0009934: e3a00016 mov r0, #22 a0009938: e12fff1e bx lr if ( !type ) return EINVAL; a000993c: e3a00016 mov r0, #22 <== NOT EXECUTED *type = attr->type; return 0; } a0009940: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000be60 : int pthread_mutexattr_setprioceiling( pthread_mutexattr_t *attr, int prioceiling ) { a000be60: e92d4030 push {r4, r5, lr} <== NOT EXECUTED if ( !attr || !attr->is_initialized ) a000be64: e2504000 subs r4, r0, #0 <== NOT EXECUTED int pthread_mutexattr_setprioceiling( pthread_mutexattr_t *attr, int prioceiling ) { a000be68: e1a05001 mov r5, r1 <== NOT EXECUTED if ( !attr || !attr->is_initialized ) a000be6c: 0a000009 beq a000be98 <== NOT EXECUTED a000be70: e5943000 ldr r3, [r4] <== NOT EXECUTED a000be74: e3530000 cmp r3, #0 <== NOT EXECUTED a000be78: 0a000006 beq a000be98 <== NOT EXECUTED return EINVAL; if ( !_POSIX_Priority_Is_valid( prioceiling ) ) a000be7c: e1a00001 mov r0, r1 <== NOT EXECUTED a000be80: eb000175 bl a000c45c <_POSIX_Priority_Is_valid> <== NOT EXECUTED a000be84: e3500000 cmp r0, #0 <== NOT EXECUTED a000be88: 0a000004 beq a000bea0 <== NOT EXECUTED return EINVAL; attr->prio_ceiling = prioceiling; a000be8c: e5845008 str r5, [r4, #8] <== NOT EXECUTED return 0; a000be90: e3a00000 mov r0, #0 <== NOT EXECUTED a000be94: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED pthread_mutexattr_t *attr, int prioceiling ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000be98: e3a00016 mov r0, #22 <== NOT EXECUTED a000be9c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED if ( !_POSIX_Priority_Is_valid( prioceiling ) ) return EINVAL; a000bea0: e3a00016 mov r0, #22 <== NOT EXECUTED attr->prio_ceiling = prioceiling; return 0; } a000bea4: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a000bea8 : int pthread_mutexattr_setprotocol( pthread_mutexattr_t *attr, int protocol ) { if ( !attr || !attr->is_initialized ) a000bea8: e3500000 cmp r0, #0 <== NOT EXECUTED a000beac: 0a000007 beq a000bed0 <== NOT EXECUTED a000beb0: e5903000 ldr r3, [r0] <== NOT EXECUTED a000beb4: e3530000 cmp r3, #0 <== NOT EXECUTED a000beb8: 0a000004 beq a000bed0 <== NOT EXECUTED return EINVAL; switch ( protocol ) { a000bebc: e3510002 cmp r1, #2 <== NOT EXECUTED case PTHREAD_PRIO_NONE: case PTHREAD_PRIO_INHERIT: case PTHREAD_PRIO_PROTECT: attr->protocol = protocol; a000bec0: 9580100c strls r1, [r0, #12] <== NOT EXECUTED return 0; a000bec4: 93a00000 movls r0, #0 <== NOT EXECUTED ) { if ( !attr || !attr->is_initialized ) return EINVAL; switch ( protocol ) { a000bec8: 912fff1e bxls lr <== NOT EXECUTED a000becc: ea000001 b a000bed8 <== NOT EXECUTED pthread_mutexattr_t *attr, int protocol ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000bed0: e3a00016 mov r0, #22 <== NOT EXECUTED a000bed4: e12fff1e bx lr <== NOT EXECUTED case PTHREAD_PRIO_PROTECT: attr->protocol = protocol; return 0; default: return EINVAL; a000bed8: e3a00016 mov r0, #22 <== NOT EXECUTED } } a000bedc: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000bee0 : int pthread_mutexattr_setpshared( pthread_mutexattr_t *attr, int pshared ) { if ( !attr || !attr->is_initialized ) a000bee0: e3500000 cmp r0, #0 <== NOT EXECUTED a000bee4: 0a000007 beq a000bf08 <== NOT EXECUTED a000bee8: e5903000 ldr r3, [r0] <== NOT EXECUTED a000beec: e3530000 cmp r3, #0 <== NOT EXECUTED a000bef0: 0a000004 beq a000bf08 <== NOT EXECUTED return EINVAL; switch ( pshared ) { a000bef4: e3510001 cmp r1, #1 <== NOT EXECUTED case PTHREAD_PROCESS_SHARED: case PTHREAD_PROCESS_PRIVATE: attr->process_shared = pshared; a000bef8: 95801004 strls r1, [r0, #4] <== NOT EXECUTED return 0; a000befc: 93a00000 movls r0, #0 <== NOT EXECUTED ) { if ( !attr || !attr->is_initialized ) return EINVAL; switch ( pshared ) { a000bf00: 912fff1e bxls lr <== NOT EXECUTED a000bf04: ea000001 b a000bf10 <== NOT EXECUTED pthread_mutexattr_t *attr, int pshared ) { if ( !attr || !attr->is_initialized ) return EINVAL; a000bf08: e3a00016 mov r0, #22 <== NOT EXECUTED a000bf0c: e12fff1e bx lr <== NOT EXECUTED case PTHREAD_PROCESS_PRIVATE: attr->process_shared = pshared; return 0; default: return EINVAL; a000bf10: e3a00016 mov r0, #22 <== NOT EXECUTED } } a000bf14: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000a808 : int pthread_once( pthread_once_t *once_control, void (*init_routine)(void) ) { if ( !once_control || !init_routine ) a000a808: e3500000 cmp r0, #0 <== NOT EXECUTED a000a80c: 13510000 cmpne r1, #0 <== NOT EXECUTED int pthread_once( pthread_once_t *once_control, void (*init_routine)(void) ) { a000a810: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED if ( !once_control || !init_routine ) a000a814: e1a04000 mov r4, r0 <== NOT EXECUTED a000a818: e1a05001 mov r5, r1 <== NOT EXECUTED a000a81c: 13a00000 movne r0, #0 <== NOT EXECUTED a000a820: 03a00001 moveq r0, #1 <== NOT EXECUTED return EINVAL; a000a824: 03a00016 moveq r0, #22 <== NOT EXECUTED int pthread_once( pthread_once_t *once_control, void (*init_routine)(void) ) { if ( !once_control || !init_routine ) a000a828: 0a000012 beq a000a878 <== NOT EXECUTED return EINVAL; if ( !once_control->init_executed ) { a000a82c: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED a000a830: e3530000 cmp r3, #0 <== NOT EXECUTED a000a834: 1a00000f bne a000a878 <== NOT EXECUTED rtems_mode saveMode; rtems_task_mode(RTEMS_NO_PREEMPT, RTEMS_PREEMPT_MASK, &saveMode); a000a838: e3a00c01 mov r0, #256 ; 0x100 <== NOT EXECUTED a000a83c: e1a01000 mov r1, r0 <== NOT EXECUTED a000a840: e1a0200d mov r2, sp <== NOT EXECUTED a000a844: eb0002d7 bl a000b3a8 <== NOT EXECUTED if ( !once_control->init_executed ) { a000a848: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED a000a84c: e3530000 cmp r3, #0 <== NOT EXECUTED a000a850: 1a000003 bne a000a864 <== NOT EXECUTED once_control->is_initialized = true; a000a854: e3a03001 mov r3, #1 <== NOT EXECUTED a000a858: e5843000 str r3, [r4] <== NOT EXECUTED once_control->init_executed = true; a000a85c: e5843004 str r3, [r4, #4] <== NOT EXECUTED (*init_routine)(); a000a860: e12fff35 blx r5 <== NOT EXECUTED } rtems_task_mode(saveMode, RTEMS_PREEMPT_MASK, &saveMode); a000a864: e59d0000 ldr r0, [sp] <== NOT EXECUTED a000a868: e3a01c01 mov r1, #256 ; 0x100 <== NOT EXECUTED a000a86c: e1a0200d mov r2, sp <== NOT EXECUTED a000a870: eb0002cc bl a000b3a8 <== NOT EXECUTED } return 0; a000a874: e3a00000 mov r0, #0 <== NOT EXECUTED } a000a878: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a000b1a8 : ) { POSIX_RWLock_Control *the_rwlock = NULL; Objects_Locations location; if ( !rwlock ) a000b1a8: e2503000 subs r3, r0, #0 * source of the error. */ int pthread_rwlock_destroy( pthread_rwlock_t *rwlock ) { a000b1ac: e92d4031 push {r0, r4, r5, lr} POSIX_RWLock_Control *the_rwlock = NULL; Objects_Locations location; if ( !rwlock ) a000b1b0: 0a000017 beq a000b214 RTEMS_INLINE_ROUTINE POSIX_RWLock_Control *_POSIX_RWLock_Get ( pthread_rwlock_t *RWLock, Objects_Locations *location ) { return (POSIX_RWLock_Control *) _Objects_Get( a000b1b4: e5931000 ldr r1, [r3] a000b1b8: e59f005c ldr r0, [pc, #92] ; a000b21c a000b1bc: e1a0200d mov r2, sp a000b1c0: eb000ae9 bl a000dd6c <_Objects_Get> return EINVAL; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { a000b1c4: e59d3000 ldr r3, [sp] a000b1c8: e1a04000 mov r4, r0 a000b1cc: e3530000 cmp r3, #0 a000b1d0: 1a00000f bne a000b214 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 ) { a000b1d4: e2800010 add r0, r0, #16 a000b1d8: eb001050 bl a000f320 <_Thread_queue_First> a000b1dc: e2505000 subs r5, r0, #0 a000b1e0: 0a000002 beq a000b1f0 _Thread_Enable_dispatch(); a000b1e4: eb000e4f bl a000eb28 <_Thread_Enable_dispatch> <== NOT EXECUTED return EBUSY; a000b1e8: e3a00010 mov r0, #16 <== NOT EXECUTED a000b1ec: ea000009 b a000b218 <== NOT EXECUTED /* * POSIX doesn't require behavior when it is locked. */ _Objects_Close( &_POSIX_RWLock_Information, &the_rwlock->Object ); a000b1f0: e59f0024 ldr r0, [pc, #36] ; a000b21c a000b1f4: e1a01004 mov r1, r4 a000b1f8: eb0009d6 bl a000d958 <_Objects_Close> */ RTEMS_INLINE_ROUTINE void _POSIX_RWLock_Free ( POSIX_RWLock_Control *the_RWLock ) { _Objects_Free( &_POSIX_RWLock_Information, &the_RWLock->Object ); a000b1fc: e59f0018 ldr r0, [pc, #24] ; a000b21c a000b200: e1a01004 mov r1, r4 a000b204: eb000a80 bl a000dc0c <_Objects_Free> _POSIX_RWLock_Free( the_rwlock ); _Thread_Enable_dispatch(); a000b208: eb000e46 bl a000eb28 <_Thread_Enable_dispatch> return 0; a000b20c: e1a00005 mov r0, r5 a000b210: ea000000 b a000b218 #endif case OBJECTS_ERROR: break; } return EINVAL; a000b214: e3a00016 mov r0, #22 <== NOT EXECUTED } a000b218: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000a770 : int pthread_rwlock_init( pthread_rwlock_t *rwlock, const pthread_rwlockattr_t *attr ) { a000a770: e92d40f7 push {r0, r1, r2, r4, r5, r6, r7, lr} const pthread_rwlockattr_t *the_attr; /* * Error check parameters */ if ( !rwlock ) a000a774: e2507000 subs r7, r0, #0 a000a778: 0a000023 beq a000a80c return EINVAL; /* * If the user passed in NULL, use the default attributes */ if ( attr ) { a000a77c: e3510000 cmp r1, #0 a000a780: 1a000002 bne a000a790 the_attr = attr; } else { (void) pthread_rwlockattr_init( &default_attr ); a000a784: e1a0000d mov r0, sp <== NOT EXECUTED a000a788: eb0001b4 bl a000ae60 <== NOT EXECUTED the_attr = &default_attr; a000a78c: e1a0100d mov r1, sp <== NOT EXECUTED } /* * Now start error checking the attributes that we are going to use */ if ( !the_attr->is_initialized ) a000a790: e5913000 ldr r3, [r1] a000a794: e3530000 cmp r3, #0 a000a798: 0a00001b beq a000a80c return EINVAL; switch ( the_attr->process_shared ) { a000a79c: e5915004 ldr r5, [r1, #4] a000a7a0: e3550000 cmp r5, #0 a000a7a4: 1a000018 bne a000a80c * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000a7a8: e59f3064 ldr r3, [pc, #100] ; a000a814 */ RTEMS_INLINE_ROUTINE void _CORE_RWLock_Initialize_attributes( CORE_RWLock_Attributes *the_attributes ) { the_attributes->XXX = 0; a000a7ac: e58d5008 str r5, [sp, #8] a000a7b0: e5932000 ldr r2, [r3] ++level; a000a7b4: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000a7b8: e5832000 str r2, [r3] * This function allocates a RWLock control block from * the inactive chain of free RWLock control blocks. */ RTEMS_INLINE_ROUTINE POSIX_RWLock_Control *_POSIX_RWLock_Allocate( void ) { return (POSIX_RWLock_Control *) a000a7bc: e59f6054 ldr r6, [pc, #84] ; a000a818 a000a7c0: e1a00006 mov r0, r6 a000a7c4: eb000a1d bl a000d040 <_Objects_Allocate> */ _Thread_Disable_dispatch(); /* prevents deletion */ the_rwlock = _POSIX_RWLock_Allocate(); if ( !the_rwlock ) { a000a7c8: e2504000 subs r4, r0, #0 a000a7cc: 1a000002 bne a000a7dc _Thread_Enable_dispatch(); a000a7d0: eb000ee9 bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED return EAGAIN; a000a7d4: e3a0000b mov r0, #11 <== NOT EXECUTED a000a7d8: ea00000c b a000a810 <== NOT EXECUTED } _CORE_RWLock_Initialize( &the_rwlock->RWLock, &the_attributes ); a000a7dc: e2840010 add r0, r4, #16 a000a7e0: e28d1008 add r1, sp, #8 a000a7e4: eb000889 bl a000ca10 <_CORE_RWLock_Initialize> #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a7e8: e596201c ldr r2, [r6, #28] Objects_Information *information, Objects_Control *the_object, uint32_t name ) { _Objects_Set_local_object( a000a7ec: e5943008 ldr r3, [r4, #8] a000a7f0: e1d410b8 ldrh r1, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a7f4: 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; a000a7f8: e584500c str r5, [r4, #12] &_POSIX_RWLock_Information, &the_rwlock->Object, 0 ); *rwlock = the_rwlock->Object.id; a000a7fc: e5873000 str r3, [r7] _Thread_Enable_dispatch(); a000a800: eb000edd bl a000e37c <_Thread_Enable_dispatch> return 0; a000a804: e1a00005 mov r0, r5 a000a808: ea000000 b a000a810 switch ( the_attr->process_shared ) { case PTHREAD_PROCESS_PRIVATE: /* only supported values */ break; case PTHREAD_PROCESS_SHARED: default: return EINVAL; a000a80c: e3a00016 mov r0, #22 <== NOT EXECUTED *rwlock = the_rwlock->Object.id; _Thread_Enable_dispatch(); return 0; } a000a810: e8bd80fe pop {r1, r2, r3, r4, r5, r6, r7, pc} =============================================================================== a000b2cc : */ int pthread_rwlock_rdlock( pthread_rwlock_t *rwlock ) { a000b2cc: e92d4013 push {r0, r1, r4, lr} POSIX_RWLock_Control *the_rwlock; Objects_Locations location; if ( !rwlock ) a000b2d0: e2504000 subs r4, r0, #0 a000b2d4: 0a000011 beq a000b320 RTEMS_INLINE_ROUTINE POSIX_RWLock_Control *_POSIX_RWLock_Get ( pthread_rwlock_t *RWLock, Objects_Locations *location ) { return (POSIX_RWLock_Control *) _Objects_Get( a000b2d8: e59f0048 ldr r0, [pc, #72] ; a000b328 a000b2dc: e5941000 ldr r1, [r4] a000b2e0: e28d2004 add r2, sp, #4 a000b2e4: eb000aa0 bl a000dd6c <_Objects_Get> return EINVAL; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { a000b2e8: e59d3004 ldr r3, [sp, #4] a000b2ec: e3530000 cmp r3, #0 a000b2f0: 1a00000a bne a000b320 case OBJECTS_LOCAL: _CORE_RWLock_Obtain_for_reading( a000b2f4: e58d3000 str r3, [sp] a000b2f8: e2800010 add r0, r0, #16 a000b2fc: e5941000 ldr r1, [r4] a000b300: e3a02001 mov r2, #1 a000b304: eb000747 bl a000d028 <_CORE_RWLock_Obtain_for_reading> true, /* we are willing to wait forever */ 0, NULL ); _Thread_Enable_dispatch(); a000b308: eb000e06 bl a000eb28 <_Thread_Enable_dispatch> return _POSIX_RWLock_Translate_core_RWLock_return_code( (CORE_RWLock_Status) _Thread_Executing->Wait.return_code a000b30c: e59f3018 ldr r3, [pc, #24] ; a000b32c a000b310: e5933008 ldr r3, [r3, #8] 0, NULL ); _Thread_Enable_dispatch(); return _POSIX_RWLock_Translate_core_RWLock_return_code( a000b314: e5930034 ldr r0, [r3, #52] ; 0x34 a000b318: eb00005e bl a000b498 <_POSIX_RWLock_Translate_core_RWLock_return_code> a000b31c: ea000000 b a000b324 #endif case OBJECTS_ERROR: break; } return EINVAL; a000b320: e3a00016 mov r0, #22 <== NOT EXECUTED } a000b324: e8bd801c pop {r2, r3, r4, pc} =============================================================================== a000b330 : int pthread_rwlock_timedrdlock( pthread_rwlock_t *rwlock, const struct timespec *abstime ) { a000b330: e92d4077 push {r0, r1, r2, r4, r5, r6, lr} Objects_Locations location; Watchdog_Interval ticks; bool do_wait = true; POSIX_Absolute_timeout_conversion_results_t status; if ( !rwlock ) a000b334: e2506000 subs r6, r0, #0 a000b338: 0a000025 beq a000b3d4 * * 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 ); a000b33c: e1a00001 mov r0, r1 a000b340: e28d1008 add r1, sp, #8 a000b344: eb00181f bl a00113c8 <_POSIX_Absolute_timeout_to_ticks> a000b348: e5961000 ldr r1, [r6] a000b34c: e1a04000 mov r4, r0 a000b350: e28d2004 add r2, sp, #4 a000b354: e59f0080 ldr r0, [pc, #128] ; a000b3dc a000b358: eb000a83 bl a000dd6c <_Objects_Get> if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE ) do_wait = false; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { a000b35c: e59d3004 ldr r3, [sp, #4] a000b360: e3530000 cmp r3, #0 a000b364: 1a00001a bne a000b3d4 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, a000b368: e2442003 sub r2, r4, #3 a000b36c: e2725000 rsbs r5, r2, #0 a000b370: e0a55002 adc r5, r5, r2 case OBJECTS_LOCAL: _CORE_RWLock_Obtain_for_reading( a000b374: e58d3000 str r3, [sp] a000b378: e2800010 add r0, r0, #16 a000b37c: e59d3008 ldr r3, [sp, #8] a000b380: e5961000 ldr r1, [r6] a000b384: e1a02005 mov r2, r5 a000b388: eb000726 bl a000d028 <_CORE_RWLock_Obtain_for_reading> do_wait, ticks, NULL ); _Thread_Enable_dispatch(); a000b38c: eb000de5 bl a000eb28 <_Thread_Enable_dispatch> if ( !do_wait ) { a000b390: e3550000 cmp r5, #0 a000b394: e59f3044 ldr r3, [pc, #68] ; a000b3e0 a000b398: 1a000009 bne a000b3c4 if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) { a000b39c: e5932008 ldr r2, [r3, #8] a000b3a0: e5922034 ldr r2, [r2, #52] ; 0x34 a000b3a4: e3520002 cmp r2, #2 a000b3a8: 1a000005 bne a000b3c4 if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID ) a000b3ac: e3540000 cmp r4, #0 <== NOT EXECUTED a000b3b0: 0a000007 beq a000b3d4 <== NOT EXECUTED return EINVAL; if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST || a000b3b4: e2444001 sub r4, r4, #1 <== NOT EXECUTED a000b3b8: e3540001 cmp r4, #1 <== NOT EXECUTED status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW ) return ETIMEDOUT; a000b3bc: 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 || a000b3c0: 9a000004 bls a000b3d8 <== NOT EXECUTED return ETIMEDOUT; } } return _POSIX_RWLock_Translate_core_RWLock_return_code( (CORE_RWLock_Status) _Thread_Executing->Wait.return_code a000b3c4: e5933008 ldr r3, [r3, #8] status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW ) return ETIMEDOUT; } } return _POSIX_RWLock_Translate_core_RWLock_return_code( a000b3c8: e5930034 ldr r0, [r3, #52] ; 0x34 a000b3cc: eb000031 bl a000b498 <_POSIX_RWLock_Translate_core_RWLock_return_code> a000b3d0: ea000000 b a000b3d8 _Thread_Enable_dispatch(); if ( !do_wait ) { if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) { if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID ) return EINVAL; a000b3d4: e3a00016 mov r0, #22 <== NOT EXECUTED case OBJECTS_ERROR: break; } return EINVAL; } a000b3d8: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc} =============================================================================== a000b3e4 : int pthread_rwlock_timedwrlock( pthread_rwlock_t *rwlock, const struct timespec *abstime ) { a000b3e4: e92d4077 push {r0, r1, r2, r4, r5, r6, lr} Objects_Locations location; Watchdog_Interval ticks; bool do_wait = true; POSIX_Absolute_timeout_conversion_results_t status; if ( !rwlock ) a000b3e8: e2506000 subs r6, r0, #0 a000b3ec: 0a000025 beq a000b488 * * 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 ); a000b3f0: e1a00001 mov r0, r1 a000b3f4: e28d1008 add r1, sp, #8 a000b3f8: eb0017f2 bl a00113c8 <_POSIX_Absolute_timeout_to_ticks> a000b3fc: e5961000 ldr r1, [r6] a000b400: e1a04000 mov r4, r0 a000b404: e28d2004 add r2, sp, #4 a000b408: e59f0080 ldr r0, [pc, #128] ; a000b490 a000b40c: eb000a56 bl a000dd6c <_Objects_Get> if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE ) do_wait = false; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { a000b410: e59d3004 ldr r3, [sp, #4] a000b414: e3530000 cmp r3, #0 a000b418: 1a00001a bne a000b488 (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, a000b41c: e2442003 sub r2, r4, #3 a000b420: e2725000 rsbs r5, r2, #0 a000b424: e0a55002 adc r5, r5, r2 case OBJECTS_LOCAL: _CORE_RWLock_Obtain_for_writing( a000b428: e58d3000 str r3, [sp] a000b42c: e2800010 add r0, r0, #16 a000b430: e59d3008 ldr r3, [sp, #8] a000b434: e5961000 ldr r1, [r6] a000b438: e1a02005 mov r2, r5 a000b43c: eb000728 bl a000d0e4 <_CORE_RWLock_Obtain_for_writing> do_wait, ticks, NULL ); _Thread_Enable_dispatch(); a000b440: eb000db8 bl a000eb28 <_Thread_Enable_dispatch> if ( !do_wait && a000b444: e3550000 cmp r5, #0 a000b448: e59f3044 ldr r3, [pc, #68] ; a000b494 a000b44c: 1a000009 bne a000b478 (_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) { a000b450: e5932008 ldr r2, [r3, #8] ticks, NULL ); _Thread_Enable_dispatch(); if ( !do_wait && a000b454: e5922034 ldr r2, [r2, #52] ; 0x34 a000b458: e3520002 cmp r2, #2 a000b45c: 1a000005 bne a000b478 (_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) { if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID ) a000b460: e3540000 cmp r4, #0 <== NOT EXECUTED a000b464: 0a000007 beq a000b488 <== NOT EXECUTED return EINVAL; if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST || a000b468: e2444001 sub r4, r4, #1 <== NOT EXECUTED a000b46c: e3540001 cmp r4, #1 <== NOT EXECUTED status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW ) return ETIMEDOUT; a000b470: 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 || a000b474: 9a000004 bls a000b48c <== 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 a000b478: e5933008 ldr r3, [r3, #8] if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST || status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW ) return ETIMEDOUT; } return _POSIX_RWLock_Translate_core_RWLock_return_code( a000b47c: e5930034 ldr r0, [r3, #52] ; 0x34 a000b480: eb000004 bl a000b498 <_POSIX_RWLock_Translate_core_RWLock_return_code> a000b484: ea000000 b a000b48c _Thread_Enable_dispatch(); if ( !do_wait && (_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) { if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID ) return EINVAL; a000b488: e3a00016 mov r0, #22 <== NOT EXECUTED case OBJECTS_ERROR: break; } return EINVAL; } a000b48c: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc} =============================================================================== a000b4a8 : */ int pthread_rwlock_tryrdlock( pthread_rwlock_t *rwlock ) { a000b4a8: e92d4013 push {r0, r1, r4, lr} POSIX_RWLock_Control *the_rwlock; Objects_Locations location; if ( !rwlock ) a000b4ac: e2504000 subs r4, r0, #0 a000b4b0: 0a000011 beq a000b4fc a000b4b4: e28d2004 add r2, sp, #4 a000b4b8: e59f0044 ldr r0, [pc, #68] ; a000b504 a000b4bc: e5941000 ldr r1, [r4] a000b4c0: eb000a29 bl a000dd6c <_Objects_Get> return EINVAL; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { a000b4c4: e59d2004 ldr r2, [sp, #4] a000b4c8: e3520000 cmp r2, #0 a000b4cc: 1a00000a bne a000b4fc case OBJECTS_LOCAL: _CORE_RWLock_Obtain_for_reading( a000b4d0: e58d2000 str r2, [sp] a000b4d4: e1a03002 mov r3, r2 a000b4d8: e2800010 add r0, r0, #16 a000b4dc: e5941000 ldr r1, [r4] a000b4e0: eb0006d0 bl a000d028 <_CORE_RWLock_Obtain_for_reading> 0, NULL ); _Thread_Enable_dispatch(); a000b4e4: eb000d8f bl a000eb28 <_Thread_Enable_dispatch> return _POSIX_RWLock_Translate_core_RWLock_return_code( (CORE_RWLock_Status) _Thread_Executing->Wait.return_code a000b4e8: e59f3018 ldr r3, [pc, #24] ; a000b508 a000b4ec: e5933008 ldr r3, [r3, #8] NULL ); _Thread_Enable_dispatch(); return _POSIX_RWLock_Translate_core_RWLock_return_code( a000b4f0: e5930034 ldr r0, [r3, #52] ; 0x34 a000b4f4: ebffffe7 bl a000b498 <_POSIX_RWLock_Translate_core_RWLock_return_code> a000b4f8: ea000000 b a000b500 #endif case OBJECTS_ERROR: break; } return EINVAL; a000b4fc: e3a00016 mov r0, #22 <== NOT EXECUTED } a000b500: e8bd801c pop {r2, r3, r4, pc} =============================================================================== a000b50c : */ int pthread_rwlock_trywrlock( pthread_rwlock_t *rwlock ) { a000b50c: e92d4013 push {r0, r1, r4, lr} POSIX_RWLock_Control *the_rwlock; Objects_Locations location; if ( !rwlock ) a000b510: e2504000 subs r4, r0, #0 a000b514: 0a000011 beq a000b560 a000b518: e28d2004 add r2, sp, #4 a000b51c: e59f0044 ldr r0, [pc, #68] ; a000b568 a000b520: e5941000 ldr r1, [r4] a000b524: eb000a10 bl a000dd6c <_Objects_Get> return EINVAL; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { a000b528: e59d2004 ldr r2, [sp, #4] a000b52c: e3520000 cmp r2, #0 a000b530: 1a00000a bne a000b560 case OBJECTS_LOCAL: _CORE_RWLock_Obtain_for_writing( a000b534: e58d2000 str r2, [sp] a000b538: e1a03002 mov r3, r2 a000b53c: e2800010 add r0, r0, #16 a000b540: e5941000 ldr r1, [r4] a000b544: eb0006e6 bl a000d0e4 <_CORE_RWLock_Obtain_for_writing> false, /* we are not willing to wait */ 0, NULL ); _Thread_Enable_dispatch(); a000b548: eb000d76 bl a000eb28 <_Thread_Enable_dispatch> return _POSIX_RWLock_Translate_core_RWLock_return_code( (CORE_RWLock_Status) _Thread_Executing->Wait.return_code a000b54c: e59f3018 ldr r3, [pc, #24] ; a000b56c a000b550: e5933008 ldr r3, [r3, #8] 0, NULL ); _Thread_Enable_dispatch(); return _POSIX_RWLock_Translate_core_RWLock_return_code( a000b554: e5930034 ldr r0, [r3, #52] ; 0x34 a000b558: ebffffce bl a000b498 <_POSIX_RWLock_Translate_core_RWLock_return_code> a000b55c: ea000000 b a000b564 #endif case OBJECTS_ERROR: break; } return EINVAL; a000b560: e3a00016 mov r0, #22 <== NOT EXECUTED } a000b564: e8bd801c pop {r2, r3, r4, pc} =============================================================================== a000b570 : { POSIX_RWLock_Control *the_rwlock; Objects_Locations location; CORE_RWLock_Status status; if ( !rwlock ) a000b570: e2503000 subs r3, r0, #0 */ int pthread_rwlock_unlock( pthread_rwlock_t *rwlock ) { a000b574: e92d4011 push {r0, r4, lr} POSIX_RWLock_Control *the_rwlock; Objects_Locations location; CORE_RWLock_Status status; if ( !rwlock ) a000b578: 0a00000d beq a000b5b4 a000b57c: e5931000 ldr r1, [r3] a000b580: e59f0034 ldr r0, [pc, #52] ; a000b5bc a000b584: e1a0200d mov r2, sp a000b588: eb0009f7 bl a000dd6c <_Objects_Get> return EINVAL; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { a000b58c: e59d3000 ldr r3, [sp] a000b590: e3530000 cmp r3, #0 a000b594: 1a000006 bne a000b5b4 case OBJECTS_LOCAL: status = _CORE_RWLock_Release( &the_rwlock->RWLock ); a000b598: e2800010 add r0, r0, #16 a000b59c: eb0006f3 bl a000d170 <_CORE_RWLock_Release> a000b5a0: e1a04000 mov r4, r0 _Thread_Enable_dispatch(); a000b5a4: eb000d5f bl a000eb28 <_Thread_Enable_dispatch> return _POSIX_RWLock_Translate_core_RWLock_return_code( status ); a000b5a8: e1a00004 mov r0, r4 a000b5ac: ebffffb9 bl a000b498 <_POSIX_RWLock_Translate_core_RWLock_return_code> a000b5b0: ea000000 b a000b5b8 #endif case OBJECTS_ERROR: break; } return EINVAL; a000b5b4: e3a00016 mov r0, #22 <== NOT EXECUTED } a000b5b8: e8bd8018 pop {r3, r4, pc} =============================================================================== a000b5c0 : */ int pthread_rwlock_wrlock( pthread_rwlock_t *rwlock ) { a000b5c0: e92d4013 push {r0, r1, r4, lr} POSIX_RWLock_Control *the_rwlock; Objects_Locations location; if ( !rwlock ) a000b5c4: e2504000 subs r4, r0, #0 a000b5c8: 0a000011 beq a000b614 a000b5cc: e59f0048 ldr r0, [pc, #72] ; a000b61c a000b5d0: e5941000 ldr r1, [r4] a000b5d4: e28d2004 add r2, sp, #4 a000b5d8: eb0009e3 bl a000dd6c <_Objects_Get> return EINVAL; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { a000b5dc: e59d3004 ldr r3, [sp, #4] a000b5e0: e3530000 cmp r3, #0 a000b5e4: 1a00000a bne a000b614 case OBJECTS_LOCAL: _CORE_RWLock_Obtain_for_writing( a000b5e8: e58d3000 str r3, [sp] a000b5ec: e2800010 add r0, r0, #16 a000b5f0: e5941000 ldr r1, [r4] a000b5f4: e3a02001 mov r2, #1 a000b5f8: eb0006b9 bl a000d0e4 <_CORE_RWLock_Obtain_for_writing> true, /* do not timeout -- wait forever */ 0, NULL ); _Thread_Enable_dispatch(); a000b5fc: eb000d49 bl a000eb28 <_Thread_Enable_dispatch> return _POSIX_RWLock_Translate_core_RWLock_return_code( (CORE_RWLock_Status) _Thread_Executing->Wait.return_code a000b600: e59f3018 ldr r3, [pc, #24] ; a000b620 a000b604: e5933008 ldr r3, [r3, #8] 0, NULL ); _Thread_Enable_dispatch(); return _POSIX_RWLock_Translate_core_RWLock_return_code( a000b608: e5930034 ldr r0, [r3, #52] ; 0x34 a000b60c: ebffffa1 bl a000b498 <_POSIX_RWLock_Translate_core_RWLock_return_code> a000b610: ea000000 b a000b618 #endif case OBJECTS_ERROR: break; } return EINVAL; a000b614: e3a00016 mov r0, #22 <== NOT EXECUTED } a000b618: e8bd801c pop {r2, r3, r4, pc} =============================================================================== a000bb80 : int pthread_rwlockattr_destroy( pthread_rwlockattr_t *attr ) { if ( !attr || attr->is_initialized == false ) a000bb80: e2503000 subs r3, r0, #0 return EINVAL; a000bb84: 03a00016 moveq r0, #22 int pthread_rwlockattr_destroy( pthread_rwlockattr_t *attr ) { if ( !attr || attr->is_initialized == false ) a000bb88: 012fff1e bxeq lr a000bb8c: e5932000 ldr r2, [r3] <== NOT EXECUTED a000bb90: e3520000 cmp r2, #0 <== NOT EXECUTED return EINVAL; attr->is_initialized = false; a000bb94: 13a00000 movne r0, #0 <== NOT EXECUTED a000bb98: 15830000 strne r0, [r3] <== NOT EXECUTED int pthread_rwlockattr_destroy( pthread_rwlockattr_t *attr ) { if ( !attr || attr->is_initialized == false ) return EINVAL; a000bb9c: 03a00016 moveq r0, #22 <== NOT EXECUTED attr->is_initialized = false; return 0; } a000bba0: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000bba4 : int pthread_rwlockattr_getpshared( const pthread_rwlockattr_t *attr, int *pshared ) { if ( !attr ) a000bba4: e3500000 cmp r0, #0 return EINVAL; a000bba8: 03a00016 moveq r0, #22 int pthread_rwlockattr_getpshared( const pthread_rwlockattr_t *attr, int *pshared ) { if ( !attr ) a000bbac: 012fff1e bxeq lr return EINVAL; if ( !attr->is_initialized ) a000bbb0: e5903000 ldr r3, [r0] <== NOT EXECUTED a000bbb4: e3530000 cmp r3, #0 <== NOT EXECUTED return EINVAL; *pshared = attr->process_shared; a000bbb8: 15903004 ldrne r3, [r0, #4] <== NOT EXECUTED { if ( !attr ) return EINVAL; if ( !attr->is_initialized ) return EINVAL; a000bbbc: 03a00016 moveq r0, #22 <== NOT EXECUTED *pshared = attr->process_shared; return 0; a000bbc0: 13a00000 movne r0, #0 <== NOT EXECUTED return EINVAL; if ( !attr->is_initialized ) return EINVAL; *pshared = attr->process_shared; a000bbc4: 15813000 strne r3, [r1] <== NOT EXECUTED return 0; } a000bbc8: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000bbe8 : int pthread_rwlockattr_setpshared( pthread_rwlockattr_t *attr, int pshared ) { if ( !attr ) a000bbe8: e3500000 cmp r0, #0 a000bbec: 0a000007 beq a000bc10 return EINVAL; if ( !attr->is_initialized ) a000bbf0: e5903000 ldr r3, [r0] <== NOT EXECUTED a000bbf4: e3530000 cmp r3, #0 <== NOT EXECUTED a000bbf8: 0a000004 beq a000bc10 <== NOT EXECUTED return EINVAL; switch ( pshared ) { a000bbfc: e3510001 cmp r1, #1 <== NOT EXECUTED case PTHREAD_PROCESS_SHARED: case PTHREAD_PROCESS_PRIVATE: attr->process_shared = pshared; a000bc00: 95801004 strls r1, [r0, #4] <== NOT EXECUTED return 0; a000bc04: 93a00000 movls r0, #0 <== NOT EXECUTED return EINVAL; if ( !attr->is_initialized ) return EINVAL; switch ( pshared ) { a000bc08: 912fff1e bxls lr <== NOT EXECUTED a000bc0c: ea000001 b a000bc18 <== NOT EXECUTED { if ( !attr ) return EINVAL; if ( !attr->is_initialized ) return EINVAL; a000bc10: e3a00016 mov r0, #22 a000bc14: e12fff1e bx lr case PTHREAD_PROCESS_PRIVATE: attr->process_shared = pshared; return 0; default: return EINVAL; a000bc18: e3a00016 mov r0, #22 <== NOT EXECUTED } } a000bc1c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a0009b44 : * 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() ) a0009b44: e59f3068 ldr r3, [pc, #104] ; a0009bb4 int pthread_setcancelstate( int state, int *oldstate ) { a0009b48: 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() ) a0009b4c: e5934000 ldr r4, [r3] a0009b50: e3540000 cmp r4, #0 a0009b54: 1a000010 bne a0009b9c return EPROTO; if ( !oldstate ) a0009b58: e3510000 cmp r1, #0 a0009b5c: 0a000010 beq a0009ba4 return EINVAL; if ( state != PTHREAD_CANCEL_ENABLE && state != PTHREAD_CANCEL_DISABLE ) a0009b60: e3500001 cmp r0, #1 a0009b64: 8a000010 bhi a0009bac * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0009b68: e59fc048 ldr ip, [pc, #72] ; a0009bb8 return EINVAL; thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; a0009b6c: e5932008 ldr r2, [r3, #8] a0009b70: e59ce000 ldr lr, [ip] a0009b74: e59220f4 ldr r2, [r2, #244] ; 0xf4 ++level; a0009b78: e28ee001 add lr, lr, #1 _Thread_Dispatch_disable_level = level; a0009b7c: e58ce000 str lr, [ip] _Thread_Disable_dispatch(); *oldstate = thread_support->cancelability_state; a0009b80: e592c0d8 ldr ip, [r2, #216] ; 0xd8 a0009b84: e581c000 str ip, [r1] thread_support->cancelability_state = state; a0009b88: e58200d8 str r0, [r2, #216] ; 0xd8 _POSIX_Thread_Evaluate_cancellation_and_enable_dispatch(_Thread_Executing); a0009b8c: e5930008 ldr r0, [r3, #8] a0009b90: eb001467 bl a000ed34 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch> /* * _Thread_Enable_dispatch is invoked by above call. */ return 0; a0009b94: e1a00004 mov r0, r4 a0009b98: 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; a0009b9c: e3a00047 mov r0, #71 ; 0x47 <== NOT EXECUTED a0009ba0: e8bd8010 pop {r4, pc} <== NOT EXECUTED if ( !oldstate ) return EINVAL; a0009ba4: e3a00016 mov r0, #22 a0009ba8: e8bd8010 pop {r4, pc} if ( state != PTHREAD_CANCEL_ENABLE && state != PTHREAD_CANCEL_DISABLE ) return EINVAL; a0009bac: e3a00016 mov r0, #22 /* * _Thread_Enable_dispatch is invoked by above call. */ return 0; } a0009bb0: e8bd8010 pop {r4, pc} =============================================================================== a0009bbc : * 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() ) a0009bbc: e59f3068 ldr r3, [pc, #104] ; a0009c2c int pthread_setcanceltype( int type, int *oldtype ) { a0009bc0: 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() ) a0009bc4: e5934000 ldr r4, [r3] a0009bc8: e3540000 cmp r4, #0 a0009bcc: 1a000010 bne a0009c14 return EPROTO; if ( !oldtype ) a0009bd0: e3510000 cmp r1, #0 a0009bd4: 0a000010 beq a0009c1c return EINVAL; if ( type != PTHREAD_CANCEL_DEFERRED && type != PTHREAD_CANCEL_ASYNCHRONOUS ) a0009bd8: e3500001 cmp r0, #1 a0009bdc: 8a000010 bhi a0009c24 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0009be0: e59fc048 ldr ip, [pc, #72] ; a0009c30 return EINVAL; thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; a0009be4: e5932008 ldr r2, [r3, #8] a0009be8: e59ce000 ldr lr, [ip] a0009bec: e59220f4 ldr r2, [r2, #244] ; 0xf4 ++level; a0009bf0: e28ee001 add lr, lr, #1 _Thread_Dispatch_disable_level = level; a0009bf4: e58ce000 str lr, [ip] _Thread_Disable_dispatch(); *oldtype = thread_support->cancelability_type; a0009bf8: e592c0dc ldr ip, [r2, #220] ; 0xdc a0009bfc: e581c000 str ip, [r1] thread_support->cancelability_type = type; a0009c00: e58200dc str r0, [r2, #220] ; 0xdc _POSIX_Thread_Evaluate_cancellation_and_enable_dispatch(_Thread_Executing); a0009c04: e5930008 ldr r0, [r3, #8] a0009c08: eb001449 bl a000ed34 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch> /* * _Thread_Enable_dispatch is invoked by above call. */ return 0; a0009c0c: e1a00004 mov r0, r4 a0009c10: 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; a0009c14: e3a00047 mov r0, #71 ; 0x47 <== NOT EXECUTED a0009c18: e8bd8010 pop {r4, pc} <== NOT EXECUTED if ( !oldtype ) return EINVAL; a0009c1c: e3a00016 mov r0, #22 a0009c20: e8bd8010 pop {r4, pc} if ( type != PTHREAD_CANCEL_DEFERRED && type != PTHREAD_CANCEL_ASYNCHRONOUS ) return EINVAL; a0009c24: e3a00016 mov r0, #22 /* * _Thread_Enable_dispatch is invoked by above call. */ return 0; } a0009c28: e8bd8010 pop {r4, pc} =============================================================================== a000cbb0 : int pthread_setschedparam( pthread_t thread, int policy, struct sched_param *param ) { a000cbb0: e92d41f7 push {r0, r1, r2, r4, r5, r6, r7, r8, lr} int rc; /* * Check all the parameters */ if ( !param ) a000cbb4: e2528000 subs r8, r2, #0 int pthread_setschedparam( pthread_t thread, int policy, struct sched_param *param ) { a000cbb8: e1a04000 mov r4, r0 a000cbbc: e1a06001 mov r6, r1 /* * Check all the parameters */ if ( !param ) return EINVAL; a000cbc0: 03a07016 moveq r7, #22 int rc; /* * Check all the parameters */ if ( !param ) a000cbc4: 0a000039 beq a000ccb0 return EINVAL; rc = _POSIX_Thread_Translate_sched_param( a000cbc8: e1a00001 mov r0, r1 a000cbcc: e1a0200d mov r2, sp a000cbd0: e1a01008 mov r1, r8 a000cbd4: e28d3004 add r3, sp, #4 a000cbd8: eb00160b bl a001240c <_POSIX_Thread_Translate_sched_param> policy, param, &budget_algorithm, &budget_callout ); if ( rc ) a000cbdc: e2507000 subs r7, r0, #0 a000cbe0: 1a000032 bne a000ccb0 return rc; /* * Actually change the scheduling policy and parameters */ the_thread = _Thread_Get( thread, &location ); a000cbe4: e1a00004 mov r0, r4 a000cbe8: e28d1008 add r1, sp, #8 a000cbec: eb000b63 bl a000f980 <_Thread_Get> switch ( location ) { a000cbf0: e59d3008 ldr r3, [sp, #8] return rc; /* * Actually change the scheduling policy and parameters */ the_thread = _Thread_Get( thread, &location ); a000cbf4: e1a05000 mov r5, r0 switch ( location ) { a000cbf8: e3530000 cmp r3, #0 #endif case OBJECTS_ERROR: break; } return ESRCH; a000cbfc: 13a07003 movne r7, #3 /* * Actually change the scheduling policy and parameters */ the_thread = _Thread_Get( thread, &location ); switch ( location ) { a000cc00: 1a00002a bne a000ccb0 case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a000cc04: e59040f4 ldr r4, [r0, #244] ; 0xf4 if ( api->schedpolicy == SCHED_SPORADIC ) a000cc08: e5943084 ldr r3, [r4, #132] ; 0x84 a000cc0c: e3530004 cmp r3, #4 a000cc10: 1a000001 bne a000cc1c (void) _Watchdog_Remove( &api->Sporadic_timer ); a000cc14: e28400a8 add r0, r4, #168 ; 0xa8 <== NOT EXECUTED a000cc18: eb000f0c bl a0010850 <_Watchdog_Remove> <== NOT EXECUTED api->schedpolicy = policy; a000cc1c: e5846084 str r6, [r4, #132] ; 0x84 api->schedparam = *param; a000cc20: e284c088 add ip, r4, #136 ; 0x88 a000cc24: e8b8000f ldm r8!, {r0, r1, r2, r3} a000cc28: e8ac000f stmia ip!, {r0, r1, r2, r3} the_thread->budget_algorithm = budget_algorithm; a000cc2c: e59d3000 ldr r3, [sp] if ( api->schedpolicy == SCHED_SPORADIC ) (void) _Watchdog_Remove( &api->Sporadic_timer ); api->schedpolicy = policy; api->schedparam = *param; a000cc30: e8980007 ldm r8, {r0, r1, r2} a000cc34: e88c0007 stm ip, {r0, r1, r2} the_thread->budget_algorithm = budget_algorithm; a000cc38: e5853078 str r3, [r5, #120] ; 0x78 the_thread->budget_callout = budget_callout; a000cc3c: e59d3004 ldr r3, [sp, #4] switch ( api->schedpolicy ) { a000cc40: 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; a000cc44: e585307c str r3, [r5, #124] ; 0x7c switch ( api->schedpolicy ) { a000cc48: ba000017 blt a000ccac a000cc4c: e3560002 cmp r6, #2 a000cc50: da000002 ble a000cc60 a000cc54: e3560004 cmp r6, #4 a000cc58: 1a000013 bne a000ccac a000cc5c: ea00000b b a000cc90 case SCHED_OTHER: case SCHED_FIFO: case SCHED_RR: the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice; a000cc60: e59f3050 ldr r3, [pc, #80] ; a000ccb8 the_thread->real_priority = _POSIX_Priority_To_core( api->schedparam.sched_priority ); _Thread_Change_priority( a000cc64: e1a00005 mov r0, r5 a000cc68: 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; a000cc6c: e5933000 ldr r3, [r3] a000cc70: e5853074 str r3, [r5, #116] ; 0x74 a000cc74: e59f3040 ldr r3, [pc, #64] ; a000ccbc a000cc78: e5d31000 ldrb r1, [r3] a000cc7c: e5943088 ldr r3, [r4, #136] ; 0x88 a000cc80: e0631001 rsb r1, r3, r1 the_thread->real_priority = a000cc84: e5851018 str r1, [r5, #24] _POSIX_Priority_To_core( api->schedparam.sched_priority ); _Thread_Change_priority( a000cc88: eb000a1b bl a000f4fc <_Thread_Change_priority> the_thread, the_thread->real_priority, true ); break; a000cc8c: ea000006 b a000ccac case SCHED_SPORADIC: api->ss_high_priority = api->schedparam.sched_priority; a000cc90: e5943088 ldr r3, [r4, #136] ; 0x88 _Watchdog_Remove( &api->Sporadic_timer ); a000cc94: e28400a8 add r0, r4, #168 ; 0xa8 true ); break; case SCHED_SPORADIC: api->ss_high_priority = api->schedparam.sched_priority; a000cc98: e58430a4 str r3, [r4, #164] ; 0xa4 _Watchdog_Remove( &api->Sporadic_timer ); a000cc9c: eb000eeb bl a0010850 <_Watchdog_Remove> _POSIX_Threads_Sporadic_budget_TSR( 0, the_thread ); a000cca0: e3a00000 mov r0, #0 a000cca4: e1a01005 mov r1, r5 a000cca8: ebffff79 bl a000ca94 <_POSIX_Threads_Sporadic_budget_TSR> break; } _Thread_Enable_dispatch(); a000ccac: eb000b2b bl a000f960 <_Thread_Enable_dispatch> case OBJECTS_ERROR: break; } return ESRCH; } a000ccb0: e1a00007 mov r0, r7 a000ccb4: e8bd81fe pop {r1, r2, r3, r4, r5, r6, r7, r8, pc} =============================================================================== a00104ec : sigset_t *oset ) { POSIX_API_Control *api; if ( !set && !oset ) a00104ec: e271c001 rsbs ip, r1, #1 a00104f0: 33a0c000 movcc ip, #0 a00104f4: e3520000 cmp r2, #0 a00104f8: 03510000 cmpeq r1, #0 int pthread_sigmask( int how, const sigset_t *set, sigset_t *oset ) { a00104fc: e92d4010 push {r4, lr} POSIX_API_Control *api; if ( !set && !oset ) a0010500: 0a00001f beq a0010584 rtems_set_errno_and_return_minus_one( EINVAL ); api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; a0010504: e59f30a0 ldr r3, [pc, #160] ; a00105ac if ( oset ) a0010508: 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 ]; a001050c: e5933008 ldr r3, [r3, #8] a0010510: e59330f4 ldr r3, [r3, #244] ; 0xf4 if ( oset ) *oset = api->signals_blocked; a0010514: 159340d0 ldrne r4, [r3, #208] ; 0xd0 a0010518: 15824000 strne r4, [r2] if ( !set ) a001051c: e35c0000 cmp ip, #0 a0010520: 1a00001f bne a00105a4 return 0; switch ( how ) { a0010524: e3500001 cmp r0, #1 a0010528: 0a000005 beq a0010544 a001052c: e3500002 cmp r0, #2 a0010530: 0a000007 beq a0010554 a0010534: e3500000 cmp r0, #0 <== NOT EXECUTED break; case SIG_UNBLOCK: api->signals_blocked &= ~*set; break; case SIG_SETMASK: api->signals_blocked = *set; a0010538: 05912000 ldreq r2, [r1] <== NOT EXECUTED *oset = api->signals_blocked; if ( !set ) return 0; switch ( how ) { a001053c: 0a000007 beq a0010560 <== NOT EXECUTED a0010540: ea00000f b a0010584 <== NOT EXECUTED case SIG_BLOCK: api->signals_blocked |= *set; a0010544: e59300d0 ldr r0, [r3, #208] ; 0xd0 a0010548: e5912000 ldr r2, [r1] a001054c: e1802002 orr r2, r0, r2 a0010550: ea000002 b a0010560 break; case SIG_UNBLOCK: api->signals_blocked &= ~*set; a0010554: e5911000 ldr r1, [r1] a0010558: e59320d0 ldr r2, [r3, #208] ; 0xd0 a001055c: e1c22001 bic r2, r2, r1 break; case SIG_SETMASK: api->signals_blocked = *set; a0010560: 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) ) { a0010564: e59f2044 ldr r2, [pc, #68] ; a00105b0 a0010568: e5920000 ldr r0, [r2] a001056c: e59320d4 ldr r2, [r3, #212] ; 0xd4 /* XXX are there critical section problems here? */ /* XXX evaluate the new set */ if ( ~api->signals_blocked & a0010570: e59330d0 ldr r3, [r3, #208] ; 0xd0 (api->signals_pending | _POSIX_signals_Pending) ) { a0010574: e1800002 orr r0, r0, r2 /* XXX are there critical section problems here? */ /* XXX evaluate the new set */ if ( ~api->signals_blocked & a0010578: e1d00003 bics r0, r0, r3 a001057c: 0a000009 beq a00105a8 a0010580: ea000004 b a0010598 break; case SIG_SETMASK: api->signals_blocked = *set; break; default: rtems_set_errno_and_return_minus_one( EINVAL ); a0010584: eb0008fc bl a001297c <__errno> <== NOT EXECUTED a0010588: e3a03016 mov r3, #22 <== NOT EXECUTED a001058c: e5803000 str r3, [r0] <== NOT EXECUTED a0010590: e3e00000 mvn r0, #0 <== NOT EXECUTED a0010594: e8bd8010 pop {r4, pc} <== NOT EXECUTED /* XXX evaluate the new set */ if ( ~api->signals_blocked & (api->signals_pending | _POSIX_signals_Pending) ) { _Thread_Dispatch(); a0010598: ebfff3c2 bl a000d4a8 <_Thread_Dispatch> } return 0; a001059c: e3a00000 mov r0, #0 a00105a0: e8bd8010 pop {r4, pc} if ( oset ) *oset = api->signals_blocked; if ( !set ) return 0; a00105a4: e3a00000 mov r0, #0 (api->signals_pending | _POSIX_signals_Pending) ) { _Thread_Dispatch(); } return 0; } a00105a8: e8bd8010 pop {r4, pc} =============================================================================== a000a12c : ) { POSIX_Spinlock_Control *the_spinlock = NULL; Objects_Locations location; if ( !spinlock ) a000a12c: e2503000 subs r3, r0, #0 <== NOT EXECUTED * source of the error. */ int pthread_spin_destroy( pthread_spinlock_t *spinlock ) { a000a130: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED POSIX_Spinlock_Control *the_spinlock = NULL; Objects_Locations location; if ( !spinlock ) a000a134: 0a000016 beq a000a194 <== NOT EXECUTED RTEMS_INLINE_ROUTINE POSIX_Spinlock_Control *_POSIX_Spinlock_Get ( pthread_spinlock_t *spinlock, Objects_Locations *location ) { return (POSIX_Spinlock_Control *) _Objects_Get( a000a138: e5931000 ldr r1, [r3] <== NOT EXECUTED a000a13c: e59f0058 ldr r0, [pc, #88] ; a000a19c <== NOT EXECUTED a000a140: e1a0200d mov r2, sp <== NOT EXECUTED a000a144: eb000872 bl a000c314 <_Objects_Get> <== NOT EXECUTED return EINVAL; the_spinlock = _POSIX_Spinlock_Get( spinlock, &location ); switch ( location ) { a000a148: e59d3000 ldr r3, [sp] <== NOT EXECUTED a000a14c: e1a04000 mov r4, r0 <== NOT EXECUTED a000a150: e3530000 cmp r3, #0 <== NOT EXECUTED a000a154: 1a00000e bne a000a194 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE bool _CORE_spinlock_Is_busy( CORE_spinlock_Control *the_spinlock ) { return (the_spinlock->users != 0); a000a158: e5905018 ldr r5, [r0, #24] <== NOT EXECUTED case OBJECTS_LOCAL: if ( _CORE_spinlock_Is_busy( &the_spinlock->Spinlock ) ) { a000a15c: e3550000 cmp r5, #0 <== NOT EXECUTED a000a160: 0a000002 beq a000a170 <== NOT EXECUTED _Thread_Enable_dispatch(); a000a164: eb000bd9 bl a000d0d0 <_Thread_Enable_dispatch> <== NOT EXECUTED return EBUSY; a000a168: e3a00010 mov r0, #16 <== NOT EXECUTED a000a16c: ea000009 b a000a198 <== NOT EXECUTED } _Objects_Close( &_POSIX_Spinlock_Information, &the_spinlock->Object ); a000a170: e59f0024 ldr r0, [pc, #36] ; a000a19c <== NOT EXECUTED a000a174: e1a01004 mov r1, r4 <== NOT EXECUTED a000a178: eb000760 bl a000bf00 <_Objects_Close> <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void _POSIX_Spinlock_Free ( POSIX_Spinlock_Control *the_spinlock ) { _Objects_Free( &_POSIX_Spinlock_Information, &the_spinlock->Object ); a000a17c: e59f0018 ldr r0, [pc, #24] ; a000a19c <== NOT EXECUTED a000a180: e1a01004 mov r1, r4 <== NOT EXECUTED a000a184: eb00080a bl a000c1b4 <_Objects_Free> <== NOT EXECUTED _POSIX_Spinlock_Free( the_spinlock ); _Thread_Enable_dispatch(); a000a188: eb000bd0 bl a000d0d0 <_Thread_Enable_dispatch> <== NOT EXECUTED return 0; a000a18c: e1a00005 mov r0, r5 <== NOT EXECUTED a000a190: ea000000 b a000a198 <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } return EINVAL; a000a194: e3a00016 mov r0, #22 <== NOT EXECUTED } a000a198: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a000a81c : int pthread_spin_init( pthread_spinlock_t *spinlock, int pshared ) { a000a81c: e92d40f1 push {r0, r4, r5, r6, r7, lr} POSIX_Spinlock_Control *the_spinlock; CORE_spinlock_Attributes attributes; if ( !spinlock ) a000a820: e2507000 subs r7, r0, #0 int pthread_spin_init( pthread_spinlock_t *spinlock, int pshared ) { a000a824: e1a05001 mov r5, r1 POSIX_Spinlock_Control *the_spinlock; CORE_spinlock_Attributes attributes; if ( !spinlock ) a000a828: 0a00001b beq a000a89c return EINVAL; switch ( pshared ) { a000a82c: e3510000 cmp r1, #0 a000a830: 1a000019 bne a000a89c * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000a834: e59f3068 ldr r3, [pc, #104] ; a000a8a4 a000a838: e5932000 ldr r2, [r3] ++level; a000a83c: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000a840: e5832000 str r2, [r3] * This function allocates a spinlock control block from * the inactive chain of free spinlock control blocks. */ RTEMS_INLINE_ROUTINE POSIX_Spinlock_Control *_POSIX_Spinlock_Allocate( void ) { return (POSIX_Spinlock_Control *) a000a844: e59f605c ldr r6, [pc, #92] ; a000a8a8 a000a848: e1a00006 mov r0, r6 a000a84c: eb0009fb bl a000d040 <_Objects_Allocate> _Thread_Disable_dispatch(); /* prevents deletion */ the_spinlock = _POSIX_Spinlock_Allocate(); if ( !the_spinlock ) { a000a850: e2504000 subs r4, r0, #0 a000a854: 1a000002 bne a000a864 _Thread_Enable_dispatch(); a000a858: eb000ec7 bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED return EAGAIN; a000a85c: e3a0000b mov r0, #11 <== NOT EXECUTED a000a860: ea00000e b a000a8a0 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void _CORE_spinlock_Initialize_attributes( CORE_spinlock_Attributes *the_attributes ) { the_attributes->XXX = 0; a000a864: e28d1004 add r1, sp, #4 } _CORE_spinlock_Initialize_attributes( &attributes ); _CORE_spinlock_Initialize( &the_spinlock->Spinlock, &attributes ); a000a868: e2840010 add r0, r4, #16 a000a86c: e5215004 str r5, [r1, #-4]! a000a870: e1a0100d mov r1, sp a000a874: eb00088d bl a000cab0 <_CORE_spinlock_Initialize> #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a878: e596201c ldr r2, [r6, #28] Objects_Information *information, Objects_Control *the_object, uint32_t name ) { _Objects_Set_local_object( a000a87c: e5943008 ldr r3, [r4, #8] a000a880: e1d410b8 ldrh r1, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a884: 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; a000a888: e584500c str r5, [r4, #12] _Objects_Open_u32( &_POSIX_Spinlock_Information, &the_spinlock->Object, 0 ); *spinlock = the_spinlock->Object.id; a000a88c: e5873000 str r3, [r7] _Thread_Enable_dispatch(); a000a890: eb000eb9 bl a000e37c <_Thread_Enable_dispatch> return 0; a000a894: e1a00005 mov r0, r5 a000a898: ea000000 b a000a8a0 switch ( pshared ) { case PTHREAD_PROCESS_PRIVATE: /* only supported values */ break; case PTHREAD_PROCESS_SHARED: default: return EINVAL; a000a89c: e3a00016 mov r0, #22 *spinlock = the_spinlock->Object.id; _Thread_Enable_dispatch(); return 0; } a000a8a0: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} =============================================================================== a000a230 : { POSIX_Spinlock_Control *the_spinlock = NULL; Objects_Locations location; CORE_spinlock_Status status; if ( !spinlock ) a000a230: e2503000 subs r3, r0, #0 * source of the error. */ int pthread_spin_lock( pthread_spinlock_t *spinlock ) { a000a234: e92d4011 push {r0, r4, lr} POSIX_Spinlock_Control *the_spinlock = NULL; Objects_Locations location; CORE_spinlock_Status status; if ( !spinlock ) a000a238: 0a00000e beq a000a278 RTEMS_INLINE_ROUTINE POSIX_Spinlock_Control *_POSIX_Spinlock_Get ( pthread_spinlock_t *spinlock, Objects_Locations *location ) { return (POSIX_Spinlock_Control *) _Objects_Get( a000a23c: e1a0200d mov r2, sp a000a240: e59f0038 ldr r0, [pc, #56] ; a000a280 a000a244: e5931000 ldr r1, [r3] a000a248: eb000831 bl a000c314 <_Objects_Get> return EINVAL; the_spinlock = _POSIX_Spinlock_Get( spinlock, &location ); switch ( location ) { a000a24c: e59d2000 ldr r2, [sp] a000a250: e3520000 cmp r2, #0 a000a254: 1a000007 bne a000a278 case OBJECTS_LOCAL: status = _CORE_spinlock_Wait( &the_spinlock->Spinlock, true, 0 ); a000a258: e3a01001 mov r1, #1 a000a25c: e2800010 add r0, r0, #16 a000a260: eb000571 bl a000b82c <_CORE_spinlock_Wait> a000a264: e1a04000 mov r4, r0 _Thread_Enable_dispatch(); a000a268: eb000b98 bl a000d0d0 <_Thread_Enable_dispatch> return _POSIX_Spinlock_Translate_core_spinlock_return_code( status ); a000a26c: e1a00004 mov r0, r4 a000a270: eb000003 bl a000a284 <_POSIX_Spinlock_Translate_core_spinlock_return_code> a000a274: ea000000 b a000a27c #endif case OBJECTS_ERROR: break; } return EINVAL; a000a278: e3a00016 mov r0, #22 <== NOT EXECUTED } a000a27c: e8bd8018 pop {r3, r4, pc} =============================================================================== a000a294 : { POSIX_Spinlock_Control *the_spinlock = NULL; Objects_Locations location; CORE_spinlock_Status status; if ( !spinlock ) a000a294: e2503000 subs r3, r0, #0 */ int pthread_spin_trylock( pthread_spinlock_t *spinlock ) { a000a298: e92d4011 push {r0, r4, lr} POSIX_Spinlock_Control *the_spinlock = NULL; Objects_Locations location; CORE_spinlock_Status status; if ( !spinlock ) a000a29c: 0a00000e beq a000a2dc a000a2a0: e5931000 ldr r1, [r3] a000a2a4: e59f0038 ldr r0, [pc, #56] ; a000a2e4 a000a2a8: e1a0200d mov r2, sp a000a2ac: eb000818 bl a000c314 <_Objects_Get> return EINVAL; the_spinlock = _POSIX_Spinlock_Get( spinlock, &location ); switch ( location ) { a000a2b0: e59d1000 ldr r1, [sp] a000a2b4: e3510000 cmp r1, #0 a000a2b8: 1a000007 bne a000a2dc case OBJECTS_LOCAL: status = _CORE_spinlock_Wait( &the_spinlock->Spinlock, false, 0 ); a000a2bc: e1a02001 mov r2, r1 a000a2c0: e2800010 add r0, r0, #16 a000a2c4: eb000558 bl a000b82c <_CORE_spinlock_Wait> a000a2c8: e1a04000 mov r4, r0 _Thread_Enable_dispatch(); a000a2cc: eb000b7f bl a000d0d0 <_Thread_Enable_dispatch> return _POSIX_Spinlock_Translate_core_spinlock_return_code( status ); a000a2d0: e1a00004 mov r0, r4 a000a2d4: ebffffea bl a000a284 <_POSIX_Spinlock_Translate_core_spinlock_return_code> a000a2d8: ea000000 b a000a2e0 #endif case OBJECTS_ERROR: break; } return EINVAL; a000a2dc: e3a00016 mov r0, #22 <== NOT EXECUTED } a000a2e0: e8bd8018 pop {r3, r4, pc} =============================================================================== a000a2e8 : { POSIX_Spinlock_Control *the_spinlock = NULL; Objects_Locations location; CORE_spinlock_Status status; if ( !spinlock ) a000a2e8: e2503000 subs r3, r0, #0 */ int pthread_spin_unlock( pthread_spinlock_t *spinlock ) { a000a2ec: e92d4011 push {r0, r4, lr} POSIX_Spinlock_Control *the_spinlock = NULL; Objects_Locations location; CORE_spinlock_Status status; if ( !spinlock ) a000a2f0: 0a00000d beq a000a32c a000a2f4: e5931000 ldr r1, [r3] a000a2f8: e59f0034 ldr r0, [pc, #52] ; a000a334 a000a2fc: e1a0200d mov r2, sp a000a300: eb000803 bl a000c314 <_Objects_Get> return EINVAL; the_spinlock = _POSIX_Spinlock_Get( spinlock, &location ); switch ( location ) { a000a304: e59d3000 ldr r3, [sp] a000a308: e3530000 cmp r3, #0 a000a30c: 1a000006 bne a000a32c case OBJECTS_LOCAL: status = _CORE_spinlock_Release( &the_spinlock->Spinlock ); a000a310: e2800010 add r0, r0, #16 a000a314: eb000528 bl a000b7bc <_CORE_spinlock_Release> a000a318: e1a04000 mov r4, r0 _Thread_Enable_dispatch(); a000a31c: eb000b6b bl a000d0d0 <_Thread_Enable_dispatch> return _POSIX_Spinlock_Translate_core_spinlock_return_code( status ); a000a320: e1a00004 mov r0, r4 a000a324: ebffffd6 bl a000a284 <_POSIX_Spinlock_Translate_core_spinlock_return_code> a000a328: ea000000 b a000a330 #endif case OBJECTS_ERROR: break; } return EINVAL; a000a32c: e3a00016 mov r0, #22 <== NOT EXECUTED } a000a330: e8bd8018 pop {r3, r4, pc} =============================================================================== a000a514 : * 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() ) a000a514: e59f3060 ldr r3, [pc, #96] ; a000a57c <== NOT EXECUTED /* * 18.2.2 Setting Cancelability State, P1003.1c/Draft 10, p. 183 */ void pthread_testcancel( void ) { a000a518: 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() ) a000a51c: e5934000 ldr r4, [r3] <== NOT EXECUTED a000a520: e3540000 cmp r4, #0 <== NOT EXECUTED a000a524: 1a000013 bne a000a578 <== NOT EXECUTED * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000a528: e59f2050 ldr r2, [pc, #80] ; a000a580 <== NOT EXECUTED return; thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; a000a52c: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED a000a530: e5921000 ldr r1, [r2] <== NOT EXECUTED a000a534: e59330f4 ldr r3, [r3, #244] ; 0xf4 <== NOT EXECUTED ++level; a000a538: e2811001 add r1, r1, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a000a53c: e5821000 str r1, [r2] <== NOT EXECUTED _Thread_Disable_dispatch(); if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE && a000a540: e59320d8 ldr r2, [r3, #216] ; 0xd8 <== NOT EXECUTED a000a544: e3520000 cmp r2, #0 <== NOT EXECUTED a000a548: 1a000002 bne a000a558 <== 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)); a000a54c: e59340e0 ldr r4, [r3, #224] ; 0xe0 <== NOT EXECUTED a000a550: e2944000 adds r4, r4, #0 <== NOT EXECUTED a000a554: 13a04001 movne r4, #1 <== NOT EXECUTED thread_support->cancelation_requested ) cancel = true; _Thread_Enable_dispatch(); a000a558: eb000af5 bl a000d134 <_Thread_Enable_dispatch> <== NOT EXECUTED if ( cancel ) a000a55c: e3540000 cmp r4, #0 <== NOT EXECUTED a000a560: 0a000004 beq a000a578 <== NOT EXECUTED _POSIX_Thread_Exit( _Thread_Executing, PTHREAD_CANCELED ); a000a564: e59f3010 ldr r3, [pc, #16] ; a000a57c <== NOT EXECUTED a000a568: e3e01000 mvn r1, #0 <== NOT EXECUTED a000a56c: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED } a000a570: e8bd4010 pop {r4, lr} <== NOT EXECUTED thread_support->cancelation_requested ) cancel = true; _Thread_Enable_dispatch(); if ( cancel ) _POSIX_Thread_Exit( _Thread_Executing, PTHREAD_CANCELED ); a000a574: ea0015cb b a000fca8 <_POSIX_Thread_Exit> <== NOT EXECUTED a000a578: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000a970 : * errno - otherwise */ int rtems_aio_enqueue (rtems_aio_request *req) { a000a970: e92d41f0 push {r4, r5, r6, r7, r8, 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); a000a974: e59f41e8 ldr r4, [pc, #488] ; a000ab64 * errno - otherwise */ int rtems_aio_enqueue (rtems_aio_request *req) { a000a978: e24dd024 sub sp, sp, #36 ; 0x24 a000a97c: 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); a000a980: e1a00004 mov r0, r4 a000a984: eb00025e bl a000b304 if (result != 0) { a000a988: e2505000 subs r5, r0, #0 a000a98c: 0a000002 beq a000a99c free (req); a000a990: e1a00006 mov r0, r6 <== NOT EXECUTED a000a994: ebfff014 bl a00069ec <== NOT EXECUTED return result; a000a998: ea00006e b a000ab58 <== 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); a000a99c: eb00046f bl a000bb60 a000a9a0: e28d1020 add r1, sp, #32 a000a9a4: e1a0200d mov r2, sp a000a9a8: eb000379 bl a000b794 req->caller_thread = pthread_self (); a000a9ac: eb00046b bl a000bb60 req->priority = param.sched_priority - req->aiocbp->aio_reqprio; a000a9b0: e5963014 ldr r3, [r6, #20] a000a9b4: 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 (); a000a9b8: e5860010 str r0, [r6, #16] req->priority = param.sched_priority - req->aiocbp->aio_reqprio; a000a9bc: e5932014 ldr r2, [r3, #20] a000a9c0: e0622001 rsb r2, r2, r1 a000a9c4: e586200c str r2, [r6, #12] req->policy = policy; a000a9c8: e59d2020 ldr r2, [sp, #32] a000a9cc: e5862008 str r2, [r6, #8] req->aiocbp->error_code = EINPROGRESS; a000a9d0: e3a02077 mov r2, #119 ; 0x77 a000a9d4: e5832030 str r2, [r3, #48] ; 0x30 req->aiocbp->return_value = 0; if ((aio_request_queue.idle_threads == 0) && a000a9d8: 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; a000a9dc: e5835034 str r5, [r3, #52] ; 0x34 if ((aio_request_queue.idle_threads == 0) && a000a9e0: e3520000 cmp r2, #0 a000a9e4: 1a00002d bne a000aaa0 a000a9e8: e5942064 ldr r2, [r4, #100] ; 0x64 a000a9ec: e3520004 cmp r2, #4 a000a9f0: ca00002a bgt a000aaa0 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); a000a9f4: e5931000 ldr r1, [r3] a000a9f8: e2840048 add r0, r4, #72 ; 0x48 a000a9fc: e3a02001 mov r2, #1 a000aa00: ebffff83 bl a000a814 if (r_chain->new_fd == 1) { a000aa04: 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); a000aa08: e1a07000 mov r7, r0 a000aa0c: e2808008 add r8, r0, #8 if (r_chain->new_fd == 1) { a000aa10: e3530001 cmp r3, #1 a000aa14: 1a000017 bne a000aa78 RTEMS_INLINE_ROUTINE void _Chain_Prepend( Chain_Control *the_chain, Chain_Node *the_node ) { _Chain_Insert(_Chain_Head(the_chain), the_node); a000aa18: e1a01006 mov r1, r6 a000aa1c: e1a00008 mov r0, r8 a000aa20: eb00089e bl a000cca0 <_Chain_Insert> rtems_chain_prepend (&r_chain->perfd, &req->next_prio); r_chain->new_fd = 0; pthread_mutex_init (&r_chain->mutex, NULL); a000aa24: 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; a000aa28: e5875018 str r5, [r7, #24] pthread_mutex_init (&r_chain->mutex, NULL); a000aa2c: e287001c add r0, r7, #28 a000aa30: eb0001e1 bl a000b1bc pthread_cond_init (&r_chain->cond, NULL); a000aa34: e1a01005 mov r1, r5 a000aa38: e2870020 add r0, r7, #32 a000aa3c: eb0000f2 bl a000ae0c AIO_printf ("New thread \n"); result = pthread_create (&thid, &aio_request_queue.attr, a000aa40: e1a03007 mov r3, r7 a000aa44: e28d001c add r0, sp, #28 a000aa48: e2841008 add r1, r4, #8 a000aa4c: e59f2114 ldr r2, [pc, #276] ; a000ab68 a000aa50: eb0002ba bl a000b540 rtems_aio_handle, (void *) r_chain); if (result != 0) { a000aa54: e2506000 subs r6, r0, #0 pthread_mutex_unlock (&aio_request_queue.mutex); return result; } ++aio_request_queue.active_threads; a000aa58: 05943064 ldreq r3, [r4, #100] ; 0x64 a000aa5c: 02833001 addeq r3, r3, #1 a000aa60: 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) { a000aa64: 0a000039 beq a000ab50 pthread_mutex_unlock (&aio_request_queue.mutex); a000aa68: e1a00004 mov r0, r4 <== NOT EXECUTED a000aa6c: eb000243 bl a000b380 <== NOT EXECUTED return result; a000aa70: e1a05006 mov r5, r6 <== NOT EXECUTED a000aa74: ea000037 b a000ab58 <== NOT EXECUTED } ++aio_request_queue.active_threads; } else { /* put request in the fd chain it belongs to */ pthread_mutex_lock (&r_chain->mutex); a000aa78: e280401c add r4, r0, #28 <== NOT EXECUTED a000aa7c: e1a00004 mov r0, r4 <== NOT EXECUTED a000aa80: eb00021f bl a000b304 <== NOT EXECUTED rtems_aio_insert_prio (&r_chain->perfd, req); a000aa84: e1a00008 mov r0, r8 <== NOT EXECUTED a000aa88: e1a01006 mov r1, r6 <== NOT EXECUTED a000aa8c: ebffff1a bl a000a6fc <== NOT EXECUTED pthread_cond_signal (&r_chain->cond); a000aa90: e2870020 add r0, r7, #32 <== NOT EXECUTED a000aa94: eb00010d bl a000aed0 <== NOT EXECUTED pthread_mutex_unlock (&r_chain->mutex); a000aa98: e1a00004 mov r0, r4 <== NOT EXECUTED a000aa9c: ea00000e b a000aadc <== 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, a000aaa0: e59f00c4 ldr r0, [pc, #196] ; a000ab6c <== NOT EXECUTED a000aaa4: e5931000 ldr r1, [r3] <== NOT EXECUTED a000aaa8: e3a02000 mov r2, #0 <== NOT EXECUTED a000aaac: ebffff58 bl a000a814 <== NOT EXECUTED req->aiocbp->aio_fildes, 0); if (r_chain != NULL) a000aab0: e2504000 subs r4, r0, #0 <== NOT EXECUTED a000aab4: 0a00000a beq a000aae4 <== NOT EXECUTED { pthread_mutex_lock (&r_chain->mutex); a000aab8: e284701c add r7, r4, #28 <== NOT EXECUTED a000aabc: e1a00007 mov r0, r7 <== NOT EXECUTED a000aac0: eb00020f bl a000b304 <== NOT EXECUTED rtems_aio_insert_prio (&r_chain->perfd, req); a000aac4: e2840008 add r0, r4, #8 <== NOT EXECUTED a000aac8: e1a01006 mov r1, r6 <== NOT EXECUTED a000aacc: ebffff0a bl a000a6fc <== NOT EXECUTED pthread_cond_signal (&r_chain->cond); a000aad0: e2840020 add r0, r4, #32 <== NOT EXECUTED a000aad4: eb0000fd bl a000aed0 <== NOT EXECUTED pthread_mutex_unlock (&r_chain->mutex); a000aad8: e1a00007 mov r0, r7 <== NOT EXECUTED a000aadc: eb000227 bl a000b380 <== NOT EXECUTED a000aae0: ea00001a b a000ab50 <== 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); a000aae4: e5963014 ldr r3, [r6, #20] <== NOT EXECUTED a000aae8: e59f0080 ldr r0, [pc, #128] ; a000ab70 <== NOT EXECUTED a000aaec: e3a02001 mov r2, #1 <== NOT EXECUTED a000aaf0: e5931000 ldr r1, [r3] <== NOT EXECUTED a000aaf4: ebffff46 bl a000a814 <== NOT EXECUTED if (r_chain->new_fd == 1) { a000aaf8: 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); a000aafc: e1a07000 mov r7, r0 <== NOT EXECUTED a000ab00: e1a01006 mov r1, r6 <== NOT EXECUTED if (r_chain->new_fd == 1) { a000ab04: e3530001 cmp r3, #1 <== NOT EXECUTED a000ab08: e2800008 add r0, r0, #8 <== NOT EXECUTED a000ab0c: 1a000008 bne a000ab34 <== NOT EXECUTED a000ab10: eb000862 bl a000cca0 <_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); a000ab14: 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; a000ab18: e5874018 str r4, [r7, #24] <== NOT EXECUTED pthread_mutex_init (&r_chain->mutex, NULL); a000ab1c: e287001c add r0, r7, #28 <== NOT EXECUTED a000ab20: eb0001a5 bl a000b1bc <== NOT EXECUTED pthread_cond_init (&r_chain->cond, NULL); a000ab24: e2870020 add r0, r7, #32 <== NOT EXECUTED a000ab28: e1a01004 mov r1, r4 <== NOT EXECUTED a000ab2c: eb0000b6 bl a000ae0c <== NOT EXECUTED a000ab30: ea000000 b a000ab38 <== NOT EXECUTED } else /* just insert the request in the existing fd chain */ rtems_aio_insert_prio (&r_chain->perfd, req); a000ab34: ebfffef0 bl a000a6fc <== NOT EXECUTED if (aio_request_queue.idle_threads > 0) a000ab38: e59f0024 ldr r0, [pc, #36] ; a000ab64 <== NOT EXECUTED a000ab3c: e5903068 ldr r3, [r0, #104] ; 0x68 <== NOT EXECUTED a000ab40: e3530000 cmp r3, #0 <== NOT EXECUTED a000ab44: da000001 ble a000ab50 <== NOT EXECUTED pthread_cond_signal (&aio_request_queue.new_req); a000ab48: e2800004 add r0, r0, #4 <== NOT EXECUTED a000ab4c: eb0000df bl a000aed0 <== NOT EXECUTED } } pthread_mutex_unlock (&aio_request_queue.mutex); a000ab50: e59f000c ldr r0, [pc, #12] ; a000ab64 a000ab54: eb000209 bl a000b380 return 0; } a000ab58: e1a00005 mov r0, r5 a000ab5c: e28dd024 add sp, sp, #36 ; 0x24 a000ab60: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a000a490 : * NULL - if error */ static void * rtems_aio_handle (void *arg) { a000a490: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, 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); a000a494: e59f425c ldr r4, [pc, #604] ; a000a6f8 <== NOT EXECUTED * NULL - if error */ static void * rtems_aio_handle (void *arg) { a000a498: e24dd02c sub sp, sp, #44 ; 0x2c <== NOT EXECUTED a000a49c: e1a05000 mov r5, 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 && a000a4a0: e284904c add r9, r4, #76 ; 0x4c <== 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); a000a4a4: e285801c add r8, r5, #28 <== NOT EXECUTED a000a4a8: e1a00008 mov r0, r8 <== NOT EXECUTED a000a4ac: eb000394 bl a000b304 <== NOT EXECUTED if (result != 0) a000a4b0: e250a000 subs sl, r0, #0 <== NOT EXECUTED a000a4b4: 1a00008c bne a000a6ec <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000a4b8: 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 ); a000a4bc: 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)) { a000a4c0: e1560003 cmp r6, r3 <== NOT EXECUTED a000a4c4: 0a000035 beq a000a5a0 <== 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); a000a4c8: eb0005a4 bl a000bb60 <== NOT EXECUTED a000a4cc: e28d1028 add r1, sp, #40 ; 0x28 <== NOT EXECUTED a000a4d0: e28d2004 add r2, sp, #4 <== NOT EXECUTED a000a4d4: eb0004ae bl a000b794 <== NOT EXECUTED param.sched_priority = req->priority; a000a4d8: e596300c ldr r3, [r6, #12] <== NOT EXECUTED a000a4dc: e58d3004 str r3, [sp, #4] <== NOT EXECUTED pthread_setschedparam (pthread_self(), req->policy, ¶m); a000a4e0: eb00059e bl a000bb60 <== NOT EXECUTED a000a4e4: e28d2004 add r2, sp, #4 <== NOT EXECUTED a000a4e8: e5961008 ldr r1, [r6, #8] <== NOT EXECUTED a000a4ec: eb0005a0 bl a000bb74 <== NOT EXECUTED a000a4f0: e1a00006 mov r0, r6 <== NOT EXECUTED a000a4f4: eb0009d4 bl a000cc4c <_Chain_Extract> <== NOT EXECUTED rtems_chain_extract (node); pthread_mutex_unlock (&r_chain->mutex); a000a4f8: e1a00008 mov r0, r8 <== NOT EXECUTED a000a4fc: eb00039f bl a000b380 <== NOT EXECUTED switch (req->aiocbp->aio_lio_opcode) { a000a500: e5962014 ldr r2, [r6, #20] <== NOT EXECUTED a000a504: e592302c ldr r3, [r2, #44] ; 0x2c <== NOT EXECUTED a000a508: e3530002 cmp r3, #2 <== NOT EXECUTED a000a50c: 0a00000b beq a000a540 <== NOT EXECUTED a000a510: e3530003 cmp r3, #3 <== NOT EXECUTED a000a514: 0a000011 beq a000a560 <== NOT EXECUTED a000a518: e3530001 cmp r3, #1 <== NOT EXECUTED a000a51c: 1a000013 bne a000a570 <== NOT EXECUTED case LIO_READ: AIO_printf ("read\n"); result = pread (req->aiocbp->aio_fildes, a000a520: e5921008 ldr r1, [r2, #8] <== NOT EXECUTED a000a524: e5923004 ldr r3, [r2, #4] <== NOT EXECUTED a000a528: e58d1000 str r1, [sp] <== NOT EXECUTED a000a52c: e592100c ldr r1, [r2, #12] <== NOT EXECUTED a000a530: e5920000 ldr r0, [r2] <== NOT EXECUTED a000a534: e5922010 ldr r2, [r2, #16] <== NOT EXECUTED a000a538: eb00284b bl a001466c <== NOT EXECUTED (void *) req->aiocbp->aio_buf, req->aiocbp->aio_nbytes, req->aiocbp->aio_offset); break; a000a53c: ea000009 b a000a568 <== NOT EXECUTED case LIO_WRITE: AIO_printf ("write\n"); result = pwrite (req->aiocbp->aio_fildes, a000a540: e5921008 ldr r1, [r2, #8] <== NOT EXECUTED a000a544: e5923004 ldr r3, [r2, #4] <== NOT EXECUTED a000a548: e58d1000 str r1, [sp] <== NOT EXECUTED a000a54c: e592100c ldr r1, [r2, #12] <== NOT EXECUTED a000a550: e5920000 ldr r0, [r2] <== NOT EXECUTED a000a554: e5922010 ldr r2, [r2, #16] <== NOT EXECUTED a000a558: eb002886 bl a0014778 <== NOT EXECUTED (void *) req->aiocbp->aio_buf, req->aiocbp->aio_nbytes, req->aiocbp->aio_offset); break; a000a55c: ea000001 b a000a568 <== NOT EXECUTED case LIO_SYNC: AIO_printf ("sync\n"); result = fsync (req->aiocbp->aio_fildes); a000a560: e5920000 ldr r0, [r2] <== NOT EXECUTED a000a564: eb001923 bl a00109f8 <== NOT EXECUTED break; default: result = -1; } if (result == -1) { a000a568: e3700001 cmn r0, #1 <== NOT EXECUTED a000a56c: 1a000006 bne a000a58c <== NOT EXECUTED req->aiocbp->return_value = -1; a000a570: e5966014 ldr r6, [r6, #20] <== NOT EXECUTED a000a574: e3e03000 mvn r3, #0 <== NOT EXECUTED a000a578: e5863034 str r3, [r6, #52] ; 0x34 <== NOT EXECUTED req->aiocbp->error_code = errno; a000a57c: eb002560 bl a0013b04 <__errno> <== NOT EXECUTED a000a580: e5903000 ldr r3, [r0] <== NOT EXECUTED a000a584: e5863030 str r3, [r6, #48] ; 0x30 <== NOT EXECUTED a000a588: eaffffc5 b a000a4a4 <== NOT EXECUTED } else { req->aiocbp->return_value = result; a000a58c: e5963014 ldr r3, [r6, #20] <== NOT EXECUTED req->aiocbp->error_code = 0; a000a590: 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; a000a594: e5830034 str r0, [r3, #52] ; 0x34 <== NOT EXECUTED req->aiocbp->error_code = 0; a000a598: e5832030 str r2, [r3, #48] ; 0x30 <== NOT EXECUTED a000a59c: eaffffc0 b a000a4a4 <== 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); a000a5a0: e59f7150 ldr r7, [pc, #336] ; a000a6f8 <== NOT EXECUTED struct timespec timeout; AIO_printf ("Chain is empty [WQ], wait for work\n"); pthread_mutex_unlock (&r_chain->mutex); a000a5a4: e1a00008 mov r0, r8 <== NOT EXECUTED a000a5a8: eb000374 bl a000b380 <== NOT EXECUTED pthread_mutex_lock (&aio_request_queue.mutex); a000a5ac: e1a00007 mov r0, r7 <== NOT EXECUTED a000a5b0: eb000353 bl a000b304 <== NOT EXECUTED if (rtems_chain_is_empty (chain)) a000a5b4: e5953008 ldr r3, [r5, #8] <== NOT EXECUTED a000a5b8: e1530006 cmp r3, r6 <== NOT EXECUTED a000a5bc: 1a000047 bne a000a6e0 <== NOT EXECUTED { clock_gettime (CLOCK_REALTIME, &timeout); a000a5c0: e28d1020 add r1, sp, #32 <== NOT EXECUTED a000a5c4: e3a00001 mov r0, #1 <== NOT EXECUTED a000a5c8: eb0001b3 bl a000ac9c <== NOT EXECUTED timeout.tv_sec += 3; a000a5cc: e59d3020 ldr r3, [sp, #32] <== NOT EXECUTED timeout.tv_nsec = 0; result = pthread_cond_timedwait (&r_chain->cond, a000a5d0: e2856020 add r6, r5, #32 <== NOT EXECUTED a000a5d4: 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; a000a5d8: e2833003 add r3, r3, #3 <== NOT EXECUTED timeout.tv_nsec = 0; result = pthread_cond_timedwait (&r_chain->cond, a000a5dc: e1a01007 mov r1, r7 <== NOT EXECUTED a000a5e0: e28d2020 add r2, sp, #32 <== NOT EXECUTED pthread_mutex_lock (&aio_request_queue.mutex); if (rtems_chain_is_empty (chain)) { clock_gettime (CLOCK_REALTIME, &timeout); timeout.tv_sec += 3; a000a5e4: e58d3020 str r3, [sp, #32] <== NOT EXECUTED timeout.tv_nsec = 0; a000a5e8: e58da024 str sl, [sp, #36] ; 0x24 <== NOT EXECUTED result = pthread_cond_timedwait (&r_chain->cond, a000a5ec: eb00024e bl a000af2c <== 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) { a000a5f0: e3500074 cmp r0, #116 ; 0x74 <== NOT EXECUTED a000a5f4: 1a000039 bne a000a6e0 <== NOT EXECUTED a000a5f8: e1a00005 mov r0, r5 <== NOT EXECUTED a000a5fc: eb000992 bl a000cc4c <_Chain_Extract> <== NOT EXECUTED rtems_chain_extract (&r_chain->next_fd); pthread_mutex_destroy (&r_chain->mutex); a000a600: e1a00008 mov r0, r8 <== NOT EXECUTED a000a604: eb00029c bl a000b07c <== NOT EXECUTED pthread_cond_destroy (&r_chain->cond); a000a608: e1a00006 mov r0, r6 <== NOT EXECUTED a000a60c: eb0001cc bl a000ad44 <== NOT EXECUTED free (r_chain); a000a610: e1a00005 mov r0, r5 <== NOT EXECUTED a000a614: ebfff0f4 bl a00069ec <== 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)) { a000a618: e5942054 ldr r2, [r4, #84] ; 0x54 <== NOT EXECUTED a000a61c: e2873058 add r3, r7, #88 ; 0x58 <== NOT EXECUTED a000a620: e1520003 cmp r2, r3 <== NOT EXECUTED a000a624: 1a000018 bne a000a68c <== NOT EXECUTED AIO_printf ("Chain is empty [IQ], wait for work\n"); ++aio_request_queue.idle_threads; a000a628: e5943068 ldr r3, [r4, #104] ; 0x68 <== NOT EXECUTED --aio_request_queue.active_threads; clock_gettime (CLOCK_REALTIME, &timeout); a000a62c: e28d1020 add r1, sp, #32 <== NOT EXECUTED a000a630: 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; a000a634: e2833001 add r3, r3, #1 <== NOT EXECUTED a000a638: e5843068 str r3, [r4, #104] ; 0x68 <== NOT EXECUTED --aio_request_queue.active_threads; a000a63c: e5943064 ldr r3, [r4, #100] ; 0x64 <== NOT EXECUTED a000a640: e2433001 sub r3, r3, #1 <== NOT EXECUTED a000a644: e5843064 str r3, [r4, #100] ; 0x64 <== NOT EXECUTED clock_gettime (CLOCK_REALTIME, &timeout); a000a648: eb000193 bl a000ac9c <== NOT EXECUTED timeout.tv_sec += 3; a000a64c: e59d3020 ldr r3, [sp, #32] <== NOT EXECUTED timeout.tv_nsec = 0; result = pthread_cond_timedwait (&aio_request_queue.new_req, a000a650: e2870004 add r0, r7, #4 <== NOT EXECUTED a000a654: e1a01007 mov r1, 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; a000a658: e2833003 add r3, r3, #3 <== NOT EXECUTED timeout.tv_nsec = 0; result = pthread_cond_timedwait (&aio_request_queue.new_req, a000a65c: e28d2020 add r2, sp, #32 <== 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; a000a660: e58d3020 str r3, [sp, #32] <== NOT EXECUTED timeout.tv_nsec = 0; a000a664: e58da024 str sl, [sp, #36] ; 0x24 <== NOT EXECUTED result = pthread_cond_timedwait (&aio_request_queue.new_req, a000a668: eb00022f bl a000af2c <== 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) { a000a66c: e3500074 cmp r0, #116 ; 0x74 <== NOT EXECUTED a000a670: 1a000005 bne a000a68c <== NOT EXECUTED AIO_printf ("Etimeout\n"); --aio_request_queue.idle_threads; a000a674: e5973068 ldr r3, [r7, #104] ; 0x68 <== NOT EXECUTED pthread_mutex_unlock (&aio_request_queue.mutex); a000a678: e1a00007 mov r0, r7 <== 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; a000a67c: e2433001 sub r3, r3, #1 <== NOT EXECUTED a000a680: e5873068 str r3, [r7, #104] ; 0x68 <== NOT EXECUTED pthread_mutex_unlock (&aio_request_queue.mutex); a000a684: eb00033d bl a000b380 <== NOT EXECUTED return NULL; a000a688: ea000017 b a000a6ec <== 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; a000a68c: e5943068 ldr r3, [r4, #104] ; 0x68 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000a690: e5945054 ldr r5, [r4, #84] ; 0x54 <== NOT EXECUTED a000a694: e2433001 sub r3, r3, #1 <== NOT EXECUTED a000a698: e5843068 str r3, [r4, #104] ; 0x68 <== NOT EXECUTED ++aio_request_queue.active_threads; a000a69c: e5943064 ldr r3, [r4, #100] ; 0x64 <== NOT EXECUTED a000a6a0: e1a00005 mov r0, r5 <== NOT EXECUTED a000a6a4: e2833001 add r3, r3, #1 <== NOT EXECUTED a000a6a8: e5843064 str r3, [r4, #100] ; 0x64 <== NOT EXECUTED a000a6ac: eb000966 bl a000cc4c <_Chain_Extract> <== NOT EXECUTED a000a6b0: e5943048 ldr r3, [r4, #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 && a000a6b4: e5952014 ldr r2, [r5, #20] <== NOT EXECUTED a000a6b8: ea000000 b a000a6c0 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next( Chain_Node *the_node ) { return the_node->next; a000a6bc: e5933000 ldr r3, [r3] <== NOT EXECUTED a000a6c0: e5931014 ldr r1, [r3, #20] <== NOT EXECUTED a000a6c4: e1510002 cmp r1, r2 <== NOT EXECUTED a000a6c8: aa000001 bge a000a6d4 <== NOT EXECUTED a000a6cc: e1530009 cmp r3, r9 <== NOT EXECUTED a000a6d0: 1afffff9 bne a000a6bc <== 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 ); a000a6d4: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED a000a6d8: e1a01005 mov r1, r5 <== NOT EXECUTED a000a6dc: eb00096f bl a000cca0 <_Chain_Insert> <== 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); a000a6e0: e59f0010 ldr r0, [pc, #16] ; a000a6f8 <== NOT EXECUTED a000a6e4: eb000325 bl a000b380 <== NOT EXECUTED a000a6e8: eaffff6d b a000a4a4 <== NOT EXECUTED } } AIO_printf ("Thread finished\n"); return NULL; } a000a6ec: e3a00000 mov r0, #0 <== NOT EXECUTED a000a6f0: e28dd02c add sp, sp, #44 ; 0x2c <== NOT EXECUTED a000a6f4: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED =============================================================================== a000a74c : * 0 - if initialization succeeded */ int rtems_aio_init (void) { a000a74c: e92d4010 push {r4, lr} int result = 0; result = pthread_attr_init (&aio_request_queue.attr); a000a750: e59f00ac ldr r0, [pc, #172] ; a000a804 a000a754: eb00035a bl a000b4c4 if (result != 0) a000a758: e2504000 subs r4, r0, #0 a000a75c: 1a000026 bne a000a7fc return result; result = a000a760: e59f009c ldr r0, [pc, #156] ; a000a804 a000a764: e1a01004 mov r1, r4 a000a768: eb000366 bl a000b508 pthread_attr_setdetachstate (&aio_request_queue.attr, PTHREAD_CREATE_DETACHED); if (result != 0) a000a76c: e3500000 cmp r0, #0 a000a770: 0a000001 beq a000a77c pthread_attr_destroy (&aio_request_queue.attr); a000a774: e59f0088 ldr r0, [pc, #136] ; a000a804 <== NOT EXECUTED a000a778: eb000348 bl a000b4a0 <== NOT EXECUTED result = pthread_mutex_init (&aio_request_queue.mutex, NULL); a000a77c: e59f0084 ldr r0, [pc, #132] ; a000a808 a000a780: e3a01000 mov r1, #0 a000a784: eb00028c bl a000b1bc if (result != 0) a000a788: e3500000 cmp r0, #0 a000a78c: 0a000001 beq a000a798 pthread_attr_destroy (&aio_request_queue.attr); a000a790: e59f006c ldr r0, [pc, #108] ; a000a804 <== NOT EXECUTED a000a794: eb000341 bl a000b4a0 <== NOT EXECUTED result = pthread_cond_init (&aio_request_queue.new_req, NULL); a000a798: e59f006c ldr r0, [pc, #108] ; a000a80c a000a79c: e3a01000 mov r1, #0 a000a7a0: eb000199 bl a000ae0c if (result != 0) { a000a7a4: e2504000 subs r4, r0, #0 a000a7a8: 0a000003 beq a000a7bc pthread_mutex_destroy (&aio_request_queue.mutex); a000a7ac: e59f0054 ldr r0, [pc, #84] ; a000a808 <== NOT EXECUTED a000a7b0: eb000231 bl a000b07c <== NOT EXECUTED pthread_attr_destroy (&aio_request_queue.attr); a000a7b4: e59f0048 ldr r0, [pc, #72] ; a000a804 <== NOT EXECUTED a000a7b8: eb000338 bl a000b4a0 <== NOT EXECUTED ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); head->next = tail; a000a7bc: e59f3044 ldr r3, [pc, #68] ; a000a808 a000a7c0: e283204c add r2, r3, #76 ; 0x4c a000a7c4: e5832048 str r2, [r3, #72] ; 0x48 head->previous = NULL; a000a7c8: e3a02000 mov r2, #0 tail->previous = head; a000a7cc: 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; a000a7d0: e583204c str r2, [r3, #76] ; 0x4c a000a7d4: 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; a000a7d8: e5832064 str r2, [r3, #100] ; 0x64 aio_request_queue.idle_threads = 0; a000a7dc: e5832068 str r2, [r3, #104] ; 0x68 aio_request_queue.initialized = AIO_QUEUE_INITIALIZED; a000a7e0: e59f2028 ldr r2, [pc, #40] ; a000a810 tail->previous = head; a000a7e4: e5831050 str r1, [r3, #80] ; 0x50 ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *tail = _Chain_Tail( the_chain ); head->next = tail; a000a7e8: e2831058 add r1, r3, #88 ; 0x58 a000a7ec: e5831054 str r1, [r3, #84] ; 0x54 head->previous = NULL; tail->previous = head; a000a7f0: e2831054 add r1, r3, #84 ; 0x54 a000a7f4: e583105c str r1, [r3, #92] ; 0x5c a000a7f8: e5832060 str r2, [r3, #96] ; 0x60 return result; } a000a7fc: e1a00004 mov r0, r4 a000a800: e8bd8010 pop {r4, pc} =============================================================================== a000a6fc : */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000a6fc: e1a02000 mov r2, r0 <== NOT EXECUTED a000a700: e4923004 ldr r3, [r2], #4 <== NOT EXECUTED * NONE */ static void rtems_aio_insert_prio (rtems_chain_control *chain, rtems_aio_request *req) { a000a704: 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)) { a000a708: e1530002 cmp r3, r2 <== NOT EXECUTED a000a70c: 0a00000d beq a000a748 <== 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; a000a710: e5931014 ldr r1, [r3, #20] <== NOT EXECUTED while (req->aiocbp->aio_reqprio > prio && a000a714: 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; a000a718: e5911014 ldr r1, [r1, #20] <== NOT EXECUTED while (req->aiocbp->aio_reqprio > prio && a000a71c: e5900014 ldr r0, [r0, #20] <== NOT EXECUTED a000a720: ea000002 b a000a730 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next( Chain_Node *the_node ) { return the_node->next; a000a724: e5933000 ldr r3, [r3] <== NOT EXECUTED !rtems_chain_is_tail (chain, node)) { node = rtems_chain_next (node); prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio; a000a728: e5931014 ldr r1, [r3, #20] <== NOT EXECUTED a000a72c: 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 && a000a730: e1500001 cmp r0, r1 <== NOT EXECUTED a000a734: da000001 ble a000a740 <== NOT EXECUTED a000a738: e1530002 cmp r3, r2 <== NOT EXECUTED a000a73c: 1afffff8 bne a000a724 <== NOT EXECUTED a000a740: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED a000a744: e1a0100c mov r1, ip <== NOT EXECUTED a000a748: ea000954 b a000cca0 <_Chain_Insert> <== NOT EXECUTED =============================================================================== a000a8c0 : * Output parameters: * NONE */ void rtems_aio_remove_fd (rtems_aio_request_chain *r_chain) { a000a8c0: e92d41f0 push {r4, r5, r6, r7, r8, lr} <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000a8c4: e5904008 ldr r4, [r0, #8] <== NOT EXECUTED RTEMS_INLINE_ROUTINE bool _Chain_Is_tail( const Chain_Control *the_chain, const Chain_Node *the_node ) { return (the_node == _Chain_Immutable_tail( the_chain )); a000a8c8: e280700c add r7, r0, #12 <== 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; a000a8cc: e3a0608c mov r6, #140 ; 0x8c <== NOT EXECUTED req->aiocbp->return_value = -1; a000a8d0: 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)) a000a8d4: ea000008 b a000a8fc <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node ); a000a8d8: e1a00004 mov r0, r4 <== NOT EXECUTED a000a8dc: eb0008da bl a000cc4c <_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; a000a8e0: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next( Chain_Node *the_node ) { return the_node->next; a000a8e4: e5948000 ldr r8, [r4] <== NOT EXECUTED req->aiocbp->return_value = -1; free (req); a000a8e8: 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; a000a8ec: e5836030 str r6, [r3, #48] ; 0x30 <== NOT EXECUTED req->aiocbp->return_value = -1; a000a8f0: e5835034 str r5, [r3, #52] ; 0x34 <== NOT EXECUTED free (req); a000a8f4: ebfff03c bl a00069ec <== 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); a000a8f8: 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)) a000a8fc: e1540007 cmp r4, r7 <== NOT EXECUTED a000a900: 1afffff4 bne a000a8d8 <== NOT EXECUTED node = rtems_chain_next (node); req->aiocbp->error_code = ECANCELED; req->aiocbp->return_value = -1; free (req); } } a000a904: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED =============================================================================== a000a908 : * 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) { a000a908: e92d4010 push {r4, lr} <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000a90c: e4904004 ldr r4, [r0], #4 <== NOT EXECUTED if (rtems_chain_is_empty (chain)) a000a910: e1540000 cmp r4, r0 <== NOT EXECUTED a000a914: 1a000005 bne a000a930 <== NOT EXECUTED a000a918: ea000012 b a000a968 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next( Chain_Node *the_node ) { return the_node->next; a000a91c: e5944000 ldr r4, [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) { a000a920: e1540000 cmp r4, r0 <== NOT EXECUTED a000a924: 1a000001 bne a000a930 <== NOT EXECUTED node = rtems_chain_next (node); current = (rtems_aio_request *) node; } if (rtems_chain_is_tail (chain, node)) return AIO_NOTCANCELED; a000a928: e3a00001 mov r0, #1 <== NOT EXECUTED a000a92c: e8bd8010 pop {r4, pc} <== 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) { a000a930: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED a000a934: e1530001 cmp r3, r1 <== NOT EXECUTED a000a938: 1afffff7 bne a000a91c <== NOT EXECUTED a000a93c: e1a00004 mov r0, r4 <== NOT EXECUTED a000a940: eb0008c1 bl a000cc4c <_Chain_Extract> <== NOT EXECUTED if (rtems_chain_is_tail (chain, node)) return AIO_NOTCANCELED; else { rtems_chain_extract (node); current->aiocbp->error_code = ECANCELED; a000a944: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED a000a948: e3a0208c mov r2, #140 ; 0x8c <== NOT EXECUTED current->aiocbp->return_value = -1; free (current); a000a94c: 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; a000a950: e5832030 str r2, [r3, #48] ; 0x30 <== NOT EXECUTED current->aiocbp->return_value = -1; a000a954: e3e02000 mvn r2, #0 <== NOT EXECUTED a000a958: e5832034 str r2, [r3, #52] ; 0x34 <== NOT EXECUTED free (current); a000a95c: ebfff022 bl a00069ec <== NOT EXECUTED } return AIO_CANCELED; a000a960: e3a00000 mov r0, #0 <== NOT EXECUTED a000a964: 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; a000a968: e3a00002 mov r0, #2 <== NOT EXECUTED current->aiocbp->return_value = -1; free (current); } return AIO_CANCELED; } a000a96c: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000a814 : */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000a814: e1a03000 mov r3, r0 * */ rtems_aio_request_chain * rtems_aio_search_fd (rtems_chain_control *chain, int fildes, int create) { a000a818: e92d40f0 push {r4, r5, r6, r7, lr} a000a81c: e1a04000 mov r4, r0 a000a820: e1a05001 mov r5, r1 a000a824: e4937004 ldr r7, [r3], #4 rtems_chain_node *node; node = rtems_chain_first (chain); r_chain = (rtems_aio_request_chain *) node; while (r_chain->fildes < fildes && !rtems_chain_is_tail (chain, node)) { a000a828: ea000000 b a000a830 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next( Chain_Node *the_node ) { return the_node->next; a000a82c: e5977000 ldr r7, [r7] a000a830: e5971014 ldr r1, [r7, #20] a000a834: e1510005 cmp r1, r5 a000a838: ba000001 blt a000a844 node = rtems_chain_next (node); r_chain = (rtems_aio_request_chain *) node; } if (r_chain->fildes == fildes) a000a83c: 1a000006 bne a000a85c a000a840: ea000002 b a000a850 <== NOT EXECUTED rtems_chain_node *node; node = rtems_chain_first (chain); r_chain = (rtems_aio_request_chain *) node; while (r_chain->fildes < fildes && !rtems_chain_is_tail (chain, node)) { a000a844: e1570003 cmp r7, r3 a000a848: 1afffff7 bne a000a82c a000a84c: ea000002 b a000a85c <== NOT EXECUTED node = rtems_chain_next (node); r_chain = (rtems_aio_request_chain *) node; } if (r_chain->fildes == fildes) r_chain->new_fd = 0; a000a850: e3a03000 mov r3, #0 <== NOT EXECUTED a000a854: e5873018 str r3, [r7, #24] <== NOT EXECUTED a000a858: ea000016 b a000a8b8 <== NOT EXECUTED else { if (create == 0) a000a85c: e3520000 cmp r2, #0 r_chain = NULL; a000a860: 01a07002 moveq r7, r2 } if (r_chain->fildes == fildes) r_chain->new_fd = 0; else { if (create == 0) a000a864: 0a000013 beq a000a8b8 r_chain = NULL; else { r_chain = malloc (sizeof (rtems_aio_request_chain)); a000a868: e3a00024 mov r0, #36 ; 0x24 a000a86c: ebfff17b bl a0006e60 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 ); a000a870: e280200c add r2, r0, #12 head->next = tail; a000a874: e5802008 str r2, [r0, #8] head->previous = NULL; a000a878: e3a02000 mov r2, #0 a000a87c: e580200c str r2, [r0, #12] rtems_chain_initialize_empty (&r_chain->perfd); if (rtems_chain_is_empty (chain)) a000a880: e5942000 ldr r2, [r4] 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 ); a000a884: e2803008 add r3, r0, #8 head->next = tail; head->previous = NULL; tail->previous = head; a000a888: e5803010 str r3, [r0, #16] RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); a000a88c: e2843004 add r3, r4, #4 r_chain->new_fd = 0; else { if (create == 0) r_chain = NULL; else { r_chain = malloc (sizeof (rtems_aio_request_chain)); a000a890: e1a06000 mov r6, r0 rtems_chain_initialize_empty (&r_chain->perfd); if (rtems_chain_is_empty (chain)) a000a894: e1520003 cmp r2, r3 a000a898: 15970004 ldrne r0, [r7, #4] RTEMS_INLINE_ROUTINE void _Chain_Prepend( Chain_Control *the_chain, Chain_Node *the_node ) { _Chain_Insert(_Chain_Head(the_chain), the_node); a000a89c: 01a00004 moveq r0, r4 a000a8a0: e1a01006 mov r1, r6 a000a8a4: eb0008fd bl a000cca0 <_Chain_Insert> rtems_chain_prepend (chain, &r_chain->next_fd); else rtems_chain_insert (rtems_chain_previous (node), &r_chain->next_fd); r_chain->new_fd = 1; a000a8a8: e3a03001 mov r3, #1 a000a8ac: e5863018 str r3, [r6, #24] r_chain->fildes = fildes; a000a8b0: e5865014 str r5, [r6, #20] a000a8b4: e1a07006 mov r7, r6 } } return r_chain; } a000a8b8: e1a00007 mov r0, r7 a000a8bc: e8bd80f0 pop {r4, r5, r6, r7, pc} =============================================================================== a000b8c0 : uint32_t the_class, uint32_t node, uint32_t index ) { return (( (Objects_Id) the_api ) << OBJECTS_API_START_BIT) | a000b8c0: e1a00c00 lsl r0, r0, #24 <== NOT EXECUTED a000b8c4: e1800d81 orr r0, r0, r1, lsl #27 <== NOT EXECUTED (( (Objects_Id) the_class ) << OBJECTS_CLASS_START_BIT) | a000b8c8: e1800003 orr r0, r0, r3 <== NOT EXECUTED uint32_t node, uint32_t index ) { return _Objects_Build_id( api, class, node, index ); } a000b8cc: e1800802 orr r0, r0, r2, lsl #16 <== NOT EXECUTED a000b8d0: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000b8d4 : char C1, char C2, char C3, char C4 ) { a000b8d4: e1a01801 lsl r1, r1, #16 <== NOT EXECUTED return _Objects_Build_name( C1, C2, C3, C4 ); a000b8d8: e20118ff and r1, r1, #16711680 ; 0xff0000 <== NOT EXECUTED char C1, char C2, char C3, char C4 ) { a000b8dc: e1a02402 lsl r2, r2, #8 <== NOT EXECUTED return _Objects_Build_name( C1, C2, C3, C4 ); a000b8e0: e1810c00 orr r0, r1, r0, lsl #24 <== NOT EXECUTED a000b8e4: e2022cff and r2, r2, #65280 ; 0xff00 <== NOT EXECUTED char C1, char C2, char C3, char C4 ) { a000b8e8: e20330ff and r3, r3, #255 ; 0xff <== NOT EXECUTED return _Objects_Build_name( C1, C2, C3, C4 ); a000b8ec: e1800002 orr r0, r0, r2 <== NOT EXECUTED } a000b8f0: e1800003 orr r0, r0, r3 <== NOT EXECUTED a000b8f4: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000ad30 : rtems_chain_control *chain, rtems_chain_node *node, rtems_id task, rtems_event_set events ) { a000ad30: e92d4030 push {r4, r5, lr} <== NOT EXECUTED a000ad34: e1a04002 mov r4, r2 <== NOT EXECUTED a000ad38: 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 ); a000ad3c: eb00015a bl a000b2ac <_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 ) { a000ad40: e3500000 cmp r0, #0 <== NOT EXECUTED a000ad44: 0a000003 beq a000ad58 <== NOT EXECUTED sc = rtems_event_send( task, events ); a000ad48: e1a00004 mov r0, r4 <== NOT EXECUTED a000ad4c: e1a01005 mov r1, r5 <== NOT EXECUTED } return sc; } a000ad50: 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 ); a000ad54: eafffd99 b a000a3c0 <== NOT EXECUTED } return sc; } a000ad58: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a000ad5c : rtems_chain_control *chain, rtems_id task, rtems_event_set events, rtems_chain_node **node ) { a000ad5c: e92d4030 push {r4, r5, lr} <== NOT EXECUTED a000ad60: 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 ); a000ad64: e1a01003 mov r1, r3 <== NOT EXECUTED a000ad68: e1a05002 mov r5, r2 <== NOT EXECUTED a000ad6c: eb00016a bl a000b31c <_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 ) { a000ad70: e3500000 cmp r0, #0 <== NOT EXECUTED a000ad74: 0a000003 beq a000ad88 <== NOT EXECUTED sc = rtems_event_send( task, events ); a000ad78: e1a00004 mov r0, r4 <== NOT EXECUTED a000ad7c: e1a01005 mov r1, r5 <== NOT EXECUTED } return sc; } a000ad80: 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 ); a000ad84: eafffd8d b a000a3c0 <== NOT EXECUTED } return sc; } a000ad88: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a000ad8c : rtems_chain_control *chain, rtems_event_set events, rtems_interval timeout, rtems_chain_node **node_ptr ) { a000ad8c: e92d41f1 push {r0, r4, r5, r6, r7, r8, lr} <== NOT EXECUTED a000ad90: e1a07000 mov r7, r0 <== NOT EXECUTED a000ad94: e1a06001 mov r6, r1 <== NOT EXECUTED a000ad98: e1a05002 mov r5, r2 <== NOT EXECUTED a000ad9c: e1a08003 mov r8, r3 <== NOT EXECUTED a000ada0: ea000006 b a000adc0 <== NOT EXECUTED while ( sc == RTEMS_SUCCESSFUL && (node = rtems_chain_get( chain )) == NULL ) { rtems_event_set out; sc = rtems_event_receive( a000ada4: e1a00006 mov r0, r6 <== NOT EXECUTED a000ada8: e1a01004 mov r1, r4 <== NOT EXECUTED a000adac: e1a02005 mov r2, r5 <== NOT EXECUTED a000adb0: e1a0300d mov r3, sp <== NOT EXECUTED a000adb4: ebfffd22 bl a000a244 <== NOT EXECUTED ) { rtems_status_code sc = RTEMS_SUCCESSFUL; rtems_chain_node *node = NULL; while ( a000adb8: e3500000 cmp r0, #0 <== NOT EXECUTED a000adbc: 1a000004 bne a000add4 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get( rtems_chain_control *the_chain ) { return _Chain_Get( the_chain ); a000adc0: e1a00007 mov r0, r7 <== NOT EXECUTED a000adc4: eb000168 bl a000b36c <_Chain_Get> <== NOT EXECUTED sc == RTEMS_SUCCESSFUL && (node = rtems_chain_get( chain )) == NULL a000adc8: e2504000 subs r4, r0, #0 <== NOT EXECUTED a000adcc: 0afffff4 beq a000ada4 <== NOT EXECUTED a000add0: e3a00000 mov r0, #0 <== NOT EXECUTED timeout, &out ); } *node_ptr = node; a000add4: e5884000 str r4, [r8] <== NOT EXECUTED return sc; } a000add8: e8bd81f8 pop {r3, r4, r5, r6, r7, r8, pc} <== NOT EXECUTED =============================================================================== a000addc : rtems_chain_control *chain, rtems_chain_node *node, rtems_id task, rtems_event_set events ) { a000addc: e92d4030 push {r4, r5, lr} <== NOT EXECUTED a000ade0: e1a04002 mov r4, r2 <== NOT EXECUTED a000ade4: 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 ); a000ade8: eb000186 bl a000b408 <_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) { a000adec: e3500000 cmp r0, #0 <== NOT EXECUTED a000adf0: 0a000003 beq a000ae04 <== NOT EXECUTED sc = rtems_event_send( task, events ); a000adf4: e1a00004 mov r0, r4 <== NOT EXECUTED a000adf8: e1a01005 mov r1, r5 <== NOT EXECUTED } return sc; } a000adfc: 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 ); a000ae00: eafffd6e b a000a3c0 <== NOT EXECUTED } return sc; } a000ae04: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a000ac74 : rtems_status_code rtems_clock_get( rtems_clock_get_options option, void *time_buffer ) { a000ac74: e92d4010 push {r4, lr} if ( !time_buffer ) a000ac78: e2514000 subs r4, r1, #0 a000ac7c: 0a000018 beq a000ace4 return RTEMS_INVALID_ADDRESS; if ( option == RTEMS_CLOCK_GET_TOD ) a000ac80: e3500000 cmp r0, #0 a000ac84: 1a000002 bne a000ac94 return rtems_clock_get_tod( (rtems_time_of_day *)time_buffer ); a000ac88: 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; } a000ac8c: 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 ); a000ac90: ea000037 b a000ad74 if ( option == RTEMS_CLOCK_GET_SECONDS_SINCE_EPOCH ) a000ac94: e3500001 cmp r0, #1 a000ac98: 1a000002 bne a000aca8 return rtems_clock_get_seconds_since_epoch((rtems_interval *)time_buffer); a000ac9c: 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; } a000aca0: 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); a000aca4: ea000012 b a000acf4 if ( option == RTEMS_CLOCK_GET_TICKS_SINCE_BOOT ) { a000aca8: e3500002 cmp r0, #2 a000acac: 1a000001 bne a000acb8 rtems_interval *interval = (rtems_interval *)time_buffer; *interval = rtems_clock_get_ticks_since_boot(); a000acb0: eb00002b bl a000ad64 <== NOT EXECUTED a000acb4: ea000002 b a000acc4 <== NOT EXECUTED return RTEMS_SUCCESSFUL; } if ( option == RTEMS_CLOCK_GET_TICKS_PER_SECOND ) { a000acb8: e3500003 cmp r0, #3 a000acbc: 1a000003 bne a000acd0 rtems_interval *interval = (rtems_interval *)time_buffer; *interval = rtems_clock_get_ticks_per_second(); a000acc0: eb00001f bl a000ad44 <== NOT EXECUTED a000acc4: e5840000 str r0, [r4] <== NOT EXECUTED return RTEMS_SUCCESSFUL; a000acc8: e3a00000 mov r0, #0 <== NOT EXECUTED a000accc: e8bd8010 pop {r4, pc} <== NOT EXECUTED } if ( option == RTEMS_CLOCK_GET_TIME_VALUE ) a000acd0: e3500004 cmp r0, #4 a000acd4: 1a000004 bne a000acec return rtems_clock_get_tod_timeval( (struct timeval *)time_buffer ); a000acd8: e1a00004 mov r0, r4 <== NOT EXECUTED return RTEMS_INVALID_NUMBER; } a000acdc: 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 ); a000ace0: ea00005c b a000ae58 <== NOT EXECUTED rtems_clock_get_options option, void *time_buffer ) { if ( !time_buffer ) return RTEMS_INVALID_ADDRESS; a000ace4: e3a00009 mov r0, #9 a000ace8: e8bd8010 pop {r4, pc} } if ( option == RTEMS_CLOCK_GET_TIME_VALUE ) return rtems_clock_get_tod_timeval( (struct timeval *)time_buffer ); return RTEMS_INVALID_NUMBER; a000acec: e3a0000a mov r0, #10 } a000acf0: e8bd8010 pop {r4, pc} =============================================================================== a000a9c4 : #include rtems_status_code rtems_clock_get_seconds_since_epoch( rtems_interval *the_interval ) { a000a9c4: e92d4010 push {r4, lr} if ( !the_interval ) a000a9c8: e2504000 subs r4, r0, #0 a000a9cc: 0a00000a beq a000a9fc return RTEMS_INVALID_ADDRESS; if ( !_TOD.is_set ) a000a9d0: e59f3034 ldr r3, [pc, #52] ; a000aa0c a000a9d4: e5d32014 ldrb r2, [r3, #20] a000a9d8: e3520000 cmp r2, #0 a000a9dc: 0a000008 beq a000aa04 static inline uint32_t _Timestamp64_implementation_Get_seconds( const Timestamp64_Control *_time ) { return (uint32_t) (*_time / 1000000000L); a000a9e0: e8930003 ldm r3, {r0, r1} a000a9e4: e59f2024 ldr r2, [pc, #36] ; a000aa10 a000a9e8: e3a03000 mov r3, #0 a000a9ec: eb004a57 bl a001d350 <__divdi3> a000a9f0: e5840000 str r0, [r4] return RTEMS_NOT_DEFINED; *the_interval = _TOD_Seconds_since_epoch(); return RTEMS_SUCCESSFUL; a000a9f4: e3a00000 mov r0, #0 a000a9f8: e8bd8010 pop {r4, pc} rtems_status_code rtems_clock_get_seconds_since_epoch( rtems_interval *the_interval ) { if ( !the_interval ) return RTEMS_INVALID_ADDRESS; a000a9fc: e3a00009 mov r0, #9 <== NOT EXECUTED a000aa00: e8bd8010 pop {r4, pc} <== NOT EXECUTED if ( !_TOD.is_set ) return RTEMS_NOT_DEFINED; a000aa04: e3a0000b mov r0, #11 <== NOT EXECUTED *the_interval = _TOD_Seconds_since_epoch(); return RTEMS_SUCCESSFUL; } a000aa08: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a0017704 : #include rtems_status_code rtems_clock_get_tod_timeval( struct timeval *time ) { a0017704: e92d40d3 push {r0, r1, r4, r6, r7, lr} if ( !time ) a0017708: e2504000 subs r4, r0, #0 return RTEMS_INVALID_ADDRESS; a001770c: 03a00009 moveq r0, #9 rtems_status_code rtems_clock_get_tod_timeval( struct timeval *time ) { if ( !time ) a0017710: 0a000017 beq a0017774 return RTEMS_INVALID_ADDRESS; if ( !_TOD.is_set ) a0017714: e59f105c ldr r1, [pc, #92] ; a0017778 a0017718: e5d13014 ldrb r3, [r1, #20] a001771c: e3530000 cmp r3, #0 return RTEMS_NOT_DEFINED; a0017720: 03a0000b moveq r0, #11 ) { if ( !time ) return RTEMS_INVALID_ADDRESS; if ( !_TOD.is_set ) a0017724: 0a000012 beq a0017774 ) { Timestamp_Control snapshot_as_timestamp; Timestamp_Control *snapshot_as_timestamp_ptr; snapshot_as_timestamp_ptr = a0017728: e1a0000d mov r0, sp <== NOT EXECUTED a001772c: ebffd662 bl a000d0bc <_TOD_Get_with_nanoseconds> <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timeval( const Timestamp64_Control *_timestamp, struct timeval *_timeval ) { _timeval->tv_sec = (time_t) (*_timestamp / 1000000000U); a0017730: e59f2044 ldr r2, [pc, #68] ; a001777c <== NOT EXECUTED return RTEMS_NOT_DEFINED; _TOD_Get_timeval( time ); return RTEMS_SUCCESSFUL; } a0017734: e89000c0 ldm r0, {r6, r7} <== NOT EXECUTED a0017738: e3a03000 mov r3, #0 <== NOT EXECUTED a001773c: e1a00006 mov r0, r6 <== NOT EXECUTED a0017740: e1a01007 mov r1, r7 <== NOT EXECUTED a0017744: ebffb81b bl a00057b8 <__divdi3> <== NOT EXECUTED _timeval->tv_usec = (suseconds_t) ((*_timestamp % 1000000000U) / 1000U); a0017748: e59f202c ldr r2, [pc, #44] ; a001777c <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timeval( const Timestamp64_Control *_timestamp, struct timeval *_timeval ) { _timeval->tv_sec = (time_t) (*_timestamp / 1000000000U); a001774c: e5840000 str r0, [r4] <== NOT EXECUTED _timeval->tv_usec = (suseconds_t) ((*_timestamp % 1000000000U) / 1000U); a0017750: e3a03000 mov r3, #0 <== NOT EXECUTED a0017754: e1a00006 mov r0, r6 <== NOT EXECUTED a0017758: e1a01007 mov r1, r7 <== NOT EXECUTED a001775c: eb004db0 bl a002ae24 <__moddi3> <== NOT EXECUTED a0017760: e3a02ffa mov r2, #1000 ; 0x3e8 <== NOT EXECUTED a0017764: e3a03000 mov r3, #0 <== NOT EXECUTED a0017768: ebffb812 bl a00057b8 <__divdi3> <== NOT EXECUTED a001776c: e5840004 str r0, [r4, #4] <== NOT EXECUTED if ( !_TOD.is_set ) return RTEMS_NOT_DEFINED; _TOD_Get_timeval( time ); return RTEMS_SUCCESSFUL; a0017770: e3a00000 mov r0, #0 <== NOT EXECUTED } a0017774: e8bd80dc pop {r2, r3, r4, r6, r7, pc} =============================================================================== a00269dc : */ rtems_status_code rtems_clock_get_uptime( struct timespec *uptime ) { if ( !uptime ) a00269dc: e3500000 cmp r0, #0 <== NOT EXECUTED * error code - if unsuccessful */ rtems_status_code rtems_clock_get_uptime( struct timespec *uptime ) { a00269e0: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED if ( !uptime ) a00269e4: 0a000002 beq a00269f4 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; _TOD_Get_uptime_as_timespec( uptime ); a00269e8: eb00022d bl a00272a4 <_TOD_Get_uptime_as_timespec> <== NOT EXECUTED return RTEMS_SUCCESSFUL; a00269ec: e3a00000 mov r0, #0 <== NOT EXECUTED a00269f0: 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; a00269f4: e3a00009 mov r0, #9 <== NOT EXECUTED _TOD_Get_uptime_as_timespec( uptime ); return RTEMS_SUCCESSFUL; } a00269f8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a0015d94 : #endif #include time_t rtems_clock_get_uptime_seconds( void ) { a0015d94: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0015d98: e10f3000 mrs r3, CPSR <== NOT EXECUTED a0015d9c: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED a0015da0: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED Timestamp_Control snapshot_as_timestamp; struct timespec snapshot_as_timespec; ISR_Level level; _ISR_Disable( level ); snapshot_as_timestamp = _TOD.uptime; a0015da4: e59f2018 ldr r2, [pc, #24] ; a0015dc4 <== NOT EXECUTED a0015da8: e2821008 add r1, r2, #8 <== NOT EXECUTED a0015dac: e8910003 ldm r1, {r0, r1} <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0015db0: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0015db4: e59f200c ldr r2, [pc, #12] ; a0015dc8 <== NOT EXECUTED a0015db8: e3a03000 mov r3, #0 <== NOT EXECUTED a0015dbc: eb005c08 bl a002cde4 <__divdi3> <== NOT EXECUTED _ISR_Enable( level ); _Timestamp_To_timespec( &snapshot_as_timestamp, &snapshot_as_timespec ); return snapshot_as_timespec.tv_sec; } a0015dc0: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a0015dcc : #endif #include void rtems_clock_get_uptime_timeval( struct timeval *uptime ) { a0015dcc: e92d40d3 push {r0, r1, r4, r6, r7, lr} <== NOT EXECUTED a0015dd0: e1a04000 mov r4, r0 <== NOT EXECUTED */ static inline void _TOD_Get_uptime( Timestamp_Control *time ) { _TOD_Get_with_nanoseconds( time, &_TOD.uptime ); a0015dd4: e59f1048 ldr r1, [pc, #72] ; a0015e24 <== NOT EXECUTED a0015dd8: e1a0000d mov r0, sp <== NOT EXECUTED a0015ddc: eb0011d3 bl a001a530 <_TOD_Get_with_nanoseconds> <== NOT EXECUTED Timestamp_Control snapshot_as_timestamp; _TOD_Get_uptime( &snapshot_as_timestamp ); _Timestamp_To_timeval( &snapshot_as_timestamp, uptime ); a0015de0: e89d00c0 ldm sp, {r6, r7} <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timeval( const Timestamp64_Control *_timestamp, struct timeval *_timeval ) { _timeval->tv_sec = (time_t) (*_timestamp / 1000000000U); a0015de4: e59f203c ldr r2, [pc, #60] ; a0015e28 <== NOT EXECUTED a0015de8: e3a03000 mov r3, #0 <== NOT EXECUTED a0015dec: e1a00006 mov r0, r6 <== NOT EXECUTED a0015df0: e1a01007 mov r1, r7 <== NOT EXECUTED a0015df4: eb005bfa bl a002cde4 <__divdi3> <== NOT EXECUTED _timeval->tv_usec = (suseconds_t) ((*_timestamp % 1000000000U) / 1000U); a0015df8: e59f2028 ldr r2, [pc, #40] ; a0015e28 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timeval( const Timestamp64_Control *_timestamp, struct timeval *_timeval ) { _timeval->tv_sec = (time_t) (*_timestamp / 1000000000U); a0015dfc: e5840000 str r0, [r4] <== NOT EXECUTED _timeval->tv_usec = (suseconds_t) ((*_timestamp % 1000000000U) / 1000U); a0015e00: e3a03000 mov r3, #0 <== NOT EXECUTED a0015e04: e1a00006 mov r0, r6 <== NOT EXECUTED a0015e08: e1a01007 mov r1, r7 <== NOT EXECUTED a0015e0c: eb005d2f bl a002d2d0 <__moddi3> <== NOT EXECUTED a0015e10: e3a02ffa mov r2, #1000 ; 0x3e8 <== NOT EXECUTED a0015e14: e3a03000 mov r3, #0 <== NOT EXECUTED a0015e18: eb005bf1 bl a002cde4 <__divdi3> <== NOT EXECUTED a0015e1c: e5840004 str r0, [r4, #4] <== NOT EXECUTED } a0015e20: e8bd80dc pop {r2, r3, r4, r6, r7, pc} <== NOT EXECUTED =============================================================================== a0009b08 : #include #include #include rtems_status_code rtems_clock_tick( void ) { a0009b08: e52de004 push {lr} ; (str lr, [sp, #-4]!) _TOD_Tickle_ticks(); a0009b0c: eb00053b bl a000b000 <_TOD_Tickle_ticks> */ RTEMS_INLINE_ROUTINE void _Watchdog_Tickle_ticks( void ) { _Watchdog_Tickle( &_Watchdog_Ticks_chain ); a0009b10: e59f0038 ldr r0, [pc, #56] ; a0009b50 a0009b14: eb000e95 bl a000d570 <_Watchdog_Tickle> * scheduler which support standard RTEMS features, this includes * time-slicing management. */ RTEMS_INLINE_ROUTINE void _Scheduler_Tick( void ) { _Scheduler.Operations.tick(); a0009b18: e59f3034 ldr r3, [pc, #52] ; a0009b54 a0009b1c: e5933038 ldr r3, [r3, #56] ; 0x38 a0009b20: e12fff33 blx r3 * otherwise. */ RTEMS_INLINE_ROUTINE bool _Thread_Is_context_switch_necessary( void ) { return ( _Thread_Dispatch_necessary ); a0009b24: e59f302c ldr r3, [pc, #44] ; a0009b58 a0009b28: e5d33004 ldrb r3, [r3, #4] _Watchdog_Tickle_ticks(); _Scheduler_Tick(); if ( _Thread_Is_context_switch_necessary() && a0009b2c: e3530000 cmp r3, #0 a0009b30: 0a000004 beq a0009b48 * This routine returns true if thread dispatch indicates * that we are in a critical section. */ RTEMS_INLINE_ROUTINE bool _Thread_Dispatch_in_critical_section(void) { if ( _Thread_Dispatch_disable_level == 0 ) a0009b34: e59f3020 ldr r3, [pc, #32] ; a0009b5c <== NOT EXECUTED a0009b38: e5933000 ldr r3, [r3] <== NOT EXECUTED a0009b3c: e3530000 cmp r3, #0 <== NOT EXECUTED a0009b40: 1a000000 bne a0009b48 <== NOT EXECUTED _Thread_Is_dispatching_enabled() ) _Thread_Dispatch(); a0009b44: eb000acd bl a000c680 <_Thread_Dispatch> <== NOT EXECUTED return RTEMS_SUCCESSFUL; } a0009b48: e3a00000 mov r0, #0 a0009b4c: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a000c580 : rtems_status_code rtems_extension_ident( rtems_name name, rtems_id *id ) { a000c580: e1a02000 mov r2, r0 <== NOT EXECUTED a000c584: e1a03001 mov r3, r1 <== NOT EXECUTED a000c588: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED Objects_Name_or_id_lookup_errors status; status = _Objects_Name_to_id_u32( a000c58c: e1a01002 mov r1, r2 <== NOT EXECUTED a000c590: e59f0010 ldr r0, [pc, #16] ; a000c5a8 <== NOT EXECUTED a000c594: e3e02102 mvn r2, #-2147483648 ; 0x80000000 <== NOT EXECUTED a000c598: eb0004c9 bl a000d8c4 <_Objects_Name_to_id_u32> <== NOT EXECUTED OBJECTS_SEARCH_LOCAL_NODE, id ); return _Status_Object_name_errors_to_status[ status ]; } a000c59c: e59f3008 ldr r3, [pc, #8] ; a000c5ac <== NOT EXECUTED a000c5a0: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED a000c5a4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000aa78 : uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000aa78: e10f0000 mrs r0, CPSR <== NOT EXECUTED a000aa7c: e3803080 orr r3, r0, #128 ; 0x80 <== NOT EXECUTED a000aa80: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED rtems_interrupt_level previous_level; _ISR_Disable( previous_level ); return previous_level; } a000aa84: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000aa88 : static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000aa88: e129f000 msr CPSR_fc, r0 <== NOT EXECUTED void rtems_interrupt_enable( rtems_interrupt_level previous_level ) { _ISR_Enable( previous_level ); } a000aa8c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000aa90 : static inline void arm_interrupt_flash( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000aa90: e10f3000 mrs r3, CPSR <== NOT EXECUTED a000aa94: e129f000 msr CPSR_fc, r0 <== NOT EXECUTED a000aa98: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED void rtems_interrupt_flash( rtems_interrupt_level previous_level ) { _ISR_Flash( previous_level ); } a000aa9c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000aaa0 : #undef rtems_interrupt_is_in_progress bool rtems_interrupt_is_in_progress( void ) { return _ISR_Is_in_progress(); a000aaa0: e59f300c ldr r3, [pc, #12] ; a000aab4 <== NOT EXECUTED a000aaa4: e5930000 ldr r0, [r3] <== NOT EXECUTED } a000aaa8: e2900000 adds r0, r0, #0 <== NOT EXECUTED a000aaac: 13a00001 movne r0, #1 <== NOT EXECUTED a000aab0: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000aab8 : Modes_Control rtems_interrupt_level_body( uint32_t level ) { return RTEMS_INTERRUPT_LEVEL(level); } a000aab8: e2000080 and r0, r0, #128 ; 0x80 <== NOT EXECUTED a000aabc: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a001157c : void *argument ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a001157c: e59fc044 ldr ip, [pc, #68] ; a00115c8 rtems_status_code rtems_io_close( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a0011580: e92d4010 push {r4, lr} rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a0011584: e59cc000 ldr ip, [ip] rtems_status_code rtems_io_close( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a0011588: e1a03000 mov r3, r0 rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a001158c: e150000c cmp r0, ip a0011590: 2a000008 bcs a00115b8 return RTEMS_INVALID_NUMBER; callout = _IO_Driver_address_table[major].close_entry; a0011594: e59fc030 ldr ip, [pc, #48] ; a00115cc a0011598: e3a04018 mov r4, #24 a001159c: e59cc000 ldr ip, [ip] a00115a0: e023c394 mla r3, r4, r3, ip a00115a4: e5933008 ldr r3, [r3, #8] return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a00115a8: e3530000 cmp r3, #0 a00115ac: 0a000003 beq a00115c0 a00115b0: e12fff33 blx r3 a00115b4: e8bd8010 pop {r4, pc} ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) return RTEMS_INVALID_NUMBER; a00115b8: e3a0000a mov r0, #10 <== NOT EXECUTED a00115bc: e8bd8010 pop {r4, pc} <== NOT EXECUTED callout = _IO_Driver_address_table[major].close_entry; return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a00115c0: e1a00003 mov r0, r3 } a00115c4: e8bd8010 pop {r4, pc} =============================================================================== a00115d0 : void *argument ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a00115d0: e59fc044 ldr ip, [pc, #68] ; a001161c rtems_status_code rtems_io_control( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a00115d4: e92d4010 push {r4, lr} rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a00115d8: e59cc000 ldr ip, [ip] rtems_status_code rtems_io_control( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a00115dc: e1a03000 mov r3, r0 rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a00115e0: e150000c cmp r0, ip a00115e4: 2a000008 bcs a001160c return RTEMS_INVALID_NUMBER; callout = _IO_Driver_address_table[major].control_entry; a00115e8: e59fc030 ldr ip, [pc, #48] ; a0011620 a00115ec: e3a04018 mov r4, #24 a00115f0: e59cc000 ldr ip, [ip] a00115f4: e023c394 mla r3, r4, r3, ip a00115f8: e5933014 ldr r3, [r3, #20] return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a00115fc: e3530000 cmp r3, #0 a0011600: 0a000003 beq a0011614 a0011604: e12fff33 blx r3 a0011608: e8bd8010 pop {r4, pc} ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) return RTEMS_INVALID_NUMBER; a001160c: e3a0000a mov r0, #10 <== NOT EXECUTED a0011610: e8bd8010 pop {r4, pc} <== NOT EXECUTED callout = _IO_Driver_address_table[major].control_entry; return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a0011614: e1a00003 mov r0, r3 <== NOT EXECUTED } a0011618: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000f730 : void *argument ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a000f730: e59fc044 ldr ip, [pc, #68] ; a000f77c rtems_status_code rtems_io_initialize( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a000f734: e92d4010 push {r4, lr} rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a000f738: e59cc000 ldr ip, [ip] rtems_status_code rtems_io_initialize( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a000f73c: e1a03000 mov r3, r0 rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a000f740: e150000c cmp r0, ip a000f744: 2a000008 bcs a000f76c return RTEMS_INVALID_NUMBER; callout = _IO_Driver_address_table[major].initialization_entry; a000f748: e59fc030 ldr ip, [pc, #48] ; a000f780 a000f74c: e3a04018 mov r4, #24 a000f750: e0030394 mul r3, r4, r3 a000f754: e59cc000 ldr ip, [ip] a000f758: e79c3003 ldr r3, [ip, r3] return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a000f75c: e3530000 cmp r3, #0 a000f760: 0a000003 beq a000f774 a000f764: e12fff33 blx r3 a000f768: e8bd8010 pop {r4, pc} ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) return RTEMS_INVALID_NUMBER; a000f76c: e3a0000a mov r0, #10 <== NOT EXECUTED a000f770: e8bd8010 pop {r4, pc} <== NOT EXECUTED callout = _IO_Driver_address_table[major].initialization_entry; return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a000f774: e1a00003 mov r0, r3 } a000f778: e8bd8010 pop {r4, pc} =============================================================================== a0011624 : void *argument ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a0011624: e59fc044 ldr ip, [pc, #68] ; a0011670 rtems_status_code rtems_io_open( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a0011628: e92d4010 push {r4, lr} rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a001162c: e59cc000 ldr ip, [ip] rtems_status_code rtems_io_open( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a0011630: e1a03000 mov r3, r0 rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a0011634: e150000c cmp r0, ip a0011638: 2a000008 bcs a0011660 return RTEMS_INVALID_NUMBER; callout = _IO_Driver_address_table[major].open_entry; a001163c: e59fc030 ldr ip, [pc, #48] ; a0011674 a0011640: e3a04018 mov r4, #24 a0011644: e59cc000 ldr ip, [ip] a0011648: e023c394 mla r3, r4, r3, ip a001164c: e5933004 ldr r3, [r3, #4] return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a0011650: e3530000 cmp r3, #0 a0011654: 0a000003 beq a0011668 a0011658: e12fff33 blx r3 a001165c: e8bd8010 pop {r4, pc} ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) return RTEMS_INVALID_NUMBER; a0011660: e3a0000a mov r0, #10 <== NOT EXECUTED a0011664: e8bd8010 pop {r4, pc} <== NOT EXECUTED callout = _IO_Driver_address_table[major].open_entry; return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a0011668: e1a00003 mov r0, r3 } a001166c: e8bd8010 pop {r4, pc} =============================================================================== a0011678 : void *argument ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a0011678: e59fc044 ldr ip, [pc, #68] ; a00116c4 rtems_status_code rtems_io_read( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a001167c: e92d4010 push {r4, lr} rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a0011680: e59cc000 ldr ip, [ip] rtems_status_code rtems_io_read( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a0011684: e1a03000 mov r3, r0 rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a0011688: e150000c cmp r0, ip a001168c: 2a000008 bcs a00116b4 return RTEMS_INVALID_NUMBER; callout = _IO_Driver_address_table[major].read_entry; a0011690: e59fc030 ldr ip, [pc, #48] ; a00116c8 a0011694: e3a04018 mov r4, #24 a0011698: e59cc000 ldr ip, [ip] a001169c: e023c394 mla r3, r4, r3, ip a00116a0: e593300c ldr r3, [r3, #12] return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a00116a4: e3530000 cmp r3, #0 a00116a8: 0a000003 beq a00116bc a00116ac: e12fff33 blx r3 a00116b0: e8bd8010 pop {r4, pc} ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) return RTEMS_INVALID_NUMBER; a00116b4: e3a0000a mov r0, #10 <== NOT EXECUTED a00116b8: e8bd8010 pop {r4, pc} <== NOT EXECUTED callout = _IO_Driver_address_table[major].read_entry; return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a00116bc: e1a00003 mov r0, r3 } a00116c0: e8bd8010 pop {r4, pc} =============================================================================== a000baf8 : 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 ) { a000baf8: e92d4010 push {r4, lr} a000bafc: e1a04000 mov r4, r0 rtems_device_major_number major_limit = _IO_Number_of_drivers; if ( rtems_interrupt_is_in_progress() ) a000bb00: e59f015c ldr r0, [pc, #348] ; a000bc64 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; a000bb04: e59f315c ldr r3, [pc, #348] ; a000bc68 if ( rtems_interrupt_is_in_progress() ) a000bb08: 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; a000bb0c: e5933000 ldr r3, [r3] if ( rtems_interrupt_is_in_progress() ) a000bb10: e3500000 cmp r0, #0 a000bb14: 1a000043 bne a000bc28 return RTEMS_CALLED_FROM_ISR; if ( registered_major == NULL ) a000bb18: e3520000 cmp r2, #0 a000bb1c: 0a000043 beq a000bc30 return RTEMS_INVALID_ADDRESS; /* Set it to an invalid value */ *registered_major = major_limit; if ( driver_table == NULL ) a000bb20: e3510000 cmp r1, #0 if ( registered_major == NULL ) return RTEMS_INVALID_ADDRESS; /* Set it to an invalid value */ *registered_major = major_limit; a000bb24: e5823000 str r3, [r2] if ( driver_table == NULL ) a000bb28: 0a000040 beq a000bc30 static inline bool rtems_io_is_empty_table( const rtems_driver_address_table *table ) { return table->initialization_entry == NULL && table->open_entry == NULL; a000bb2c: e5910000 ldr r0, [r1] a000bb30: e3500000 cmp r0, #0 a000bb34: 1a000041 bne a000bc40 a000bb38: e5910004 ldr r0, [r1, #4] a000bb3c: e3500000 cmp r0, #0 a000bb40: 1a00003e bne a000bc40 a000bb44: ea000039 b a000bc30 <== NOT EXECUTED * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000bb48: e59f311c ldr r3, [pc, #284] ; a000bc6c a000bb4c: e5930000 ldr r0, [r3] ++level; a000bb50: e2800001 add r0, r0, #1 _Thread_Dispatch_disable_level = level; a000bb54: e5830000 str r0, [r3] if ( major >= major_limit ) return RTEMS_INVALID_NUMBER; _Thread_Disable_dispatch(); if ( major == 0 ) { a000bb58: e3540000 cmp r4, #0 a000bb5c: e59f010c ldr r0, [pc, #268] ; a000bc70 a000bb60: 1a000010 bne a000bba8 static rtems_status_code rtems_io_obtain_major_number( rtems_device_major_number *major ) { rtems_device_major_number n = _IO_Number_of_drivers; a000bb64: e59f30fc ldr r3, [pc, #252] ; a000bc68 a000bb68: e593c000 ldr ip, [r3] a000bb6c: e5903000 ldr r3, [r0] a000bb70: ea000006 b a000bb90 static inline bool rtems_io_is_empty_table( const rtems_driver_address_table *table ) { return table->initialization_entry == NULL && table->open_entry == NULL; a000bb74: e5930000 ldr r0, [r3] a000bb78: e3500000 cmp r0, #0 a000bb7c: 1a000032 bne a000bc4c a000bb80: e5930004 ldr r0, [r3, #4] a000bb84: e3500000 cmp r0, #0 a000bb88: 1a00002f bne a000bc4c a000bb8c: ea000001 b a000bb98 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 ) { a000bb90: e154000c cmp r4, ip a000bb94: 1afffff6 bne a000bb74 } /* Assigns invalid value in case of failure */ *major = m; if ( m != n ) a000bb98: e154000c cmp r4, ip if ( rtems_io_is_empty_table( table ) ) break; } /* Assigns invalid value in case of failure */ *major = m; a000bb9c: e5824000 str r4, [r2] if ( m != n ) a000bba0: 1a000011 bne a000bbec a000bba4: ea00002b b a000bc58 _Thread_Enable_dispatch(); return sc; } major = *registered_major; } else { rtems_driver_address_table *const table = _IO_Driver_address_table + major; a000bba8: e3a03018 mov r3, #24 a000bbac: e0030394 mul r3, r4, r3 a000bbb0: e5900000 ldr r0, [r0] a000bbb4: 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; a000bbb8: e7903003 ldr r3, [r0, r3] a000bbbc: e3530000 cmp r3, #0 a000bbc0: 13a03000 movne r3, #0 a000bbc4: 1a000002 bne a000bbd4 return RTEMS_SUCCESSFUL; return RTEMS_TOO_MANY; } rtems_status_code rtems_io_register_driver( a000bbc8: e59c3004 ldr r3, [ip, #4] a000bbcc: e2733001 rsbs r3, r3, #1 a000bbd0: 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 ) ) { a000bbd4: e3530000 cmp r3, #0 _Thread_Enable_dispatch(); return RTEMS_RESOURCE_IN_USE; } *registered_major = major; a000bbd8: 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 ) ) { a000bbdc: 1a000002 bne a000bbec _Thread_Enable_dispatch(); a000bbe0: eb000753 bl a000d934 <_Thread_Enable_dispatch> return RTEMS_RESOURCE_IN_USE; a000bbe4: e3a0000c mov r0, #12 a000bbe8: e8bd8010 pop {r4, pc} } *registered_major = major; } _IO_Driver_address_table [major] = *driver_table; a000bbec: e59f307c ldr r3, [pc, #124] ; a000bc70 a000bbf0: e3a0c018 mov ip, #24 a000bbf4: e1a0e001 mov lr, r1 a000bbf8: e5933000 ldr r3, [r3] a000bbfc: e02c3c94 mla ip, r4, ip, r3 a000bc00: e8be000f ldm lr!, {r0, r1, r2, r3} a000bc04: e8ac000f stmia ip!, {r0, r1, r2, r3} a000bc08: e89e0003 ldm lr, {r0, r1} a000bc0c: e88c0003 stm ip, {r0, r1} _Thread_Enable_dispatch(); a000bc10: eb000747 bl a000d934 <_Thread_Enable_dispatch> return rtems_io_initialize( major, 0, NULL ); a000bc14: e3a01000 mov r1, #0 a000bc18: e1a00004 mov r0, r4 a000bc1c: e1a02001 mov r2, r1 } a000bc20: e8bd4010 pop {r4, lr} _IO_Driver_address_table [major] = *driver_table; _Thread_Enable_dispatch(); return rtems_io_initialize( major, 0, NULL ); a000bc24: ea001e5f b a00135a8 ) { rtems_device_major_number major_limit = _IO_Number_of_drivers; if ( rtems_interrupt_is_in_progress() ) return RTEMS_CALLED_FROM_ISR; a000bc28: e3a00012 mov r0, #18 <== NOT EXECUTED a000bc2c: 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; a000bc30: e3a00009 mov r0, #9 <== NOT EXECUTED a000bc34: e8bd8010 pop {r4, pc} <== NOT EXECUTED if ( major >= major_limit ) return RTEMS_INVALID_NUMBER; a000bc38: e3a0000a mov r0, #10 <== NOT EXECUTED _IO_Driver_address_table [major] = *driver_table; _Thread_Enable_dispatch(); return rtems_io_initialize( major, 0, NULL ); } a000bc3c: 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 ) a000bc40: e1540003 cmp r4, r3 a000bc44: 2afffffb bcs a000bc38 a000bc48: eaffffbe b a000bb48 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 ) { a000bc4c: e2844001 add r4, r4, #1 a000bc50: e2833018 add r3, r3, #24 a000bc54: eaffffcd b a000bb90 if ( major == 0 ) { rtems_status_code sc = rtems_io_obtain_major_number( registered_major ); if ( sc != RTEMS_SUCCESSFUL ) { _Thread_Enable_dispatch(); a000bc58: eb000735 bl a000d934 <_Thread_Enable_dispatch> *major = m; if ( m != n ) return RTEMS_SUCCESSFUL; return RTEMS_TOO_MANY; a000bc5c: 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; a000bc60: e8bd8010 pop {r4, pc} =============================================================================== a000bc74 : rtems_status_code rtems_io_unregister_driver( rtems_device_major_number major ) { if ( rtems_interrupt_is_in_progress() ) a000bc74: e59f3060 ldr r3, [pc, #96] ; a000bcdc #include rtems_status_code rtems_io_unregister_driver( rtems_device_major_number major ) { a000bc78: e92d4010 push {r4, lr} if ( rtems_interrupt_is_in_progress() ) a000bc7c: e5934000 ldr r4, [r3] a000bc80: e3540000 cmp r4, #0 a000bc84: 1a000010 bne a000bccc return RTEMS_CALLED_FROM_ISR; if ( major < _IO_Number_of_drivers ) { a000bc88: e59f3050 ldr r3, [pc, #80] ; a000bce0 a000bc8c: e5933000 ldr r3, [r3] a000bc90: e1500003 cmp r0, r3 a000bc94: 2a00000e bcs a000bcd4 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000bc98: e59f3044 ldr r3, [pc, #68] ; a000bce4 a000bc9c: e5932000 ldr r2, [r3] ++level; a000bca0: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000bca4: e5832000 str r2, [r3] _Thread_Disable_dispatch(); memset( a000bca8: e59f3038 ldr r3, [pc, #56] ; a000bce8 &_IO_Driver_address_table[major], a000bcac: 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( a000bcb0: e1a01004 mov r1, r4 a000bcb4: e5933000 ldr r3, [r3] a000bcb8: e0203092 mla r0, r2, r0, r3 a000bcbc: eb002949 bl a00161e8 &_IO_Driver_address_table[major], 0, sizeof( rtems_driver_address_table ) ); _Thread_Enable_dispatch(); a000bcc0: eb00071b bl a000d934 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000bcc4: e1a00004 mov r0, r4 a000bcc8: 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; a000bccc: e3a00012 mov r0, #18 <== NOT EXECUTED a000bcd0: e8bd8010 pop {r4, pc} <== NOT EXECUTED _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_UNSATISFIED; a000bcd4: e3a0000d mov r0, #13 <== NOT EXECUTED } a000bcd8: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a00116cc : void *argument ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a00116cc: e59fc044 ldr ip, [pc, #68] ; a0011718 rtems_status_code rtems_io_write( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a00116d0: e92d4010 push {r4, lr} rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a00116d4: e59cc000 ldr ip, [ip] rtems_status_code rtems_io_write( rtems_device_major_number major, rtems_device_minor_number minor, void *argument ) { a00116d8: e1a03000 mov r3, r0 rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) a00116dc: e150000c cmp r0, ip a00116e0: 2a000008 bcs a0011708 return RTEMS_INVALID_NUMBER; callout = _IO_Driver_address_table[major].write_entry; a00116e4: e59fc030 ldr ip, [pc, #48] ; a001171c a00116e8: e3a04018 mov r4, #24 a00116ec: e59cc000 ldr ip, [ip] a00116f0: e023c394 mla r3, r4, r3, ip a00116f4: e5933010 ldr r3, [r3, #16] return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a00116f8: e3530000 cmp r3, #0 a00116fc: 0a000003 beq a0011710 a0011700: e12fff33 blx r3 a0011704: e8bd8010 pop {r4, pc} ) { rtems_device_driver_entry callout; if ( major >= _IO_Number_of_drivers ) return RTEMS_INVALID_NUMBER; a0011708: e3a0000a mov r0, #10 <== NOT EXECUTED a001170c: e8bd8010 pop {r4, pc} <== NOT EXECUTED callout = _IO_Driver_address_table[major].write_entry; return callout ? callout(major, minor, argument) : RTEMS_SUCCESSFUL; a0011710: e1a00003 mov r0, r3 <== NOT EXECUTED } a0011714: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a00165f4 : rtems_id id, const void *buffer, size_t size, uint32_t *count ) { a00165f4: 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 ) a00165f8: e2517000 subs r7, r1, #0 rtems_id id, const void *buffer, size_t size, uint32_t *count ) { a00165fc: e1a04000 mov r4, r0 a0016600: e1a05002 mov r5, r2 a0016604: e1a06003 mov r6, r3 register Message_queue_Control *the_message_queue; Objects_Locations location; CORE_message_queue_Status core_status; if ( !buffer ) a0016608: 0a000014 beq a0016660 return RTEMS_INVALID_ADDRESS; if ( !count ) a001660c: e3530000 cmp r3, #0 a0016610: 0a000012 beq a0016660 RTEMS_INLINE_ROUTINE Message_queue_Control *_Message_queue_Get ( Objects_Id id, Objects_Locations *location ) { return (Message_queue_Control *) a0016614: e59f004c ldr r0, [pc, #76] ; a0016668 a0016618: e1a01004 mov r1, r4 a001661c: e28d2008 add r2, sp, #8 a0016620: eb001504 bl a001ba38 <_Objects_Get> return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { a0016624: e59d3008 ldr r3, [sp, #8] a0016628: e3530000 cmp r3, #0 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a001662c: 13a00004 movne r0, #4 if ( !count ) return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { a0016630: 1a00000b bne a0016664 case OBJECTS_LOCAL: core_status = _CORE_message_queue_Broadcast( a0016634: e88d0048 stm sp, {r3, r6} a0016638: e1a01007 mov r1, r7 a001663c: e1a03004 mov r3, r4 a0016640: e1a02005 mov r2, r5 a0016644: e2800014 add r0, r0, #20 a0016648: eb000dc1 bl a0019d54 <_CORE_message_queue_Broadcast> a001664c: e1a04000 mov r4, r0 NULL, #endif count ); _Thread_Enable_dispatch(); a0016650: eb00188b bl a001c884 <_Thread_Enable_dispatch> return a0016654: e1a00004 mov r0, r4 a0016658: eb0000cd bl a0016994 <_Message_queue_Translate_core_message_queue_return_code> a001665c: ea000000 b a0016664 if ( !buffer ) return RTEMS_INVALID_ADDRESS; if ( !count ) return RTEMS_INVALID_ADDRESS; a0016660: e3a00009 mov r0, #9 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0016664: e8bd80fe pop {r1, r2, r3, r4, r5, r6, r7, pc} =============================================================================== a0011788 : uint32_t count, size_t max_message_size, rtems_attribute attribute_set, rtems_id *id ) { a0011788: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr} #if defined(RTEMS_MULTIPROCESSING) bool is_global; size_t max_packet_payload_size; #endif if ( !rtems_is_name_valid( name ) ) a001178c: e2507000 subs r7, r0, #0 uint32_t count, size_t max_message_size, rtems_attribute attribute_set, rtems_id *id ) { a0011790: e1a06001 mov r6, r1 a0011794: e1a05002 mov r5, r2 a0011798: e1a0a003 mov sl, r3 a001179c: e59d8020 ldr r8, [sp, #32] bool is_global; size_t max_packet_payload_size; #endif if ( !rtems_is_name_valid( name ) ) return RTEMS_INVALID_NAME; a00117a0: 03a00003 moveq r0, #3 #if defined(RTEMS_MULTIPROCESSING) bool is_global; size_t max_packet_payload_size; #endif if ( !rtems_is_name_valid( name ) ) a00117a4: 0a00002e beq a0011864 return RTEMS_INVALID_NAME; if ( !id ) a00117a8: e3580000 cmp r8, #0 return RTEMS_INVALID_ADDRESS; a00117ac: 03a00009 moveq r0, #9 #endif if ( !rtems_is_name_valid( name ) ) return RTEMS_INVALID_NAME; if ( !id ) a00117b0: 0a00002b beq a0011864 if ( (is_global = _Attributes_Is_global( attribute_set ) ) && !_System_state_Is_multiprocessing ) return RTEMS_MP_NOT_CONFIGURED; #endif if ( count == 0 ) a00117b4: e3510000 cmp r1, #0 return RTEMS_INVALID_NUMBER; a00117b8: 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 ) a00117bc: 0a000028 beq a0011864 return RTEMS_INVALID_NUMBER; if ( max_message_size == 0 ) a00117c0: e3520000 cmp r2, #0 return RTEMS_INVALID_SIZE; a00117c4: 03a00008 moveq r0, #8 #endif if ( count == 0 ) return RTEMS_INVALID_NUMBER; if ( max_message_size == 0 ) a00117c8: 0a000025 beq a0011864 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a00117cc: e59f3094 ldr r3, [pc, #148] ; a0011868 a00117d0: e5932000 ldr r2, [r3] ++level; a00117d4: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a00117d8: e5832000 str r2, [r3] #endif #endif _Thread_Disable_dispatch(); /* protects object pointer */ the_message_queue = _Message_queue_Allocate(); a00117dc: eb0017c6 bl a00176fc <_Message_queue_Allocate> if ( !the_message_queue ) { a00117e0: e2504000 subs r4, r0, #0 a00117e4: 1a000002 bne a00117f4 _Thread_Enable_dispatch(); a00117e8: eb000c85 bl a0014a04 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_TOO_MANY; a00117ec: e3a00005 mov r0, #5 <== NOT EXECUTED a00117f0: ea00001b b a0011864 <== NOT EXECUTED #endif the_message_queue->attribute_set = attribute_set; if (_Attributes_Is_priority( attribute_set ) ) the_msgq_attributes.discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_PRIORITY; a00117f4: e31a0004 tst sl, #4 a00117f8: 03a03000 moveq r3, #0 a00117fc: 13a03001 movne r3, #1 _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } #endif the_message_queue->attribute_set = attribute_set; a0011800: e28d1004 add r1, sp, #4 a0011804: e5213004 str r3, [r1, #-4]! a0011808: e584a010 str sl, [r4, #16] 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; if ( ! _CORE_message_queue_Initialize( a001180c: e2840014 add r0, r4, #20 a0011810: e1a0100d mov r1, sp a0011814: e1a02006 mov r2, r6 a0011818: e1a03005 mov r3, r5 a001181c: eb0004b0 bl a0012ae4 <_CORE_message_queue_Initialize> a0011820: e3500000 cmp r0, #0 a0011824: 1a000005 bne a0011840 */ RTEMS_INLINE_ROUTINE void _Message_queue_Free ( Message_queue_Control *the_message_queue ) { _Objects_Free( &_Message_queue_Information, &the_message_queue->Object ); a0011828: e59f003c ldr r0, [pc, #60] ; a001186c a001182c: e1a01004 mov r1, r4 a0011830: eb000888 bl a0013a58 <_Objects_Free> _Objects_MP_Close( &_Message_queue_Information, the_message_queue->Object.id); #endif _Message_queue_Free( the_message_queue ); _Thread_Enable_dispatch(); a0011834: eb000c72 bl a0014a04 <_Thread_Enable_dispatch> return RTEMS_UNSATISFIED; a0011838: e3a0000d mov r0, #13 a001183c: ea000008 b a0011864 #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a0011840: e59f2024 ldr r2, [pc, #36] ; a001186c Objects_Information *information, Objects_Control *the_object, Objects_Name name ) { _Objects_Set_local_object( a0011844: e5943008 ldr r3, [r4, #8] a0011848: e1d410b8 ldrh r1, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a001184c: e592201c ldr r2, [r2, #28] a0011850: e7824101 str r4, [r2, r1, lsl #2] information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name; a0011854: e584700c str r7, [r4, #12] &_Message_queue_Information, &the_message_queue->Object, (Objects_Name) name ); *id = the_message_queue->Object.id; a0011858: e5883000 str r3, [r8] name, 0 ); #endif _Thread_Enable_dispatch(); a001185c: eb000c68 bl a0014a04 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0011860: e3a00000 mov r0, #0 } a0011864: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc} =============================================================================== a0016804 : rtems_status_code rtems_message_queue_get_number_pending( rtems_id id, uint32_t *count ) { a0016804: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED register Message_queue_Control *the_message_queue; Objects_Locations location; if ( !count ) a0016808: e2514000 subs r4, r1, #0 <== NOT EXECUTED rtems_status_code rtems_message_queue_get_number_pending( rtems_id id, uint32_t *count ) { a001680c: e1a03000 mov r3, r0 <== NOT EXECUTED register Message_queue_Control *the_message_queue; Objects_Locations location; if ( !count ) return RTEMS_INVALID_ADDRESS; a0016810: 03a00009 moveq r0, #9 <== NOT EXECUTED ) { register Message_queue_Control *the_message_queue; Objects_Locations location; if ( !count ) a0016814: 0a00000b beq a0016848 <== NOT EXECUTED a0016818: e59f002c ldr r0, [pc, #44] ; a001684c <== NOT EXECUTED a001681c: e1a01003 mov r1, r3 <== NOT EXECUTED a0016820: e1a0200d mov r2, sp <== NOT EXECUTED a0016824: eb001483 bl a001ba38 <_Objects_Get> <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { a0016828: e59d5000 ldr r5, [sp] <== NOT EXECUTED a001682c: e3550000 cmp r5, #0 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0016830: 13a00004 movne r0, #4 <== NOT EXECUTED if ( !count ) return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { a0016834: 1a000003 bne a0016848 <== NOT EXECUTED case OBJECTS_LOCAL: *count = the_message_queue->message_queue.number_of_pending_messages; a0016838: e590305c ldr r3, [r0, #92] ; 0x5c <== NOT EXECUTED a001683c: e5843000 str r3, [r4] <== NOT EXECUTED _Thread_Enable_dispatch(); a0016840: eb00180f bl a001c884 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_SUCCESSFUL; a0016844: e1a00005 mov r0, r5 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0016848: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a00118a4 : void *buffer, size_t *size, rtems_option option_set, rtems_interval timeout ) { a00118a4: e92d4077 push {r0, r1, r2, r4, r5, r6, lr} register Message_queue_Control *the_message_queue; Objects_Locations location; bool wait; if ( !buffer ) a00118a8: e2515000 subs r5, r1, #0 void *buffer, size_t *size, rtems_option option_set, rtems_interval timeout ) { a00118ac: e1a0c000 mov ip, r0 a00118b0: e1a04002 mov r4, r2 a00118b4: e1a06003 mov r6, r3 register Message_queue_Control *the_message_queue; Objects_Locations location; bool wait; if ( !buffer ) a00118b8: 0a00001a beq a0011928 return RTEMS_INVALID_ADDRESS; if ( !size ) a00118bc: e3520000 cmp r2, #0 a00118c0: 0a000018 beq a0011928 RTEMS_INLINE_ROUTINE Message_queue_Control *_Message_queue_Get ( Objects_Id id, Objects_Locations *location ) { return (Message_queue_Control *) a00118c4: e28d2008 add r2, sp, #8 a00118c8: e59f0060 ldr r0, [pc, #96] ; a0011930 a00118cc: e1a0100c mov r1, ip a00118d0: eb0008b8 bl a0013bb8 <_Objects_Get> return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { a00118d4: e59d2008 ldr r2, [sp, #8] a00118d8: e1a03000 mov r3, r0 a00118dc: e3520000 cmp r2, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a00118e0: 13a00004 movne r0, #4 if ( !size ) return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { a00118e4: 1a000010 bne a001192c if ( _Options_Is_no_wait( option_set ) ) wait = false; else wait = true; _CORE_message_queue_Seize( a00118e8: 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; a00118ec: e2066001 and r6, r6, #1 a00118f0: e2266001 eor r6, r6, #1 a00118f4: e58d2004 str r2, [sp, #4] a00118f8: e58d6000 str r6, [sp] a00118fc: e2830014 add r0, r3, #20 a0011900: e5931008 ldr r1, [r3, #8] a0011904: e1a02005 mov r2, r5 a0011908: e1a03004 mov r3, r4 a001190c: eb0004a8 bl a0012bb4 <_CORE_message_queue_Seize> buffer, size, wait, timeout ); _Thread_Enable_dispatch(); a0011910: eb000c3b bl a0014a04 <_Thread_Enable_dispatch> return _Message_queue_Translate_core_message_queue_return_code( _Thread_Executing->Wait.return_code a0011914: e59f3018 ldr r3, [pc, #24] ; a0011934 a0011918: e5933008 ldr r3, [r3, #8] size, wait, timeout ); _Thread_Enable_dispatch(); return _Message_queue_Translate_core_message_queue_return_code( a001191c: e5930034 ldr r0, [r3, #52] ; 0x34 a0011920: eb000023 bl a00119b4 <_Message_queue_Translate_core_message_queue_return_code> a0011924: ea000000 b a001192c if ( !buffer ) return RTEMS_INVALID_ADDRESS; if ( !size ) return RTEMS_INVALID_ADDRESS; a0011928: e3a00009 mov r0, #9 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a001192c: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc} =============================================================================== a0009f18 : int rtems_object_api_maximum_class( int api ) { return _Objects_API_maximum_class(api); a0009f18: ea0005bc b a000b610 <_Objects_API_maximum_class> <== NOT EXECUTED =============================================================================== a0009f30 : ) { const rtems_assoc_t *api_assoc; const rtems_assoc_t *class_assoc; if ( the_api == OBJECTS_INTERNAL_API ) a0009f30: e3500001 cmp r0, #1 <== NOT EXECUTED const char *rtems_object_get_api_class_name( int the_api, int the_class ) { a0009f34: 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 ) a0009f38: 0a000005 beq a0009f54 <== NOT EXECUTED api_assoc = rtems_object_api_internal_assoc; else if ( the_api == OBJECTS_CLASSIC_API ) a0009f3c: e3500002 cmp r0, #2 <== NOT EXECUTED a0009f40: 0a000005 beq a0009f5c <== NOT EXECUTED api_assoc = rtems_object_api_classic_assoc; #ifdef RTEMS_POSIX_API else if ( the_api == OBJECTS_POSIX_API ) a0009f44: e3500003 cmp r0, #3 <== NOT EXECUTED api_assoc = rtems_object_api_posix_assoc; a0009f48: 059f0034 ldreq r0, [pc, #52] ; a0009f84 <== 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 ) a0009f4c: 1a000008 bne a0009f74 <== NOT EXECUTED a0009f50: ea000002 b a0009f60 <== 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; a0009f54: e59f002c ldr r0, [pc, #44] ; a0009f88 <== NOT EXECUTED a0009f58: ea000000 b a0009f60 <== NOT EXECUTED else if ( the_api == OBJECTS_CLASSIC_API ) api_assoc = rtems_object_api_classic_assoc; a0009f5c: e59f0028 ldr r0, [pc, #40] ; a0009f8c <== 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 ); a0009f60: eb001184 bl a000e578 <== NOT EXECUTED if ( class_assoc ) a0009f64: e3500000 cmp r0, #0 <== NOT EXECUTED return class_assoc->name; a0009f68: 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 ) a0009f6c: 149df004 popne {pc} ; (ldrne pc, [sp], #4) <== NOT EXECUTED a0009f70: ea000001 b a0009f7c <== 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"; a0009f74: e59f0014 ldr r0, [pc, #20] ; a0009f90 <== NOT EXECUTED a0009f78: 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"; a0009f7c: e59f0010 ldr r0, [pc, #16] ; a0009f94 <== NOT EXECUTED } a0009f80: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a0009f98 : }; const char *rtems_object_get_api_name( int api ) { a0009f98: e1a01000 mov r1, r0 <== NOT EXECUTED a0009f9c: 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 ); a0009fa0: e59f0010 ldr r0, [pc, #16] ; a0009fb8 <== NOT EXECUTED a0009fa4: eb001173 bl a000e578 <== NOT EXECUTED if ( api_assoc ) a0009fa8: e3500000 cmp r0, #0 <== NOT EXECUTED return api_assoc->name; a0009fac: 15900000 ldrne r0, [r0] <== NOT EXECUTED return "BAD CLASS"; a0009fb0: 059f0004 ldreq r0, [pc, #4] ; a0009fbc <== NOT EXECUTED } a0009fb4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000b9d0 : rtems_status_code rtems_object_get_class_information( int the_api, int the_class, rtems_object_api_class_information *info ) { a000b9d0: e92d4010 push {r4, lr} <== NOT EXECUTED int i; /* * Validate parameters and look up information structure. */ if ( !info ) a000b9d4: e2524000 subs r4, r2, #0 <== NOT EXECUTED a000b9d8: 0a000019 beq a000ba44 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; obj_info = _Objects_Get_information( the_api, the_class ); a000b9dc: e1a01801 lsl r1, r1, #16 <== NOT EXECUTED a000b9e0: e1a01821 lsr r1, r1, #16 <== NOT EXECUTED a000b9e4: eb0006e1 bl a000d570 <_Objects_Get_information> <== NOT EXECUTED if ( !obj_info ) a000b9e8: e3500000 cmp r0, #0 <== NOT EXECUTED a000b9ec: 0a000016 beq a000ba4c <== NOT EXECUTED return RTEMS_INVALID_NUMBER; /* * Return information about this object class to the user. */ info->minimum_id = obj_info->minimum_id; a000b9f0: 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; a000b9f4: e1d011b0 ldrh r1, [r0, #16] <== NOT EXECUTED for ( unallocated=0, i=1 ; i <= info->maximum ; i++ ) a000b9f8: 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; a000b9fc: e5843000 str r3, [r4] <== NOT EXECUTED info->maximum_id = obj_info->maximum_id; a000ba00: e590300c ldr r3, [r0, #12] <== NOT EXECUTED a000ba04: e5843004 str r3, [r4, #4] <== NOT EXECUTED info->auto_extend = obj_info->auto_extend; a000ba08: e5d03012 ldrb r3, [r0, #18] <== NOT EXECUTED info->maximum = obj_info->maximum; a000ba0c: 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; a000ba10: e5c4300c strb r3, [r4, #12] <== NOT EXECUTED info->maximum = obj_info->maximum; for ( unallocated=0, i=1 ; i <= info->maximum ; i++ ) a000ba14: e3a03001 mov r3, #1 <== NOT EXECUTED a000ba18: ea000004 b a000ba30 <== NOT EXECUTED if ( !obj_info->local_table[i] ) a000ba1c: e590c01c ldr ip, [r0, #28] <== NOT EXECUTED a000ba20: 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++ ) a000ba24: e2833001 add r3, r3, #1 <== NOT EXECUTED if ( !obj_info->local_table[i] ) a000ba28: e35c0000 cmp ip, #0 <== NOT EXECUTED unallocated++; a000ba2c: 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++ ) a000ba30: e1530001 cmp r3, r1 <== NOT EXECUTED a000ba34: 9afffff8 bls a000ba1c <== NOT EXECUTED if ( !obj_info->local_table[i] ) unallocated++; info->unallocated = unallocated; a000ba38: e5842010 str r2, [r4, #16] <== NOT EXECUTED return RTEMS_SUCCESSFUL; a000ba3c: e3a00000 mov r0, #0 <== NOT EXECUTED a000ba40: e8bd8010 pop {r4, pc} <== NOT EXECUTED /* * Validate parameters and look up information structure. */ if ( !info ) return RTEMS_INVALID_ADDRESS; a000ba44: e3a00009 mov r0, #9 <== NOT EXECUTED a000ba48: e8bd8010 pop {r4, pc} <== NOT EXECUTED obj_info = _Objects_Get_information( the_api, the_class ); if ( !obj_info ) return RTEMS_INVALID_NUMBER; a000ba4c: e3a0000a mov r0, #10 <== NOT EXECUTED unallocated++; info->unallocated = unallocated; return RTEMS_SUCCESSFUL; } a000ba50: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000ba58 : #undef rtems_object_id_api_maximum int rtems_object_id_api_maximum(void) { return OBJECTS_APIS_LAST; } a000ba58: e3a00003 mov r0, #3 <== NOT EXECUTED a000ba5c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000ba60 : #undef rtems_object_id_api_minimum int rtems_object_id_api_minimum(void) { return OBJECTS_INTERNAL_API; } a000ba60: e3a00001 mov r0, #1 <== NOT EXECUTED a000ba64: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000ba68 : */ RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API( Objects_Id id ) { return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS); a000ba68: e1a00c20 lsr r0, r0, #24 <== NOT EXECUTED int rtems_object_id_get_api( rtems_id id ) { return _Objects_Get_API( id ); } a000ba6c: e2000007 and r0, r0, #7 <== NOT EXECUTED a000ba70: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000ba74 : int rtems_object_id_get_class( rtems_id id ) { return _Objects_Get_class( id ); } a000ba74: e1a00da0 lsr r0, r0, #27 <== NOT EXECUTED a000ba78: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000ba7c : #undef rtems_object_id_get_index int rtems_object_id_get_index( rtems_id id ) { return _Objects_Get_index( id ); a000ba7c: e1a00800 lsl r0, r0, #16 <== NOT EXECUTED } a000ba80: e1a00820 lsr r0, r0, #16 <== NOT EXECUTED a000ba84: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a000ba88 : * 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; a000ba88: e1a00820 lsr r0, r0, #16 <== NOT EXECUTED int rtems_object_id_get_node( rtems_id id ) { return _Objects_Get_node( id ); } a000ba8c: e20000ff and r0, r0, #255 ; 0xff <== NOT EXECUTED a000ba90: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a0009fc4 : */ rtems_status_code rtems_object_set_name( rtems_id id, const char *name ) { a0009fc4: e92d4071 push {r0, r4, r5, r6, lr} Objects_Information *information; Objects_Locations location; Objects_Control *the_object; Objects_Id tmpId; if ( !name ) a0009fc8: e2515000 subs r5, r1, #0 return RTEMS_INVALID_ADDRESS; a0009fcc: 03a00009 moveq r0, #9 Objects_Information *information; Objects_Locations location; Objects_Control *the_object; Objects_Id tmpId; if ( !name ) a0009fd0: 0a000016 beq a000a030 return RTEMS_INVALID_ADDRESS; tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id; a0009fd4: e3500000 cmp r0, #0 a0009fd8: 059f3054 ldreq r3, [pc, #84] ; a000a034 a0009fdc: 11a04000 movne r4, r0 a0009fe0: 05933008 ldreq r3, [r3, #8] a0009fe4: 05934008 ldreq r4, [r3, #8] information = _Objects_Get_information_id( tmpId ); a0009fe8: e1a00004 mov r0, r4 a0009fec: eb000659 bl a000b958 <_Objects_Get_information_id> if ( !information ) a0009ff0: e2506000 subs r6, r0, #0 a0009ff4: 0a00000c beq a000a02c return RTEMS_INVALID_ID; the_object = _Objects_Get( information, tmpId, &location ); a0009ff8: e1a01004 mov r1, r4 a0009ffc: e1a0200d mov r2, sp a000a000: eb0006d0 bl a000bb48 <_Objects_Get> switch ( location ) { a000a004: e59d4000 ldr r4, [sp] information = _Objects_Get_information_id( tmpId ); if ( !information ) return RTEMS_INVALID_ID; the_object = _Objects_Get( information, tmpId, &location ); a000a008: e1a01000 mov r1, r0 switch ( location ) { a000a00c: e3540000 cmp r4, #0 a000a010: 1a000005 bne a000a02c case OBJECTS_LOCAL: _Objects_Set_name( information, the_object, name ); a000a014: e1a02005 mov r2, r5 a000a018: e1a00006 mov r0, r6 a000a01c: eb000722 bl a000bcac <_Objects_Set_name> _Thread_Enable_dispatch(); a000a020: eb000a66 bl a000c9c0 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000a024: e1a00004 mov r0, r4 a000a028: ea000000 b a000a030 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000a02c: e3a00004 mov r0, #4 <== NOT EXECUTED } a000a030: e8bd8078 pop {r3, r4, r5, r6, pc} =============================================================================== a000b4bc : uint32_t length, uint32_t buffer_size, rtems_attribute attribute_set, rtems_id *id ) { a000b4bc: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} register Partition_Control *the_partition; if ( !rtems_is_name_valid( name ) ) a000b4c0: e2508000 subs r8, r0, #0 uint32_t length, uint32_t buffer_size, rtems_attribute attribute_set, rtems_id *id ) { a000b4c4: e1a05001 mov r5, r1 a000b4c8: e1a09002 mov r9, r2 a000b4cc: e1a0a003 mov sl, r3 register Partition_Control *the_partition; if ( !rtems_is_name_valid( name ) ) a000b4d0: 0a000032 beq a000b5a0 return RTEMS_INVALID_NAME; if ( !starting_address ) a000b4d4: e3510000 cmp r1, #0 a000b4d8: 0a000032 beq a000b5a8 return RTEMS_INVALID_ADDRESS; if ( !id ) a000b4dc: e59d2028 ldr r2, [sp, #40] ; 0x28 a000b4e0: e3520000 cmp r2, #0 a000b4e4: 0a00002f beq a000b5a8 return RTEMS_INVALID_ADDRESS; if ( length == 0 || buffer_size == 0 || length < buffer_size || a000b4e8: e3590000 cmp r9, #0 a000b4ec: 13530000 cmpne r3, #0 a000b4f0: 0a00002e beq a000b5b0 a000b4f4: e1590003 cmp r9, r3 a000b4f8: 3a00002c bcc a000b5b0 a000b4fc: e3130003 tst r3, #3 a000b500: 1a00002a bne a000b5b0 !_Partition_Is_buffer_size_aligned( buffer_size ) ) return RTEMS_INVALID_SIZE; if ( !_Addresses_Is_aligned( starting_address ) ) a000b504: e2116007 ands r6, r1, #7 a000b508: 1a00002a bne a000b5b8 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000b50c: e59f30ac ldr r3, [pc, #172] ; a000b5c0 a000b510: e5932000 ldr r2, [r3] ++level; a000b514: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000b518: 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 ); a000b51c: e59f70a0 ldr r7, [pc, #160] ; a000b5c4 a000b520: e1a00007 mov r0, r7 a000b524: eb0006c5 bl a000d040 <_Objects_Allocate> _Thread_Disable_dispatch(); /* prevents deletion */ the_partition = _Partition_Allocate(); if ( !the_partition ) { a000b528: e2504000 subs r4, r0, #0 a000b52c: 1a000002 bne a000b53c _Thread_Enable_dispatch(); a000b530: eb000b91 bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_TOO_MANY; a000b534: e3a00005 mov r0, #5 <== NOT EXECUTED a000b538: 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; a000b53c: e59d3024 ldr r3, [sp, #36] ; 0x24 the_partition->number_of_used_blocks = 0; _Chain_Initialize( &the_partition->Memory, starting_address, a000b540: e1a0100a mov r1, sl _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } #endif the_partition->starting_address = starting_address; a000b544: e5845010 str r5, [r4, #16] the_partition->length = length; the_partition->buffer_size = buffer_size; the_partition->attribute_set = attribute_set; a000b548: e584301c str r3, [r4, #28] return RTEMS_TOO_MANY; } #endif the_partition->starting_address = starting_address; the_partition->length = length; a000b54c: e5849014 str r9, [r4, #20] the_partition->buffer_size = buffer_size; a000b550: e584a018 str sl, [r4, #24] the_partition->attribute_set = attribute_set; the_partition->number_of_used_blocks = 0; a000b554: e5846020 str r6, [r4, #32] _Chain_Initialize( &the_partition->Memory, starting_address, a000b558: e1a00009 mov r0, r9 a000b55c: eb00446f bl a001c720 <__aeabi_uidiv> a000b560: e284b024 add fp, r4, #36 ; 0x24 a000b564: e1a02000 mov r2, r0 a000b568: e1a01005 mov r1, r5 a000b56c: e1a0000b mov r0, fp a000b570: e1a0300a mov r3, sl a000b574: eb000441 bl a000c680 <_Chain_Initialize> #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000b578: e597201c ldr r2, [r7, #28] Objects_Information *information, Objects_Control *the_object, Objects_Name name ) { _Objects_Set_local_object( a000b57c: e1d410b8 ldrh r1, [r4, #8] a000b580: e5943008 ldr r3, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000b584: e7824101 str r4, [r2, r1, lsl #2] &_Partition_Information, &the_partition->Object, (Objects_Name) name ); *id = the_partition->Object.id; a000b588: e59d2028 ldr r2, [sp, #40] ; 0x28 information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name; a000b58c: e584800c str r8, [r4, #12] a000b590: e5823000 str r3, [r2] name, 0 /* Not used */ ); #endif _Thread_Enable_dispatch(); a000b594: eb000b78 bl a000e37c <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000b598: e1a00006 mov r0, r6 a000b59c: 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; a000b5a0: e3a00003 mov r0, #3 <== NOT EXECUTED a000b5a4: 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; a000b5a8: e3a00009 mov r0, #9 <== NOT EXECUTED a000b5ac: 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; a000b5b0: e3a00008 mov r0, #8 <== NOT EXECUTED a000b5b4: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED if ( !_Addresses_Is_aligned( starting_address ) ) return RTEMS_INVALID_ADDRESS; a000b5b8: e3a00009 mov r0, #9 <== NOT EXECUTED ); #endif _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } a000b5bc: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED =============================================================================== a0016b2c : #include rtems_status_code rtems_partition_delete( rtems_id id ) { a0016b2c: e92d4031 push {r0, r4, r5, lr} a0016b30: e1a01000 mov r1, r0 RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Get ( Objects_Id id, Objects_Locations *location ) { return (Partition_Control *) a0016b34: e1a0200d mov r2, sp a0016b38: e59f0050 ldr r0, [pc, #80] ; a0016b90 a0016b3c: eb0013bd bl a001ba38 <_Objects_Get> register Partition_Control *the_partition; Objects_Locations location; the_partition = _Partition_Get( id, &location ); switch ( location ) { a0016b40: e59d3000 ldr r3, [sp] a0016b44: e1a04000 mov r4, r0 a0016b48: e3530000 cmp r3, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0016b4c: 13a00004 movne r0, #4 { register Partition_Control *the_partition; Objects_Locations location; the_partition = _Partition_Get( id, &location ); switch ( location ) { a0016b50: 1a00000d bne a0016b8c case OBJECTS_LOCAL: if ( the_partition->number_of_used_blocks == 0 ) { a0016b54: e5945020 ldr r5, [r4, #32] a0016b58: e3550000 cmp r5, #0 a0016b5c: 1a000008 bne a0016b84 _Objects_Close( &_Partition_Information, &the_partition->Object ); a0016b60: e59f0028 ldr r0, [pc, #40] ; a0016b90 a0016b64: e1a01004 mov r1, r4 a0016b68: eb00129f bl a001b5ec <_Objects_Close> */ RTEMS_INLINE_ROUTINE void _Partition_Free ( Partition_Control *the_partition ) { _Objects_Free( &_Partition_Information, &the_partition->Object ); a0016b6c: e59f001c ldr r0, [pc, #28] ; a0016b90 a0016b70: e1a01004 mov r1, r4 a0016b74: eb001349 bl a001b8a0 <_Objects_Free> 0 /* Not used */ ); } #endif _Thread_Enable_dispatch(); a0016b78: eb001741 bl a001c884 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0016b7c: e1a00005 mov r0, r5 a0016b80: ea000001 b a0016b8c } _Thread_Enable_dispatch(); a0016b84: eb00173e bl a001c884 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_RESOURCE_IN_USE; a0016b88: e3a0000c mov r0, #12 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0016b8c: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a0016c3c : rtems_status_code rtems_partition_return_buffer( rtems_id id, void *buffer ) { a0016c3c: e92d4071 push {r0, r4, r5, r6, lr} a0016c40: e1a03000 mov r3, r0 a0016c44: e1a04001 mov r4, r1 RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Get ( Objects_Id id, Objects_Locations *location ) { return (Partition_Control *) a0016c48: e59f0088 ldr r0, [pc, #136] ; a0016cd8 a0016c4c: e1a01003 mov r1, r3 a0016c50: e1a0200d mov r2, sp a0016c54: eb001377 bl a001ba38 <_Objects_Get> register Partition_Control *the_partition; Objects_Locations location; the_partition = _Partition_Get( id, &location ); switch ( location ) { a0016c58: e59d3000 ldr r3, [sp] a0016c5c: e1a05000 mov r5, r0 a0016c60: e3530000 cmp r3, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0016c64: 13a00004 movne r0, #4 { register Partition_Control *the_partition; Objects_Locations location; the_partition = _Partition_Get( id, &location ); switch ( location ) { a0016c68: 1a000016 bne a0016cc8 ) { void *starting; void *ending; starting = the_partition->starting_address; a0016c6c: e5950010 ldr r0, [r5, #16] a0016c70: e5953014 ldr r3, [r5, #20] a0016c74: e0803003 add r3, r0, r3 const void *address, const void *base, const void *limit ) { return (address >= base && address <= limit); a0016c78: e1540003 cmp r4, r3 a0016c7c: 83a03000 movhi r3, #0 a0016c80: 93a03001 movls r3, #1 a0016c84: e1540000 cmp r4, r0 a0016c88: 33a03000 movcc r3, #0 ending = _Addresses_Add_offset( starting, the_partition->length ); return ( _Addresses_Is_in_range( the_buffer, starting, ending ) && a0016c8c: e3530000 cmp r3, #0 a0016c90: 0a00000d beq a0016ccc offset = (uint32_t) _Addresses_Subtract( the_buffer, the_partition->starting_address ); return ((offset % the_partition->buffer_size) == 0); a0016c94: e0600004 rsb r0, r0, r4 a0016c98: e5951018 ldr r1, [r5, #24] a0016c9c: eb0055a3 bl a002c330 <__umodsi3> starting = the_partition->starting_address; ending = _Addresses_Add_offset( starting, the_partition->length ); return ( _Addresses_Is_in_range( the_buffer, starting, ending ) && a0016ca0: e2506000 subs r6, r0, #0 a0016ca4: 1a000008 bne a0016ccc RTEMS_INLINE_ROUTINE void _Partition_Free_buffer ( Partition_Control *the_partition, Chain_Node *the_buffer ) { _Chain_Append( &the_partition->Memory, the_buffer ); a0016ca8: e2850024 add r0, r5, #36 ; 0x24 a0016cac: e1a01004 mov r1, r4 a0016cb0: eb000bff bl a0019cb4 <_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; a0016cb4: e5953020 ldr r3, [r5, #32] a0016cb8: e2433001 sub r3, r3, #1 a0016cbc: e5853020 str r3, [r5, #32] _Thread_Enable_dispatch(); a0016cc0: eb0016ef bl a001c884 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0016cc4: e1a00006 mov r0, r6 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0016cc8: 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(); a0016ccc: eb0016ec bl a001c884 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; a0016cd0: e3a00009 mov r0, #9 <== NOT EXECUTED a0016cd4: eafffffb b a0016cc8 <== NOT EXECUTED =============================================================================== a001608c : void *internal_start, void *external_start, uint32_t length, rtems_id *id ) { a001608c: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} register Dual_ported_memory_Control *the_port; if ( !rtems_is_name_valid( name ) ) a0016090: e250a000 subs sl, r0, #0 void *internal_start, void *external_start, uint32_t length, rtems_id *id ) { a0016094: e1a04001 mov r4, r1 a0016098: e1a05002 mov r5, r2 a001609c: e1a09003 mov r9, r3 a00160a0: e59d6020 ldr r6, [sp, #32] register Dual_ported_memory_Control *the_port; if ( !rtems_is_name_valid( name ) ) a00160a4: 0a00001d beq a0016120 return RTEMS_INVALID_NAME; if ( !id ) a00160a8: e3560000 cmp r6, #0 a00160ac: 0a00001d beq a0016128 #include #include #include #include rtems_status_code rtems_port_create( a00160b0: e1828001 orr r8, r2, r1 return RTEMS_INVALID_NAME; if ( !id ) return RTEMS_INVALID_ADDRESS; if ( !_Addresses_Is_aligned( internal_start ) || a00160b4: e2188007 ands r8, r8, #7 a00160b8: 1a00001c bne a0016130 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a00160bc: e59f3074 ldr r3, [pc, #116] ; a0016138 a00160c0: e5932000 ldr r2, [r3] ++level; a00160c4: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a00160c8: e5832000 str r2, [r3] * of free port control blocks. */ RTEMS_INLINE_ROUTINE Dual_ported_memory_Control *_Dual_ported_memory_Allocate ( void ) { return (Dual_ported_memory_Control *) a00160cc: e59f7068 ldr r7, [pc, #104] ; a001613c a00160d0: e1a00007 mov r0, r7 a00160d4: eb001522 bl a001b564 <_Objects_Allocate> _Thread_Disable_dispatch(); /* to prevent deletion */ the_port = _Dual_ported_memory_Allocate(); if ( !the_port ) { a00160d8: e3500000 cmp r0, #0 a00160dc: 1a000002 bne a00160ec _Thread_Enable_dispatch(); a00160e0: eb0019e7 bl a001c884 <_Thread_Enable_dispatch> return RTEMS_TOO_MANY; a00160e4: e3a00005 mov r0, #5 a00160e8: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} Objects_Information *information, Objects_Control *the_object, Objects_Name name ) { _Objects_Set_local_object( a00160ec: e5903008 ldr r3, [r0, #8] a00160f0: e1d010b8 ldrh r1, [r0, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a00160f4: e597201c ldr r2, [r7, #28] } the_port->internal_base = internal_start; the_port->external_base = external_start; the_port->length = length - 1; a00160f8: e2499001 sub r9, r9, #1 if ( !the_port ) { _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } the_port->internal_base = internal_start; a00160fc: e5804010 str r4, [r0, #16] the_port->external_base = external_start; a0016100: e5805014 str r5, [r0, #20] the_port->length = length - 1; a0016104: e5809018 str r9, [r0, #24] a0016108: e7820101 str r0, [r2, r1, lsl #2] information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name; a001610c: e580a00c str sl, [r0, #12] &_Dual_ported_memory_Information, &the_port->Object, (Objects_Name) name ); *id = the_port->Object.id; a0016110: e5863000 str r3, [r6] _Thread_Enable_dispatch(); a0016114: eb0019da bl a001c884 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0016118: e1a00008 mov r0, r8 a001611c: 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; a0016120: e3a00003 mov r0, #3 <== NOT EXECUTED a0016124: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED if ( !id ) return RTEMS_INVALID_ADDRESS; a0016128: e3a00009 mov r0, #9 <== NOT EXECUTED a001612c: 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; a0016130: e3a00009 mov r0, #9 <== NOT EXECUTED ); *id = the_port->Object.id; _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } a0016134: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED =============================================================================== a0016cdc : #include rtems_status_code rtems_rate_monotonic_cancel( rtems_id id ) { a0016cdc: e92d4031 push {r0, r4, r5, lr} a0016ce0: e1a01000 mov r1, r0 RTEMS_INLINE_ROUTINE Rate_monotonic_Control *_Rate_monotonic_Get ( Objects_Id id, Objects_Locations *location ) { return (Rate_monotonic_Control *) a0016ce4: e1a0200d mov r2, sp a0016ce8: e59f0060 ldr r0, [pc, #96] ; a0016d50 a0016cec: eb001351 bl a001ba38 <_Objects_Get> Rate_monotonic_Control *the_period; Objects_Locations location; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a0016cf0: e59d4000 ldr r4, [sp] a0016cf4: e1a05000 mov r5, r0 a0016cf8: e3540000 cmp r4, #0 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0016cfc: 13a00004 movne r0, #4 { Rate_monotonic_Control *the_period; Objects_Locations location; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a0016d00: 1a000011 bne a0016d4c case OBJECTS_LOCAL: if ( !_Thread_Is_executing( the_period->owner ) ) { a0016d04: e59f3048 ldr r3, [pc, #72] ; a0016d54 a0016d08: e5952040 ldr r2, [r5, #64] ; 0x40 a0016d0c: e5933008 ldr r3, [r3, #8] a0016d10: e1520003 cmp r2, r3 a0016d14: 0a000002 beq a0016d24 _Thread_Enable_dispatch(); a0016d18: eb0016d9 bl a001c884 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_NOT_OWNER_OF_RESOURCE; a0016d1c: e3a00017 mov r0, #23 <== NOT EXECUTED a0016d20: ea000009 b a0016d4c <== NOT EXECUTED } (void) _Watchdog_Remove( &the_period->Timer ); a0016d24: e2850010 add r0, r5, #16 a0016d28: eb001a7c bl a001d720 <_Watchdog_Remove> RTEMS_INLINE_ROUTINE void _Scheduler_Release_job( Thread_Control *the_thread, uint32_t length ) { _Scheduler.Operations.release_job(the_thread, length); a0016d2c: e59f3024 ldr r3, [pc, #36] ; a0016d58 a0016d30: e5950040 ldr r0, [r5, #64] ; 0x40 a0016d34: e1a01004 mov r1, r4 a0016d38: e5933034 ldr r3, [r3, #52] ; 0x34 the_period->state = RATE_MONOTONIC_INACTIVE; a0016d3c: e5854038 str r4, [r5, #56] ; 0x38 a0016d40: e12fff33 blx r3 _Scheduler_Release_job(the_period->owner, 0); _Thread_Enable_dispatch(); a0016d44: eb0016ce bl a001c884 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0016d48: e1a00004 mov r0, r4 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0016d4c: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000b5c8 : rtems_status_code rtems_rate_monotonic_create( rtems_name name, rtems_id *id ) { a000b5c8: e92d41f0 push {r4, r5, r6, r7, r8, lr} Rate_monotonic_Control *the_period; if ( !rtems_is_name_valid( name ) ) a000b5cc: e2508000 subs r8, r0, #0 rtems_status_code rtems_rate_monotonic_create( rtems_name name, rtems_id *id ) { a000b5d0: e1a06001 mov r6, r1 Rate_monotonic_Control *the_period; if ( !rtems_is_name_valid( name ) ) a000b5d4: 0a000029 beq a000b680 return RTEMS_INVALID_NAME; if ( !id ) a000b5d8: e3510000 cmp r1, #0 a000b5dc: 0a000029 beq a000b688 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000b5e0: e59f30a8 ldr r3, [pc, #168] ; a000b690 a000b5e4: e5932000 ldr r2, [r3] ++level; a000b5e8: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000b5ec: e5832000 str r2, [r3] * This function allocates a period control block from * the inactive chain of free period control blocks. */ RTEMS_INLINE_ROUTINE Rate_monotonic_Control *_Rate_monotonic_Allocate( void ) { return (Rate_monotonic_Control *) a000b5f0: e59f709c ldr r7, [pc, #156] ; a000b694 a000b5f4: e1a00007 mov r0, r7 a000b5f8: eb000690 bl a000d040 <_Objects_Allocate> _Thread_Disable_dispatch(); /* to prevent deletion */ the_period = _Rate_monotonic_Allocate(); if ( !the_period ) { a000b5fc: e2504000 subs r4, r0, #0 a000b600: 1a000002 bne a000b610 _Thread_Enable_dispatch(); a000b604: eb000b5c bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_TOO_MANY; a000b608: e3a00005 mov r0, #5 <== NOT EXECUTED a000b60c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED } the_period->owner = _Thread_Executing; a000b610: e59f3080 ldr r3, [pc, #128] ; a000b698 the_period->state = RATE_MONOTONIC_INACTIVE; a000b614: e3a05000 mov r5, #0 _Watchdog_Initialize( &the_period->Timer, NULL, 0, NULL ); _Rate_monotonic_Reset_statistics( the_period ); a000b618: e1a01005 mov r1, r5 if ( !the_period ) { _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } the_period->owner = _Thread_Executing; a000b61c: e5933008 ldr r3, [r3, #8] the_period->state = RATE_MONOTONIC_INACTIVE; _Watchdog_Initialize( &the_period->Timer, NULL, 0, NULL ); _Rate_monotonic_Reset_statistics( the_period ); a000b620: e3a02038 mov r2, #56 ; 0x38 _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } the_period->owner = _Thread_Executing; the_period->state = RATE_MONOTONIC_INACTIVE; a000b624: e5845038 str r5, [r4, #56] ; 0x38 if ( !the_period ) { _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } the_period->owner = _Thread_Executing; a000b628: e5843040 str r3, [r4, #64] ; 0x40 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a000b62c: e5845018 str r5, [r4, #24] the_watchdog->routine = routine; a000b630: e584502c str r5, [r4, #44] ; 0x2c the_watchdog->id = id; a000b634: e5845030 str r5, [r4, #48] ; 0x30 the_watchdog->user_data = user_data; a000b638: 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 ); a000b63c: e2840054 add r0, r4, #84 ; 0x54 a000b640: eb0022a0 bl a00140c8 Timestamp64_Control *_time, Timestamp64_Control _seconds, Timestamp64_Control _nanoseconds ) { *_time = _seconds * 1000000000L + _nanoseconds; a000b644: e59f2050 ldr r2, [pc, #80] ; a000b69c a000b648: e59f3050 ldr r3, [pc, #80] ; a000b6a0 Objects_Information *information, Objects_Control *the_object, Objects_Name name ) { _Objects_Set_local_object( a000b64c: e1d410b8 ldrh r1, [r4, #8] a000b650: e584205c str r2, [r4, #92] ; 0x5c a000b654: e5843060 str r3, [r4, #96] ; 0x60 a000b658: e5842074 str r2, [r4, #116] ; 0x74 a000b65c: e5843078 str r3, [r4, #120] ; 0x78 #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000b660: e597201c ldr r2, [r7, #28] Objects_Information *information, Objects_Control *the_object, Objects_Name name ) { _Objects_Set_local_object( a000b664: e5943008 ldr r3, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000b668: e7824101 str r4, [r2, r1, lsl #2] information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name; a000b66c: e584800c str r8, [r4, #12] &_Rate_monotonic_Information, &the_period->Object, (Objects_Name) name ); *id = the_period->Object.id; a000b670: e5863000 str r3, [r6] _Thread_Enable_dispatch(); a000b674: eb000b40 bl a000e37c <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000b678: e1a00005 mov r0, r5 a000b67c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} ) { Rate_monotonic_Control *the_period; if ( !rtems_is_name_valid( name ) ) return RTEMS_INVALID_NAME; a000b680: e3a00003 mov r0, #3 <== NOT EXECUTED a000b684: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED if ( !id ) return RTEMS_INVALID_ADDRESS; a000b688: e3a00009 mov r0, #9 <== NOT EXECUTED ); *id = the_period->Object.id; _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } a000b68c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED =============================================================================== a0032458 : rtems_status_code rtems_rate_monotonic_get_statistics( rtems_id id, rtems_rate_monotonic_period_statistics *statistics ) { a0032458: e92d41f1 push {r0, r4, r5, r6, r7, r8, lr} <== NOT EXECUTED Objects_Locations location; Rate_monotonic_Control *the_period; rtems_rate_monotonic_period_statistics *dst; Rate_monotonic_Statistics *src; if ( !statistics ) a003245c: e2514000 subs r4, r1, #0 <== NOT EXECUTED rtems_status_code rtems_rate_monotonic_get_statistics( rtems_id id, rtems_rate_monotonic_period_statistics *statistics ) { a0032460: 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; a0032464: 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 ) a0032468: 0a000062 beq a00325f8 <== NOT EXECUTED a003246c: e59f0188 ldr r0, [pc, #392] ; a00325fc <== NOT EXECUTED a0032470: e1a01003 mov r1, r3 <== NOT EXECUTED a0032474: e1a0200d mov r2, sp <== NOT EXECUTED a0032478: ebff675e bl a000c1f8 <_Objects_Get> <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a003247c: e59d8000 ldr r8, [sp] <== NOT EXECUTED a0032480: e1a05000 mov r5, r0 <== NOT EXECUTED a0032484: e3580000 cmp r8, #0 <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0032488: 13a00004 movne r0, #4 <== NOT EXECUTED if ( !statistics ) return RTEMS_INVALID_ADDRESS; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a003248c: 1a000059 bne a00325f8 <== NOT EXECUTED case OBJECTS_LOCAL: dst = statistics; src = &the_period->Statistics; dst->count = src->count; a0032490: e5953054 ldr r3, [r5, #84] ; 0x54 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0032494: e285705c add r7, r5, #92 ; 0x5c <== NOT EXECUTED a0032498: e89700c0 ldm r7, {r6, r7} <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a003249c: e59f215c ldr r2, [pc, #348] ; a0032600 <== NOT EXECUTED switch ( location ) { case OBJECTS_LOCAL: dst = statistics; src = &the_period->Statistics; dst->count = src->count; a00324a0: e5843000 str r3, [r4] <== NOT EXECUTED dst->missed_count = src->missed_count; a00324a4: e5953058 ldr r3, [r5, #88] ; 0x58 <== NOT EXECUTED a00324a8: e1a00006 mov r0, r6 <== NOT EXECUTED a00324ac: e1a01007 mov r1, r7 <== NOT EXECUTED a00324b0: e5843004 str r3, [r4, #4] <== NOT EXECUTED a00324b4: e3a03000 mov r3, #0 <== NOT EXECUTED a00324b8: eb0075e8 bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00324bc: e1a01007 mov r1, r7 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00324c0: e5840008 str r0, [r4, #8] <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00324c4: e59f2134 ldr r2, [pc, #308] ; a0032600 <== NOT EXECUTED a00324c8: e1a00006 mov r0, r6 <== NOT EXECUTED a00324cc: e3a03000 mov r3, #0 <== NOT EXECUTED a00324d0: eb00771d bl a005014c <__moddi3> <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a00324d4: e2857064 add r7, r5, #100 ; 0x64 <== NOT EXECUTED a00324d8: e89700c0 ldm r7, {r6, r7} <== NOT EXECUTED a00324dc: e584000c str r0, [r4, #12] <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00324e0: e1a01007 mov r1, r7 <== NOT EXECUTED a00324e4: e1a00006 mov r0, r6 <== NOT EXECUTED a00324e8: e59f2110 ldr r2, [pc, #272] ; a0032600 <== NOT EXECUTED a00324ec: e3a03000 mov r3, #0 <== NOT EXECUTED a00324f0: eb0075da bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00324f4: e1a01007 mov r1, r7 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00324f8: e5840010 str r0, [r4, #16] <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00324fc: e59f20fc ldr r2, [pc, #252] ; a0032600 <== NOT EXECUTED a0032500: e1a00006 mov r0, r6 <== NOT EXECUTED a0032504: e3a03000 mov r3, #0 <== NOT EXECUTED a0032508: eb00770f bl a005014c <__moddi3> <== NOT EXECUTED a003250c: e285706c add r7, r5, #108 ; 0x6c <== NOT EXECUTED a0032510: e89700c0 ldm r7, {r6, r7} <== NOT EXECUTED a0032514: e5840014 str r0, [r4, #20] <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0032518: e1a01007 mov r1, r7 <== NOT EXECUTED a003251c: e1a00006 mov r0, r6 <== NOT EXECUTED a0032520: e59f20d8 ldr r2, [pc, #216] ; a0032600 <== NOT EXECUTED a0032524: e3a03000 mov r3, #0 <== NOT EXECUTED a0032528: eb0075cc bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a003252c: e1a01007 mov r1, r7 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0032530: e5840018 str r0, [r4, #24] <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a0032534: e59f20c4 ldr r2, [pc, #196] ; a0032600 <== NOT EXECUTED a0032538: e1a00006 mov r0, r6 <== NOT EXECUTED a003253c: e3a03000 mov r3, #0 <== NOT EXECUTED a0032540: eb007701 bl a005014c <__moddi3> <== NOT EXECUTED a0032544: e2857074 add r7, r5, #116 ; 0x74 <== NOT EXECUTED a0032548: e89700c0 ldm r7, {r6, r7} <== NOT EXECUTED a003254c: e584001c str r0, [r4, #28] <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0032550: e1a01007 mov r1, r7 <== NOT EXECUTED a0032554: e1a00006 mov r0, r6 <== NOT EXECUTED a0032558: e59f20a0 ldr r2, [pc, #160] ; a0032600 <== NOT EXECUTED a003255c: e3a03000 mov r3, #0 <== NOT EXECUTED a0032560: eb0075be bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a0032564: e1a01007 mov r1, r7 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0032568: e5840020 str r0, [r4, #32] <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a003256c: e59f208c ldr r2, [pc, #140] ; a0032600 <== NOT EXECUTED a0032570: e1a00006 mov r0, r6 <== NOT EXECUTED a0032574: e3a03000 mov r3, #0 <== NOT EXECUTED a0032578: eb0076f3 bl a005014c <__moddi3> <== NOT EXECUTED a003257c: e285707c add r7, r5, #124 ; 0x7c <== NOT EXECUTED a0032580: e89700c0 ldm r7, {r6, r7} <== NOT EXECUTED a0032584: e5840024 str r0, [r4, #36] ; 0x24 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0032588: e1a01007 mov r1, r7 <== NOT EXECUTED a003258c: e1a00006 mov r0, r6 <== NOT EXECUTED a0032590: e59f2068 ldr r2, [pc, #104] ; a0032600 <== NOT EXECUTED a0032594: e3a03000 mov r3, #0 <== NOT EXECUTED a0032598: eb0075b0 bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a003259c: e1a01007 mov r1, r7 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00325a0: e5840028 str r0, [r4, #40] ; 0x28 <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00325a4: e59f2054 ldr r2, [pc, #84] ; a0032600 <== NOT EXECUTED a00325a8: e1a00006 mov r0, r6 <== NOT EXECUTED a00325ac: e3a03000 mov r3, #0 <== NOT EXECUTED a00325b0: eb0076e5 bl a005014c <__moddi3> <== NOT EXECUTED a00325b4: e2857084 add r7, r5, #132 ; 0x84 <== NOT EXECUTED a00325b8: e89700c0 ldm r7, {r6, r7} <== NOT EXECUTED a00325bc: e584002c str r0, [r4, #44] ; 0x2c <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00325c0: e59f2038 ldr r2, [pc, #56] ; a0032600 <== NOT EXECUTED a00325c4: e3a03000 mov r3, #0 <== NOT EXECUTED a00325c8: e1a00006 mov r0, r6 <== NOT EXECUTED a00325cc: e1a01007 mov r1, r7 <== NOT EXECUTED a00325d0: eb0075a2 bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00325d4: e59f2024 ldr r2, [pc, #36] ; a0032600 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00325d8: e5840030 str r0, [r4, #48] ; 0x30 <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00325dc: e3a03000 mov r3, #0 <== NOT EXECUTED a00325e0: e1a00006 mov r0, r6 <== NOT EXECUTED a00325e4: e1a01007 mov r1, r7 <== NOT EXECUTED a00325e8: eb0076d7 bl a005014c <__moddi3> <== NOT EXECUTED a00325ec: e5840034 str r0, [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(); a00325f0: ebff6a6f bl a000cfb4 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_SUCCESSFUL; a00325f4: e1a00008 mov r0, r8 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a00325f8: e8bd81f8 pop {r3, r4, r5, r6, r7, r8, pc} <== NOT EXECUTED =============================================================================== a0032604 : rtems_status_code rtems_rate_monotonic_get_status( rtems_id id, rtems_rate_monotonic_period_status *status ) { a0032604: e92d40d0 push {r4, r6, r7, lr} Objects_Locations location; Rate_monotonic_Period_time_t since_last_period; Rate_monotonic_Control *the_period; bool valid_status; if ( !status ) a0032608: e2514000 subs r4, r1, #0 rtems_status_code rtems_rate_monotonic_get_status( rtems_id id, rtems_rate_monotonic_period_status *status ) { a003260c: e1a03000 mov r3, r0 a0032610: 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; a0032614: 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 ) a0032618: 0a000038 beq a0032700 a003261c: e1a01003 mov r1, r3 a0032620: e28d2010 add r2, sp, #16 a0032624: e59f00dc ldr r0, [pc, #220] ; a0032708 a0032628: ebff66f2 bl a000c1f8 <_Objects_Get> return RTEMS_INVALID_ADDRESS; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a003262c: e59d2010 ldr r2, [sp, #16] a0032630: e1a03000 mov r3, r0 a0032634: e3520000 cmp r2, #0 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0032638: 13a00004 movne r0, #4 if ( !status ) return RTEMS_INVALID_ADDRESS; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a003263c: 1a00002f bne a0032700 case OBJECTS_LOCAL: status->owner = the_period->owner->Object.id; a0032640: e5932040 ldr r2, [r3, #64] ; 0x40 status->state = the_period->state; a0032644: 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; a0032648: 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 ) { a003264c: 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; a0032650: e5843004 str r3, [r4, #4] the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { case OBJECTS_LOCAL: status->owner = the_period->owner->Object.id; a0032654: e5842000 str r2, [r4] /* * 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 ); a0032658: 05843008 streq r3, [r4, #8] a003265c: 0584300c streq r3, [r4, #12] _Timespec_Set_to_zero( &status->executed_since_last_period ); a0032660: 05843010 streq r3, [r4, #16] a0032664: 05843014 streq r3, [r4, #20] a0032668: 0a000022 beq a00326f8 } else { /* * Grab the current status. */ valid_status = a003266c: e28d1008 add r1, sp, #8 <== NOT EXECUTED a0032670: e1a0200d mov r2, sp <== NOT EXECUTED a0032674: eb000025 bl a0032710 <_Rate_monotonic_Get_status> <== NOT EXECUTED _Rate_monotonic_Get_status( the_period, &since_last_period, &executed ); if (!valid_status) { a0032678: e3500000 cmp r0, #0 <== NOT EXECUTED a003267c: 1a000002 bne a003268c <== NOT EXECUTED _Thread_Enable_dispatch(); a0032680: ebff6a4b bl a000cfb4 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_NOT_DEFINED; a0032684: e3a0000b mov r0, #11 <== NOT EXECUTED a0032688: ea00001c b a0032700 <== NOT EXECUTED } #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ _Timestamp_To_timespec( a003268c: e28d7008 add r7, sp, #8 <== NOT EXECUTED a0032690: e89700c0 ldm r7, {r6, r7} <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a0032694: e59f2070 ldr r2, [pc, #112] ; a003270c <== NOT EXECUTED a0032698: e1a00006 mov r0, r6 <== NOT EXECUTED a003269c: e1a01007 mov r1, r7 <== NOT EXECUTED a00326a0: e3a03000 mov r3, #0 <== NOT EXECUTED a00326a4: eb00756d bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00326a8: e1a01007 mov r1, r7 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00326ac: e5840008 str r0, [r4, #8] <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00326b0: e59f2054 ldr r2, [pc, #84] ; a003270c <== NOT EXECUTED a00326b4: e1a00006 mov r0, r6 <== NOT EXECUTED a00326b8: e3a03000 mov r3, #0 <== NOT EXECUTED a00326bc: eb0076a2 bl a005014c <__moddi3> <== NOT EXECUTED &since_last_period, &status->since_last_period ); _Timestamp_To_timespec( a00326c0: e89d00c0 ldm sp, {r6, r7} <== NOT EXECUTED a00326c4: e584000c str r0, [r4, #12] <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00326c8: e59f203c ldr r2, [pc, #60] ; a003270c <== NOT EXECUTED a00326cc: e3a03000 mov r3, #0 <== NOT EXECUTED a00326d0: e1a00006 mov r0, r6 <== NOT EXECUTED a00326d4: e1a01007 mov r1, r7 <== NOT EXECUTED a00326d8: eb007560 bl a004fc60 <__divdi3> <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00326dc: e1a01007 mov r1, r7 <== NOT EXECUTED static inline void _Timestamp64_implementation_To_timespec( const Timestamp64_Control *_timestamp, struct timespec *_timespec ) { _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L); a00326e0: e5840010 str r0, [r4, #16] <== NOT EXECUTED _timespec->tv_nsec = (long) (*_timestamp % 1000000000L); a00326e4: e59f2020 ldr r2, [pc, #32] ; a003270c <== NOT EXECUTED a00326e8: e1a00006 mov r0, r6 <== NOT EXECUTED a00326ec: e3a03000 mov r3, #0 <== NOT EXECUTED a00326f0: eb007695 bl a005014c <__moddi3> <== NOT EXECUTED a00326f4: e5840014 str r0, [r4, #20] <== NOT EXECUTED status->since_last_period = since_last_period; status->executed_since_last_period = executed; #endif } _Thread_Enable_dispatch(); a00326f8: ebff6a2d bl a000cfb4 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a00326fc: e3a00000 mov r0, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0032700: e28dd014 add sp, sp, #20 a0032704: e8bd80d0 pop {r4, r6, r7, pc} =============================================================================== a0032910 : rtems_status_code rtems_rate_monotonic_period( rtems_id id, rtems_interval length ) { a0032910: e92d40f1 push {r0, r4, r5, r6, r7, lr} a0032914: e1a05000 mov r5, r0 a0032918: e1a04001 mov r4, r1 a003291c: e59f0184 ldr r0, [pc, #388] ; a0032aa8 a0032920: e1a01005 mov r1, r5 a0032924: e1a0200d mov r2, sp a0032928: ebff6632 bl a000c1f8 <_Objects_Get> rtems_rate_monotonic_period_states local_state; ISR_Level level; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a003292c: e59d3000 ldr r3, [sp] a0032930: e1a06000 mov r6, r0 a0032934: e3530000 cmp r3, #0 a0032938: 1a000057 bne a0032a9c case OBJECTS_LOCAL: if ( !_Thread_Is_executing( the_period->owner ) ) { a003293c: e59f3168 ldr r3, [pc, #360] ; a0032aac a0032940: e5902040 ldr r2, [r0, #64] ; 0x40 a0032944: e5933008 ldr r3, [r3, #8] a0032948: e1520003 cmp r2, r3 a003294c: 0a000002 beq a003295c _Thread_Enable_dispatch(); a0032950: ebff6997 bl a000cfb4 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_NOT_OWNER_OF_RESOURCE; a0032954: e3a04017 mov r4, #23 <== NOT EXECUTED a0032958: ea000050 b a0032aa0 <== NOT EXECUTED } if ( length == RTEMS_PERIOD_STATUS ) { a003295c: e3540000 cmp r4, #0 a0032960: 1a000005 bne a003297c switch ( the_period->state ) { a0032964: e5903038 ldr r3, [r0, #56] ; 0x38 a0032968: e3530004 cmp r3, #4 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a003296c: 959f213c ldrls r2, [pc, #316] ; a0032ab0 a0032970: 97d24003 ldrbls r4, [r2, r3] case RATE_MONOTONIC_ACTIVE: default: /* unreached -- only to remove warnings */ return_value = RTEMS_SUCCESSFUL; break; } _Thread_Enable_dispatch(); a0032974: ebff698e bl a000cfb4 <_Thread_Enable_dispatch> return( return_value ); a0032978: ea000048 b a0032aa0 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a003297c: e10f7000 mrs r7, CPSR a0032980: e3873080 orr r3, r7, #128 ; 0x80 a0032984: e129f003 msr CPSR_fc, r3 } _ISR_Disable( level ); if ( the_period->state == RATE_MONOTONIC_INACTIVE ) { a0032988: e5903038 ldr r3, [r0, #56] ; 0x38 a003298c: e3530000 cmp r3, #0 a0032990: 1a000011 bne a00329dc static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0032994: e129f007 msr CPSR_fc, r7 _ISR_Enable( level ); the_period->next_length = length; a0032998: e580403c str r4, [r0, #60] ; 0x3c /* * Baseline statistics information for the beginning of a period. */ _Rate_monotonic_Initiate_statistics( the_period ); a003299c: ebffffb9 bl a0032888 <_Rate_monotonic_Initiate_statistics> the_period->state = RATE_MONOTONIC_ACTIVE; a00329a0: e3a03002 mov r3, #2 a00329a4: e5863038 str r3, [r6, #56] ; 0x38 Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a00329a8: e59f3104 ldr r3, [pc, #260] ; a0032ab4 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a00329ac: e3a07000 mov r7, #0 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a00329b0: e586401c str r4, [r6, #28] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a00329b4: e586302c str r3, [r6, #44] ; 0x2c ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a00329b8: e59f00f8 ldr r0, [pc, #248] ; a0032ab8 a00329bc: e2861010 add r1, r6, #16 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a00329c0: e5867018 str r7, [r6, #24] the_watchdog->routine = routine; the_watchdog->id = id; a00329c4: e5865030 str r5, [r6, #48] ; 0x30 the_watchdog->user_data = user_data; a00329c8: e5867034 str r7, [r6, #52] ; 0x34 ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a00329cc: ebff6c5c bl a000db44 <_Watchdog_Insert> NULL ); _Watchdog_Insert_ticks( &the_period->Timer, length ); _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; a00329d0: e1a04007 mov r4, r7 id, NULL ); _Watchdog_Insert_ticks( &the_period->Timer, length ); _Thread_Enable_dispatch(); a00329d4: ebff6976 bl a000cfb4 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a00329d8: ea000030 b a0032aa0 } if ( the_period->state == RATE_MONOTONIC_ACTIVE ) { a00329dc: e3530002 cmp r3, #2 a00329e0: 1a00001a bne a0032a50 /* * Update statistics from the concluding period. */ _Rate_monotonic_Update_statistics( the_period ); a00329e4: ebffff70 bl a00327ac <_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; a00329e8: e3a03001 mov r3, #1 a00329ec: e5863038 str r3, [r6, #56] ; 0x38 the_period->next_length = length; a00329f0: e586403c str r4, [r6, #60] ; 0x3c a00329f4: e129f007 msr CPSR_fc, r7 _ISR_Enable( level ); _Thread_Executing->Wait.id = the_period->Object.id; a00329f8: e59f30ac ldr r3, [pc, #172] ; a0032aac _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); a00329fc: 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; a0032a00: e5930008 ldr r0, [r3, #8] a0032a04: e5963008 ldr r3, [r6, #8] a0032a08: e5803020 str r3, [r0, #32] _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); a0032a0c: ebff6b79 bl a000d7f8 <_Thread_Set_state> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0032a10: e10f2000 mrs r2, CPSR a0032a14: e3823080 orr r3, r2, #128 ; 0x80 a0032a18: 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; a0032a1c: e3a01002 mov r1, #2 /* * Did the watchdog timer expire while we were actually blocking * on it? */ _ISR_Disable( level ); local_state = the_period->state; a0032a20: e5963038 ldr r3, [r6, #56] ; 0x38 the_period->state = RATE_MONOTONIC_ACTIVE; a0032a24: e5861038 str r1, [r6, #56] ; 0x38 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0032a28: 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 ) a0032a2c: e3530003 cmp r3, #3 a0032a30: 1a000003 bne a0032a44 _Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); a0032a34: e59f3070 ldr r3, [pc, #112] ; a0032aac <== NOT EXECUTED a0032a38: e3a01901 mov r1, #16384 ; 0x4000 <== NOT EXECUTED a0032a3c: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED a0032a40: ebff687e bl a000cc40 <_Thread_Clear_state> <== NOT EXECUTED _Thread_Enable_dispatch(); a0032a44: ebff695a bl a000cfb4 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0032a48: e3a04000 mov r4, #0 <== NOT EXECUTED a0032a4c: ea000013 b a0032aa0 <== NOT EXECUTED } if ( the_period->state == RATE_MONOTONIC_EXPIRED ) { a0032a50: e3530004 cmp r3, #4 <== NOT EXECUTED a0032a54: 1a000010 bne a0032a9c <== NOT EXECUTED /* * Update statistics from the concluding period */ _Rate_monotonic_Update_statistics( the_period ); a0032a58: ebffff53 bl a00327ac <_Rate_monotonic_Update_statistics> <== NOT EXECUTED a0032a5c: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED _ISR_Enable( level ); the_period->state = RATE_MONOTONIC_ACTIVE; a0032a60: e3a03002 mov r3, #2 <== NOT EXECUTED a0032a64: e5863038 str r3, [r6, #56] ; 0x38 <== NOT EXECUTED the_period->next_length = length; a0032a68: e586403c str r4, [r6, #60] ; 0x3c <== NOT EXECUTED Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a0032a6c: e586401c str r4, [r6, #28] <== NOT EXECUTED _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a0032a70: e59f0040 ldr r0, [pc, #64] ; a0032ab8 <== NOT EXECUTED a0032a74: e2861010 add r1, r6, #16 <== NOT EXECUTED a0032a78: ebff6c31 bl a000db44 <_Watchdog_Insert> <== NOT EXECUTED a0032a7c: e59f3038 ldr r3, [pc, #56] ; a0032abc <== NOT EXECUTED a0032a80: e5960040 ldr r0, [r6, #64] ; 0x40 <== NOT EXECUTED a0032a84: e596103c ldr r1, [r6, #60] ; 0x3c <== NOT EXECUTED a0032a88: e5933034 ldr r3, [r3, #52] ; 0x34 <== NOT EXECUTED a0032a8c: e12fff33 blx r3 <== NOT EXECUTED _Watchdog_Insert_ticks( &the_period->Timer, length ); _Scheduler_Release_job(the_period->owner, the_period->next_length); _Thread_Enable_dispatch(); return RTEMS_TIMEOUT; a0032a90: e3a04006 mov r4, #6 <== NOT EXECUTED the_period->state = RATE_MONOTONIC_ACTIVE; the_period->next_length = length; _Watchdog_Insert_ticks( &the_period->Timer, length ); _Scheduler_Release_job(the_period->owner, the_period->next_length); _Thread_Enable_dispatch(); a0032a94: ebff6946 bl a000cfb4 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_TIMEOUT; a0032a98: ea000000 b a0032aa0 <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0032a9c: e3a04004 mov r4, #4 <== NOT EXECUTED } a0032aa0: e1a00004 mov r0, r4 a0032aa4: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} =============================================================================== a0026db8 : void rtems_rate_monotonic_report_statistics( void ) { rtems_rate_monotonic_report_statistics_with_plugin( NULL, printk_plugin ); a0026db8: e59f1004 ldr r1, [pc, #4] ; a0026dc4 <== NOT EXECUTED a0026dbc: e3a00000 mov r0, #0 <== NOT EXECUTED a0026dc0: eaffff88 b a0026be8 <== NOT EXECUTED =============================================================================== a0026be8 : void rtems_rate_monotonic_report_statistics_with_plugin( void *context, rtems_printk_plugin_t print ) { a0026be8: e92d45f0 push {r4, r5, r6, r7, r8, sl, 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 ) a0026bec: e2514000 subs r4, r1, #0 <== NOT EXECUTED void rtems_rate_monotonic_report_statistics_with_plugin( void *context, rtems_printk_plugin_t print ) { a0026bf0: e24dd070 sub sp, sp, #112 ; 0x70 <== NOT EXECUTED a0026bf4: 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 ) a0026bf8: 0a000062 beq a0026d88 <== NOT EXECUTED return; (*print)( context, "Period information by period\n" ); a0026bfc: e59f118c ldr r1, [pc, #396] ; a0026d90 <== NOT EXECUTED a0026c00: e12fff34 blx r4 <== NOT EXECUTED #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ (*print)( context, "--- CPU times are in seconds ---\n" ); a0026c04: e59f1188 ldr r1, [pc, #392] ; a0026d94 <== NOT EXECUTED a0026c08: e1a00005 mov r0, r5 <== NOT EXECUTED a0026c0c: 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 ; a0026c10: e59f7180 ldr r7, [pc, #384] ; a0026d98 <== NOT EXECUTED return; (*print)( context, "Period information by period\n" ); #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ (*print)( context, "--- CPU times are in seconds ---\n" ); (*print)( context, "--- Wall times are in seconds ---\n" ); a0026c14: e59f1180 ldr r1, [pc, #384] ; a0026d9c <== NOT EXECUTED a0026c18: e1a00005 mov r0, r5 <== NOT EXECUTED a0026c1c: e12fff34 blx r4 <== NOT EXECUTED Be sure to test the various cases. (*print)( context,"\ 1234567890123456789012345678901234567890123456789012345678901234567890123456789\ \n"); */ (*print)( context, " ID OWNER COUNT MISSED " a0026c20: e59f1178 ldr r1, [pc, #376] ; a0026da0 <== NOT EXECUTED a0026c24: e1a00005 mov r0, r5 <== NOT EXECUTED a0026c28: e12fff34 blx r4 <== NOT EXECUTED #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ " " #endif " WALL TIME\n" ); (*print)( context, " " a0026c2c: e1a00005 mov r0, r5 <== NOT EXECUTED a0026c30: e59f116c ldr r1, [pc, #364] ; a0026da4 <== NOT EXECUTED a0026c34: 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; a0026c38: e28d8028 add r8, sp, #40 ; 0x28 <== 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 ; a0026c3c: e5976008 ldr r6, [r7, #8] <== NOT EXECUTED a0026c40: ea00004d b a0026d7c <== NOT EXECUTED id <= _Rate_monotonic_Information.maximum_id ; id++ ) { status = rtems_rate_monotonic_get_statistics( id, &the_stats ); a0026c44: e1a00006 mov r0, r6 <== NOT EXECUTED a0026c48: e28d1010 add r1, sp, #16 <== NOT EXECUTED a0026c4c: eb002e01 bl a0032458 <== NOT EXECUTED if ( status != RTEMS_SUCCESSFUL ) a0026c50: e3500000 cmp r0, #0 <== NOT EXECUTED a0026c54: 1a000047 bne a0026d78 <== 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 ); a0026c58: e28d1048 add r1, sp, #72 ; 0x48 <== NOT EXECUTED a0026c5c: e1a00006 mov r0, r6 <== NOT EXECUTED a0026c60: eb002e67 bl a0032604 <== NOT EXECUTED #endif rtems_object_get_name( the_status.owner, sizeof(name), name ); a0026c64: e3a01005 mov r1, #5 <== NOT EXECUTED a0026c68: e28d2068 add r2, sp, #104 ; 0x68 <== NOT EXECUTED a0026c6c: e59d0048 ldr r0, [sp, #72] ; 0x48 <== NOT EXECUTED a0026c70: ebffac5b bl a0011de4 <== NOT EXECUTED /* * Print part of report line that is not dependent on granularity */ (*print)( context, a0026c74: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED a0026c78: e59f1128 ldr r1, [pc, #296] ; a0026da8 <== NOT EXECUTED a0026c7c: e1a00005 mov r0, r5 <== NOT EXECUTED a0026c80: e58d3000 str r3, [sp] <== NOT EXECUTED a0026c84: e59d3014 ldr r3, [sp, #20] <== NOT EXECUTED a0026c88: e1a02006 mov r2, r6 <== NOT EXECUTED a0026c8c: e58d3004 str r3, [sp, #4] <== NOT EXECUTED a0026c90: e28d3068 add r3, sp, #104 ; 0x68 <== NOT EXECUTED a0026c94: e12fff34 blx r4 <== NOT EXECUTED ); /* * If the count is zero, don't print statistics */ if (the_stats.count == 0) { a0026c98: e59d1010 ldr r1, [sp, #16] <== NOT EXECUTED a0026c9c: e3510000 cmp r1, #0 <== NOT EXECUTED a0026ca0: 1a000003 bne a0026cb4 <== NOT EXECUTED (*print)( context, "\n" ); a0026ca4: e1a00005 mov r0, r5 <== NOT EXECUTED a0026ca8: e59f10fc ldr r1, [pc, #252] ; a0026dac <== NOT EXECUTED a0026cac: e12fff34 blx r4 <== NOT EXECUTED continue; a0026cb0: ea000030 b a0026d78 <== 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 ); a0026cb4: e28d2060 add r2, sp, #96 ; 0x60 <== NOT EXECUTED a0026cb8: e1a00008 mov r0, r8 <== NOT EXECUTED a0026cbc: eb00027e bl a00276bc <_Timespec_Divide_by_integer> <== NOT EXECUTED (*print)( context, a0026cc0: e59d001c ldr r0, [sp, #28] <== NOT EXECUTED a0026cc4: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED a0026cc8: eb00a061 bl a004ee54 <__aeabi_idiv> <== NOT EXECUTED a0026ccc: e59d3020 ldr r3, [sp, #32] <== NOT EXECUTED a0026cd0: e1a0a000 mov sl, r0 <== NOT EXECUTED a0026cd4: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED a0026cd8: e59d0024 ldr r0, [sp, #36] ; 0x24 <== NOT EXECUTED a0026cdc: e58d3000 str r3, [sp] <== NOT EXECUTED a0026ce0: eb00a05b bl a004ee54 <__aeabi_idiv> <== NOT EXECUTED a0026ce4: e59d3060 ldr r3, [sp, #96] ; 0x60 <== NOT EXECUTED a0026ce8: e58d0004 str r0, [sp, #4] <== NOT EXECUTED a0026cec: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED a0026cf0: e59d0064 ldr r0, [sp, #100] ; 0x64 <== NOT EXECUTED a0026cf4: e58d3008 str r3, [sp, #8] <== NOT EXECUTED a0026cf8: eb00a055 bl a004ee54 <__aeabi_idiv> <== NOT EXECUTED a0026cfc: e1a0300a mov r3, sl <== NOT EXECUTED a0026d00: e58d000c str r0, [sp, #12] <== NOT EXECUTED a0026d04: e59f10a4 ldr r1, [pc, #164] ; a0026db0 <== NOT EXECUTED a0026d08: e59d2018 ldr r2, [sp, #24] <== NOT EXECUTED a0026d0c: e1a00005 mov r0, r5 <== NOT EXECUTED a0026d10: 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); a0026d14: e28d2060 add r2, sp, #96 ; 0x60 <== NOT EXECUTED a0026d18: e28d0040 add r0, sp, #64 ; 0x40 <== NOT EXECUTED a0026d1c: e59d1010 ldr r1, [sp, #16] <== NOT EXECUTED a0026d20: eb000265 bl a00276bc <_Timespec_Divide_by_integer> <== NOT EXECUTED (*print)( context, a0026d24: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED a0026d28: e59d0034 ldr r0, [sp, #52] ; 0x34 <== NOT EXECUTED a0026d2c: eb00a048 bl a004ee54 <__aeabi_idiv> <== NOT EXECUTED a0026d30: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED a0026d34: e1a0a000 mov sl, r0 <== NOT EXECUTED a0026d38: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED a0026d3c: e59d003c ldr r0, [sp, #60] ; 0x3c <== NOT EXECUTED a0026d40: e58d3000 str r3, [sp] <== NOT EXECUTED a0026d44: eb00a042 bl a004ee54 <__aeabi_idiv> <== NOT EXECUTED a0026d48: e59d3060 ldr r3, [sp, #96] ; 0x60 <== NOT EXECUTED a0026d4c: e58d0004 str r0, [sp, #4] <== NOT EXECUTED a0026d50: e3a01ffa mov r1, #1000 ; 0x3e8 <== NOT EXECUTED a0026d54: e59d0064 ldr r0, [sp, #100] ; 0x64 <== NOT EXECUTED a0026d58: e58d3008 str r3, [sp, #8] <== NOT EXECUTED a0026d5c: eb00a03c bl a004ee54 <__aeabi_idiv> <== NOT EXECUTED a0026d60: e59f104c ldr r1, [pc, #76] ; a0026db4 <== NOT EXECUTED a0026d64: e58d000c str r0, [sp, #12] <== NOT EXECUTED a0026d68: e59d2030 ldr r2, [sp, #48] ; 0x30 <== NOT EXECUTED a0026d6c: e1a00005 mov r0, r5 <== NOT EXECUTED a0026d70: e1a0300a mov r3, sl <== NOT EXECUTED a0026d74: 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++ ) { a0026d78: 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 ; a0026d7c: e597300c ldr r3, [r7, #12] <== NOT EXECUTED a0026d80: e1560003 cmp r6, r3 <== NOT EXECUTED a0026d84: 9affffae bls a0026c44 <== NOT EXECUTED the_stats.min_wall_time, the_stats.max_wall_time, ival_wall, fval_wall ); #endif } } } a0026d88: e28dd070 add sp, sp, #112 ; 0x70 <== NOT EXECUTED a0026d8c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED =============================================================================== a0026dc8 : * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0026dc8: e59f3038 ldr r3, [pc, #56] ; a0026e08 <== NOT EXECUTED /* * rtems_rate_monotonic_reset_all_statistics */ void rtems_rate_monotonic_reset_all_statistics( void ) { a0026dcc: e92d4030 push {r4, r5, lr} <== NOT EXECUTED a0026dd0: e5932000 ldr r2, [r3] <== NOT EXECUTED ++level; a0026dd4: e2822001 add r2, r2, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a0026dd8: 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 ; a0026ddc: e59f5028 ldr r5, [pc, #40] ; a0026e0c <== NOT EXECUTED a0026de0: e5954008 ldr r4, [r5, #8] <== NOT EXECUTED a0026de4: ea000002 b a0026df4 <== NOT EXECUTED id <= _Rate_monotonic_Information.maximum_id ; id++ ) { (void) rtems_rate_monotonic_reset_statistics( id ); a0026de8: e1a00004 mov r0, r4 <== NOT EXECUTED a0026dec: eb000007 bl a0026e10 <== 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++ ) { a0026df0: 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 ; a0026df4: e595300c ldr r3, [r5, #12] <== NOT EXECUTED a0026df8: e1540003 cmp r4, r3 <== NOT EXECUTED a0026dfc: 9afffff9 bls a0026de8 <== NOT EXECUTED /* * Done so exit thread dispatching disabled critical section. */ _Thread_Enable_dispatch(); } a0026e00: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED } /* * Done so exit thread dispatching disabled critical section. */ _Thread_Enable_dispatch(); a0026e04: eaff986a b a000cfb4 <_Thread_Enable_dispatch> <== NOT EXECUTED =============================================================================== a0026e10 : */ rtems_status_code rtems_rate_monotonic_reset_statistics( rtems_id id ) { a0026e10: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED a0026e14: e1a01000 mov r1, r0 <== NOT EXECUTED RTEMS_INLINE_ROUTINE Rate_monotonic_Control *_Rate_monotonic_Get ( Objects_Id id, Objects_Locations *location ) { return (Rate_monotonic_Control *) a0026e18: e1a0200d mov r2, sp <== NOT EXECUTED a0026e1c: e59f0048 ldr r0, [pc, #72] ; a0026e6c <== NOT EXECUTED a0026e20: ebff94f4 bl a000c1f8 <_Objects_Get> <== NOT EXECUTED Objects_Locations location; Rate_monotonic_Control *the_period; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a0026e24: e59d4000 ldr r4, [sp] <== NOT EXECUTED a0026e28: e1a05000 mov r5, r0 <== NOT EXECUTED a0026e2c: e3540000 cmp r4, #0 <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0026e30: 13a00004 movne r0, #4 <== NOT EXECUTED { Objects_Locations location; Rate_monotonic_Control *the_period; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { a0026e34: 1a00000b bne a0026e68 <== NOT EXECUTED case OBJECTS_LOCAL: _Rate_monotonic_Reset_statistics( the_period ); a0026e38: e1a01004 mov r1, r4 <== NOT EXECUTED a0026e3c: e3a02038 mov r2, #56 ; 0x38 <== NOT EXECUTED a0026e40: e2850054 add r0, r5, #84 ; 0x54 <== NOT EXECUTED a0026e44: eb00492b bl a00392f8 <== NOT EXECUTED a0026e48: e59f2020 ldr r2, [pc, #32] ; a0026e70 <== NOT EXECUTED a0026e4c: e59f3020 ldr r3, [pc, #32] ; a0026e74 <== NOT EXECUTED a0026e50: e585205c str r2, [r5, #92] ; 0x5c <== NOT EXECUTED a0026e54: e5853060 str r3, [r5, #96] ; 0x60 <== NOT EXECUTED a0026e58: e5852074 str r2, [r5, #116] ; 0x74 <== NOT EXECUTED a0026e5c: e5853078 str r3, [r5, #120] ; 0x78 <== NOT EXECUTED _Thread_Enable_dispatch(); a0026e60: ebff9853 bl a000cfb4 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_SUCCESSFUL; a0026e64: e1a00004 mov r0, r4 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0026e68: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a000b210 : return big_enough; } void *rtems_rbheap_allocate(rtems_rbheap_control *control, size_t size) { a000b210: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} void *ptr = NULL; rtems_chain_control *free_chain = &control->free_chunk_chain; rtems_rbtree_control *chunk_tree = &control->chunk_tree; uintptr_t alignment = control->alignment; a000b214: e5906030 ldr r6, [r0, #48] ; 0x30 return big_enough; } void *rtems_rbheap_allocate(rtems_rbheap_control *control, size_t size) { a000b218: e1a05001 mov r5, r1 a000b21c: e1a04000 mov r4, r0 #include static uintptr_t align_up(uintptr_t alignment, uintptr_t value) { uintptr_t excess = value % alignment; a000b220: e1a00001 mov r0, r1 a000b224: e1a01006 mov r1, r6 a000b228: eb004273 bl a001bbfc <__umodsi3> if (excess > 0) { a000b22c: e3500000 cmp r0, #0 value += alignment - excess; a000b230: 10856006 addne r6, r5, r6 a000b234: 10606006 rsbne r6, r0, r6 static uintptr_t align_up(uintptr_t alignment, uintptr_t value) { uintptr_t excess = value % alignment; if (excess > 0) { a000b238: 01a06005 moveq r6, r5 rtems_chain_control *free_chain = &control->free_chunk_chain; rtems_rbtree_control *chunk_tree = &control->chunk_tree; uintptr_t alignment = control->alignment; uintptr_t aligned_size = align_up(alignment, size); if (size > 0 && size <= aligned_size) { a000b23c: e1550006 cmp r5, r6 a000b240: 83a00000 movhi r0, #0 a000b244: 93a00001 movls r0, #1 a000b248: e3550000 cmp r5, #0 a000b24c: 03a00000 moveq r0, #0 a000b250: e3500000 cmp r0, #0 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a000b254: 11a02004 movne r2, r4 a000b258: 14923004 ldrne r3, [r2], #4 size_t size ) { rtems_chain_node *current = rtems_chain_first(free_chain); const rtems_chain_node *tail = rtems_chain_tail(free_chain); rtems_rbheap_chunk *big_enough = NULL; a000b25c: 13a07000 movne r7, #0 rtems_chain_control *free_chain = &control->free_chunk_chain; rtems_rbtree_control *chunk_tree = &control->chunk_tree; uintptr_t alignment = control->alignment; uintptr_t aligned_size = align_up(alignment, size); if (size > 0 && size <= aligned_size) { a000b260: 1a000005 bne a000b27c a000b264: ea000039 b a000b350 rtems_rbheap_chunk *big_enough = NULL; while (current != tail && big_enough == NULL) { rtems_rbheap_chunk *free_chunk = (rtems_rbheap_chunk *) current; if (free_chunk->size >= size) { a000b268: e593701c ldr r7, [r3, #28] a000b26c: e1570006 cmp r7, r6 a000b270: 21a07003 movcs r7, r3 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next( Chain_Node *the_node ) { return the_node->next; a000b274: e5933000 ldr r3, [r3] a000b278: 33a07000 movcc r7, #0 { rtems_chain_node *current = rtems_chain_first(free_chain); const rtems_chain_node *tail = rtems_chain_tail(free_chain); rtems_rbheap_chunk *big_enough = NULL; while (current != tail && big_enough == NULL) { a000b27c: e2778001 rsbs r8, r7, #1 a000b280: 33a08000 movcc r8, #0 a000b284: e1530002 cmp r3, r2 a000b288: 03a08000 moveq r8, #0 a000b28c: e3580000 cmp r8, #0 a000b290: 1afffff4 bne a000b268 uintptr_t aligned_size = align_up(alignment, size); if (size > 0 && size <= aligned_size) { rtems_rbheap_chunk *free_chunk = search_free_chunk(free_chain, aligned_size); if (free_chunk != NULL) { a000b294: e3570000 cmp r7, #0 a000b298: 0a000029 beq a000b344 uintptr_t free_size = free_chunk->size; a000b29c: e597901c ldr r9, [r7, #28] if (free_size > aligned_size) { a000b2a0: e1590006 cmp r9, r6 a000b2a4: 9a00001f bls a000b328 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000b2a8: e1a0a004 mov sl, r4 a000b2ac: e5ba500c ldr r5, [sl, #12]! RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); a000b2b0: e2843010 add r3, r4, #16 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) a000b2b4: e1550003 cmp r5, r3 Chain_Control *the_chain ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *old_first = head->next; Chain_Node *new_first = old_first->next; a000b2b8: 15953000 ldrne r3, [r5] head->next = new_first; a000b2bc: 1584300c strne r3, [r4, #12] new_first->previous = head; a000b2c0: 1583a004 strne sl, [r3, #4] */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) a000b2c4: 1a000009 bne a000b2f0 { rtems_chain_control *chain = &control->spare_descriptor_chain; rtems_chain_node *chunk = rtems_chain_get_unprotected(chain); if (chunk == NULL) { (*control->extend_descriptors)(control); a000b2c8: e5943034 ldr r3, [r4, #52] ; 0x34 <== NOT EXECUTED a000b2cc: e1a00004 mov r0, r4 <== NOT EXECUTED a000b2d0: e12fff33 blx r3 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000b2d4: e594300c ldr r3, [r4, #12] <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) a000b2d8: e1530005 cmp r3, r5 <== NOT EXECUTED a000b2dc: 0a00001a beq a000b34c <== NOT EXECUTED Chain_Control *the_chain ) { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *old_first = head->next; Chain_Node *new_first = old_first->next; a000b2e0: e5932000 ldr r2, [r3] <== NOT EXECUTED head->next = new_first; new_first->previous = head; a000b2e4: e1a05003 mov r5, r3 <== NOT EXECUTED { Chain_Node *head = _Chain_Head( the_chain ); Chain_Node *old_first = head->next; Chain_Node *new_first = old_first->next; head->next = new_first; a000b2e8: e584200c str r2, [r4, #12] <== NOT EXECUTED new_first->previous = head; a000b2ec: e582a004 str sl, [r2, #4] <== NOT EXECUTED if (new_chunk != NULL) { uintptr_t new_free_size = free_size - aligned_size; free_chunk->size = new_free_size; new_chunk->begin = free_chunk->begin + new_free_size; a000b2f0: e5973018 ldr r3, [r7, #24] if (free_size > aligned_size) { rtems_rbheap_chunk *new_chunk = get_chunk(control); if (new_chunk != NULL) { uintptr_t new_free_size = free_size - aligned_size; a000b2f4: e0669009 rsb r9, r6, r9 free_chunk->size = new_free_size; a000b2f8: e587901c str r9, [r7, #28] */ RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain( Chain_Node *node ) { node->next = node->previous = NULL; a000b2fc: e1a01005 mov r1, r5 new_chunk->begin = free_chunk->begin + new_free_size; a000b300: e0899003 add r9, r9, r3 a000b304: e3a03000 mov r3, #0 a000b308: e5859018 str r9, [r5, #24] new_chunk->size = aligned_size; a000b30c: e585601c str r6, [r5, #28] a000b310: e5853004 str r3, [r5, #4] a000b314: e4813008 str r3, [r1], #8 static void insert_into_tree( rtems_rbtree_control *tree, rtems_rbheap_chunk *chunk ) { _RBTree_Insert_unprotected(tree, &chunk->tree_node); a000b318: e2840018 add r0, r4, #24 a000b31c: eb000666 bl a000ccbc <_RBTree_Insert_unprotected> free_chunk->size = new_free_size; new_chunk->begin = free_chunk->begin + new_free_size; new_chunk->size = aligned_size; rtems_chain_set_off_chain(&new_chunk->chain_node); insert_into_tree(chunk_tree, new_chunk); ptr = (void *) new_chunk->begin; a000b320: e5950018 ldr r0, [r5, #24] a000b324: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; a000b328: e897000c ldm r7, {r2, r3} } } else { rtems_chain_extract_unprotected(&free_chunk->chain_node); rtems_chain_set_off_chain(&free_chunk->chain_node); ptr = (void *) free_chunk->begin; a000b32c: e5970018 ldr r0, [r7, #24] next->previous = previous; a000b330: e5823004 str r3, [r2, #4] previous->next = next; a000b334: e5832000 str r2, [r3] */ RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain( Chain_Node *node ) { node->next = node->previous = NULL; a000b338: e5878004 str r8, [r7, #4] a000b33c: e5878000 str r8, [r7] a000b340: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} return big_enough; } void *rtems_rbheap_allocate(rtems_rbheap_control *control, size_t size) { void *ptr = NULL; a000b344: e1a00007 mov r0, r7 a000b348: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} a000b34c: e1a00008 mov r0, r8 <== NOT EXECUTED } } } return ptr; } a000b350: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== a000b4dc : void rtems_rbheap_extend_descriptors_with_malloc(rtems_rbheap_control *control) { a000b4dc: e92d4010 push {r4, lr} <== NOT EXECUTED a000b4e0: e1a04000 mov r4, r0 <== NOT EXECUTED rtems_rbheap_chunk *chunk = malloc(sizeof(*chunk)); a000b4e4: e3a00020 mov r0, #32 <== NOT EXECUTED a000b4e8: ebffee83 bl a0006efc <== NOT EXECUTED if (chunk != NULL) { a000b4ec: e3500000 cmp r0, #0 <== NOT EXECUTED a000b4f0: 0a000005 beq a000b50c <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Chain_Prepend_unprotected( Chain_Control *the_chain, Chain_Node *the_node ) { _Chain_Insert_unprotected(_Chain_Head(the_chain), the_node); a000b4f4: e284300c add r3, r4, #12 <== NOT EXECUTED Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; a000b4f8: e5803004 str r3, [r0, #4] <== NOT EXECUTED before_node = after_node->next; a000b4fc: e594300c ldr r3, [r4, #12] <== NOT EXECUTED after_node->next = the_node; a000b500: e584000c str r0, [r4, #12] <== NOT EXECUTED the_node->next = before_node; before_node->previous = the_node; a000b504: e5830004 str r0, [r3, #4] <== NOT EXECUTED Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; after_node->next = the_node; the_node->next = before_node; a000b508: e5803000 str r3, [r0] <== NOT EXECUTED a000b50c: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a000b354 : _RBTree_Extract_unprotected(chunk_tree, &b->tree_node); } } rtems_status_code rtems_rbheap_free(rtems_rbheap_control *control, void *ptr) { a000b354: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} rtems_status_code sc = RTEMS_SUCCESSFUL; if (ptr != NULL) { a000b358: e2516000 subs r6, r1, #0 _RBTree_Extract_unprotected(chunk_tree, &b->tree_node); } } rtems_status_code rtems_rbheap_free(rtems_rbheap_control *control, void *ptr) { a000b35c: e24dd020 sub sp, sp, #32 a000b360: e1a05000 mov r5, r0 rtems_status_code sc = RTEMS_SUCCESSFUL; if (ptr != NULL) { a000b364: 0a000058 beq a000b4cc #define NULL_PAGE rtems_rbheap_chunk_of_node(NULL) static rtems_rbheap_chunk *find(rtems_rbtree_control *chunk_tree, uintptr_t key) { rtems_rbheap_chunk chunk = { .begin = key }; a000b368: e1a0000d mov r0, sp a000b36c: e3a01000 mov r1, #0 a000b370: e3a02020 mov r2, #32 RBTree_Control *the_rbtree, RBTree_Node *the_node ) { RBTree_Node* iter_node = the_rbtree->root; RBTree_Node* found = NULL; a000b374: e3a04000 mov r4, #0 a000b378: eb002058 bl a00134e0 return rtems_rbheap_chunk_of_node( a000b37c: e08d3004 add r3, sp, r4 #define NULL_PAGE rtems_rbheap_chunk_of_node(NULL) static rtems_rbheap_chunk *find(rtems_rbtree_control *chunk_tree, uintptr_t key) { rtems_rbheap_chunk chunk = { .begin = key }; a000b380: e58d6018 str r6, [sp, #24] return rtems_rbheap_chunk_of_node( a000b384: e2837008 add r7, r3, #8 RTEMS_INLINE_ROUTINE RBTree_Node *_RBTree_Find_unprotected( RBTree_Control *the_rbtree, RBTree_Node *the_node ) { RBTree_Node* iter_node = the_rbtree->root; a000b388: e595601c ldr r6, [r5, #28] a000b38c: ea00000d b a000b3c8 RBTree_Node* found = NULL; int compare_result; while (iter_node) { compare_result = the_rbtree->compare_function(the_node, iter_node); a000b390: e5953028 ldr r3, [r5, #40] ; 0x28 a000b394: e1a00007 mov r0, r7 a000b398: e1a01006 mov r1, r6 a000b39c: e12fff33 blx r3 if ( _RBTree_Is_equal( compare_result ) ) { a000b3a0: e3500000 cmp r0, #0 a000b3a4: 1a000003 bne a000b3b8 found = iter_node; if ( the_rbtree->is_unique ) a000b3a8: e5d5302c ldrb r3, [r5, #44] ; 0x2c a000b3ac: e3530000 cmp r3, #0 a000b3b0: 1a000007 bne a000b3d4 a000b3b4: e1a04006 mov r4, r6 <== NOT EXECUTED break; } RBTree_Direction dir = (RBTree_Direction) _RBTree_Is_greater( compare_result ); iter_node = iter_node->child[dir]; a000b3b8: e3500000 cmp r0, #0 a000b3bc: c3a00008 movgt r0, #8 a000b3c0: d3a00004 movle r0, #4 a000b3c4: e7906006 ldr r6, [r0, r6] ) { RBTree_Node* iter_node = the_rbtree->root; RBTree_Node* found = NULL; int compare_result; while (iter_node) { a000b3c8: e3560000 cmp r6, #0 a000b3cc: 1affffef bne a000b390 a000b3d0: e1a06004 mov r6, r4 a000b3d4: e2464008 sub r4, r6, #8 if (ptr != NULL) { rtems_chain_control *free_chain = &control->free_chunk_chain; rtems_rbtree_control *chunk_tree = &control->chunk_tree; rtems_rbheap_chunk *chunk = find(chunk_tree, (uintptr_t) ptr); if (chunk != NULL_PAGE) { a000b3d8: e3740008 cmn r4, #8 check_and_merge(free_chain, chunk_tree, chunk, pred); } else { sc = RTEMS_INCORRECT_STATE; } } else { sc = RTEMS_INVALID_ID; a000b3dc: 03a06004 moveq r6, #4 if (ptr != NULL) { rtems_chain_control *free_chain = &control->free_chunk_chain; rtems_rbtree_control *chunk_tree = &control->chunk_tree; rtems_rbheap_chunk *chunk = find(chunk_tree, (uintptr_t) ptr); if (chunk != NULL_PAGE) { a000b3e0: 0a000039 beq a000b4cc */ RTEMS_INLINE_ROUTINE bool _Chain_Is_node_off_chain( const Chain_Node *node ) { return (node->next == NULL) && (node->previous == NULL); a000b3e4: e5163008 ldr r3, [r6, #-8] a000b3e8: e3530000 cmp r3, #0 a000b3ec: 13a0a000 movne sl, #0 a000b3f0: 1a000002 bne a000b400 add_to_chain(free_chain, b); _RBTree_Extract_unprotected(chunk_tree, &b->tree_node); } } rtems_status_code rtems_rbheap_free(rtems_rbheap_control *control, void *ptr) a000b3f4: e594a004 ldr sl, [r4, #4] a000b3f8: e27aa001 rsbs sl, sl, #1 a000b3fc: 33a0a000 movcc sl, #0 rtems_chain_control *free_chain = &control->free_chunk_chain; rtems_rbtree_control *chunk_tree = &control->chunk_tree; rtems_rbheap_chunk *chunk = find(chunk_tree, (uintptr_t) ptr); if (chunk != NULL_PAGE) { if (!rtems_rbheap_is_chunk_free(chunk)) { a000b400: e23aa001 eors sl, sl, #1 check_and_merge(free_chain, chunk_tree, chunk, succ); add_to_chain(free_chain, chunk); check_and_merge(free_chain, chunk_tree, chunk, pred); } else { sc = RTEMS_INCORRECT_STATE; a000b404: 13a0600e movne r6, #14 rtems_chain_control *free_chain = &control->free_chunk_chain; rtems_rbtree_control *chunk_tree = &control->chunk_tree; rtems_rbheap_chunk *chunk = find(chunk_tree, (uintptr_t) ptr); if (chunk != NULL_PAGE) { if (!rtems_rbheap_is_chunk_free(chunk)) { a000b408: 1a00002f bne a000b4cc static rtems_rbheap_chunk *get_next( const rtems_rbheap_chunk *chunk, RBTree_Direction dir ) { return rtems_rbheap_chunk_of_node( a000b40c: e2849008 add r9, r4, #8 a000b410: e1a0100a mov r1, sl a000b414: e1a00009 mov r0, r9 a000b418: eb0006ab bl a000cecc <_RBTree_Next_unprotected> a000b41c: e3a01001 mov r1, #1 a000b420: e1a06000 mov r6, r0 a000b424: e2408008 sub r8, r0, #8 a000b428: e1a00009 mov r0, r9 a000b42c: eb0006a6 bl a000cecc <_RBTree_Next_unprotected> a000b430: e2403008 sub r3, r0, #8 rtems_rbtree_control *chunk_tree, rtems_rbheap_chunk *a, rtems_rbheap_chunk *b ) { if (b != NULL_PAGE && rtems_rbheap_is_chunk_free(b)) { a000b434: e3730008 cmn r3, #8 { rtems_status_code sc = RTEMS_SUCCESSFUL; if (ptr != NULL) { rtems_chain_control *free_chain = &control->free_chunk_chain; rtems_rbtree_control *chunk_tree = &control->chunk_tree; a000b438: e2857018 add r7, r5, #24 rtems_rbtree_control *chunk_tree, rtems_rbheap_chunk *a, rtems_rbheap_chunk *b ) { if (b != NULL_PAGE && rtems_rbheap_is_chunk_free(b)) { a000b43c: 0a00000b beq a000b470 a000b440: e5102008 ldr r2, [r0, #-8] a000b444: e3520000 cmp r2, #0 a000b448: 1a000002 bne a000b458 add_to_chain(free_chain, b); _RBTree_Extract_unprotected(chunk_tree, &b->tree_node); } } rtems_status_code rtems_rbheap_free(rtems_rbheap_control *control, void *ptr) a000b44c: e510a004 ldr sl, [r0, #-4] a000b450: e27aa001 rsbs sl, sl, #1 a000b454: 33a0a000 movcc sl, #0 rtems_rbtree_control *chunk_tree, rtems_rbheap_chunk *a, rtems_rbheap_chunk *b ) { if (b != NULL_PAGE && rtems_rbheap_is_chunk_free(b)) { a000b458: e35a0000 cmp sl, #0 a000b45c: 1a000003 bne a000b470 a000b460: e1a00005 mov r0, r5 a000b464: e1a01007 mov r1, r7 a000b468: e1a02004 mov r2, r4 a000b46c: ebffff06 bl a000b08c ) { Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; a000b470: e5953000 ldr r3, [r5] a000b474: e3780008 cmn r8, #8 Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; a000b478: e5845004 str r5, [r4, #4] before_node = after_node->next; after_node->next = the_node; a000b47c: e5854000 str r4, [r5] the_node->next = before_node; before_node->previous = the_node; a000b480: e5834004 str r4, [r3, #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; a000b484: e5843000 str r3, [r4] a000b488: 0a00000e beq a000b4c8 */ RTEMS_INLINE_ROUTINE bool _Chain_Is_node_off_chain( const Chain_Node *node ) { return (node->next == NULL) && (node->previous == NULL); a000b48c: e5163008 ldr r3, [r6, #-8] a000b490: e3530000 cmp r3, #0 a000b494: 13a06000 movne r6, #0 a000b498: 1a000002 bne a000b4a8 add_to_chain(free_chain, b); _RBTree_Extract_unprotected(chunk_tree, &b->tree_node); } } rtems_status_code rtems_rbheap_free(rtems_rbheap_control *control, void *ptr) a000b49c: e5166004 ldr r6, [r6, #-4] a000b4a0: e2766001 rsbs r6, r6, #1 a000b4a4: 33a06000 movcc r6, #0 rtems_rbtree_control *chunk_tree, rtems_rbheap_chunk *a, rtems_rbheap_chunk *b ) { if (b != NULL_PAGE && rtems_rbheap_is_chunk_free(b)) { a000b4a8: e21660ff ands r6, r6, #255 ; 0xff a000b4ac: 1a000005 bne a000b4c8 a000b4b0: e1a00005 mov r0, r5 a000b4b4: e1a01007 mov r1, r7 a000b4b8: e1a02004 mov r2, r4 a000b4bc: e1a03008 mov r3, r8 a000b4c0: ebfffef1 bl a000b08c a000b4c4: ea000000 b a000b4cc } } rtems_status_code rtems_rbheap_free(rtems_rbheap_control *control, void *ptr) { rtems_status_code sc = RTEMS_SUCCESSFUL; a000b4c8: e3a06000 mov r6, #0 sc = RTEMS_INVALID_ID; } } return sc; } a000b4cc: e1a00006 mov r0, r6 a000b4d0: e28dd020 add sp, sp, #32 a000b4d4: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== a000b6a4 : uintptr_t length, uintptr_t page_size, rtems_attribute attribute_set, rtems_id *id ) { a000b6a4: 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 ) ) a000b6a8: e2509000 subs r9, r0, #0 uintptr_t length, uintptr_t page_size, rtems_attribute attribute_set, rtems_id *id ) { a000b6ac: e1a06001 mov r6, r1 a000b6b0: e1a07002 mov r7, r2 a000b6b4: e1a08003 mov r8, r3 a000b6b8: e59da024 ldr sl, [sp, #36] ; 0x24 a000b6bc: 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; a000b6c0: 03a06003 moveq r6, #3 ) { rtems_status_code return_status; Region_Control *the_region; if ( !rtems_is_name_valid( name ) ) a000b6c4: 0a000031 beq a000b790 return RTEMS_INVALID_NAME; if ( !starting_address ) a000b6c8: e3560000 cmp r6, #0 a000b6cc: 0a00002e beq a000b78c return RTEMS_INVALID_ADDRESS; if ( !id ) a000b6d0: e35b0000 cmp fp, #0 a000b6d4: 0a00002c beq a000b78c return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); /* to prevent deletion */ a000b6d8: e59f30b8 ldr r3, [pc, #184] ; a000b798 * 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 ); a000b6dc: e59f50b8 ldr r5, [pc, #184] ; a000b79c a000b6e0: e5930000 ldr r0, [r3] a000b6e4: eb0003a7 bl a000c588 <_API_Mutex_Lock> a000b6e8: e1a00005 mov r0, r5 a000b6ec: eb000653 bl a000d040 <_Objects_Allocate> the_region = _Region_Allocate(); if ( !the_region ) a000b6f0: e2504000 subs r4, r0, #0 return_status = RTEMS_TOO_MANY; a000b6f4: 03a06005 moveq r6, #5 _RTEMS_Lock_allocator(); /* to prevent deletion */ the_region = _Region_Allocate(); if ( !the_region ) a000b6f8: 0a00001f beq a000b77c return_status = RTEMS_TOO_MANY; else { the_region->maximum_segment_size = _Heap_Initialize( a000b6fc: e2840068 add r0, r4, #104 ; 0x68 a000b700: e1a01006 mov r1, r6 a000b704: e1a02007 mov r2, r7 a000b708: e1a03008 mov r3, r8 a000b70c: eb00059a bl a000cd7c <_Heap_Initialize> &the_region->Memory, starting_address, length, page_size ); if ( !the_region->maximum_segment_size ) { a000b710: e3500000 cmp r0, #0 if ( !the_region ) return_status = RTEMS_TOO_MANY; else { the_region->maximum_segment_size = _Heap_Initialize( a000b714: e584005c str r0, [r4, #92] ; 0x5c &the_region->Memory, starting_address, length, page_size ); if ( !the_region->maximum_segment_size ) { a000b718: 1a000004 bne a000b730 */ RTEMS_INLINE_ROUTINE void _Region_Free ( Region_Control *the_region ) { _Objects_Free( &_Region_Information, &the_region->Object ); a000b71c: e1a00005 mov r0, r5 <== NOT EXECUTED a000b720: e1a01004 mov r1, r4 <== NOT EXECUTED a000b724: eb000714 bl a000d37c <_Objects_Free> <== NOT EXECUTED _Region_Free( the_region ); return_status = RTEMS_INVALID_SIZE; a000b728: e3a06008 mov r6, #8 <== NOT EXECUTED a000b72c: ea000012 b a000b77c <== NOT EXECUTED } else { the_region->starting_address = starting_address; a000b730: 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( a000b734: 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; a000b738: e3a06000 mov r6, #0 _Thread_queue_Initialize( a000b73c: 03a01000 moveq r1, #0 a000b740: 13a01001 movne r1, #1 a000b744: e3a02040 mov r2, #64 ; 0x40 a000b748: e3a03006 mov r3, #6 } else { the_region->starting_address = starting_address; the_region->length = length; a000b74c: e5847054 str r7, [r4, #84] ; 0x54 the_region->page_size = page_size; a000b750: e5848058 str r8, [r4, #88] ; 0x58 the_region->attribute_set = attribute_set; a000b754: e584a060 str sl, [r4, #96] ; 0x60 the_region->number_of_used_blocks = 0; a000b758: e5846064 str r6, [r4, #100] ; 0x64 _Thread_queue_Initialize( a000b75c: e2840010 add r0, r4, #16 a000b760: eb000cd2 bl a000eab0 <_Thread_queue_Initialize> #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000b764: e595201c ldr r2, [r5, #28] Objects_Information *information, Objects_Control *the_object, Objects_Name name ) { _Objects_Set_local_object( a000b768: e5943008 ldr r3, [r4, #8] a000b76c: e1d410b8 ldrh r1, [r4, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000b770: e7824101 str r4, [r2, r1, lsl #2] information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name; a000b774: e584900c str r9, [r4, #12] &_Region_Information, &the_region->Object, (Objects_Name) name ); *id = the_region->Object.id; a000b778: e58b3000 str r3, [fp] return_status = RTEMS_SUCCESSFUL; } } _RTEMS_Unlock_allocator(); a000b77c: e59f3014 ldr r3, [pc, #20] ; a000b798 a000b780: e5930000 ldr r0, [r3] a000b784: eb000398 bl a000c5ec <_API_Mutex_Unlock> return return_status; a000b788: ea000000 b a000b790 if ( !starting_address ) return RTEMS_INVALID_ADDRESS; if ( !id ) return RTEMS_INVALID_ADDRESS; a000b78c: e3a06009 mov r6, #9 <== NOT EXECUTED } } _RTEMS_Unlock_allocator(); return return_status; } a000b790: e1a00006 mov r0, r6 a000b794: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} =============================================================================== a0017764 : rtems_status_code rtems_region_extend( rtems_id id, void *starting_address, uintptr_t length ) { a0017764: e92d40f1 push {r0, r4, r5, r6, r7, lr} <== NOT EXECUTED uintptr_t amount_extended; Objects_Locations location; rtems_status_code return_status; Region_Control *the_region; if ( !starting_address ) a0017768: e2517000 subs r7, r1, #0 <== NOT EXECUTED rtems_status_code rtems_region_extend( rtems_id id, void *starting_address, uintptr_t length ) { a001776c: e1a04000 mov r4, r0 <== NOT EXECUTED a0017770: 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; a0017774: 03a05009 moveq r5, #9 <== NOT EXECUTED uintptr_t amount_extended; Objects_Locations location; rtems_status_code return_status; Region_Control *the_region; if ( !starting_address ) a0017778: 0a00001c beq a00177f0 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); /* to prevent deletion */ a001777c: e59f3074 ldr r3, [pc, #116] ; a00177f8 <== NOT EXECUTED a0017780: e5930000 ldr r0, [r3] <== NOT EXECUTED a0017784: eb000924 bl a0019c1c <_API_Mutex_Lock> <== NOT EXECUTED RTEMS_INLINE_ROUTINE Region_Control *_Region_Get ( Objects_Id id, Objects_Locations *location ) { return (Region_Control *) a0017788: e1a01004 mov r1, r4 <== NOT EXECUTED a001778c: e59f0068 ldr r0, [pc, #104] ; a00177fc <== NOT EXECUTED a0017790: e1a0200d mov r2, sp <== NOT EXECUTED a0017794: eb001099 bl a001ba00 <_Objects_Get_no_protection> <== NOT EXECUTED the_region = _Region_Get( id, &location ); switch ( location ) { a0017798: e59d5000 ldr r5, [sp] <== NOT EXECUTED a001779c: e1a04000 mov r4, r0 <== NOT EXECUTED a00177a0: e3550000 cmp r5, #0 <== NOT EXECUTED break; #endif case OBJECTS_ERROR: default: return_status = RTEMS_INVALID_ID; a00177a4: 13a05004 movne r5, #4 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); /* to prevent deletion */ the_region = _Region_Get( id, &location ); switch ( location ) { a00177a8: 1a00000d bne a00177e4 <== NOT EXECUTED case OBJECTS_LOCAL: amount_extended = _Heap_Extend( a00177ac: e1a03005 mov r3, r5 <== NOT EXECUTED a00177b0: e2800068 add r0, r0, #104 ; 0x68 <== NOT EXECUTED a00177b4: e1a01007 mov r1, r7 <== NOT EXECUTED a00177b8: e1a02006 mov r2, r6 <== NOT EXECUTED a00177bc: eb000c6e bl a001a97c <_Heap_Extend> <== NOT EXECUTED starting_address, length, 0 ); if ( amount_extended > 0 ) { a00177c0: 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; a00177c4: 03a05009 moveq r5, #9 <== NOT EXECUTED starting_address, length, 0 ); if ( amount_extended > 0 ) { a00177c8: 0a000005 beq a00177e4 <== NOT EXECUTED the_region->length += amount_extended; a00177cc: e5943054 ldr r3, [r4, #84] ; 0x54 <== NOT EXECUTED a00177d0: e0833000 add r3, r3, r0 <== NOT EXECUTED a00177d4: e5843054 str r3, [r4, #84] ; 0x54 <== NOT EXECUTED the_region->maximum_segment_size += amount_extended; a00177d8: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED a00177dc: e0830000 add r0, r3, r0 <== NOT EXECUTED a00177e0: e584005c str r0, [r4, #92] ; 0x5c <== NOT EXECUTED default: return_status = RTEMS_INVALID_ID; break; } _RTEMS_Unlock_allocator(); a00177e4: e59f300c ldr r3, [pc, #12] ; a00177f8 <== NOT EXECUTED a00177e8: e5930000 ldr r0, [r3] <== NOT EXECUTED a00177ec: eb000923 bl a0019c80 <_API_Mutex_Unlock> <== NOT EXECUTED return return_status; } a00177f0: e1a00005 mov r0, r5 <== NOT EXECUTED a00177f4: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} <== NOT EXECUTED =============================================================================== a0017800 : rtems_status_code rtems_region_get_free_information( rtems_id id, Heap_Information_block *the_info ) { a0017800: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED Objects_Locations location; rtems_status_code return_status; register Region_Control *the_region; if ( !the_info ) a0017804: e2514000 subs r4, r1, #0 <== NOT EXECUTED rtems_status_code rtems_region_get_free_information( rtems_id id, Heap_Information_block *the_info ) { a0017808: 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; a001780c: 03a05009 moveq r5, #9 <== NOT EXECUTED { Objects_Locations location; rtems_status_code return_status; register Region_Control *the_region; if ( !the_info ) a0017810: 0a000013 beq a0017864 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); a0017814: e59f3050 ldr r3, [pc, #80] ; a001786c <== NOT EXECUTED a0017818: e5930000 ldr r0, [r3] <== NOT EXECUTED a001781c: eb0008fe bl a0019c1c <_API_Mutex_Lock> <== NOT EXECUTED a0017820: e1a01005 mov r1, r5 <== NOT EXECUTED a0017824: e59f0044 ldr r0, [pc, #68] ; a0017870 <== NOT EXECUTED a0017828: e1a0200d mov r2, sp <== NOT EXECUTED a001782c: eb001073 bl a001ba00 <_Objects_Get_no_protection> <== NOT EXECUTED the_region = _Region_Get( id, &location ); switch ( location ) { a0017830: e59d5000 ldr r5, [sp] <== NOT EXECUTED a0017834: e3550000 cmp r5, #0 <== NOT EXECUTED break; #endif case OBJECTS_ERROR: default: return_status = RTEMS_INVALID_ID; a0017838: 13a05004 movne r5, #4 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); the_region = _Region_Get( id, &location ); switch ( location ) { a001783c: 1a000005 bne a0017858 <== NOT EXECUTED case OBJECTS_LOCAL: the_info->Used.number = 0; a0017840: e584500c str r5, [r4, #12] <== NOT EXECUTED the_info->Used.total = 0; a0017844: e5845014 str r5, [r4, #20] <== NOT EXECUTED the_info->Used.largest = 0; a0017848: e5845010 str r5, [r4, #16] <== NOT EXECUTED _Heap_Get_free_information( &the_region->Memory, &the_info->Free ); a001784c: e2800068 add r0, r0, #104 ; 0x68 <== NOT EXECUTED a0017850: e1a01004 mov r1, r4 <== NOT EXECUTED a0017854: eb000d72 bl a001ae24 <_Heap_Get_free_information> <== NOT EXECUTED default: return_status = RTEMS_INVALID_ID; break; } _RTEMS_Unlock_allocator(); a0017858: e59f300c ldr r3, [pc, #12] ; a001786c <== NOT EXECUTED a001785c: e5930000 ldr r0, [r3] <== NOT EXECUTED a0017860: eb000906 bl a0019c80 <_API_Mutex_Unlock> <== NOT EXECUTED return return_status; } a0017864: e1a00005 mov r0, r5 <== NOT EXECUTED a0017868: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a0017874 : rtems_status_code rtems_region_get_information( rtems_id id, Heap_Information_block *the_info ) { a0017874: e92d4071 push {r0, r4, r5, r6, lr} <== NOT EXECUTED Objects_Locations location; rtems_status_code return_status; register Region_Control *the_region; if ( !the_info ) a0017878: e2515000 subs r5, r1, #0 <== NOT EXECUTED rtems_status_code rtems_region_get_information( rtems_id id, Heap_Information_block *the_info ) { a001787c: e1a06000 mov r6, r0 <== NOT EXECUTED Objects_Locations location; rtems_status_code return_status; register Region_Control *the_region; if ( !the_info ) return RTEMS_INVALID_ADDRESS; a0017880: 03a06009 moveq r6, #9 <== NOT EXECUTED { Objects_Locations location; rtems_status_code return_status; register Region_Control *the_region; if ( !the_info ) a0017884: 0a00000f beq a00178c8 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); a0017888: e59f4040 ldr r4, [pc, #64] ; a00178d0 <== NOT EXECUTED a001788c: e5940000 ldr r0, [r4] <== NOT EXECUTED a0017890: eb0008e1 bl a0019c1c <_API_Mutex_Lock> <== NOT EXECUTED a0017894: e1a01006 mov r1, r6 <== NOT EXECUTED a0017898: e59f0034 ldr r0, [pc, #52] ; a00178d4 <== NOT EXECUTED a001789c: e1a0200d mov r2, sp <== NOT EXECUTED a00178a0: eb001056 bl a001ba00 <_Objects_Get_no_protection> <== NOT EXECUTED the_region = _Region_Get( id, &location ); switch ( location ) { a00178a4: e59d6000 ldr r6, [sp] <== NOT EXECUTED a00178a8: e3560000 cmp r6, #0 <== NOT EXECUTED break; #endif case OBJECTS_ERROR: default: return_status = RTEMS_INVALID_ID; a00178ac: 13a06004 movne r6, #4 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); the_region = _Region_Get( id, &location ); switch ( location ) { a00178b0: 1a000002 bne a00178c0 <== NOT EXECUTED case OBJECTS_LOCAL: _Heap_Get_information( &the_region->Memory, the_info ); a00178b4: e2800068 add r0, r0, #104 ; 0x68 <== NOT EXECUTED a00178b8: e1a01005 mov r1, r5 <== NOT EXECUTED a00178bc: eb000d7a bl a001aeac <_Heap_Get_information> <== NOT EXECUTED default: return_status = RTEMS_INVALID_ID; break; } _RTEMS_Unlock_allocator(); a00178c0: e5940000 ldr r0, [r4] <== NOT EXECUTED a00178c4: eb0008ed bl a0019c80 <_API_Mutex_Unlock> <== NOT EXECUTED return return_status; } a00178c8: e1a00006 mov r0, r6 <== NOT EXECUTED a00178cc: e8bd8078 pop {r3, r4, r5, r6, pc} <== NOT EXECUTED =============================================================================== a0017a04 : rtems_status_code rtems_region_get_segment_size( rtems_id id, void *segment, uintptr_t *size ) { a0017a04: e92d4071 push {r0, r4, r5, r6, lr} Objects_Locations location; rtems_status_code return_status = RTEMS_SUCCESSFUL; register Region_Control *the_region; if ( !segment ) a0017a08: e2515000 subs r5, r1, #0 rtems_status_code rtems_region_get_segment_size( rtems_id id, void *segment, uintptr_t *size ) { a0017a0c: e1a06000 mov r6, r0 a0017a10: e1a04002 mov r4, r2 Objects_Locations location; rtems_status_code return_status = RTEMS_SUCCESSFUL; register Region_Control *the_region; if ( !segment ) a0017a14: 0a000019 beq a0017a80 return RTEMS_INVALID_ADDRESS; if ( !size ) a0017a18: e3520000 cmp r2, #0 a0017a1c: 0a000017 beq a0017a80 return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); a0017a20: e59f3064 ldr r3, [pc, #100] ; a0017a8c a0017a24: e5930000 ldr r0, [r3] a0017a28: eb00087b bl a0019c1c <_API_Mutex_Lock> a0017a2c: e59f005c ldr r0, [pc, #92] ; a0017a90 a0017a30: e1a01006 mov r1, r6 a0017a34: e1a0200d mov r2, sp a0017a38: eb000ff0 bl a001ba00 <_Objects_Get_no_protection> the_region = _Region_Get( id, &location ); switch ( location ) { a0017a3c: e59d3000 ldr r3, [sp] a0017a40: e3530000 cmp r3, #0 a0017a44: 0a000002 beq a0017a54 void *segment, uintptr_t *size ) { Objects_Locations location; rtems_status_code return_status = RTEMS_SUCCESSFUL; a0017a48: e3530001 cmp r3, #1 <== NOT EXECUTED a0017a4c: 03a04004 moveq r4, #4 <== NOT EXECUTED a0017a50: ea000005 b a0017a6c <== NOT EXECUTED the_region = _Region_Get( id, &location ); switch ( location ) { case OBJECTS_LOCAL: if ( !_Heap_Size_of_alloc_area( &the_region->Memory, segment, size ) ) a0017a54: e1a02004 mov r2, r4 a0017a58: e2800068 add r0, r0, #104 ; 0x68 a0017a5c: e1a01005 mov r1, r5 a0017a60: eb000e7b bl a001b454 <_Heap_Size_of_alloc_area> void *segment, uintptr_t *size ) { Objects_Locations location; rtems_status_code return_status = RTEMS_SUCCESSFUL; a0017a64: e3500000 cmp r0, #0 a0017a68: 03a04009 moveq r4, #9 case OBJECTS_ERROR: return_status = RTEMS_INVALID_ID; break; } _RTEMS_Unlock_allocator(); a0017a6c: e59f3018 ldr r3, [pc, #24] ; a0017a8c void *segment, uintptr_t *size ) { Objects_Locations location; rtems_status_code return_status = RTEMS_SUCCESSFUL; a0017a70: 13a04000 movne r4, #0 case OBJECTS_ERROR: return_status = RTEMS_INVALID_ID; break; } _RTEMS_Unlock_allocator(); a0017a74: e5930000 ldr r0, [r3] a0017a78: eb000880 bl a0019c80 <_API_Mutex_Unlock> return return_status; a0017a7c: ea000000 b a0017a84 if ( !segment ) return RTEMS_INVALID_ADDRESS; if ( !size ) return RTEMS_INVALID_ADDRESS; a0017a80: e3a04009 mov r4, #9 <== NOT EXECUTED break; } _RTEMS_Unlock_allocator(); return return_status; } a0017a84: e1a00004 mov r0, r4 a0017a88: e8bd8078 pop {r3, r4, r5, r6, pc} =============================================================================== a0017ac4 : rtems_id id, void *segment, uintptr_t size, uintptr_t *old_size ) { a0017ac4: 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 ) a0017ac8: e2538000 subs r8, r3, #0 <== NOT EXECUTED rtems_id id, void *segment, uintptr_t size, uintptr_t *old_size ) { a0017acc: e1a05000 mov r5, r0 <== NOT EXECUTED a0017ad0: e1a07001 mov r7, r1 <== NOT EXECUTED a0017ad4: 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; a0017ad8: 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 ) a0017adc: 0a000022 beq a0017b6c <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); a0017ae0: e59f408c ldr r4, [pc, #140] ; a0017b74 <== NOT EXECUTED a0017ae4: e5940000 ldr r0, [r4] <== NOT EXECUTED a0017ae8: eb00084b bl a0019c1c <_API_Mutex_Lock> <== NOT EXECUTED a0017aec: e1a01005 mov r1, r5 <== NOT EXECUTED a0017af0: e59f0080 ldr r0, [pc, #128] ; a0017b78 <== NOT EXECUTED a0017af4: e28d2008 add r2, sp, #8 <== NOT EXECUTED a0017af8: eb000fc0 bl a001ba00 <_Objects_Get_no_protection> <== NOT EXECUTED the_region = _Region_Get( id, &location ); switch ( location ) { a0017afc: e59d3008 ldr r3, [sp, #8] <== NOT EXECUTED a0017b00: e1a05000 mov r5, r0 <== NOT EXECUTED a0017b04: e3530000 cmp r3, #0 <== NOT EXECUTED a0017b08: 1a000014 bne a0017b60 <== NOT EXECUTED case OBJECTS_LOCAL: _Region_Debug_Walk( the_region, 7 ); status = _Heap_Resize_block( a0017b0c: e28d3004 add r3, sp, #4 <== NOT EXECUTED a0017b10: e58d3000 str r3, [sp] <== NOT EXECUTED a0017b14: e1a02006 mov r2, r6 <== NOT EXECUTED a0017b18: e28d300c add r3, sp, #12 <== NOT EXECUTED a0017b1c: e2800068 add r0, r0, #104 ; 0x68 <== NOT EXECUTED a0017b20: e1a01007 mov r1, r7 <== NOT EXECUTED a0017b24: eb000dfb bl a001b318 <_Heap_Resize_block> <== NOT EXECUTED segment, (uint32_t) size, &osize, &avail_size ); *old_size = (uint32_t) osize; a0017b28: e59d300c ldr r3, [sp, #12] <== NOT EXECUTED _Region_Debug_Walk( the_region, 8 ); if ( status == HEAP_RESIZE_SUCCESSFUL ) a0017b2c: e2506000 subs r6, r0, #0 <== NOT EXECUTED segment, (uint32_t) size, &osize, &avail_size ); *old_size = (uint32_t) osize; a0017b30: e5883000 str r3, [r8] <== NOT EXECUTED _Region_Debug_Walk( the_region, 8 ); if ( status == HEAP_RESIZE_SUCCESSFUL ) a0017b34: 1a000003 bne a0017b48 <== NOT EXECUTED _Region_Process_queue( the_region ); /* unlocks allocator */ a0017b38: e1a00005 mov r0, r5 <== NOT EXECUTED a0017b3c: eb001ee1 bl a001f6c8 <_Region_Process_queue> <== NOT EXECUTED else _RTEMS_Unlock_allocator(); if (status == HEAP_RESIZE_SUCCESSFUL) return RTEMS_SUCCESSFUL; a0017b40: e1a00006 mov r0, r6 <== NOT EXECUTED a0017b44: ea000008 b a0017b6c <== NOT EXECUTED _Region_Debug_Walk( the_region, 8 ); if ( status == HEAP_RESIZE_SUCCESSFUL ) _Region_Process_queue( the_region ); /* unlocks allocator */ else _RTEMS_Unlock_allocator(); a0017b48: e5940000 ldr r0, [r4] <== NOT EXECUTED a0017b4c: eb00084b bl a0019c80 <_API_Mutex_Unlock> <== NOT EXECUTED if (status == HEAP_RESIZE_SUCCESSFUL) return RTEMS_SUCCESSFUL; if (status == HEAP_RESIZE_UNSATISFIED) return RTEMS_UNSATISFIED; a0017b50: e3560001 cmp r6, #1 <== NOT EXECUTED a0017b54: 13a00009 movne r0, #9 <== NOT EXECUTED a0017b58: 03a0000d moveq r0, #13 <== NOT EXECUTED a0017b5c: ea000002 b a0017b6c <== NOT EXECUTED default: return_status = RTEMS_INVALID_ID; break; } _RTEMS_Unlock_allocator(); a0017b60: e5940000 ldr r0, [r4] <== NOT EXECUTED a0017b64: eb000845 bl a0019c80 <_API_Mutex_Unlock> <== NOT EXECUTED return return_status; a0017b68: e3a00004 mov r0, #4 <== NOT EXECUTED } a0017b6c: e28dd010 add sp, sp, #16 <== NOT EXECUTED a0017b70: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED =============================================================================== a0017b7c : rtems_status_code rtems_region_return_segment( rtems_id id, void *segment ) { a0017b7c: e92d4071 push {r0, r4, r5, r6, lr} uint32_t size; #endif int status; register Region_Control *the_region; _RTEMS_Lock_allocator(); a0017b80: e59f3074 ldr r3, [pc, #116] ; a0017bfc rtems_status_code rtems_region_return_segment( rtems_id id, void *segment ) { a0017b84: e1a05000 mov r5, r0 a0017b88: e1a04001 mov r4, r1 uint32_t size; #endif int status; register Region_Control *the_region; _RTEMS_Lock_allocator(); a0017b8c: e5930000 ldr r0, [r3] a0017b90: eb000821 bl a0019c1c <_API_Mutex_Lock> a0017b94: e1a01005 mov r1, r5 a0017b98: e59f0060 ldr r0, [pc, #96] ; a0017c00 a0017b9c: e1a0200d mov r2, sp a0017ba0: eb000f96 bl a001ba00 <_Objects_Get_no_protection> the_region = _Region_Get( id, &location ); switch ( location ) { a0017ba4: e59d6000 ldr r6, [sp] a0017ba8: e1a05000 mov r5, r0 a0017bac: e3560000 cmp r6, #0 break; #endif case OBJECTS_ERROR: default: return_status = RTEMS_INVALID_ID; a0017bb0: 13a06004 movne r6, #4 register Region_Control *the_region; _RTEMS_Lock_allocator(); the_region = _Region_Get( id, &location ); switch ( location ) { a0017bb4: 1a00000b bne a0017be8 RTEMS_INLINE_ROUTINE bool _Region_Free_segment ( Region_Control *the_region, void *the_segment ) { return _Heap_Free( &the_region->Memory, the_segment ); a0017bb8: e2800068 add r0, r0, #104 ; 0x68 a0017bbc: e1a01004 mov r1, r4 a0017bc0: eb000c1b bl a001ac34 <_Heap_Free> #endif status = _Region_Free_segment( the_region, segment ); _Region_Debug_Walk( the_region, 4 ); if ( !status ) a0017bc4: e3500000 cmp r0, #0 return_status = RTEMS_INVALID_ADDRESS; a0017bc8: 03a06009 moveq r6, #9 #endif status = _Region_Free_segment( the_region, segment ); _Region_Debug_Walk( the_region, 4 ); if ( !status ) a0017bcc: 0a000005 beq a0017be8 return_status = RTEMS_INVALID_ADDRESS; else { the_region->number_of_used_blocks -= 1; a0017bd0: e5953064 ldr r3, [r5, #100] ; 0x64 _Region_Process_queue(the_region); /* unlocks allocator */ a0017bd4: 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; a0017bd8: e2433001 sub r3, r3, #1 a0017bdc: e5853064 str r3, [r5, #100] ; 0x64 _Region_Process_queue(the_region); /* unlocks allocator */ a0017be0: eb001eb8 bl a001f6c8 <_Region_Process_queue> return RTEMS_SUCCESSFUL; a0017be4: ea000002 b a0017bf4 default: return_status = RTEMS_INVALID_ID; break; } _RTEMS_Unlock_allocator(); a0017be8: e59f300c ldr r3, [pc, #12] ; a0017bfc <== NOT EXECUTED a0017bec: e5930000 ldr r0, [r3] <== NOT EXECUTED a0017bf0: eb000822 bl a0019c80 <_API_Mutex_Unlock> <== NOT EXECUTED return return_status; } a0017bf4: e1a00006 mov r0, r6 a0017bf8: e8bd8078 pop {r3, r4, r5, r6, pc} =============================================================================== a0009ec4 : uint32_t count, rtems_attribute attribute_set, rtems_task_priority priority_ceiling, rtems_id *id ) { a0009ec4: 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 ) ) a0009ec8: e2507000 subs r7, r0, #0 uint32_t count, rtems_attribute attribute_set, rtems_task_priority priority_ceiling, rtems_id *id ) { a0009ecc: e24dd018 sub sp, sp, #24 a0009ed0: e1a04001 mov r4, r1 a0009ed4: e1a08002 mov r8, r2 a0009ed8: e1a09003 mov r9, r3 a0009edc: 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; a0009ee0: 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 ) ) a0009ee4: 0a00005a beq a000a054 return RTEMS_INVALID_NAME; if ( !id ) a0009ee8: e3560000 cmp r6, #0 return RTEMS_INVALID_ADDRESS; a0009eec: 03a00009 moveq r0, #9 CORE_mutex_Status mutex_status; if ( !rtems_is_name_valid( name ) ) return RTEMS_INVALID_NAME; if ( !id ) a0009ef0: 0a000057 beq a000a054 return RTEMS_NOT_DEFINED; } else #endif if ( _Attributes_Is_inherit_priority( attribute_set ) || a0009ef4: e21230c0 ands r3, r2, #192 ; 0xc0 a0009ef8: 0a000006 beq a0009f18 */ RTEMS_INLINE_ROUTINE bool _Attributes_Is_binary_semaphore( rtems_attribute attribute_set ) { return ((attribute_set & RTEMS_SEMAPHORE_CLASS) == RTEMS_BINARY_SEMAPHORE); a0009efc: e2022030 and r2, r2, #48 ; 0x30 _Attributes_Is_priority_ceiling( attribute_set ) ) { if ( ! (_Attributes_Is_binary_semaphore( attribute_set ) && a0009f00: e3520010 cmp r2, #16 a0009f04: 1a000051 bne a000a050 a0009f08: e3180004 tst r8, #4 a0009f0c: 0a00004f beq a000a050 _Attributes_Is_priority( attribute_set ) ) ) return RTEMS_NOT_DEFINED; } if ( _Attributes_Is_inherit_priority( attribute_set ) && a0009f10: e35300c0 cmp r3, #192 ; 0xc0 a0009f14: 0a00004d beq a000a050 _Attributes_Is_priority_ceiling( attribute_set ) ) return RTEMS_NOT_DEFINED; if ( !_Attributes_Is_counting_semaphore( attribute_set ) && ( count > 1 ) ) a0009f18: e218a030 ands sl, r8, #48 ; 0x30 a0009f1c: 0a000002 beq a0009f2c a0009f20: e3540001 cmp r4, #1 return RTEMS_INVALID_NUMBER; a0009f24: 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 ) ) a0009f28: 8a000049 bhi a000a054 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a0009f2c: e59f3128 ldr r3, [pc, #296] ; a000a05c a0009f30: e5932000 ldr r2, [r3] ++level; a0009f34: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a0009f38: 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 ); a0009f3c: e59f011c ldr r0, [pc, #284] ; a000a060 a0009f40: eb00056c bl a000b4f8 <_Objects_Allocate> _Thread_Disable_dispatch(); /* prevents deletion */ the_semaphore = _Semaphore_Allocate(); if ( !the_semaphore ) { a0009f44: e2505000 subs r5, r0, #0 a0009f48: 1a000002 bne a0009f58 _Thread_Enable_dispatch(); a0009f4c: eb000a23 bl a000c7e0 <_Thread_Enable_dispatch> return RTEMS_TOO_MANY; a0009f50: e3a00005 mov r0, #5 a0009f54: ea00003e b a000a054 the_semaphore->attribute_set = attribute_set; /* * Initialize it as a counting semaphore. */ if ( _Attributes_Is_counting_semaphore( attribute_set ) ) { a0009f58: e35a0000 cmp sl, #0 _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } #endif the_semaphore->attribute_set = attribute_set; a0009f5c: e5858010 str r8, [r5, #16] a0009f60: e2083004 and r3, r8, #4 /* * Initialize it as a counting semaphore. */ if ( _Attributes_Is_counting_semaphore( attribute_set ) ) { a0009f64: 1a00000b bne a0009f98 * This effectively disables limit checking. */ the_semaphore_attr.maximum_count = 0xFFFFFFFF; if ( _Attributes_Is_priority( attribute_set ) ) the_semaphore_attr.discipline = CORE_SEMAPHORE_DISCIPLINES_PRIORITY; a0009f68: e2933000 adds r3, r3, #0 */ if ( _Attributes_Is_counting_semaphore( attribute_set ) ) { /* * This effectively disables limit checking. */ the_semaphore_attr.maximum_count = 0xFFFFFFFF; a0009f6c: e3e02000 mvn r2, #0 a0009f70: e58d2010 str r2, [sp, #16] if ( _Attributes_Is_priority( attribute_set ) ) the_semaphore_attr.discipline = CORE_SEMAPHORE_DISCIPLINES_PRIORITY; a0009f74: 13a03001 movne r3, #1 * 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( a0009f78: e2850014 add r0, r5, #20 a0009f7c: e28d1010 add r1, sp, #16 a0009f80: e1a02004 mov r2, r4 */ if ( _Attributes_Is_counting_semaphore( attribute_set ) ) { /* * This effectively disables limit checking. */ the_semaphore_attr.maximum_count = 0xFFFFFFFF; a0009f84: e58d3014 str r3, [sp, #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; a0009f88: e58da000 str sl, [sp] the_mutex_attr.priority_ceiling = PRIORITY_MINIMUM; a0009f8c: e58da00c str sl, [sp, #12] _CORE_semaphore_Initialize( a0009f90: eb0003dc bl a000af08 <_CORE_semaphore_Initialize> a0009f94: ea000023 b a000a028 /* * 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 ) ) the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY; a0009f98: e2933000 adds r3, r3, #0 a0009f9c: 13a03001 movne r3, #1 else the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_FIFO; if ( _Attributes_Is_binary_semaphore( attribute_set ) ) { a0009fa0: e35a0010 cmp sl, #16 /* * 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 ) ) the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY; a0009fa4: e58d3008 str r3, [sp, #8] a0009fa8: e3a02000 mov r2, #0 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; a0009fac: 13a03002 movne r3, #2 a0009fb0: 158d3000 strne r3, [sp] the_mutex_attr.only_owner_release = false; a0009fb4: 15cd2004 strbne r2, [sp, #4] 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 ) ) { a0009fb8: 1a00000c bne a0009ff0 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 ) { a0009fbc: e3530001 cmp r3, #1 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; a0009fc0: e58d900c str r9, [sp, #12] the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES; a0009fc4: e58d2000 str r2, [sp] the_mutex_attr.only_owner_release = false; a0009fc8: e5cd2004 strb r2, [sp, #4] if ( the_mutex_attr.discipline == CORE_MUTEX_DISCIPLINES_PRIORITY ) { a0009fcc: 1a000007 bne a0009ff0 if ( _Attributes_Is_inherit_priority( attribute_set ) ) { a0009fd0: e3180040 tst r8, #64 ; 0x40 the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; a0009fd4: 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 ) ) { a0009fd8: 1a000002 bne a0009fe8 the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; the_mutex_attr.only_owner_release = true; } else if ( _Attributes_Is_priority_ceiling( attribute_set ) ) { a0009fdc: e3180080 tst r8, #128 ; 0x80 a0009fe0: 0a000002 beq a0009ff0 the_mutex_attr.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING; a0009fe4: e3a02003 mov r2, #3 a0009fe8: e58d2008 str r2, [sp, #8] the_mutex_attr.only_owner_release = true; a0009fec: e5cd3004 strb r3, [sp, #4] } else /* must be simple binary semaphore */ { the_mutex_attr.lock_nesting_behavior = CORE_MUTEX_NESTING_BLOCKS; the_mutex_attr.only_owner_release = false; } mutex_status = _CORE_mutex_Initialize( a0009ff0: e2443001 sub r3, r4, #1 a0009ff4: e2732000 rsbs r2, r3, #0 a0009ff8: e0a22003 adc r2, r2, r3 a0009ffc: e2850014 add r0, r5, #20 a000a000: e1a0100d mov r1, sp a000a004: eb0002f5 bl a000abe0 <_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 ) { a000a008: e3500006 cmp r0, #6 a000a00c: 1a000005 bne a000a028 */ RTEMS_INLINE_ROUTINE void _Semaphore_Free ( Semaphore_Control *the_semaphore ) { _Objects_Free( &_Semaphore_Information, &the_semaphore->Object ); a000a010: e59f0048 ldr r0, [pc, #72] ; a000a060 a000a014: e1a01005 mov r1, r5 a000a018: eb000605 bl a000b834 <_Objects_Free> _Semaphore_Free( the_semaphore ); _Thread_Enable_dispatch(); a000a01c: eb0009ef bl a000c7e0 <_Thread_Enable_dispatch> return RTEMS_INVALID_PRIORITY; a000a020: e3a00013 mov r0, #19 a000a024: ea00000a b a000a054 #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a028: e59f2030 ldr r2, [pc, #48] ; a000a060 Objects_Information *information, Objects_Control *the_object, Objects_Name name ) { _Objects_Set_local_object( a000a02c: e5953008 ldr r3, [r5, #8] a000a030: e1d510b8 ldrh r1, [r5, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a034: e592201c ldr r2, [r2, #28] a000a038: e7825101 str r5, [r2, r1, lsl #2] information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name; a000a03c: e585700c str r7, [r5, #12] &_Semaphore_Information, &the_semaphore->Object, (Objects_Name) name ); *id = the_semaphore->Object.id; a000a040: e5863000 str r3, [r6] the_semaphore->Object.id, name, 0 /* Not used */ ); #endif _Thread_Enable_dispatch(); a000a044: eb0009e5 bl a000c7e0 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000a048: e3a00000 mov r0, #0 a000a04c: ea000000 b a000a054 } if ( _Attributes_Is_inherit_priority( attribute_set ) && _Attributes_Is_priority_ceiling( attribute_set ) ) return RTEMS_NOT_DEFINED; a000a050: e3a0000b mov r0, #11 <== NOT EXECUTED 0 /* Not used */ ); #endif _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } a000a054: e28dd018 add sp, sp, #24 a000a058: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== a000a064 : #endif rtems_status_code rtems_semaphore_delete( rtems_id id ) { a000a064: e92d4011 push {r0, r4, lr} a000a068: e1a01000 mov r1, r0 RTEMS_INLINE_ROUTINE Semaphore_Control *_Semaphore_Get ( Objects_Id id, Objects_Locations *location ) { return (Semaphore_Control *) a000a06c: e1a0200d mov r2, sp a000a070: e59f0084 ldr r0, [pc, #132] ; a000a0fc a000a074: eb000646 bl a000b994 <_Objects_Get> register Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _Semaphore_Get( id, &location ); switch ( location ) { a000a078: e59d3000 ldr r3, [sp] a000a07c: e1a04000 mov r4, r0 a000a080: e3530000 cmp r3, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000a084: 13a00004 movne r0, #4 { register Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _Semaphore_Get( id, &location ); switch ( location ) { a000a088: 1a00001a bne a000a0f8 */ RTEMS_INLINE_ROUTINE bool _Attributes_Is_counting_semaphore( rtems_attribute attribute_set ) { return ((attribute_set & RTEMS_SEMAPHORE_CLASS) == RTEMS_COUNTING_SEMAPHORE); a000a08c: e5941010 ldr r1, [r4, #16] case OBJECTS_LOCAL: if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) { a000a090: e2111030 ands r1, r1, #48 ; 0x30 a000a094: 0a00000c beq a000a0cc if ( _CORE_mutex_Is_locked( &the_semaphore->Core_control.mutex ) && a000a098: e5943064 ldr r3, [r4, #100] ; 0x64 a000a09c: e3530000 cmp r3, #0 a000a0a0: 1a000004 bne a000a0b8 a000a0a4: e3510020 cmp r1, #32 a000a0a8: 0a000002 beq a000a0b8 !_Attributes_Is_simple_binary_semaphore( the_semaphore->attribute_set ) ) { _Thread_Enable_dispatch(); a000a0ac: eb0009cb bl a000c7e0 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_RESOURCE_IN_USE; a000a0b0: e3a0000c mov r0, #12 <== NOT EXECUTED a000a0b4: ea00000f b a000a0f8 <== NOT EXECUTED } _CORE_mutex_Flush( a000a0b8: e2840014 add r0, r4, #20 a000a0bc: e3a01000 mov r1, #0 a000a0c0: e3a02004 mov r2, #4 a000a0c4: eb0002c4 bl a000abdc <_CORE_mutex_Flush> a000a0c8: ea000002 b a000a0d8 &the_semaphore->Core_control.mutex, SEMAPHORE_MP_OBJECT_WAS_DELETED, CORE_MUTEX_WAS_DELETED ); } else { _CORE_semaphore_Flush( a000a0cc: e2840014 add r0, r4, #20 a000a0d0: e3a02002 mov r2, #2 a000a0d4: eb00038a bl a000af04 <_CORE_semaphore_Flush> SEMAPHORE_MP_OBJECT_WAS_DELETED, CORE_SEMAPHORE_WAS_DELETED ); } _Objects_Close( &_Semaphore_Information, &the_semaphore->Object ); a000a0d8: e59f001c ldr r0, [pc, #28] ; a000a0fc a000a0dc: e1a01004 mov r1, r4 a000a0e0: eb000526 bl a000b580 <_Objects_Close> */ RTEMS_INLINE_ROUTINE void _Semaphore_Free ( Semaphore_Control *the_semaphore ) { _Objects_Free( &_Semaphore_Information, &the_semaphore->Object ); a000a0e4: e59f0010 ldr r0, [pc, #16] ; a000a0fc a000a0e8: e1a01004 mov r1, r4 a000a0ec: eb0005d0 bl a000b834 <_Objects_Free> 0, /* Not used */ 0 /* Not used */ ); } #endif _Thread_Enable_dispatch(); a000a0f0: eb0009ba bl a000c7e0 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000a0f4: e3a00000 mov r0, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a000a0f8: e8bd8018 pop {r3, r4, pc} =============================================================================== a00130cc : #endif rtems_status_code rtems_semaphore_flush( rtems_id id ) { a00130cc: e92d4001 push {r0, lr} a00130d0: e1a01000 mov r1, r0 a00130d4: e1a0200d mov r2, sp a00130d8: e59f0044 ldr r0, [pc, #68] ; a0013124 a00130dc: ebffe6fd bl a000ccd8 <_Objects_Get> register Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _Semaphore_Get( id, &location ); switch ( location ) { a00130e0: e59d3000 ldr r3, [sp] a00130e4: e3530000 cmp r3, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a00130e8: 13a00004 movne r0, #4 { register Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _Semaphore_Get( id, &location ); switch ( location ) { a00130ec: 1a00000b bne a0013120 a00130f0: e5901010 ldr r1, [r0, #16] a00130f4: e2800014 add r0, r0, #20 case OBJECTS_LOCAL: if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) { a00130f8: e2111030 ands r1, r1, #48 ; 0x30 a00130fc: 0a000003 beq a0013110 _CORE_mutex_Flush( a0013100: e1a01003 mov r1, r3 a0013104: e3a02001 mov r2, #1 a0013108: ebffe3aa bl a000bfb8 <_CORE_mutex_Flush> a001310c: ea000001 b a0013118 &the_semaphore->Core_control.mutex, SEND_OBJECT_WAS_DELETED, CORE_MUTEX_STATUS_UNSATISFIED_NOWAIT ); } else { _CORE_semaphore_Flush( a0013110: e3a02001 mov r2, #1 <== NOT EXECUTED a0013114: ebffe471 bl a000c2e0 <_CORE_semaphore_Flush> <== NOT EXECUTED &the_semaphore->Core_control.semaphore, SEND_OBJECT_WAS_DELETED, CORE_SEMAPHORE_STATUS_UNSATISFIED_NOWAIT ); } _Thread_Enable_dispatch(); a0013118: ebffea05 bl a000d934 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a001311c: e3a00000 mov r0, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0013120: e8bd8008 pop {r3, pc} =============================================================================== a000a100 : rtems_status_code rtems_semaphore_obtain( rtems_id id, rtems_option option_set, rtems_interval timeout ) { a000a100: e92d4077 push {r0, r1, r2, r4, r5, r6, lr} a000a104: e1a04000 mov r4, r0 Objects_Id id, Objects_Locations *location, ISR_Level *level ) { return (Semaphore_Control *) a000a108: e28d3008 add r3, sp, #8 a000a10c: e1a06001 mov r6, r1 a000a110: e1a05002 mov r5, r2 a000a114: e59f00f0 ldr r0, [pc, #240] ; a000a20c a000a118: e1a01004 mov r1, r4 a000a11c: e28d2004 add r2, sp, #4 a000a120: eb000600 bl a000b928 <_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 ) { a000a124: e59d3004 ldr r3, [sp, #4] a000a128: e3530000 cmp r3, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000a12c: 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 ) { a000a130: 1a000034 bne a000a208 a000a134: e5903010 ldr r3, [r0, #16] case OBJECTS_LOCAL: if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) { a000a138: e2132030 ands r2, r3, #48 ; 0x30 a000a13c: 0a00000c beq a000a174 _CORE_mutex_Seize( a000a140: e59d3008 ldr r3, [sp, #8] */ RTEMS_INLINE_ROUTINE bool _Options_Is_no_wait ( rtems_option option_set ) { return (option_set & RTEMS_NO_WAIT) ? true : false; a000a144: e2062001 and r2, r6, #1 a000a148: e2800014 add r0, r0, #20 a000a14c: e58d3000 str r3, [sp] a000a150: e1a01004 mov r1, r4 a000a154: e1a03005 mov r3, r5 a000a158: e2222001 eor r2, r2, #1 a000a15c: eb0002ed bl a000ad18 <_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 ); a000a160: e59f30a8 ldr r3, [pc, #168] ; a000a210 a000a164: e5933008 ldr r3, [r3, #8] id, ((_Options_Is_no_wait( option_set )) ? false : true), timeout, level ); return _Semaphore_Translate_core_mutex_return_code( a000a168: e5930034 ldr r0, [r3, #52] ; 0x34 a000a16c: eb000047 bl a000a290 <_Semaphore_Translate_core_mutex_return_code> a000a170: ea000024 b a000a208 { Thread_Control *executing; /* disabled when you get here */ executing = _Thread_Executing; a000a174: e59f3094 ldr r3, [pc, #148] ; a000a210 a000a178: e5933008 ldr r3, [r3, #8] executing->Wait.return_code = CORE_SEMAPHORE_STATUS_SUCCESSFUL; a000a17c: e5832034 str r2, [r3, #52] ; 0x34 if ( the_semaphore->count != 0 ) { a000a180: e590205c ldr r2, [r0, #92] ; 0x5c a000a184: e3520000 cmp r2, #0 a000a188: 0a000004 beq a000a1a0 the_semaphore->count -= 1; a000a18c: e2422001 sub r2, r2, #1 a000a190: e580205c str r2, [r0, #92] ; 0x5c a000a194: e59d3008 ldr r3, [sp, #8] a000a198: e129f003 msr CPSR_fc, r3 a000a19c: ea000015 b a000a1f8 _ISR_Enable( *level_p ); return; } if ( !wait ) { a000a1a0: e3160001 tst r6, #1 a000a1a4: 0a000004 beq a000a1bc a000a1a8: e59d2008 ldr r2, [sp, #8] <== NOT EXECUTED a000a1ac: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED _ISR_Enable( *level_p ); executing->Wait.return_code = CORE_SEMAPHORE_STATUS_UNSATISFIED_NOWAIT; a000a1b0: e3a02001 mov r2, #1 <== NOT EXECUTED a000a1b4: e5832034 str r2, [r3, #52] ; 0x34 <== NOT EXECUTED a000a1b8: ea00000e b a000a1f8 <== NOT EXECUTED * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000a1bc: e59f2050 ldr r2, [pc, #80] ; a000a214 a000a1c0: e5921000 ldr r1, [r2] ++level; a000a1c4: e2811001 add r1, r1, #1 _Thread_Dispatch_disable_level = level; a000a1c8: 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; a000a1cc: e3a02001 mov r2, #1 a000a1d0: 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; a000a1d4: e2800014 add r0, r0, #20 a000a1d8: e5830044 str r0, [r3, #68] ; 0x44 executing->Wait.id = id; a000a1dc: e5834020 str r4, [r3, #32] a000a1e0: e59d3008 ldr r3, [sp, #8] a000a1e4: e129f003 msr CPSR_fc, r3 _ISR_Enable( *level_p ); _Thread_queue_Enqueue( &the_semaphore->Wait_queue, timeout ); a000a1e8: e59f2028 ldr r2, [pc, #40] ; a000a218 a000a1ec: e1a01005 mov r1, r5 a000a1f0: eb000aa5 bl a000cc8c <_Thread_queue_Enqueue_with_handler> _Thread_Enable_dispatch(); a000a1f4: eb000979 bl a000c7e0 <_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 ); a000a1f8: e59f3010 ldr r3, [pc, #16] ; a000a210 a000a1fc: e5933008 ldr r3, [r3, #8] id, ((_Options_Is_no_wait( option_set )) ? false : true), timeout, &level ); return _Semaphore_Translate_core_semaphore_return_code( a000a200: e5930034 ldr r0, [r3, #52] ; 0x34 a000a204: eb000025 bl a000a2a0 <_Semaphore_Translate_core_semaphore_return_code> break; } return RTEMS_INVALID_ID; } a000a208: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc} =============================================================================== a0018084 : rtems_status_code rtems_signal_send( rtems_id id, rtems_signal_set signal_set ) { a0018084: e92d4011 push {r0, r4, lr} register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; ASR_Information *asr; if ( !signal_set ) a0018088: e2514000 subs r4, r1, #0 return RTEMS_INVALID_NUMBER; a001808c: 03a0000a moveq r0, #10 register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; ASR_Information *asr; if ( !signal_set ) a0018090: 0a000025 beq a001812c return RTEMS_INVALID_NUMBER; the_thread = _Thread_Get( id, &location ); a0018094: e1a0100d mov r1, sp a0018098: eb001201 bl a001c8a4 <_Thread_Get> switch ( location ) { a001809c: e59d3000 ldr r3, [sp] a00180a0: e3530000 cmp r3, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a00180a4: 13a00004 movne r0, #4 if ( !signal_set ) return RTEMS_INVALID_NUMBER; the_thread = _Thread_Get( id, &location ); switch ( location ) { a00180a8: 1a00001f bne a001812c case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_RTEMS ]; a00180ac: e59030f0 ldr r3, [r0, #240] ; 0xf0 asr = &api->Signal; if ( ! _ASR_Is_null_handler( asr->handler ) ) { a00180b0: e593200c ldr r2, [r3, #12] a00180b4: e3520000 cmp r2, #0 a00180b8: 0a000019 beq a0018124 if ( asr->is_enabled ) { a00180bc: e5d32008 ldrb r2, [r3, #8] a00180c0: e3520000 cmp r2, #0 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a00180c4: e10f2000 mrs r2, CPSR a00180c8: e3821080 orr r1, r2, #128 ; 0x80 a00180cc: e129f001 msr CPSR_fc, r1 a00180d0: 0a00000c beq a0018108 ) { ISR_Level _level; _ISR_Disable( _level ); *signal_set |= signals; a00180d4: e5931014 ldr r1, [r3, #20] a00180d8: e1814004 orr r4, r1, r4 a00180dc: e5834014 str r4, [r3, #20] static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a00180e0: e129f002 msr CPSR_fc, r2 _ASR_Post_signals( signal_set, &asr->signals_posted ); if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) ) a00180e4: e59f3044 ldr r3, [pc, #68] ; a0018130 a00180e8: e5932000 ldr r2, [r3] a00180ec: e3520000 cmp r2, #0 a00180f0: 0a000008 beq a0018118 a00180f4: e5932008 ldr r2, [r3, #8] <== NOT EXECUTED a00180f8: e1500002 cmp r0, r2 <== NOT EXECUTED _Thread_Dispatch_necessary = true; a00180fc: 03a02001 moveq r2, #1 <== NOT EXECUTED a0018100: 05c32004 strbeq r2, [r3, #4] <== NOT EXECUTED a0018104: ea000003 b a0018118 <== NOT EXECUTED a0018108: e5931018 ldr r1, [r3, #24] <== NOT EXECUTED a001810c: e1814004 orr r4, r1, r4 <== NOT EXECUTED a0018110: e5834018 str r4, [r3, #24] <== NOT EXECUTED a0018114: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED } else { _ASR_Post_signals( signal_set, &asr->signals_pending ); } _Thread_Enable_dispatch(); a0018118: eb0011d9 bl a001c884 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a001811c: e3a00000 mov r0, #0 a0018120: ea000001 b a001812c } _Thread_Enable_dispatch(); a0018124: eb0011d6 bl a001c884 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_NOT_DEFINED; a0018128: e3a0000b mov r0, #11 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a001812c: e8bd8018 pop {r3, r4, pc} =============================================================================== a000bf38 : rtems_status_code rtems_task_get_note( rtems_id id, uint32_t notepad, uint32_t *note ) { a000bf38: e92d4071 push {r0, r4, r5, r6, lr} a000bf3c: e1a05002 mov r5, r2 register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; if ( !rtems_configuration_get_notepads_enabled() ) a000bf40: e59f2098 ldr r2, [pc, #152] ; a000bfe0 rtems_status_code rtems_task_get_note( rtems_id id, uint32_t notepad, uint32_t *note ) { a000bf44: e1a03000 mov r3, r0 a000bf48: e1a04001 mov r4, r1 register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; if ( !rtems_configuration_get_notepads_enabled() ) a000bf4c: e5d22004 ldrb r2, [r2, #4] a000bf50: e3520000 cmp r2, #0 return RTEMS_NOT_CONFIGURED; a000bf54: 03a00016 moveq r0, #22 { register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; if ( !rtems_configuration_get_notepads_enabled() ) a000bf58: 0a00001f beq a000bfdc return RTEMS_NOT_CONFIGURED; if ( !note ) a000bf5c: e3550000 cmp r5, #0 return RTEMS_INVALID_ADDRESS; a000bf60: 03a00009 moveq r0, #9 RTEMS_API_Control *api; if ( !rtems_configuration_get_notepads_enabled() ) return RTEMS_NOT_CONFIGURED; if ( !note ) a000bf64: 0a00001c beq a000bfdc /* * 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 ) a000bf68: e351000f cmp r1, #15 return RTEMS_INVALID_NUMBER; a000bf6c: 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 ) a000bf70: 8a000019 bhi a000bfdc /* * Optimize the most likely case to avoid the Thread_Dispatch. */ if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) || a000bf74: e3530000 cmp r3, #0 a000bf78: e59f2064 ldr r2, [pc, #100] ; a000bfe4 a000bf7c: 0a000003 beq a000bf90 _Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) { a000bf80: e5921008 ldr r1, [r2, #8] /* * Optimize the most likely case to avoid the Thread_Dispatch. */ if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) || a000bf84: e5911008 ldr r1, [r1, #8] a000bf88: e1530001 cmp r3, r1 a000bf8c: 1a000006 bne a000bfac _Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) { api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ]; a000bf90: e5923008 ldr r3, [r2, #8] <== NOT EXECUTED *note = api->Notepads[ notepad ]; a000bf94: e2844008 add r4, r4, #8 <== NOT EXECUTED return RTEMS_SUCCESSFUL; a000bf98: e3a00000 mov r0, #0 <== NOT EXECUTED */ 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 ]; *note = api->Notepads[ notepad ]; a000bf9c: e59330f0 ldr r3, [r3, #240] ; 0xf0 <== NOT EXECUTED a000bfa0: e7933104 ldr r3, [r3, r4, lsl #2] <== NOT EXECUTED a000bfa4: e5853000 str r3, [r5] <== NOT EXECUTED return RTEMS_SUCCESSFUL; a000bfa8: ea00000b b a000bfdc <== NOT EXECUTED } the_thread = _Thread_Get( id, &location ); a000bfac: e1a0100d mov r1, sp a000bfb0: eb000985 bl a000e5cc <_Thread_Get> switch ( location ) { a000bfb4: e59d6000 ldr r6, [sp] a000bfb8: e3560000 cmp r6, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000bfbc: 13a00004 movne r0, #4 *note = api->Notepads[ notepad ]; return RTEMS_SUCCESSFUL; } the_thread = _Thread_Get( id, &location ); switch ( location ) { a000bfc0: 1a000005 bne a000bfdc case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_RTEMS ]; *note = api->Notepads[ notepad ]; a000bfc4: e59030f0 ldr r3, [r0, #240] ; 0xf0 a000bfc8: e2844008 add r4, r4, #8 a000bfcc: e7933104 ldr r3, [r3, r4, lsl #2] a000bfd0: e5853000 str r3, [r5] _Thread_Enable_dispatch(); a000bfd4: eb000974 bl a000e5ac <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000bfd8: e1a00006 mov r0, r6 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a000bfdc: e8bd8078 pop {r3, r4, r5, r6, pc} =============================================================================== a000a4c4 : rtems_id *id ) { Objects_Name_or_id_lookup_errors status; if ( !id ) a000a4c4: e2523000 subs r3, r2, #0 rtems_status_code rtems_task_ident( rtems_name name, uint32_t node, rtems_id *id ) { a000a4c8: e92d4010 push {r4, lr} a000a4cc: e1a0c000 mov ip, r0 a000a4d0: e1a04001 mov r4, r1 Objects_Name_or_id_lookup_errors status; if ( !id ) a000a4d4: 0a00000d beq a000a510 return RTEMS_INVALID_ADDRESS; if ( name == OBJECTS_ID_OF_SELF ) { a000a4d8: e3500000 cmp r0, #0 a000a4dc: 1a000004 bne a000a4f4 *id = _Thread_Executing->Object.id; a000a4e0: e59f2030 ldr r2, [pc, #48] ; a000a518 a000a4e4: e5922008 ldr r2, [r2, #8] a000a4e8: e5922008 ldr r2, [r2, #8] a000a4ec: e5832000 str r2, [r3] return RTEMS_SUCCESSFUL; a000a4f0: e8bd8010 pop {r4, pc} } status = _Objects_Name_to_id_u32( &_RTEMS_tasks_Information, name, node, id ); a000a4f4: e59f0020 ldr r0, [pc, #32] ; a000a51c a000a4f8: e1a0100c mov r1, ip a000a4fc: e1a02004 mov r2, r4 a000a500: eb00057c bl a000baf8 <_Objects_Name_to_id_u32> return _Status_Object_name_errors_to_status[ status ]; a000a504: e59f3014 ldr r3, [pc, #20] ; a000a520 a000a508: e7930100 ldr r0, [r3, r0, lsl #2] a000a50c: e8bd8010 pop {r4, pc} ) { Objects_Name_or_id_lookup_errors status; if ( !id ) return RTEMS_INVALID_ADDRESS; a000a510: 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 ]; } a000a514: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a00184d8 : */ rtems_status_code rtems_task_is_suspended( rtems_id id ) { a00184d8: e92d4011 push {r0, r4, lr} register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); a00184dc: e1a0100d mov r1, sp a00184e0: eb0010ef bl a001c8a4 <_Thread_Get> switch ( location ) { a00184e4: e59d3000 ldr r3, [sp] a00184e8: e3530000 cmp r3, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a00184ec: 13a00004 movne r0, #4 { register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { a00184f0: 1a000007 bne a0018514 */ RTEMS_INLINE_ROUTINE bool _States_Is_suspended ( States_Control the_states ) { return (the_states & STATES_SUSPENDED); a00184f4: e5904010 ldr r4, [r0, #16] <== NOT EXECUTED case OBJECTS_LOCAL: if ( !_States_Is_suspended( the_thread->current_state ) ) { a00184f8: e2144002 ands r4, r4, #2 <== NOT EXECUTED a00184fc: 1a000002 bne a001850c <== NOT EXECUTED _Thread_Enable_dispatch(); a0018500: eb0010df bl a001c884 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_SUCCESSFUL; a0018504: e1a00004 mov r0, r4 <== NOT EXECUTED a0018508: ea000001 b a0018514 <== NOT EXECUTED } _Thread_Enable_dispatch(); a001850c: eb0010dc bl a001c884 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_ALREADY_SUSPENDED; a0018510: e3a0000f mov r0, #15 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0018514: e8bd8018 pop {r3, r4, pc} =============================================================================== a00131e4 : rtems_status_code rtems_task_mode( rtems_mode mode_set, rtems_mode mask, rtems_mode *previous_mode_set ) { a00131e4: 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 ) a00131e8: e252a000 subs sl, r2, #0 rtems_status_code rtems_task_mode( rtems_mode mode_set, rtems_mode mask, rtems_mode *previous_mode_set ) { a00131ec: e1a04000 mov r4, r0 a00131f0: 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 ) a00131f4: 0a00004f beq a0013338 return RTEMS_INVALID_ADDRESS; executing = _Thread_Executing; a00131f8: e59f3144 ldr r3, [pc, #324] ; a0013344 a00131fc: e5937008 ldr r7, [r3, #8] api = executing->API_Extensions[ THREAD_API_RTEMS ]; a0013200: e59760f0 ldr r6, [r7, #240] ; 0xf0 asr = &api->Signal; old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT; a0013204: e5d78070 ldrb r8, [r7, #112] ; 0x70 if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE ) a0013208: e5973078 ldr r3, [r7, #120] ; 0x78 old_mode |= RTEMS_NO_TIMESLICE; else old_mode |= RTEMS_TIMESLICE; old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR; a001320c: 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; a0013210: e3580000 cmp r8, #0 a0013214: 03a08c01 moveq r8, #256 ; 0x100 a0013218: 13a08000 movne r8, #0 if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE ) a001321c: e3530000 cmp r3, #0 old_mode |= RTEMS_NO_TIMESLICE; else old_mode |= RTEMS_TIMESLICE; a0013220: 13888c02 orrne r8, r8, #512 ; 0x200 old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR; a0013224: e3590000 cmp r9, #0 a0013228: 03a09b01 moveq r9, #1024 ; 0x400 a001322c: 13a09000 movne r9, #0 old_mode |= _ISR_Get_level(); a0013230: ebffee60 bl a000ebb8 <_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; a0013234: e1899000 orr r9, r9, r0 old_mode |= _ISR_Get_level(); a0013238: e1898008 orr r8, r9, r8 *previous_mode_set = old_mode; /* * These are generic thread scheduling characteristics. */ if ( mask & RTEMS_PREEMPT_MASK ) a001323c: 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; a0013240: e58a8000 str r8, [sl] /* * These are generic thread scheduling characteristics. */ if ( mask & RTEMS_PREEMPT_MASK ) a0013244: 0a000003 beq a0013258 executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false; a0013248: e3140c01 tst r4, #256 ; 0x100 a001324c: 13a03000 movne r3, #0 a0013250: 03a03001 moveq r3, #1 a0013254: e5c73070 strb r3, [r7, #112] ; 0x70 if ( mask & RTEMS_TIMESLICE_MASK ) { a0013258: e3150c02 tst r5, #512 ; 0x200 a001325c: 0a000006 beq a001327c if ( _Modes_Is_timeslice(mode_set) ) { a0013260: e2143c02 ands r3, r4, #512 ; 0x200 executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE; a0013264: 13a03001 movne r3, #1 a0013268: 15873078 strne r3, [r7, #120] ; 0x78 executing->cpu_time_budget = _Thread_Ticks_per_timeslice; a001326c: 159f30d4 ldrne r3, [pc, #212] ; a0013348 } else executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE; a0013270: 05873078 streq r3, [r7, #120] ; 0x78 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; a0013274: 15933000 ldrne r3, [r3] a0013278: 15873074 strne r3, [r7, #116] ; 0x74 } /* * Set the new interrupt level */ if ( mask & RTEMS_INTERRUPT_MASK ) a001327c: e3150080 tst r5, #128 ; 0x80 a0013280: 0a000001 beq a001328c */ RTEMS_INLINE_ROUTINE void _Modes_Set_interrupt_level ( Modes_Control mode_set ) { _ISR_Set_level( _Modes_Get_interrupt_level( mode_set ) ); a0013284: e2040080 and r0, r4, #128 ; 0x80 a0013288: ebffee45 bl a000eba4 <_CPU_ISR_Set_level> * This is specific to the RTEMS API */ is_asr_enabled = false; needs_asr_dispatching = false; if ( mask & RTEMS_ASR_MASK ) { a001328c: e2150b01 ands r0, r5, #1024 ; 0x400 a0013290: 0a000013 beq a00132e4 is_asr_enabled = _Modes_Is_asr_disabled( mode_set ) ? false : true; if ( is_asr_enabled != asr->is_enabled ) { a0013294: e5d62008 ldrb r2, [r6, #8] #include #include #include #include rtems_status_code rtems_task_mode( a0013298: e3140b01 tst r4, #1024 ; 0x400 a001329c: 13a03000 movne r3, #0 a00132a0: 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 ) { a00132a4: e1520003 cmp r2, r3 /* * This is specific to the RTEMS API */ is_asr_enabled = false; needs_asr_dispatching = false; a00132a8: 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 ) { a00132ac: 0a00000c beq a00132e4 asr->is_enabled = is_asr_enabled; a00132b0: e5c63008 strb r3, [r6, #8] uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a00132b4: e10f3000 mrs r3, CPSR a00132b8: e3832080 orr r2, r3, #128 ; 0x80 a00132bc: e129f002 msr CPSR_fc, r2 { rtems_signal_set _signals; ISR_Level _level; _ISR_Disable( _level ); _signals = information->signals_pending; a00132c0: e5962018 ldr r2, [r6, #24] information->signals_pending = information->signals_posted; a00132c4: e5961014 ldr r1, [r6, #20] information->signals_posted = _signals; a00132c8: 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; a00132cc: e5861018 str r1, [r6, #24] static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a00132d0: e129f003 msr CPSR_fc, r3 _ASR_Swap_signals( asr ); if ( _ASR_Are_signals_pending( asr ) ) { a00132d4: e5960014 ldr r0, [r6, #20] /* * This is specific to the RTEMS API */ is_asr_enabled = false; needs_asr_dispatching = false; a00132d8: e3500000 cmp r0, #0 a00132dc: 13a00001 movne r0, #1 a00132e0: 03a00000 moveq r0, #0 needs_asr_dispatching = true; } } } if ( _System_state_Is_up( _System_state_Get() ) ) { a00132e4: e59f3060 ldr r3, [pc, #96] ; a001334c a00132e8: e5933000 ldr r3, [r3] a00132ec: e3530003 cmp r3, #3 if (_Thread_Evaluate_is_dispatch_needed( needs_asr_dispatching ) ) _Thread_Dispatch(); } return RTEMS_SUCCESSFUL; a00132f0: 13a00000 movne r0, #0 needs_asr_dispatching = true; } } } if ( _System_state_Is_up( _System_state_Get() ) ) { a00132f4: 1a000011 bne a0013340 bool are_signals_pending ) { Thread_Control *executing; executing = _Thread_Executing; a00132f8: e59f3044 ldr r3, [pc, #68] ; a0013344 if ( are_signals_pending || a00132fc: e3500000 cmp r0, #0 bool are_signals_pending ) { Thread_Control *executing; executing = _Thread_Executing; a0013300: e5932008 ldr r2, [r3, #8] a0013304: e1a01003 mov r1, r3 if ( are_signals_pending || a0013308: 1a000005 bne a0013324 a001330c: e593300c ldr r3, [r3, #12] a0013310: e1520003 cmp r2, r3 a0013314: 0a000009 beq a0013340 (!_Thread_Is_heir( executing ) && executing->is_preemptible) ) { a0013318: e5d23070 ldrb r3, [r2, #112] ; 0x70 a001331c: e3530000 cmp r3, #0 a0013320: 0a000006 beq a0013340 _Thread_Dispatch_necessary = true; a0013324: e3a03001 mov r3, #1 a0013328: e5c13004 strb r3, [r1, #4] if (_Thread_Evaluate_is_dispatch_needed( needs_asr_dispatching ) ) _Thread_Dispatch(); a001332c: eb000276 bl a0013d0c <_Thread_Dispatch> } return RTEMS_SUCCESSFUL; a0013330: e3a00000 mov r0, #0 a0013334: 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; a0013338: e3a00009 mov r0, #9 <== NOT EXECUTED a001333c: 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; } a0013340: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== a000d440 : #include rtems_status_code rtems_task_resume( rtems_id id ) { a000d440: e92d4011 push {r0, r4, lr} register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); a000d444: e1a0100d mov r1, sp a000d448: eb000873 bl a000f61c <_Thread_Get> switch ( location ) { a000d44c: e59d4000 ldr r4, [sp] ) { register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); a000d450: e1a03000 mov r3, r0 switch ( location ) { a000d454: e3540000 cmp r4, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000d458: 13a00004 movne r0, #4 { register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { a000d45c: 1a000009 bne a000d488 */ RTEMS_INLINE_ROUTINE bool _States_Is_suspended ( States_Control the_states ) { return (the_states & STATES_SUSPENDED); a000d460: e5933010 ldr r3, [r3, #16] case OBJECTS_LOCAL: if ( _States_Is_suspended( the_thread->current_state ) ) { a000d464: e3130002 tst r3, #2 a000d468: 0a000004 beq a000d480 _Thread_Resume( the_thread ); a000d46c: e3a01002 mov r1, #2 a000d470: eb000784 bl a000f288 <_Thread_Clear_state> _Thread_Enable_dispatch(); a000d474: eb000860 bl a000f5fc <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000d478: e1a00004 mov r0, r4 a000d47c: ea000001 b a000d488 } _Thread_Enable_dispatch(); a000d480: eb00085d bl a000f5fc <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_INCORRECT_STATE; a000d484: e3a0000e mov r0, #14 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a000d488: e8bd8018 pop {r3, r4, pc} =============================================================================== a000c0cc : rtems_status_code rtems_task_set_note( rtems_id id, uint32_t notepad, uint32_t note ) { a000c0cc: e92d4071 push {r0, r4, r5, r6, lr} a000c0d0: e1a05002 mov r5, r2 register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; if ( !rtems_configuration_get_notepads_enabled() ) a000c0d4: e59f2084 ldr r2, [pc, #132] ; a000c160 rtems_status_code rtems_task_set_note( rtems_id id, uint32_t notepad, uint32_t note ) { a000c0d8: e1a03000 mov r3, r0 a000c0dc: e1a04001 mov r4, r1 register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; if ( !rtems_configuration_get_notepads_enabled() ) a000c0e0: e5d22004 ldrb r2, [r2, #4] a000c0e4: e3520000 cmp r2, #0 return RTEMS_NOT_CONFIGURED; a000c0e8: 03a00016 moveq r0, #22 { register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; if ( !rtems_configuration_get_notepads_enabled() ) a000c0ec: 0a00001a beq a000c15c /* * 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 ) a000c0f0: e351000f cmp r1, #15 return RTEMS_INVALID_NUMBER; a000c0f4: 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 ) a000c0f8: 8a000017 bhi a000c15c /* * Optimize the most likely case to avoid the Thread_Dispatch. */ if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) || a000c0fc: e3530000 cmp r3, #0 a000c100: e59f205c ldr r2, [pc, #92] ; a000c164 a000c104: 0a000003 beq a000c118 _Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) { a000c108: e5921008 ldr r1, [r2, #8] /* * Optimize the most likely case to avoid the Thread_Dispatch. */ if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) || a000c10c: e5911008 ldr r1, [r1, #8] a000c110: e1530001 cmp r3, r1 a000c114: 1a000005 bne a000c130 _Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) { api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ]; a000c118: e5923008 ldr r3, [r2, #8] <== NOT EXECUTED api->Notepads[ notepad ] = note; a000c11c: e2844008 add r4, r4, #8 <== NOT EXECUTED return RTEMS_SUCCESSFUL; a000c120: e3a00000 mov r0, #0 <== NOT EXECUTED */ 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 ]; api->Notepads[ notepad ] = note; a000c124: e59330f0 ldr r3, [r3, #240] ; 0xf0 <== NOT EXECUTED a000c128: e7835104 str r5, [r3, r4, lsl #2] <== NOT EXECUTED return RTEMS_SUCCESSFUL; a000c12c: ea00000a b a000c15c <== NOT EXECUTED } the_thread = _Thread_Get( id, &location ); a000c130: e1a0100d mov r1, sp a000c134: eb000924 bl a000e5cc <_Thread_Get> switch ( location ) { a000c138: e59d6000 ldr r6, [sp] a000c13c: e3560000 cmp r6, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000c140: 13a00004 movne r0, #4 api->Notepads[ notepad ] = note; return RTEMS_SUCCESSFUL; } the_thread = _Thread_Get( id, &location ); switch ( location ) { a000c144: 1a000004 bne a000c15c case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_RTEMS ]; api->Notepads[ notepad ] = note; a000c148: e59030f0 ldr r3, [r0, #240] ; 0xf0 a000c14c: e2844008 add r4, r4, #8 a000c150: e7835104 str r5, [r3, r4, lsl #2] _Thread_Enable_dispatch(); a000c154: eb000914 bl a000e5ac <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000c158: e1a00006 mov r0, r6 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a000c15c: e8bd8078 pop {r3, r4, r5, r6, pc} =============================================================================== a000e414 : rtems_status_code rtems_task_set_priority( rtems_id id, rtems_task_priority new_priority, rtems_task_priority *old_priority ) { a000e414: e92d4031 push {r0, r4, r5, lr} register Thread_Control *the_thread; Objects_Locations location; if ( new_priority != RTEMS_CURRENT_PRIORITY && a000e418: 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 ) { a000e41c: e1a05002 mov r5, r2 register Thread_Control *the_thread; Objects_Locations location; if ( new_priority != RTEMS_CURRENT_PRIORITY && a000e420: 0a000004 beq a000e438 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 ) ); a000e424: e59f3074 ldr r3, [pc, #116] ; a000e4a0 a000e428: e5d33000 ldrb r3, [r3] a000e42c: e1540003 cmp r4, r3 !_RTEMS_tasks_Priority_is_valid( new_priority ) ) return RTEMS_INVALID_PRIORITY; a000e430: 83a00013 movhi r0, #19 ) { register Thread_Control *the_thread; Objects_Locations location; if ( new_priority != RTEMS_CURRENT_PRIORITY && a000e434: 8a000018 bhi a000e49c !_RTEMS_tasks_Priority_is_valid( new_priority ) ) return RTEMS_INVALID_PRIORITY; if ( !old_priority ) a000e438: e3550000 cmp r5, #0 return RTEMS_INVALID_ADDRESS; a000e43c: 03a00009 moveq r0, #9 if ( new_priority != RTEMS_CURRENT_PRIORITY && !_RTEMS_tasks_Priority_is_valid( new_priority ) ) return RTEMS_INVALID_PRIORITY; if ( !old_priority ) a000e440: 0a000015 beq a000e49c return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get( id, &location ); a000e444: e1a0100d mov r1, sp a000e448: eb0008f9 bl a0010834 <_Thread_Get> switch ( location ) { a000e44c: e59d3000 ldr r3, [sp] a000e450: e3530000 cmp r3, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000e454: 13a00004 movne r0, #4 if ( !old_priority ) return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get( id, &location ); switch ( location ) { a000e458: 1a00000f bne a000e49c case OBJECTS_LOCAL: /* XXX need helper to "convert" from core priority */ *old_priority = the_thread->current_priority; a000e45c: e5903014 ldr r3, [r0, #20] if ( new_priority != RTEMS_CURRENT_PRIORITY ) { a000e460: 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; a000e464: e5853000 str r3, [r5] if ( new_priority != RTEMS_CURRENT_PRIORITY ) { a000e468: 0a000009 beq a000e494 the_thread->real_priority = new_priority; if ( the_thread->resource_count == 0 || a000e46c: 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; a000e470: e5804018 str r4, [r0, #24] if ( the_thread->resource_count == 0 || a000e474: e3530000 cmp r3, #0 a000e478: 0a000002 beq a000e488 a000e47c: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED a000e480: e1530004 cmp r3, r4 <== NOT EXECUTED a000e484: 9a000002 bls a000e494 <== NOT EXECUTED the_thread->current_priority > new_priority ) _Thread_Change_priority( the_thread, new_priority, false ); a000e488: e1a01004 mov r1, r4 a000e48c: e3a02000 mov r2, #0 a000e490: eb0007c6 bl a00103b0 <_Thread_Change_priority> } _Thread_Enable_dispatch(); a000e494: eb0008de bl a0010814 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000e498: e3a00000 mov r0, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a000e49c: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000a5a8 : rtems_status_code rtems_task_start( rtems_id id, rtems_task_entry entry_point, rtems_task_argument argument ) { a000a5a8: e92d4073 push {r0, r1, r4, r5, r6, lr} register Thread_Control *the_thread; Objects_Locations location; if ( entry_point == NULL ) a000a5ac: e2515000 subs r5, r1, #0 rtems_status_code rtems_task_start( rtems_id id, rtems_task_entry entry_point, rtems_task_argument argument ) { a000a5b0: e1a06002 mov r6, r2 register Thread_Control *the_thread; Objects_Locations location; if ( entry_point == NULL ) return RTEMS_INVALID_ADDRESS; a000a5b4: 03a00009 moveq r0, #9 ) { register Thread_Control *the_thread; Objects_Locations location; if ( entry_point == NULL ) a000a5b8: 0a000011 beq a000a604 return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get( id, &location ); a000a5bc: e28d1004 add r1, sp, #4 a000a5c0: eb00088e bl a000c800 <_Thread_Get> switch ( location ) { a000a5c4: e59d4004 ldr r4, [sp, #4] a000a5c8: e3540000 cmp r4, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000a5cc: 13a00004 movne r0, #4 if ( entry_point == NULL ) return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get( id, &location ); switch ( location ) { a000a5d0: 1a00000b bne a000a604 case OBJECTS_LOCAL: if ( _Thread_Start( a000a5d4: e1a01004 mov r1, r4 a000a5d8: e1a02005 mov r2, r5 a000a5dc: e1a03004 mov r3, r4 a000a5e0: e58d6000 str r6, [sp] a000a5e4: eb000ad6 bl a000d144 <_Thread_Start> a000a5e8: e3500000 cmp r0, #0 a000a5ec: 0a000002 beq a000a5fc the_thread, THREAD_START_NUMERIC, entry_point, NULL, argument ) ) { _Thread_Enable_dispatch(); a000a5f0: eb00087a bl a000c7e0 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000a5f4: e1a00004 mov r0, r4 a000a5f8: ea000001 b a000a604 } _Thread_Enable_dispatch(); a000a5fc: eb000877 bl a000c7e0 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_INCORRECT_STATE; a000a600: e3a0000e mov r0, #14 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a000a604: e8bd807c pop {r2, r3, r4, r5, r6, pc} =============================================================================== a000d6cc : #include rtems_status_code rtems_task_suspend( rtems_id id ) { a000d6cc: e92d4011 push {r0, r4, lr} register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); a000d6d0: e1a0100d mov r1, sp a000d6d4: eb000843 bl a000f7e8 <_Thread_Get> switch ( location ) { a000d6d8: e59d2000 ldr r2, [sp] ) { register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); a000d6dc: e1a03000 mov r3, r0 switch ( location ) { a000d6e0: e3520000 cmp r2, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000d6e4: 13a00004 movne r0, #4 { register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { a000d6e8: 1a000009 bne a000d714 */ RTEMS_INLINE_ROUTINE bool _States_Is_suspended ( States_Control the_states ) { return (the_states & STATES_SUSPENDED); a000d6ec: e5934010 ldr r4, [r3, #16] case OBJECTS_LOCAL: if ( !_States_Is_suspended( the_thread->current_state ) ) { a000d6f0: e2144002 ands r4, r4, #2 a000d6f4: 1a000004 bne a000d70c _Thread_Suspend( the_thread ); a000d6f8: e3a01002 mov r1, #2 a000d6fc: eb000a42 bl a001000c <_Thread_Set_state> _Thread_Enable_dispatch(); a000d700: eb000830 bl a000f7c8 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000d704: e1a00004 mov r0, r4 a000d708: ea000001 b a000d714 } _Thread_Enable_dispatch(); a000d70c: eb00082d bl a000f7c8 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_ALREADY_SUSPENDED; a000d710: e3a0000f mov r0, #15 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a000d714: e8bd8018 pop {r3, r4, pc} =============================================================================== a0008e08 : rtems_status_code rtems_task_variable_add( rtems_id tid, void **ptr, void (*dtor)(void *) ) { a0008e08: e92d40f1 push {r0, r4, r5, r6, r7, lr} Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp, *new; if ( !ptr ) a0008e0c: e2514000 subs r4, r1, #0 rtems_status_code rtems_task_variable_add( rtems_id tid, void **ptr, void (*dtor)(void *) ) { a0008e10: e1a05002 mov r5, r2 Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp, *new; if ( !ptr ) return RTEMS_INVALID_ADDRESS; a0008e14: 03a00009 moveq r0, #9 { Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp, *new; if ( !ptr ) a0008e18: 0a000023 beq a0008eac return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get (tid, &location); a0008e1c: e1a0100d mov r1, sp a0008e20: eb0007b9 bl a000ad0c <_Thread_Get> switch (location) { a0008e24: e59d3000 ldr r3, [sp] rtems_task_variable_t *tvp, *new; if ( !ptr ) return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get (tid, &location); a0008e28: e1a07000 mov r7, r0 switch (location) { a0008e2c: e3530000 cmp r3, #0 case OBJECTS_LOCAL: /* * Figure out if the variable is already in this task's list. */ tvp = the_thread->task_variables; a0008e30: 059060fc ldreq r6, [r0, #252] ; 0xfc if ( !ptr ) return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get (tid, &location); switch (location) { a0008e34: 0a000008 beq a0008e5c a0008e38: ea00001a b a0008ea8 <== NOT EXECUTED /* * Figure out if the variable is already in this task's list. */ tvp = the_thread->task_variables; while (tvp) { if (tvp->ptr == ptr) { a0008e3c: e5963004 ldr r3, [r6, #4] <== NOT EXECUTED a0008e40: e1530004 cmp r3, r4 <== NOT EXECUTED a0008e44: 1a000003 bne a0008e58 <== NOT EXECUTED tvp->dtor = dtor; a0008e48: e5865010 str r5, [r6, #16] <== NOT EXECUTED _Thread_Enable_dispatch(); a0008e4c: eb0007a6 bl a000acec <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_SUCCESSFUL; a0008e50: e3a00000 mov r0, #0 <== NOT EXECUTED a0008e54: ea000014 b a0008eac <== NOT EXECUTED } tvp = (rtems_task_variable_t *)tvp->next; a0008e58: 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) { a0008e5c: e3560000 cmp r6, #0 a0008e60: 1afffff5 bne a0008e3c } /* * Now allocate memory for this task variable. */ new = (rtems_task_variable_t *) a0008e64: e3a00014 mov r0, #20 a0008e68: eb000b50 bl a000bbb0 <_Workspace_Allocate> _Workspace_Allocate(sizeof(rtems_task_variable_t)); if (new == NULL) { a0008e6c: e3500000 cmp r0, #0 a0008e70: 1a000002 bne a0008e80 _Thread_Enable_dispatch(); a0008e74: eb00079c bl a000acec <_Thread_Enable_dispatch> return RTEMS_NO_MEMORY; a0008e78: e3a0001a mov r0, #26 a0008e7c: ea00000a b a0008eac } new->gval = *ptr; a0008e80: e5943000 ldr r3, [r4] new->ptr = ptr; a0008e84: e5804004 str r4, [r0, #4] new->dtor = dtor; a0008e88: 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; a0008e8c: e5803008 str r3, [r0, #8] new->ptr = ptr; new->dtor = dtor; new->next = (struct rtems_task_variable_tt *)the_thread->task_variables; a0008e90: e59730fc ldr r3, [r7, #252] ; 0xfc a0008e94: e5803000 str r3, [r0] the_thread->task_variables = new; a0008e98: e58700fc str r0, [r7, #252] ; 0xfc _Thread_Enable_dispatch(); a0008e9c: eb000792 bl a000acec <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0008ea0: e1a00006 mov r0, r6 a0008ea4: ea000000 b a0008eac #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0008ea8: e3a00004 mov r0, #4 <== NOT EXECUTED } a0008eac: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} =============================================================================== a0008eb0 : rtems_status_code rtems_task_variable_delete( rtems_id tid, void **ptr ) { a0008eb0: e92d4011 push {r0, r4, lr} Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp, *prev; if ( !ptr ) a0008eb4: e2514000 subs r4, r1, #0 a0008eb8: 0a000016 beq a0008f18 return RTEMS_INVALID_ADDRESS; prev = NULL; the_thread = _Thread_Get (tid, &location); a0008ebc: e1a0100d mov r1, sp a0008ec0: eb000791 bl a000ad0c <_Thread_Get> switch (location) { a0008ec4: e59d3000 ldr r3, [sp] a0008ec8: e3530000 cmp r3, #0 case OBJECTS_LOCAL: tvp = the_thread->task_variables; a0008ecc: 059010fc ldreq r1, [r0, #252] ; 0xfc return RTEMS_INVALID_ADDRESS; prev = NULL; the_thread = _Thread_Get (tid, &location); switch (location) { a0008ed0: 0a00000d beq a0008f0c a0008ed4: ea000011 b a0008f20 <== NOT EXECUTED case OBJECTS_LOCAL: tvp = the_thread->task_variables; while (tvp) { if (tvp->ptr == ptr) { a0008ed8: e5912004 ldr r2, [r1, #4] a0008edc: e1520004 cmp r2, r4 a0008ee0: 1a000007 bne a0008f04 a0008ee4: e5912000 ldr r2, [r1] if (prev) a0008ee8: e3530000 cmp r3, #0 prev->next = tvp->next; else the_thread->task_variables = (rtems_task_variable_t *)tvp->next; a0008eec: 058020fc streq r2, [r0, #252] ; 0xfc case OBJECTS_LOCAL: tvp = the_thread->task_variables; while (tvp) { if (tvp->ptr == ptr) { if (prev) prev->next = tvp->next; a0008ef0: 15832000 strne r2, [r3] else the_thread->task_variables = (rtems_task_variable_t *)tvp->next; _RTEMS_Tasks_Invoke_task_variable_dtor( the_thread, tvp ); a0008ef4: eb000028 bl a0008f9c <_RTEMS_Tasks_Invoke_task_variable_dtor> _Thread_Enable_dispatch(); a0008ef8: eb00077b bl a000acec <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0008efc: e3a00000 mov r0, #0 a0008f00: ea000007 b a0008f24 } prev = tvp; tvp = (rtems_task_variable_t *)tvp->next; a0008f04: e1a03001 mov r3, r1 <== NOT EXECUTED a0008f08: e5911000 ldr r1, [r1] <== NOT EXECUTED the_thread = _Thread_Get (tid, &location); switch (location) { case OBJECTS_LOCAL: tvp = the_thread->task_variables; while (tvp) { a0008f0c: e3510000 cmp r1, #0 a0008f10: 1afffff0 bne a0008ed8 return RTEMS_SUCCESSFUL; } prev = tvp; tvp = (rtems_task_variable_t *)tvp->next; } _Thread_Enable_dispatch(); a0008f14: eb000774 bl a000acec <_Thread_Enable_dispatch> <== NOT EXECUTED Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp, *prev; if ( !ptr ) return RTEMS_INVALID_ADDRESS; a0008f18: e3a00009 mov r0, #9 <== NOT EXECUTED a0008f1c: ea000000 b a0008f24 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0008f20: e3a00004 mov r0, #4 <== NOT EXECUTED } a0008f24: e8bd8018 pop {r3, r4, pc} =============================================================================== a0008f28 : rtems_status_code rtems_task_variable_get( rtems_id tid, void **ptr, void **result ) { a0008f28: e92d4031 push {r0, r4, r5, lr} Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp; if ( !ptr ) a0008f2c: e2515000 subs r5, r1, #0 rtems_status_code rtems_task_variable_get( rtems_id tid, void **ptr, void **result ) { a0008f30: e1a04002 mov r4, r2 Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp; if ( !ptr ) a0008f34: 0a000014 beq a0008f8c return RTEMS_INVALID_ADDRESS; if ( !result ) a0008f38: e3520000 cmp r2, #0 a0008f3c: 0a000012 beq a0008f8c return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get (tid, &location); a0008f40: e1a0100d mov r1, sp a0008f44: eb000770 bl a000ad0c <_Thread_Get> switch (location) { a0008f48: e59d3000 ldr r3, [sp] a0008f4c: e3530000 cmp r3, #0 case OBJECTS_LOCAL: /* * Figure out if the variable is in this task's list. */ tvp = the_thread->task_variables; a0008f50: 059030fc ldreq r3, [r0, #252] ; 0xfc if ( !result ) return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get (tid, &location); switch (location) { a0008f54: 0a000009 beq a0008f80 a0008f58: ea00000d b a0008f94 /* * Figure out if the variable is in this task's list. */ tvp = the_thread->task_variables; while (tvp) { if (tvp->ptr == ptr) { a0008f5c: e5932004 ldr r2, [r3, #4] <== NOT EXECUTED a0008f60: e1520005 cmp r2, r5 <== NOT EXECUTED a0008f64: 1a000004 bne a0008f7c <== NOT EXECUTED /* * Should this return the current (i.e not the * saved) value if `tid' is the current task? */ *result = tvp->tval; a0008f68: e593300c ldr r3, [r3, #12] <== NOT EXECUTED a0008f6c: e5843000 str r3, [r4] <== NOT EXECUTED _Thread_Enable_dispatch(); a0008f70: eb00075d bl a000acec <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_SUCCESSFUL; a0008f74: e3a00000 mov r0, #0 <== NOT EXECUTED a0008f78: ea000006 b a0008f98 <== NOT EXECUTED } tvp = (rtems_task_variable_t *)tvp->next; a0008f7c: 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) { a0008f80: e3530000 cmp r3, #0 a0008f84: 1afffff4 bne a0008f5c _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } tvp = (rtems_task_variable_t *)tvp->next; } _Thread_Enable_dispatch(); a0008f88: eb000757 bl a000acec <_Thread_Enable_dispatch> if ( !ptr ) return RTEMS_INVALID_ADDRESS; if ( !result ) return RTEMS_INVALID_ADDRESS; a0008f8c: e3a00009 mov r0, #9 a0008f90: ea000000 b a0008f98 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0008f94: e3a00004 mov r0, #4 } a0008f98: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000b4ec : #include rtems_status_code rtems_task_wake_when( rtems_time_of_day *time_buffer ) { a000b4ec: e92d40f0 push {r4, r5, r6, r7, lr} Watchdog_Interval seconds; if ( !_TOD.is_set ) a000b4f0: e59f60d8 ldr r6, [pc, #216] ; a000b5d0 #include rtems_status_code rtems_task_wake_when( rtems_time_of_day *time_buffer ) { a000b4f4: e1a04000 mov r4, r0 Watchdog_Interval seconds; if ( !_TOD.is_set ) a000b4f8: e5d63014 ldrb r3, [r6, #20] a000b4fc: e3530000 cmp r3, #0 a000b500: 0a00002a beq a000b5b0 return RTEMS_NOT_DEFINED; if ( !time_buffer ) a000b504: e3500000 cmp r0, #0 a000b508: 0a00002a beq a000b5b8 return RTEMS_INVALID_ADDRESS; time_buffer->ticks = 0; a000b50c: e3a05000 mov r5, #0 a000b510: e5805018 str r5, [r0, #24] if ( !_TOD_Validate( time_buffer ) ) a000b514: ebfffcfa bl a000a904 <_TOD_Validate> a000b518: e1500005 cmp r0, r5 a000b51c: 0a000027 beq a000b5c0 return RTEMS_INVALID_CLOCK; seconds = _TOD_To_seconds( time_buffer ); a000b520: e1a00004 mov r0, r4 a000b524: ebfffcce bl a000a864 <_TOD_To_seconds> static inline uint32_t _Timestamp64_implementation_Get_seconds( const Timestamp64_Control *_time ) { return (uint32_t) (*_time / 1000000000L); a000b528: e59f20a4 ldr r2, [pc, #164] ; a000b5d4 a000b52c: e1a07000 mov r7, r0 a000b530: e3a03000 mov r3, #0 a000b534: e8960003 ldm r6, {r0, r1} a000b538: eb00456d bl a001caf4 <__divdi3> if ( seconds <= _TOD_Seconds_since_epoch() ) a000b53c: e1570000 cmp r7, r0 a000b540: 9a000020 bls a000b5c8 * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000b544: e59f308c ldr r3, [pc, #140] ; a000b5d8 a000b548: e5932000 ldr r2, [r3] ++level; a000b54c: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000b550: e5832000 str r2, [r3] return RTEMS_INVALID_CLOCK; _Thread_Disable_dispatch(); _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_TIME ); a000b554: e59f4080 ldr r4, [pc, #128] ; a000b5dc a000b558: e3a01010 mov r1, #16 a000b55c: e5940008 ldr r0, [r4, #8] a000b560: eb000aaf bl a000e024 <_Thread_Set_state> a000b564: e8960003 ldm r6, {r0, r1} _Watchdog_Initialize( &_Thread_Executing->Timer, a000b568: e5944008 ldr r4, [r4, #8] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a000b56c: e59f206c ldr r2, [pc, #108] ; a000b5e0 if ( seconds <= _TOD_Seconds_since_epoch() ) return RTEMS_INVALID_CLOCK; _Thread_Disable_dispatch(); _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_TIME ); _Watchdog_Initialize( a000b570: e5943008 ldr r3, [r4, #8] a000b574: e5842064 str r2, [r4, #100] ; 0x64 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a000b578: e5845050 str r5, [r4, #80] ; 0x50 a000b57c: e59f2050 ldr r2, [pc, #80] ; a000b5d4 the_watchdog->routine = routine; the_watchdog->id = id; a000b580: e5843068 str r3, [r4, #104] ; 0x68 the_watchdog->user_data = user_data; a000b584: e584506c str r5, [r4, #108] ; 0x6c a000b588: e3a03000 mov r3, #0 a000b58c: eb004558 bl a001caf4 <__divdi3> &_Thread_Executing->Timer, _Thread_Delay_ended, _Thread_Executing->Object.id, NULL ); _Watchdog_Insert_seconds( a000b590: e0600007 rsb r0, r0, r7 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a000b594: e5840054 str r0, [r4, #84] ; 0x54 _Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog ); a000b598: e2841048 add r1, r4, #72 ; 0x48 a000b59c: e59f0040 ldr r0, [pc, #64] ; a000b5e4 a000b5a0: eb000b9a bl a000e410 <_Watchdog_Insert> &_Thread_Executing->Timer, seconds - _TOD_Seconds_since_epoch() ); _Thread_Enable_dispatch(); a000b5a4: eb00088d bl a000d7e0 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000b5a8: e1a00005 mov r0, r5 <== NOT EXECUTED a000b5ac: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED ) { Watchdog_Interval seconds; if ( !_TOD.is_set ) return RTEMS_NOT_DEFINED; a000b5b0: e3a0000b mov r0, #11 <== NOT EXECUTED a000b5b4: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED if ( !time_buffer ) return RTEMS_INVALID_ADDRESS; a000b5b8: e3a00009 mov r0, #9 <== NOT EXECUTED a000b5bc: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED time_buffer->ticks = 0; if ( !_TOD_Validate( time_buffer ) ) return RTEMS_INVALID_CLOCK; a000b5c0: e3a00014 mov r0, #20 <== NOT EXECUTED a000b5c4: 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; a000b5c8: e3a00014 mov r0, #20 <== NOT EXECUTED &_Thread_Executing->Timer, seconds - _TOD_Seconds_since_epoch() ); _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } a000b5cc: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED =============================================================================== a000a62c : rtems_status_code rtems_timer_create( rtems_name name, rtems_id *id ) { a000a62c: e92d40f0 push {r4, r5, r6, r7, lr} Timer_Control *the_timer; if ( !rtems_is_name_valid( name ) ) a000a630: e2506000 subs r6, r0, #0 rtems_status_code rtems_timer_create( rtems_name name, rtems_id *id ) { a000a634: e1a04001 mov r4, r1 Timer_Control *the_timer; if ( !rtems_is_name_valid( name ) ) a000a638: 0a00001d beq a000a6b4 return RTEMS_INVALID_NAME; if ( !id ) a000a63c: e3510000 cmp r1, #0 a000a640: 0a00001d beq a000a6bc * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000a644: e59f3078 ldr r3, [pc, #120] ; a000a6c4 a000a648: e5932000 ldr r2, [r3] ++level; a000a64c: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000a650: 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 ); a000a654: e59f506c ldr r5, [pc, #108] ; a000a6c8 a000a658: e1a00005 mov r0, r5 a000a65c: eb0003df bl a000b5e0 <_Objects_Allocate> _Thread_Disable_dispatch(); /* to prevent deletion */ the_timer = _Timer_Allocate(); if ( !the_timer ) { a000a660: e3500000 cmp r0, #0 a000a664: 1a000002 bne a000a674 _Thread_Enable_dispatch(); a000a668: eb000872 bl a000c838 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_TOO_MANY; a000a66c: e3a00005 mov r0, #5 <== NOT EXECUTED a000a670: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED } the_timer->the_class = TIMER_DORMANT; a000a674: e3a03004 mov r3, #4 a000a678: e5803038 str r3, [r0, #56] ; 0x38 Objects_Information *information, Objects_Control *the_object, Objects_Name name ) { _Objects_Set_local_object( a000a67c: e1d010b8 ldrh r1, [r0, #8] a000a680: e5903008 ldr r3, [r0, #8] #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object; a000a684: e595201c ldr r2, [r5, #28] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a000a688: e3a07000 mov r7, #0 a000a68c: e5807018 str r7, [r0, #24] the_watchdog->routine = routine; a000a690: e580702c str r7, [r0, #44] ; 0x2c the_watchdog->id = id; a000a694: e5807030 str r7, [r0, #48] ; 0x30 the_watchdog->user_data = user_data; a000a698: e5807034 str r7, [r0, #52] ; 0x34 a000a69c: e7820101 str r0, [r2, r1, lsl #2] information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name; a000a6a0: e580600c str r6, [r0, #12] &_Timer_Information, &the_timer->Object, (Objects_Name) name ); *id = the_timer->Object.id; a000a6a4: e5843000 str r3, [r4] _Thread_Enable_dispatch(); a000a6a8: eb000862 bl a000c838 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000a6ac: e1a00007 mov r0, r7 a000a6b0: e8bd80f0 pop {r4, r5, r6, r7, pc} ) { Timer_Control *the_timer; if ( !rtems_is_name_valid( name ) ) return RTEMS_INVALID_NAME; a000a6b4: e3a00003 mov r0, #3 <== NOT EXECUTED a000a6b8: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED if ( !id ) return RTEMS_INVALID_ADDRESS; a000a6bc: e3a00009 mov r0, #9 <== NOT EXECUTED ); *id = the_timer->Object.id; _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } a000a6c0: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED =============================================================================== a000a6cc : rtems_id id, rtems_interval ticks, rtems_timer_service_routine_entry routine, void *user_data ) { a000a6cc: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr} Timer_Control *the_timer; Objects_Locations location; ISR_Level level; if ( ticks == 0 ) a000a6d0: e2516000 subs r6, r1, #0 rtems_id id, rtems_interval ticks, rtems_timer_service_routine_entry routine, void *user_data ) { a000a6d4: e1a04000 mov r4, r0 a000a6d8: e1a05002 mov r5, r2 a000a6dc: e1a07003 mov r7, r3 Timer_Control *the_timer; Objects_Locations location; ISR_Level level; if ( ticks == 0 ) return RTEMS_INVALID_NUMBER; a000a6e0: 03a0000a moveq r0, #10 { Timer_Control *the_timer; Objects_Locations location; ISR_Level level; if ( ticks == 0 ) a000a6e4: 0a000022 beq a000a774 return RTEMS_INVALID_NUMBER; if ( !routine ) a000a6e8: e3520000 cmp r2, #0 return RTEMS_INVALID_ADDRESS; a000a6ec: 03a00009 moveq r0, #9 ISR_Level level; if ( ticks == 0 ) return RTEMS_INVALID_NUMBER; if ( !routine ) a000a6f0: 0a00001f beq a000a774 RTEMS_INLINE_ROUTINE Timer_Control *_Timer_Get ( Objects_Id id, Objects_Locations *location ) { return (Timer_Control *) a000a6f4: e59f007c ldr r0, [pc, #124] ; a000a778 a000a6f8: e1a01004 mov r1, r4 a000a6fc: e1a0200d mov r2, sp a000a700: eb0004dd bl a000ba7c <_Objects_Get> return RTEMS_INVALID_ADDRESS; the_timer = _Timer_Get( id, &location ); switch ( location ) { a000a704: e59d3000 ldr r3, [sp] a000a708: e1a08000 mov r8, r0 a000a70c: e3530000 cmp r3, #0 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a000a710: 13a00004 movne r0, #4 if ( !routine ) return RTEMS_INVALID_ADDRESS; the_timer = _Timer_Get( id, &location ); switch ( location ) { a000a714: 1a000016 bne a000a774 case OBJECTS_LOCAL: (void) _Watchdog_Remove( &the_timer->Ticker ); a000a718: e288a010 add sl, r8, #16 a000a71c: e1a0000a mov r0, sl a000a720: eb000b7f bl a000d524 <_Watchdog_Remove> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000a724: e10f2000 mrs r2, CPSR a000a728: e3823080 orr r3, r2, #128 ; 0x80 a000a72c: 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 ) { a000a730: e5983018 ldr r3, [r8, #24] a000a734: e3530000 cmp r3, #0 a000a738: 0a000001 beq a000a744 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000a73c: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED a000a740: ea000009 b a000a76c <== 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; a000a744: e5883038 str r3, [r8, #56] ; 0x38 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a000a748: e5883018 str r3, [r8, #24] the_watchdog->routine = routine; a000a74c: e588502c str r5, [r8, #44] ; 0x2c the_watchdog->id = id; a000a750: e5884030 str r4, [r8, #48] ; 0x30 the_watchdog->user_data = user_data; a000a754: e5887034 str r7, [r8, #52] ; 0x34 a000a758: e129f002 msr CPSR_fc, r2 ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a000a75c: e59f0018 ldr r0, [pc, #24] ; a000a77c Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a000a760: e588601c str r6, [r8, #28] _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a000a764: e1a0100a mov r1, sl a000a768: eb000b16 bl a000d3c8 <_Watchdog_Insert> _Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data ); _ISR_Enable( level ); _Watchdog_Insert_ticks( &the_timer->Ticker, ticks ); _Thread_Enable_dispatch(); a000a76c: eb000831 bl a000c838 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a000a770: e3a00000 mov r0, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a000a774: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc} =============================================================================== a0018c74 : rtems_id id, rtems_time_of_day *wall_time, rtems_timer_service_routine_entry routine, void *user_data ) { a0018c74: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} Timer_Control *the_timer; Objects_Locations location; rtems_interval seconds; if ( !_TOD.is_set ) a0018c78: e59f60dc ldr r6, [pc, #220] ; a0018d5c rtems_id id, rtems_time_of_day *wall_time, rtems_timer_service_routine_entry routine, void *user_data ) { a0018c7c: e1a0b003 mov fp, r3 a0018c80: e1a0a000 mov sl, r0 Timer_Control *the_timer; Objects_Locations location; rtems_interval seconds; if ( !_TOD.is_set ) a0018c84: e5d63014 ldrb r3, [r6, #20] rtems_id id, rtems_time_of_day *wall_time, rtems_timer_service_routine_entry routine, void *user_data ) { a0018c88: e1a04001 mov r4, r1 a0018c8c: e1a08002 mov r8, r2 Timer_Control *the_timer; Objects_Locations location; rtems_interval seconds; if ( !_TOD.is_set ) a0018c90: e3530000 cmp r3, #0 return RTEMS_NOT_DEFINED; a0018c94: 03a0000b moveq r0, #11 { Timer_Control *the_timer; Objects_Locations location; rtems_interval seconds; if ( !_TOD.is_set ) a0018c98: 0a00002e beq a0018d58 return RTEMS_NOT_DEFINED; if ( !_TOD_Validate( wall_time ) ) a0018c9c: e1a00001 mov r0, r1 a0018ca0: ebfff4c6 bl a0015fc0 <_TOD_Validate> a0018ca4: e3500000 cmp r0, #0 a0018ca8: 0a000029 beq a0018d54 return RTEMS_INVALID_CLOCK; if ( !routine ) a0018cac: e3580000 cmp r8, #0 return RTEMS_INVALID_ADDRESS; a0018cb0: 03a00009 moveq r0, #9 return RTEMS_NOT_DEFINED; if ( !_TOD_Validate( wall_time ) ) return RTEMS_INVALID_CLOCK; if ( !routine ) a0018cb4: 0a000027 beq a0018d58 return RTEMS_INVALID_ADDRESS; seconds = _TOD_To_seconds( wall_time ); a0018cb8: e1a00004 mov r0, r4 a0018cbc: ebfff497 bl a0015f20 <_TOD_To_seconds> a0018cc0: e59f2098 ldr r2, [pc, #152] ; a0018d60 a0018cc4: e1a07000 mov r7, r0 a0018cc8: e3a03000 mov r3, #0 a0018ccc: e8960003 ldm r6, {r0, r1} a0018cd0: eb005043 bl a002cde4 <__divdi3> if ( seconds <= _TOD_Seconds_since_epoch() ) a0018cd4: e1570000 cmp r7, r0 a0018cd8: 9a00001d bls a0018d54 a0018cdc: e59f0080 ldr r0, [pc, #128] ; a0018d64 a0018ce0: e1a0100a mov r1, sl a0018ce4: e1a0200d mov r2, sp a0018ce8: eb000b52 bl a001ba38 <_Objects_Get> return RTEMS_INVALID_CLOCK; the_timer = _Timer_Get( id, &location ); switch ( location ) { a0018cec: e59d5000 ldr r5, [sp] a0018cf0: e1a04000 mov r4, r0 a0018cf4: e3550000 cmp r5, #0 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0018cf8: 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 ) { a0018cfc: 1a000015 bne a0018d58 case OBJECTS_LOCAL: (void) _Watchdog_Remove( &the_timer->Ticker ); a0018d00: e2849010 add r9, r4, #16 a0018d04: e1a00009 mov r0, r9 a0018d08: eb001284 bl a001d720 <_Watchdog_Remove> a0018d0c: e8960003 ldm r6, {r0, r1} the_timer->the_class = TIMER_TIME_OF_DAY; a0018d10: e3a03002 mov r3, #2 a0018d14: e59f2044 ldr r2, [pc, #68] ; a0018d60 a0018d18: e5843038 str r3, [r4, #56] ; 0x38 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a0018d1c: e5845018 str r5, [r4, #24] a0018d20: e3a03000 mov r3, #0 the_watchdog->routine = routine; a0018d24: e584802c str r8, [r4, #44] ; 0x2c the_watchdog->id = id; a0018d28: e584a030 str sl, [r4, #48] ; 0x30 the_watchdog->user_data = user_data; a0018d2c: e584b034 str fp, [r4, #52] ; 0x34 a0018d30: eb00502b bl a002cde4 <__divdi3> _Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data ); _Watchdog_Insert_seconds( a0018d34: e0600007 rsb r0, r0, r7 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a0018d38: e584001c str r0, [r4, #28] _Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog ); a0018d3c: e1a01009 mov r1, r9 a0018d40: e59f0020 ldr r0, [pc, #32] ; a0018d68 a0018d44: eb00121e bl a001d5c4 <_Watchdog_Insert> &the_timer->Ticker, seconds - _TOD_Seconds_since_epoch() ); _Thread_Enable_dispatch(); a0018d48: eb000ecd bl a001c884 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0018d4c: e1a00005 mov r0, r5 a0018d50: ea000000 b a0018d58 if ( !routine ) return RTEMS_INVALID_ADDRESS; seconds = _TOD_To_seconds( wall_time ); if ( seconds <= _TOD_Seconds_since_epoch() ) return RTEMS_INVALID_CLOCK; a0018d54: e3a00014 mov r0, #20 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0018d58: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} =============================================================================== a0018d6c : rtems_status_code rtems_timer_get_information( rtems_id id, rtems_timer_information *the_info ) { a0018d6c: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED Timer_Control *the_timer; Objects_Locations location; if ( !the_info ) a0018d70: e2514000 subs r4, r1, #0 <== NOT EXECUTED rtems_status_code rtems_timer_get_information( rtems_id id, rtems_timer_information *the_info ) { a0018d74: e1a03000 mov r3, r0 <== NOT EXECUTED Timer_Control *the_timer; Objects_Locations location; if ( !the_info ) return RTEMS_INVALID_ADDRESS; a0018d78: 03a00009 moveq r0, #9 <== NOT EXECUTED ) { Timer_Control *the_timer; Objects_Locations location; if ( !the_info ) a0018d7c: 0a000011 beq a0018dc8 <== NOT EXECUTED a0018d80: e59f0044 ldr r0, [pc, #68] ; a0018dcc <== NOT EXECUTED a0018d84: e1a01003 mov r1, r3 <== NOT EXECUTED a0018d88: e1a0200d mov r2, sp <== NOT EXECUTED a0018d8c: eb000b29 bl a001ba38 <_Objects_Get> <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; the_timer = _Timer_Get( id, &location ); switch ( location ) { a0018d90: e59d5000 ldr r5, [sp] <== NOT EXECUTED a0018d94: e3550000 cmp r5, #0 <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0018d98: 13a00004 movne r0, #4 <== NOT EXECUTED if ( !the_info ) return RTEMS_INVALID_ADDRESS; the_timer = _Timer_Get( id, &location ); switch ( location ) { a0018d9c: 1a000009 bne a0018dc8 <== NOT EXECUTED case OBJECTS_LOCAL: the_info->the_class = the_timer->the_class; a0018da0: e5903038 ldr r3, [r0, #56] ; 0x38 <== NOT EXECUTED a0018da4: e5843000 str r3, [r4] <== NOT EXECUTED the_info->initial = the_timer->Ticker.initial; a0018da8: e590301c ldr r3, [r0, #28] <== NOT EXECUTED a0018dac: e5843004 str r3, [r4, #4] <== NOT EXECUTED the_info->start_time = the_timer->Ticker.start_time; a0018db0: e5903024 ldr r3, [r0, #36] ; 0x24 <== NOT EXECUTED a0018db4: e5843008 str r3, [r4, #8] <== NOT EXECUTED the_info->stop_time = the_timer->Ticker.stop_time; a0018db8: e5903028 ldr r3, [r0, #40] ; 0x28 <== NOT EXECUTED a0018dbc: e584300c str r3, [r4, #12] <== NOT EXECUTED _Thread_Enable_dispatch(); a0018dc0: eb000eaf bl a001c884 <_Thread_Enable_dispatch> <== NOT EXECUTED return RTEMS_SUCCESSFUL; a0018dc4: e1a00005 mov r0, r5 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0018dc8: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED =============================================================================== a0018e00 : */ rtems_status_code rtems_timer_reset( rtems_id id ) { a0018e00: e92d4071 push {r0, r4, r5, r6, lr} a0018e04: e1a01000 mov r1, r0 a0018e08: e1a0200d mov r2, sp a0018e0c: e59f0078 ldr r0, [pc, #120] ; a0018e8c a0018e10: eb000b08 bl a001ba38 <_Objects_Get> Timer_Control *the_timer; Objects_Locations location; rtems_status_code status = RTEMS_SUCCESSFUL; the_timer = _Timer_Get( id, &location ); switch ( location ) { a0018e14: e59d5000 ldr r5, [sp] a0018e18: e1a06000 mov r6, r0 a0018e1c: e3550000 cmp r5, #0 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0018e20: 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 ) { a0018e24: 1a000016 bne a0018e84 case OBJECTS_LOCAL: if ( the_timer->the_class == TIMER_INTERVAL ) { a0018e28: e5904038 ldr r4, [r0, #56] ; 0x38 a0018e2c: e3540000 cmp r4, #0 a0018e30: 1a000006 bne a0018e50 _Watchdog_Remove( &the_timer->Ticker ); a0018e34: e2806010 add r6, r0, #16 a0018e38: e1a00006 mov r0, r6 a0018e3c: eb001237 bl a001d720 <_Watchdog_Remove> _Watchdog_Insert( &_Watchdog_Ticks_chain, &the_timer->Ticker ); a0018e40: e59f0048 ldr r0, [pc, #72] ; a0018e90 a0018e44: e1a01006 mov r1, r6 a0018e48: eb0011dd bl a001d5c4 <_Watchdog_Insert> a0018e4c: ea00000b b a0018e80 } else if ( the_timer->the_class == TIMER_INTERVAL_ON_TASK ) { a0018e50: 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; a0018e54: 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 ) { a0018e58: 1a000008 bne a0018e80 <== NOT EXECUTED Timer_server_Control *timer_server = _Timer_server; a0018e5c: e59f3030 ldr r3, [pc, #48] ; a0018e94 <== NOT EXECUTED if ( !timer_server ) { _Thread_Enable_dispatch(); return RTEMS_INCORRECT_STATE; } #endif _Watchdog_Remove( &the_timer->Ticker ); a0018e60: 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; a0018e64: e5934000 ldr r4, [r3] <== NOT EXECUTED if ( !timer_server ) { _Thread_Enable_dispatch(); return RTEMS_INCORRECT_STATE; } #endif _Watchdog_Remove( &the_timer->Ticker ); a0018e68: eb00122c bl a001d720 <_Watchdog_Remove> <== NOT EXECUTED (*timer_server->schedule_operation)( timer_server, the_timer ); a0018e6c: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED a0018e70: e1a00004 mov r0, r4 <== NOT EXECUTED a0018e74: e1a01006 mov r1, r6 <== NOT EXECUTED a0018e78: e12fff33 blx r3 <== NOT EXECUTED rtems_id id ) { Timer_Control *the_timer; Objects_Locations location; rtems_status_code status = RTEMS_SUCCESSFUL; a0018e7c: 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(); a0018e80: eb000e7f bl a001c884 <_Thread_Enable_dispatch> case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0018e84: e1a00004 mov r0, r4 a0018e88: e8bd8078 pop {r3, r4, r5, r6, pc} =============================================================================== a0018e98 : rtems_id id, rtems_interval ticks, rtems_timer_service_routine_entry routine, void *user_data ) { a0018e98: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr} a0018e9c: e1a08003 mov r8, r3 Timer_Control *the_timer; Objects_Locations location; ISR_Level level; Timer_server_Control *timer_server = _Timer_server; a0018ea0: e59f30b8 ldr r3, [pc, #184] ; a0018f60 rtems_id id, rtems_interval ticks, rtems_timer_service_routine_entry routine, void *user_data ) { a0018ea4: e1a05000 mov r5, r0 a0018ea8: e1a04001 mov r4, r1 Timer_Control *the_timer; Objects_Locations location; ISR_Level level; Timer_server_Control *timer_server = _Timer_server; a0018eac: e5937000 ldr r7, [r3] rtems_id id, rtems_interval ticks, rtems_timer_service_routine_entry routine, void *user_data ) { a0018eb0: e1a06002 mov r6, r2 Timer_Control *the_timer; Objects_Locations location; ISR_Level level; Timer_server_Control *timer_server = _Timer_server; if ( !timer_server ) a0018eb4: e3570000 cmp r7, #0 return RTEMS_INCORRECT_STATE; a0018eb8: 03a0000e moveq r0, #14 Timer_Control *the_timer; Objects_Locations location; ISR_Level level; Timer_server_Control *timer_server = _Timer_server; if ( !timer_server ) a0018ebc: 0a000026 beq a0018f5c return RTEMS_INCORRECT_STATE; if ( !routine ) a0018ec0: e3520000 cmp r2, #0 return RTEMS_INVALID_ADDRESS; a0018ec4: 03a00009 moveq r0, #9 Timer_server_Control *timer_server = _Timer_server; if ( !timer_server ) return RTEMS_INCORRECT_STATE; if ( !routine ) a0018ec8: 0a000023 beq a0018f5c return RTEMS_INVALID_ADDRESS; if ( ticks == 0 ) a0018ecc: e3510000 cmp r1, #0 return RTEMS_INVALID_NUMBER; a0018ed0: 03a0000a moveq r0, #10 return RTEMS_INCORRECT_STATE; if ( !routine ) return RTEMS_INVALID_ADDRESS; if ( ticks == 0 ) a0018ed4: 0a000020 beq a0018f5c a0018ed8: e59f0084 ldr r0, [pc, #132] ; a0018f64 a0018edc: e1a01005 mov r1, r5 a0018ee0: e1a0200d mov r2, sp a0018ee4: eb000ad3 bl a001ba38 <_Objects_Get> return RTEMS_INVALID_NUMBER; the_timer = _Timer_Get( id, &location ); switch ( location ) { a0018ee8: e59d3000 ldr r3, [sp] a0018eec: e1a0a000 mov sl, r0 a0018ef0: e3530000 cmp r3, #0 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0018ef4: 13a00004 movne r0, #4 if ( ticks == 0 ) return RTEMS_INVALID_NUMBER; the_timer = _Timer_Get( id, &location ); switch ( location ) { a0018ef8: 1a000017 bne a0018f5c case OBJECTS_LOCAL: (void) _Watchdog_Remove( &the_timer->Ticker ); a0018efc: e28a0010 add r0, sl, #16 a0018f00: eb001206 bl a001d720 <_Watchdog_Remove> uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a0018f04: e10f3000 mrs r3, CPSR a0018f08: e3832080 orr r2, r3, #128 ; 0x80 a0018f0c: 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 ) { a0018f10: e59a2018 ldr r2, [sl, #24] a0018f14: e3520000 cmp r2, #0 a0018f18: 0a000001 beq a0018f24 static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a0018f1c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED a0018f20: ea00000b b a0018f54 <== 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; a0018f24: e3a01001 mov r1, #1 a0018f28: e58a1038 str r1, [sl, #56] ; 0x38 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a0018f2c: e58a2018 str r2, [sl, #24] the_watchdog->routine = routine; a0018f30: e58a602c str r6, [sl, #44] ; 0x2c the_watchdog->id = id; a0018f34: e58a5030 str r5, [sl, #48] ; 0x30 the_watchdog->user_data = user_data; a0018f38: e58a8034 str r8, [sl, #52] ; 0x34 _Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data ); the_timer->Ticker.initial = ticks; a0018f3c: e58a401c str r4, [sl, #28] a0018f40: e129f003 msr CPSR_fc, r3 _ISR_Enable( level ); (*timer_server->schedule_operation)( timer_server, the_timer ); a0018f44: e5973004 ldr r3, [r7, #4] a0018f48: e1a00007 mov r0, r7 a0018f4c: e1a0100a mov r1, sl a0018f50: e12fff33 blx r3 _Thread_Enable_dispatch(); a0018f54: eb000e4a bl a001c884 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0018f58: e3a00000 mov r0, #0 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0018f5c: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc} =============================================================================== a0018f68 : rtems_id id, rtems_time_of_day *wall_time, rtems_timer_service_routine_entry routine, void *user_data ) { a0018f68: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} a0018f6c: e1a0b003 mov fp, r3 Timer_Control *the_timer; Objects_Locations location; rtems_interval seconds; Timer_server_Control *timer_server = _Timer_server; a0018f70: e59f30ec ldr r3, [pc, #236] ; a0019064 rtems_id id, rtems_time_of_day *wall_time, rtems_timer_service_routine_entry routine, void *user_data ) { a0018f74: e1a09000 mov r9, r0 a0018f78: e1a04001 mov r4, r1 Timer_Control *the_timer; Objects_Locations location; rtems_interval seconds; Timer_server_Control *timer_server = _Timer_server; a0018f7c: e5935000 ldr r5, [r3] rtems_id id, rtems_time_of_day *wall_time, rtems_timer_service_routine_entry routine, void *user_data ) { a0018f80: e1a0a002 mov sl, r2 Timer_Control *the_timer; Objects_Locations location; rtems_interval seconds; Timer_server_Control *timer_server = _Timer_server; if ( !timer_server ) a0018f84: e3550000 cmp r5, #0 return RTEMS_INCORRECT_STATE; a0018f88: 03a0000e moveq r0, #14 Timer_Control *the_timer; Objects_Locations location; rtems_interval seconds; Timer_server_Control *timer_server = _Timer_server; if ( !timer_server ) a0018f8c: 0a000033 beq a0019060 return RTEMS_INCORRECT_STATE; if ( !_TOD.is_set ) a0018f90: e59f60d0 ldr r6, [pc, #208] ; a0019068 a0018f94: e5d63014 ldrb r3, [r6, #20] a0018f98: e3530000 cmp r3, #0 return RTEMS_NOT_DEFINED; a0018f9c: 03a0000b moveq r0, #11 Timer_server_Control *timer_server = _Timer_server; if ( !timer_server ) return RTEMS_INCORRECT_STATE; if ( !_TOD.is_set ) a0018fa0: 0a00002e beq a0019060 return RTEMS_NOT_DEFINED; if ( !routine ) a0018fa4: e3520000 cmp r2, #0 return RTEMS_INVALID_ADDRESS; a0018fa8: 03a00009 moveq r0, #9 return RTEMS_INCORRECT_STATE; if ( !_TOD.is_set ) return RTEMS_NOT_DEFINED; if ( !routine ) a0018fac: 0a00002b beq a0019060 return RTEMS_INVALID_ADDRESS; if ( !_TOD_Validate( wall_time ) ) a0018fb0: e1a00001 mov r0, r1 a0018fb4: ebfff401 bl a0015fc0 <_TOD_Validate> a0018fb8: e3500000 cmp r0, #0 a0018fbc: 0a000026 beq a001905c return RTEMS_INVALID_CLOCK; seconds = _TOD_To_seconds( wall_time ); a0018fc0: e1a00004 mov r0, r4 a0018fc4: ebfff3d5 bl a0015f20 <_TOD_To_seconds> a0018fc8: e59f209c ldr r2, [pc, #156] ; a001906c a0018fcc: e1a07000 mov r7, r0 a0018fd0: e3a03000 mov r3, #0 a0018fd4: e8960003 ldm r6, {r0, r1} a0018fd8: eb004f81 bl a002cde4 <__divdi3> if ( seconds <= _TOD_Seconds_since_epoch() ) a0018fdc: e1570000 cmp r7, r0 a0018fe0: 9a00001d bls a001905c a0018fe4: e59f0084 ldr r0, [pc, #132] ; a0019070 a0018fe8: e1a01009 mov r1, r9 a0018fec: e1a0200d mov r2, sp a0018ff0: eb000a90 bl a001ba38 <_Objects_Get> return RTEMS_INVALID_CLOCK; the_timer = _Timer_Get( id, &location ); switch ( location ) { a0018ff4: e59d8000 ldr r8, [sp] a0018ff8: e1a04000 mov r4, r0 a0018ffc: e3580000 cmp r8, #0 #endif case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; a0019000: 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 ) { a0019004: 1a000015 bne a0019060 case OBJECTS_LOCAL: (void) _Watchdog_Remove( &the_timer->Ticker ); a0019008: e2840010 add r0, r4, #16 a001900c: eb0011c3 bl a001d720 <_Watchdog_Remove> a0019010: e8960003 ldm r6, {r0, r1} the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK; a0019014: e3a03003 mov r3, #3 a0019018: e59f204c ldr r2, [pc, #76] ; a001906c a001901c: e5843038 str r3, [r4, #56] ; 0x38 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a0019020: e5848018 str r8, [r4, #24] a0019024: e3a03000 mov r3, #0 the_watchdog->routine = routine; a0019028: e584a02c str sl, [r4, #44] ; 0x2c the_watchdog->id = id; a001902c: e5849030 str r9, [r4, #48] ; 0x30 the_watchdog->user_data = user_data; a0019030: e584b034 str fp, [r4, #52] ; 0x34 a0019034: eb004f6a bl a002cde4 <__divdi3> _Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data ); the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch(); a0019038: e0600007 rsb r0, r0, r7 a001903c: e584001c str r0, [r4, #28] (*timer_server->schedule_operation)( timer_server, the_timer ); a0019040: e5953004 ldr r3, [r5, #4] a0019044: e1a00005 mov r0, r5 a0019048: e1a01004 mov r1, r4 a001904c: e12fff33 blx r3 _Thread_Enable_dispatch(); a0019050: eb000e0b bl a001c884 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; a0019054: e1a00008 mov r0, r8 a0019058: ea000000 b a0019060 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; a001905c: e3a00014 mov r0, #20 <== NOT EXECUTED case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } a0019060: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} =============================================================================== a000aa08 : * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000aa08: e59f3020 ldr r3, [pc, #32] ; a000aa30 <== NOT EXECUTED void rtems_workspace_greedy_free( void *opaque ) { a000aa0c: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED a000aa10: e5932000 ldr r2, [r3] <== NOT EXECUTED a000aa14: e1a01000 mov r1, r0 <== NOT EXECUTED ++level; a000aa18: e2822001 add r2, r2, #1 <== NOT EXECUTED _Thread_Dispatch_disable_level = level; a000aa1c: e5832000 str r2, [r3] <== NOT EXECUTED _Thread_Disable_dispatch(); _Heap_Greedy_free( &_Workspace_Area, opaque ); a000aa20: e59f000c ldr r0, [pc, #12] ; a000aa34 <== NOT EXECUTED a000aa24: eb0002dc bl a000b59c <_Heap_Greedy_free> <== NOT EXECUTED _Thread_Enable_dispatch(); } a000aa28: e49de004 pop {lr} ; (ldr lr, [sp], #4) <== NOT EXECUTED void rtems_workspace_greedy_free( void *opaque ) { _Thread_Disable_dispatch(); _Heap_Greedy_free( &_Workspace_Area, opaque ); _Thread_Enable_dispatch(); a000aa2c: ea000892 b a000cc7c <_Thread_Enable_dispatch> <== NOT EXECUTED =============================================================================== a000a890 : int sched_get_priority_max( int policy ) { switch ( policy ) { a000a890: e3500004 cmp r0, #4 #include int sched_get_priority_max( int policy ) { a000a894: e52de004 push {lr} ; (str lr, [sp, #-4]!) switch ( policy ) { a000a898: 8a000003 bhi a000a8ac a000a89c: e3a03001 mov r3, #1 a000a8a0: e1a00013 lsl r0, r3, r0 a000a8a4: e3100017 tst r0, #23 a000a8a8: 1a000004 bne a000a8c0 case SCHED_RR: case SCHED_SPORADIC: break; default: rtems_set_errno_and_return_minus_one( EINVAL ); a000a8ac: eb001f6d bl a0012668 <__errno> <== NOT EXECUTED a000a8b0: e3a03016 mov r3, #22 <== NOT EXECUTED a000a8b4: e5803000 str r3, [r0] <== NOT EXECUTED a000a8b8: e3e00000 mvn r0, #0 <== NOT EXECUTED a000a8bc: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED } return POSIX_SCHEDULER_MAXIMUM_PRIORITY; a000a8c0: e59f3008 ldr r3, [pc, #8] ; a000a8d0 a000a8c4: e5d30000 ldrb r0, [r3] a000a8c8: e2400001 sub r0, r0, #1 } a000a8cc: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a000a8d4 : */ int sched_get_priority_min( int policy ) { switch ( policy ) { a000a8d4: e3500004 cmp r0, #4 * 13.3.6 Get Scheduling Parameter Limits, P1003.1b-1993, p. 258 */ int sched_get_priority_min( int policy ) { a000a8d8: e52de004 push {lr} ; (str lr, [sp, #-4]!) switch ( policy ) { a000a8dc: 8a000003 bhi a000a8f0 a000a8e0: e3a03001 mov r3, #1 a000a8e4: e1a00013 lsl r0, r3, r0 a000a8e8: e3100017 tst r0, #23 a000a8ec: 1a000004 bne a000a904 case SCHED_RR: case SCHED_SPORADIC: break; default: rtems_set_errno_and_return_minus_one( EINVAL ); a000a8f0: eb001f5c bl a0012668 <__errno> <== NOT EXECUTED a000a8f4: e3a03016 mov r3, #22 <== NOT EXECUTED a000a8f8: e5803000 str r3, [r0] <== NOT EXECUTED a000a8fc: e3e00000 mvn r0, #0 <== NOT EXECUTED a000a900: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED } return POSIX_SCHEDULER_MINIMUM_PRIORITY; a000a904: e1a00003 mov r0, r3 } a000a908: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a0009e08 : */ int sched_getparam( pid_t pid __attribute__((unused)), struct sched_param *param __attribute__((unused)) ) { a0009e08: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009e0c: eb00206b bl a0011fc0 <__errno> <== NOT EXECUTED a0009e10: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009e14: e5803000 str r3, [r0] <== NOT EXECUTED } a0009e18: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009e1c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a0009e20 : #include int sched_getscheduler( pid_t pid __attribute__((unused)) ) { a0009e20: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009e24: eb002065 bl a0011fc0 <__errno> <== NOT EXECUTED a0009e28: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009e2c: e5803000 str r3, [r0] <== NOT EXECUTED } a0009e30: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009e34: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000a90c : int sched_rr_get_interval( pid_t pid, struct timespec *interval ) { a000a90c: e92d4030 push {r4, r5, lr} <== NOT EXECUTED /* * Only supported for the "calling process" (i.e. this node). */ if ( pid && pid != getpid() ) a000a910: e2505000 subs r5, r0, #0 <== NOT EXECUTED int sched_rr_get_interval( pid_t pid, struct timespec *interval ) { a000a914: e1a04001 mov r4, r1 <== NOT EXECUTED /* * Only supported for the "calling process" (i.e. this node). */ if ( pid && pid != getpid() ) a000a918: 0a000005 beq a000a934 <== NOT EXECUTED a000a91c: ebfff076 bl a0006afc <== NOT EXECUTED a000a920: e1550000 cmp r5, r0 <== NOT EXECUTED a000a924: 0a000002 beq a000a934 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ESRCH ); a000a928: eb001f4e bl a0012668 <__errno> <== NOT EXECUTED a000a92c: e3a03003 mov r3, #3 <== NOT EXECUTED a000a930: ea000003 b a000a944 <== NOT EXECUTED if ( !interval ) a000a934: e3540000 cmp r4, #0 <== NOT EXECUTED a000a938: 1a000004 bne a000a950 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EINVAL ); a000a93c: eb001f49 bl a0012668 <__errno> <== NOT EXECUTED a000a940: e3a03016 mov r3, #22 <== NOT EXECUTED a000a944: e5803000 str r3, [r0] <== NOT EXECUTED a000a948: e3e00000 mvn r0, #0 <== NOT EXECUTED a000a94c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED _Timespec_From_ticks( _Thread_Ticks_per_timeslice, interval ); a000a950: e59f3010 ldr r3, [pc, #16] ; a000a968 <== NOT EXECUTED a000a954: e1a01004 mov r1, r4 <== NOT EXECUTED a000a958: e5930000 ldr r0, [r3] <== NOT EXECUTED a000a95c: eb000dc4 bl a000e074 <_Timespec_From_ticks> <== NOT EXECUTED return 0; a000a960: e3a00000 mov r0, #0 <== NOT EXECUTED } a000a964: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a0009e38 : int sched_setparam( pid_t pid __attribute__((unused)), const struct sched_param *param __attribute__((unused)) ) { a0009e38: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009e3c: eb00205f bl a0011fc0 <__errno> <== NOT EXECUTED a0009e40: e3a03058 mov r3, #88 ; 0x58 <== 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 =============================================================================== a0009e50 : int sched_setscheduler( pid_t pid __attribute__((unused)), int policy __attribute__((unused)), const struct sched_param *param __attribute__((unused)) ) { a0009e50: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009e54: eb002059 bl a0011fc0 <__errno> <== NOT EXECUTED a0009e58: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009e5c: e5803000 str r3, [r0] <== NOT EXECUTED } a0009e60: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009e64: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000cc74 : #include int sem_close( sem_t *sem ) { a000cc74: e92d4011 push {r0, r4, lr} a000cc78: e1a03000 mov r3, r0 RTEMS_INLINE_ROUTINE POSIX_Semaphore_Control *_POSIX_Semaphore_Get ( sem_t *id, Objects_Locations *location ) { return (POSIX_Semaphore_Control *) a000cc7c: e5931000 ldr r1, [r3] a000cc80: e59f0040 ldr r0, [pc, #64] ; a000ccc8 a000cc84: e1a0200d mov r2, sp a000cc88: eb00085c bl a000ee00 <_Objects_Get> register POSIX_Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _POSIX_Semaphore_Get( sem, &location ); switch ( location ) { a000cc8c: e59d4000 ldr r4, [sp] a000cc90: e3540000 cmp r4, #0 a000cc94: 1a000006 bne a000ccb4 case OBJECTS_LOCAL: the_semaphore->open_count -= 1; a000cc98: e5902018 ldr r2, [r0, #24] a000cc9c: e2422001 sub r2, r2, #1 a000cca0: e5802018 str r2, [r0, #24] _POSIX_Semaphore_Delete( the_semaphore ); a000cca4: eb0017c3 bl a0012bb8 <_POSIX_Semaphore_Delete> _Thread_Enable_dispatch(); a000cca8: eb000bc3 bl a000fbbc <_Thread_Enable_dispatch> return 0; a000ccac: e1a00004 mov r0, r4 a000ccb0: ea000003 b a000ccc4 #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a000ccb4: eb002268 bl a001565c <__errno> <== NOT EXECUTED a000ccb8: e3a03016 mov r3, #22 <== NOT EXECUTED a000ccbc: e5803000 str r3, [r0] <== NOT EXECUTED a000ccc0: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000ccc4: e8bd8018 pop {r3, r4, pc} =============================================================================== a000cccc : #include int sem_destroy( sem_t *sem ) { a000cccc: e92d4011 push {r0, r4, lr} a000ccd0: e1a03000 mov r3, r0 a000ccd4: e1a0200d mov r2, sp a000ccd8: e59f0048 ldr r0, [pc, #72] ; a000cd28 a000ccdc: e5931000 ldr r1, [r3] a000cce0: eb000846 bl a000ee00 <_Objects_Get> register POSIX_Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _POSIX_Semaphore_Get( sem, &location ); switch ( location ) { a000cce4: e59d2000 ldr r2, [sp] a000cce8: e3520000 cmp r2, #0 a000ccec: 1a000008 bne a000cd14 case OBJECTS_LOCAL: /* * Undefined operation on a named semaphore. */ if ( the_semaphore->named == true ) { a000ccf0: e5d04014 ldrb r4, [r0, #20] a000ccf4: e3540000 cmp r4, #0 a000ccf8: 0a000001 beq a000cd04 _Thread_Enable_dispatch(); a000ccfc: eb000bae bl a000fbbc <_Thread_Enable_dispatch> <== NOT EXECUTED a000cd00: ea000003 b a000cd14 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EINVAL ); } _POSIX_Semaphore_Delete( the_semaphore ); a000cd04: eb0017ab bl a0012bb8 <_POSIX_Semaphore_Delete> _Thread_Enable_dispatch(); a000cd08: eb000bab bl a000fbbc <_Thread_Enable_dispatch> return 0; a000cd0c: e1a00004 mov r0, r4 a000cd10: ea000003 b a000cd24 #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a000cd14: eb002250 bl a001565c <__errno> <== NOT EXECUTED a000cd18: e3a03016 mov r3, #22 <== NOT EXECUTED a000cd1c: e5803000 str r3, [r0] <== NOT EXECUTED a000cd20: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000cd24: e8bd8018 pop {r3, r4, pc} =============================================================================== a000cd2c : int sem_getvalue( sem_t *sem, int *sval ) { a000cd2c: e92d4031 push {r0, r4, r5, lr} a000cd30: e1a03000 mov r3, r0 a000cd34: e1a04001 mov r4, r1 a000cd38: e59f003c ldr r0, [pc, #60] ; a000cd7c a000cd3c: e5931000 ldr r1, [r3] a000cd40: e1a0200d mov r2, sp a000cd44: eb00082d bl a000ee00 <_Objects_Get> register POSIX_Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _POSIX_Semaphore_Get( sem, &location ); switch ( location ) { a000cd48: e59d5000 ldr r5, [sp] a000cd4c: e3550000 cmp r5, #0 a000cd50: 1a000004 bne a000cd68 case OBJECTS_LOCAL: *sval = _CORE_semaphore_Get_count( &the_semaphore->Semaphore ); a000cd54: e5903064 ldr r3, [r0, #100] ; 0x64 a000cd58: e5843000 str r3, [r4] _Thread_Enable_dispatch(); a000cd5c: eb000b96 bl a000fbbc <_Thread_Enable_dispatch> return 0; a000cd60: e1a00005 mov r0, r5 a000cd64: ea000003 b a000cd78 #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a000cd68: eb00223b bl a001565c <__errno> <== NOT EXECUTED a000cd6c: e3a03016 mov r3, #22 <== NOT EXECUTED a000cd70: e5803000 str r3, [r0] <== NOT EXECUTED a000cd74: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000cd78: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000ae7c : int oflag, ... /* mode_t mode, */ /* unsigned int value */ ) { a000ae7c: e92d000e push {r1, r2, r3} * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000ae80: e59f3100 ldr r3, [pc, #256] ; a000af88 a000ae84: e92d41f0 push {r4, r5, r6, r7, r8, lr} a000ae88: e5932000 ldr r2, [r3] a000ae8c: e24dd018 sub sp, sp, #24 a000ae90: e59d4030 ldr r4, [sp, #48] ; 0x30 ++level; a000ae94: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000ae98: e5832000 str r2, [r3] a000ae9c: e1a06000 mov r6, r0 Objects_Locations location; size_t name_len; _Thread_Disable_dispatch(); if ( oflag & O_CREAT ) { a000aea0: e2147c02 ands r7, r4, #512 ; 0x200 va_start(arg, oflag); mode = va_arg( arg, mode_t ); value = va_arg( arg, unsigned int ); a000aea4: 128d303c addne r3, sp, #60 ; 0x3c a000aea8: 158d3004 strne r3, [sp, #4] const char *name, Objects_Id *id, size_t *len ) { return _POSIX_Name_to_id( &_POSIX_Semaphore_Information, name, id, len ); a000aeac: e59f00d8 ldr r0, [pc, #216] ; a000af8c a000aeb0: e1a01006 mov r1, r6 a000aeb4: e28d2008 add r2, sp, #8 a000aeb8: e28d3014 add r3, sp, #20 a000aebc: 159d5038 ldrne r5, [sp, #56] ; 0x38 /* unsigned int value */ ) { va_list arg; mode_t mode; unsigned int value = 0; a000aec0: 01a05007 moveq r5, r7 a000aec4: ebfffe78 bl a000a8ac <_POSIX_Name_to_id> * 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 ) { a000aec8: e2508000 subs r8, r0, #0 a000aecc: 0a000007 beq a000aef0 /* * 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) ) ) { a000aed0: e3580002 cmp r8, #2 a000aed4: 1a000001 bne a000aee0 a000aed8: e3570000 cmp r7, #0 a000aedc: 1a000017 bne a000af40 _Thread_Enable_dispatch(); a000aee0: eb000d25 bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one_cast( status, sem_t * ); a000aee4: eb002207 bl a0013708 <__errno> <== NOT EXECUTED a000aee8: e5808000 str r8, [r0] <== NOT EXECUTED a000aeec: ea000006 b a000af0c <== NOT EXECUTED /* * Check for existence with creation. */ if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) { a000aef0: e2044c0a and r4, r4, #2560 ; 0xa00 a000aef4: e3540c0a cmp r4, #2560 ; 0xa00 a000aef8: 1a000005 bne a000af14 _Thread_Enable_dispatch(); a000aefc: eb000d1e bl a000e37c <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one_cast( EEXIST, sem_t * ); a000af00: eb002200 bl a0013708 <__errno> <== NOT EXECUTED a000af04: e3a03011 mov r3, #17 <== NOT EXECUTED a000af08: e5803000 str r3, [r0] <== NOT EXECUTED a000af0c: e3e00000 mvn r0, #0 <== NOT EXECUTED a000af10: ea000018 b a000af78 <== NOT EXECUTED RTEMS_INLINE_ROUTINE POSIX_Semaphore_Control *_POSIX_Semaphore_Get ( sem_t *id, Objects_Locations *location ) { return (POSIX_Semaphore_Control *) a000af14: e59d1008 ldr r1, [sp, #8] a000af18: e28d2010 add r2, sp, #16 a000af1c: e59f0068 ldr r0, [pc, #104] ; a000af8c a000af20: eb00096d bl a000d4dc <_Objects_Get> } the_semaphore = _POSIX_Semaphore_Get( (sem_t *) &the_semaphore_id, &location ); the_semaphore->open_count += 1; a000af24: e5903018 ldr r3, [r0, #24] 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( (sem_t *) &the_semaphore_id, &location ); a000af28: e58d000c str r0, [sp, #12] the_semaphore->open_count += 1; a000af2c: e2833001 add r3, r3, #1 a000af30: e5803018 str r3, [r0, #24] _Thread_Enable_dispatch(); a000af34: eb000d10 bl a000e37c <_Thread_Enable_dispatch> _Thread_Enable_dispatch(); a000af38: eb000d0f bl a000e37c <_Thread_Enable_dispatch> goto return_id; a000af3c: ea00000b b a000af70 /* * 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( a000af40: e28d300c add r3, sp, #12 a000af44: e58d3000 str r3, [sp] a000af48: e59d1014 ldr r1, [sp, #20] a000af4c: e3a02000 mov r2, #0 a000af50: e1a03005 mov r3, r5 a000af54: e1a00006 mov r0, r6 a000af58: eb001837 bl a001103c <_POSIX_Semaphore_Create_support> a000af5c: e1a04000 mov r4, r0 /* * errno was set by Create_support, so don't set it again. */ _Thread_Enable_dispatch(); a000af60: eb000d05 bl a000e37c <_Thread_Enable_dispatch> if ( status == -1 ) a000af64: e3740001 cmn r4, #1 return SEM_FAILED; a000af68: 01a00004 moveq r0, r4 * errno was set by Create_support, so don't set it again. */ _Thread_Enable_dispatch(); if ( status == -1 ) a000af6c: 0a000001 beq a000af78 return_id: #if defined(RTEMS_USE_16_BIT_OBJECT) the_semaphore->Semaphore_id = the_semaphore->Object.id; return &the_semaphore->Semaphore_id; #else return (sem_t *)&the_semaphore->Object.id; a000af70: e59d000c ldr r0, [sp, #12] a000af74: e2800008 add r0, r0, #8 #endif } a000af78: e28dd018 add sp, sp, #24 a000af7c: e8bd41f0 pop {r4, r5, r6, r7, r8, lr} a000af80: e28dd00c add sp, sp, #12 a000af84: e12fff1e bx lr =============================================================================== a000a43c : #include int sem_post( sem_t *sem ) { a000a43c: e92d4011 push {r0, r4, lr} a000a440: e1a03000 mov r3, r0 RTEMS_INLINE_ROUTINE POSIX_Semaphore_Control *_POSIX_Semaphore_Get ( sem_t *id, Objects_Locations *location ) { return (POSIX_Semaphore_Control *) a000a444: e5931000 ldr r1, [r3] a000a448: e59f0044 ldr r0, [pc, #68] ; a000a494 a000a44c: e1a0200d mov r2, sp a000a450: eb000806 bl a000c470 <_Objects_Get> register POSIX_Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _POSIX_Semaphore_Get( sem, &location ); switch ( location ) { a000a454: e59d4000 ldr r4, [sp] a000a458: e1a03000 mov r3, r0 a000a45c: e3540000 cmp r4, #0 a000a460: 1a000006 bne a000a480 case OBJECTS_LOCAL: _CORE_semaphore_Surrender( a000a464: e5931008 ldr r1, [r3, #8] a000a468: e1a02004 mov r2, r4 a000a46c: e280001c add r0, r0, #28 a000a470: eb000568 bl a000ba18 <_CORE_semaphore_Surrender> NULL /* XXX need to define a routine to handle this case */ #else NULL #endif ); _Thread_Enable_dispatch(); a000a474: eb000b6c bl a000d22c <_Thread_Enable_dispatch> return 0; a000a478: e1a00004 mov r0, r4 a000a47c: ea000003 b a000a490 #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a000a480: eb00205a bl a00125f0 <__errno> <== NOT EXECUTED a000a484: e3a03016 mov r3, #22 <== NOT EXECUTED a000a488: e5803000 str r3, [r0] <== NOT EXECUTED a000a48c: e3e00000 mvn r0, #0 <== NOT EXECUTED } a000a490: e8bd8018 pop {r3, r4, pc} =============================================================================== a000cf44 : int sem_timedwait( sem_t *sem, const struct timespec *abstime ) { a000cf44: e92d4011 push {r0, r4, lr} <== NOT EXECUTED a000cf48: 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 ); a000cf4c: e1a00001 mov r0, r1 <== NOT EXECUTED a000cf50: e1a0100d mov r1, sp <== NOT EXECUTED a000cf54: eb001475 bl a0012130 <_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 ); a000cf58: e2403003 sub r3, r0, #3 <== NOT EXECUTED a000cf5c: e2731000 rsbs r1, r3, #0 <== NOT EXECUTED a000cf60: e0a11003 adc r1, r1, r3 <== NOT EXECUTED a000cf64: e1a00004 mov r0, r4 <== NOT EXECUTED a000cf68: e59d2000 ldr r2, [sp] <== NOT EXECUTED a000cf6c: eb001734 bl a0012c44 <_POSIX_Semaphore_Wait_support> <== NOT EXECUTED lock_status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW ) rtems_set_errno_and_return_minus_one( ETIMEDOUT ); } return lock_status; } a000cf70: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED =============================================================================== a000cf80 : * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000cf80: e59f3070 ldr r3, [pc, #112] ; a000cff8 #include int sem_unlink( const char *name ) { a000cf84: e92d4073 push {r0, r1, r4, r5, r6, lr} a000cf88: e5932000 ldr r2, [r3] a000cf8c: e1a01000 mov r1, r0 ++level; a000cf90: e2822001 add r2, r2, #1 _Thread_Dispatch_disable_level = level; a000cf94: e5832000 str r2, [r3] const char *name, Objects_Id *id, size_t *len ) { return _POSIX_Name_to_id( &_POSIX_Semaphore_Information, name, id, len ); a000cf98: e59f405c ldr r4, [pc, #92] ; a000cffc a000cf9c: e1a0200d mov r2, sp a000cfa0: e28d3004 add r3, sp, #4 a000cfa4: e1a00004 mov r0, r4 a000cfa8: eb00151e bl a0012428 <_POSIX_Name_to_id> size_t name_len; _Thread_Disable_dispatch(); status = _POSIX_Semaphore_Name_to_id( name, &the_semaphore_id, &name_len ); if ( status != 0 ) { a000cfac: e2505000 subs r5, r0, #0 a000cfb0: 0a000004 beq a000cfc8 _Thread_Enable_dispatch(); a000cfb4: eb000b00 bl a000fbbc <_Thread_Enable_dispatch> <== NOT EXECUTED rtems_set_errno_and_return_minus_one( status ); a000cfb8: eb0021a7 bl a001565c <__errno> <== NOT EXECUTED a000cfbc: e5805000 str r5, [r0] <== NOT EXECUTED a000cfc0: e3e00000 mvn r0, #0 <== NOT EXECUTED a000cfc4: ea00000a b a000cff4 <== NOT EXECUTED */ #if defined(RTEMS_DEBUG) if ( index > information->maximum ) return NULL; #endif return information->local_table[ index ]; a000cfc8: e594301c ldr r3, [r4, #28] a000cfcc: e1dd20b0 ldrh r2, [sp] RTEMS_INLINE_ROUTINE void _POSIX_Semaphore_Namespace_remove ( POSIX_Semaphore_Control *the_semaphore ) { _Objects_Namespace_remove( a000cfd0: e1a00004 mov r0, r4 a000cfd4: e7936102 ldr r6, [r3, r2, lsl #2] a000cfd8: e1a01006 mov r1, r6 the_semaphore = (POSIX_Semaphore_Control *) _Objects_Get_local_object( &_POSIX_Semaphore_Information, _Objects_Get_index( the_semaphore_id ) ); the_semaphore->linked = false; a000cfdc: e5c65015 strb r5, [r6, #21] a000cfe0: eb0007d5 bl a000ef3c <_Objects_Namespace_remove> _POSIX_Semaphore_Namespace_remove( the_semaphore ); _POSIX_Semaphore_Delete( the_semaphore ); a000cfe4: e1a00006 mov r0, r6 a000cfe8: eb0016f2 bl a0012bb8 <_POSIX_Semaphore_Delete> _Thread_Enable_dispatch(); a000cfec: eb000af2 bl a000fbbc <_Thread_Enable_dispatch> return 0; a000cff0: e1a00005 mov r0, r5 } a000cff4: e8bd807c pop {r2, r3, r4, r5, r6, pc} =============================================================================== a0009d0c : int which, const struct itimerval *value, struct itimerval *ovalue ) { if ( !value ) a0009d0c: e3510000 cmp r1, #0 int setitimer( int which, const struct itimerval *value, struct itimerval *ovalue ) { a0009d10: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( !value ) a0009d14: 0a000001 beq a0009d20 rtems_set_errno_and_return_minus_one( EFAULT ); if ( !ovalue ) a0009d18: e3520000 cmp r2, #0 a0009d1c: 1a000002 bne a0009d2c rtems_set_errno_and_return_minus_one( EFAULT ); a0009d20: eb002053 bl a0011e74 <__errno> <== NOT EXECUTED a0009d24: e3a0300e mov r3, #14 <== NOT EXECUTED a0009d28: ea000006 b a0009d48 <== NOT EXECUTED switch ( which ) { a0009d2c: e3500002 cmp r0, #2 a0009d30: 8a000002 bhi a0009d40 case ITIMER_REAL: case ITIMER_VIRTUAL: case ITIMER_PROF: rtems_set_errno_and_return_minus_one( ENOSYS ); a0009d34: eb00204e bl a0011e74 <__errno> <== NOT EXECUTED a0009d38: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009d3c: ea000001 b a0009d48 <== NOT EXECUTED default: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a0009d40: eb00204b bl a0011e74 <__errno> a0009d44: e3a03016 mov r3, #22 a0009d48: e5803000 str r3, [r0] } a0009d4c: e3e00000 mvn r0, #0 a0009d50: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a000a780 : struct sigaction *oact ) { ISR_Level level; if ( oact ) a000a780: e3520000 cmp r2, #0 int sigaction( int sig, const struct sigaction *act, struct sigaction *oact ) { a000a784: e92d41f0 push {r4, r5, r6, r7, r8, lr} a000a788: e1a04000 mov r4, r0 a000a78c: e1a05001 mov r5, r1 ISR_Level level; if ( oact ) a000a790: 0a00000a beq a000a7c0 *oact = _POSIX_signals_Vectors[ sig ]; a000a794: e3a0300c mov r3, #12 a000a798: e0030394 mul r3, r4, r3 a000a79c: e59f00e0 ldr r0, [pc, #224] ; a000a884 a000a7a0: e0801003 add r1, r0, r3 a000a7a4: e7900003 ldr r0, [r0, r3] a000a7a8: e1a03002 mov r3, r2 a000a7ac: e4830004 str r0, [r3], #4 a000a7b0: e5910004 ldr r0, [r1, #4] a000a7b4: e5820004 str r0, [r2, #4] a000a7b8: e5912008 ldr r2, [r1, #8] a000a7bc: e5832004 str r2, [r3, #4] if ( !sig ) a000a7c0: e3540000 cmp r4, #0 a000a7c4: 0a000004 beq a000a7dc static inline bool is_valid_signo( int signo ) { return ((signo) >= 1 && (signo) <= 32 ); a000a7c8: e2443001 sub r3, r4, #1 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !is_valid_signo(sig) ) a000a7cc: e353001f cmp r3, #31 a000a7d0: 8a000001 bhi a000a7dc * * NOTE: Solaris documentation claims to "silently enforce" this which * contradicts the POSIX specification. */ if ( sig == SIGKILL ) a000a7d4: e3540009 cmp r4, #9 a000a7d8: 1a000004 bne a000a7f0 rtems_set_errno_and_return_minus_one( EINVAL ); a000a7dc: eb002066 bl a001297c <__errno> <== NOT EXECUTED a000a7e0: e3a03016 mov r3, #22 <== NOT EXECUTED a000a7e4: e5803000 str r3, [r0] <== NOT EXECUTED a000a7e8: e3e00000 mvn r0, #0 <== NOT EXECUTED a000a7ec: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED /* * Evaluate the new action structure and set the global signal vector * appropriately. */ if ( act ) { a000a7f0: e3550000 cmp r5, #0 a000a7f4: 0a000020 beq a000a87c uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000a7f8: e10f8000 mrs r8, CPSR a000a7fc: e3883080 orr r3, r8, #128 ; 0x80 a000a800: 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 ) { a000a804: e5953008 ldr r3, [r5, #8] a000a808: e59f6074 ldr r6, [pc, #116] ; a000a884 a000a80c: e3a0700c mov r7, #12 a000a810: e3530000 cmp r3, #0 a000a814: 1a00000a bne a000a844 _POSIX_signals_Vectors[ sig ] = _POSIX_signals_Default_vectors[ sig ]; a000a818: e0040497 mul r4, r7, r4 a000a81c: e59f1064 ldr r1, [pc, #100] ; a000a888 a000a820: e0863004 add r3, r6, r4 a000a824: e0812004 add r2, r1, r4 a000a828: e7911004 ldr r1, [r1, r4] a000a82c: e7861004 str r1, [r6, r4] a000a830: e5921004 ldr r1, [r2, #4] a000a834: e5922008 ldr r2, [r2, #8] a000a838: e5831004 str r1, [r3, #4] a000a83c: e5832008 str r2, [r3, #8] a000a840: ea00000a b a000a870 } else { _POSIX_signals_Clear_process_signals( sig ); a000a844: e1a00004 mov r0, r4 a000a848: eb001589 bl a000fe74 <_POSIX_signals_Clear_process_signals> _POSIX_signals_Vectors[ sig ] = *act; a000a84c: e0040497 mul r4, r7, r4 a000a850: e1a03005 mov r3, r5 a000a854: e4931004 ldr r1, [r3], #4 a000a858: e0862004 add r2, r6, r4 a000a85c: e7861004 str r1, [r6, r4] a000a860: e5951004 ldr r1, [r5, #4] a000a864: e5821004 str r1, [r2, #4] a000a868: e5933004 ldr r3, [r3, #4] a000a86c: e5823008 str r3, [r2, #8] static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000a870: e129f008 msr CPSR_fc, r8 * 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; a000a874: e3a00000 mov r0, #0 a000a878: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} a000a87c: e1a00005 mov r0, r5 <== NOT EXECUTED } a000a880: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED =============================================================================== a000a88c : int sigaddset( sigset_t *set, int signo ) { if ( !set ) a000a88c: e3500000 cmp r0, #0 int sigaddset( sigset_t *set, int signo ) { a000a890: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( !set ) a000a894: 0a000004 beq a000a8ac rtems_set_errno_and_return_minus_one( EINVAL ); if ( !signo ) a000a898: e3510000 cmp r1, #0 a000a89c: 0a000002 beq a000a8ac a000a8a0: e2411001 sub r1, r1, #1 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !is_valid_signo(signo) ) a000a8a4: e351001f cmp r1, #31 a000a8a8: 9a000004 bls a000a8c0 rtems_set_errno_and_return_minus_one( EINVAL ); a000a8ac: eb002032 bl a001297c <__errno> <== NOT EXECUTED a000a8b0: e3a03016 mov r3, #22 <== NOT EXECUTED a000a8b4: e5803000 str r3, [r0] <== NOT EXECUTED a000a8b8: e3e00000 mvn r0, #0 <== NOT EXECUTED a000a8bc: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED *set |= signo_to_mask(signo); a000a8c0: e5903000 ldr r3, [r0] a000a8c4: e3a02001 mov r2, #1 a000a8c8: e1831112 orr r1, r3, r2, lsl r1 a000a8cc: e5801000 str r1, [r0] return 0; a000a8d0: e3a00000 mov r0, #0 } a000a8d4: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a000c850 : int sigdelset( sigset_t *set, int signo ) { if ( !set ) a000c850: e3500000 cmp r0, #0 int sigdelset( sigset_t *set, int signo ) { a000c854: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( !set ) a000c858: 0a000004 beq a000c870 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !signo ) a000c85c: e3510000 cmp r1, #0 a000c860: 0a00000d beq a000c89c a000c864: e2411001 sub r1, r1, #1 return 0; if ( !is_valid_signo(signo) ) a000c868: e351001f cmp r1, #31 a000c86c: 9a000004 bls a000c884 rtems_set_errno_and_return_minus_one( EINVAL ); a000c870: eb00209f bl a0014af4 <__errno> <== NOT EXECUTED a000c874: e3a03016 mov r3, #22 <== NOT EXECUTED a000c878: e5803000 str r3, [r0] <== NOT EXECUTED a000c87c: e3e00000 mvn r0, #0 <== NOT EXECUTED a000c880: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED *set &= ~signo_to_mask(signo); a000c884: e5903000 ldr r3, [r0] a000c888: e3a02001 mov r2, #1 a000c88c: e1c31112 bic r1, r3, r2, lsl r1 a000c890: e5801000 str r1, [r0] return 0; a000c894: e3a00000 mov r0, #0 a000c898: e49df004 pop {pc} ; (ldr pc, [sp], #4) { if ( !set ) rtems_set_errno_and_return_minus_one( EINVAL ); if ( !signo ) return 0; a000c89c: 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; } a000c8a0: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000f2cc : int sigemptyset( sigset_t *set ) { if ( !set ) a000f2cc: e2503000 subs r3, r0, #0 #include int sigemptyset( sigset_t *set ) { a000f2d0: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( !set ) a000f2d4: 1a000004 bne a000f2ec rtems_set_errno_and_return_minus_one( EINVAL ); a000f2d8: eb00098f bl a001191c <__errno> <== NOT EXECUTED a000f2dc: e3a03016 mov r3, #22 <== NOT EXECUTED a000f2e0: e5803000 str r3, [r0] <== NOT EXECUTED a000f2e4: e3e00000 mvn r0, #0 <== NOT EXECUTED a000f2e8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED *set = 0; a000f2ec: e3a00000 mov r0, #0 a000f2f0: e5830000 str r0, [r3] return 0; } a000f2f4: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a000c8d0 : int sigfillset( sigset_t *set ) { if ( !set ) a000c8d0: e3500000 cmp r0, #0 #include int sigfillset( sigset_t *set ) { a000c8d4: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( !set ) a000c8d8: 1a000004 bne a000c8f0 rtems_set_errno_and_return_minus_one( EINVAL ); a000c8dc: eb002084 bl a0014af4 <__errno> <== NOT EXECUTED a000c8e0: e3a03016 mov r3, #22 <== NOT EXECUTED a000c8e4: e5803000 str r3, [r0] <== NOT EXECUTED a000c8e8: e3e00000 mvn r0, #0 <== NOT EXECUTED a000c8ec: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED *set = SIGNAL_ALL_MASK; a000c8f0: e3e03000 mvn r3, #0 a000c8f4: e5803000 str r3, [r0] return 0; a000c8f8: e3a00000 mov r0, #0 } a000c8fc: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a000c900 : int sigismember( const sigset_t *set, int signo ) { if ( !set ) a000c900: e3500000 cmp r0, #0 int sigismember( const sigset_t *set, int signo ) { a000c904: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( !set ) a000c908: 0a000004 beq a000c920 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !signo ) a000c90c: e3510000 cmp r1, #0 a000c910: 0a00000d beq a000c94c a000c914: e2411001 sub r1, r1, #1 return 0; if ( !is_valid_signo(signo) ) a000c918: e351001f cmp r1, #31 a000c91c: 9a000004 bls a000c934 rtems_set_errno_and_return_minus_one( EINVAL ); a000c920: eb002073 bl a0014af4 <__errno> <== NOT EXECUTED a000c924: e3a03016 mov r3, #22 <== NOT EXECUTED a000c928: e5803000 str r3, [r0] <== NOT EXECUTED a000c92c: e3e00000 mvn r0, #0 <== NOT EXECUTED a000c930: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED if ( *set & signo_to_mask(signo) ) a000c934: e5903000 ldr r3, [r0] const sigset_t *set, int signo ) { if ( !set ) rtems_set_errno_and_return_minus_one( EINVAL ); a000c938: e3a02001 mov r2, #1 a000c93c: e0133112 ands r3, r3, r2, lsl r1 a000c940: 03a00000 moveq r0, #0 a000c944: 13a00001 movne r0, #1 a000c948: e49df004 pop {pc} ; (ldr pc, [sp], #4) if ( !signo ) return 0; a000c94c: e1a00001 mov r0, r1 <== NOT EXECUTED if ( *set & signo_to_mask(signo) ) return 1; return 0; } a000c950: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000a904 : sigset_t *set ) { POSIX_API_Control *api; if ( !set ) a000a904: e3500000 cmp r0, #0 #include int sigpending( sigset_t *set ) { a000a908: e52de004 push {lr} ; (str lr, [sp, #-4]!) POSIX_API_Control *api; if ( !set ) a000a90c: 1a000004 bne a000a924 rtems_set_errno_and_return_minus_one( EINVAL ); a000a910: eb002019 bl a001297c <__errno> <== NOT EXECUTED a000a914: e3a03016 mov r3, #22 <== NOT EXECUTED a000a918: e5803000 str r3, [r0] <== NOT EXECUTED a000a91c: e3e00000 mvn r0, #0 <== NOT EXECUTED a000a920: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; a000a924: e59f3020 ldr r3, [pc, #32] ; a000a94c *set = api->signals_pending | _POSIX_signals_Pending; a000a928: e59f2020 ldr r2, [pc, #32] ; a000a950 POSIX_API_Control *api; if ( !set ) rtems_set_errno_and_return_minus_one( EINVAL ); api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; a000a92c: e5933008 ldr r3, [r3, #8] *set = api->signals_pending | _POSIX_signals_Pending; a000a930: e5922000 ldr r2, [r2] a000a934: e59330f4 ldr r3, [r3, #244] ; 0xf4 a000a938: e59330d4 ldr r3, [r3, #212] ; 0xd4 a000a93c: e1823003 orr r3, r2, r3 a000a940: e5803000 str r3, [r0] return 0; a000a944: e3a00000 mov r0, #0 } a000a948: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a000c9a8 : int sigqueue( pid_t pid, int signo, const union sigval value ) { a000c9a8: e92d4001 push {r0, lr} <== NOT EXECUTED a000c9ac: e28d3004 add r3, sp, #4 <== NOT EXECUTED a000c9b0: e5232004 str r2, [r3, #-4]! <== NOT EXECUTED return killinfo( pid, signo, &value ); a000c9b4: e1a0200d mov r2, sp <== NOT EXECUTED a000c9b8: eb001585 bl a0011fd4 <== NOT EXECUTED } a000c9bc: e8bd8008 pop {r3, pc} <== NOT EXECUTED =============================================================================== a000c9c0 : #include int sigsuspend( const sigset_t *sigmask ) { a000c9c0: e92d4013 push {r0, r1, r4, lr} <== NOT EXECUTED a000c9c4: e1a04000 mov r4, 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 ); a000c9c8: e1a01004 mov r1, r4 <== NOT EXECUTED a000c9cc: e1a0200d mov r2, sp <== NOT EXECUTED a000c9d0: e3a00001 mov r0, #1 <== NOT EXECUTED a000c9d4: ebfffff2 bl a000c9a4 <== NOT EXECUTED current_unblocked_signals = ~(*sigmask); a000c9d8: e5943000 ldr r3, [r4] <== NOT EXECUTED a000c9dc: e28d0008 add r0, sp, #8 <== NOT EXECUTED status = sigtimedwait( ¤t_unblocked_signals, NULL, NULL ); a000c9e0: 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); a000c9e4: e1e03003 mvn r3, r3 <== NOT EXECUTED a000c9e8: e5203004 str r3, [r0, #-4]! <== NOT EXECUTED status = sigtimedwait( ¤t_unblocked_signals, NULL, NULL ); a000c9ec: e1a02001 mov r2, r1 <== NOT EXECUTED a000c9f0: eb00001a bl a000ca60 <== NOT EXECUTED (void) sigprocmask( SIG_SETMASK, &saved_signals_blocked, NULL ); a000c9f4: e3a00000 mov r0, #0 <== NOT EXECUTED a000c9f8: e1a0100d mov r1, sp <== NOT EXECUTED a000c9fc: e1a02000 mov r2, r0 <== NOT EXECUTED a000ca00: ebffffe7 bl a000c9a4 <== NOT EXECUTED */ #if defined(RTEMS_DEBUG) assert( status != -1 ); #endif rtems_set_errno_and_return_minus_one( EINTR ); a000ca04: eb00203a bl a0014af4 <__errno> <== NOT EXECUTED a000ca08: e3a03004 mov r3, #4 <== NOT EXECUTED a000ca0c: e5803000 str r3, [r0] <== NOT EXECUTED } a000ca10: e3e00000 mvn r0, #0 <== NOT EXECUTED a000ca14: e8bd801c pop {r2, r3, r4, pc} <== NOT EXECUTED =============================================================================== a000acbc : int sigtimedwait( const sigset_t *set, siginfo_t *info, const struct timespec *timeout ) { a000acbc: e92d45ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, sl, lr} ISR_Level level; /* * Error check parameters before disabling interrupts. */ if ( !set ) a000acc0: e2506000 subs r6, r0, #0 int sigtimedwait( const sigset_t *set, siginfo_t *info, const struct timespec *timeout ) { a000acc4: e1a04001 mov r4, r1 a000acc8: e1a05002 mov r5, r2 ISR_Level level; /* * Error check parameters before disabling interrupts. */ if ( !set ) a000accc: 0a000009 beq a000acf8 /* NOTE: This is very specifically a RELATIVE not ABSOLUTE time * in the Open Group specification. */ interval = 0; if ( timeout ) { a000acd0: e3520000 cmp r2, #0 a000acd4: 0a00000a beq a000ad04 if ( !_Timespec_Is_valid( timeout ) ) a000acd8: e1a00002 mov r0, r2 a000acdc: eb000e02 bl a000e4ec <_Timespec_Is_valid> a000ace0: e3500000 cmp r0, #0 a000ace4: 0a000003 beq a000acf8 rtems_set_errno_and_return_minus_one( EINVAL ); interval = _Timespec_To_ticks( timeout ); a000ace8: e1a00005 mov r0, r5 a000acec: eb000e0f bl a000e530 <_Timespec_To_ticks> if ( !interval ) a000acf0: e2501000 subs r1, r0, #0 a000acf4: 1a000003 bne a000ad08 rtems_set_errno_and_return_minus_one( EINVAL ); a000acf8: eb0020c6 bl a0013018 <__errno> a000acfc: e3a03016 mov r3, #22 a000ad00: ea000055 b a000ae5c /* NOTE: This is very specifically a RELATIVE not ABSOLUTE time * in the Open Group specification. */ interval = 0; a000ad04: e1a01002 mov r1, r2 * Initialize local variables. */ the_info = ( info ) ? info : &signal_information; the_thread = _Thread_Executing; a000ad08: e59f3160 ldr r3, [pc, #352] ; a000ae70 /* * Initialize local variables. */ the_info = ( info ) ? info : &signal_information; a000ad0c: e3540000 cmp r4, #0 a000ad10: 028d4004 addeq r4, sp, #4 the_thread = _Thread_Executing; a000ad14: e5933008 ldr r3, [r3, #8] api = the_thread->API_Extensions[ THREAD_API_POSIX ]; a000ad18: e59380f4 ldr r8, [r3, #244] ; 0xf4 uint32_t level; #if defined(ARM_MULTILIB_ARCH_V4) uint32_t arm_switch_reg; __asm__ volatile ( a000ad1c: e10f7000 mrs r7, CPSR a000ad20: e3872080 orr r2, r7, #128 ; 0x80 a000ad24: e129f002 msr CPSR_fc, r2 */ /* API signals pending? */ _ISR_Disable( level ); if ( *set & api->signals_pending ) { a000ad28: e5962000 ldr r2, [r6] a000ad2c: e59800d4 ldr r0, [r8, #212] ; 0xd4 a000ad30: e012a000 ands sl, r2, r0 a000ad34: 0a00000d beq a000ad70 /* XXX real info later */ the_info->si_signo = _POSIX_signals_Get_lowest( api->signals_pending ); a000ad38: ebffffcd bl a000ac74 <_POSIX_signals_Get_lowest> <== NOT EXECUTED _POSIX_signals_Clear_signals( a000ad3c: 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 ); a000ad40: e5840000 str r0, [r4] <== NOT EXECUTED a000ad44: e1a01000 mov r1, r0 <== NOT EXECUTED _POSIX_signals_Clear_signals( a000ad48: e1a02004 mov r2, r4 <== NOT EXECUTED a000ad4c: e1a00008 mov r0, r8 <== NOT EXECUTED a000ad50: e58d3000 str r3, [sp] <== NOT EXECUTED a000ad54: eb00163a bl a0010644 <_POSIX_signals_Clear_signals> <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { #if defined(ARM_MULTILIB_ARCH_V4) ARM_SWITCH_REGISTERS; __asm__ volatile ( a000ad58: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED false ); _ISR_Enable( level ); the_info->si_code = SI_USER; the_info->si_value.sival_int = 0; a000ad5c: e3a01001 mov r1, #1 <== NOT EXECUTED a000ad60: e3a03000 mov r3, #0 <== NOT EXECUTED a000ad64: e984000a stmib r4, {r1, r3} <== NOT EXECUTED return the_info->si_signo; a000ad68: e5945000 ldr r5, [r4] <== NOT EXECUTED a000ad6c: ea00003c b a000ae64 <== NOT EXECUTED } /* Process pending signals? */ if ( *set & _POSIX_signals_Pending ) { a000ad70: e59f00fc ldr r0, [pc, #252] ; a000ae74 a000ad74: e5900000 ldr r0, [r0] a000ad78: e1120000 tst r2, r0 a000ad7c: 0a00000d beq a000adb8 signo = _POSIX_signals_Get_lowest( _POSIX_signals_Pending ); a000ad80: ebffffbb bl a000ac74 <_POSIX_signals_Get_lowest> <== NOT EXECUTED a000ad84: e1a05000 mov r5, r0 <== NOT EXECUTED _POSIX_signals_Clear_signals( api, signo, the_info, true, false ); a000ad88: e1a01005 mov r1, r5 <== NOT EXECUTED a000ad8c: e1a00008 mov r0, r8 <== NOT EXECUTED a000ad90: e1a02004 mov r2, r4 <== NOT EXECUTED a000ad94: e3a03001 mov r3, #1 <== NOT EXECUTED a000ad98: e58da000 str sl, [sp] <== NOT EXECUTED a000ad9c: eb001628 bl a0010644 <_POSIX_signals_Clear_signals> <== NOT EXECUTED a000ada0: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED _ISR_Enable( level ); the_info->si_signo = signo; the_info->si_code = SI_USER; the_info->si_value.sival_int = 0; a000ada4: e3a02001 mov r2, #1 <== NOT EXECUTED a000ada8: 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; a000adac: e5845000 str r5, [r4] <== NOT EXECUTED the_info->si_code = SI_USER; the_info->si_value.sival_int = 0; a000adb0: e984000c stmib r4, {r2, r3} <== NOT EXECUTED return signo; a000adb4: ea00002a b a000ae64 <== NOT EXECUTED } the_info->si_signo = -1; a000adb8: e3e02000 mvn r2, #0 a000adbc: e5842000 str r2, [r4] * * This rountine increments the thread dispatch level */ RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void) { uint32_t level = _Thread_Dispatch_disable_level; a000adc0: e59f20b0 ldr r2, [pc, #176] ; a000ae78 a000adc4: e5920000 ldr r0, [r2] ++level; a000adc8: e2800001 add r0, r0, #1 _Thread_Dispatch_disable_level = level; a000adcc: e5820000 str r0, [r2] _Thread_Disable_dispatch(); the_thread->Wait.queue = &_POSIX_signals_Wait_queue; the_thread->Wait.return_code = EINTR; a000add0: e3a00004 mov r0, #4 a000add4: e5830034 str r0, [r3, #52] ; 0x34 the_thread->Wait.option = *set; a000add8: e5960000 ldr r0, [r6] } the_info->si_signo = -1; _Thread_Disable_dispatch(); the_thread->Wait.queue = &_POSIX_signals_Wait_queue; a000addc: e59f2098 ldr r2, [pc, #152] ; a000ae7c the_thread->Wait.return_code = EINTR; the_thread->Wait.option = *set; the_thread->Wait.return_argument = the_info; a000ade0: 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; a000ade4: e5830030 str r0, [r3, #48] ; 0x30 } the_info->si_signo = -1; _Thread_Disable_dispatch(); the_thread->Wait.queue = &_POSIX_signals_Wait_queue; a000ade8: 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; a000adec: e3a03001 mov r3, #1 a000adf0: e5823030 str r3, [r2, #48] ; 0x30 a000adf4: 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 ); a000adf8: e1a00002 mov r0, r2 a000adfc: e59f207c ldr r2, [pc, #124] ; a000ae80 a000ae00: eb000c76 bl a000dfe0 <_Thread_queue_Enqueue_with_handler> _Thread_Enable_dispatch(); a000ae04: eb000b4a bl a000db34 <_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 ); a000ae08: e3a03000 mov r3, #0 <== NOT EXECUTED a000ae0c: e58d3000 str r3, [sp] <== NOT EXECUTED a000ae10: e1a00008 mov r0, r8 <== NOT EXECUTED a000ae14: e5941000 ldr r1, [r4] <== NOT EXECUTED a000ae18: e1a02004 mov r2, r4 <== NOT EXECUTED a000ae1c: eb001608 bl a0010644 <_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) a000ae20: e59f3048 ldr r3, [pc, #72] ; a000ae70 <== NOT EXECUTED a000ae24: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED a000ae28: e5933034 ldr r3, [r3, #52] ; 0x34 <== NOT EXECUTED a000ae2c: e3530004 cmp r3, #4 <== NOT EXECUTED a000ae30: 1a000005 bne a000ae4c <== NOT EXECUTED || !(*set & signo_to_mask( the_info->si_signo )) ) { a000ae34: e5945000 ldr r5, [r4] <== NOT EXECUTED a000ae38: e5963000 ldr r3, [r6] <== NOT EXECUTED a000ae3c: e3a01001 mov r1, #1 <== NOT EXECUTED a000ae40: e2452001 sub r2, r5, #1 <== NOT EXECUTED a000ae44: e0131211 ands r1, r3, r1, lsl r2 <== NOT EXECUTED a000ae48: 1a000005 bne a000ae64 <== NOT EXECUTED errno = _Thread_Executing->Wait.return_code; a000ae4c: eb002071 bl a0013018 <__errno> <== NOT EXECUTED a000ae50: e59f3018 ldr r3, [pc, #24] ; a000ae70 <== NOT EXECUTED a000ae54: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED a000ae58: e5933034 ldr r3, [r3, #52] ; 0x34 <== NOT EXECUTED a000ae5c: e5803000 str r3, [r0] return -1; a000ae60: e3e05000 mvn r5, #0 } return the_info->si_signo; } a000ae64: e1a00005 mov r0, r5 a000ae68: e28dd010 add sp, sp, #16 a000ae6c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} =============================================================================== a000cc30 : int sigwait( const sigset_t *set, int *sig ) { a000cc30: e92d4010 push {r4, lr} a000cc34: e1a04001 mov r4, r1 int status; status = sigtimedwait( set, NULL, NULL ); a000cc38: e3a01000 mov r1, #0 a000cc3c: e1a02001 mov r2, r1 a000cc40: ebffff86 bl a000ca60 if ( status != -1 ) { a000cc44: e3700001 cmn r0, #1 a000cc48: 0a000004 beq a000cc60 if ( sig ) a000cc4c: e3540000 cmp r4, #0 <== NOT EXECUTED a000cc50: 0a000005 beq a000cc6c <== NOT EXECUTED *sig = status; a000cc54: e5840000 str r0, [r4] <== NOT EXECUTED return 0; a000cc58: e3a00000 mov r0, #0 <== NOT EXECUTED a000cc5c: e8bd8010 pop {r4, pc} <== NOT EXECUTED } return errno; a000cc60: eb001fa3 bl a0014af4 <__errno> a000cc64: e5900000 ldr r0, [r0] a000cc68: e8bd8010 pop {r4, pc} status = sigtimedwait( set, NULL, NULL ); if ( status != -1 ) { if ( sig ) *sig = status; return 0; a000cc6c: e1a00004 mov r0, r4 <== NOT EXECUTED } return errno; } a000cc70: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== a0009aa8 : long sysconf( int name ) { if ( name == _SC_CLK_TCK ) a0009aa8: e3500002 cmp r0, #2 */ long sysconf( int name ) { a0009aac: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( name == _SC_CLK_TCK ) a0009ab0: 1a000004 bne a0009ac8 return (TOD_MICROSECONDS_PER_SECOND / a0009ab4: e59f3058 ldr r3, [pc, #88] ; a0009b14 a0009ab8: e59f0058 ldr r0, [pc, #88] ; a0009b18 a0009abc: e593100c ldr r1, [r3, #12] a0009ac0: eb00444f bl a001ac04 <__aeabi_uidiv> a0009ac4: e49df004 pop {pc} ; (ldr pc, [sp], #4) rtems_configuration_get_microseconds_per_tick()); if ( name == _SC_OPEN_MAX ) a0009ac8: e3500004 cmp r0, #4 return rtems_libio_number_iops; a0009acc: 059f3048 ldreq r3, [pc, #72] ; a0009b1c a0009ad0: 05930000 ldreq r0, [r3] { if ( name == _SC_CLK_TCK ) return (TOD_MICROSECONDS_PER_SECOND / rtems_configuration_get_microseconds_per_tick()); if ( name == _SC_OPEN_MAX ) a0009ad4: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) return rtems_libio_number_iops; if ( name == _SC_GETPW_R_SIZE_MAX ) a0009ad8: e3500033 cmp r0, #51 ; 0x33 return 1024; a0009adc: 03a00b01 moveq r0, #1024 ; 0x400 rtems_configuration_get_microseconds_per_tick()); if ( name == _SC_OPEN_MAX ) return rtems_libio_number_iops; if ( name == _SC_GETPW_R_SIZE_MAX ) a0009ae0: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) return 1024; if ( name == _SC_PAGESIZE ) a0009ae4: e3500008 cmp r0, #8 return PAGE_SIZE; a0009ae8: 03a00a01 moveq r0, #4096 ; 0x1000 return rtems_libio_number_iops; if ( name == _SC_GETPW_R_SIZE_MAX ) return 1024; if ( name == _SC_PAGESIZE ) a0009aec: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) return PAGE_SIZE; if ( name == _SC_SYMLOOP_MAX ) a0009af0: e350004f cmp r0, #79 ; 0x4f a0009af4: 0a000004 beq a0009b0c #if defined(__sparc__) if ( name == 515 ) /* Solaris _SC_STACK_PROT */ return 0; #endif rtems_set_errno_and_return_minus_one( EINVAL ); a0009af8: eb002050 bl a0011c40 <__errno> a0009afc: e3a03016 mov r3, #22 a0009b00: e5803000 str r3, [r0] a0009b04: e3e00000 mvn r0, #0 a0009b08: e49df004 pop {pc} ; (ldr pc, [sp], #4) if ( name == _SC_PAGESIZE ) return PAGE_SIZE; if ( name == _SC_SYMLOOP_MAX ) return RTEMS_FILESYSTEM_SYMLOOP_MAX; a0009b0c: e3a00020 mov r0, #32 <== NOT EXECUTED if ( name == 515 ) /* Solaris _SC_STACK_PROT */ return 0; #endif rtems_set_errno_and_return_minus_one( EINVAL ); } a0009b10: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a000a594 : int timer_delete( timer_t timerid ) { a000a594: e92d4031 push {r0, r4, r5, lr} a000a598: e1a01000 mov r1, r0 RTEMS_INLINE_ROUTINE POSIX_Timer_Control *_POSIX_Timer_Get ( timer_t id, Objects_Locations *location ) { return (POSIX_Timer_Control *) a000a59c: e1a0200d mov r2, sp a000a5a0: e59f0058 ldr r0, [pc, #88] ; a000a600 a000a5a4: eb000887 bl a000c7c8 <_Objects_Get> */ POSIX_Timer_Control *ptimer; Objects_Locations location; ptimer = _POSIX_Timer_Get( timerid, &location ); switch ( location ) { a000a5a8: e59d5000 ldr r5, [sp] a000a5ac: e1a04000 mov r4, r0 a000a5b0: e3550000 cmp r5, #0 a000a5b4: 1a00000c bne a000a5ec case OBJECTS_LOCAL: _Objects_Close( &_POSIX_Timer_Information, &ptimer->Object ); a000a5b8: e1a01004 mov r1, r4 <== NOT EXECUTED a000a5bc: e59f003c ldr r0, [pc, #60] ; a000a600 <== NOT EXECUTED a000a5c0: eb00077b bl a000c3b4 <_Objects_Close> <== NOT EXECUTED ptimer->state = POSIX_TIMER_STATE_FREE; a000a5c4: e3a03001 mov r3, #1 <== NOT EXECUTED a000a5c8: e5c4303c strb r3, [r4, #60] ; 0x3c <== NOT EXECUTED (void) _Watchdog_Remove( &ptimer->Timer ); a000a5cc: e2840010 add r0, r4, #16 <== NOT EXECUTED a000a5d0: eb000f81 bl a000e3dc <_Watchdog_Remove> <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _POSIX_Timer_Free ( POSIX_Timer_Control *the_timer ) { _Objects_Free( &_POSIX_Timer_Information, &the_timer->Object ); a000a5d4: e59f0024 ldr r0, [pc, #36] ; a000a600 <== NOT EXECUTED a000a5d8: e1a01004 mov r1, r4 <== NOT EXECUTED a000a5dc: eb000821 bl a000c668 <_Objects_Free> <== NOT EXECUTED _POSIX_Timer_Free( ptimer ); _Thread_Enable_dispatch(); a000a5e0: eb000be7 bl a000d584 <_Thread_Enable_dispatch> <== NOT EXECUTED return 0; a000a5e4: e1a00005 mov r0, r5 <== NOT EXECUTED a000a5e8: ea000003 b a000a5fc <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a000a5ec: eb00221f bl a0012e70 <__errno> a000a5f0: e3a03016 mov r3, #22 a000a5f4: e5803000 str r3, [r0] a000a5f8: e3e00000 mvn r0, #0 } a000a5fc: e8bd8038 pop {r3, r4, r5, pc} =============================================================================== a000b19c : #include int timer_getoverrun( timer_t timerid ) { a000b19c: e92d4011 push {r0, r4, lr} a000b1a0: e1a01000 mov r1, r0 RTEMS_INLINE_ROUTINE POSIX_Timer_Control *_POSIX_Timer_Get ( timer_t id, Objects_Locations *location ) { return (POSIX_Timer_Control *) a000b1a4: e1a0200d mov r2, sp a000b1a8: e59f0034 ldr r0, [pc, #52] ; a000b1e4 a000b1ac: eb00086b bl a000d360 <_Objects_Get> int overrun; POSIX_Timer_Control *ptimer; Objects_Locations location; ptimer = _POSIX_Timer_Get( timerid, &location ); switch ( location ) { a000b1b0: e59d3000 ldr r3, [sp] a000b1b4: e3530000 cmp r3, #0 a000b1b8: 1a000003 bne a000b1cc case OBJECTS_LOCAL: overrun = ptimer->overrun; a000b1bc: e5904068 ldr r4, [r0, #104] ; 0x68 <== NOT EXECUTED ptimer->overrun = 0; a000b1c0: e5803068 str r3, [r0, #104] ; 0x68 <== NOT EXECUTED _Thread_Enable_dispatch(); a000b1c4: eb000bd4 bl a000e11c <_Thread_Enable_dispatch> <== NOT EXECUTED return overrun; a000b1c8: ea000003 b a000b1dc <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a000b1cc: eb00214a bl a00136fc <__errno> a000b1d0: e3a03016 mov r3, #22 a000b1d4: e5803000 str r3, [r0] a000b1d8: e3e04000 mvn r4, #0 } a000b1dc: e1a00004 mov r0, r4 a000b1e0: e8bd8018 pop {r3, r4, pc} =============================================================================== a000b1e8 : int timer_gettime( timer_t timerid, struct itimerspec *value ) { a000b1e8: 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 ) a000b1ec: e2514000 subs r4, r1, #0 int timer_gettime( timer_t timerid, struct itimerspec *value ) { a000b1f0: e1a05000 mov r5, r0 POSIX_Timer_Control *ptimer; Objects_Locations location; struct timespec current_time; Watchdog_Interval left; if ( !value ) a000b1f4: 0a000018 beq a000b25c a000b1f8: e59f1070 ldr r1, [pc, #112] ; a000b270 <== NOT EXECUTED a000b1fc: e1a0000d mov r0, sp <== NOT EXECUTED a000b200: eb0005bd bl a000c8fc <_TOD_Get_with_nanoseconds> <== NOT EXECUTED a000b204: e1a01005 mov r1, r5 <== NOT EXECUTED a000b208: e59f0064 ldr r0, [pc, #100] ; a000b274 <== NOT EXECUTED a000b20c: e28d2008 add r2, sp, #8 <== NOT EXECUTED a000b210: eb000852 bl a000d360 <_Objects_Get> <== NOT EXECUTED /* Reads the current time */ _TOD_Get( ¤t_time ); ptimer = _POSIX_Timer_Get( timerid, &location ); switch ( location ) { a000b214: e59d6008 ldr r6, [sp, #8] <== NOT EXECUTED a000b218: e1a05000 mov r5, r0 <== NOT EXECUTED a000b21c: e3560000 cmp r6, #0 <== NOT EXECUTED a000b220: 1a00000d bne a000b25c <== NOT EXECUTED case OBJECTS_LOCAL: /* Calculates the time left before the timer finishes */ left = (ptimer->Timer.start_time + ptimer->Timer.initial) - /* expire */ a000b224: e59f304c ldr r3, [pc, #76] ; a000b278 <== NOT EXECUTED a000b228: e5952024 ldr r2, [r5, #36] ; 0x24 <== NOT EXECUTED a000b22c: e590001c ldr r0, [r0, #28] <== NOT EXECUTED a000b230: e5933000 ldr r3, [r3] <== NOT EXECUTED _Watchdog_Ticks_since_boot; /* now */ _Timespec_From_ticks( left, &value->it_value ); a000b234: 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 */ a000b238: e0800002 add r0, r0, r2 <== NOT EXECUTED _Watchdog_Ticks_since_boot; /* now */ _Timespec_From_ticks( left, &value->it_value ); a000b23c: e0630000 rsb r0, r3, r0 <== NOT EXECUTED a000b240: eb000e3b bl a000eb34 <_Timespec_From_ticks> <== NOT EXECUTED value->it_interval = ptimer->timer_data.it_interval; a000b244: e2853054 add r3, r5, #84 ; 0x54 <== NOT EXECUTED a000b248: e893000c ldm r3, {r2, r3} <== NOT EXECUTED a000b24c: e884000c stm r4, {r2, r3} <== NOT EXECUTED _Thread_Enable_dispatch(); a000b250: eb000bb1 bl a000e11c <_Thread_Enable_dispatch> <== NOT EXECUTED return 0; a000b254: e1a00006 mov r0, r6 <== NOT EXECUTED a000b258: ea000003 b a000b26c <== NOT EXECUTED #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a000b25c: eb002126 bl a00136fc <__errno> a000b260: e3a03016 mov r3, #22 a000b264: e5803000 str r3, [r0] a000b268: e3e00000 mvn r0, #0 } a000b26c: e8bd807e pop {r1, r2, r3, r4, r5, r6, pc} =============================================================================== a0009cf4 : timer_t timerid, int flags, const struct itimerspec *value, struct itimerspec *ovalue ) { a0009cf4: e92d41f0 push {r4, r5, r6, r7, r8, lr} Objects_Locations location; bool activated; uint32_t initial_period; struct itimerspec normalize; if ( !value ) a0009cf8: e2525000 subs r5, r2, #0 timer_t timerid, int flags, const struct itimerspec *value, struct itimerspec *ovalue ) { a0009cfc: e24dd020 sub sp, sp, #32 a0009d00: e1a08000 mov r8, r0 a0009d04: e1a07001 mov r7, r1 a0009d08: e1a04003 mov r4, r3 Objects_Locations location; bool activated; uint32_t initial_period; struct itimerspec normalize; if ( !value ) a0009d0c: 0a000053 beq a0009e60 /* * 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) ) ) { a0009d10: e2850008 add r0, r5, #8 a0009d14: eb000e5d bl a000d690 <_Timespec_Is_valid> a0009d18: e3500000 cmp r0, #0 a0009d1c: 0a00004f beq a0009e60 rtems_set_errno_and_return_minus_one( EINVAL ); } if ( !_Timespec_Is_valid( &(value->it_interval) ) ) { a0009d20: e1a00005 mov r0, r5 a0009d24: eb000e59 bl a000d690 <_Timespec_Is_valid> a0009d28: e3500000 cmp r0, #0 a0009d2c: 0a00004b beq a0009e60 rtems_set_errno_and_return_minus_one( EINVAL ); } if ( flags != TIMER_ABSTIME && flags != POSIX_TIMER_RELATIVE ) { a0009d30: e3570000 cmp r7, #0 a0009d34: 13570004 cmpne r7, #4 a0009d38: 1a000048 bne a0009e60 rtems_set_errno_and_return_minus_one( EINVAL ); } normalize = *value; a0009d3c: e28d6004 add r6, sp, #4 /* Convert absolute to relative time */ if (flags == TIMER_ABSTIME) { a0009d40: e3570004 cmp r7, #4 if ( flags != TIMER_ABSTIME && flags != POSIX_TIMER_RELATIVE ) { rtems_set_errno_and_return_minus_one( EINVAL ); } normalize = *value; a0009d44: e895000f ldm r5, {r0, r1, r2, r3} a0009d48: e886000f stm r6, {r0, r1, r2, r3} /* Convert absolute to relative time */ if (flags == TIMER_ABSTIME) { a0009d4c: 1a00000b bne a0009d80 struct timespec now; _TOD_Get( &now ); a0009d50: e28d0014 add r0, sp, #20 /* Check for seconds in the past */ if ( _Timespec_Greater_than( &now, &normalize.it_value ) ) a0009d54: e2866008 add r6, r6, #8 normalize = *value; /* Convert absolute to relative time */ if (flags == TIMER_ABSTIME) { struct timespec now; _TOD_Get( &now ); a0009d58: ebffffd0 bl a0009ca0 <_TOD_Get> /* Check for seconds in the past */ if ( _Timespec_Greater_than( &now, &normalize.it_value ) ) a0009d5c: e1a00006 mov r0, r6 a0009d60: e28d1014 add r1, sp, #20 a0009d64: eb000e5a bl a000d6d4 <_Timespec_Less_than> a0009d68: e3500000 cmp r0, #0 a0009d6c: 1a00003b bne a0009e60 rtems_set_errno_and_return_minus_one( EINVAL ); _Timespec_Subtract( &now, &normalize.it_value, &normalize.it_value ); a0009d70: e28d0014 add r0, sp, #20 a0009d74: e1a01006 mov r1, r6 a0009d78: e1a02006 mov r2, r6 a0009d7c: eb000e62 bl a000d70c <_Timespec_Subtract> RTEMS_INLINE_ROUTINE POSIX_Timer_Control *_POSIX_Timer_Get ( timer_t id, Objects_Locations *location ) { return (POSIX_Timer_Control *) a0009d80: e59f00f0 ldr r0, [pc, #240] ; a0009e78 a0009d84: e1a01008 mov r1, r8 a0009d88: e28d201c add r2, sp, #28 a0009d8c: eb000862 bl a000bf1c <_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 ) { a0009d90: e59d301c ldr r3, [sp, #28] a0009d94: e1a06000 mov r6, r0 a0009d98: e3530000 cmp r3, #0 a0009d9c: 1a00002f bne a0009e60 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 ) { a0009da0: e59d300c ldr r3, [sp, #12] a0009da4: e3530000 cmp r3, #0 a0009da8: 1a00000e bne a0009de8 a0009dac: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED a0009db0: e3530000 cmp r3, #0 <== NOT EXECUTED a0009db4: 1a00000b bne a0009de8 <== NOT EXECUTED /* Stop the timer */ (void) _Watchdog_Remove( &ptimer->Timer ); a0009db8: e2800010 add r0, r0, #16 <== NOT EXECUTED a0009dbc: eb000f49 bl a000dae8 <_Watchdog_Remove> <== NOT EXECUTED /* The old data of the timer are returned */ if ( ovalue ) a0009dc0: e3540000 cmp r4, #0 <== NOT EXECUTED a0009dc4: e286c054 add ip, r6, #84 ; 0x54 <== NOT EXECUTED *ovalue = ptimer->timer_data; a0009dc8: 189c000f ldmne ip, {r0, r1, r2, r3} <== NOT EXECUTED a0009dcc: 1884000f stmne r4, {r0, r1, r2, r3} <== NOT EXECUTED /* The new data are set */ ptimer->timer_data = normalize; a0009dd0: e28d3004 add r3, sp, #4 <== NOT EXECUTED a0009dd4: e893000f ldm r3, {r0, r1, r2, r3} <== NOT EXECUTED a0009dd8: e88c000f stm ip, {r0, r1, r2, r3} <== NOT EXECUTED /* Indicates that the timer is created and stopped */ ptimer->state = POSIX_TIMER_STATE_CREATE_STOP; a0009ddc: e3a03004 mov r3, #4 <== NOT EXECUTED a0009de0: e5c6303c strb r3, [r6, #60] ; 0x3c <== NOT EXECUTED a0009de4: ea00001a b a0009e54 <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* Convert from seconds and nanoseconds to ticks */ ptimer->ticks = _Timespec_To_ticks( &value->it_interval ); a0009de8: e1a00005 mov r0, r5 a0009dec: eb000e57 bl a000d750 <_Timespec_To_ticks> initial_period = _Timespec_To_ticks( &normalize.it_value ); a0009df0: e28d5004 add r5, sp, #4 _Thread_Enable_dispatch(); return 0; } /* Convert from seconds and nanoseconds to ticks */ ptimer->ticks = _Timespec_To_ticks( &value->it_interval ); a0009df4: e5860064 str r0, [r6, #100] ; 0x64 initial_period = _Timespec_To_ticks( &normalize.it_value ); a0009df8: e2850008 add r0, r5, #8 a0009dfc: eb000e53 bl a000d750 <_Timespec_To_ticks> activated = _POSIX_Timer_Insert_helper( a0009e00: 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 ); a0009e04: e1a01000 mov r1, r0 activated = _POSIX_Timer_Insert_helper( a0009e08: e5962008 ldr r2, [r6, #8] a0009e0c: e2860010 add r0, r6, #16 a0009e10: e59f3064 ldr r3, [pc, #100] ; a0009e7c a0009e14: eb0016f3 bl a000f9e8 <_POSIX_Timer_Insert_helper> initial_period, ptimer->Object.id, _POSIX_Timer_TSR, ptimer ); if ( !activated ) { a0009e18: e2507000 subs r7, r0, #0 a0009e1c: 1a000002 bne a0009e2c _Thread_Enable_dispatch(); a0009e20: eb000bac bl a000ccd8 <_Thread_Enable_dispatch> <== NOT EXECUTED return 0; a0009e24: e1a00007 mov r0, r7 <== NOT EXECUTED a0009e28: ea000010 b a0009e70 <== NOT EXECUTED /* * The timer has been started and is running. So we return the * old ones in "ovalue" */ if ( ovalue ) a0009e2c: e3540000 cmp r4, #0 a0009e30: e286c054 add ip, r6, #84 ; 0x54 *ovalue = ptimer->timer_data; a0009e34: 189c000f ldmne ip, {r0, r1, r2, r3} a0009e38: 1884000f stmne r4, {r0, r1, r2, r3} ptimer->timer_data = normalize; a0009e3c: e895000f ldm r5, {r0, r1, r2, r3} a0009e40: e88c000f stm ip, {r0, r1, r2, r3} /* Indicate that the time is running */ ptimer->state = POSIX_TIMER_STATE_CREATE_RUN; a0009e44: e3a03003 mov r3, #3 a0009e48: e5c6303c strb r3, [r6, #60] ; 0x3c _TOD_Get( &ptimer->time ); a0009e4c: e286006c add r0, r6, #108 ; 0x6c a0009e50: ebffff92 bl a0009ca0 <_TOD_Get> _Thread_Enable_dispatch(); a0009e54: eb000b9f bl a000ccd8 <_Thread_Enable_dispatch> return 0; a0009e58: e3a00000 mov r0, #0 a0009e5c: ea000003 b a0009e70 #endif case OBJECTS_ERROR: break; } rtems_set_errno_and_return_minus_one( EINVAL ); a0009e60: eb0020b8 bl a0012148 <__errno> <== NOT EXECUTED a0009e64: e3a03016 mov r3, #22 <== NOT EXECUTED a0009e68: e5803000 str r3, [r0] <== NOT EXECUTED a0009e6c: e3e00000 mvn r0, #0 <== NOT EXECUTED } a0009e70: e28dd020 add sp, sp, #32 a0009e74: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} =============================================================================== a0009e34 : useconds_t ualarm( useconds_t useconds, useconds_t interval ) { a0009e34: e92d4073 push {r0, r1, r4, r5, r6, lr} <== NOT EXECUTED /* * Initialize the timer used to implement alarm(). */ if ( !the_timer->routine ) { a0009e38: e59f60cc ldr r6, [pc, #204] ; a0009f0c <== NOT EXECUTED useconds_t ualarm( useconds_t useconds, useconds_t interval ) { a0009e3c: e1a05000 mov r5, r0 <== NOT EXECUTED /* * Initialize the timer used to implement alarm(). */ if ( !the_timer->routine ) { a0009e40: e596401c ldr r4, [r6, #28] <== NOT EXECUTED a0009e44: e3540000 cmp r4, #0 <== NOT EXECUTED a0009e48: 1a000005 bne a0009e64 <== NOT EXECUTED Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a0009e4c: e59f30bc ldr r3, [pc, #188] ; a0009f10 <== NOT EXECUTED Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; a0009e50: e5864008 str r4, [r6, #8] <== NOT EXECUTED the_watchdog->routine = routine; the_watchdog->id = id; a0009e54: e5864020 str r4, [r6, #32] <== NOT EXECUTED Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; a0009e58: e586301c str r3, [r6, #28] <== NOT EXECUTED the_watchdog->id = id; the_watchdog->user_data = user_data; a0009e5c: e5864024 str r4, [r6, #36] ; 0x24 <== NOT EXECUTED a0009e60: ea000013 b a0009eb4 <== NOT EXECUTED _Watchdog_Initialize( the_timer, _POSIX_signals_Ualarm_TSR, 0, NULL ); } else { Watchdog_States state; state = _Watchdog_Remove( the_timer ); a0009e64: e1a00006 mov r0, r6 <== NOT EXECUTED a0009e68: eb000ed0 bl a000d9b0 <_Watchdog_Remove> <== NOT EXECUTED if ( (state == WATCHDOG_ACTIVE) || (state == WATCHDOG_REMOVE_IT) ) { a0009e6c: e2400002 sub r0, r0, #2 <== NOT EXECUTED a0009e70: e3500001 cmp r0, #1 <== NOT EXECUTED useconds_t ualarm( useconds_t useconds, useconds_t interval ) { useconds_t remaining = 0; a0009e74: 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) ) { a0009e78: 8a00000d bhi a0009eb4 <== 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); a0009e7c: e596300c ldr r3, [r6, #12] <== NOT EXECUTED a0009e80: e5960014 ldr r0, [r6, #20] <== NOT EXECUTED /* remaining is now in ticks */ _Timespec_From_ticks( ticks, &tp ); a0009e84: e1a0100d mov r1, sp <== NOT EXECUTED remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND; a0009e88: e59f4084 ldr r4, [pc, #132] ; a0009f14 <== 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); a0009e8c: e0800003 add r0, r0, r3 <== NOT EXECUTED a0009e90: e5963018 ldr r3, [r6, #24] <== NOT EXECUTED /* remaining is now in ticks */ _Timespec_From_ticks( ticks, &tp ); a0009e94: e0630000 rsb r0, r3, r0 <== NOT EXECUTED a0009e98: eb000da4 bl a000d530 <_Timespec_From_ticks> <== NOT EXECUTED remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND; a0009e9c: e59d3000 ldr r3, [sp] <== NOT EXECUTED remaining += tp.tv_nsec / 1000; a0009ea0: e59d0004 ldr r0, [sp, #4] <== NOT EXECUTED a0009ea4: 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; a0009ea8: e0040493 mul r4, r3, r4 <== NOT EXECUTED remaining += tp.tv_nsec / 1000; a0009eac: eb004a5d bl a001c828 <__aeabi_idiv> <== NOT EXECUTED a0009eb0: 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 ) { a0009eb4: e3550000 cmp r5, #0 <== NOT EXECUTED a0009eb8: 0a000011 beq a0009f04 <== NOT EXECUTED Watchdog_Interval ticks; tp.tv_sec = useconds / TOD_MICROSECONDS_PER_SECOND; a0009ebc: e59f1050 ldr r1, [pc, #80] ; a0009f14 <== NOT EXECUTED a0009ec0: e1a00005 mov r0, r5 <== NOT EXECUTED a0009ec4: eb004a11 bl a001c710 <__aeabi_uidiv> <== NOT EXECUTED tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000; a0009ec8: e59f1044 ldr r1, [pc, #68] ; a0009f14 <== 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; a0009ecc: e58d0000 str r0, [sp] <== NOT EXECUTED tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000; a0009ed0: e1a00005 mov r0, r5 <== NOT EXECUTED a0009ed4: eb004aa5 bl a001c970 <__umodsi3> <== NOT EXECUTED a0009ed8: e3a03ffa mov r3, #1000 ; 0x3e8 <== NOT EXECUTED a0009edc: e0030390 mul r3, r0, r3 <== NOT EXECUTED ticks = _Timespec_To_ticks( &tp ); a0009ee0: 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; a0009ee4: e58d3004 str r3, [sp, #4] <== NOT EXECUTED ticks = _Timespec_To_ticks( &tp ); a0009ee8: eb000da2 bl a000d578 <_Timespec_To_ticks> <== NOT EXECUTED if ( ticks == 0 ) ticks = 1; _Watchdog_Insert_ticks( the_timer, _Timespec_To_ticks( &tp ) ); a0009eec: e1a0000d mov r0, sp <== NOT EXECUTED a0009ef0: eb000da0 bl a000d578 <_Timespec_To_ticks> <== NOT EXECUTED Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; a0009ef4: e59f1010 ldr r1, [pc, #16] ; a0009f0c <== NOT EXECUTED a0009ef8: e581000c str r0, [r1, #12] <== NOT EXECUTED _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); a0009efc: e59f0014 ldr r0, [pc, #20] ; a0009f18 <== NOT EXECUTED a0009f00: eb000e53 bl a000d854 <_Watchdog_Insert> <== NOT EXECUTED } return remaining; } a0009f04: e1a00004 mov r0, r4 <== NOT EXECUTED a0009f08: e8bd807c pop {r2, r3, r4, r5, r6, pc} <== NOT EXECUTED =============================================================================== a0009e68 : #include pid_t vfork(void) { return -1; } a0009e68: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009e6c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a0009e70 : #include int wait( int *stat_loc ) { a0009e70: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009e74: eb002051 bl a0011fc0 <__errno> <== NOT EXECUTED a0009e78: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009e7c: e5803000 str r3, [r0] <== NOT EXECUTED } a0009e80: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009e84: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a0009e88 : int waitpid( pid_t pid, int *stat_loc, int options ) { a0009e88: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOSYS ); a0009e8c: eb00204b bl a0011fc0 <__errno> <== NOT EXECUTED a0009e90: e3a03058 mov r3, #88 ; 0x58 <== NOT EXECUTED a0009e94: e5803000 str r3, [r0] <== NOT EXECUTED } a0009e98: e3e00000 mvn r0, #0 <== NOT EXECUTED a0009e9c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED