ffc09a18 <_CORE_semaphore_Surrender>: CORE_semaphore_Status _CORE_semaphore_Surrender( CORE_semaphore_Control *the_semaphore, Objects_Id id, CORE_semaphore_API_mp_support_callout api_semaphore_mp_support ) { ffc09a18: 94 21 ff f0 stwu r1,-16(r1) ffc09a1c: 7c 08 02 a6 mflr r0 ffc09a20: 93 e1 00 0c stw r31,12(r1) ffc09a24: 7c 7f 1b 78 mr r31,r3 ffc09a28: 90 01 00 14 stw r0,20(r1) ISR_Level level; CORE_semaphore_Status status; status = CORE_SEMAPHORE_STATUS_SUCCESSFUL; if ( (the_thread = _Thread_queue_Dequeue(&the_semaphore->Wait_queue)) ) { ffc09a2c: 48 00 1c 11 bl ffc0b63c <_Thread_queue_Dequeue> ffc09a30: 2f 83 00 00 cmpwi cr7,r3,0 ffc09a34: 38 60 00 00 li r3,0 ffc09a38: 41 9e 00 18 beq- cr7,ffc09a50 <_CORE_semaphore_Surrender+0x38> status = CORE_SEMAPHORE_MAXIMUM_COUNT_EXCEEDED; _ISR_Enable( level ); } return status; } ffc09a3c: 80 01 00 14 lwz r0,20(r1) ffc09a40: 83 e1 00 0c lwz r31,12(r1) ffc09a44: 38 21 00 10 addi r1,r1,16 ffc09a48: 7c 08 03 a6 mtlr r0 ffc09a4c: 4e 80 00 20 blr static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc09a50: 7c 00 00 a6 mfmsr r0 ffc09a54: 7d 30 42 a6 mfsprg r9,0 ffc09a58: 7c 09 48 78 andc r9,r0,r9 ffc09a5c: 7d 20 01 24 mtmsr r9 (*api_semaphore_mp_support) ( the_thread, id ); #endif } else { _ISR_Disable( level ); if ( the_semaphore->count < the_semaphore->Attributes.maximum_count ) ffc09a60: 81 3f 00 48 lwz r9,72(r31) ffc09a64: 38 60 00 04 li r3,4 ffc09a68: 81 7f 00 40 lwz r11,64(r31) ffc09a6c: 7f 89 58 40 cmplw cr7,r9,r11 ffc09a70: 41 9c 00 1c blt- cr7,ffc09a8c <_CORE_semaphore_Surrender+0x74> return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc09a74: 7c 00 01 24 mtmsr r0 <== NOT EXECUTED status = CORE_SEMAPHORE_MAXIMUM_COUNT_EXCEEDED; _ISR_Enable( level ); } return status; } ffc09a78: 80 01 00 14 lwz r0,20(r1) ffc09a7c: 83 e1 00 0c lwz r31,12(r1) ffc09a80: 38 21 00 10 addi r1,r1,16 ffc09a84: 7c 08 03 a6 mtlr r0 ffc09a88: 4e 80 00 20 blr #endif } else { _ISR_Disable( level ); if ( the_semaphore->count < the_semaphore->Attributes.maximum_count ) the_semaphore->count += 1; ffc09a8c: 39 29 00 01 addi r9,r9,1 ffc09a90: 91 3f 00 48 stw r9,72(r31) ffc09a94: 38 60 00 00 li r3,0 ffc09a98: 7c 00 01 24 mtmsr r0 ffc09a9c: 4b ff ff dc b ffc09a78 <_CORE_semaphore_Surrender+0x60> ffc0abd8 <_Heap_Walk>: uintptr_t const page_size = heap->page_size; uintptr_t const min_block_size = heap->min_block_size; Heap_Block *const last_block = heap->last_block; Heap_Block *block = heap->first_block; Heap_Walk_printer printer = dump ? _Heap_Walk_print : _Heap_Walk_print_nothing; ffc0abd8: 2f 85 00 00 cmpwi cr7,r5,0 bool _Heap_Walk( Heap_Control *heap, int source, bool dump ) { ffc0abdc: 94 21 ff 98 stwu r1,-104(r1) ffc0abe0: 7c 08 02 a6 mflr r0 ffc0abe4: 93 21 00 4c stw r25,76(r1) ffc0abe8: 90 01 00 6c stw r0,108(r1) ffc0abec: 93 41 00 50 stw r26,80(r1) ffc0abf0: 93 61 00 54 stw r27,84(r1) ffc0abf4: 93 81 00 58 stw r28,88(r1) ffc0abf8: 7c 9c 23 78 mr r28,r4 ffc0abfc: 93 c1 00 60 stw r30,96(r1) ffc0ac00: 93 e1 00 64 stw r31,100(r1) ffc0ac04: 7c 7f 1b 78 mr r31,r3 ffc0ac08: 91 c1 00 20 stw r14,32(r1) ffc0ac0c: 91 e1 00 24 stw r15,36(r1) ffc0ac10: 92 01 00 28 stw r16,40(r1) ffc0ac14: 92 21 00 2c stw r17,44(r1) ffc0ac18: 92 41 00 30 stw r18,48(r1) ffc0ac1c: 92 61 00 34 stw r19,52(r1) ffc0ac20: 92 81 00 38 stw r20,56(r1) ffc0ac24: 92 a1 00 3c stw r21,60(r1) ffc0ac28: 92 c1 00 40 stw r22,64(r1) ffc0ac2c: 92 e1 00 44 stw r23,68(r1) ffc0ac30: 93 01 00 48 stw r24,72(r1) ffc0ac34: 93 a1 00 5c stw r29,92(r1) uintptr_t const page_size = heap->page_size; ffc0ac38: 83 63 00 10 lwz r27,16(r3) uintptr_t const min_block_size = heap->min_block_size; ffc0ac3c: 83 43 00 14 lwz r26,20(r3) Heap_Block *const last_block = heap->last_block; ffc0ac40: 83 23 00 24 lwz r25,36(r3) Heap_Block *block = heap->first_block; ffc0ac44: 83 c3 00 20 lwz r30,32(r3) Heap_Walk_printer printer = dump ? _Heap_Walk_print : _Heap_Walk_print_nothing; ffc0ac48: 40 9e 00 7c bne- cr7,ffc0acc4 <_Heap_Walk+0xec> ffc0ac4c: 3d 20 ff c1 lis r9,-63 ffc0ac50: 39 29 ab d4 addi r9,r9,-21548 ffc0ac54: 91 21 00 18 stw r9,24(r1) if ( !_System_state_Is_up( _System_state_Get() ) ) { ffc0ac58: 3d 20 00 00 lis r9,0 ffc0ac5c: 80 09 27 d4 lwz r0,10196(r9) ffc0ac60: 2f 80 00 03 cmpwi cr7,r0,3 ffc0ac64: 41 9e 00 7c beq- cr7,ffc0ace0 <_Heap_Walk+0x108> if ( !_Heap_Walk_check_control( source, printer, heap ) ) { return false; } while ( block != last_block ) { ffc0ac68: 38 60 00 01 li r3,1 block = next_block; } return true; } ffc0ac6c: 80 01 00 6c lwz r0,108(r1) ffc0ac70: 81 c1 00 20 lwz r14,32(r1) ffc0ac74: 7c 08 03 a6 mtlr r0 ffc0ac78: 81 e1 00 24 lwz r15,36(r1) ffc0ac7c: 82 01 00 28 lwz r16,40(r1) ffc0ac80: 82 21 00 2c lwz r17,44(r1) ffc0ac84: 82 41 00 30 lwz r18,48(r1) ffc0ac88: 82 61 00 34 lwz r19,52(r1) ffc0ac8c: 82 81 00 38 lwz r20,56(r1) ffc0ac90: 82 a1 00 3c lwz r21,60(r1) ffc0ac94: 82 c1 00 40 lwz r22,64(r1) ffc0ac98: 82 e1 00 44 lwz r23,68(r1) ffc0ac9c: 83 01 00 48 lwz r24,72(r1) ffc0aca0: 83 21 00 4c lwz r25,76(r1) ffc0aca4: 83 41 00 50 lwz r26,80(r1) ffc0aca8: 83 61 00 54 lwz r27,84(r1) ffc0acac: 83 81 00 58 lwz r28,88(r1) ffc0acb0: 83 a1 00 5c lwz r29,92(r1) ffc0acb4: 83 c1 00 60 lwz r30,96(r1) ffc0acb8: 83 e1 00 64 lwz r31,100(r1) ffc0acbc: 38 21 00 68 addi r1,r1,104 ffc0acc0: 4e 80 00 20 blr uintptr_t const page_size = heap->page_size; uintptr_t const min_block_size = heap->min_block_size; Heap_Block *const last_block = heap->last_block; Heap_Block *block = heap->first_block; Heap_Walk_printer printer = dump ? _Heap_Walk_print : _Heap_Walk_print_nothing; ffc0acc4: 3d 20 ff c1 lis r9,-63 ffc0acc8: 39 29 b1 f0 addi r9,r9,-19984 ffc0accc: 91 21 00 18 stw r9,24(r1) if ( !_System_state_Is_up( _System_state_Get() ) ) { ffc0acd0: 3d 20 00 00 lis r9,0 ffc0acd4: 80 09 27 d4 lwz r0,10196(r9) ffc0acd8: 2f 80 00 03 cmpwi cr7,r0,3 ffc0acdc: 40 9e ff 8c bne+ cr7,ffc0ac68 <_Heap_Walk+0x90> 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)( ffc0ace0: 80 1f 00 0c lwz r0,12(r31) ffc0ace4: 3c a0 ff c2 lis r5,-62 ffc0ace8: 81 1f 00 18 lwz r8,24(r31) ffc0acec: 38 a5 0b e0 addi r5,r5,3040 ffc0acf0: 81 3f 00 1c lwz r9,28(r31) ffc0acf4: 7f 83 e3 78 mr r3,r28 ffc0acf8: 81 7f 00 08 lwz r11,8(r31) ffc0acfc: 38 80 00 00 li r4,0 ffc0ad00: 90 01 00 10 stw r0,16(r1) ffc0ad04: 7f 66 db 78 mr r6,r27 ffc0ad08: 7f 47 d3 78 mr r7,r26 ffc0ad0c: 80 01 00 18 lwz r0,24(r1) ffc0ad10: 7f ca f3 78 mr r10,r30 ffc0ad14: 91 61 00 0c stw r11,12(r1) ffc0ad18: 7c 09 03 a6 mtctr r0 ffc0ad1c: 93 21 00 08 stw r25,8(r1) ffc0ad20: 4c c6 31 82 crclr 4*cr1+eq ffc0ad24: 4e 80 04 21 bctrl heap->area_begin, heap->area_end, first_block, last_block, first_free_block, last_free_block ); if ( page_size == 0 ) { ffc0ad28: 2f 9b 00 00 cmpwi cr7,r27,0 ffc0ad2c: 41 9e 00 d0 beq- cr7,ffc0adfc <_Heap_Walk+0x224> (*printer)( source, true, "page size is zero\n" ); return false; } if ( !_Addresses_Is_aligned( (void *) page_size ) ) { ffc0ad30: 73 67 00 07 andi. r7,r27,7 ffc0ad34: 40 82 00 f0 bne- ffc0ae24 <_Heap_Walk+0x24c> ); return false; } if ( !_Heap_Is_aligned( min_block_size, page_size ) ) { ffc0ad38: 7c 1a db 96 divwu r0,r26,r27 ffc0ad3c: 7c 00 d9 d6 mullw r0,r0,r27 ffc0ad40: 7f 9a 00 00 cmpw cr7,r26,r0 ffc0ad44: 40 9e 00 f4 bne- cr7,ffc0ae38 <_Heap_Walk+0x260> ); return false; } if ( ffc0ad48: 38 1e 00 08 addi r0,r30,8 ffc0ad4c: 7d 20 db 96 divwu r9,r0,r27 ffc0ad50: 7d 29 d9 d6 mullw r9,r9,r27 ffc0ad54: 7f 80 48 00 cmpw cr7,r0,r9 ffc0ad58: 40 9e 00 f4 bne- cr7,ffc0ae4c <_Heap_Walk+0x274> 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; ffc0ad5c: 83 1e 00 04 lwz r24,4(r30) ); return false; } if ( !_Heap_Is_prev_used( first_block ) ) { ffc0ad60: 73 00 00 01 andi. r0,r24,1 ffc0ad64: 41 82 00 fc beq- ffc0ae60 <_Heap_Walk+0x288> ); return false; } if ( first_block->prev_size != page_size ) { ffc0ad68: 80 de 00 00 lwz r6,0(r30) ffc0ad6c: 7f 9b 30 00 cmpw cr7,r27,r6 ffc0ad70: 40 9e 00 60 bne- cr7,ffc0add0 <_Heap_Walk+0x1f8> ); return false; } if ( _Heap_Is_free( last_block ) ) { ffc0ad74: 81 39 00 04 lwz r9,4(r25) ffc0ad78: 55 29 00 3c rlwinm r9,r9,0,0,30 ffc0ad7c: 7d 39 4a 14 add r9,r25,r9 ffc0ad80: 81 29 00 04 lwz r9,4(r9) ffc0ad84: 71 27 00 01 andi. r7,r9,1 ffc0ad88: 41 82 04 28 beq- ffc0b1b0 <_Heap_Walk+0x5d8> return &heap->free_list; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap ) { return _Heap_Free_list_head(heap)->next; ffc0ad8c: 80 df 00 08 lwz r6,8(r31) int source, Heap_Walk_printer printer, Heap_Control *heap ) { uintptr_t const page_size = heap->page_size; ffc0ad90: 80 bf 00 10 lwz r5,16(r31) 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 ) { ffc0ad94: 7f 9f 30 00 cmpw cr7,r31,r6 ffc0ad98: 41 9e 01 78 beq- cr7,ffc0af10 <_Heap_Walk+0x338> 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; ffc0ad9c: 81 5f 00 20 lwz r10,32(r31) RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap( const Heap_Control *heap, const Heap_Block *block ) { return (uintptr_t) block >= (uintptr_t) heap->first_block ffc0ada0: 7f 8a 30 40 cmplw cr7,r10,r6 ffc0ada4: 40 9d 00 cc ble- cr7,ffc0ae70 <_Heap_Walk+0x298> if ( !_Heap_Is_block_in_heap( heap, free_block ) ) { (*printer)( ffc0ada8: 3c a0 ff c2 lis r5,-62 ffc0adac: 7f 83 e3 78 mr r3,r28 ffc0adb0: 38 a5 0d 74 addi r5,r5,3444 return false; } if ( !_Heap_Walk_is_in_free_list( heap, block ) ) { (*printer)( ffc0adb4: 80 01 00 18 lwz r0,24(r1) ffc0adb8: 38 80 00 01 li r4,1 ffc0adbc: 7c 09 03 a6 mtctr r0 ffc0adc0: 4c c6 31 82 crclr 4*cr1+eq ffc0adc4: 4e 80 04 21 bctrl ffc0adc8: 38 60 00 00 li r3,0 ffc0adcc: 4b ff fe a0 b ffc0ac6c <_Heap_Walk+0x94> return false; } if ( first_block->prev_size != page_size ) { (*printer)( ffc0add0: 3c a0 ff c2 lis r5,-62 ffc0add4: 7f 83 e3 78 mr r3,r28 ffc0add8: 38 a5 0d 30 addi r5,r5,3376 ffc0addc: 7f 67 db 78 mr r7,r27 return false; } if ( next_block_begin <= block_begin ) { (*printer)( ffc0ade0: 80 01 00 18 lwz r0,24(r1) ffc0ade4: 38 80 00 01 li r4,1 ffc0ade8: 7c 09 03 a6 mtctr r0 ffc0adec: 4c c6 31 82 crclr 4*cr1+eq ffc0adf0: 4e 80 04 21 bctrl ffc0adf4: 38 60 00 00 li r3,0 "block 0x%08x: next block 0x%08x is not a successor\n", block, next_block ); return false; ffc0adf8: 4b ff fe 74 b ffc0ac6c <_Heap_Walk+0x94> first_block, last_block, first_free_block, last_free_block ); if ( page_size == 0 ) { (*printer)( source, true, "page size is zero\n" ); ffc0adfc: 3c a0 ff c2 lis r5,-62 ffc0ae00: 7f 83 e3 78 mr r3,r28 ffc0ae04: 38 a5 0c 74 addi r5,r5,3188 return false; } if ( !_Heap_Is_prev_used( first_block ) ) { (*printer)( ffc0ae08: 80 01 00 18 lwz r0,24(r1) ffc0ae0c: 38 80 00 01 li r4,1 ffc0ae10: 7c 09 03 a6 mtctr r0 ffc0ae14: 4c c6 31 82 crclr 4*cr1+eq ffc0ae18: 4e 80 04 21 bctrl ffc0ae1c: 38 60 00 00 li r3,0 ffc0ae20: 4b ff fe 4c b ffc0ac6c <_Heap_Walk+0x94> return false; } if ( !_Addresses_Is_aligned( (void *) page_size ) ) { (*printer)( ffc0ae24: 3c a0 ff c2 lis r5,-62 ffc0ae28: 7f 83 e3 78 mr r3,r28 ffc0ae2c: 38 a5 0c 88 addi r5,r5,3208 ffc0ae30: 7f 66 db 78 mr r6,r27 ffc0ae34: 4b ff ff 80 b ffc0adb4 <_Heap_Walk+0x1dc> return false; } if ( !_Heap_Is_aligned( min_block_size, page_size ) ) { (*printer)( ffc0ae38: 3c a0 ff c2 lis r5,-62 ffc0ae3c: 7f 83 e3 78 mr r3,r28 ffc0ae40: 38 a5 0c a8 addi r5,r5,3240 ffc0ae44: 7f 46 d3 78 mr r6,r26 ffc0ae48: 4b ff ff 6c b ffc0adb4 <_Heap_Walk+0x1dc> } if ( !_Heap_Is_aligned( _Heap_Alloc_area_of_block( first_block ), page_size ) ) { (*printer)( ffc0ae4c: 3c a0 ff c2 lis r5,-62 ffc0ae50: 7f 83 e3 78 mr r3,r28 ffc0ae54: 38 a5 0c cc addi r5,r5,3276 ffc0ae58: 7f c6 f3 78 mr r6,r30 ffc0ae5c: 4b ff ff 58 b ffc0adb4 <_Heap_Walk+0x1dc> return false; } if ( !_Heap_Is_prev_used( first_block ) ) { (*printer)( ffc0ae60: 3c a0 ff c2 lis r5,-62 ffc0ae64: 7f 83 e3 78 mr r3,r28 ffc0ae68: 38 a5 0d 00 addi r5,r5,3328 ffc0ae6c: 4b ff ff 9c b ffc0ae08 <_Heap_Walk+0x230> && (uintptr_t) block <= (uintptr_t) heap->last_block; ffc0ae70: 81 1f 00 24 lwz r8,36(r31) RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap( const Heap_Control *heap, const Heap_Block *block ) { return (uintptr_t) block >= (uintptr_t) heap->first_block ffc0ae74: 7f 88 30 40 cmplw cr7,r8,r6 ffc0ae78: 41 bc ff 30 blt- cr7,ffc0ada8 <_Heap_Walk+0x1d0> ); return false; } if ( ffc0ae7c: 39 26 00 08 addi r9,r6,8 ffc0ae80: 7d 69 2b 96 divwu r11,r9,r5 ffc0ae84: 7d 6b 29 d6 mullw r11,r11,r5 ffc0ae88: 7f 89 58 00 cmpw cr7,r9,r11 ffc0ae8c: 40 9e 03 34 bne- cr7,ffc0b1c0 <_Heap_Walk+0x5e8> ); return false; } if ( _Heap_Is_used( free_block ) ) { ffc0ae90: 81 26 00 04 lwz r9,4(r6) ffc0ae94: 55 29 00 3c rlwinm r9,r9,0,0,30 ffc0ae98: 7d 26 4a 14 add r9,r6,r9 ffc0ae9c: 81 29 00 04 lwz r9,4(r9) ffc0aea0: 71 27 00 01 andi. r7,r9,1 ffc0aea4: 40 82 03 3c bne- ffc0b1e0 <_Heap_Walk+0x608> ); return false; } if ( free_block->prev != prev_block ) { ffc0aea8: 80 e6 00 0c lwz r7,12(r6) ffc0aeac: 7f 9f 38 00 cmpw cr7,r31,r7 ffc0aeb0: 41 be 00 48 beq+ cr7,ffc0aef8 <_Heap_Walk+0x320> ffc0aeb4: 48 00 03 1c b ffc0b1d0 <_Heap_Walk+0x5f8> <== NOT EXECUTED ffc0aeb8: 41 b8 fe f0 blt- cr6,ffc0ada8 <_Heap_Walk+0x1d0> ); return false; } if ( ffc0aebc: 39 66 00 08 addi r11,r6,8 ffc0aec0: 41 a4 fe e8 blt- cr1,ffc0ada8 <_Heap_Walk+0x1d0> ffc0aec4: 7c eb 2b 96 divwu r7,r11,r5 ffc0aec8: 7c e7 29 d6 mullw r7,r7,r5 ffc0aecc: 7f 8b 38 00 cmpw cr7,r11,r7 ffc0aed0: 40 9e 02 f0 bne- cr7,ffc0b1c0 <_Heap_Walk+0x5e8> ); return false; } if ( _Heap_Is_used( free_block ) ) { ffc0aed4: 81 66 00 04 lwz r11,4(r6) ffc0aed8: 55 6b 00 3c rlwinm r11,r11,0,0,30 ffc0aedc: 7d 6b 32 14 add r11,r11,r6 ffc0aee0: 81 6b 00 04 lwz r11,4(r11) ffc0aee4: 71 67 00 01 andi. r7,r11,1 ffc0aee8: 40 82 02 f8 bne- ffc0b1e0 <_Heap_Walk+0x608> ); return false; } if ( free_block->prev != prev_block ) { ffc0aeec: 80 e6 00 0c lwz r7,12(r6) ffc0aef0: 7f 87 48 00 cmpw cr7,r7,r9 ffc0aef4: 40 9e 02 dc bne- cr7,ffc0b1d0 <_Heap_Walk+0x5f8> (*printer)( ffc0aef8: 7c c9 33 78 mr r9,r6 return false; } prev_block = free_block; free_block = free_block->next; ffc0aefc: 80 c6 00 08 lwz r6,8(r6) 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 ) { ffc0af00: 7f 9f 30 00 cmpw cr7,r31,r6 ffc0af04: 7f 06 50 40 cmplw cr6,r6,r10 ffc0af08: 7c 88 30 40 cmplw cr1,r8,r6 ffc0af0c: 40 9e ff ac bne+ cr7,ffc0aeb8 <_Heap_Walk+0x2e0> if ( !_Heap_Walk_check_control( source, printer, heap ) ) { return false; } while ( block != last_block ) { ffc0af10: 7f 99 f0 00 cmpw cr7,r25,r30 ffc0af14: 41 be fd 54 beq- cr7,ffc0ac68 <_Heap_Walk+0x90> 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; if ( prev_used ) { (*printer)( ffc0af18: 3e 60 ff c2 lis r19,-62 "block 0x%08x: size %u\n", block, block_size ); } else { (*printer)( ffc0af1c: 3e 80 ff c2 lis r20,-62 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)( ffc0af20: 3e 40 ff c2 lis r18,-62 " (= first)" : (block->prev == free_list_head ? " (= head)" : ""), block->next, block->next == last_free_block ? " (= last)" : (block->next == free_list_tail ? " (= tail)" : "") ffc0af24: 3d e0 ff c2 lis r15,-62 ffc0af28: 3e a0 ff c2 lis r21,-62 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)( ffc0af2c: 3e 20 ff c2 lis r17,-62 "block 0x%08x: prev 0x%08x%s, next 0x%08x%s\n", block, block->prev, block->prev == first_free_block ? " (= first)" : (block->prev == free_list_head ? " (= head)" : ""), ffc0af30: 3d c0 ff c2 lis r14,-62 return &heap->free_list; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap ) { return _Heap_Free_list_head(heap)->next; ffc0af34: 3e 00 ff c2 lis r16,-62 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; if ( prev_used ) { (*printer)( ffc0af38: 3a 73 0e 14 addi r19,r19,3604 "block 0x%08x: size %u\n", block, block_size ); } else { (*printer)( ffc0af3c: 3a 94 0e 2c addi r20,r20,3628 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)( ffc0af40: 3a 52 0f 44 addi r18,r18,3908 " (= first)" : (block->prev == free_list_head ? " (= head)" : ""), block->next, block->next == last_free_block ? " (= last)" : (block->next == free_list_tail ? " (= tail)" : "") ffc0af44: 39 ef 0f 38 addi r15,r15,3896 ffc0af48: 3a b5 0f a8 addi r21,r21,4008 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)( ffc0af4c: 3a 31 0f 2c addi r17,r17,3884 "block 0x%08x: prev 0x%08x%s, next 0x%08x%s\n", block, block->prev, block->prev == first_free_block ? " (= first)" : (block->prev == free_list_head ? " (= head)" : ""), ffc0af50: 39 ce 0f 20 addi r14,r14,3872 ffc0af54: 3a 10 0f 14 addi r16,r16,3860 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; if ( prev_used ) { ffc0af58: 2f 80 00 00 cmpwi cr7,r0,0 - 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; ffc0af5c: 57 18 00 3c rlwinm r24,r24,0,0,30 RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at( const Heap_Block *block, uintptr_t offset ) { return (Heap_Block *) ((uintptr_t) block + offset); ffc0af60: 7f b8 f2 14 add r29,r24,r30 ffc0af64: 41 9e 00 4c beq- cr7,ffc0afb0 <_Heap_Walk+0x3d8> (*printer)( ffc0af68: 80 01 00 18 lwz r0,24(r1) ffc0af6c: 7f 83 e3 78 mr r3,r28 ffc0af70: 38 80 00 00 li r4,0 ffc0af74: 7c 09 03 a6 mtctr r0 ffc0af78: 7e 65 9b 78 mr r5,r19 ffc0af7c: 7f c6 f3 78 mr r6,r30 ffc0af80: 7f 07 c3 78 mr r7,r24 ffc0af84: 4c c6 31 82 crclr 4*cr1+eq ffc0af88: 4e 80 04 21 bctrl RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap( const Heap_Control *heap, const Heap_Block *block ) { return (uintptr_t) block >= (uintptr_t) heap->first_block ffc0af8c: 80 1f 00 20 lwz r0,32(r31) ffc0af90: 7f 80 e8 40 cmplw cr7,r0,r29 ffc0af94: 40 9d 00 50 ble- cr7,ffc0afe4 <_Heap_Walk+0x40c> block->prev_size ); } if ( !_Heap_Is_block_in_heap( heap, next_block ) ) { (*printer)( ffc0af98: 3c a0 ff c2 lis r5,-62 ffc0af9c: 7f 83 e3 78 mr r3,r28 ffc0afa0: 38 a5 0e 54 addi r5,r5,3668 ffc0afa4: 7f c6 f3 78 mr r6,r30 ffc0afa8: 7f a7 eb 78 mr r7,r29 ffc0afac: 4b ff fe 34 b ffc0ade0 <_Heap_Walk+0x208> "block 0x%08x: size %u\n", block, block_size ); } else { (*printer)( ffc0afb0: 80 01 00 18 lwz r0,24(r1) ffc0afb4: 7f 83 e3 78 mr r3,r28 ffc0afb8: 38 80 00 00 li r4,0 ffc0afbc: 81 1e 00 00 lwz r8,0(r30) ffc0afc0: 7c 09 03 a6 mtctr r0 ffc0afc4: 7e 85 a3 78 mr r5,r20 ffc0afc8: 7f c6 f3 78 mr r6,r30 ffc0afcc: 7f 07 c3 78 mr r7,r24 ffc0afd0: 4c c6 31 82 crclr 4*cr1+eq ffc0afd4: 4e 80 04 21 bctrl ffc0afd8: 80 1f 00 20 lwz r0,32(r31) ffc0afdc: 7f 80 e8 40 cmplw cr7,r0,r29 ffc0afe0: 41 bd ff b8 bgt- cr7,ffc0af98 <_Heap_Walk+0x3c0> ffc0afe4: 80 1f 00 24 lwz r0,36(r31) ffc0afe8: 7f 80 e8 40 cmplw cr7,r0,r29 ffc0afec: 41 bc ff ac blt- cr7,ffc0af98 <_Heap_Walk+0x3c0> ); return false; } if ( !_Heap_Is_aligned( block_size, page_size ) ) { ffc0aff0: 7c 18 db 96 divwu r0,r24,r27 ffc0aff4: 7c 00 d9 d6 mullw r0,r0,r27 ffc0aff8: 7f 98 00 00 cmpw cr7,r24,r0 ffc0affc: 40 9e 01 50 bne- cr7,ffc0b14c <_Heap_Walk+0x574> ); return false; } if ( block_size < min_block_size ) { ffc0b000: 7f 9a c0 40 cmplw cr7,r26,r24 ffc0b004: 41 9d 01 60 bgt- cr7,ffc0b164 <_Heap_Walk+0x58c> ); return false; } if ( next_block_begin <= block_begin ) { ffc0b008: 7f 9e e8 40 cmplw cr7,r30,r29 ffc0b00c: 40 9c 01 8c bge- cr7,ffc0b198 <_Heap_Walk+0x5c0> ); return false; } if ( !_Heap_Is_prev_used( next_block ) ) { ffc0b010: 80 1d 00 04 lwz r0,4(r29) ffc0b014: 70 07 00 01 andi. r7,r0,1 ffc0b018: 40 82 00 b0 bne- ffc0b0c8 <_Heap_Walk+0x4f0> return &heap->free_list; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap ) { return _Heap_Free_list_head(heap)->next; ffc0b01c: 80 1f 00 08 lwz r0,8(r31) ffc0b020: 7e 08 83 78 mr r8,r16 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)( ffc0b024: 80 fe 00 0c lwz r7,12(r30) 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; ffc0b028: 82 de 00 04 lwz r22,4(r30) return &heap->free_list; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap ) { return _Heap_Free_list_head(heap)->next; ffc0b02c: 7f 80 38 00 cmpw cr7,r0,r7 } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_last( Heap_Control *heap ) { return _Heap_Free_list_tail(heap)->prev; ffc0b030: 80 1f 00 0c lwz r0,12(r31) - 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; ffc0b034: 56 d8 00 3c rlwinm r24,r22,0,0,30 RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at( const Heap_Block *block, uintptr_t offset ) { return (Heap_Block *) ((uintptr_t) block + offset); ffc0b038: 7e fe c2 14 add r23,r30,r24 return &heap->free_list; } RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap ) { return _Heap_Free_list_head(heap)->next; ffc0b03c: 41 9e 00 10 beq- cr7,ffc0b04c <_Heap_Walk+0x474> "block 0x%08x: prev 0x%08x%s, next 0x%08x%s\n", block, block->prev, block->prev == first_free_block ? " (= first)" : (block->prev == free_list_head ? " (= head)" : ""), ffc0b040: 7f 87 f8 00 cmpw cr7,r7,r31 ffc0b044: 7e a8 ab 78 mr r8,r21 ffc0b048: 41 9e 00 fc beq- cr7,ffc0b144 <_Heap_Walk+0x56c> 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)( ffc0b04c: 81 3e 00 08 lwz r9,8(r30) ffc0b050: 7e 2a 8b 78 mr r10,r17 ffc0b054: 7f 80 48 00 cmpw cr7,r0,r9 ffc0b058: 41 9e 00 10 beq- cr7,ffc0b068 <_Heap_Walk+0x490> " (= first)" : (block->prev == free_list_head ? " (= head)" : ""), block->next, block->next == last_free_block ? " (= last)" : (block->next == free_list_tail ? " (= tail)" : "") ffc0b05c: 7f 89 f8 00 cmpw cr7,r9,r31 ffc0b060: 7e aa ab 78 mr r10,r21 ffc0b064: 41 9e 00 d8 beq- cr7,ffc0b13c <_Heap_Walk+0x564> 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)( ffc0b068: 80 01 00 18 lwz r0,24(r1) ffc0b06c: 7f 83 e3 78 mr r3,r28 ffc0b070: 38 80 00 00 li r4,0 ffc0b074: 7e 45 93 78 mr r5,r18 ffc0b078: 7c 09 03 a6 mtctr r0 ffc0b07c: 7f c6 f3 78 mr r6,r30 ffc0b080: 4c c6 31 82 crclr 4*cr1+eq ffc0b084: 4e 80 04 21 bctrl block->next == last_free_block ? " (= last)" : (block->next == free_list_tail ? " (= tail)" : "") ); if ( block_size != next_block->prev_size ) { ffc0b088: 81 17 00 00 lwz r8,0(r23) ffc0b08c: 7f 98 40 00 cmpw cr7,r24,r8 ffc0b090: 41 9e 00 50 beq- cr7,ffc0b0e0 <_Heap_Walk+0x508> (*printer)( ffc0b094: 80 01 00 18 lwz r0,24(r1) ffc0b098: 3c a0 ff c2 lis r5,-62 ffc0b09c: 7f 83 e3 78 mr r3,r28 ffc0b0a0: 38 a5 0f 70 addi r5,r5,3952 ffc0b0a4: 7c 09 03 a6 mtctr r0 ffc0b0a8: 7f c6 f3 78 mr r6,r30 ffc0b0ac: 7f 07 c3 78 mr r7,r24 ffc0b0b0: 7e e9 bb 78 mr r9,r23 ffc0b0b4: 38 80 00 01 li r4,1 ffc0b0b8: 4c c6 31 82 crclr 4*cr1+eq ffc0b0bc: 4e 80 04 21 bctrl ffc0b0c0: 38 60 00 00 li r3,0 ffc0b0c4: 4b ff fb a8 b ffc0ac6c <_Heap_Walk+0x94> if ( !_Heap_Walk_check_control( source, printer, heap ) ) { return false; } while ( block != last_block ) { ffc0b0c8: 7f 99 e8 00 cmpw cr7,r25,r29 ffc0b0cc: 41 be fb 9c beq- cr7,ffc0ac68 <_Heap_Walk+0x90> 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 ) { ffc0b0d0: 83 1d 00 04 lwz r24,4(r29) ffc0b0d4: 7f be eb 78 mr r30,r29 ffc0b0d8: 57 00 07 fe clrlwi r0,r24,31 ffc0b0dc: 4b ff fe 7c b ffc0af58 <_Heap_Walk+0x380> ); return false; } if ( !prev_used ) { ffc0b0e0: 72 c7 00 01 andi. r7,r22,1 ffc0b0e4: 41 82 00 44 beq- ffc0b128 <_Heap_Walk+0x550> ffc0b0e8: 81 3f 00 08 lwz r9,8(r31) ) { 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 ) { ffc0b0ec: 7f 89 f8 00 cmpw cr7,r9,r31 ffc0b0f0: 41 9e 00 24 beq- cr7,ffc0b114 <_Heap_Walk+0x53c> if ( free_block == block ) { ffc0b0f4: 7f 89 f0 00 cmpw cr7,r9,r30 ffc0b0f8: 40 be 00 0c bne+ cr7,ffc0b104 <_Heap_Walk+0x52c> ffc0b0fc: 4b ff ff cc b ffc0b0c8 <_Heap_Walk+0x4f0> ffc0b100: 41 ba ff c8 beq- cr6,ffc0b0c8 <_Heap_Walk+0x4f0> return true; } free_block = free_block->next; ffc0b104: 81 29 00 08 lwz r9,8(r9) ) { 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 ) { ffc0b108: 7f 89 f8 00 cmpw cr7,r9,r31 if ( free_block == block ) { ffc0b10c: 7f 09 f0 00 cmpw cr6,r9,r30 ) { 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 ) { ffc0b110: 40 9e ff f0 bne+ cr7,ffc0b100 <_Heap_Walk+0x528> return false; } if ( !_Heap_Walk_is_in_free_list( heap, block ) ) { (*printer)( ffc0b114: 3c a0 ff c2 lis r5,-62 ffc0b118: 7f 83 e3 78 mr r3,r28 ffc0b11c: 38 a5 0f dc addi r5,r5,4060 ffc0b120: 7f c6 f3 78 mr r6,r30 ffc0b124: 4b ff fc 90 b ffc0adb4 <_Heap_Walk+0x1dc> return false; } if ( !prev_used ) { (*printer)( ffc0b128: 3c a0 ff c2 lis r5,-62 ffc0b12c: 7f 83 e3 78 mr r3,r28 ffc0b130: 38 a5 0f ac addi r5,r5,4012 return false; } if ( !_Heap_Walk_is_in_free_list( heap, block ) ) { (*printer)( ffc0b134: 7f c6 f3 78 mr r6,r30 ffc0b138: 4b ff fc 7c b ffc0adb4 <_Heap_Walk+0x1dc> " (= first)" : (block->prev == free_list_head ? " (= head)" : ""), block->next, block->next == last_free_block ? " (= last)" : (block->next == free_list_tail ? " (= tail)" : "") ffc0b13c: 7d ea 7b 78 mr r10,r15 ffc0b140: 4b ff ff 28 b ffc0b068 <_Heap_Walk+0x490> "block 0x%08x: prev 0x%08x%s, next 0x%08x%s\n", block, block->prev, block->prev == first_free_block ? " (= first)" : (block->prev == free_list_head ? " (= head)" : ""), ffc0b144: 7d c8 73 78 mr r8,r14 ffc0b148: 4b ff ff 04 b ffc0b04c <_Heap_Walk+0x474> return false; } if ( !_Heap_Is_aligned( block_size, page_size ) ) { (*printer)( ffc0b14c: 3c a0 ff c2 lis r5,-62 ffc0b150: 7f 83 e3 78 mr r3,r28 ffc0b154: 38 a5 0e 84 addi r5,r5,3716 ffc0b158: 7f c6 f3 78 mr r6,r30 ffc0b15c: 7f 07 c3 78 mr r7,r24 ffc0b160: 4b ff fc 80 b ffc0ade0 <_Heap_Walk+0x208> return false; } if ( block_size < min_block_size ) { (*printer)( ffc0b164: 80 01 00 18 lwz r0,24(r1) ffc0b168: 3c a0 ff c2 lis r5,-62 ffc0b16c: 7f 83 e3 78 mr r3,r28 ffc0b170: 38 a5 0e b4 addi r5,r5,3764 ffc0b174: 7c 09 03 a6 mtctr r0 ffc0b178: 7f c6 f3 78 mr r6,r30 ffc0b17c: 7f 07 c3 78 mr r7,r24 ffc0b180: 7f 48 d3 78 mr r8,r26 ffc0b184: 38 80 00 01 li r4,1 ffc0b188: 4c c6 31 82 crclr 4*cr1+eq ffc0b18c: 4e 80 04 21 bctrl ffc0b190: 38 60 00 00 li r3,0 block, block_size, min_block_size ); return false; ffc0b194: 4b ff fa d8 b ffc0ac6c <_Heap_Walk+0x94> } if ( next_block_begin <= block_begin ) { (*printer)( ffc0b198: 3c a0 ff c2 lis r5,-62 ffc0b19c: 7f 83 e3 78 mr r3,r28 ffc0b1a0: 38 a5 0e e0 addi r5,r5,3808 ffc0b1a4: 7f c6 f3 78 mr r6,r30 ffc0b1a8: 7f a7 eb 78 mr r7,r29 ffc0b1ac: 4b ff fc 34 b ffc0ade0 <_Heap_Walk+0x208> return false; } if ( _Heap_Is_free( last_block ) ) { (*printer)( ffc0b1b0: 3c a0 ff c2 lis r5,-62 ffc0b1b4: 7f 83 e3 78 mr r3,r28 ffc0b1b8: 38 a5 0d 5c addi r5,r5,3420 ffc0b1bc: 4b ff fc 4c b ffc0ae08 <_Heap_Walk+0x230> } if ( !_Heap_Is_aligned( _Heap_Alloc_area_of_block( free_block ), page_size ) ) { (*printer)( ffc0b1c0: 3c a0 ff c2 lis r5,-62 ffc0b1c4: 7f 83 e3 78 mr r3,r28 ffc0b1c8: 38 a5 0d 94 addi r5,r5,3476 ffc0b1cc: 4b ff fb e8 b ffc0adb4 <_Heap_Walk+0x1dc> return false; } if ( free_block->prev != prev_block ) { (*printer)( ffc0b1d0: 3c a0 ff c2 lis r5,-62 ffc0b1d4: 7f 83 e3 78 mr r3,r28 ffc0b1d8: 38 a5 0d e0 addi r5,r5,3552 ffc0b1dc: 4b ff fc 04 b ffc0ade0 <_Heap_Walk+0x208> return false; } if ( _Heap_Is_used( free_block ) ) { (*printer)( ffc0b1e0: 3c a0 ff c2 lis r5,-62 ffc0b1e4: 7f 83 e3 78 mr r3,r28 ffc0b1e8: 38 a5 0d c4 addi r5,r5,3524 ffc0b1ec: 4b ff fb c8 b ffc0adb4 <_Heap_Walk+0x1dc> ffc0b1f0 <_Heap_Walk_print>: { /* Do nothing */ } static void _Heap_Walk_print( int source, bool error, const char *fmt, ... ) { ffc0b1f0: 94 21 ff 88 stwu r1,-120(r1) ffc0b1f4: 7c 08 02 a6 mflr r0 ffc0b1f8: 93 e1 00 74 stw r31,116(r1) ffc0b1fc: 90 01 00 7c stw r0,124(r1) ffc0b200: 7c 60 1b 78 mr r0,r3 ffc0b204: 90 c1 00 1c stw r6,28(r1) ffc0b208: 90 e1 00 20 stw r7,32(r1) ffc0b20c: 91 01 00 24 stw r8,36(r1) ffc0b210: 91 21 00 28 stw r9,40(r1) ffc0b214: 91 41 00 2c stw r10,44(r1) ffc0b218: 40 86 00 24 bne- cr1,ffc0b23c <_Heap_Walk_print+0x4c> ffc0b21c: d8 21 00 30 stfd f1,48(r1) <== NOT EXECUTED ffc0b220: d8 41 00 38 stfd f2,56(r1) <== NOT EXECUTED ffc0b224: d8 61 00 40 stfd f3,64(r1) <== NOT EXECUTED ffc0b228: d8 81 00 48 stfd f4,72(r1) <== NOT EXECUTED ffc0b22c: d8 a1 00 50 stfd f5,80(r1) <== NOT EXECUTED ffc0b230: d8 c1 00 58 stfd f6,88(r1) <== NOT EXECUTED ffc0b234: d8 e1 00 60 stfd f7,96(r1) <== NOT EXECUTED ffc0b238: d9 01 00 68 stfd f8,104(r1) <== NOT EXECUTED va_list ap; if ( error ) { ffc0b23c: 2f 84 00 00 cmpwi cr7,r4,0 { /* Do nothing */ } static void _Heap_Walk_print( int source, bool error, const char *fmt, ... ) { ffc0b240: 7c bf 2b 78 mr r31,r5 va_list ap; if ( error ) { ffc0b244: 40 9e 00 58 bne- cr7,ffc0b29c <_Heap_Walk_print+0xac> printk( "FAIL[%d]: ", source ); } else { printk( "PASS[%d]: ", source ); ffc0b248: 3c 60 ff c2 lis r3,-62 ffc0b24c: 7c 04 03 78 mr r4,r0 ffc0b250: 38 63 10 14 addi r3,r3,4116 ffc0b254: 4c c6 31 82 crclr 4*cr1+eq ffc0b258: 4b ff ad 7d bl ffc05fd4 } va_start( ap, fmt ); ffc0b25c: 38 00 00 03 li r0,3 ffc0b260: 98 01 00 08 stb r0,8(r1) ffc0b264: 38 00 00 00 li r0,0 vprintk( fmt, ap ); ffc0b268: 7f e3 fb 78 mr r3,r31 printk( "FAIL[%d]: ", source ); } else { printk( "PASS[%d]: ", source ); } va_start( ap, fmt ); ffc0b26c: 98 01 00 09 stb r0,9(r1) ffc0b270: 38 01 00 80 addi r0,r1,128 vprintk( fmt, ap ); ffc0b274: 38 81 00 08 addi r4,r1,8 printk( "FAIL[%d]: ", source ); } else { printk( "PASS[%d]: ", source ); } va_start( ap, fmt ); ffc0b278: 90 01 00 0c stw r0,12(r1) ffc0b27c: 38 01 00 10 addi r0,r1,16 ffc0b280: 90 01 00 10 stw r0,16(r1) vprintk( fmt, ap ); ffc0b284: 4b ff d0 85 bl ffc08308 va_end( ap ); } ffc0b288: 80 01 00 7c lwz r0,124(r1) ffc0b28c: 83 e1 00 74 lwz r31,116(r1) ffc0b290: 38 21 00 78 addi r1,r1,120 ffc0b294: 7c 08 03 a6 mtlr r0 ffc0b298: 4e 80 00 20 blr static void _Heap_Walk_print( int source, bool error, const char *fmt, ... ) { va_list ap; if ( error ) { printk( "FAIL[%d]: ", source ); ffc0b29c: 3c 60 ff c2 lis r3,-62 ffc0b2a0: 7c 04 03 78 mr r4,r0 ffc0b2a4: 38 63 10 08 addi r3,r3,4104 ffc0b2a8: 4c c6 31 82 crclr 4*cr1+eq ffc0b2ac: 4b ff ad 29 bl ffc05fd4 } else { printk( "PASS[%d]: ", source ); } va_start( ap, fmt ); ffc0b2b0: 38 00 00 03 li r0,3 ffc0b2b4: 98 01 00 08 stb r0,8(r1) ffc0b2b8: 38 00 00 00 li r0,0 vprintk( fmt, ap ); ffc0b2bc: 7f e3 fb 78 mr r3,r31 printk( "FAIL[%d]: ", source ); } else { printk( "PASS[%d]: ", source ); } va_start( ap, fmt ); ffc0b2c0: 98 01 00 09 stb r0,9(r1) ffc0b2c4: 38 01 00 80 addi r0,r1,128 vprintk( fmt, ap ); ffc0b2c8: 38 81 00 08 addi r4,r1,8 printk( "FAIL[%d]: ", source ); } else { printk( "PASS[%d]: ", source ); } va_start( ap, fmt ); ffc0b2cc: 90 01 00 0c stw r0,12(r1) ffc0b2d0: 38 01 00 10 addi r0,r1,16 ffc0b2d4: 90 01 00 10 stw r0,16(r1) vprintk( fmt, ap ); ffc0b2d8: 4b ff d0 31 bl ffc08308 va_end( ap ); } ffc0b2dc: 80 01 00 7c lwz r0,124(r1) ffc0b2e0: 83 e1 00 74 lwz r31,116(r1) ffc0b2e4: 38 21 00 78 addi r1,r1,120 ffc0b2e8: 7c 08 03 a6 mtlr r0 ffc0b2ec: 4e 80 00 20 blr ffc09f74 <_Internal_error_Occurred>: void _Internal_error_Occurred( Internal_errors_Source the_source, bool is_internal, Internal_errors_t the_error ) { ffc09f74: 94 21 ff f0 stwu r1,-16(r1) ffc09f78: 7c 08 02 a6 mflr r0 _Internal_errors_What_happened.the_source = the_source; ffc09f7c: 3d 60 00 00 lis r11,0 ffc09f80: 39 2b 2d 30 addi r9,r11,11568 void _Internal_error_Occurred( Internal_errors_Source the_source, bool is_internal, Internal_errors_t the_error ) { ffc09f84: 90 01 00 14 stw r0,20(r1) _Internal_errors_What_happened.the_source = the_source; _Internal_errors_What_happened.is_internal = is_internal; _Internal_errors_What_happened.the_error = the_error; ffc09f88: 90 a9 00 08 stw r5,8(r9) Internal_errors_t the_error ) { _Internal_errors_What_happened.the_source = the_source; _Internal_errors_What_happened.is_internal = is_internal; ffc09f8c: 98 89 00 04 stb r4,4(r9) void _Internal_error_Occurred( Internal_errors_Source the_source, bool is_internal, Internal_errors_t the_error ) { ffc09f90: 93 e1 00 0c stw r31,12(r1) ffc09f94: 7c bf 2b 78 mr r31,r5 _Internal_errors_What_happened.the_source = the_source; ffc09f98: 90 6b 2d 30 stw r3,11568(r11) _Internal_errors_What_happened.is_internal = is_internal; _Internal_errors_What_happened.the_error = the_error; _User_extensions_Fatal( the_source, is_internal, the_error ); ffc09f9c: 48 00 26 45 bl ffc0c5e0 <_User_extensions_Fatal> RTEMS_INLINE_ROUTINE void _System_state_Set ( System_state_Codes state ) { _System_state_Current = state; ffc09fa0: 38 00 00 05 li r0,5 ffc09fa4: 3d 20 00 00 lis r9,0 _System_state_Set( SYSTEM_STATE_FAILED ); _CPU_Fatal_halt( the_error ); ffc09fa8: 7f e3 fb 78 mr r3,r31 ffc09fac: 90 09 27 d4 stw r0,10196(r9) ffc09fb0: 4b ff 9a 85 bl ffc03a34 <_BSP_Fatal_error> ffc09fb4: 48 00 00 00 b ffc09fb4 <_Internal_error_Occurred+0x40><== NOT EXECUTED ffc0a0d0 <_Objects_Extend_information>: */ void _Objects_Extend_information( Objects_Information *information ) { ffc0a0d0: 94 21 ff b8 stwu r1,-72(r1) ffc0a0d4: 7c 08 02 a6 mflr r0 ffc0a0d8: 90 01 00 4c stw r0,76(r1) minimum_index = _Objects_Get_index( information->minimum_id ); index_base = minimum_index; block = 0; /* if ( information->maximum < minimum_index ) */ if ( information->object_blocks == NULL ) ffc0a0dc: 81 63 00 34 lwz r11,52(r3) */ void _Objects_Extend_information( Objects_Information *information ) { ffc0a0e0: 93 a1 00 3c stw r29,60(r1) minimum_index = _Objects_Get_index( information->minimum_id ); index_base = minimum_index; block = 0; /* if ( information->maximum < minimum_index ) */ if ( information->object_blocks == NULL ) ffc0a0e4: 2f 8b 00 00 cmpwi cr7,r11,0 */ void _Objects_Extend_information( Objects_Information *information ) { ffc0a0e8: 93 e1 00 44 stw r31,68(r1) ffc0a0ec: 7c 7f 1b 78 mr r31,r3 ffc0a0f0: 92 a1 00 1c stw r21,28(r1) ffc0a0f4: 92 c1 00 20 stw r22,32(r1) ffc0a0f8: 92 e1 00 24 stw r23,36(r1) ffc0a0fc: 93 01 00 28 stw r24,40(r1) ffc0a100: 93 21 00 2c stw r25,44(r1) ffc0a104: 93 41 00 30 stw r26,48(r1) ffc0a108: 93 61 00 34 stw r27,52(r1) ffc0a10c: 93 81 00 38 stw r28,56(r1) ffc0a110: 93 c1 00 40 stw r30,64(r1) /* * Search for a free block of indexes. The block variable ends up set * to block_count + 1 if the table needs to be extended. */ minimum_index = _Objects_Get_index( information->minimum_id ); ffc0a114: a3 a3 00 0a lhz r29,10(r3) index_base = minimum_index; block = 0; /* if ( information->maximum < minimum_index ) */ if ( information->object_blocks == NULL ) ffc0a118: 41 9e 02 9c beq- cr7,ffc0a3b4 <_Objects_Extend_information+0x2e4> block_count = 0; else { block_count = information->maximum / information->allocation_size; ffc0a11c: a3 23 00 10 lhz r25,16(r3) ffc0a120: a1 23 00 14 lhz r9,20(r3) ffc0a124: 7e b9 4b 96 divwu r21,r25,r9 for ( ; block < block_count; block++ ) { ffc0a128: 2f 95 00 00 cmpwi cr7,r21,0 ffc0a12c: 41 9e 02 a0 beq- cr7,ffc0a3cc <_Objects_Extend_information+0x2fc> if ( information->object_blocks[ block ] == NULL ) ffc0a130: 80 0b 00 00 lwz r0,0(r11) ffc0a134: 2f 80 00 00 cmpwi cr7,r0,0 ffc0a138: 41 9e 02 94 beq- cr7,ffc0a3cc <_Objects_Extend_information+0x2fc> ffc0a13c: 7d 2a 4b 78 mr r10,r9 ffc0a140: 7e a9 03 a6 mtctr r21 ffc0a144: 7f be eb 78 mr r30,r29 ffc0a148: 3b 60 00 00 li r27,0 ffc0a14c: 48 00 00 10 b ffc0a15c <_Objects_Extend_information+0x8c> ffc0a150: 7c 0b 00 2e lwzx r0,r11,r0 ffc0a154: 2f 80 00 00 cmpwi cr7,r0,0 ffc0a158: 41 9e 00 14 beq- cr7,ffc0a16c <_Objects_Extend_information+0x9c> if ( information->object_blocks == NULL ) block_count = 0; else { block_count = information->maximum / information->allocation_size; for ( ; block < block_count; block++ ) { ffc0a15c: 3b 7b 00 01 addi r27,r27,1 if ( information->object_blocks[ block ] == NULL ) ffc0a160: 57 60 10 3a rlwinm r0,r27,2,0,29 break; else index_base += information->allocation_size; ffc0a164: 7f de 4a 14 add r30,r30,r9 if ( information->object_blocks == NULL ) block_count = 0; else { block_count = information->maximum / information->allocation_size; for ( ; block < block_count; block++ ) { ffc0a168: 42 00 ff e8 bdnz+ ffc0a150 <_Objects_Extend_information+0x80> else index_base += information->allocation_size; } } maximum = (uint32_t) information->maximum + information->allocation_size; ffc0a16c: 7f 39 52 14 add r25,r25,r10 /* * We need to limit the number of objects to the maximum number * representable in the index portion of the object Id. In the * case of 16-bit Ids, this is only 256 object instances. */ if ( maximum > OBJECTS_ID_FINAL_INDEX ) { ffc0a170: 2b 99 ff ff cmplwi cr7,r25,65535 ffc0a174: 41 9d 01 b8 bgt- cr7,ffc0a32c <_Objects_Extend_information+0x25c> /* * Allocate the name table, and the objects and if it fails either return or * generate a fatal error depending on auto-extending being active. */ block_size = information->allocation_size * information->size; if ( information->auto_extend ) { ffc0a178: 88 1f 00 12 lbz r0,18(r31) /* * Allocate the name table, and the objects and if it fails either return or * generate a fatal error depending on auto-extending being active. */ block_size = information->allocation_size * information->size; ffc0a17c: 80 7f 00 18 lwz r3,24(r31) if ( information->auto_extend ) { ffc0a180: 2f 80 00 00 cmpwi cr7,r0,0 /* * Allocate the name table, and the objects and if it fails either return or * generate a fatal error depending on auto-extending being active. */ block_size = information->allocation_size * information->size; ffc0a184: 7c 6a 19 d6 mullw r3,r10,r3 if ( information->auto_extend ) { ffc0a188: 40 9e 01 e0 bne- cr7,ffc0a368 <_Objects_Extend_information+0x298> new_object_block = _Workspace_Allocate( block_size ); if ( !new_object_block ) return; } else { new_object_block = _Workspace_Allocate_or_fatal_error( block_size ); ffc0a18c: 48 00 2a 71 bl ffc0cbfc <_Workspace_Allocate_or_fatal_error> ffc0a190: 7c 7c 1b 78 mr r28,r3 } /* * If the index_base is the maximum we need to grow the tables. */ if (index_base >= information->maximum ) { ffc0a194: a0 1f 00 10 lhz r0,16(r31) ffc0a198: 7f 9e 00 40 cmplw cr7,r30,r0 ffc0a19c: 41 9c 01 08 blt- cr7,ffc0a2a4 <_Objects_Extend_information+0x1d4> */ /* * Up the block count and maximum */ block_count++; ffc0a1a0: 3b 55 00 01 addi r26,r21,1 * Allocate the tables and break it up. */ block_size = block_count * (sizeof(void *) + sizeof(uint32_t) + sizeof(Objects_Name *)) + ((maximum + minimum_index) * sizeof(Objects_Control *)); object_blocks = (void**) _Workspace_Allocate( block_size ); ffc0a1a4: 1c 7a 00 03 mulli r3,r26,3 ffc0a1a8: 7c 79 1a 14 add r3,r25,r3 ffc0a1ac: 7c 63 ea 14 add r3,r3,r29 ffc0a1b0: 54 63 10 3a rlwinm r3,r3,2,0,29 ffc0a1b4: 48 00 2a 91 bl ffc0cc44 <_Workspace_Allocate> if ( !object_blocks ) { ffc0a1b8: 7c 76 1b 79 mr. r22,r3 ffc0a1bc: 41 82 02 20 beq- ffc0a3dc <_Objects_Extend_information+0x30c> * Take the block count down. Saves all the (block_count - 1) * in the copies. */ block_count--; if ( information->maximum > minimum_index ) { ffc0a1c0: a0 1f 00 10 lhz r0,16(r31) } /* * Break the block into the various sections. */ inactive_per_block = (uint32_t *) _Addresses_Add_offset( ffc0a1c4: 57 5a 10 3a rlwinm r26,r26,2,0,29 RTEMS_INLINE_ROUTINE void *_Addresses_Add_offset ( const void *base, uintptr_t offset ) { return (void *)((uintptr_t)base + offset); ffc0a1c8: 7f 16 d2 14 add r24,r22,r26 * Take the block count down. Saves all the (block_count - 1) * in the copies. */ block_count--; if ( information->maximum > minimum_index ) { ffc0a1cc: 7f 9d 00 40 cmplw cr7,r29,r0 ffc0a1d0: 7f 58 d2 14 add r26,r24,r26 ffc0a1d4: 41 9c 01 a4 blt- cr7,ffc0a378 <_Objects_Extend_information+0x2a8> } else { /* * Deal with the special case of the 0 to minimum_index */ for ( index = 0; index < minimum_index; index++ ) { ffc0a1d8: 2f 9d 00 00 cmpwi cr7,r29,0 information->object_blocks, block_count * sizeof(void*) ); memcpy( inactive_per_block, information->inactive_per_block, block_count * sizeof(uint32_t) ); memcpy( local_table, ffc0a1dc: 39 20 00 00 li r9,0 } else { /* * Deal with the special case of the 0 to minimum_index */ for ( index = 0; index < minimum_index; index++ ) { ffc0a1e0: 56 b7 10 3a rlwinm r23,r21,2,0,29 ffc0a1e4: 41 9e 00 20 beq- cr7,ffc0a204 <_Objects_Extend_information+0x134> local_table[ index ] = NULL; ffc0a1e8: 7f a9 03 a6 mtctr r29 ffc0a1ec: 38 00 00 00 li r0,0 ffc0a1f0: 55 2b 10 3a rlwinm r11,r9,2,0,29 ffc0a1f4: 7c 0b d1 2e stwx r0,r11,r26 } else { /* * Deal with the special case of the 0 to minimum_index */ for ( index = 0; index < minimum_index; index++ ) { ffc0a1f8: 39 29 00 01 addi r9,r9,1 ffc0a1fc: 42 00 ff f4 bdnz+ ffc0a1f0 <_Objects_Extend_information+0x120> ffc0a200: 56 b7 10 3a rlwinm r23,r21,2,0,29 */ object_blocks[block_count] = NULL; inactive_per_block[block_count] = 0; for ( index=index_base ; index < ( information->allocation_size + index_base ); ffc0a204: a1 7f 00 14 lhz r11,20(r31) } /* * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; ffc0a208: 38 00 00 00 li r0,0 inactive_per_block[block_count] = 0; ffc0a20c: 7c 18 b9 2e stwx r0,r24,r23 for ( index=index_base ; index < ( information->allocation_size + index_base ); ffc0a210: 7d 7e 5a 14 add r11,r30,r11 * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; inactive_per_block[block_count] = 0; for ( index=index_base ; ffc0a214: 7f 9e 58 40 cmplw cr7,r30,r11 } /* * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; ffc0a218: 7c 16 b9 2e stwx r0,r22,r23 inactive_per_block[block_count] = 0; for ( index=index_base ; ffc0a21c: 40 9c 00 30 bge- cr7,ffc0a24c <_Objects_Extend_information+0x17c> ffc0a220: 38 1e 00 01 addi r0,r30,1 ffc0a224: 7f 80 58 40 cmplw cr7,r0,r11 ffc0a228: 57 c9 10 3a rlwinm r9,r30,2,0,29 index < ( information->allocation_size + index_base ); index++ ) { local_table[ index ] = NULL; ffc0a22c: 7d 7e 58 50 subf r11,r30,r11 * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; inactive_per_block[block_count] = 0; for ( index=index_base ; ffc0a230: 7d 3a 4a 14 add r9,r26,r9 index < ( information->allocation_size + index_base ); index++ ) { local_table[ index ] = NULL; ffc0a234: 7d 69 03 a6 mtctr r11 ffc0a238: 38 00 00 00 li r0,0 ffc0a23c: 41 9d 01 ac bgt- cr7,ffc0a3e8 <_Objects_Extend_information+0x318> ffc0a240: 90 09 00 00 stw r0,0(r9) object_blocks[block_count] = NULL; inactive_per_block[block_count] = 0; for ( index=index_base ; index < ( information->allocation_size + index_base ); index++ ) { ffc0a244: 39 29 00 04 addi r9,r9,4 * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; inactive_per_block[block_count] = 0; for ( index=index_base ; ffc0a248: 42 00 ff f8 bdnz+ ffc0a240 <_Objects_Extend_information+0x170> static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc0a24c: 7c 00 00 a6 mfmsr r0 ffc0a250: 7d 30 42 a6 mfsprg r9,0 ffc0a254: 7c 09 48 78 andc r9,r0,r9 ffc0a258: 7d 20 01 24 mtmsr r9 information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; information->local_table = local_table; information->maximum = (Objects_Maximum) maximum; information->maximum_id = _Objects_Build_id( ffc0a25c: 81 7f 00 00 lwz r11,0(r31) old_tables = information->object_blocks; information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; information->local_table = local_table; information->maximum = (Objects_Maximum) maximum; ffc0a260: 57 39 04 3e clrlwi r25,r25,16 information->maximum_id = _Objects_Build_id( ffc0a264: a1 3f 00 04 lhz r9,4(r31) ffc0a268: 55 6b c0 0e rlwinm r11,r11,24,0,7 local_table[ index ] = NULL; } _ISR_Disable( level ); old_tables = information->object_blocks; ffc0a26c: 80 7f 00 34 lwz r3,52(r31) information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; information->local_table = local_table; information->maximum = (Objects_Maximum) maximum; information->maximum_id = _Objects_Build_id( ffc0a270: 65 6b 00 01 oris r11,r11,1 _ISR_Disable( level ); old_tables = information->object_blocks; information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; ffc0a274: 93 1f 00 30 stw r24,48(r31) information->local_table = local_table; information->maximum = (Objects_Maximum) maximum; information->maximum_id = _Objects_Build_id( ffc0a278: 55 29 d8 08 rlwinm r9,r9,27,0,4 ffc0a27c: 7d 69 4b 78 or r9,r11,r9 old_tables = information->object_blocks; information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; information->local_table = local_table; ffc0a280: 93 5f 00 1c stw r26,28(r31) information->maximum = (Objects_Maximum) maximum; information->maximum_id = _Objects_Build_id( ffc0a284: 7d 29 cb 78 or r9,r9,r25 ffc0a288: 91 3f 00 0c stw r9,12(r31) old_tables = information->object_blocks; information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; information->local_table = local_table; information->maximum = (Objects_Maximum) maximum; ffc0a28c: b3 3f 00 10 sth r25,16(r31) _ISR_Disable( level ); old_tables = information->object_blocks; information->object_blocks = object_blocks; ffc0a290: 92 df 00 34 stw r22,52(r31) return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc0a294: 7c 00 01 24 mtmsr r0 information->maximum ); _ISR_Enable( level ); if ( old_tables ) ffc0a298: 2f 83 00 00 cmpwi cr7,r3,0 ffc0a29c: 41 9e 00 08 beq- cr7,ffc0a2a4 <_Objects_Extend_information+0x1d4> _Workspace_Free( old_tables ); ffc0a2a0: 48 00 29 d9 bl ffc0cc78 <_Workspace_Free> } /* * Assign the new object block to the object block table. */ information->object_blocks[ block ] = new_object_block; ffc0a2a4: 81 3f 00 34 lwz r9,52(r31) ffc0a2a8: 57 7b 10 3a rlwinm r27,r27,2,0,29 /* * Initialize objects .. add to a local chain first. */ _Chain_Initialize( ffc0a2ac: 3b a1 00 08 addi r29,r1,8 ffc0a2b0: a0 bf 00 14 lhz r5,20(r31) } /* * Assign the new object block to the object block table. */ information->object_blocks[ block ] = new_object_block; ffc0a2b4: 7f 89 d9 2e stwx r28,r9,r27 /* * Initialize objects .. add to a local chain first. */ _Chain_Initialize( ffc0a2b8: 7f 84 e3 78 mr r4,r28 ffc0a2bc: 7f a3 eb 78 mr r3,r29 ffc0a2c0: 80 df 00 18 lwz r6,24(r31) information->the_class, _Objects_Local_node, index ); _Chain_Append( &information->Inactive, &the_object->Node ); ffc0a2c4: 3b 9f 00 20 addi r28,r31,32 information->object_blocks[ block ] = new_object_block; /* * Initialize objects .. add to a local chain first. */ _Chain_Initialize( ffc0a2c8: 48 00 54 55 bl ffc0f71c <_Chain_Initialize> /* * Move from the local chain, initialise, then append to the inactive chain */ index = index_base; while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) { ffc0a2cc: 48 00 00 2c b ffc0a2f8 <_Objects_Extend_information+0x228> the_object->id = _Objects_Build_id( ffc0a2d0: 81 7f 00 00 lwz r11,0(r31) ffc0a2d4: a0 1f 00 04 lhz r0,4(r31) ffc0a2d8: 55 6b c0 0e rlwinm r11,r11,24,0,7 ffc0a2dc: 65 6b 00 01 oris r11,r11,1 ffc0a2e0: 54 00 d8 08 rlwinm r0,r0,27,0,4 ffc0a2e4: 7d 60 03 78 or r0,r11,r0 ffc0a2e8: 7c 00 f3 78 or r0,r0,r30 ffc0a2ec: 90 09 00 08 stw r0,8(r9) index ); _Chain_Append( &information->Inactive, &the_object->Node ); index++; ffc0a2f0: 3b de 00 01 addi r30,r30,1 information->the_class, _Objects_Local_node, index ); _Chain_Append( &information->Inactive, &the_object->Node ); ffc0a2f4: 4b ff f1 fd bl ffc094f0 <_Chain_Append> /* * Move from the local chain, initialise, then append to the inactive chain */ index = index_base; while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) { ffc0a2f8: 7f a3 eb 78 mr r3,r29 ffc0a2fc: 4b ff f2 25 bl ffc09520 <_Chain_Get> ffc0a300: 7c 69 1b 79 mr. r9,r3 information->the_class, _Objects_Local_node, index ); _Chain_Append( &information->Inactive, &the_object->Node ); ffc0a304: 7f 83 e3 78 mr r3,r28 ffc0a308: 7d 24 4b 78 mr r4,r9 /* * Move from the local chain, initialise, then append to the inactive chain */ index = index_base; while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) { ffc0a30c: 40 82 ff c4 bne+ ffc0a2d0 <_Objects_Extend_information+0x200> _Chain_Append( &information->Inactive, &the_object->Node ); index++; } information->inactive_per_block[ block ] = information->allocation_size; ffc0a310: a0 1f 00 14 lhz r0,20(r31) information->inactive = ffc0a314: a1 3f 00 2c lhz r9,44(r31) _Chain_Append( &information->Inactive, &the_object->Node ); index++; } information->inactive_per_block[ block ] = information->allocation_size; ffc0a318: 81 7f 00 30 lwz r11,48(r31) information->inactive = ffc0a31c: 7d 20 4a 14 add r9,r0,r9 _Chain_Append( &information->Inactive, &the_object->Node ); index++; } information->inactive_per_block[ block ] = information->allocation_size; ffc0a320: 54 00 04 3e clrlwi r0,r0,16 information->inactive = ffc0a324: b1 3f 00 2c sth r9,44(r31) _Chain_Append( &information->Inactive, &the_object->Node ); index++; } information->inactive_per_block[ block ] = information->allocation_size; ffc0a328: 7c 0b d9 2e stwx r0,r11,r27 information->inactive = (Objects_Maximum)(information->inactive + information->allocation_size); } ffc0a32c: 80 01 00 4c lwz r0,76(r1) ffc0a330: 82 a1 00 1c lwz r21,28(r1) ffc0a334: 7c 08 03 a6 mtlr r0 ffc0a338: 82 c1 00 20 lwz r22,32(r1) ffc0a33c: 82 e1 00 24 lwz r23,36(r1) ffc0a340: 83 01 00 28 lwz r24,40(r1) ffc0a344: 83 21 00 2c lwz r25,44(r1) ffc0a348: 83 41 00 30 lwz r26,48(r1) ffc0a34c: 83 61 00 34 lwz r27,52(r1) ffc0a350: 83 81 00 38 lwz r28,56(r1) ffc0a354: 83 a1 00 3c lwz r29,60(r1) ffc0a358: 83 c1 00 40 lwz r30,64(r1) ffc0a35c: 83 e1 00 44 lwz r31,68(r1) ffc0a360: 38 21 00 48 addi r1,r1,72 ffc0a364: 4e 80 00 20 blr * Allocate the name table, and the objects and if it fails either return or * generate a fatal error depending on auto-extending being active. */ block_size = information->allocation_size * information->size; if ( information->auto_extend ) { new_object_block = _Workspace_Allocate( block_size ); ffc0a368: 48 00 28 dd bl ffc0cc44 <_Workspace_Allocate> if ( !new_object_block ) ffc0a36c: 7c 7c 1b 79 mr. r28,r3 ffc0a370: 40 82 fe 24 bne+ ffc0a194 <_Objects_Extend_information+0xc4> ffc0a374: 4b ff ff b8 b ffc0a32c <_Objects_Extend_information+0x25c> * separate parts as size of each block has changed. */ memcpy( object_blocks, information->object_blocks, block_count * sizeof(void*) ); ffc0a378: 56 b7 10 3a rlwinm r23,r21,2,0,29 /* * Copy each section of the table over. This has to be performed as * separate parts as size of each block has changed. */ memcpy( object_blocks, ffc0a37c: 80 9f 00 34 lwz r4,52(r31) ffc0a380: 7e e5 bb 78 mr r5,r23 ffc0a384: 48 00 9a 99 bl ffc13e1c information->object_blocks, block_count * sizeof(void*) ); memcpy( inactive_per_block, ffc0a388: 80 9f 00 30 lwz r4,48(r31) ffc0a38c: 7e e5 bb 78 mr r5,r23 ffc0a390: 7f 03 c3 78 mr r3,r24 ffc0a394: 48 00 9a 89 bl ffc13e1c information->inactive_per_block, block_count * sizeof(uint32_t) ); memcpy( local_table, ffc0a398: a0 bf 00 10 lhz r5,16(r31) ffc0a39c: 80 9f 00 1c lwz r4,28(r31) ffc0a3a0: 7f 43 d3 78 mr r3,r26 ffc0a3a4: 7c bd 2a 14 add r5,r29,r5 ffc0a3a8: 54 a5 10 3a rlwinm r5,r5,2,0,29 ffc0a3ac: 48 00 9a 71 bl ffc13e1c ffc0a3b0: 4b ff fe 54 b ffc0a204 <_Objects_Extend_information+0x134> minimum_index = _Objects_Get_index( information->minimum_id ); index_base = minimum_index; block = 0; /* if ( information->maximum < minimum_index ) */ if ( information->object_blocks == NULL ) ffc0a3b4: a3 23 00 10 lhz r25,16(r3) ffc0a3b8: 7f be eb 78 mr r30,r29 ffc0a3bc: a1 43 00 14 lhz r10,20(r3) ffc0a3c0: 3b 60 00 00 li r27,0 ffc0a3c4: 3a a0 00 00 li r21,0 ffc0a3c8: 4b ff fd a4 b ffc0a16c <_Objects_Extend_information+0x9c> block_count = 0; else { block_count = information->maximum / information->allocation_size; for ( ; block < block_count; block++ ) { if ( information->object_blocks[ block ] == NULL ) ffc0a3cc: 7d 2a 4b 78 mr r10,r9 <== NOT EXECUTED ffc0a3d0: 7f be eb 78 mr r30,r29 <== NOT EXECUTED ffc0a3d4: 3b 60 00 00 li r27,0 <== NOT EXECUTED ffc0a3d8: 4b ff fd 94 b ffc0a16c <_Objects_Extend_information+0x9c><== NOT EXECUTED (sizeof(void *) + sizeof(uint32_t) + sizeof(Objects_Name *)) + ((maximum + minimum_index) * sizeof(Objects_Control *)); object_blocks = (void**) _Workspace_Allocate( block_size ); if ( !object_blocks ) { _Workspace_Free( new_object_block ); ffc0a3dc: 7f 83 e3 78 mr r3,r28 ffc0a3e0: 48 00 28 99 bl ffc0cc78 <_Workspace_Free> return; ffc0a3e4: 4b ff ff 48 b ffc0a32c <_Objects_Extend_information+0x25c> ffc0a3e8: 39 60 00 01 li r11,1 <== NOT EXECUTED ffc0a3ec: 7d 69 03 a6 mtctr r11 <== NOT EXECUTED ffc0a3f0: 4b ff fe 50 b ffc0a240 <_Objects_Extend_information+0x170><== NOT EXECUTED ffc0a838 <_Objects_Shrink_information>: */ void _Objects_Shrink_information( Objects_Information *information ) { ffc0a838: 94 21 ff e8 stwu r1,-24(r1) ffc0a83c: 7c 08 02 a6 mflr r0 ffc0a840: 90 01 00 1c stw r0,28(r1) ffc0a844: 93 c1 00 10 stw r30,16(r1) /* * Search the list to find block or chunk with all objects inactive. */ index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / ffc0a848: a1 23 00 10 lhz r9,16(r3) /* * Search the list to find block or chunk with all objects inactive. */ index_base = _Objects_Get_index( information->minimum_id ); ffc0a84c: a3 c3 00 0a lhz r30,10(r3) block_count = (information->maximum - index_base) / ffc0a850: a0 03 00 14 lhz r0,20(r3) ffc0a854: 7d 3e 48 50 subf r9,r30,r9 */ void _Objects_Shrink_information( Objects_Information *information ) { ffc0a858: 93 81 00 08 stw r28,8(r1) /* * Search the list to find block or chunk with all objects inactive. */ index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / ffc0a85c: 7d 29 03 96 divwu r9,r9,r0 */ void _Objects_Shrink_information( Objects_Information *information ) { ffc0a860: 93 a1 00 0c stw r29,12(r1) ffc0a864: 93 e1 00 14 stw r31,20(r1) index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { ffc0a868: 2f 89 00 00 cmpwi cr7,r9,0 */ void _Objects_Shrink_information( Objects_Information *information ) { ffc0a86c: 7c 7c 1b 78 mr r28,r3 index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { ffc0a870: 41 9e 00 3c beq- cr7,ffc0a8ac <_Objects_Shrink_information+0x74> if ( information->inactive_per_block[ block ] == ffc0a874: 81 63 00 30 lwz r11,48(r3) ffc0a878: 7d 29 03 a6 mtctr r9 information->object_blocks[ block ] = NULL; information->inactive_per_block[ block ] = 0; information->inactive -= information->allocation_size; return; ffc0a87c: 3b e0 00 04 li r31,4 index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { if ( information->inactive_per_block[ block ] == ffc0a880: 81 2b 00 00 lwz r9,0(r11) ffc0a884: 7f 80 48 00 cmpw cr7,r0,r9 ffc0a888: 41 9e 00 44 beq- cr7,ffc0a8cc <_Objects_Shrink_information+0x94> index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { ffc0a88c: 42 40 00 20 bdz- ffc0a8ac <_Objects_Shrink_information+0x74> if ( information->inactive_per_block[ block ] == ffc0a890: 7d 2b f8 2e lwzx r9,r11,r31 information->inactive -= information->allocation_size; return; } index_base += information->allocation_size; ffc0a894: 7f de 02 14 add r30,r30,r0 index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { if ( information->inactive_per_block[ block ] == ffc0a898: 7f 80 48 00 cmpw cr7,r0,r9 information->inactive -= information->allocation_size; return; } index_base += information->allocation_size; ffc0a89c: 39 3f 00 04 addi r9,r31,4 index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { if ( information->inactive_per_block[ block ] == ffc0a8a0: 41 9e 00 30 beq- cr7,ffc0a8d0 <_Objects_Shrink_information+0x98> ffc0a8a4: 7d 3f 4b 78 mr r31,r9 index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { ffc0a8a8: 42 00 ff e8 bdnz+ ffc0a890 <_Objects_Shrink_information+0x58> return; } index_base += information->allocation_size; } } ffc0a8ac: 80 01 00 1c lwz r0,28(r1) ffc0a8b0: 83 81 00 08 lwz r28,8(r1) ffc0a8b4: 7c 08 03 a6 mtlr r0 ffc0a8b8: 83 a1 00 0c lwz r29,12(r1) ffc0a8bc: 83 c1 00 10 lwz r30,16(r1) ffc0a8c0: 83 e1 00 14 lwz r31,20(r1) ffc0a8c4: 38 21 00 18 addi r1,r1,24 ffc0a8c8: 4e 80 00 20 blr index_base = _Objects_Get_index( information->minimum_id ); block_count = (information->maximum - index_base) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { if ( information->inactive_per_block[ block ] == ffc0a8cc: 3b e0 00 00 li r31,0 <== NOT EXECUTED information->allocation_size ) { /* * Assume the Inactive chain is never empty at this point */ the_object = (Objects_Control *) information->Inactive.first; ffc0a8d0: 80 7c 00 20 lwz r3,32(r28) ffc0a8d4: 48 00 00 10 b ffc0a8e4 <_Objects_Shrink_information+0xac> if ((index >= index_base) && (index < (index_base + information->allocation_size))) { _Chain_Extract( &extract_me->Node ); } } while ( the_object ); ffc0a8d8: 2f 9d 00 00 cmpwi cr7,r29,0 ffc0a8dc: 7f a3 eb 78 mr r3,r29 ffc0a8e0: 41 9e 00 34 beq- cr7,ffc0a914 <_Objects_Shrink_information+0xdc> * Assume the Inactive chain is never empty at this point */ the_object = (Objects_Control *) information->Inactive.first; do { index = _Objects_Get_index( the_object->id ); ffc0a8e4: a0 03 00 0a lhz r0,10(r3) /* * Get the next node before the node is extracted */ extract_me = the_object; the_object = (Objects_Control *) the_object->Node.next; ffc0a8e8: 83 a3 00 00 lwz r29,0(r3) if ((index >= index_base) && ffc0a8ec: 7f 80 f0 40 cmplw cr7,r0,r30 ffc0a8f0: 41 bc ff e8 blt- cr7,ffc0a8d8 <_Objects_Shrink_information+0xa0> (index < (index_base + information->allocation_size))) { ffc0a8f4: a1 3c 00 14 lhz r9,20(r28) ffc0a8f8: 7d 3e 4a 14 add r9,r30,r9 ffc0a8fc: 7f 80 48 40 cmplw cr7,r0,r9 ffc0a900: 40 9c ff d8 bge+ cr7,ffc0a8d8 <_Objects_Shrink_information+0xa0> _Chain_Extract( &extract_me->Node ); ffc0a904: 48 00 4d f1 bl ffc0f6f4 <_Chain_Extract> } } while ( the_object ); ffc0a908: 2f 9d 00 00 cmpwi cr7,r29,0 ffc0a90c: 7f a3 eb 78 mr r3,r29 ffc0a910: 40 9e ff d4 bne+ cr7,ffc0a8e4 <_Objects_Shrink_information+0xac> /* * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); ffc0a914: 81 3c 00 34 lwz r9,52(r28) ffc0a918: 7c 69 f8 2e lwzx r3,r9,r31 ffc0a91c: 48 00 23 5d bl ffc0cc78 <_Workspace_Free> information->object_blocks[ block ] = NULL; information->inactive_per_block[ block ] = 0; information->inactive -= information->allocation_size; ffc0a920: a1 5c 00 2c lhz r10,44(r28) ffc0a924: a0 1c 00 14 lhz r0,20(r28) /* * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); information->object_blocks[ block ] = NULL; ffc0a928: 81 3c 00 34 lwz r9,52(r28) information->inactive_per_block[ block ] = 0; information->inactive -= information->allocation_size; ffc0a92c: 7c 00 50 50 subf r0,r0,r10 * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); information->object_blocks[ block ] = NULL; information->inactive_per_block[ block ] = 0; ffc0a930: 81 7c 00 30 lwz r11,48(r28) information->inactive -= information->allocation_size; ffc0a934: b0 1c 00 2c sth r0,44(r28) return; } index_base += information->allocation_size; } } ffc0a938: 80 01 00 1c lwz r0,28(r1) * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); information->object_blocks[ block ] = NULL; information->inactive_per_block[ block ] = 0; ffc0a93c: 7f ab f9 2e stwx r29,r11,r31 return; } index_base += information->allocation_size; } } ffc0a940: 7c 08 03 a6 mtlr r0 /* * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); information->object_blocks[ block ] = NULL; ffc0a944: 7f a9 f9 2e stwx r29,r9,r31 return; } index_base += information->allocation_size; } } ffc0a948: 83 81 00 08 lwz r28,8(r1) ffc0a94c: 83 a1 00 0c lwz r29,12(r1) ffc0a950: 83 c1 00 10 lwz r30,16(r1) ffc0a954: 83 e1 00 14 lwz r31,20(r1) ffc0a958: 38 21 00 18 addi r1,r1,24 ffc0a95c: 4e 80 00 20 blr ffc0ec48 <_POSIX_Threads_Exitted_extension>: * This method is invoked each time a thread exits. */ void _POSIX_Threads_Exitted_extension( Thread_Control *executing ) { ffc0ec48: 7c 08 02 a6 mflr r0 ffc0ec4c: 94 21 ff f8 stwu r1,-8(r1) ffc0ec50: 90 01 00 0c stw r0,12(r1) /* * If the executing thread was not created with the POSIX API, then this * API do not get to define its exit behavior. */ if ( _Objects_Get_API( executing->Object.id ) == OBJECTS_POSIX_API ) ffc0ec54: 88 03 00 08 lbz r0,8(r3) ffc0ec58: 54 00 07 7e clrlwi r0,r0,29 ffc0ec5c: 2f 80 00 03 cmpwi cr7,r0,3 ffc0ec60: 41 9e 00 14 beq- cr7,ffc0ec74 <_POSIX_Threads_Exitted_extension+0x2c> pthread_exit( executing->Wait.return_argument ); } ffc0ec64: 80 01 00 0c lwz r0,12(r1) ffc0ec68: 38 21 00 08 addi r1,r1,8 ffc0ec6c: 7c 08 03 a6 mtlr r0 ffc0ec70: 4e 80 00 20 blr /* * If the executing thread was not created with the POSIX API, then this * API do not get to define its exit behavior. */ if ( _Objects_Get_API( executing->Object.id ) == OBJECTS_POSIX_API ) pthread_exit( executing->Wait.return_argument ); ffc0ec74: 80 63 00 28 lwz r3,40(r3) ffc0ec78: 48 00 2e cd bl ffc11b44 } ffc0ec7c: 80 01 00 0c lwz r0,12(r1) <== NOT EXECUTED ffc0ec80: 38 21 00 08 addi r1,r1,8 <== NOT EXECUTED ffc0ec84: 7c 08 03 a6 mtlr r0 <== NOT EXECUTED ffc0ec88: 4e 80 00 20 blr <== NOT EXECUTED ffc0eebc <_POSIX_Threads_Sporadic_budget_callout>: * _POSIX_Threads_Sporadic_budget_callout */ void _POSIX_Threads_Sporadic_budget_callout( Thread_Control *the_thread ) { ffc0eebc: 7c 08 02 a6 mflr r0 ffc0eec0: 94 21 ff f8 stwu r1,-8(r1) RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core( int priority ) { return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1); ffc0eec4: 3d 40 00 00 lis r10,0 ffc0eec8: 90 01 00 0c stw r0,12(r1) */ #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 ) { ffc0eecc: 80 03 00 1c lwz r0,28(r3) ) { POSIX_API_Control *api; uint32_t new_priority; api = the_thread->API_Extensions[ THREAD_API_POSIX ]; ffc0eed0: 81 63 01 48 lwz r11,328(r3) */ #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 ) { ffc0eed4: 2f 80 00 00 cmpwi cr7,r0,0 ffc0eed8: 88 8a 26 a4 lbz r4,9892(r10) ffc0eedc: 80 0b 00 88 lwz r0,136(r11) ffc0eee0: 7c 80 20 50 subf r4,r0,r4 /* * 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 */ ffc0eee4: 38 00 ff ff li r0,-1 new_priority = _POSIX_Priority_To_core(api->schedparam.sched_ss_low_priority); the_thread->real_priority = new_priority; ffc0eee8: 90 83 00 18 stw r4,24(r3) /* * 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 */ ffc0eeec: 90 03 00 78 stw r0,120(r3) */ #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 ) { ffc0eef0: 40 9e 00 10 bne- cr7,ffc0ef00 <_POSIX_Threads_Sporadic_budget_callout+0x44> /* * 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 ) { ffc0eef4: 80 03 00 14 lwz r0,20(r3) ffc0eef8: 7f 80 20 40 cmplw cr7,r0,r4 ffc0eefc: 41 9c 00 14 blt- cr7,ffc0ef10 <_POSIX_Threads_Sporadic_budget_callout+0x54> #if 0 printk( "lower priority\n" ); #endif } } } ffc0ef00: 80 01 00 0c lwz r0,12(r1) <== NOT EXECUTED ffc0ef04: 38 21 00 08 addi r1,r1,8 <== NOT EXECUTED ffc0ef08: 7c 08 03 a6 mtlr r0 <== NOT EXECUTED ffc0ef0c: 4e 80 00 20 blr <== 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 ) { _Thread_Change_priority( the_thread, new_priority, true ); ffc0ef10: 38 a0 00 01 li r5,1 ffc0ef14: 4b ff bb 81 bl ffc0aa94 <_Thread_Change_priority> #if 0 printk( "lower priority\n" ); #endif } } } ffc0ef18: 80 01 00 0c lwz r0,12(r1) ffc0ef1c: 38 21 00 08 addi r1,r1,8 ffc0ef20: 7c 08 03 a6 mtlr r0 ffc0ef24: 4e 80 00 20 blr ffc08ac0 <_POSIX_Timer_TSR>: * This is the operation that is run when a timer expires */ void _POSIX_Timer_TSR( Objects_Id timer __attribute__((unused)), void *data) { ffc08ac0: 94 21 ff f0 stwu r1,-16(r1) ffc08ac4: 7c 08 02 a6 mflr r0 ffc08ac8: 90 01 00 14 stw r0,20(r1) /* Increment the number of expirations. */ ptimer->overrun = ptimer->overrun + 1; /* The timer must be reprogrammed */ if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) || ffc08acc: 80 04 00 54 lwz r0,84(r4) bool activated; ptimer = (POSIX_Timer_Control *)data; /* Increment the number of expirations. */ ptimer->overrun = ptimer->overrun + 1; ffc08ad0: 81 24 00 68 lwz r9,104(r4) /* The timer must be reprogrammed */ if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) || ffc08ad4: 2f 80 00 00 cmpwi cr7,r0,0 * This is the operation that is run when a timer expires */ void _POSIX_Timer_TSR( Objects_Id timer __attribute__((unused)), void *data) { ffc08ad8: 93 e1 00 0c stw r31,12(r1) bool activated; ptimer = (POSIX_Timer_Control *)data; /* Increment the number of expirations. */ ptimer->overrun = ptimer->overrun + 1; ffc08adc: 38 09 00 01 addi r0,r9,1 * This is the operation that is run when a timer expires */ void _POSIX_Timer_TSR( Objects_Id timer __attribute__((unused)), void *data) { ffc08ae0: 7c 9f 23 78 mr r31,r4 bool activated; ptimer = (POSIX_Timer_Control *)data; /* Increment the number of expirations. */ ptimer->overrun = ptimer->overrun + 1; ffc08ae4: 90 04 00 68 stw r0,104(r4) /* The timer must be reprogrammed */ if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) || ffc08ae8: 40 9e 00 40 bne- cr7,ffc08b28 <_POSIX_Timer_TSR+0x68> ( ptimer->timer_data.it_interval.tv_nsec != 0 ) ) { ffc08aec: 80 04 00 58 lwz r0,88(r4) ffc08af0: 2f 80 00 00 cmpwi cr7,r0,0 ffc08af4: 40 9e 00 34 bne- cr7,ffc08b28 <_POSIX_Timer_TSR+0x68> /* 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; ffc08af8: 38 00 00 04 li r0,4 <== NOT EXECUTED ffc08afc: 98 04 00 3c stb r0,60(r4) <== 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 ) ) { ffc08b00: 80 7f 00 38 lwz r3,56(r31) ffc08b04: 80 9f 00 44 lwz r4,68(r31) ffc08b08: 48 00 72 15 bl ffc0fd1c } /* After the signal handler returns, the count of expirations of the * timer must be set to 0. */ ptimer->overrun = 0; ffc08b0c: 38 00 00 00 li r0,0 ffc08b10: 90 1f 00 68 stw r0,104(r31) } ffc08b14: 80 01 00 14 lwz r0,20(r1) ffc08b18: 83 e1 00 0c lwz r31,12(r1) ffc08b1c: 38 21 00 10 addi r1,r1,16 ffc08b20: 7c 08 03 a6 mtlr r0 ffc08b24: 4e 80 00 20 blr ptimer->overrun = ptimer->overrun + 1; /* The timer must be reprogrammed */ if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) || ( ptimer->timer_data.it_interval.tv_nsec != 0 ) ) { activated = _POSIX_Timer_Insert_helper( ffc08b28: 80 9f 00 64 lwz r4,100(r31) ffc08b2c: 3c c0 ff c1 lis r6,-63 ffc08b30: 80 bf 00 08 lwz r5,8(r31) ffc08b34: 38 c6 8a c0 addi r6,r6,-30016 ffc08b38: 38 7f 00 10 addi r3,r31,16 ffc08b3c: 7f e7 fb 78 mr r7,r31 ffc08b40: 48 00 77 fd bl ffc1033c <_POSIX_Timer_Insert_helper> ptimer->ticks, ptimer->Object.id, _POSIX_Timer_TSR, ptimer ); if ( !activated ) ffc08b44: 2f 83 00 00 cmpwi cr7,r3,0 ffc08b48: 41 9e ff cc beq+ cr7,ffc08b14 <_POSIX_Timer_TSR+0x54> return; /* Store the time when the timer was started again */ _TOD_Get( &ptimer->time ); ffc08b4c: 38 7f 00 6c addi r3,r31,108 ffc08b50: 48 00 1e 25 bl ffc0a974 <_TOD_Get> /* The state really did not change but just to be safe */ ptimer->state = POSIX_TIMER_STATE_CREATE_RUN; ffc08b54: 38 00 00 03 li r0,3 ffc08b58: 98 1f 00 3c stb r0,60(r31) /* Increment the number of expirations. */ ptimer->overrun = ptimer->overrun + 1; /* The timer must be reprogrammed */ if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) || ffc08b5c: 4b ff ff a4 b ffc08b00 <_POSIX_Timer_TSR+0x40> ffc12dec <_POSIX_signals_Clear_process_signals>: static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc12dec: 7d 60 00 a6 mfmsr r11 ffc12df0: 7c 10 42 a6 mfsprg r0,0 ffc12df4: 7d 60 00 78 andc r0,r11,r0 ffc12df8: 7c 00 01 24 mtmsr r0 mask = signo_to_mask( signo ); ISR_Level level; _ISR_Disable( level ); if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) { ffc12dfc: 3d 20 00 00 lis r9,0 ffc12e00: 1c 03 00 0c mulli r0,r3,12 ffc12e04: 39 29 31 70 addi r9,r9,12656 ffc12e08: 7d 29 00 2e lwzx r9,r9,r0 ffc12e0c: 2f 89 00 02 cmpwi cr7,r9,2 ffc12e10: 41 9e 00 40 beq- cr7,ffc12e50 <_POSIX_signals_Clear_process_signals+0x64> if ( !_Chain_Is_empty( &_POSIX_signals_Siginfo[ signo ] ) ) clear_signal = false; } if ( clear_signal ) { _POSIX_signals_Pending &= ~mask; ffc12e14: 3d 20 00 00 lis r9,0 ffc12e18: 80 09 27 e4 lwz r0,10212(r9) ffc12e1c: 38 63 ff ff addi r3,r3,-1 ffc12e20: 39 40 ff fe li r10,-2 ffc12e24: 5d 43 18 3e rotlw r3,r10,r3 ffc12e28: 7c 63 00 38 and r3,r3,r0 if ( !_POSIX_signals_Pending ) ffc12e2c: 2f 83 00 00 cmpwi cr7,r3,0 if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) { if ( !_Chain_Is_empty( &_POSIX_signals_Siginfo[ signo ] ) ) clear_signal = false; } if ( clear_signal ) { _POSIX_signals_Pending &= ~mask; ffc12e30: 90 69 27 e4 stw r3,10212(r9) if ( !_POSIX_signals_Pending ) ffc12e34: 40 9e 00 14 bne- cr7,ffc12e48 <_POSIX_signals_Clear_process_signals+0x5c> _Thread_Do_post_task_switch_extension--; ffc12e38: 3d 20 00 00 lis r9,0 ffc12e3c: 81 49 27 a0 lwz r10,10144(r9) ffc12e40: 38 0a ff ff addi r0,r10,-1 ffc12e44: 90 09 27 a0 stw r0,10144(r9) return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc12e48: 7d 60 01 24 mtmsr r11 } _ISR_Enable( level ); } ffc12e4c: 4e 80 00 20 blr ISR_Level level; _ISR_Disable( level ); if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) { if ( !_Chain_Is_empty( &_POSIX_signals_Siginfo[ signo ] ) ) ffc12e50: 3d 20 00 00 lis r9,0 ffc12e54: 39 29 33 64 addi r9,r9,13156 ffc12e58: 7d 49 00 2e lwzx r10,r9,r0 ffc12e5c: 7d 29 02 14 add r9,r9,r0 ffc12e60: 38 09 00 04 addi r0,r9,4 ffc12e64: 7f 8a 00 00 cmpw cr7,r10,r0 ffc12e68: 41 be ff ac beq- cr7,ffc12e14 <_POSIX_signals_Clear_process_signals+0x28> ffc12e6c: 7d 60 01 24 mtmsr r11 <== NOT EXECUTED _POSIX_signals_Pending &= ~mask; if ( !_POSIX_signals_Pending ) _Thread_Do_post_task_switch_extension--; } _ISR_Enable( level ); } ffc12e70: 4e 80 00 20 blr <== NOT EXECUTED ffc0aa94 <_Thread_Change_priority>: void _Thread_Change_priority( Thread_Control *the_thread, Priority_Control new_priority, bool prepend_it ) { ffc0aa94: 94 21 ff e8 stwu r1,-24(r1) ffc0aa98: 7c 08 02 a6 mflr r0 ffc0aa9c: 90 01 00 1c stw r0,28(r1) ffc0aaa0: 93 e1 00 14 stw r31,20(r1) ffc0aaa4: 7c 7f 1b 78 mr r31,r3 ffc0aaa8: 93 81 00 08 stw r28,8(r1) ffc0aaac: 7c bc 2b 78 mr r28,r5 ffc0aab0: 93 a1 00 0c stw r29,12(r1) ffc0aab4: 93 c1 00 10 stw r30,16(r1) ffc0aab8: 7c 9e 23 78 mr r30,r4 */ /* * Save original state */ original_state = the_thread->current_state; ffc0aabc: 83 a3 00 10 lwz r29,16(r3) /* * Set a transient state for the thread so it is pulled off the Ready chains. * This will prevent it from being scheduled no matter what happens in an * ISR. */ _Thread_Set_transient( the_thread ); ffc0aac0: 48 00 13 81 bl ffc0be40 <_Thread_Set_transient> /* * Do not bother recomputing all the priority related information if * we are not REALLY changing priority. */ if ( the_thread->current_priority != new_priority ) ffc0aac4: 80 1f 00 14 lwz r0,20(r31) ffc0aac8: 7f 80 f0 00 cmpw cr7,r0,r30 ffc0aacc: 41 9e 00 10 beq- cr7,ffc0aadc <_Thread_Change_priority+0x48> _Thread_Set_priority( the_thread, new_priority ); ffc0aad0: 7f c4 f3 78 mr r4,r30 ffc0aad4: 7f e3 fb 78 mr r3,r31 ffc0aad8: 48 00 11 e9 bl ffc0bcc0 <_Thread_Set_priority> static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc0aadc: 7d 20 00 a6 mfmsr r9 ffc0aae0: 7c 10 42 a6 mfsprg r0,0 ffc0aae4: 7d 20 00 78 andc r0,r9,r0 ffc0aae8: 7c 00 01 24 mtmsr r0 /* * If the thread has more than STATES_TRANSIENT set, then it is blocked, * If it is blocked on a thread queue, then we need to requeue it. */ state = the_thread->current_state; ffc0aaec: 80 1f 00 10 lwz r0,16(r31) if ( state != STATES_TRANSIENT ) { ffc0aaf0: 2f 80 00 04 cmpwi cr7,r0,4 ffc0aaf4: 41 9e 00 88 beq- cr7,ffc0ab7c <_Thread_Change_priority+0xe8> /* Only clear the transient state if it wasn't set already */ if ( ! _States_Is_transient( original_state ) ) ffc0aaf8: 73 ab 00 04 andi. r11,r29,4 ffc0aafc: 41 82 00 38 beq- ffc0ab34 <_Thread_Change_priority+0xa0> return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc0ab00: 7d 20 01 24 mtmsr r9 <== NOT EXECUTED the_thread->current_state = _States_Clear( STATES_TRANSIENT, state ); _ISR_Enable( level ); if ( _States_Is_waiting_on_thread_queue( state ) ) { ffc0ab04: 3d 20 00 03 lis r9,3 <== NOT EXECUTED ffc0ab08: 61 29 be e0 ori r9,r9,48864 <== NOT EXECUTED ffc0ab0c: 7c 0b 48 39 and. r11,r0,r9 <== NOT EXECUTED ffc0ab10: 40 82 00 40 bne- ffc0ab50 <_Thread_Change_priority+0xbc><== NOT EXECUTED if ( !_Thread_Is_executing_also_the_heir() && _Thread_Executing->is_preemptible ) _Context_Switch_necessary = true; _ISR_Enable( level ); } ffc0ab14: 80 01 00 1c lwz r0,28(r1) ffc0ab18: 83 81 00 08 lwz r28,8(r1) ffc0ab1c: 7c 08 03 a6 mtlr r0 ffc0ab20: 83 a1 00 0c lwz r29,12(r1) ffc0ab24: 83 c1 00 10 lwz r30,16(r1) ffc0ab28: 83 e1 00 14 lwz r31,20(r1) ffc0ab2c: 38 21 00 18 addi r1,r1,24 ffc0ab30: 4e 80 00 20 blr */ state = the_thread->current_state; if ( state != STATES_TRANSIENT ) { /* Only clear the transient state if it wasn't set already */ if ( ! _States_Is_transient( original_state ) ) the_thread->current_state = _States_Clear( STATES_TRANSIENT, state ); ffc0ab34: 54 0b 07 b8 rlwinm r11,r0,0,30,28 ffc0ab38: 91 7f 00 10 stw r11,16(r31) ffc0ab3c: 7d 20 01 24 mtmsr r9 _ISR_Enable( level ); if ( _States_Is_waiting_on_thread_queue( state ) ) { ffc0ab40: 3d 20 00 03 lis r9,3 ffc0ab44: 61 29 be e0 ori r9,r9,48864 ffc0ab48: 7c 0b 48 39 and. r11,r0,r9 ffc0ab4c: 41 82 ff c8 beq+ ffc0ab14 <_Thread_Change_priority+0x80> _Thread_queue_Requeue( the_thread->Wait.queue, the_thread ); ffc0ab50: 80 7f 00 44 lwz r3,68(r31) ffc0ab54: 7f e4 fb 78 mr r4,r31 ffc0ab58: 48 00 10 71 bl ffc0bbc8 <_Thread_queue_Requeue> if ( !_Thread_Is_executing_also_the_heir() && _Thread_Executing->is_preemptible ) _Context_Switch_necessary = true; _ISR_Enable( level ); } ffc0ab5c: 80 01 00 1c lwz r0,28(r1) ffc0ab60: 83 81 00 08 lwz r28,8(r1) ffc0ab64: 7c 08 03 a6 mtlr r0 ffc0ab68: 83 a1 00 0c lwz r29,12(r1) ffc0ab6c: 83 c1 00 10 lwz r30,16(r1) ffc0ab70: 83 e1 00 14 lwz r31,20(r1) ffc0ab74: 38 21 00 18 addi r1,r1,24 ffc0ab78: 4e 80 00 20 blr } return; } /* Only clear the transient state if it wasn't set already */ if ( ! _States_Is_transient( original_state ) ) { ffc0ab7c: 73 bd 00 04 andi. r29,r29,4 ffc0ab80: 3d 40 00 00 lis r10,0 ffc0ab84: 40 82 00 4c bne- ffc0abd0 <_Thread_Change_priority+0x13c> * Interrupts are STILL disabled. * We now know the thread will be in the READY state when we remove * the TRANSIENT state. So we have to place it on the appropriate * Ready Queue with interrupts off. */ the_thread->current_state = _States_Clear( STATES_TRANSIENT, state ); ffc0ab88: 93 bf 00 10 stw r29,16(r31) _Priority_Add_to_bit_map( &the_thread->Priority_map ); if ( prepend_it ) ffc0ab8c: 2f 9c 00 00 cmpwi cr7,r28,0 RTEMS_INLINE_ROUTINE void _Priority_Add_to_bit_map ( Priority_Information *the_priority_map ) { *the_priority_map->minor |= the_priority_map->ready_minor; ffc0ab90: 81 7f 00 90 lwz r11,144(r31) ffc0ab94: 80 1f 00 98 lwz r0,152(r31) ffc0ab98: 81 0b 00 00 lwz r8,0(r11) ffc0ab9c: 7d 00 03 78 or r0,r8,r0 ffc0aba0: 90 0b 00 00 stw r0,0(r11) _Priority_Major_bit_map |= the_priority_map->ready_major; ffc0aba4: 81 6a 27 a4 lwz r11,10148(r10) ffc0aba8: 80 1f 00 94 lwz r0,148(r31) ffc0abac: 7d 60 03 78 or r0,r11,r0 ffc0abb0: 90 0a 27 a4 stw r0,10148(r10) ffc0abb4: 41 9e 00 b8 beq- cr7,ffc0ac6c <_Thread_Change_priority+0x1d8> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Head( Chain_Control *the_chain ) { return (Chain_Node *) the_chain; ffc0abb8: 81 7f 00 8c lwz r11,140(r31) ) { Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; ffc0abbc: 81 0b 00 00 lwz r8,0(r11) Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; ffc0abc0: 91 7f 00 04 stw r11,4(r31) before_node = after_node->next; after_node->next = the_node; ffc0abc4: 93 eb 00 00 stw r31,0(r11) the_node->next = before_node; before_node->previous = the_node; ffc0abc8: 93 e8 00 04 stw r31,4(r8) Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; after_node->next = the_node; the_node->next = before_node; ffc0abcc: 91 1f 00 00 stw r8,0(r31) static inline void ppc_interrupt_flash( uint32_t level ) { uint32_t current_level; asm volatile ( ffc0abd0: 7c 00 00 a6 mfmsr r0 ffc0abd4: 7d 20 01 24 mtmsr r9 ffc0abd8: 7c 00 01 24 mtmsr r0 */ RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void ) { _Thread_Heir = (Thread_Control *) _Thread_Ready_chain[ _Priority_Get_highest() ].first; ffc0abdc: 3d 00 00 00 lis r8,0 RTEMS_INLINE_ROUTINE Priority_Control _Priority_Get_highest( void ) { Priority_Bit_map_control minor; Priority_Bit_map_control major; _Bitfield_Find_first_bit( _Priority_Major_bit_map, major ); ffc0abe0: 81 6a 27 a4 lwz r11,10148(r10) ffc0abe4: 80 a8 27 64 lwz r5,10084(r8) ffc0abe8: 7d 66 00 34 cntlzw r6,r11 _Bitfield_Find_first_bit( _Priority_Bit_map[major], minor ); ffc0abec: 3c e0 00 00 lis r7,0 RTEMS_INLINE_ROUTINE Priority_Control _Priority_Get_highest( void ) { Priority_Bit_map_control minor; Priority_Bit_map_control major; _Bitfield_Find_first_bit( _Priority_Major_bit_map, major ); ffc0abf0: 91 6a 27 a4 stw r11,10148(r10) _Bitfield_Find_first_bit( _Priority_Bit_map[major], minor ); ffc0abf4: 38 e7 2d a0 addi r7,r7,11680 ffc0abf8: 54 c8 10 3a rlwinm r8,r6,2,0,29 ffc0abfc: 7c 07 40 2e lwzx r0,r7,r8 ffc0ac00: 7c 0b 00 34 cntlzw r11,r0 * ready thread. */ RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void ) { _Thread_Heir = (Thread_Control *) ffc0ac04: 54 c6 20 36 rlwinm r6,r6,4,0,27 ffc0ac08: 7c 07 41 2e stwx r0,r7,r8 ffc0ac0c: 7c c6 5a 14 add r6,r6,r11 ffc0ac10: 1c c6 00 0c mulli r6,r6,12 * is also the heir thread, and false otherwise. */ RTEMS_INLINE_ROUTINE bool _Thread_Is_executing_also_the_heir( void ) { return ( _Thread_Executing == _Thread_Heir ); ffc0ac14: 3d 60 00 00 lis r11,0 * ready thread. */ RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void ) { _Thread_Heir = (Thread_Control *) ffc0ac18: 7c 05 30 2e lwzx r0,r5,r6 * is also the heir thread, and false otherwise. */ RTEMS_INLINE_ROUTINE bool _Thread_Is_executing_also_the_heir( void ) { return ( _Thread_Executing == _Thread_Heir ); ffc0ac1c: 81 6b 27 b0 lwz r11,10160(r11) * ready thread. */ RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void ) { _Thread_Heir = (Thread_Control *) ffc0ac20: 3d 40 00 00 lis r10,0 ffc0ac24: 90 0a 27 8c stw r0,10124(r10) * We altered the set of thread priorities. So let's figure out * who is the heir and if we need to switch to them. */ _Thread_Calculate_heir(); if ( !_Thread_Is_executing_also_the_heir() && ffc0ac28: 7f 80 58 00 cmpw cr7,r0,r11 ffc0ac2c: 41 9e 00 1c beq- cr7,ffc0ac48 <_Thread_Change_priority+0x1b4> _Thread_Executing->is_preemptible ) ffc0ac30: 88 0b 00 75 lbz r0,117(r11) ffc0ac34: 2f 80 00 00 cmpwi cr7,r0,0 ffc0ac38: 41 9e 00 10 beq- cr7,ffc0ac48 <_Thread_Change_priority+0x1b4> _Context_Switch_necessary = true; ffc0ac3c: 38 00 00 01 li r0,1 ffc0ac40: 3d 60 00 00 lis r11,0 ffc0ac44: 98 0b 27 c0 stb r0,10176(r11) return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc0ac48: 7d 20 01 24 mtmsr r9 _ISR_Enable( level ); } ffc0ac4c: 80 01 00 1c lwz r0,28(r1) ffc0ac50: 83 81 00 08 lwz r28,8(r1) ffc0ac54: 7c 08 03 a6 mtlr r0 ffc0ac58: 83 a1 00 0c lwz r29,12(r1) ffc0ac5c: 83 c1 00 10 lwz r30,16(r1) ffc0ac60: 83 e1 00 14 lwz r31,20(r1) ffc0ac64: 38 21 00 18 addi r1,r1,24 ffc0ac68: 4e 80 00 20 blr _Priority_Add_to_bit_map( &the_thread->Priority_map ); if ( prepend_it ) _Chain_Prepend_unprotected( the_thread->ready, &the_thread->Object.Node ); else _Chain_Append_unprotected( the_thread->ready, &the_thread->Object.Node ); ffc0ac6c: 81 7f 00 8c lwz r11,140(r31) Chain_Node *the_node ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); ffc0ac70: 38 0b 00 04 addi r0,r11,4 ffc0ac74: 90 1f 00 00 stw r0,0(r31) old_last_node = the_chain->last; ffc0ac78: 81 0b 00 08 lwz r8,8(r11) the_chain->last = the_node; ffc0ac7c: 93 eb 00 08 stw r31,8(r11) old_last_node->next = the_node; the_node->previous = old_last_node; ffc0ac80: 91 1f 00 04 stw r8,4(r31) Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); old_last_node = the_chain->last; the_chain->last = the_node; old_last_node->next = the_node; ffc0ac84: 93 e8 00 00 stw r31,0(r8) ffc0ac88: 4b ff ff 48 b ffc0abd0 <_Thread_Change_priority+0x13c> ffc10248 <_Thread_Reset_timeslice>: { ISR_Level level; Thread_Control *executing; Chain_Control *ready; executing = _Thread_Executing; ffc10248: 3d 20 00 00 lis r9,0 ffc1024c: 81 29 27 b0 lwz r9,10160(r9) ready = executing->ready; ffc10250: 81 69 00 8c lwz r11,140(r9) static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc10254: 7c 00 00 a6 mfmsr r0 ffc10258: 7d 50 42 a6 mfsprg r10,0 ffc1025c: 7c 0a 50 78 andc r10,r0,r10 ffc10260: 7d 40 01 24 mtmsr r10 _ISR_Disable( level ); if ( _Chain_Has_only_one_node( ready ) ) { ffc10264: 81 0b 00 00 lwz r8,0(r11) ffc10268: 81 4b 00 08 lwz r10,8(r11) ffc1026c: 7f 88 50 00 cmpw cr7,r8,r10 ffc10270: 41 9e 00 78 beq- cr7,ffc102e8 <_Thread_Reset_timeslice+0xa0> ) { Chain_Node *next; Chain_Node *previous; next = the_node->next; ffc10274: 81 49 00 00 lwz r10,0(r9) Chain_Node *the_node ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); ffc10278: 38 eb 00 04 addi r7,r11,4 { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; ffc1027c: 81 09 00 04 lwz r8,4(r9) next->previous = previous; previous->next = next; ffc10280: 91 48 00 00 stw r10,0(r8) Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; next->previous = previous; ffc10284: 91 0a 00 04 stw r8,4(r10) Chain_Node *the_node ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); ffc10288: 90 e9 00 00 stw r7,0(r9) old_last_node = the_chain->last; ffc1028c: 81 4b 00 08 lwz r10,8(r11) the_chain->last = the_node; ffc10290: 91 2b 00 08 stw r9,8(r11) old_last_node->next = the_node; the_node->previous = old_last_node; ffc10294: 91 49 00 04 stw r10,4(r9) Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); old_last_node = the_chain->last; the_chain->last = the_node; old_last_node->next = the_node; ffc10298: 91 2a 00 00 stw r9,0(r10) static inline void ppc_interrupt_flash( uint32_t level ) { uint32_t current_level; asm volatile ( ffc1029c: 7d 40 00 a6 mfmsr r10 ffc102a0: 7c 00 01 24 mtmsr r0 ffc102a4: 7d 40 01 24 mtmsr r10 _Chain_Extract_unprotected( &executing->Object.Node ); _Chain_Append_unprotected( ready, &executing->Object.Node ); _ISR_Flash( level ); if ( _Thread_Is_heir( executing ) ) ffc102a8: 3d 40 00 00 lis r10,0 ffc102ac: 81 0a 27 8c lwz r8,10124(r10) ffc102b0: 7f 89 40 00 cmpw cr7,r9,r8 ffc102b4: 41 9e 00 18 beq- cr7,ffc102cc <_Thread_Reset_timeslice+0x84> _Thread_Heir = (Thread_Control *) ready->first; _Context_Switch_necessary = true; ffc102b8: 39 60 00 01 li r11,1 <== NOT EXECUTED ffc102bc: 3d 20 00 00 lis r9,0 <== NOT EXECUTED ffc102c0: 99 69 27 c0 stb r11,10176(r9) <== NOT EXECUTED return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc102c4: 7c 00 01 24 mtmsr r0 <== NOT EXECUTED ffc102c8: 4e 80 00 20 blr <== NOT EXECUTED _Chain_Append_unprotected( ready, &executing->Object.Node ); _ISR_Flash( level ); if ( _Thread_Is_heir( executing ) ) _Thread_Heir = (Thread_Control *) ready->first; ffc102cc: 81 2b 00 00 lwz r9,0(r11) _Context_Switch_necessary = true; ffc102d0: 39 60 00 01 li r11,1 _Chain_Append_unprotected( ready, &executing->Object.Node ); _ISR_Flash( level ); if ( _Thread_Is_heir( executing ) ) _Thread_Heir = (Thread_Control *) ready->first; ffc102d4: 91 2a 27 8c stw r9,10124(r10) _Context_Switch_necessary = true; ffc102d8: 3d 20 00 00 lis r9,0 ffc102dc: 99 69 27 c0 stb r11,10176(r9) ffc102e0: 7c 00 01 24 mtmsr r0 ffc102e4: 4e 80 00 20 blr ffc102e8: 7c 00 01 24 mtmsr r0 ffc102ec: 4e 80 00 20 blr ffc0cd3c <_Thread_Restart>: bool _Thread_Restart( Thread_Control *the_thread, void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { ffc0cd3c: 94 21 ff e8 stwu r1,-24(r1) ffc0cd40: 7c 08 02 a6 mflr r0 ffc0cd44: 90 01 00 1c stw r0,28(r1) if ( !_States_Is_dormant( the_thread->current_state ) ) { ffc0cd48: 80 03 00 10 lwz r0,16(r3) bool _Thread_Restart( Thread_Control *the_thread, void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { ffc0cd4c: 93 e1 00 14 stw r31,20(r1) ffc0cd50: 7c 7f 1b 78 mr r31,r3 if ( !_States_Is_dormant( the_thread->current_state ) ) { ffc0cd54: 70 09 00 01 andi. r9,r0,1 bool _Thread_Restart( Thread_Control *the_thread, void *pointer_argument, Thread_Entry_numeric_type numeric_argument ) { ffc0cd58: 93 c1 00 10 stw r30,16(r1) if ( !_States_Is_dormant( the_thread->current_state ) ) { ffc0cd5c: 38 00 00 00 li r0,0 ffc0cd60: 41 82 00 20 beq- ffc0cd80 <_Thread_Restart+0x44> return true; } return false; } ffc0cd64: 7c 03 03 78 mr r3,r0 ffc0cd68: 80 01 00 1c lwz r0,28(r1) ffc0cd6c: 83 c1 00 10 lwz r30,16(r1) ffc0cd70: 7c 08 03 a6 mtlr r0 ffc0cd74: 83 e1 00 14 lwz r31,20(r1) ffc0cd78: 38 21 00 18 addi r1,r1,24 ffc0cd7c: 4e 80 00 20 blr Thread_Entry_numeric_type numeric_argument ) { if ( !_States_Is_dormant( the_thread->current_state ) ) { _Thread_Set_transient( the_thread ); ffc0cd80: 90 81 00 08 stw r4,8(r1) _Thread_Ready( the_thread ); _User_extensions_Thread_restart( the_thread ); if ( _Thread_Is_executing ( the_thread ) ) ffc0cd84: 3f c0 00 00 lis r30,0 Thread_Entry_numeric_type numeric_argument ) { if ( !_States_Is_dormant( the_thread->current_state ) ) { _Thread_Set_transient( the_thread ); ffc0cd88: 90 a1 00 0c stw r5,12(r1) ffc0cd8c: 48 00 01 e5 bl ffc0cf70 <_Thread_Set_transient> _Thread_Reset( the_thread, pointer_argument, numeric_argument ); ffc0cd90: 7f e3 fb 78 mr r3,r31 ffc0cd94: 80 81 00 08 lwz r4,8(r1) ffc0cd98: 80 a1 00 0c lwz r5,12(r1) ffc0cd9c: 48 00 47 91 bl ffc1152c <_Thread_Reset> _Thread_Load_environment( the_thread ); ffc0cda0: 7f e3 fb 78 mr r3,r31 ffc0cda4: 48 00 43 3d bl ffc110e0 <_Thread_Load_environment> _Thread_Ready( the_thread ); ffc0cda8: 7f e3 fb 78 mr r3,r31 ffc0cdac: 48 00 46 a5 bl ffc11450 <_Thread_Ready> _User_extensions_Thread_restart( the_thread ); ffc0cdb0: 7f e3 fb 78 mr r3,r31 ffc0cdb4: 48 00 0b 05 bl ffc0d8b8 <_User_extensions_Thread_restart> if ( _Thread_Is_executing ( the_thread ) ) ffc0cdb8: 81 3e 27 fc lwz r9,10236(r30) ffc0cdbc: 38 00 00 01 li r0,1 ffc0cdc0: 7f 9f 48 00 cmpw cr7,r31,r9 ffc0cdc4: 40 9e ff a0 bne+ cr7,ffc0cd64 <_Thread_Restart+0x28> */ RTEMS_INLINE_ROUTINE void _Thread_Restart_self( void ) { #if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE ) if ( _Thread_Executing->fp_context != NULL ) ffc0cdc8: 80 1f 01 3c lwz r0,316(r31) ffc0cdcc: 2f 80 00 00 cmpwi cr7,r0,0 ffc0cdd0: 41 9e 00 10 beq- cr7,ffc0cde0 <_Thread_Restart+0xa4> _Context_Restore_fp( &_Thread_Executing->fp_context ); ffc0cdd4: 38 7f 01 3c addi r3,r31,316 ffc0cdd8: 48 01 4b c9 bl ffc219a0 <_CPU_Context_restore_fp> ffc0cddc: 83 fe 27 fc lwz r31,10236(r30) #endif _CPU_Context_Restart_self( &_Thread_Executing->Registers ); ffc0cde0: 38 7f 00 dc addi r3,r31,220 ffc0cde4: 48 01 4d 7d bl ffc21b60 <_CPU_Context_restore> ffc0cde8: 38 00 00 01 li r0,1 <== NOT EXECUTED ffc0cdec: 4b ff ff 78 b ffc0cd64 <_Thread_Restart+0x28> <== NOT EXECUTED ffc0b900 <_Thread_queue_Enqueue_priority>: Priority_Control priority; States_Control block_state; _Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; ffc0b900: 80 04 00 14 lwz r0,20(r4) */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); ffc0b904: 39 04 00 3c addi r8,r4,60 Thread_blocking_operation_States _Thread_queue_Enqueue_priority ( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread, ISR_Level *level_p ) { ffc0b908: 94 21 ff f0 stwu r1,-16(r1) the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); ffc0b90c: 39 64 00 38 addi r11,r4,56 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 ) ) ffc0b910: 70 09 00 20 andi. r9,r0,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 ]; ffc0b914: 54 0a d1 be rlwinm r10,r0,26,6,31 */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); ffc0b918: 91 04 00 38 stw r8,56(r4) ffc0b91c: 1d 4a 00 0c mulli r10,r10,12 Thread_blocking_operation_States _Thread_queue_Enqueue_priority ( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread, ISR_Level *level_p ) { ffc0b920: 93 e1 00 0c stw r31,12(r1) the_chain->permanent_null = NULL; ffc0b924: 39 00 00 00 li r8,0 _Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; header_index = _Thread_queue_Header_number( priority ); header = &the_thread_queue->Queues.Priority[ header_index ]; block_state = the_thread_queue->state; ffc0b928: 81 23 00 38 lwz r9,56(r3) _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 ]; ffc0b92c: 7d 43 52 14 add r10,r3,r10 ffc0b930: 91 04 00 3c stw r8,60(r4) the_chain->last = _Chain_Head(the_chain); ffc0b934: 91 64 00 40 stw r11,64(r4) block_state = the_thread_queue->state; if ( _Thread_queue_Is_reverse_search( priority ) ) ffc0b938: 40 82 00 7c bne- ffc0b9b4 <_Thread_queue_Enqueue_priority+0xb4> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; ffc0b93c: 39 8a 00 04 addi r12,r10,4 static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc0b940: 7c c0 00 a6 mfmsr r6 ffc0b944: 7d 70 42 a6 mfsprg r11,0 ffc0b948: 7c cb 58 78 andc r11,r6,r11 ffc0b94c: 7d 60 01 24 mtmsr r11 goto restart_reverse_search; restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->first; ffc0b950: 81 6a 00 00 lwz r11,0(r10) while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) { ffc0b954: 7f 8b 60 00 cmpw cr7,r11,r12 ffc0b958: 40 be 00 2c bne+ cr7,ffc0b984 <_Thread_queue_Enqueue_priority+0x84> ffc0b95c: 48 00 01 78 b ffc0bad4 <_Thread_queue_Enqueue_priority+0x1d4> static inline void ppc_interrupt_flash( uint32_t level ) { uint32_t current_level; asm volatile ( ffc0b960: 7c e0 00 a6 mfmsr r7 ffc0b964: 7c c0 01 24 mtmsr r6 ffc0b968: 7c e0 01 24 mtmsr r7 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) ) { ffc0b96c: 80 eb 00 10 lwz r7,16(r11) ffc0b970: 7d 3f 38 39 and. r31,r9,r7 ffc0b974: 41 82 00 f4 beq- ffc0ba68 <_Thread_queue_Enqueue_priority+0x168> _ISR_Enable( level ); goto restart_forward_search; } search_thread = (Thread_Control *)search_thread->Object.Node.next; ffc0b978: 81 6b 00 00 lwz r11,0(r11) restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->first; while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) { ffc0b97c: 7f 8b 60 00 cmpw cr7,r11,r12 ffc0b980: 41 9e 00 10 beq- cr7,ffc0b990 <_Thread_queue_Enqueue_priority+0x90> search_priority = search_thread->current_priority; ffc0b984: 81 0b 00 14 lwz r8,20(r11) if ( priority <= search_priority ) ffc0b988: 7f 80 40 40 cmplw cr7,r0,r8 ffc0b98c: 41 9d ff d4 bgt+ cr7,ffc0b960 <_Thread_queue_Enqueue_priority+0x60> restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->first; while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) { ffc0b990: 7c ca 33 78 mr r10,r6 } search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state != ffc0b994: 81 23 00 30 lwz r9,48(r3) ffc0b998: 2f 89 00 01 cmpwi cr7,r9,1 ffc0b99c: 41 9e 00 d4 beq- cr7,ffc0ba70 <_Thread_queue_Enqueue_priority+0x170> * 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; ffc0b9a0: 91 45 00 00 stw r10,0(r5) return the_thread_queue->sync_state; ffc0b9a4: 7d 23 4b 78 mr r3,r9 } ffc0b9a8: 83 e1 00 0c lwz r31,12(r1) ffc0b9ac: 38 21 00 10 addi r1,r1,16 ffc0b9b0: 4e 80 00 20 blr ffc0b9b4: 3d 80 00 00 lis r12,0 ffc0b9b8: 39 8c 26 a4 addi r12,r12,9892 the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; ffc0b9bc: 89 0c 00 00 lbz r8,0(r12) ffc0b9c0: 39 08 00 01 addi r8,r8,1 static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc0b9c4: 7c c0 00 a6 mfmsr r6 ffc0b9c8: 7d 70 42 a6 mfsprg r11,0 ffc0b9cc: 7c cb 58 78 andc r11,r6,r11 ffc0b9d0: 7d 60 01 24 mtmsr r11 _ISR_Disable( level ); search_thread = (Thread_Control *) header->last; ffc0b9d4: 81 6a 00 08 lwz r11,8(r10) while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) { ffc0b9d8: 7f 8b 50 00 cmpw cr7,r11,r10 ffc0b9dc: 40 be 00 2c bne+ cr7,ffc0ba08 <_Thread_queue_Enqueue_priority+0x108> ffc0b9e0: 48 00 00 34 b ffc0ba14 <_Thread_queue_Enqueue_priority+0x114> static inline void ppc_interrupt_flash( uint32_t level ) { uint32_t current_level; asm volatile ( ffc0b9e4: 7c e0 00 a6 mfmsr r7 ffc0b9e8: 7c c0 01 24 mtmsr r6 ffc0b9ec: 7c e0 01 24 mtmsr r7 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) ) { ffc0b9f0: 80 eb 00 10 lwz r7,16(r11) ffc0b9f4: 7d 3f 38 39 and. r31,r9,r7 ffc0b9f8: 41 82 00 68 beq- ffc0ba60 <_Thread_queue_Enqueue_priority+0x160> _ISR_Enable( level ); goto restart_reverse_search; } search_thread = (Thread_Control *) ffc0b9fc: 81 6b 00 04 lwz r11,4(r11) restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->last; while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) { ffc0ba00: 7f 8b 50 00 cmpw cr7,r11,r10 ffc0ba04: 41 9e 00 10 beq- cr7,ffc0ba14 <_Thread_queue_Enqueue_priority+0x114> search_priority = search_thread->current_priority; ffc0ba08: 81 0b 00 14 lwz r8,20(r11) if ( priority >= search_priority ) ffc0ba0c: 7f 80 40 40 cmplw cr7,r0,r8 ffc0ba10: 41 9c ff d4 blt+ cr7,ffc0b9e4 <_Thread_queue_Enqueue_priority+0xe4> } search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state != ffc0ba14: 81 23 00 30 lwz r9,48(r3) restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->last; while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) { ffc0ba18: 7c ca 33 78 mr r10,r6 } search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state != ffc0ba1c: 2f 89 00 01 cmpwi cr7,r9,1 ffc0ba20: 40 9e ff 80 bne+ cr7,ffc0b9a0 <_Thread_queue_Enqueue_priority+0xa0> THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; if ( priority == search_priority ) ffc0ba24: 7f 80 40 00 cmpw cr7,r0,r8 if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; ffc0ba28: 38 00 00 00 li r0,0 ffc0ba2c: 90 03 00 30 stw r0,48(r3) if ( priority == search_priority ) ffc0ba30: 41 9e 00 7c beq- cr7,ffc0baac <_Thread_queue_Enqueue_priority+0x1ac> goto equal_priority; search_node = (Chain_Node *) search_thread; next_node = search_node->next; ffc0ba34: 81 2b 00 00 lwz r9,0(r11) the_node = (Chain_Node *) the_thread; the_node->next = next_node; the_node->previous = search_node; ffc0ba38: 91 64 00 04 stw r11,4(r4) search_node = (Chain_Node *) search_thread; next_node = search_node->next; the_node = (Chain_Node *) the_thread; the_node->next = next_node; ffc0ba3c: 91 24 00 00 stw r9,0(r4) the_node->previous = search_node; search_node->next = the_node; next_node->previous = the_node; the_thread->Wait.queue = the_thread_queue; ffc0ba40: 90 64 00 44 stw r3,68(r4) next_node = search_node->next; the_node = (Chain_Node *) the_thread; the_node->next = next_node; the_node->previous = search_node; search_node->next = the_node; ffc0ba44: 90 8b 00 00 stw r4,0(r11) next_node->previous = the_node; ffc0ba48: 90 89 00 04 stw r4,4(r9) return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc0ba4c: 7c c0 01 24 mtmsr r6 ffc0ba50: 38 60 00 01 li r3,1 * * WARNING! Returning with interrupts disabled! */ *level_p = level; return the_thread_queue->sync_state; } ffc0ba54: 83 e1 00 0c lwz r31,12(r1) ffc0ba58: 38 21 00 10 addi r1,r1,16 ffc0ba5c: 4e 80 00 20 blr ffc0ba60: 7c c0 01 24 mtmsr r6 ffc0ba64: 4b ff ff 58 b ffc0b9bc <_Thread_queue_Enqueue_priority+0xbc> ffc0ba68: 7c c0 01 24 mtmsr r6 <== NOT EXECUTED ffc0ba6c: 4b ff fe d4 b ffc0b940 <_Thread_queue_Enqueue_priority+0x40><== NOT EXECUTED THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; if ( priority == search_priority ) ffc0ba70: 7f 80 40 00 cmpw cr7,r0,r8 if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; ffc0ba74: 38 00 00 00 li r0,0 ffc0ba78: 90 03 00 30 stw r0,48(r3) if ( priority == search_priority ) ffc0ba7c: 41 9e 00 30 beq- cr7,ffc0baac <_Thread_queue_Enqueue_priority+0x1ac> goto equal_priority; search_node = (Chain_Node *) search_thread; previous_node = search_node->previous; ffc0ba80: 81 2b 00 04 lwz r9,4(r11) the_node = (Chain_Node *) the_thread; the_node->next = search_node; ffc0ba84: 91 64 00 00 stw r11,0(r4) the_node->previous = previous_node; ffc0ba88: 91 24 00 04 stw r9,4(r4) previous_node->next = the_node; search_node->previous = the_node; the_thread->Wait.queue = the_thread_queue; ffc0ba8c: 90 64 00 44 stw r3,68(r4) previous_node = search_node->previous; the_node = (Chain_Node *) the_thread; the_node->next = search_node; the_node->previous = previous_node; previous_node->next = the_node; ffc0ba90: 90 89 00 00 stw r4,0(r9) search_node->previous = the_node; ffc0ba94: 90 8b 00 04 stw r4,4(r11) ffc0ba98: 7c c0 01 24 mtmsr r6 ffc0ba9c: 38 60 00 01 li r3,1 * * WARNING! Returning with interrupts disabled! */ *level_p = level; return the_thread_queue->sync_state; } ffc0baa0: 83 e1 00 0c lwz r31,12(r1) ffc0baa4: 38 21 00 10 addi r1,r1,16 ffc0baa8: 4e 80 00 20 blr ffc0baac: 39 6b 00 3c addi r11,r11,60 the_node->next = search_node; the_node->previous = previous_node; previous_node->next = the_node; search_node->previous = the_node; the_thread->Wait.queue = the_thread_queue; ffc0bab0: 90 64 00 44 stw r3,68(r4) _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; ffc0bab4: 81 2b 00 04 lwz r9,4(r11) the_node = (Chain_Node *) the_thread; the_node->next = search_node; ffc0bab8: 91 64 00 00 stw r11,0(r4) the_node->previous = previous_node; ffc0babc: 91 24 00 04 stw r9,4(r4) previous_node->next = the_node; ffc0bac0: 90 89 00 00 stw r4,0(r9) search_node->previous = the_node; ffc0bac4: 90 8b 00 04 stw r4,4(r11) ffc0bac8: 7d 40 01 24 mtmsr r10 ffc0bacc: 38 60 00 01 li r3,1 the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; ffc0bad0: 4b ff fe d8 b ffc0b9a8 <_Thread_queue_Enqueue_priority+0xa8> restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->first; while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) { ffc0bad4: 7c ca 33 78 mr r10,r6 ffc0bad8: 39 00 ff ff li r8,-1 ffc0badc: 4b ff fe b8 b ffc0b994 <_Thread_queue_Enqueue_priority+0x94> ffc0bbc8 <_Thread_queue_Requeue>: void _Thread_queue_Requeue( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread ) { ffc0bbc8: 94 21 ff d8 stwu r1,-40(r1) ffc0bbcc: 7c 08 02 a6 mflr r0 ffc0bbd0: 93 e1 00 24 stw r31,36(r1) /* * Just in case the thread really wasn't blocked on a thread queue * when we get here. */ if ( !the_thread_queue ) ffc0bbd4: 7c 7f 1b 79 mr. r31,r3 void _Thread_queue_Requeue( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread ) { ffc0bbd8: 93 c1 00 20 stw r30,32(r1) ffc0bbdc: 7c 9e 23 78 mr r30,r4 ffc0bbe0: 90 01 00 2c stw r0,44(r1) ffc0bbe4: 93 a1 00 1c stw r29,28(r1) /* * Just in case the thread really wasn't blocked on a thread queue * when we get here. */ if ( !the_thread_queue ) ffc0bbe8: 41 82 00 10 beq- ffc0bbf8 <_Thread_queue_Requeue+0x30> /* * If queueing by FIFO, there is nothing to do. This only applies to * priority blocking discipline. */ if ( the_thread_queue->discipline == THREAD_QUEUE_DISCIPLINE_PRIORITY ) { ffc0bbec: 80 1f 00 34 lwz r0,52(r31) ffc0bbf0: 2f 80 00 01 cmpwi cr7,r0,1 ffc0bbf4: 41 9e 00 20 beq- cr7,ffc0bc14 <_Thread_queue_Requeue+0x4c> _Thread_queue_Extract_priority_helper( tq, the_thread, true ); (void) _Thread_queue_Enqueue_priority( tq, the_thread, &level_ignored ); } _ISR_Enable( level ); } } ffc0bbf8: 80 01 00 2c lwz r0,44(r1) <== NOT EXECUTED ffc0bbfc: 83 a1 00 1c lwz r29,28(r1) <== NOT EXECUTED ffc0bc00: 7c 08 03 a6 mtlr r0 <== NOT EXECUTED ffc0bc04: 83 c1 00 20 lwz r30,32(r1) <== NOT EXECUTED ffc0bc08: 83 e1 00 24 lwz r31,36(r1) <== NOT EXECUTED ffc0bc0c: 38 21 00 28 addi r1,r1,40 <== NOT EXECUTED ffc0bc10: 4e 80 00 20 blr <== NOT EXECUTED static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc0bc14: 7f a0 00 a6 mfmsr r29 ffc0bc18: 7d 30 42 a6 mfsprg r9,0 ffc0bc1c: 7f a9 48 78 andc r9,r29,r9 ffc0bc20: 7d 20 01 24 mtmsr r9 Thread_queue_Control *tq = the_thread_queue; ISR_Level level; ISR_Level level_ignored; _ISR_Disable( level ); if ( _States_Is_waiting_on_thread_queue( the_thread->current_state ) ) { ffc0bc24: 3d 60 00 03 lis r11,3 ffc0bc28: 81 24 00 10 lwz r9,16(r4) ffc0bc2c: 61 6b be e0 ori r11,r11,48864 ffc0bc30: 7d 6a 48 39 and. r10,r11,r9 ffc0bc34: 40 82 00 24 bne- ffc0bc58 <_Thread_queue_Requeue+0x90> return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc0bc38: 7f a0 01 24 mtmsr r29 <== NOT EXECUTED _Thread_queue_Extract_priority_helper( tq, the_thread, true ); (void) _Thread_queue_Enqueue_priority( tq, the_thread, &level_ignored ); } _ISR_Enable( level ); } } ffc0bc3c: 80 01 00 2c lwz r0,44(r1) ffc0bc40: 83 a1 00 1c lwz r29,28(r1) ffc0bc44: 7c 08 03 a6 mtlr r0 ffc0bc48: 83 c1 00 20 lwz r30,32(r1) ffc0bc4c: 83 e1 00 24 lwz r31,36(r1) ffc0bc50: 38 21 00 28 addi r1,r1,40 ffc0bc54: 4e 80 00 20 blr ffc0bc58: 90 1f 00 30 stw r0,48(r31) ISR_Level level_ignored; _ISR_Disable( level ); if ( _States_Is_waiting_on_thread_queue( the_thread->current_state ) ) { _Thread_queue_Enter_critical_section( tq ); _Thread_queue_Extract_priority_helper( tq, the_thread, true ); ffc0bc5c: 38 a0 00 01 li r5,1 ffc0bc60: 48 00 43 91 bl ffc0fff0 <_Thread_queue_Extract_priority_helper> (void) _Thread_queue_Enqueue_priority( tq, the_thread, &level_ignored ); ffc0bc64: 7f e3 fb 78 mr r3,r31 ffc0bc68: 7f c4 f3 78 mr r4,r30 ffc0bc6c: 38 a1 00 08 addi r5,r1,8 ffc0bc70: 4b ff fc 91 bl ffc0b900 <_Thread_queue_Enqueue_priority> ffc0bc74: 7f a0 01 24 mtmsr r29 ffc0bc78: 4b ff ff c4 b ffc0bc3c <_Thread_queue_Requeue+0x74> ffc1bb04 <_Timer_server_Body>: * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { ffc1bb04: 94 21 ff 98 stwu r1,-104(r1) ffc1bb08: 7c 08 02 a6 mflr r0 ffc1bb0c: 92 a1 00 3c stw r21,60(r1) Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); ffc1bb10: 3a a1 00 08 addi r21,r1,8 ffc1bb14: 90 01 00 6c stw r0,108(r1) RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL; ffc1bb18: 38 00 00 00 li r0,0 ffc1bb1c: 92 e1 00 44 stw r23,68(r1) */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; ffc1bb20: 3a e1 00 18 addi r23,r1,24 ffc1bb24: 93 41 00 50 stw r26,80(r1) ffc1bb28: 3b 41 00 0c addi r26,r1,12 ffc1bb2c: 93 81 00 58 stw r28,88(r1) ffc1bb30: 3b 81 00 14 addi r28,r1,20 ffc1bb34: 92 81 00 38 stw r20,56(r1) ffc1bb38: 3e 80 00 00 lis r20,0 ffc1bb3c: 3a 94 28 68 addi r20,r20,10344 ffc1bb40: 93 01 00 48 stw r24,72(r1) ffc1bb44: 3f 00 00 00 lis r24,0 ffc1bb48: 3b 18 28 c0 addi r24,r24,10432 ffc1bb4c: 93 21 00 4c stw r25,76(r1) ffc1bb50: 3f 20 00 00 lis r25,0 ffc1bb54: 3b 39 28 88 addi r25,r25,10376 ffc1bb58: 93 c1 00 60 stw r30,96(r1) RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL; ffc1bb5c: 90 01 00 18 stw r0,24(r1) */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); ffc1bb60: 93 41 00 08 stw r26,8(r1) the_chain->permanent_null = NULL; ffc1bb64: 90 01 00 0c stw r0,12(r1) the_chain->last = _Chain_Head(the_chain); ffc1bb68: 92 a1 00 10 stw r21,16(r1) */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); ffc1bb6c: 92 e1 00 14 stw r23,20(r1) the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); ffc1bb70: 93 81 00 1c stw r28,28(r1) ffc1bb74: 92 01 00 28 stw r16,40(r1) static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog ); ffc1bb78: 3a 03 00 08 addi r16,r3,8 * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { ffc1bb7c: 92 21 00 2c stw r17,44(r1) static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog ); ffc1bb80: 3a 23 00 40 addi r17,r3,64 * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { ffc1bb84: 92 41 00 30 stw r18,48(r1) * the active flag of the timer server is true. */ (*watchdog->routine)( watchdog->id, watchdog->user_data ); } } else { ts->active = false; ffc1bb88: 3a 40 00 00 li r18,0 * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { ffc1bb8c: 92 61 00 34 stw r19,52(r1) _Thread_Set_state( ts->thread, STATES_DELAYING ); _Timer_server_Reset_interval_system_watchdog( ts ); _Timer_server_Reset_tod_system_watchdog( ts ); _Thread_Enable_dispatch(); ts->active = true; ffc1bb90: 3a 60 00 01 li r19,1 * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { ffc1bb94: 92 c1 00 40 stw r22,64(r1) * 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; ffc1bb98: 3a c0 00 00 li r22,0 * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { ffc1bb9c: 93 61 00 54 stw r27,84(r1) /* * 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 ); ffc1bba0: 3b 63 00 68 addi r27,r3,104 * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { ffc1bba4: 93 a1 00 5c stw r29,92(r1) */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); ffc1bba8: 3b a3 00 30 addi r29,r3,48 * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { ffc1bbac: 93 e1 00 64 stw r31,100(r1) ffc1bbb0: 7c 7f 1b 78 mr r31,r3 { /* * 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; ffc1bbb4: 92 bf 00 78 stw r21,120(r31) */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); ffc1bbb8: 7f a3 eb 78 mr r3,r29 ffc1bbbc: 7f 85 e3 78 mr r5,r28 static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot; ffc1bbc0: 80 18 00 00 lwz r0,0(r24) /* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; ffc1bbc4: 80 9f 00 3c lwz r4,60(r31) watchdogs->last_snapshot = snapshot; ffc1bbc8: 90 1f 00 3c stw r0,60(r31) _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); ffc1bbcc: 7c 84 00 50 subf r4,r4,r0 ffc1bbd0: 48 00 54 a9 bl ffc21078 <_Watchdog_Adjust_to_chain> static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch(); ffc1bbd4: 83 d9 00 00 lwz r30,0(r25) Watchdog_Interval last_snapshot = watchdogs->last_snapshot; ffc1bbd8: 80 9f 00 74 lwz r4,116(r31) /* * 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 ) { ffc1bbdc: 7f 9e 20 40 cmplw cr7,r30,r4 ffc1bbe0: 41 9d 00 98 bgt- cr7,ffc1bc78 <_Timer_server_Body+0x174> * TOD has been set forward. */ delta = snapshot - last_snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); } else if ( snapshot < last_snapshot ) { ffc1bbe4: 41 9c 00 a8 blt- cr7,ffc1bc8c <_Timer_server_Body+0x188> */ delta = last_snapshot - snapshot; _Watchdog_Adjust( &watchdogs->Chain, WATCHDOG_BACKWARD, delta ); } watchdogs->last_snapshot = snapshot; ffc1bbe8: 93 df 00 74 stw r30,116(r31) } static void _Timer_server_Process_insertions( Timer_server_Control *ts ) { while ( true ) { Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain ); ffc1bbec: 80 7f 00 78 lwz r3,120(r31) ffc1bbf0: 48 00 0c 09 bl ffc1c7f8 <_Chain_Get> if ( timer == NULL ) { ffc1bbf4: 2c 03 00 00 cmpwi r3,0 ffc1bbf8: 41 82 00 34 beq- ffc1bc2c <_Timer_server_Body+0x128> static void _Timer_server_Insert_timer( Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { ffc1bbfc: 80 03 00 38 lwz r0,56(r3) ffc1bc00: 2f 80 00 01 cmpwi cr7,r0,1 _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) { ffc1bc04: 2f 00 00 03 cmpwi cr6,r0,3 static void _Timer_server_Insert_timer( Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { ffc1bc08: 41 9e 00 98 beq- cr7,ffc1bca0 <_Timer_server_Body+0x19c> _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) { ffc1bc0c: 40 9a ff e0 bne+ cr6,ffc1bbec <_Timer_server_Body+0xe8> _Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker ); ffc1bc10: 38 83 00 10 addi r4,r3,16 ffc1bc14: 7f 63 db 78 mr r3,r27 ffc1bc18: 48 00 55 1d bl ffc21134 <_Watchdog_Insert> } static void _Timer_server_Process_insertions( Timer_server_Control *ts ) { while ( true ) { Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain ); ffc1bc1c: 80 7f 00 78 lwz r3,120(r31) ffc1bc20: 48 00 0b d9 bl ffc1c7f8 <_Chain_Get> if ( timer == NULL ) { ffc1bc24: 2c 03 00 00 cmpwi r3,0 ffc1bc28: 40 82 ff d4 bne+ ffc1bbfc <_Timer_server_Body+0xf8> static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc1bc2c: 7d 20 00 a6 mfmsr r9 ffc1bc30: 7c 10 42 a6 mfsprg r0,0 ffc1bc34: 7d 20 00 78 andc r0,r9,r0 ffc1bc38: 7c 00 01 24 mtmsr r0 * body loop. */ _Timer_server_Process_insertions( ts ); _ISR_Disable( level ); if ( _Chain_Is_empty( insert_chain ) ) { ffc1bc3c: 80 01 00 08 lwz r0,8(r1) ffc1bc40: 7f 9a 00 00 cmpw cr7,r26,r0 ffc1bc44: 41 9e 00 6c beq- cr7,ffc1bcb0 <_Timer_server_Body+0x1ac> return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc1bc48: 7d 20 01 24 mtmsr r9 <== NOT EXECUTED static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot; ffc1bc4c: 80 18 00 00 lwz r0,0(r24) <== NOT EXECUTED */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); ffc1bc50: 7f a3 eb 78 mr r3,r29 <== NOT EXECUTED Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot; /* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; ffc1bc54: 80 9f 00 3c lwz r4,60(r31) <== NOT EXECUTED watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); ffc1bc58: 7f 85 e3 78 mr r5,r28 <== NOT EXECUTED /* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; ffc1bc5c: 90 1f 00 3c stw r0,60(r31) <== NOT EXECUTED _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); ffc1bc60: 7c 84 00 50 subf r4,r4,r0 <== NOT EXECUTED ffc1bc64: 48 00 54 15 bl ffc21078 <_Watchdog_Adjust_to_chain> <== NOT EXECUTED static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch(); ffc1bc68: 83 d9 00 00 lwz r30,0(r25) <== NOT EXECUTED Watchdog_Interval last_snapshot = watchdogs->last_snapshot; ffc1bc6c: 80 9f 00 74 lwz r4,116(r31) <== NOT EXECUTED /* * 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 ) { ffc1bc70: 7f 9e 20 40 cmplw cr7,r30,r4 <== NOT EXECUTED ffc1bc74: 40 9d ff 70 ble+ cr7,ffc1bbe4 <_Timer_server_Body+0xe0> <== NOT EXECUTED /* * 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 ); ffc1bc78: 7c 84 f0 50 subf r4,r4,r30 ffc1bc7c: 7f 63 db 78 mr r3,r27 ffc1bc80: 7f 85 e3 78 mr r5,r28 ffc1bc84: 48 00 53 f5 bl ffc21078 <_Watchdog_Adjust_to_chain> ffc1bc88: 4b ff ff 60 b ffc1bbe8 <_Timer_server_Body+0xe4> /* * 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 ); ffc1bc8c: 7c be 20 50 subf r5,r30,r4 ffc1bc90: 7f 63 db 78 mr r3,r27 ffc1bc94: 38 80 00 01 li r4,1 ffc1bc98: 48 00 52 c1 bl ffc20f58 <_Watchdog_Adjust> ffc1bc9c: 4b ff ff 4c b ffc1bbe8 <_Timer_server_Body+0xe4> Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); ffc1bca0: 38 83 00 10 addi r4,r3,16 ffc1bca4: 7f a3 eb 78 mr r3,r29 ffc1bca8: 48 00 54 8d bl ffc21134 <_Watchdog_Insert> ffc1bcac: 4b ff ff 40 b ffc1bbec <_Timer_server_Body+0xe8> */ _Timer_server_Process_insertions( ts ); _ISR_Disable( level ); if ( _Chain_Is_empty( insert_chain ) ) { ts->insert_chain = NULL; ffc1bcb0: 90 7f 00 78 stw r3,120(r31) ffc1bcb4: 7d 20 01 24 mtmsr r9 _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 ) ) { ffc1bcb8: 80 01 00 14 lwz r0,20(r1) ffc1bcbc: 7f 97 00 00 cmpw cr7,r23,r0 ffc1bcc0: 40 be 00 30 bne+ cr7,ffc1bcf0 <_Timer_server_Body+0x1ec> ffc1bcc4: 48 00 00 50 b ffc1bd14 <_Timer_server_Body+0x210> { Chain_Node *return_node; Chain_Node *new_first; return_node = the_chain->first; new_first = return_node->next; ffc1bcc8: 81 69 00 00 lwz r11,0(r9) * 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; ffc1bccc: 92 c9 00 08 stw r22,8(r9) the_chain->first = new_first; ffc1bcd0: 91 61 00 14 stw r11,20(r1) new_first->previous = _Chain_Head(the_chain); ffc1bcd4: 93 8b 00 04 stw r28,4(r11) ffc1bcd8: 7c 00 01 24 mtmsr 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 ); ffc1bcdc: 80 09 00 1c lwz r0,28(r9) ffc1bce0: 80 89 00 24 lwz r4,36(r9) ffc1bce4: 80 69 00 20 lwz r3,32(r9) ffc1bce8: 7c 09 03 a6 mtctr r0 ffc1bcec: 4e 80 04 21 bctrl static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc1bcf0: 7c 00 00 a6 mfmsr r0 ffc1bcf4: 7d 30 42 a6 mfsprg r9,0 ffc1bcf8: 7c 09 48 78 andc r9,r0,r9 ffc1bcfc: 7d 20 01 24 mtmsr r9 */ RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); ffc1bd00: 81 21 00 14 lwz r9,20(r1) */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) ffc1bd04: 7f 97 48 00 cmpw cr7,r23,r9 ffc1bd08: 40 9e ff c0 bne+ cr7,ffc1bcc8 <_Timer_server_Body+0x1c4> return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc1bd0c: 7c 00 01 24 mtmsr r0 ffc1bd10: 4b ff fe a4 b ffc1bbb4 <_Timer_server_Body+0xb0> } } else { ts->active = false; ffc1bd14: 9a 5f 00 7c stb r18,124(r31) ffc1bd18: 80 14 00 00 lwz r0,0(r20) ffc1bd1c: 30 00 00 01 addic r0,r0,1 ffc1bd20: 90 14 00 00 stw r0,0(r20) /* * Block until there is something to do. */ _Thread_Disable_dispatch(); _Thread_Set_state( ts->thread, STATES_DELAYING ); ffc1bd24: 80 7f 00 00 lwz r3,0(r31) ffc1bd28: 38 80 00 08 li r4,8 ffc1bd2c: 48 00 45 bd bl ffc202e8 <_Thread_Set_state> _Timer_server_Reset_interval_system_watchdog( ts ); ffc1bd30: 7f e3 fb 78 mr r3,r31 ffc1bd34: 4b ff fc a9 bl ffc1b9dc <_Timer_server_Reset_interval_system_watchdog> _Timer_server_Reset_tod_system_watchdog( ts ); ffc1bd38: 7f e3 fb 78 mr r3,r31 ffc1bd3c: 4b ff fd 35 bl ffc1ba70 <_Timer_server_Reset_tod_system_watchdog> _Thread_Enable_dispatch(); ffc1bd40: 48 00 38 61 bl ffc1f5a0 <_Thread_Enable_dispatch> ts->active = true; ffc1bd44: 9a 7f 00 7c stb r19,124(r31) static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog ); ffc1bd48: 7e 03 83 78 mr r3,r16 ffc1bd4c: 48 00 55 b1 bl ffc212fc <_Watchdog_Remove> static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog ); ffc1bd50: 7e 23 8b 78 mr r3,r17 ffc1bd54: 48 00 55 a9 bl ffc212fc <_Watchdog_Remove> ffc1bd58: 4b ff fe 5c b ffc1bbb4 <_Timer_server_Body+0xb0> ffc0eed0 <_Watchdog_Adjust>: void _Watchdog_Adjust( Chain_Control *header, Watchdog_Adjust_directions direction, Watchdog_Interval units ) { ffc0eed0: 94 21 ff e0 stwu r1,-32(r1) ffc0eed4: 7c 08 02 a6 mflr r0 ffc0eed8: 90 01 00 24 stw r0,36(r1) ffc0eedc: 93 c1 00 18 stw r30,24(r1) ffc0eee0: 7c be 2b 78 mr r30,r5 ffc0eee4: 93 e1 00 1c stw r31,28(r1) ffc0eee8: 7c 7f 1b 78 mr r31,r3 ffc0eeec: 93 61 00 0c stw r27,12(r1) ffc0eef0: 93 81 00 10 stw r28,16(r1) ffc0eef4: 93 a1 00 14 stw r29,20(r1) static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc0eef8: 7c 00 00 a6 mfmsr r0 ffc0eefc: 7d 30 42 a6 mfsprg r9,0 ffc0ef00: 7c 09 48 78 andc r9,r0,r9 ffc0ef04: 7d 20 01 24 mtmsr r9 */ RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); ffc0ef08: 81 23 00 00 lwz r9,0(r3) */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; ffc0ef0c: 3b 83 00 04 addi r28,r3,4 * hence the compiler must not assume *header to remain * unmodified across that call. * * Till Straumann, 7/2003 */ if ( !_Chain_Is_empty( header ) ) { ffc0ef10: 7f 89 e0 00 cmpw cr7,r9,r28 ffc0ef14: 41 9e 00 6c beq- cr7,ffc0ef80 <_Watchdog_Adjust+0xb0> switch ( direction ) { ffc0ef18: 2f 84 00 00 cmpwi cr7,r4,0 ffc0ef1c: 40 9e 00 8c bne- cr7,ffc0efa8 <_Watchdog_Adjust+0xd8> case WATCHDOG_BACKWARD: _Watchdog_First( header )->delta_interval += units; break; case WATCHDOG_FORWARD: while ( units ) { ffc0ef20: 2f 85 00 00 cmpwi cr7,r5,0 ffc0ef24: 41 9e 00 5c beq- cr7,ffc0ef80 <_Watchdog_Adjust+0xb0> if ( units < _Watchdog_First( header )->delta_interval ) { ffc0ef28: 83 a9 00 10 lwz r29,16(r9) _Watchdog_First( header )->delta_interval -= units; break; } else { units -= _Watchdog_First( header )->delta_interval; _Watchdog_First( header )->delta_interval = 1; ffc0ef2c: 3b 60 00 01 li r27,1 case WATCHDOG_BACKWARD: _Watchdog_First( header )->delta_interval += units; break; case WATCHDOG_FORWARD: while ( units ) { if ( units < _Watchdog_First( header )->delta_interval ) { ffc0ef30: 7f 85 e8 40 cmplw cr7,r5,r29 ffc0ef34: 40 bc 00 18 bge+ cr7,ffc0ef4c <_Watchdog_Adjust+0x7c> ffc0ef38: 48 00 00 ac b ffc0efe4 <_Watchdog_Adjust+0x114> <== NOT EXECUTED switch ( direction ) { case WATCHDOG_BACKWARD: _Watchdog_First( header )->delta_interval += units; break; case WATCHDOG_FORWARD: while ( units ) { ffc0ef3c: 41 82 00 44 beq- ffc0ef80 <_Watchdog_Adjust+0xb0> if ( units < _Watchdog_First( header )->delta_interval ) { ffc0ef40: 83 a9 00 10 lwz r29,16(r9) ffc0ef44: 7f 9d f0 40 cmplw cr7,r29,r30 ffc0ef48: 41 9d 00 9c bgt- cr7,ffc0efe4 <_Watchdog_Adjust+0x114> _Watchdog_First( header )->delta_interval -= units; break; } else { units -= _Watchdog_First( header )->delta_interval; _Watchdog_First( header )->delta_interval = 1; ffc0ef4c: 93 69 00 10 stw r27,16(r9) return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc0ef50: 7c 00 01 24 mtmsr r0 _ISR_Enable( level ); _Watchdog_Tickle( header ); ffc0ef54: 7f e3 fb 78 mr r3,r31 ffc0ef58: 48 00 03 31 bl ffc0f288 <_Watchdog_Tickle> static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc0ef5c: 7c 00 00 a6 mfmsr r0 ffc0ef60: 7d 30 42 a6 mfsprg r9,0 ffc0ef64: 7c 09 48 78 andc r9,r0,r9 ffc0ef68: 7d 20 01 24 mtmsr r9 */ RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); ffc0ef6c: 81 7f 00 00 lwz r11,0(r31) switch ( direction ) { case WATCHDOG_BACKWARD: _Watchdog_First( header )->delta_interval += units; break; case WATCHDOG_FORWARD: while ( units ) { ffc0ef70: 7f dd f0 51 subf. r30,r29,r30 _Watchdog_Tickle( header ); _ISR_Disable( level ); if ( _Chain_Is_empty( header ) ) ffc0ef74: 7f 9c 58 00 cmpw cr7,r28,r11 RTEMS_INLINE_ROUTINE Watchdog_Control *_Watchdog_First( Chain_Control *header ) { return ( (Watchdog_Control *) header->first ); ffc0ef78: 7d 69 5b 78 mr r9,r11 ffc0ef7c: 40 9e ff c0 bne+ cr7,ffc0ef3c <_Watchdog_Adjust+0x6c> return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc0ef80: 7c 00 01 24 mtmsr r0 } } _ISR_Enable( level ); } ffc0ef84: 80 01 00 24 lwz r0,36(r1) ffc0ef88: 83 61 00 0c lwz r27,12(r1) ffc0ef8c: 7c 08 03 a6 mtlr r0 ffc0ef90: 83 81 00 10 lwz r28,16(r1) ffc0ef94: 83 a1 00 14 lwz r29,20(r1) ffc0ef98: 83 c1 00 18 lwz r30,24(r1) ffc0ef9c: 83 e1 00 1c lwz r31,28(r1) ffc0efa0: 38 21 00 20 addi r1,r1,32 ffc0efa4: 4e 80 00 20 blr * unmodified across that call. * * Till Straumann, 7/2003 */ if ( !_Chain_Is_empty( header ) ) { switch ( direction ) { ffc0efa8: 2f 84 00 01 cmpwi cr7,r4,1 ffc0efac: 40 9e ff d4 bne+ cr7,ffc0ef80 <_Watchdog_Adjust+0xb0> case WATCHDOG_BACKWARD: _Watchdog_First( header )->delta_interval += units; ffc0efb0: 81 69 00 10 lwz r11,16(r9) ffc0efb4: 7f cb 2a 14 add r30,r11,r5 ffc0efb8: 93 c9 00 10 stw r30,16(r9) ffc0efbc: 7c 00 01 24 mtmsr r0 } } _ISR_Enable( level ); } ffc0efc0: 80 01 00 24 lwz r0,36(r1) ffc0efc4: 83 61 00 0c lwz r27,12(r1) ffc0efc8: 7c 08 03 a6 mtlr r0 ffc0efcc: 83 81 00 10 lwz r28,16(r1) ffc0efd0: 83 a1 00 14 lwz r29,20(r1) ffc0efd4: 83 c1 00 18 lwz r30,24(r1) ffc0efd8: 83 e1 00 1c lwz r31,28(r1) ffc0efdc: 38 21 00 20 addi r1,r1,32 ffc0efe0: 4e 80 00 20 blr _Watchdog_First( header )->delta_interval += units; break; case WATCHDOG_FORWARD: while ( units ) { if ( units < _Watchdog_First( header )->delta_interval ) { _Watchdog_First( header )->delta_interval -= units; ffc0efe4: 7f de e8 50 subf r30,r30,r29 ffc0efe8: 93 c9 00 10 stw r30,16(r9) break; ffc0efec: 4b ff ff 94 b ffc0ef80 <_Watchdog_Adjust+0xb0> ffc12ad4 : int killinfo( pid_t pid, int sig, const union sigval *value ) { ffc12ad4: 94 21 ff d0 stwu r1,-48(r1) ffc12ad8: 7c 08 02 a6 mflr r0 ffc12adc: 93 61 00 1c stw r27,28(r1) ffc12ae0: 7c bb 2b 78 mr r27,r5 ffc12ae4: 93 81 00 20 stw r28,32(r1) ffc12ae8: 7c 9c 23 78 mr r28,r4 ffc12aec: 93 e1 00 2c stw r31,44(r1) ffc12af0: 7c 7f 1b 78 mr r31,r3 ffc12af4: 90 01 00 34 stw r0,52(r1) ffc12af8: 93 41 00 18 stw r26,24(r1) ffc12afc: 93 a1 00 24 stw r29,36(r1) ffc12b00: 93 c1 00 28 stw r30,40(r1) POSIX_signals_Siginfo_node *psiginfo; /* * Only supported for the "calling process" (i.e. this node). */ if ( pid != getpid() ) ffc12b04: 4b ff eb 69 bl ffc1166c ffc12b08: 7f 83 f8 00 cmpw cr7,r3,r31 ffc12b0c: 40 9e 02 a0 bne- cr7,ffc12dac rtems_set_errno_and_return_minus_one( ESRCH ); /* * Validate the signal passed. */ if ( !sig ) ffc12b10: 2f 9c 00 00 cmpwi cr7,r28,0 ffc12b14: 41 9e 02 ac beq- cr7,ffc12dc0 static inline bool is_valid_signo( int signo ) { return ((signo) >= 1 && (signo) <= 32 ); ffc12b18: 38 1c ff ff addi r0,r28,-1 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !is_valid_signo(sig) ) ffc12b1c: 2b 80 00 1f cmplwi cr7,r0,31 ffc12b20: 41 9d 02 a0 bgt- cr7,ffc12dc0 rtems_set_errno_and_return_minus_one( EINVAL ); /* * If the signal is being ignored, then we are out of here. */ if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN ) ffc12b24: 1f dc 00 0c mulli r30,r28,12 ffc12b28: 3f a0 00 00 lis r29,0 ffc12b2c: 3b bd 31 70 addi r29,r29,12656 ffc12b30: 7d 3d f2 14 add r9,r29,r30 ffc12b34: 81 29 00 08 lwz r9,8(r9) ffc12b38: 38 60 00 00 li r3,0 ffc12b3c: 2f 89 00 01 cmpwi cr7,r9,1 ffc12b40: 41 9e 01 c8 beq- cr7,ffc12d08 /* * 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 ) ) ffc12b44: 2f 9c 00 08 cmpwi cr7,r28,8 ffc12b48: 41 9e 01 e8 beq- cr7,ffc12d30 ffc12b4c: 2f 9c 00 04 cmpwi cr7,r28,4 ffc12b50: 41 9e 01 e0 beq- cr7,ffc12d30 ffc12b54: 2f 9c 00 0b cmpwi cr7,r28,11 ffc12b58: 41 9e 01 d8 beq- cr7,ffc12d30 * Build up a siginfo structure */ siginfo = &siginfo_struct; siginfo->si_signo = sig; siginfo->si_code = SI_USER; if ( !value ) { ffc12b5c: 2f 9b 00 00 cmpwi cr7,r27,0 /* * Build up a siginfo structure */ siginfo = &siginfo_struct; siginfo->si_signo = sig; ffc12b60: 93 81 00 08 stw r28,8(r1) static inline sigset_t signo_to_mask( uint32_t sig ) { return 1u << (sig - 1); ffc12b64: 3b e0 00 01 li r31,1 siginfo->si_code = SI_USER; ffc12b68: 93 e1 00 0c stw r31,12(r1) ffc12b6c: 7f ff 00 30 slw r31,r31,r0 if ( !value ) { ffc12b70: 41 9e 02 34 beq- cr7,ffc12da4 siginfo->si_value.sival_int = 0; } else { siginfo->si_value = *value; ffc12b74: 80 1b 00 00 lwz r0,0(r27) ffc12b78: 90 01 00 10 stw r0,16(r1) ffc12b7c: 3d 20 00 00 lis r9,0 ffc12b80: 81 69 27 70 lwz r11,10096(r9) ffc12b84: 38 0b 00 01 addi r0,r11,1 ffc12b88: 90 09 27 70 stw r0,10096(r9) /* * 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; ffc12b8c: 3d 20 00 00 lis r9,0 ffc12b90: 80 69 27 b0 lwz r3,10160(r9) api = the_thread->API_Extensions[ THREAD_API_POSIX ]; ffc12b94: 81 23 01 48 lwz r9,328(r3) ffc12b98: 80 09 00 cc lwz r0,204(r9) ffc12b9c: 7f e6 00 79 andc. r6,r31,r0 ffc12ba0: 40 82 01 30 bne- ffc12cd0 /* XXX violation of visibility -- need to define thread queue support */ the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo; for ( the_node = the_chain->first ; ffc12ba4: 3d 40 00 00 lis r10,0 ffc12ba8: 81 2a 32 fc lwz r9,13052(r10) ffc12bac: 39 4a 32 fc addi r10,r10,13052 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; ffc12bb0: 39 4a 00 04 addi r10,r10,4 ffc12bb4: 7f 89 50 00 cmpw cr7,r9,r10 ffc12bb8: 41 9e 00 54 beq- cr7,ffc12c0c #endif /* * Is this thread is actually blocked waiting for the signal? */ if (the_thread->Wait.option & mask) ffc12bbc: 80 09 00 30 lwz r0,48(r9) for ( the_node = the_chain->first ; !_Chain_Is_tail( the_chain, the_node ) ; the_node = the_node->next ) { the_thread = (Thread_Control *)the_node; ffc12bc0: 7d 23 4b 78 mr r3,r9 api = the_thread->API_Extensions[ THREAD_API_POSIX ]; ffc12bc4: 81 69 01 48 lwz r11,328(r9) #endif /* * Is this thread is actually blocked waiting for the signal? */ if (the_thread->Wait.option & mask) ffc12bc8: 7f e8 00 39 and. r8,r31,r0 ffc12bcc: 40 82 01 04 bne- ffc12cd0 /* * Is this thread is blocked waiting for another signal but has * not blocked this one? */ if (~api->signals_blocked & mask) ffc12bd0: 80 0b 00 cc lwz r0,204(r11) ffc12bd4: 7f eb 00 79 andc. r11,r31,r0 ffc12bd8: 41 a2 00 24 beq+ ffc12bfc ffc12bdc: 48 00 00 f4 b ffc12cd0 #endif /* * Is this thread is actually blocked waiting for the signal? */ if (the_thread->Wait.option & mask) ffc12be0: 80 09 00 30 lwz r0,48(r9) <== NOT EXECUTED for ( the_node = the_chain->first ; !_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 ]; ffc12be4: 81 69 01 48 lwz r11,328(r9) <== NOT EXECUTED #endif /* * Is this thread is actually blocked waiting for the signal? */ if (the_thread->Wait.option & mask) ffc12be8: 7f fa 00 39 and. r26,r31,r0 <== NOT EXECUTED ffc12bec: 40 82 00 e4 bne- ffc12cd0 <== NOT EXECUTED /* * Is this thread is blocked waiting for another signal but has * not blocked this one? */ if (~api->signals_blocked & mask) ffc12bf0: 80 0b 00 cc lwz r0,204(r11) <== NOT EXECUTED ffc12bf4: 7f fb 00 79 andc. r27,r31,r0 <== NOT EXECUTED ffc12bf8: 40 82 00 d8 bne- ffc12cd0 <== NOT EXECUTED the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo; for ( the_node = the_chain->first ; !_Chain_Is_tail( the_chain, the_node ) ; the_node = the_node->next ) { ffc12bfc: 81 29 00 00 lwz r9,0(r9) /* XXX violation of visibility -- need to define thread queue support */ the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo; for ( the_node = the_chain->first ; ffc12c00: 7f 89 50 00 cmpw cr7,r9,r10 !_Chain_Is_tail( the_chain, the_node ) ; the_node = the_node->next ) { the_thread = (Thread_Control *)the_node; ffc12c04: 7d 23 4b 78 mr r3,r9 /* XXX violation of visibility -- need to define thread queue support */ the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo; for ( the_node = the_chain->first ; ffc12c08: 40 9e ff d8 bne+ cr7,ffc12be0 * NOTES: * * + rtems internal threads do not receive signals. */ interested = NULL; interested_priority = PRIORITY_MAXIMUM + 1; ffc12c0c: 3d 20 00 00 lis r9,0 ffc12c10: 88 e9 26 a4 lbz r7,9892(r9) ffc12c14: 3c a0 00 00 lis r5,0 ffc12c18: 38 a5 2c 28 addi r5,r5,11304 ffc12c1c: 38 e7 00 01 addi r7,r7,1 */ #define _POSIX_signals_Is_interested( _api, _mask ) \ ( ~(_api)->signals_blocked & (_mask) ) int killinfo( ffc12c20: 38 85 00 0c addi r4,r5,12 ffc12c24: 38 60 00 00 li r3,0 for (the_api = OBJECTS_CLASSIC_API; the_api <= OBJECTS_APIS_LAST; the_api++) { /* * This can occur when no one is interested and ITRON is not configured. */ if ( !_Objects_Information_table[ the_api ] ) ffc12c28: 81 25 00 00 lwz r9,0(r5) ffc12c2c: 2f 89 00 00 cmpwi cr7,r9,0 ffc12c30: 41 9e 00 8c beq- cr7,ffc12cbc continue; the_info = _Objects_Information_table[ the_api ][ 1 ]; ffc12c34: 81 29 00 04 lwz r9,4(r9) */ if ( !the_info ) continue; #endif maximum = the_info->maximum; ffc12c38: a1 49 00 10 lhz r10,16(r9) object_table = the_info->local_table; ffc12c3c: 81 09 00 1c lwz r8,28(r9) for ( index = 1 ; index <= maximum ; index++ ) { ffc12c40: 2f 8a 00 00 cmpwi cr7,r10,0 ffc12c44: 41 9e 00 78 beq- cr7,ffc12cbc ffc12c48: 39 20 00 01 li r9,1 the_thread = (Thread_Control *) object_table[ index ]; ffc12c4c: 55 20 10 3a rlwinm r0,r9,2,0,29 ffc12c50: 7d 68 00 2e lwzx r11,r8,r0 #endif maximum = the_info->maximum; object_table = the_info->local_table; for ( index = 1 ; index <= maximum ; index++ ) { ffc12c54: 39 29 00 01 addi r9,r9,1 ffc12c58: 7f 8a 48 40 cmplw cr7,r10,r9 the_thread = (Thread_Control *) object_table[ index ]; if ( !the_thread ) ffc12c5c: 2f 0b 00 00 cmpwi cr6,r11,0 ffc12c60: 41 9a 00 58 beq- cr6,ffc12cb8 /* * If this thread is of lower priority than the interested thread, * go on to the next thread. */ if ( the_thread->current_priority > interested_priority ) ffc12c64: 80 0b 00 14 lwz r0,20(r11) ffc12c68: 7f 00 38 40 cmplw cr6,r0,r7 ffc12c6c: 41 99 00 4c bgt- cr6,ffc12cb8 DEBUG_STEP("2"); /* * If this thread is not interested, then go on to the next thread. */ api = the_thread->API_Extensions[ THREAD_API_POSIX ]; ffc12c70: 80 cb 01 48 lwz r6,328(r11) ffc12c74: 80 c6 00 cc lwz r6,204(r6) ffc12c78: 7f fa 30 79 andc. r26,r31,r6 ffc12c7c: 41 82 00 3c beq- ffc12cb8 * * 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 ) { ffc12c80: 41 98 00 30 blt- cr6,ffc12cb0 * and blocking interruptibutable by signal. * * If the interested thread is ready, don't think about changing. */ if ( !_States_Is_ready( interested->current_state ) ) { ffc12c84: 80 c3 00 10 lwz r6,16(r3) ffc12c88: 2f 06 00 00 cmpwi cr6,r6,0 ffc12c8c: 41 9a 00 2c beq- cr6,ffc12cb8 /* preferred ready over blocked */ DEBUG_STEP("5"); if ( _States_Is_ready( the_thread->current_state ) ) { ffc12c90: 83 6b 00 10 lwz r27,16(r11) continue; } DEBUG_STEP("6"); /* prefer blocked/interruptible over blocked/not interruptible */ if ( !_States_Is_interruptible_by_signal(interested->current_state) ) { ffc12c94: 74 da 10 00 andis. r26,r6,4096 */ if ( !_States_Is_ready( interested->current_state ) ) { /* preferred ready over blocked */ DEBUG_STEP("5"); if ( _States_Is_ready( the_thread->current_state ) ) { ffc12c98: 2f 1b 00 00 cmpwi cr6,r27,0 ffc12c9c: 41 9a 00 14 beq- cr6,ffc12cb0 DEBUG_STEP("6"); /* prefer blocked/interruptible over blocked/not interruptible */ if ( !_States_Is_interruptible_by_signal(interested->current_state) ) { DEBUG_STEP("7"); if ( _States_Is_interruptible_by_signal(the_thread->current_state) ) { ffc12ca0: 57 66 27 fe rlwinm r6,r27,4,31,31 ffc12ca4: 2f 06 00 00 cmpwi cr6,r6,0 continue; } DEBUG_STEP("6"); /* prefer blocked/interruptible over blocked/not interruptible */ if ( !_States_Is_interruptible_by_signal(interested->current_state) ) { ffc12ca8: 40 82 00 10 bne- ffc12cb8 DEBUG_STEP("7"); if ( _States_Is_interruptible_by_signal(the_thread->current_state) ) { ffc12cac: 41 9a 00 0c beq- cr6,ffc12cb8 ffc12cb0: 7c 07 03 78 mr r7,r0 ffc12cb4: 7d 63 5b 78 mr r3,r11 #endif maximum = the_info->maximum; object_table = the_info->local_table; for ( index = 1 ; index <= maximum ; index++ ) { ffc12cb8: 40 9c ff 94 bge+ cr7,ffc12c4c ffc12cbc: 38 a5 00 04 addi r5,r5,4 * + 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++) { ffc12cc0: 7f 85 20 00 cmpw cr7,r5,r4 ffc12cc4: 40 9e ff 64 bne+ cr7,ffc12c28 } } } } if ( interested ) { ffc12cc8: 2f 83 00 00 cmpwi cr7,r3,0 ffc12ccc: 41 9e 00 20 beq- cr7,ffc12cec * thread needs to do the post context switch extension so it can * evaluate the signals pending. */ process_it: the_thread->do_post_task_switch_extension = true; ffc12cd0: 38 00 00 01 li r0,1 ffc12cd4: 98 03 00 74 stb r0,116(r3) /* * 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 ) ) { ffc12cd8: 7f 84 e3 78 mr r4,r28 ffc12cdc: 38 a1 00 08 addi r5,r1,8 ffc12ce0: 48 00 01 d5 bl ffc12eb4 <_POSIX_signals_Unblock_thread> ffc12ce4: 2f 83 00 00 cmpwi cr7,r3,0 ffc12ce8: 40 9e 00 18 bne- cr7,ffc12d00 /* * 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 ); ffc12cec: 7f e3 fb 78 mr r3,r31 ffc12cf0: 48 00 01 85 bl ffc12e74 <_POSIX_signals_Set_process_signals> if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) { ffc12cf4: 7c 1d f0 2e lwzx r0,r29,r30 ffc12cf8: 2f 80 00 02 cmpwi cr7,r0,2 ffc12cfc: 41 9e 00 68 beq- cr7,ffc12d64 _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); } DEBUG_STEP("\n"); _Thread_Enable_dispatch(); ffc12d00: 4b ff 84 a1 bl ffc0b1a0 <_Thread_Enable_dispatch> ffc12d04: 38 60 00 00 li r3,0 return 0; } ffc12d08: 80 01 00 34 lwz r0,52(r1) ffc12d0c: 83 41 00 18 lwz r26,24(r1) ffc12d10: 7c 08 03 a6 mtlr r0 ffc12d14: 83 61 00 1c lwz r27,28(r1) ffc12d18: 83 81 00 20 lwz r28,32(r1) ffc12d1c: 83 a1 00 24 lwz r29,36(r1) ffc12d20: 83 c1 00 28 lwz r30,40(r1) ffc12d24: 83 e1 00 2c lwz r31,44(r1) ffc12d28: 38 21 00 30 addi r1,r1,48 ffc12d2c: 4e 80 00 20 blr * 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 ) ) return pthread_kill( pthread_self(), sig ); ffc12d30: 48 00 04 09 bl ffc13138 ffc12d34: 7f 84 e3 78 mr r4,r28 ffc12d38: 48 00 02 ed bl ffc13024 } DEBUG_STEP("\n"); _Thread_Enable_dispatch(); return 0; } ffc12d3c: 80 01 00 34 lwz r0,52(r1) ffc12d40: 83 41 00 18 lwz r26,24(r1) ffc12d44: 7c 08 03 a6 mtlr r0 ffc12d48: 83 61 00 1c lwz r27,28(r1) ffc12d4c: 83 81 00 20 lwz r28,32(r1) ffc12d50: 83 a1 00 24 lwz r29,36(r1) ffc12d54: 83 c1 00 28 lwz r30,40(r1) ffc12d58: 83 e1 00 2c lwz r31,44(r1) ffc12d5c: 38 21 00 30 addi r1,r1,48 ffc12d60: 4e 80 00 20 blr */ _POSIX_signals_Set_process_signals( mask ); if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) { psiginfo = (POSIX_signals_Siginfo_node *) ffc12d64: 3c 60 00 00 lis r3,0 ffc12d68: 38 63 32 f0 addi r3,r3,13040 ffc12d6c: 4b ff 67 b5 bl ffc09520 <_Chain_Get> _Chain_Get( &_POSIX_signals_Inactive_siginfo ); if ( !psiginfo ) { ffc12d70: 7c 64 1b 79 mr. r4,r3 ffc12d74: 41 82 00 60 beq- ffc12dd4 _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( EAGAIN ); } psiginfo->Info = *siginfo; ffc12d78: 81 21 00 0c lwz r9,12(r1) _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); ffc12d7c: 3c 60 00 00 lis r3,0 if ( !psiginfo ) { _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( EAGAIN ); } psiginfo->Info = *siginfo; ffc12d80: 80 01 00 10 lwz r0,16(r1) _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); ffc12d84: 38 63 33 64 addi r3,r3,13156 if ( !psiginfo ) { _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( EAGAIN ); } psiginfo->Info = *siginfo; ffc12d88: 81 61 00 08 lwz r11,8(r1) _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); ffc12d8c: 7c 63 f2 14 add r3,r3,r30 if ( !psiginfo ) { _Thread_Enable_dispatch(); rtems_set_errno_and_return_minus_one( EAGAIN ); } psiginfo->Info = *siginfo; ffc12d90: 91 24 00 0c stw r9,12(r4) ffc12d94: 91 64 00 08 stw r11,8(r4) ffc12d98: 90 04 00 10 stw r0,16(r4) _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); ffc12d9c: 4b ff 67 55 bl ffc094f0 <_Chain_Append> ffc12da0: 4b ff ff 60 b ffc12d00 */ siginfo = &siginfo_struct; siginfo->si_signo = sig; siginfo->si_code = SI_USER; if ( !value ) { siginfo->si_value.sival_int = 0; ffc12da4: 93 61 00 10 stw r27,16(r1) ffc12da8: 4b ff fd d4 b ffc12b7c /* * Only supported for the "calling process" (i.e. this node). */ if ( pid != getpid() ) rtems_set_errno_and_return_minus_one( ESRCH ); ffc12dac: 48 00 04 89 bl ffc13234 <__errno> ffc12db0: 38 00 00 03 li r0,3 ffc12db4: 90 03 00 00 stw r0,0(r3) ffc12db8: 38 60 ff ff li r3,-1 ffc12dbc: 4b ff ff 4c b ffc12d08 */ if ( !sig ) rtems_set_errno_and_return_minus_one( EINVAL ); if ( !is_valid_signo(sig) ) rtems_set_errno_and_return_minus_one( EINVAL ); ffc12dc0: 48 00 04 75 bl ffc13234 <__errno> ffc12dc4: 38 00 00 16 li r0,22 ffc12dc8: 90 03 00 00 stw r0,0(r3) ffc12dcc: 38 60 ff ff li r3,-1 ffc12dd0: 4b ff ff 38 b ffc12d08 if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) { psiginfo = (POSIX_signals_Siginfo_node *) _Chain_Get( &_POSIX_signals_Inactive_siginfo ); if ( !psiginfo ) { _Thread_Enable_dispatch(); ffc12dd4: 4b ff 83 cd bl ffc0b1a0 <_Thread_Enable_dispatch> rtems_set_errno_and_return_minus_one( EAGAIN ); ffc12dd8: 48 00 04 5d bl ffc13234 <__errno> ffc12ddc: 38 00 00 0b li r0,11 ffc12de0: 90 03 00 00 stw r0,0(r3) ffc12de4: 38 60 ff ff li r3,-1 ffc12de8: 4b ff ff 20 b ffc12d08 ffc09ff0 : int pthread_rwlock_timedrdlock( pthread_rwlock_t *rwlock, const struct timespec *abstime ) { ffc09ff0: 94 21 ff d8 stwu r1,-40(r1) ffc09ff4: 7c 08 02 a6 mflr r0 ffc09ff8: 93 a1 00 1c stw r29,28(r1) Objects_Locations location; Watchdog_Interval ticks; bool do_wait = true; POSIX_Absolute_timeout_conversion_results_t status; if ( !rwlock ) ffc09ffc: 7c 7d 1b 79 mr. r29,r3 int pthread_rwlock_timedrdlock( pthread_rwlock_t *rwlock, const struct timespec *abstime ) { ffc0a000: 90 01 00 2c stw r0,44(r1) ffc0a004: 93 c1 00 20 stw r30,32(r1) ffc0a008: 93 e1 00 24 stw r31,36(r1) Objects_Locations location; Watchdog_Interval ticks; bool do_wait = true; POSIX_Absolute_timeout_conversion_results_t status; if ( !rwlock ) ffc0a00c: 41 82 00 9c beq- ffc0a0a8 * * 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 ); ffc0a010: 7c 83 23 78 mr r3,r4 ffc0a014: 38 81 00 0c addi r4,r1,12 ffc0a018: 48 00 7f 99 bl ffc11fb0 <_POSIX_Absolute_timeout_to_ticks> ffc0a01c: 80 9d 00 00 lwz r4,0(r29) ffc0a020: 7c 7e 1b 78 mr r30,r3 ffc0a024: 3c 60 00 00 lis r3,0 ffc0a028: 38 63 2e 38 addi r3,r3,11832 ffc0a02c: 38 a1 00 08 addi r5,r1,8 ffc0a030: 48 00 37 75 bl ffc0d7a4 <_Objects_Get> if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE ) do_wait = false; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { ffc0a034: 80 01 00 08 lwz r0,8(r1) ffc0a038: 2f 80 00 00 cmpwi cr7,r0,0 ffc0a03c: 40 9e 00 6c bne- cr7,ffc0a0a8 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, ffc0a040: 6b df 00 03 xori r31,r30,3 case OBJECTS_LOCAL: _CORE_RWLock_Obtain_for_reading( ffc0a044: 80 9d 00 00 lwz r4,0(r29) ffc0a048: 7f ff 00 34 cntlzw r31,r31 ffc0a04c: 80 c1 00 0c lwz r6,12(r1) ffc0a050: 57 ff d9 7e rlwinm r31,r31,27,5,31 ffc0a054: 38 63 00 10 addi r3,r3,16 ffc0a058: 7f e5 fb 78 mr r5,r31 ffc0a05c: 38 e0 00 00 li r7,0 ffc0a060: 48 00 26 c9 bl ffc0c728 <_CORE_RWLock_Obtain_for_reading> do_wait, ticks, NULL ); _Thread_Enable_dispatch(); ffc0a064: 48 00 43 0d bl ffc0e370 <_Thread_Enable_dispatch> if ( !do_wait ) { ffc0a068: 2f 9f 00 00 cmpwi cr7,r31,0 ffc0a06c: 40 9e 00 74 bne- cr7,ffc0a0e0 if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) { ffc0a070: 3d 20 00 00 lis r9,0 ffc0a074: 81 29 27 fc lwz r9,10236(r9) ffc0a078: 80 09 00 34 lwz r0,52(r9) ffc0a07c: 2f 80 00 02 cmpwi cr7,r0,2 ffc0a080: 41 9e 00 48 beq- cr7,ffc0a0c8 break; } } } return _POSIX_RWLock_Translate_core_RWLock_return_code( ffc0a084: 7c 03 03 78 mr r3,r0 ffc0a088: 48 00 01 69 bl ffc0a1f0 <_POSIX_RWLock_Translate_core_RWLock_return_code> case OBJECTS_ERROR: break; } return EINVAL; } ffc0a08c: 80 01 00 2c lwz r0,44(r1) ffc0a090: 83 a1 00 1c lwz r29,28(r1) ffc0a094: 7c 08 03 a6 mtlr r0 ffc0a098: 83 c1 00 20 lwz r30,32(r1) ffc0a09c: 83 e1 00 24 lwz r31,36(r1) ffc0a0a0: 38 21 00 28 addi r1,r1,40 ffc0a0a4: 4e 80 00 20 blr break; } } } return _POSIX_RWLock_Translate_core_RWLock_return_code( ffc0a0a8: 38 60 00 16 li r3,22 case OBJECTS_ERROR: break; } return EINVAL; } ffc0a0ac: 80 01 00 2c lwz r0,44(r1) ffc0a0b0: 83 a1 00 1c lwz r29,28(r1) ffc0a0b4: 7c 08 03 a6 mtlr r0 ffc0a0b8: 83 c1 00 20 lwz r30,32(r1) ffc0a0bc: 83 e1 00 24 lwz r31,36(r1) ffc0a0c0: 38 21 00 28 addi r1,r1,40 ffc0a0c4: 4e 80 00 20 blr ); _Thread_Enable_dispatch(); if ( !do_wait ) { if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) { switch (status) { ffc0a0c8: 2f 9e 00 00 cmpwi cr7,r30,0 ffc0a0cc: 41 be ff dc beq- cr7,ffc0a0a8 ffc0a0d0: 2b 9e 00 02 cmplwi cr7,r30,2 ffc0a0d4: 38 60 00 74 li r3,116 ffc0a0d8: 40 bd ff d4 ble- cr7,ffc0a0ac ffc0a0dc: 4b ff ff a8 b ffc0a084 <== NOT EXECUTED ffc0a0e0: 3d 20 00 00 lis r9,0 ffc0a0e4: 81 29 27 fc lwz r9,10236(r9) ffc0a0e8: 80 09 00 34 lwz r0,52(r9) ffc0a0ec: 4b ff ff 98 b ffc0a084 ffc0a0f0 : int pthread_rwlock_timedwrlock( pthread_rwlock_t *rwlock, const struct timespec *abstime ) { ffc0a0f0: 94 21 ff d8 stwu r1,-40(r1) ffc0a0f4: 7c 08 02 a6 mflr r0 ffc0a0f8: 93 a1 00 1c stw r29,28(r1) Objects_Locations location; Watchdog_Interval ticks; bool do_wait = true; POSIX_Absolute_timeout_conversion_results_t status; if ( !rwlock ) ffc0a0fc: 7c 7d 1b 79 mr. r29,r3 int pthread_rwlock_timedwrlock( pthread_rwlock_t *rwlock, const struct timespec *abstime ) { ffc0a100: 90 01 00 2c stw r0,44(r1) ffc0a104: 93 c1 00 20 stw r30,32(r1) ffc0a108: 93 e1 00 24 stw r31,36(r1) Objects_Locations location; Watchdog_Interval ticks; bool do_wait = true; POSIX_Absolute_timeout_conversion_results_t status; if ( !rwlock ) ffc0a10c: 41 82 00 9c beq- ffc0a1a8 * * 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 ); ffc0a110: 7c 83 23 78 mr r3,r4 ffc0a114: 38 81 00 0c addi r4,r1,12 ffc0a118: 48 00 7e 99 bl ffc11fb0 <_POSIX_Absolute_timeout_to_ticks> ffc0a11c: 80 9d 00 00 lwz r4,0(r29) ffc0a120: 7c 7e 1b 78 mr r30,r3 ffc0a124: 3c 60 00 00 lis r3,0 ffc0a128: 38 63 2e 38 addi r3,r3,11832 ffc0a12c: 38 a1 00 08 addi r5,r1,8 ffc0a130: 48 00 36 75 bl ffc0d7a4 <_Objects_Get> if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE ) do_wait = false; the_rwlock = _POSIX_RWLock_Get( rwlock, &location ); switch ( location ) { ffc0a134: 80 01 00 08 lwz r0,8(r1) ffc0a138: 2f 80 00 00 cmpwi cr7,r0,0 ffc0a13c: 40 9e 00 6c bne- cr7,ffc0a1a8 (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, ffc0a140: 6b df 00 03 xori r31,r30,3 case OBJECTS_LOCAL: _CORE_RWLock_Obtain_for_writing( ffc0a144: 80 9d 00 00 lwz r4,0(r29) ffc0a148: 7f ff 00 34 cntlzw r31,r31 ffc0a14c: 80 c1 00 0c lwz r6,12(r1) ffc0a150: 57 ff d9 7e rlwinm r31,r31,27,5,31 ffc0a154: 38 63 00 10 addi r3,r3,16 ffc0a158: 7f e5 fb 78 mr r5,r31 ffc0a15c: 38 e0 00 00 li r7,0 ffc0a160: 48 00 27 0d bl ffc0c86c <_CORE_RWLock_Obtain_for_writing> do_wait, ticks, NULL ); _Thread_Enable_dispatch(); ffc0a164: 48 00 42 0d bl ffc0e370 <_Thread_Enable_dispatch> if ( !do_wait && ffc0a168: 2f 9f 00 00 cmpwi cr7,r31,0 ffc0a16c: 40 9e 00 74 bne- cr7,ffc0a1e0 (_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) { ffc0a170: 3d 20 00 00 lis r9,0 ffc0a174: 81 29 27 fc lwz r9,10236(r9) ffc0a178: 80 09 00 34 lwz r0,52(r9) ticks, NULL ); _Thread_Enable_dispatch(); if ( !do_wait && ffc0a17c: 2f 80 00 02 cmpwi cr7,r0,2 ffc0a180: 41 9e 00 48 beq- cr7,ffc0a1c8 case POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE: break; } } return _POSIX_RWLock_Translate_core_RWLock_return_code( ffc0a184: 7c 03 03 78 mr r3,r0 ffc0a188: 48 00 00 69 bl ffc0a1f0 <_POSIX_RWLock_Translate_core_RWLock_return_code> case OBJECTS_ERROR: break; } return EINVAL; } ffc0a18c: 80 01 00 2c lwz r0,44(r1) ffc0a190: 83 a1 00 1c lwz r29,28(r1) ffc0a194: 7c 08 03 a6 mtlr r0 ffc0a198: 83 c1 00 20 lwz r30,32(r1) ffc0a19c: 83 e1 00 24 lwz r31,36(r1) ffc0a1a0: 38 21 00 28 addi r1,r1,40 ffc0a1a4: 4e 80 00 20 blr case POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE: break; } } return _POSIX_RWLock_Translate_core_RWLock_return_code( ffc0a1a8: 38 60 00 16 li r3,22 case OBJECTS_ERROR: break; } return EINVAL; } ffc0a1ac: 80 01 00 2c lwz r0,44(r1) ffc0a1b0: 83 a1 00 1c lwz r29,28(r1) ffc0a1b4: 7c 08 03 a6 mtlr r0 ffc0a1b8: 83 c1 00 20 lwz r30,32(r1) ffc0a1bc: 83 e1 00 24 lwz r31,36(r1) ffc0a1c0: 38 21 00 28 addi r1,r1,40 ffc0a1c4: 4e 80 00 20 blr ); _Thread_Enable_dispatch(); if ( !do_wait && (_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) { switch (status) { ffc0a1c8: 2f 9e 00 00 cmpwi cr7,r30,0 ffc0a1cc: 41 be ff dc beq- cr7,ffc0a1a8 ffc0a1d0: 2b 9e 00 02 cmplwi cr7,r30,2 ffc0a1d4: 38 60 00 74 li r3,116 ffc0a1d8: 40 bd ff d4 ble- cr7,ffc0a1ac ffc0a1dc: 4b ff ff a8 b ffc0a184 <== NOT EXECUTED ffc0a1e0: 3d 20 00 00 lis r9,0 ffc0a1e4: 81 29 27 fc lwz r9,10236(r9) ffc0a1e8: 80 09 00 34 lwz r0,52(r9) ffc0a1ec: 4b ff ff 98 b ffc0a184 ffc08e2c : * * 18.2.2 Setting Cancelability State, P1003.1c/Draft 10, p. 183 */ void pthread_testcancel( void ) { ffc08e2c: 94 21 ff f0 stwu r1,-16(r1) ffc08e30: 7c 08 02 a6 mflr r0 * 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() ) ffc08e34: 3d 20 00 00 lis r9,0 * * 18.2.2 Setting Cancelability State, P1003.1c/Draft 10, p. 183 */ void pthread_testcancel( void ) { ffc08e38: 90 01 00 14 stw r0,20(r1) * 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() ) ffc08e3c: 80 09 27 bc lwz r0,10172(r9) * * 18.2.2 Setting Cancelability State, P1003.1c/Draft 10, p. 183 */ void pthread_testcancel( void ) { ffc08e40: 93 e1 00 0c stw r31,12(r1) * 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() ) ffc08e44: 2f 80 00 00 cmpwi cr7,r0,0 ffc08e48: 40 9e 00 48 bne- cr7,ffc08e90 ffc08e4c: 3d 20 00 00 lis r9,0 ffc08e50: 81 49 27 94 lwz r10,10132(r9) return; thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ]; ffc08e54: 3f e0 00 00 lis r31,0 ffc08e58: 81 7f 27 d4 lwz r11,10196(r31) ffc08e5c: 38 0a 00 01 addi r0,r10,1 ffc08e60: 90 09 27 94 stw r0,10132(r9) ffc08e64: 81 2b 01 48 lwz r9,328(r11) _Thread_Disable_dispatch(); if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE && ffc08e68: 80 09 00 d4 lwz r0,212(r9) ffc08e6c: 2f 80 00 00 cmpwi cr7,r0,0 ffc08e70: 40 9e 00 34 bne- cr7,ffc08ea4 thread_support->cancelation_requested ) ffc08e74: 80 09 00 dc lwz r0,220(r9) ffc08e78: 2f 80 00 00 cmpwi cr7,r0,0 ffc08e7c: 41 9e 00 28 beq- cr7,ffc08ea4 cancel = true; _Thread_Enable_dispatch(); ffc08e80: 48 00 32 3d bl ffc0c0bc <_Thread_Enable_dispatch> if ( cancel ) _POSIX_Thread_Exit( _Thread_Executing, PTHREAD_CANCELED ); ffc08e84: 80 7f 27 d4 lwz r3,10196(r31) ffc08e88: 38 80 ff ff li r4,-1 ffc08e8c: 48 00 71 4d bl ffc0ffd8 <_POSIX_Thread_Exit> } ffc08e90: 80 01 00 14 lwz r0,20(r1) <== NOT EXECUTED ffc08e94: 83 e1 00 0c lwz r31,12(r1) <== NOT EXECUTED ffc08e98: 38 21 00 10 addi r1,r1,16 <== NOT EXECUTED ffc08e9c: 7c 08 03 a6 mtlr r0 <== NOT EXECUTED ffc08ea0: 4e 80 00 20 blr <== NOT EXECUTED _Thread_Disable_dispatch(); if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE && thread_support->cancelation_requested ) cancel = true; _Thread_Enable_dispatch(); ffc08ea4: 48 00 32 19 bl ffc0c0bc <_Thread_Enable_dispatch> if ( cancel ) _POSIX_Thread_Exit( _Thread_Executing, PTHREAD_CANCELED ); } ffc08ea8: 80 01 00 14 lwz r0,20(r1) ffc08eac: 83 e1 00 0c lwz r31,12(r1) ffc08eb0: 38 21 00 10 addi r1,r1,16 ffc08eb4: 7c 08 03 a6 mtlr r0 ffc08eb8: 4e 80 00 20 blr ffc0b08c : 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 ) { ffc0b08c: 94 21 ff f0 stwu r1,-16(r1) ffc0b090: 7c 08 02 a6 mflr r0 rtems_device_major_number major_limit = _IO_Number_of_drivers; if ( rtems_interrupt_is_in_progress() ) ffc0b094: 3d 20 00 00 lis r9,0 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 ) { ffc0b098: 90 01 00 14 stw r0,20(r1) rtems_device_major_number major_limit = _IO_Number_of_drivers; if ( rtems_interrupt_is_in_progress() ) ffc0b09c: 80 09 27 b8 lwz r0,10168(r9) 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; ffc0b0a0: 3d 20 00 00 lis r9,0 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 ) { ffc0b0a4: 93 e1 00 0c stw r31,12(r1) ffc0b0a8: 7c 7f 1b 78 mr r31,r3 rtems_device_major_number major_limit = _IO_Number_of_drivers; if ( rtems_interrupt_is_in_progress() ) ffc0b0ac: 2f 80 00 00 cmpwi cr7,r0,0 ffc0b0b0: 38 60 00 12 li r3,18 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; ffc0b0b4: 80 09 28 08 lwz r0,10248(r9) if ( rtems_interrupt_is_in_progress() ) ffc0b0b8: 40 9e 00 e8 bne- cr7,ffc0b1a0 return RTEMS_CALLED_FROM_ISR; if ( registered_major == NULL ) ffc0b0bc: 2f 85 00 00 cmpwi cr7,r5,0 ffc0b0c0: 41 9e 01 38 beq- cr7,ffc0b1f8 return RTEMS_INVALID_ADDRESS; /* Set it to an invalid value */ *registered_major = major_limit; if ( driver_table == NULL ) ffc0b0c4: 2f 84 00 00 cmpwi cr7,r4,0 if ( registered_major == NULL ) return RTEMS_INVALID_ADDRESS; /* Set it to an invalid value */ *registered_major = major_limit; ffc0b0c8: 90 05 00 00 stw r0,0(r5) if ( driver_table == NULL ) ffc0b0cc: 41 9e 01 2c beq- cr7,ffc0b1f8 static inline bool rtems_io_is_empty_table( const rtems_driver_address_table *table ) { return table->initialization_entry == NULL && table->open_entry == NULL; ffc0b0d0: 81 64 00 00 lwz r11,0(r4) ffc0b0d4: 2f 8b 00 00 cmpwi cr7,r11,0 ffc0b0d8: 41 9e 01 14 beq- cr7,ffc0b1ec return RTEMS_INVALID_ADDRESS; if ( rtems_io_is_empty_table( driver_table ) ) return RTEMS_INVALID_ADDRESS; if ( major >= major_limit ) ffc0b0dc: 7f 80 f8 40 cmplw cr7,r0,r31 ffc0b0e0: 38 60 00 0a li r3,10 ffc0b0e4: 40 9d 00 bc ble- cr7,ffc0b1a0 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; ffc0b0e8: 3d 60 00 00 lis r11,0 ffc0b0ec: 81 4b 27 90 lwz r10,10128(r11) ffc0b0f0: 38 0a 00 01 addi r0,r10,1 ffc0b0f4: 90 0b 27 90 stw r0,10128(r11) return RTEMS_INVALID_NUMBER; _Thread_Disable_dispatch(); if ( major == 0 ) { ffc0b0f8: 2f 9f 00 00 cmpwi cr7,r31,0 ffc0b0fc: 40 9e 00 b8 bne- cr7,ffc0b1b4 static rtems_status_code rtems_io_obtain_major_number( rtems_device_major_number *major ) { rtems_device_major_number n = _IO_Number_of_drivers; ffc0b100: 81 69 28 08 lwz r11,10248(r9) rtems_device_major_number m = 0; /* major is error checked by caller */ for ( m = 0; m < n; ++m ) { ffc0b104: 2f 8b 00 00 cmpwi cr7,r11,0 ffc0b108: 41 9e 01 08 beq- cr7,ffc0b210 ffc0b10c: 3d 20 00 00 lis r9,0 ffc0b110: 7d 69 03 a6 mtctr r11 ffc0b114: 81 49 28 0c lwz r10,10252(r9) ffc0b118: 7d 49 53 78 mr r9,r10 ffc0b11c: 40 be 00 14 bne+ cr7,ffc0b130 ffc0b120: 48 00 01 14 b ffc0b234 <== NOT EXECUTED ffc0b124: 3b ff 00 01 addi r31,r31,1 ffc0b128: 39 29 00 18 addi r9,r9,24 ffc0b12c: 42 40 00 1c bdz- ffc0b148 static inline bool rtems_io_is_empty_table( const rtems_driver_address_table *table ) { return table->initialization_entry == NULL && table->open_entry == NULL; ffc0b130: 80 09 00 00 lwz r0,0(r9) ffc0b134: 2f 80 00 00 cmpwi cr7,r0,0 ffc0b138: 40 9e ff ec bne+ cr7,ffc0b124 ffc0b13c: 80 09 00 04 lwz r0,4(r9) ffc0b140: 2f 80 00 00 cmpwi cr7,r0,0 ffc0b144: 40 9e ff e0 bne+ cr7,ffc0b124 } /* Assigns invalid value in case of failure */ *major = m; if ( m != n ) ffc0b148: 7f 8b f8 00 cmpw cr7,r11,r31 if ( rtems_io_is_empty_table( table ) ) break; } /* Assigns invalid value in case of failure */ *major = m; ffc0b14c: 93 e5 00 00 stw r31,0(r5) if ( m != n ) ffc0b150: 41 9e 00 c4 beq- cr7,ffc0b214 ffc0b154: 1d 3f 00 18 mulli r9,r31,24 ffc0b158: 7d 2a 4a 14 add r9,r10,r9 } *registered_major = major; } _IO_Driver_address_table [major] = *driver_table; ffc0b15c: 81 64 00 08 lwz r11,8(r4) ffc0b160: 80 04 00 0c lwz r0,12(r4) ffc0b164: 81 04 00 00 lwz r8,0(r4) ffc0b168: 81 44 00 04 lwz r10,4(r4) ffc0b16c: 91 09 00 00 stw r8,0(r9) ffc0b170: 91 49 00 04 stw r10,4(r9) ffc0b174: 91 69 00 08 stw r11,8(r9) ffc0b178: 90 09 00 0c stw r0,12(r9) ffc0b17c: 81 64 00 14 lwz r11,20(r4) ffc0b180: 80 04 00 10 lwz r0,16(r4) ffc0b184: 91 69 00 14 stw r11,20(r9) ffc0b188: 90 09 00 10 stw r0,16(r9) _Thread_Enable_dispatch(); ffc0b18c: 48 00 22 2d bl ffc0d3b8 <_Thread_Enable_dispatch> return rtems_io_initialize( major, 0, NULL ); ffc0b190: 7f e3 fb 78 mr r3,r31 ffc0b194: 38 80 00 00 li r4,0 ffc0b198: 38 a0 00 00 li r5,0 ffc0b19c: 48 00 ae 65 bl ffc16000 } ffc0b1a0: 80 01 00 14 lwz r0,20(r1) ffc0b1a4: 83 e1 00 0c lwz r31,12(r1) ffc0b1a8: 38 21 00 10 addi r1,r1,16 ffc0b1ac: 7c 08 03 a6 mtlr r0 ffc0b1b0: 4e 80 00 20 blr _Thread_Enable_dispatch(); return sc; } major = *registered_major; } else { rtems_driver_address_table *const table = _IO_Driver_address_table + major; ffc0b1b4: 3d 20 00 00 lis r9,0 ffc0b1b8: 81 29 28 0c lwz r9,10252(r9) ffc0b1bc: 1c 1f 00 18 mulli r0,r31,24 static inline bool rtems_io_is_empty_table( const rtems_driver_address_table *table ) { return table->initialization_entry == NULL && table->open_entry == NULL; ffc0b1c0: 7d 69 00 2e lwzx r11,r9,r0 _Thread_Enable_dispatch(); return sc; } major = *registered_major; } else { rtems_driver_address_table *const table = _IO_Driver_address_table + major; ffc0b1c4: 7d 29 02 14 add r9,r9,r0 static inline bool rtems_io_is_empty_table( const rtems_driver_address_table *table ) { return table->initialization_entry == NULL && table->open_entry == NULL; ffc0b1c8: 2f 8b 00 00 cmpwi cr7,r11,0 ffc0b1cc: 41 9e 00 54 beq- cr7,ffc0b220 major = *registered_major; } else { rtems_driver_address_table *const table = _IO_Driver_address_table + major; if ( !rtems_io_is_empty_table( table ) ) { _Thread_Enable_dispatch(); ffc0b1d0: 48 00 21 e9 bl ffc0d3b8 <_Thread_Enable_dispatch> _IO_Driver_address_table [major] = *driver_table; _Thread_Enable_dispatch(); return rtems_io_initialize( major, 0, NULL ); } ffc0b1d4: 80 01 00 14 lwz r0,20(r1) major = *registered_major; } else { rtems_driver_address_table *const table = _IO_Driver_address_table + major; if ( !rtems_io_is_empty_table( table ) ) { _Thread_Enable_dispatch(); ffc0b1d8: 38 60 00 0c li r3,12 _IO_Driver_address_table [major] = *driver_table; _Thread_Enable_dispatch(); return rtems_io_initialize( major, 0, NULL ); } ffc0b1dc: 83 e1 00 0c lwz r31,12(r1) ffc0b1e0: 7c 08 03 a6 mtlr r0 ffc0b1e4: 38 21 00 10 addi r1,r1,16 ffc0b1e8: 4e 80 00 20 blr static inline bool rtems_io_is_empty_table( const rtems_driver_address_table *table ) { return table->initialization_entry == NULL && table->open_entry == NULL; ffc0b1ec: 81 64 00 04 lwz r11,4(r4) ffc0b1f0: 2f 8b 00 00 cmpwi cr7,r11,0 ffc0b1f4: 40 9e fe e8 bne+ cr7,ffc0b0dc _IO_Driver_address_table [major] = *driver_table; _Thread_Enable_dispatch(); return rtems_io_initialize( major, 0, NULL ); } ffc0b1f8: 80 01 00 14 lwz r0,20(r1) _IO_Driver_address_table [major] = *driver_table; _Thread_Enable_dispatch(); return rtems_io_initialize( major, 0, NULL ); ffc0b1fc: 38 60 00 09 li r3,9 } ffc0b200: 83 e1 00 0c lwz r31,12(r1) ffc0b204: 38 21 00 10 addi r1,r1,16 ffc0b208: 7c 08 03 a6 mtlr r0 ffc0b20c: 4e 80 00 20 blr if ( rtems_io_is_empty_table( table ) ) break; } /* Assigns invalid value in case of failure */ *major = m; ffc0b210: 93 e5 00 00 stw r31,0(r5) <== NOT EXECUTED if ( major == 0 ) { rtems_status_code sc = rtems_io_obtain_major_number( registered_major ); if ( sc != RTEMS_SUCCESSFUL ) { _Thread_Enable_dispatch(); ffc0b214: 48 00 21 a5 bl ffc0d3b8 <_Thread_Enable_dispatch> ffc0b218: 38 60 00 05 li r3,5 return sc; ffc0b21c: 4b ff ff 84 b ffc0b1a0 static inline bool rtems_io_is_empty_table( const rtems_driver_address_table *table ) { return table->initialization_entry == NULL && table->open_entry == NULL; ffc0b220: 80 09 00 04 lwz r0,4(r9) ffc0b224: 2f 80 00 00 cmpwi cr7,r0,0 ffc0b228: 40 9e ff a8 bne+ cr7,ffc0b1d0 if ( !rtems_io_is_empty_table( table ) ) { _Thread_Enable_dispatch(); return RTEMS_RESOURCE_IN_USE; } *registered_major = major; ffc0b22c: 93 e5 00 00 stw r31,0(r5) ffc0b230: 4b ff ff 2c b ffc0b15c ffc0b234: 38 00 00 01 li r0,1 <== NOT EXECUTED ffc0b238: 7c 09 03 a6 mtctr r0 <== NOT EXECUTED ffc0b23c: 4b ff fe f4 b ffc0b130 <== NOT EXECUTED ffc47dbc : rtems_status_code rtems_rate_monotonic_period( rtems_id id, rtems_interval length ) { ffc47dbc: 94 21 ff d0 stwu r1,-48(r1) ffc47dc0: 7c 08 02 a6 mflr r0 ffc47dc4: 93 e1 00 2c stw r31,44(r1) ffc47dc8: 7c 7f 1b 78 mr r31,r3 ffc47dcc: 3c 60 00 00 lis r3,0 ffc47dd0: 93 c1 00 28 stw r30,40(r1) ffc47dd4: 38 63 6f ec addi r3,r3,28652 ffc47dd8: 7c 9e 23 78 mr r30,r4 ffc47ddc: 38 a1 00 08 addi r5,r1,8 ffc47de0: 90 01 00 34 stw r0,52(r1) ffc47de4: 7f e4 fb 78 mr r4,r31 ffc47de8: 93 a1 00 24 stw r29,36(r1) ffc47dec: 93 61 00 1c stw r27,28(r1) ffc47df0: 93 81 00 20 stw r28,32(r1) ffc47df4: 4b fc 6e 85 bl ffc0ec78 <_Objects_Get> ffc47df8: 7c 7d 1b 78 mr r29,r3 rtems_rate_monotonic_period_states local_state; ISR_Level level; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { ffc47dfc: 80 01 00 08 lwz r0,8(r1) ffc47e00: 2f 80 00 00 cmpwi cr7,r0,0 ffc47e04: 40 9e 00 48 bne- cr7,ffc47e4c case OBJECTS_LOCAL: if ( !_Thread_Is_executing( the_period->owner ) ) { ffc47e08: 3f 80 00 00 lis r28,0 ffc47e0c: 81 23 00 40 lwz r9,64(r3) ffc47e10: 80 1c 36 58 lwz r0,13912(r28) ffc47e14: 7f 89 00 00 cmpw cr7,r9,r0 ffc47e18: 41 9e 00 60 beq- cr7,ffc47e78 _Thread_Enable_dispatch(); ffc47e1c: 4b fc 7b 55 bl ffc0f970 <_Thread_Enable_dispatch> ffc47e20: 3b e0 00 17 li r31,23 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } ffc47e24: 80 01 00 34 lwz r0,52(r1) ffc47e28: 7f e3 fb 78 mr r3,r31 ffc47e2c: 83 61 00 1c lwz r27,28(r1) ffc47e30: 7c 08 03 a6 mtlr r0 ffc47e34: 83 81 00 20 lwz r28,32(r1) ffc47e38: 83 a1 00 24 lwz r29,36(r1) ffc47e3c: 83 c1 00 28 lwz r30,40(r1) ffc47e40: 83 e1 00 2c lwz r31,44(r1) ffc47e44: 38 21 00 30 addi r1,r1,48 ffc47e48: 4e 80 00 20 blr ffc47e4c: 80 01 00 34 lwz r0,52(r1) the_period->state = RATE_MONOTONIC_ACTIVE; the_period->next_length = length; _Watchdog_Insert_ticks( &the_period->Timer, length ); _Thread_Enable_dispatch(); return RTEMS_TIMEOUT; ffc47e50: 3b e0 00 04 li r31,4 case OBJECTS_ERROR: break; } return RTEMS_INVALID_ID; } ffc47e54: 7f e3 fb 78 mr r3,r31 ffc47e58: 83 61 00 1c lwz r27,28(r1) ffc47e5c: 7c 08 03 a6 mtlr r0 ffc47e60: 83 81 00 20 lwz r28,32(r1) ffc47e64: 83 a1 00 24 lwz r29,36(r1) ffc47e68: 83 c1 00 28 lwz r30,40(r1) ffc47e6c: 83 e1 00 2c lwz r31,44(r1) ffc47e70: 38 21 00 30 addi r1,r1,48 ffc47e74: 4e 80 00 20 blr if ( !_Thread_Is_executing( the_period->owner ) ) { _Thread_Enable_dispatch(); return RTEMS_NOT_OWNER_OF_RESOURCE; } if ( length == RTEMS_PERIOD_STATUS ) { ffc47e78: 2f 9e 00 00 cmpwi cr7,r30,0 ffc47e7c: 41 9e 00 b4 beq- cr7,ffc47f30 static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc47e80: 7f 60 00 a6 mfmsr r27 ffc47e84: 7c 10 42 a6 mfsprg r0,0 ffc47e88: 7f 60 00 78 andc r0,r27,r0 ffc47e8c: 7c 00 01 24 mtmsr r0 _Thread_Enable_dispatch(); return( return_value ); } _ISR_Disable( level ); switch ( the_period->state ) { ffc47e90: 80 03 00 38 lwz r0,56(r3) ffc47e94: 2f 80 00 02 cmpwi cr7,r0,2 ffc47e98: 41 9e 00 c0 beq- cr7,ffc47f58 ffc47e9c: 2f 80 00 04 cmpwi cr7,r0,4 ffc47ea0: 41 9e 00 5c beq- cr7,ffc47efc ffc47ea4: 2f 80 00 00 cmpwi cr7,r0,0 ffc47ea8: 40 be ff a4 bne- cr7,ffc47e4c return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc47eac: 7f 60 01 24 mtmsr r27 _ISR_Enable( level ); /* * Baseline statistics information for the beginning of a period. */ _Rate_monotonic_Initiate_statistics( the_period ); ffc47eb0: 4b ff fc 1d bl ffc47acc <_Rate_monotonic_Initiate_statistics> the_period->state = RATE_MONOTONIC_ACTIVE; ffc47eb4: 39 20 00 02 li r9,2 ffc47eb8: 91 3d 00 38 stw r9,56(r29) Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; ffc47ebc: 3d 20 ff c4 lis r9,-60 Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; ffc47ec0: 38 00 00 00 li r0,0 the_watchdog->routine = routine; ffc47ec4: 39 29 7f c8 addi r9,r9,32712 the_watchdog->id = id; ffc47ec8: 93 fd 00 30 stw r31,48(r29) ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); ffc47ecc: 3c 60 00 00 lis r3,0 Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; ffc47ed0: 91 3d 00 2c stw r9,44(r29) ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); ffc47ed4: 38 63 65 e8 addi r3,r3,26088 ffc47ed8: 38 9d 00 10 addi r4,r29,16 ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; the_watchdog->id = id; the_watchdog->user_data = user_data; ffc47edc: 90 1d 00 34 stw r0,52(r29) ); the_period->next_length = length; _Watchdog_Insert_ticks( &the_period->Timer, length ); _Thread_Enable_dispatch(); ffc47ee0: 3b e0 00 00 li r31,0 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; ffc47ee4: 93 dd 00 1c stw r30,28(r29) Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; ffc47ee8: 90 1d 00 18 stw r0,24(r29) _Rate_monotonic_Timeout, id, NULL ); the_period->next_length = length; ffc47eec: 93 dd 00 3c stw r30,60(r29) ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); ffc47ef0: 4b fc 91 6d bl ffc1105c <_Watchdog_Insert> _Watchdog_Insert_ticks( &the_period->Timer, length ); _Thread_Enable_dispatch(); ffc47ef4: 4b fc 7a 7d bl ffc0f970 <_Thread_Enable_dispatch> return RTEMS_SUCCESSFUL; ffc47ef8: 4b ff ff 2c b ffc47e24 case RATE_MONOTONIC_EXPIRED: /* * Update statistics from the concluding period */ _Rate_monotonic_Update_statistics( the_period ); ffc47efc: 4b ff fd 79 bl ffc47c74 <_Rate_monotonic_Update_statistics> ffc47f00: 7f 60 01 24 mtmsr r27 _ISR_Enable( level ); the_period->state = RATE_MONOTONIC_ACTIVE; ffc47f04: 38 00 00 02 li r0,2 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; ffc47f08: 93 dd 00 1c stw r30,28(r29) _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); ffc47f0c: 3c 60 00 00 lis r3,0 ffc47f10: 90 1d 00 38 stw r0,56(r29) ffc47f14: 38 63 65 e8 addi r3,r3,26088 ffc47f18: 38 9d 00 10 addi r4,r29,16 the_period->next_length = length; ffc47f1c: 93 dd 00 3c stw r30,60(r29) _Watchdog_Insert_ticks( &the_period->Timer, length ); _Thread_Enable_dispatch(); ffc47f20: 3b e0 00 06 li r31,6 ffc47f24: 4b fc 91 39 bl ffc1105c <_Watchdog_Insert> ffc47f28: 4b fc 7a 49 bl ffc0f970 <_Thread_Enable_dispatch> return RTEMS_TIMEOUT; ffc47f2c: 4b ff fe f8 b ffc47e24 _Thread_Enable_dispatch(); return RTEMS_NOT_OWNER_OF_RESOURCE; } if ( length == RTEMS_PERIOD_STATUS ) { switch ( the_period->state ) { ffc47f30: 80 03 00 38 lwz r0,56(r3) ffc47f34: 3b e0 00 00 li r31,0 ffc47f38: 2b 80 00 04 cmplwi cr7,r0,4 ffc47f3c: 41 bd ff b8 bgt- cr7,ffc47ef4 ffc47f40: 3d 20 ff c7 lis r9,-57 ffc47f44: 54 00 10 3a rlwinm r0,r0,2,0,29 ffc47f48: 39 29 3f 6c addi r9,r9,16236 ffc47f4c: 7f e9 00 2e lwzx r31,r9,r0 ); the_period->next_length = length; _Watchdog_Insert_ticks( &the_period->Timer, length ); _Thread_Enable_dispatch(); ffc47f50: 4b fc 7a 21 bl ffc0f970 <_Thread_Enable_dispatch> ffc47f54: 4b ff fe d0 b ffc47e24 case RATE_MONOTONIC_ACTIVE: /* * Update statistics from the concluding period. */ _Rate_monotonic_Update_statistics( the_period ); ffc47f58: 4b ff fd 1d bl ffc47c74 <_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; ffc47f5c: 38 00 00 01 li r0,1 the_period->next_length = length; ffc47f60: 93 dd 00 3c stw r30,60(r29) /* * 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; ffc47f64: 90 1d 00 38 stw r0,56(r29) ffc47f68: 7f 60 01 24 mtmsr r27 the_period->next_length = length; _ISR_Enable( level ); _Thread_Executing->Wait.id = the_period->Object.id; ffc47f6c: 81 3c 36 58 lwz r9,13912(r28) _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); ffc47f70: 38 80 40 00 li r4,16384 the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING; the_period->next_length = length; _ISR_Enable( level ); _Thread_Executing->Wait.id = the_period->Object.id; ffc47f74: 80 1d 00 08 lwz r0,8(r29) _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); ffc47f78: 7d 23 4b 78 mr r3,r9 the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING; the_period->next_length = length; _ISR_Enable( level ); _Thread_Executing->Wait.id = the_period->Object.id; ffc47f7c: 90 09 00 20 stw r0,32(r9) _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); ffc47f80: 4b fc 85 6d bl ffc104ec <_Thread_Set_state> static inline uint32_t ppc_interrupt_disable( void ) { uint32_t level; uint32_t mask; asm volatile ( ffc47f84: 7d 20 00 a6 mfmsr r9 ffc47f88: 7c 10 42 a6 mfsprg r0,0 ffc47f8c: 7d 20 00 78 andc r0,r9,r0 ffc47f90: 7c 00 01 24 mtmsr r0 * 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; ffc47f94: 39 60 00 02 li r11,2 /* * Did the watchdog timer expire while we were actually blocking * on it? */ _ISR_Disable( level ); local_state = the_period->state; ffc47f98: 80 1d 00 38 lwz r0,56(r29) the_period->state = RATE_MONOTONIC_ACTIVE; ffc47f9c: 91 7d 00 38 stw r11,56(r29) return level; } static inline void ppc_interrupt_enable( uint32_t level ) { asm volatile ( ffc47fa0: 7d 20 01 24 mtmsr r9 /* * 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 ) ffc47fa4: 2f 80 00 03 cmpwi cr7,r0,3 ffc47fa8: 41 9e 00 10 beq- cr7,ffc47fb8 _Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); _Thread_Enable_dispatch(); ffc47fac: 4b fc 79 c5 bl ffc0f970 <_Thread_Enable_dispatch> ffc47fb0: 3b e0 00 00 li r31,0 return RTEMS_SUCCESSFUL; ffc47fb4: 4b ff fe 70 b ffc47e24 /* * 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 ) _Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); ffc47fb8: 80 7c 36 58 lwz r3,13912(r28) <== NOT EXECUTED ffc47fbc: 38 80 40 00 li r4,16384 <== NOT EXECUTED ffc47fc0: 4b fc 74 9d bl ffc0f45c <_Thread_Clear_state> <== NOT EXECUTED ffc47fc4: 4b ff ff e8 b ffc47fac <== NOT EXECUTED ffc0bd80 : int sem_timedwait( sem_t *sem, const struct timespec *abstime ) { ffc0bd80: 94 21 ff e0 stwu r1,-32(r1) ffc0bd84: 7c 08 02 a6 mflr r0 ffc0bd88: 93 e1 00 1c stw r31,28(r1) ffc0bd8c: 7c 7f 1b 78 mr r31,r3 * * 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 ); ffc0bd90: 7c 83 23 78 mr r3,r4 ffc0bd94: 38 81 00 08 addi r4,r1,8 int sem_timedwait( sem_t *sem, const struct timespec *abstime ) { ffc0bd98: 90 01 00 24 stw r0,36(r1) * * 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 ); ffc0bd9c: 48 00 6b f9 bl ffc12994 <_POSIX_Absolute_timeout_to_ticks> if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE ) ffc0bda0: 2f 83 00 03 cmpwi cr7,r3,3 ffc0bda4: 41 9e 00 28 beq- cr7,ffc0bdcc do_wait = false; lock_status = _POSIX_Semaphore_Wait_support( sem, do_wait, ticks ); ffc0bda8: 80 a1 00 08 lwz r5,8(r1) <== NOT EXECUTED ffc0bdac: 7f e3 fb 78 mr r3,r31 <== NOT EXECUTED ffc0bdb0: 38 80 00 00 li r4,0 <== NOT EXECUTED ffc0bdb4: 48 00 7a 4d bl ffc13800 <_POSIX_Semaphore_Wait_support><== NOT EXECUTED break; } } return lock_status; } ffc0bdb8: 80 01 00 24 lwz r0,36(r1) <== NOT EXECUTED ffc0bdbc: 83 e1 00 1c lwz r31,28(r1) <== NOT EXECUTED ffc0bdc0: 38 21 00 20 addi r1,r1,32 <== NOT EXECUTED ffc0bdc4: 7c 08 03 a6 mtlr r0 <== NOT EXECUTED ffc0bdc8: 4e 80 00 20 blr <== NOT EXECUTED */ status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks ); if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE ) do_wait = false; lock_status = _POSIX_Semaphore_Wait_support( sem, do_wait, ticks ); ffc0bdcc: 80 a1 00 08 lwz r5,8(r1) ffc0bdd0: 7f e3 fb 78 mr r3,r31 ffc0bdd4: 38 80 00 01 li r4,1 ffc0bdd8: 48 00 7a 29 bl ffc13800 <_POSIX_Semaphore_Wait_support> break; } } return lock_status; } ffc0bddc: 80 01 00 24 lwz r0,36(r1) ffc0bde0: 83 e1 00 1c lwz r31,28(r1) ffc0bde4: 38 21 00 20 addi r1,r1,32 ffc0bde8: 7c 08 03 a6 mtlr r0 ffc0bdec: 4e 80 00 20 blr