00008054 : { IMFS_jnode_t *node = loc->node_access; IMFS_fs_info_t *fs_info; fs_info = loc->mt_entry->fs_info; switch( node->type ) { 8054: e5903000 ldr r3, [r0] 8058: e593204c ldr r2, [r3, #76] ; 0x4c ) { IMFS_jnode_t *node = loc->node_access; IMFS_fs_info_t *fs_info; fs_info = loc->mt_entry->fs_info; 805c: e5903010 ldr r3, [r0, #16] switch( node->type ) { 8060: e2422001 sub r2, r2, #1 ) { IMFS_jnode_t *node = loc->node_access; IMFS_fs_info_t *fs_info; fs_info = loc->mt_entry->fs_info; 8064: e5933034 ldr r3, [r3, #52] ; 0x34 switch( node->type ) { 8068: e3520006 cmp r2, #6 806c: 979ff102 ldrls pc, [pc, r2, lsl #2] 8070: ea000010 b 80b8 <== NOT EXECUTED 8074: 00008090 .word 0x00008090 <== NOT EXECUTED 8078: 00008098 .word 0x00008098 <== NOT EXECUTED 807c: 000080a0 .word 0x000080a0 <== NOT EXECUTED 8080: 000080a0 .word 0x000080a0 <== NOT EXECUTED 8084: 000080a8 .word 0x000080a8 <== NOT EXECUTED 8088: 000080a8 .word 0x000080a8 <== NOT EXECUTED 808c: 000080b0 .word 0x000080b0 <== NOT EXECUTED case IMFS_DIRECTORY: loc->handlers = fs_info->directory_handlers; 8090: e5933008 ldr r3, [r3, #8] 8094: ea000006 b 80b4 break; case IMFS_DEVICE: loc->handlers = &IMFS_device_handlers; 8098: e59f3020 ldr r3, [pc, #32] ; 80c0 809c: ea000004 b 80b4 break; case IMFS_SYM_LINK: case IMFS_HARD_LINK: loc->handlers = &IMFS_link_handlers; 80a0: e59f301c ldr r3, [pc, #28] ; 80c4 80a4: ea000002 b 80b4 break; case IMFS_LINEAR_FILE: loc->handlers = fs_info->memfile_handlers; break; case IMFS_MEMORY_FILE: loc->handlers = fs_info->memfile_handlers; 80a8: e5933004 ldr r3, [r3, #4] 80ac: ea000000 b 80b4 break; case IMFS_FIFO: loc->handlers = &IMFS_fifo_handlers; 80b0: e59f3010 ldr r3, [pc, #16] ; 80c8 80b4: e5803008 str r3, [r0, #8] break; } return 0; } 80b8: e3a00000 mov r0, #0 80bc: e12fff1e bx lr 80c0: 00017ed0 .word 0x00017ed0 80c4: 00017f08 .word 0x00017f08 80c8: 00017e78 .word 0x00017e78 0000ad58 : IMFS_jnode_types_t type, const char *name, mode_t mode, const IMFS_types_union *info ) { ad58: e92d40f0 push {r4, r5, r6, r7, lr} IMFS_fs_info_t *fs_info; /* * MUST have a parent node to call this routine. */ if ( parent_loc == NULL ) ad5c: e2504000 subs r4, r0, #0 IMFS_jnode_types_t type, const char *name, mode_t mode, const IMFS_types_union *info ) { ad60: e1a05001 mov r5, r1 ad64: e59d6014 ldr r6, [sp, #20] ad68: e1a01002 mov r1, r2 IMFS_fs_info_t *fs_info; /* * MUST have a parent node to call this routine. */ if ( parent_loc == NULL ) ad6c: 01a07004 moveq r7, r4 ad70: 0a000041 beq ae7c return NULL; /* * Allocate filesystem node and fill in basic information */ node = IMFS_allocate_node( type, name, mode & ~rtems_filesystem_umask ); ad74: e59f2108 ldr r2, [pc, #264] ; ae84 ad78: e5922000 ldr r2, [r2] ad7c: e592202c ldr r2, [r2, #44] ; 0x2c ad80: e1a00005 mov r0, r5 ad84: e1c32002 bic r2, r3, r2 ad88: ebffffc5 bl aca4 if ( !node ) ad8c: e2507000 subs r7, r0, #0 ad90: 0a000039 beq ae7c return NULL; /* * Set the type specific information */ switch (type) { ad94: e2455001 sub r5, r5, #1 ad98: e3550006 cmp r5, #6 ad9c: 979ff105 ldrls pc, [pc, r5, lsl #2] ada0: ea000025 b ae3c <== NOT EXECUTED ada4: 0000adc0 .word 0x0000adc0 <== NOT EXECUTED ada8: 0000ade4 .word 0x0000ade4 <== NOT EXECUTED adac: 0000addc .word 0x0000addc <== NOT EXECUTED adb0: 0000addc .word 0x0000addc <== NOT EXECUTED adb4: 0000ae0c .word 0x0000ae0c <== NOT EXECUTED adb8: 0000adf4 .word 0x0000adf4 <== NOT EXECUTED adbc: 0000ae30 .word 0x0000ae30 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); adc0: e2872054 add r2, r7, #84 ; 0x54 the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); adc4: e2873050 add r3, r7, #80 ; 0x50 */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); adc8: e5872050 str r2, [r7, #80] ; 0x50 the_chain->permanent_null = NULL; adcc: e3a02000 mov r2, #0 add0: e5872054 str r2, [r7, #84] ; 0x54 the_chain->last = _Chain_Head(the_chain); add4: e5873058 str r3, [r7, #88] ; 0x58 add8: ea00001c b ae50 case IMFS_HARD_LINK: node->info.hard_link.link_node = info->hard_link.link_node; break; case IMFS_SYM_LINK: node->info.sym_link.name = info->sym_link.name; addc: e5963000 ldr r3, [r6] ade0: ea000013 b ae34 break; case IMFS_DEVICE: node->info.device.major = info->device.major; node->info.device.minor = info->device.minor; ade4: e5962004 ldr r2, [r6, #4] case IMFS_SYM_LINK: node->info.sym_link.name = info->sym_link.name; break; case IMFS_DEVICE: node->info.device.major = info->device.major; ade8: e5963000 ldr r3, [r6] node->info.device.minor = info->device.minor; adec: e5872054 str r2, [r7, #84] ; 0x54 adf0: ea00000f b ae34 break; case IMFS_LINEAR_FILE: node->info.linearfile.size = 0; adf4: e3a03000 mov r3, #0 <== NOT EXECUTED adf8: e3a02000 mov r2, #0 <== NOT EXECUTED adfc: e5872050 str r2, [r7, #80] ; 0x50 <== NOT EXECUTED ae00: e5873054 str r3, [r7, #84] ; 0x54 <== NOT EXECUTED node->info.linearfile.direct = 0; ae04: e3a03000 mov r3, #0 <== NOT EXECUTED ae08: e5873058 str r3, [r7, #88] ; 0x58 <== NOT EXECUTED case IMFS_MEMORY_FILE: node->info.file.size = 0; node->info.file.indirect = 0; ae0c: e3a03000 mov r3, #0 case IMFS_LINEAR_FILE: node->info.linearfile.size = 0; node->info.linearfile.direct = 0; case IMFS_MEMORY_FILE: node->info.file.size = 0; ae10: e3a01000 mov r1, #0 ae14: e3a02000 mov r2, #0 ae18: e5871050 str r1, [r7, #80] ; 0x50 ae1c: e5872054 str r2, [r7, #84] ; 0x54 node->info.file.indirect = 0; node->info.file.doubly_indirect = 0; node->info.file.triply_indirect = 0; ae20: e5873060 str r3, [r7, #96] ; 0x60 node->info.linearfile.size = 0; node->info.linearfile.direct = 0; case IMFS_MEMORY_FILE: node->info.file.size = 0; node->info.file.indirect = 0; ae24: e5873058 str r3, [r7, #88] ; 0x58 node->info.file.doubly_indirect = 0; ae28: e587305c str r3, [r7, #92] ; 0x5c node->info.file.triply_indirect = 0; break; ae2c: ea000007 b ae50 case IMFS_FIFO: node->info.fifo.pipe = NULL; ae30: e3a03000 mov r3, #0 ae34: e5873050 str r3, [r7, #80] ; 0x50 break; ae38: ea000004 b ae50 default: assert(0); ae3c: e59f0044 ldr r0, [pc, #68] ; ae88 <== NOT EXECUTED ae40: e3a0105c mov r1, #92 ; 0x5c <== NOT EXECUTED ae44: e59f2040 ldr r2, [pc, #64] ; ae8c <== NOT EXECUTED ae48: e59f3040 ldr r3, [pc, #64] ; ae90 <== NOT EXECUTED ae4c: ebfff7fd bl 8e48 <__assert_func> <== NOT EXECUTED /* * This node MUST have a parent, so put it in that directory list. */ parent = parent_loc->node_access; fs_info = parent_loc->mt_entry->fs_info; ae50: e5943010 ldr r3, [r4, #16] ae54: e5932034 ldr r2, [r3, #52] ; 0x34 node->Parent = parent; node->st_ino = ++fs_info->ino_count; ae58: e5923000 ldr r3, [r2] } /* * This node MUST have a parent, so put it in that directory list. */ parent = parent_loc->node_access; ae5c: e5940000 ldr r0, [r4] fs_info = parent_loc->mt_entry->fs_info; node->Parent = parent; node->st_ino = ++fs_info->ino_count; ae60: e2833001 add r3, r3, #1 ae64: e5823000 str r3, [r2] * This node MUST have a parent, so put it in that directory list. */ parent = parent_loc->node_access; fs_info = parent_loc->mt_entry->fs_info; node->Parent = parent; ae68: e5870008 str r0, [r7, #8] node->st_ino = ++fs_info->ino_count; ae6c: e5873038 str r3, [r7, #56] ; 0x38 RTEMS_INLINE_ROUTINE void rtems_chain_append( rtems_chain_control *the_chain, rtems_chain_node *the_node ) { _Chain_Append( the_chain, the_node ); ae70: e2800050 add r0, r0, #80 ; 0x50 ae74: e1a01007 mov r1, r7 ae78: ebffe935 bl 5354 <_Chain_Append> rtems_chain_append( &parent->info.directory.Entries, &node->Node ); return node; } ae7c: e1a00007 mov r0, r7 ae80: e8bd80f0 pop {r4, r5, r6, r7, pc} ae84: 00017718 .word 0x00017718 ae88: 000186e9 .word 0x000186e9 ae8c: 00018018 .word 0x00018018 ae90: 000184b9 .word 0x000184b9 00003324 : rtems_chain_node *the_node; rtems_chain_control *the_chain; IMFS_jnode_t *the_jnode; int i; assert( the_directory ); 3324: e3500000 cmp r0, #0 void IMFS_dump_directory( IMFS_jnode_t *the_directory, int level ) { 3328: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} 332c: e1a05001 mov r5, r1 rtems_chain_node *the_node; rtems_chain_control *the_chain; IMFS_jnode_t *the_jnode; int i; assert( the_directory ); 3330: 059f00a4 ldreq r0, [pc, #164] ; 33dc 3334: 03a01084 moveq r1, #132 ; 0x84 3338: 059f20a0 ldreq r2, [pc, #160] ; 33e0 333c: 059f30a0 ldreq r3, [pc, #160] ; 33e4 3340: 0a000005 beq 335c assert( level >= 0 ); 3344: e3510000 cmp r1, #0 3348: aa000004 bge 3360 334c: e59f0088 ldr r0, [pc, #136] ; 33dc <== NOT EXECUTED 3350: e59f2088 ldr r2, [pc, #136] ; 33e0 <== NOT EXECUTED 3354: e59f308c ldr r3, [pc, #140] ; 33e8 <== NOT EXECUTED 3358: e3a01086 mov r1, #134 ; 0x86 <== NOT EXECUTED 335c: eb0001d7 bl 3ac0 <__assert_func> <== NOT EXECUTED assert( the_directory->type == IMFS_DIRECTORY ); 3360: e590304c ldr r3, [r0, #76] ; 0x4c 3364: e3530001 cmp r3, #1 3368: 159f006c ldrne r0, [pc, #108] ; 33dc 336c: 13a01088 movne r1, #136 ; 0x88 3370: 159f2068 ldrne r2, [pc, #104] ; 33e0 3374: 159f3070 ldrne r3, [pc, #112] ; 33ec 3378: 1afffff7 bne 335c */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 337c: e280a054 add sl, r0, #84 ; 0x54 the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first; 3380: e5904050 ldr r4, [r0, #80] ; 0x50 the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node; for ( i=0 ; i<=level ; i++ ) fprintf(stdout, "...." ); 3384: e59f8064 ldr r8, [pc, #100] ; 33f0 IMFS_print_jnode( the_jnode ); if ( the_jnode->type == IMFS_DIRECTORY ) IMFS_dump_directory( the_jnode, level + 1 ); 3388: e2817001 add r7, r1, #1 assert( the_directory->type == IMFS_DIRECTORY ); the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first; 338c: ea00000f b 33d0 !rtems_chain_is_tail( the_chain, the_node ); the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node; 3390: e3a06000 mov r6, #0 for ( i=0 ; i<=level ; i++ ) fprintf(stdout, "...." ); 3394: e5983000 ldr r3, [r8] !rtems_chain_is_tail( the_chain, the_node ); the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node; for ( i=0 ; i<=level ; i++ ) 3398: e2866001 add r6, r6, #1 fprintf(stdout, "...." ); 339c: e5931008 ldr r1, [r3, #8] 33a0: e59f004c ldr r0, [pc, #76] ; 33f4 33a4: eb00348d bl 105e0 !rtems_chain_is_tail( the_chain, the_node ); the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node; for ( i=0 ; i<=level ; i++ ) 33a8: e1560005 cmp r6, r5 33ac: dafffff8 ble 3394 fprintf(stdout, "...." ); IMFS_print_jnode( the_jnode ); 33b0: e1a00004 mov r0, r4 33b4: ebffff7e bl 31b4 if ( the_jnode->type == IMFS_DIRECTORY ) 33b8: e594304c ldr r3, [r4, #76] ; 0x4c 33bc: e3530001 cmp r3, #1 IMFS_dump_directory( the_jnode, level + 1 ); 33c0: 01a00004 moveq r0, r4 33c4: 01a01007 moveq r1, r7 33c8: 0bffffd5 bleq 3324 the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first; !rtems_chain_is_tail( the_chain, the_node ); the_node = the_node->next ) { 33cc: e5944000 ldr r4, [r4] assert( the_directory->type == IMFS_DIRECTORY ); the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first; 33d0: e154000a cmp r4, sl 33d4: 1affffed bne 3390 fprintf(stdout, "...." ); IMFS_print_jnode( the_jnode ); if ( the_jnode->type == IMFS_DIRECTORY ) IMFS_dump_directory( the_jnode, level + 1 ); } } 33d8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 33dc: 000218de .word 0x000218de 33e0: 0002065c .word 0x0002065c 33e4: 00021994 .word 0x00021994 33e8: 000219a2 .word 0x000219a2 33ec: 000219ad .word 0x000219ad 33f0: 000200f0 .word 0x000200f0 33f4: 000219d3 .word 0x000219d3 00008240 : const char *pathname, /* IN */ int pathnamelen, /* IN */ int flags, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN/OUT */ ) { 8240: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8244: e24dd044 sub sp, sp, #68 ; 0x44 8248: e1a04003 mov r4, r3 824c: e58d0000 str r0, [sp] 8250: e1a06001 mov r6, r1 8254: e58d2004 str r2, [sp, #4] /* * This was filled in by the caller and is valid in the * mount table. */ node = pathloc->node_access; 8258: e5935000 ldr r5, [r3] 825c: e3a0b001 mov fp, #1 8260: e3a07000 mov r7, #0 * Evaluate all tokens until we are done or an error occurs. */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { type = IMFS_get_token( &pathname[i], pathnamelen, token, &len ); 8264: e28da008 add sl, sp, #8 8268: e28d8040 add r8, sp, #64 ; 0x40 case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access ) 826c: e59f9244 ldr r9, [pc, #580] ; 84b8 /* * Evaluate all tokens until we are done or an error occurs. */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { 8270: ea000061 b 83fc type = IMFS_get_token( &pathname[i], pathnamelen, token, &len ); 8274: e59d1000 ldr r1, [sp] 8278: e1a03008 mov r3, r8 827c: e0810007 add r0, r1, r7 8280: e1a0200a mov r2, sl 8284: e1a01006 mov r1, r6 8288: eb0001f9 bl 8a74 pathnamelen -= len; i += len; if ( !pathloc->node_access ) 828c: e5943000 ldr r3, [r4] 8290: e3530000 cmp r3, #0 * Evaluate all tokens until we are done or an error occurs. */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { type = IMFS_get_token( &pathname[i], pathnamelen, token, &len ); 8294: e1a0b000 mov fp, r0 pathnamelen -= len; 8298: e59de040 ldr lr, [sp, #64] ; 0x40 i += len; if ( !pathloc->node_access ) 829c: 0a00004e beq 83dc rtems_set_errno_and_return_minus_one( ENOENT ); /* * I cannot move out of this directory without execute permission. */ if ( type != IMFS_NO_MORE_PATH ) 82a0: e3500000 cmp r0, #0 82a4: 0a000005 beq 82c0 if ( node->type == IMFS_DIRECTORY ) 82a8: e595204c ldr r2, [r5, #76] ; 0x4c 82ac: e3520001 cmp r2, #1 82b0: 1a000002 bne 82c0 /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test ) 82b4: e5932030 ldr r2, [r3, #48] ; 0x30 82b8: e3120040 tst r2, #64 ; 0x40 82bc: 0a000078 beq 84a4 if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) ) rtems_set_errno_and_return_minus_one( EACCES ); node = pathloc->node_access; switch( type ) { 82c0: e35b0003 cmp fp, #3 */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { type = IMFS_get_token( &pathname[i], pathnamelen, token, &len ); pathnamelen -= len; 82c4: e06e6006 rsb r6, lr, r6 i += len; 82c8: e087700e add r7, r7, lr if ( type != IMFS_NO_MORE_PATH ) if ( node->type == IMFS_DIRECTORY ) if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) ) rtems_set_errno_and_return_minus_one( EACCES ); node = pathloc->node_access; 82cc: e1a05003 mov r5, r3 switch( type ) { 82d0: 0a000021 beq 835c 82d4: e35b0004 cmp fp, #4 82d8: 0a000044 beq 83f0 82dc: e35b0002 cmp fp, #2 82e0: 1a000045 bne 83fc case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access ) 82e4: e5992000 ldr r2, [r9] 82e8: e5922018 ldr r2, [r2, #24] 82ec: e1530002 cmp r3, r2 82f0: 0a000041 beq 83fc /* * Am I at the root of this mounted filesystem? */ if (pathloc->node_access == pathloc->mt_entry->mt_fs_root.node_access) { 82f4: e5942010 ldr r2, [r4, #16] /* * Am I at the root of this mounted filesystem? */ if (pathloc->node_access == 82f8: e592101c ldr r1, [r2, #28] 82fc: e1530001 cmp r3, r1 8300: 1a00000f bne 8344 */ if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; /* Throw out the .. in this case */ } else { newloc = pathloc->mt_entry->mt_point_node; 8304: e2828008 add r8, r2, #8 8308: e8b8000f ldm r8!, {r0, r1, r2, r3} 830c: e28dc02c add ip, sp, #44 ; 0x2c 8310: e8ac000f stmia ip!, {r0, r1, r2, r3} *pathloc = newloc; 8314: e28d502c add r5, sp, #44 ; 0x2c 8318: e8b5000f ldm r5!, {r0, r1, r2, r3} */ if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; /* Throw out the .. in this case */ } else { newloc = pathloc->mt_entry->mt_point_node; 831c: e5985000 ldr r5, [r8] *pathloc = newloc; 8320: e1a08004 mov r8, r4 8324: e8a8000f stmia r8!, {r0, r1, r2, r3} return (*pathloc->ops->evalpath_h)(&(pathname[i-len]), 8328: e59d1000 ldr r1, [sp] 832c: e06e0007 rsb r0, lr, r7 if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; /* Throw out the .. in this case */ } else { newloc = pathloc->mt_entry->mt_point_node; *pathloc = newloc; 8330: e5885000 str r5, [r8] return (*pathloc->ops->evalpath_h)(&(pathname[i-len]), 8334: e0810000 add r0, r1, r0 */ if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; /* Throw out the .. in this case */ } else { newloc = pathloc->mt_entry->mt_point_node; 8338: e58c5000 str r5, [ip] *pathloc = newloc; return (*pathloc->ops->evalpath_h)(&(pathname[i-len]), 833c: e08e1006 add r1, lr, r6 8340: ea000046 b 8460 pathnamelen+len, flags,pathloc); } } else { if ( !node->Parent ) 8344: e5935008 ldr r5, [r3, #8] 8348: e3550000 cmp r5, #0 834c: 1a000025 bne 83e8 rtems_set_errno_and_return_minus_one( ENOENT ); 8350: eb000dfe bl bb50 <__errno> 8354: e580b000 str fp, [r0] 8358: ea000054 b 84b0 case IMFS_NAME: /* * If we are at a link follow it. */ if ( node->type == IMFS_HARD_LINK ) { 835c: e593304c ldr r3, [r3, #76] ; 0x4c 8360: e3530003 cmp r3, #3 8364: 1a000006 bne 8384 IMFS_evaluate_hard_link( pathloc, 0 ); 8368: e1a00004 mov r0, r4 836c: e3a01000 mov r1, #0 8370: ebffff5d bl 80ec node = pathloc->node_access; 8374: e5945000 ldr r5, [r4] if ( !node ) 8378: e3550000 cmp r5, #0 837c: 1a000008 bne 83a4 8380: ea00000a b 83b0 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTDIR ); } else if ( node->type == IMFS_SYM_LINK ) { 8384: e3530004 cmp r3, #4 8388: 1a000005 bne 83a4 result = IMFS_evaluate_sym_link( pathloc, 0 ); 838c: e1a00004 mov r0, r4 8390: e3a01000 mov r1, #0 8394: ebffff6d bl 8150 node = pathloc->node_access; if ( result == -1 ) 8398: e3700001 cmn r0, #1 } else if ( node->type == IMFS_SYM_LINK ) { result = IMFS_evaluate_sym_link( pathloc, 0 ); node = pathloc->node_access; 839c: e5945000 ldr r5, [r4] if ( result == -1 ) 83a0: 0a00003d beq 849c /* * Only a directory can be decended into. */ if ( node->type != IMFS_DIRECTORY ) 83a4: e595304c ldr r3, [r5, #76] ; 0x4c 83a8: e3530001 cmp r3, #1 83ac: 0a000002 beq 83bc rtems_set_errno_and_return_minus_one( ENOTDIR ); 83b0: eb000de6 bl bb50 <__errno> 83b4: e3a03014 mov r3, #20 83b8: ea00003b b 84ac /* * If we are at a node that is a mount point. Set loc to the * new fs root node and let them finish evaluating the path. */ if ( node->info.directory.mt_fs != NULL ) { 83bc: e595e05c ldr lr, [r5, #92] ; 0x5c 83c0: e35e0000 cmp lr, #0 83c4: 1a000015 bne 8420 /* * Otherwise find the token name in the present location. */ node = IMFS_find_match_in_dir( node, token ); 83c8: e1a00005 mov r0, r5 83cc: e1a0100a mov r1, sl 83d0: eb00017f bl 89d4 if ( !node ) 83d4: e2505000 subs r5, r0, #0 83d8: 1a000002 bne 83e8 rtems_set_errno_and_return_minus_one( ENOENT ); 83dc: eb000ddb bl bb50 <__errno> 83e0: e3a03002 mov r3, #2 83e4: ea000030 b 84ac /* * Set the node access to the point we have found. */ pathloc->node_access = node; 83e8: e5845000 str r5, [r4] 83ec: ea000002 b 83fc case IMFS_NO_MORE_PATH: case IMFS_CURRENT_DIR: break; case IMFS_INVALID_TOKEN: rtems_set_errno_and_return_minus_one( ENAMETOOLONG ); 83f0: eb000dd6 bl bb50 <__errno> 83f4: e3a0305b mov r3, #91 ; 0x5b 83f8: ea00002b b 84ac /* * Evaluate all tokens until we are done or an error occurs. */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { 83fc: e35b0004 cmp fp, #4 8400: 135b0000 cmpne fp, #0 8404: 1affff9a bne 8274 * new fs root node and let let the mounted filesystem set the handlers. * * NOTE: The behavior of stat() on a mount point appears to be questionable. */ if ( node->type == IMFS_DIRECTORY ) { 8408: e595304c ldr r3, [r5, #76] ; 0x4c 840c: e3530001 cmp r3, #1 8410: 1a000018 bne 8478 if ( node->info.directory.mt_fs != NULL ) { 8414: e595e05c ldr lr, [r5, #92] ; 0x5c 8418: e35e0000 cmp lr, #0 841c: 0a000015 beq 8478 newloc = node->info.directory.mt_fs->mt_fs_root; 8420: e28ee01c add lr, lr, #28 8424: e8be000f ldm lr!, {r0, r1, r2, r3} 8428: e28dc02c add ip, sp, #44 ; 0x2c 842c: e8ac000f stmia ip!, {r0, r1, r2, r3} *pathloc = newloc; 8430: e28d502c add r5, sp, #44 ; 0x2c 8434: e8b5000f ldm r5!, {r0, r1, r2, r3} 8438: e1a05004 mov r5, r4 * NOTE: The behavior of stat() on a mount point appears to be questionable. */ if ( node->type == IMFS_DIRECTORY ) { if ( node->info.directory.mt_fs != NULL ) { newloc = node->info.directory.mt_fs->mt_fs_root; 843c: e59ee000 ldr lr, [lr] *pathloc = newloc; 8440: e8a5000f stmia r5!, {r0, r1, r2, r3} return (*pathloc->ops->evalpath_h)( &pathname[i-len], 8444: e59d1040 ldr r1, [sp, #64] ; 0x40 8448: e59d8000 ldr r8, [sp] 844c: e0610007 rsb r0, r1, r7 */ if ( node->type == IMFS_DIRECTORY ) { if ( node->info.directory.mt_fs != NULL ) { newloc = node->info.directory.mt_fs->mt_fs_root; *pathloc = newloc; 8450: e585e000 str lr, [r5] * NOTE: The behavior of stat() on a mount point appears to be questionable. */ if ( node->type == IMFS_DIRECTORY ) { if ( node->info.directory.mt_fs != NULL ) { newloc = node->info.directory.mt_fs->mt_fs_root; 8454: e58ce000 str lr, [ip] *pathloc = newloc; return (*pathloc->ops->evalpath_h)( &pathname[i-len], 8458: e0880000 add r0, r8, r0 845c: e0861001 add r1, r6, r1 8460: e59d2004 ldr r2, [sp, #4] 8464: e1a03004 mov r3, r4 8468: e594c00c ldr ip, [r4, #12] 846c: e1a0e00f mov lr, pc 8470: e59cf000 ldr pc, [ip] 8474: ea000008 b 849c flags, pathloc ); } else { result = IMFS_Set_handlers( pathloc ); } } else { result = IMFS_Set_handlers( pathloc ); 8478: e1a00004 mov r0, r4 847c: ebfffef4 bl 8054 if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access; 8480: e5943000 ldr r3, [r4] /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test ) 8484: e59d1004 ldr r1, [sp, #4] if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access; 8488: e5932030 ldr r2, [r3, #48] ; 0x30 /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test ) 848c: e1a03301 lsl r3, r1, #6 if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access; 8490: e0032002 and r2, r3, r2 8494: e1520003 cmp r2, r3 8498: 1a000001 bne 84a4 if ( !IMFS_evaluate_permission( pathloc, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); return result; } 849c: e28dd044 add sp, sp, #68 ; 0x44 84a0: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} /* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( pathloc, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); 84a4: eb000da9 bl bb50 <__errno> 84a8: e3a0300d mov r3, #13 84ac: e5803000 str r3, [r0] 84b0: e3e00000 mvn r0, #0 84b4: eafffff8 b 849c 84b8: 00017718 .word 0x00017718 00008570 : int IMFS_evaluate_for_make( const char *path, /* IN */ rtems_filesystem_location_info_t *pathloc, /* IN/OUT */ const char **name /* OUT */ ) { 8570: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8574: e24dd040 sub sp, sp, #64 ; 0x40 8578: e1a04001 mov r4, r1 /* * This was filled in by the caller and is valid in the * mount table. */ node = pathloc->node_access; 857c: e5916000 ldr r6, [r1] int IMFS_evaluate_for_make( const char *path, /* IN */ rtems_filesystem_location_info_t *pathloc, /* IN/OUT */ const char **name /* OUT */ ) { 8580: e58d2000 str r2, [sp] 8584: e1a07000 mov r7, r0 node = pathloc->node_access; /* * Get the path length. */ pathlen = strlen( path ); 8588: eb001161 bl cb14 case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access ) 858c: e59f9238 ldr r9, [pc, #568] ; 87cc node = pathloc->node_access; /* * Get the path length. */ pathlen = strlen( path ); 8590: e3a05000 mov r5, #0 * Evaluate all tokens until we are done or an error occurs. */ while( !done ) { type = IMFS_get_token( &path[i], pathlen, token, &len ); 8594: e28db004 add fp, sp, #4 node = pathloc->node_access; /* * Get the path length. */ pathlen = strlen( path ); 8598: e1a08000 mov r8, r0 * Evaluate all tokens until we are done or an error occurs. */ while( !done ) { type = IMFS_get_token( &path[i], pathlen, token, &len ); 859c: e1a01008 mov r1, r8 85a0: e28d303c add r3, sp, #60 ; 0x3c 85a4: e0870005 add r0, r7, r5 85a8: e1a0200b mov r2, fp 85ac: eb000130 bl 8a74 pathlen -= len; i += len; if ( !pathloc->node_access ) 85b0: e5943000 ldr r3, [r4] */ while( !done ) { type = IMFS_get_token( &path[i], pathlen, token, &len ); pathlen -= len; 85b4: e59da03c ldr sl, [sp, #60] ; 0x3c i += len; if ( !pathloc->node_access ) 85b8: e3530000 cmp r3, #0 */ while( !done ) { type = IMFS_get_token( &path[i], pathlen, token, &len ); pathlen -= len; 85bc: e06a8008 rsb r8, sl, r8 i += len; if ( !pathloc->node_access ) 85c0: 0a000067 beq 8764 /* * I cannot move out of this directory without execute permission. */ if ( type != IMFS_NO_MORE_PATH ) 85c4: e3500000 cmp r0, #0 85c8: 0a000005 beq 85e4 if ( node->type == IMFS_DIRECTORY ) 85cc: e596204c ldr r2, [r6, #76] ; 0x4c 85d0: e3520001 cmp r2, #1 85d4: 1a000002 bne 85e4 /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test ) 85d8: e5932030 ldr r2, [r3, #48] ; 0x30 85dc: e3120040 tst r2, #64 ; 0x40 85e0: 0a000074 beq 87b8 while( !done ) { type = IMFS_get_token( &path[i], pathlen, token, &len ); pathlen -= len; i += len; 85e4: e085500a add r5, r5, sl if ( type != IMFS_NO_MORE_PATH ) if ( node->type == IMFS_DIRECTORY ) if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) ) rtems_set_errno_and_return_minus_one( EACCES ); node = pathloc->node_access; 85e8: e1a06003 mov r6, r3 switch( type ) { 85ec: e3500004 cmp r0, #4 85f0: 979ff100 ldrls pc, [pc, r0, lsl #2] 85f4: eaffffe8 b 859c <== NOT EXECUTED 85f8: 00008720 .word 0x00008720 <== NOT EXECUTED 85fc: 0000859c .word 0x0000859c <== NOT EXECUTED 8600: 0000860c .word 0x0000860c <== NOT EXECUTED 8604: 0000866c .word 0x0000866c <== NOT EXECUTED 8608: 0000872c .word 0x0000872c <== NOT EXECUTED case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access ) 860c: e5992000 ldr r2, [r9] 8610: e5922018 ldr r2, [r2, #24] 8614: e1530002 cmp r3, r2 8618: 0affffdf beq 859c /* * Am I at the root of this mounted filesystem? */ if (pathloc->node_access == pathloc->mt_entry->mt_fs_root.node_access){ 861c: e594e010 ldr lr, [r4, #16] 8620: e59e201c ldr r2, [lr, #28] 8624: e1530002 cmp r3, r2 8628: 1a00000b bne 865c if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; } else { newloc = pathloc->mt_entry->mt_point_node; 862c: e28ee008 add lr, lr, #8 8630: e8be000f ldm lr!, {r0, r1, r2, r3} 8634: e28dc028 add ip, sp, #40 ; 0x28 8638: e8ac000f stmia ip!, {r0, r1, r2, r3} *pathloc = newloc; 863c: e28d6028 add r6, sp, #40 ; 0x28 8640: e8b6000f ldm r6!, {r0, r1, r2, r3} 8644: e1a06004 mov r6, r4 if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; } else { newloc = pathloc->mt_entry->mt_point_node; 8648: e59ee000 ldr lr, [lr] *pathloc = newloc; 864c: e8a6000f stmia r6!, {r0, r1, r2, r3} return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name ); 8650: e06a5005 rsb r5, sl, r5 if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; } else { newloc = pathloc->mt_entry->mt_point_node; *pathloc = newloc; 8654: e586e000 str lr, [r6] 8658: ea000022 b 86e8 return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name ); } } else { if ( !node->Parent ) 865c: e5936008 ldr r6, [r3, #8] 8660: e3560000 cmp r6, #0 8664: 1a00002b bne 8718 8668: ea00003d b 8764 pathloc->node_access = node; break; case IMFS_NAME: if ( node->type == IMFS_HARD_LINK ) { 866c: e593304c ldr r3, [r3, #76] ; 0x4c 8670: e3530003 cmp r3, #3 8674: 0a000001 beq 8680 result = IMFS_evaluate_link( pathloc, 0 ); if ( result == -1 ) return -1; } else if ( node->type == IMFS_SYM_LINK ) { 8678: e3530004 cmp r3, #4 867c: 1a000004 bne 8694 result = IMFS_evaluate_link( pathloc, 0 ); 8680: e1a00004 mov r0, r4 8684: e3a01000 mov r1, #0 8688: ebffff8b bl 84bc if ( result == -1 ) 868c: e3700001 cmn r0, #1 8690: 0a000046 beq 87b0 return -1; } node = pathloc->node_access; 8694: e5940000 ldr r0, [r4] if ( !node ) 8698: e3500000 cmp r0, #0 869c: 0a00003c beq 8794 /* * Only a directory can be decended into. */ if ( node->type != IMFS_DIRECTORY ) 86a0: e590304c ldr r3, [r0, #76] ; 0x4c 86a4: e3530001 cmp r3, #1 86a8: 1a000039 bne 8794 /* * If we are at a node that is a mount point. Set loc to the * new fs root node and let them finish evaluating the path. */ if ( node->info.directory.mt_fs != NULL ) { 86ac: e590e05c ldr lr, [r0, #92] ; 0x5c 86b0: e35e0000 cmp lr, #0 86b4: 0a000013 beq 8708 newloc = node->info.directory.mt_fs->mt_fs_root; 86b8: e28ee01c add lr, lr, #28 86bc: e8be000f ldm lr!, {r0, r1, r2, r3} 86c0: e28dc028 add ip, sp, #40 ; 0x28 86c4: e8ac000f stmia ip!, {r0, r1, r2, r3} *pathloc = newloc; 86c8: e28d6028 add r6, sp, #40 ; 0x28 86cc: e8b6000f ldm r6!, {r0, r1, r2, r3} 86d0: e1a06004 mov r6, r4 * If we are at a node that is a mount point. Set loc to the * new fs root node and let them finish evaluating the path. */ if ( node->info.directory.mt_fs != NULL ) { newloc = node->info.directory.mt_fs->mt_fs_root; 86d4: e59ee000 ldr lr, [lr] *pathloc = newloc; 86d8: e8a6000f stmia r6!, {r0, r1, r2, r3} return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name ); 86dc: e59d303c ldr r3, [sp, #60] ; 0x3c * new fs root node and let them finish evaluating the path. */ if ( node->info.directory.mt_fs != NULL ) { newloc = node->info.directory.mt_fs->mt_fs_root; *pathloc = newloc; 86e0: e586e000 str lr, [r6] return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name ); 86e4: e0635005 rsb r5, r3, r5 * If we are at a node that is a mount point. Set loc to the * new fs root node and let them finish evaluating the path. */ if ( node->info.directory.mt_fs != NULL ) { newloc = node->info.directory.mt_fs->mt_fs_root; 86e8: e58ce000 str lr, [ip] *pathloc = newloc; return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name ); 86ec: e0870005 add r0, r7, r5 86f0: e1a01004 mov r1, r4 86f4: e59d2000 ldr r2, [sp] 86f8: e594300c ldr r3, [r4, #12] 86fc: e1a0e00f mov lr, pc 8700: e593f004 ldr pc, [r3, #4] 8704: ea000029 b 87b0 /* * Otherwise find the token name in the present location. */ node = IMFS_find_match_in_dir( node, token ); 8708: e1a0100b mov r1, fp 870c: eb0000b0 bl 89d4 /* * If there is no node we have found the name of the node we * wish to create. */ if ( ! node ) 8710: e2506000 subs r6, r0, #0 8714: 0a000007 beq 8738 done = true; else pathloc->node_access = node; 8718: e5846000 str r6, [r4] 871c: eaffff9e b 859c break; case IMFS_NO_MORE_PATH: rtems_set_errno_and_return_minus_one( EEXIST ); 8720: eb000d0a bl bb50 <__errno> 8724: e3a03011 mov r3, #17 8728: ea000024 b 87c0 break; case IMFS_INVALID_TOKEN: rtems_set_errno_and_return_minus_one( ENAMETOOLONG ); 872c: eb000d07 bl bb50 <__errno> 8730: e3a0305b mov r3, #91 ; 0x5b 8734: ea000021 b 87c0 case IMFS_CURRENT_DIR: break; } } *name = &path[ i - len ]; 8738: e59d303c ldr r3, [sp, #60] ; 0x3c 873c: e59d2000 ldr r2, [sp] 8740: e0633005 rsb r3, r3, r5 8744: e0873003 add r3, r7, r3 8748: e5823000 str r3, [r2] 874c: e0875005 add r5, r7, r5 /* * We have evaluated the path as far as we can. * Verify there is not any invalid stuff at the end of the name. */ for( ; path[i] != '\0'; i++) { 8750: ea000006 b 8770 if ( !IMFS_is_separator( path[ i ] ) ) 8754: e353005c cmp r3, #92 ; 0x5c 8758: 1353002f cmpne r3, #47 ; 0x2f /* * We have evaluated the path as far as we can. * Verify there is not any invalid stuff at the end of the name. */ for( ; path[i] != '\0'; i++) { 875c: e2855001 add r5, r5, #1 if ( !IMFS_is_separator( path[ i ] ) ) 8760: 0a000002 beq 8770 rtems_set_errno_and_return_minus_one( ENOENT ); 8764: eb000cf9 bl bb50 <__errno> 8768: e3a03002 mov r3, #2 876c: ea000013 b 87c0 /* * We have evaluated the path as far as we can. * Verify there is not any invalid stuff at the end of the name. */ for( ; path[i] != '\0'; i++) { 8770: e5d53000 ldrb r3, [r5] 8774: e3530000 cmp r3, #0 8778: 1afffff5 bne 8754 /* * Verify we can execute and write to this directory. */ result = IMFS_Set_handlers( pathloc ); 877c: e1a00004 mov r0, r4 8780: ebfffe33 bl 8054 /* * The returned node must be a directory */ node = pathloc->node_access; 8784: e5943000 ldr r3, [r4] if ( node->type != IMFS_DIRECTORY ) 8788: e593204c ldr r2, [r3, #76] ; 0x4c 878c: e3520001 cmp r2, #1 8790: 0a000002 beq 87a0 rtems_set_errno_and_return_minus_one( ENOTDIR ); 8794: eb000ced bl bb50 <__errno> 8798: e3a03014 mov r3, #20 879c: ea000007 b 87c0 /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test ) 87a0: e5933030 ldr r3, [r3, #48] ; 0x30 87a4: e20330c0 and r3, r3, #192 ; 0xc0 87a8: e35300c0 cmp r3, #192 ; 0xc0 87ac: 1a000001 bne 87b8 if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_WX ) ) rtems_set_errno_and_return_minus_one( EACCES ); return result; } 87b0: e28dd040 add sp, sp, #64 ; 0x40 87b4: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} */ if ( type != IMFS_NO_MORE_PATH ) if ( node->type == IMFS_DIRECTORY ) if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) ) rtems_set_errno_and_return_minus_one( EACCES ); 87b8: eb000ce4 bl bb50 <__errno> 87bc: e3a0300d mov r3, #13 87c0: e5803000 str r3, [r0] 87c4: e3e00000 mvn r0, #0 87c8: eafffff8 b 87b0 87cc: 00017718 .word 0x00017718 000080ec : int IMFS_evaluate_hard_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) { IMFS_jnode_t *jnode = node->node_access; 80ec: e5903000 ldr r3, [r0] /* * Check for things that should never happen. */ if ( jnode->type != IMFS_HARD_LINK ) 80f0: e593204c ldr r2, [r3, #76] ; 0x4c 80f4: e3520003 cmp r2, #3 int IMFS_evaluate_hard_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) { 80f8: e92d4030 push {r4, r5, lr} 80fc: e1a04000 mov r4, r0 8100: e1a05001 mov r5, r1 /* * Check for things that should never happen. */ if ( jnode->type != IMFS_HARD_LINK ) rtems_fatal_error_occurred (0xABCD0000); 8104: 159f0040 ldrne r0, [pc, #64] ; 814c 8108: 1bfff3e9 blne 50b4 /* * Set the hard link value and the handlers. */ node->node_access = jnode->info.hard_link.link_node; 810c: e5933050 ldr r3, [r3, #80] ; 0x50 8110: e5803000 str r3, [r0] IMFS_Set_handlers( node ); 8114: ebffffce bl 8054 if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access; 8118: e5943000 ldr r3, [r4] 811c: e5933030 ldr r3, [r3, #48] ; 0x30 /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test ) 8120: e1a05305 lsl r5, r5, #6 if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access; 8124: e0053003 and r3, r5, r3 8128: e1530005 cmp r3, r5 812c: 1a000001 bne 8138 8130: e3a00000 mov r0, #0 if ( !IMFS_evaluate_permission( node, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); return result; } 8134: e8bd8030 pop {r4, r5, pc} /* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( node, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); 8138: eb000e84 bl bb50 <__errno> <== NOT EXECUTED 813c: e3a0300d mov r3, #13 <== NOT EXECUTED 8140: e5803000 str r3, [r0] <== NOT EXECUTED 8144: e3e00000 mvn r0, #0 <== NOT EXECUTED 8148: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED 814c: abcd0000 .word 0xabcd0000 000080cc : /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test ) 80cc: e5903000 ldr r3, [r0] <== NOT EXECUTED 80d0: e5933030 ldr r3, [r3, #48] ; 0x30 <== NOT EXECUTED 80d4: e1a01301 lsl r1, r1, #6 <== NOT EXECUTED 80d8: e0013003 and r3, r1, r3 <== NOT EXECUTED return 1; return 0; } 80dc: e1530001 cmp r3, r1 <== NOT EXECUTED 80e0: 13a00000 movne r0, #0 <== NOT EXECUTED 80e4: 03a00001 moveq r0, #1 <== NOT EXECUTED 80e8: e12fff1e bx lr <== NOT EXECUTED 00008150 : int IMFS_evaluate_sym_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) { 8150: e92d4070 push {r4, r5, r6, lr} IMFS_jnode_t *jnode = node->node_access; 8154: e590e000 ldr lr, [r0] /* * Check for things that should never happen. */ if ( jnode->type != IMFS_SYM_LINK ) 8158: e59e304c ldr r3, [lr, #76] ; 0x4c 815c: e3530004 cmp r3, #4 int IMFS_evaluate_sym_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) { 8160: e1a04000 mov r4, r0 8164: e1a05001 mov r5, r1 /* * Check for things that should never happen. */ if ( jnode->type != IMFS_SYM_LINK ) rtems_fatal_error_occurred (0xABCD0000); 8168: 159f00c4 ldrne r0, [pc, #196] ; 8234 /* * Check for things that should never happen. */ if ( jnode->type != IMFS_SYM_LINK ) 816c: 1a000003 bne 8180 rtems_fatal_error_occurred (0xABCD0000); if ( !jnode->Parent ) 8170: e59e3008 ldr r3, [lr, #8] 8174: e3530000 cmp r3, #0 8178: 1a000001 bne 8184 rtems_fatal_error_occurred( 0xBAD00000 ); 817c: e59f00b4 ldr r0, [pc, #180] ; 8238 <== NOT EXECUTED 8180: ebfff3cb bl 50b4 <== NOT EXECUTED /* * Move the node_access to either the symbolic links parent or * root depending on the symbolic links path. */ node->node_access = jnode->Parent; 8184: e5843000 str r3, [r4] rtems_filesystem_get_sym_start_loc( 8188: e59e3050 ldr r3, [lr, #80] ; 0x50 818c: e5d33000 ldrb r3, [r3] 8190: e353002f cmp r3, #47 ; 0x2f 8194: 1353005c cmpne r3, #92 ; 0x5c 8198: 13a06000 movne r6, #0 819c: 03a06001 moveq r6, #1 81a0: 0a000001 beq 81ac 81a4: e3530000 cmp r3, #0 81a8: 1a000008 bne 81d0 81ac: e59f3088 ldr r3, [pc, #136] ; 823c 81b0: e593c000 ldr ip, [r3] 81b4: e28cc018 add ip, ip, #24 81b8: e8bc000f ldm ip!, {r0, r1, r2, r3} 81bc: e1a06004 mov r6, r4 81c0: e8a6000f stmia r6!, {r0, r1, r2, r3} 81c4: e59c2000 ldr r2, [ip] 81c8: e5862000 str r2, [r6] 81cc: e3a06001 mov r6, #1 * Use eval path to evaluate the path of the symbolic link. */ result = IMFS_eval_path( &jnode->info.sym_link.name[i], strlen( &jnode->info.sym_link.name[i] ), 81d0: e59e3050 ldr r3, [lr, #80] ; 0x50 81d4: e0836006 add r6, r3, r6 81d8: e1a00006 mov r0, r6 81dc: eb00124c bl cb14 /* * Use eval path to evaluate the path of the symbolic link. */ result = IMFS_eval_path( 81e0: e1a02005 mov r2, r5 &jnode->info.sym_link.name[i], strlen( &jnode->info.sym_link.name[i] ), 81e4: e1a01000 mov r1, r0 /* * Use eval path to evaluate the path of the symbolic link. */ result = IMFS_eval_path( 81e8: e1a03004 mov r3, r4 81ec: e1a00006 mov r0, r6 81f0: eb000012 bl 8240 81f4: e1a06000 mov r6, r0 strlen( &jnode->info.sym_link.name[i] ), flags, node ); IMFS_Set_handlers( node ); 81f8: e1a00004 mov r0, r4 81fc: ebffff94 bl 8054 if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access; 8200: e5943000 ldr r3, [r4] 8204: e5933030 ldr r3, [r3, #48] ; 0x30 /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test ) 8208: e1a05305 lsl r5, r5, #6 if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access; 820c: e0053003 and r3, r5, r3 8210: e1530005 cmp r3, r5 8214: 1a000001 bne 8220 if ( !IMFS_evaluate_permission( node, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); return result; } 8218: e1a00006 mov r0, r6 821c: e8bd8070 pop {r4, r5, r6, pc} /* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( node, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); 8220: eb000e4a bl bb50 <__errno> <== NOT EXECUTED 8224: e3a0300d mov r3, #13 <== NOT EXECUTED 8228: e5803000 str r3, [r0] <== NOT EXECUTED 822c: e3e06000 mvn r6, #0 <== NOT EXECUTED 8230: eafffff8 b 8218 <== NOT EXECUTED 8234: abcd0000 .word 0xabcd0000 8238: bad00000 .word 0xbad00000 823c: 00017718 .word 0x00017718 00008930 : } int IMFS_fifo_close( rtems_libio_t *iop ) { 8930: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED IMFS_jnode_t *jnode = iop->file_info; 8934: e5904038 ldr r4, [r0, #56] ; 0x38 <== NOT EXECUTED int err = pipe_release(&JNODE2PIPE(jnode), iop); 8938: e1a01000 mov r1, r0 <== NOT EXECUTED } int IMFS_fifo_close( rtems_libio_t *iop ) { 893c: e1a05000 mov r5, r0 <== NOT EXECUTED IMFS_jnode_t *jnode = iop->file_info; int err = pipe_release(&JNODE2PIPE(jnode), iop); 8940: e2840050 add r0, r4, #80 ; 0x50 <== NOT EXECUTED 8944: eb0007c7 bl a868 <== NOT EXECUTED if (! err) { 8948: e2506000 subs r6, r0, #0 <== NOT EXECUTED 894c: 1a00000c bne 8984 <== NOT EXECUTED iop->flags &= ~LIBIO_FLAGS_OPEN; 8950: e5953014 ldr r3, [r5, #20] <== NOT EXECUTED 8954: e3c33c01 bic r3, r3, #256 ; 0x100 <== NOT EXECUTED 8958: e5853014 str r3, [r5, #20] <== NOT EXECUTED /* Free jnode if file is already unlinked and no one opens it */ if (! rtems_libio_is_file_open(jnode) && jnode->st_nlink < 1) 895c: e1a00004 mov r0, r4 <== NOT EXECUTED 8960: eb0001f3 bl 9134 <== NOT EXECUTED 8964: e3500000 cmp r0, #0 <== NOT EXECUTED 8968: 1a00000a bne 8998 <== NOT EXECUTED 896c: e1d433b4 ldrh r3, [r4, #52] ; 0x34 <== NOT EXECUTED 8970: e3530000 cmp r3, #0 <== NOT EXECUTED 8974: 1a000007 bne 8998 <== NOT EXECUTED free(jnode); 8978: e1a00004 mov r0, r4 <== NOT EXECUTED 897c: ebffe3f1 bl 1948 <== NOT EXECUTED 8980: ea000004 b 8998 <== NOT EXECUTED } IMFS_FIFO_RETURN(err); 8984: aa000003 bge 8998 <== NOT EXECUTED 8988: eb000c70 bl bb50 <__errno> <== NOT EXECUTED 898c: e2666000 rsb r6, r6, #0 <== NOT EXECUTED 8990: e5806000 str r6, [r0] <== NOT EXECUTED 8994: e3e06000 mvn r6, #0 <== NOT EXECUTED } 8998: e1a00006 mov r0, r6 <== NOT EXECUTED 899c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED 00008818 : void *buffer ) { int err; if (command == FIONBIO) { 8818: e59f3068 ldr r3, [pc, #104] ; 8888 <== NOT EXECUTED 881c: e1510003 cmp r1, r3 <== NOT EXECUTED int IMFS_fifo_ioctl( rtems_libio_t *iop, uint32_t command, void *buffer ) { 8820: e92d4010 push {r4, lr} <== NOT EXECUTED 8824: e1a03000 mov r3, r0 <== NOT EXECUTED int err; if (command == FIONBIO) { 8828: 1a00000b bne 885c <== NOT EXECUTED if (buffer == NULL) 882c: e3520000 cmp r2, #0 <== NOT EXECUTED 8830: 03e0400d mvneq r4, #13 <== NOT EXECUTED 8834: 0a00000d beq 8870 <== NOT EXECUTED err = -EFAULT; else { if (*(int *)buffer) 8838: e5924000 ldr r4, [r2] <== NOT EXECUTED 883c: e5932014 ldr r2, [r3, #20] <== NOT EXECUTED 8840: e3540000 cmp r4, #0 <== NOT EXECUTED iop->flags |= LIBIO_FLAGS_NO_DELAY; 8844: 13822001 orrne r2, r2, #1 <== NOT EXECUTED else iop->flags &= ~LIBIO_FLAGS_NO_DELAY; 8848: 03c22001 biceq r2, r2, #1 <== NOT EXECUTED if (command == FIONBIO) { if (buffer == NULL) err = -EFAULT; else { if (*(int *)buffer) iop->flags |= LIBIO_FLAGS_NO_DELAY; 884c: 15832014 strne r2, [r3, #20] <== NOT EXECUTED 8850: 13a04000 movne r4, #0 <== NOT EXECUTED else iop->flags &= ~LIBIO_FLAGS_NO_DELAY; 8854: 05832014 streq r2, [r3, #20] <== NOT EXECUTED 8858: ea000008 b 8880 <== NOT EXECUTED return 0; } } else err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop); 885c: e5930038 ldr r0, [r3, #56] ; 0x38 <== NOT EXECUTED 8860: e5900050 ldr r0, [r0, #80] ; 0x50 <== NOT EXECUTED 8864: eb00071a bl a4d4 <== NOT EXECUTED IMFS_FIFO_RETURN(err); 8868: e2504000 subs r4, r0, #0 <== NOT EXECUTED 886c: aa000003 bge 8880 <== NOT EXECUTED 8870: eb000cb6 bl bb50 <__errno> <== NOT EXECUTED 8874: e2644000 rsb r4, r4, #0 <== NOT EXECUTED 8878: e5804000 str r4, [r0] <== NOT EXECUTED 887c: e3e04000 mvn r4, #0 <== NOT EXECUTED } 8880: e1a00004 mov r0, r4 <== NOT EXECUTED 8884: e8bd8010 pop {r4, pc} <== NOT EXECUTED 8888: 8004667e .word 0x8004667e 000087d0 : rtems_off64_t IMFS_fifo_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) { 87d0: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED off_t err = pipe_lseek(LIBIO2PIPE(iop), offset, whence, iop); 87d4: e58d0000 str r0, [sp] <== NOT EXECUTED 87d8: e5900038 ldr r0, [r0, #56] ; 0x38 <== NOT EXECUTED 87dc: e5900050 ldr r0, [r0, #80] ; 0x50 <== NOT EXECUTED 87e0: eb000721 bl a46c <== NOT EXECUTED 87e4: e1a03000 mov r3, r0 <== NOT EXECUTED 87e8: e1a04fc3 asr r4, r3, #31 <== NOT EXECUTED IMFS_FIFO_RETURN(err); 87ec: e3540000 cmp r4, #0 <== NOT EXECUTED rtems_libio_t *iop, rtems_off64_t offset, int whence ) { off_t err = pipe_lseek(LIBIO2PIPE(iop), offset, whence, iop); 87f0: e1a05000 mov r5, r0 <== NOT EXECUTED IMFS_FIFO_RETURN(err); 87f4: aa000004 bge 880c <== NOT EXECUTED 87f8: eb000cd4 bl bb50 <__errno> <== NOT EXECUTED 87fc: e2655000 rsb r5, r5, #0 <== NOT EXECUTED 8800: e5805000 str r5, [r0] <== NOT EXECUTED 8804: e3e03000 mvn r3, #0 <== NOT EXECUTED 8808: e3e04000 mvn r4, #0 <== NOT EXECUTED } 880c: e1a01004 mov r1, r4 <== NOT EXECUTED 8810: e1a00003 mov r0, r3 <== NOT EXECUTED 8814: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED 000088e0 : ssize_t IMFS_fifo_read( rtems_libio_t *iop, void *buffer, size_t count ) { 88e0: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED IMFS_jnode_t *jnode = iop->file_info; 88e4: e5904038 ldr r4, [r0, #56] ; 0x38 <== NOT EXECUTED ssize_t IMFS_fifo_read( rtems_libio_t *iop, void *buffer, size_t count ) { 88e8: e1a03000 mov r3, r0 <== NOT EXECUTED IMFS_jnode_t *jnode = iop->file_info; int err = pipe_read(JNODE2PIPE(jnode), buffer, count, iop); 88ec: e5940050 ldr r0, [r4, #80] ; 0x50 <== NOT EXECUTED 88f0: eb000773 bl a6c4 <== NOT EXECUTED if (err > 0) 88f4: e2505000 subs r5, r0, #0 <== NOT EXECUTED 88f8: da000005 ble 8914 <== NOT EXECUTED IMFS_update_atime(jnode); 88fc: e1a0000d mov r0, sp <== NOT EXECUTED 8900: e3a01000 mov r1, #0 <== NOT EXECUTED 8904: eb0001d6 bl 9064 <== NOT EXECUTED 8908: e59d3000 ldr r3, [sp] <== NOT EXECUTED 890c: e5843040 str r3, [r4, #64] ; 0x40 <== NOT EXECUTED 8910: ea000004 b 8928 <== NOT EXECUTED IMFS_FIFO_RETURN(err); 8914: 0a000003 beq 8928 <== NOT EXECUTED 8918: eb000c8c bl bb50 <__errno> <== NOT EXECUTED 891c: e2655000 rsb r5, r5, #0 <== NOT EXECUTED 8920: e5805000 str r5, [r0] <== NOT EXECUTED 8924: e3e05000 mvn r5, #0 <== NOT EXECUTED } 8928: e1a00005 mov r0, r5 <== NOT EXECUTED 892c: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED 0000888c : ssize_t IMFS_fifo_write( rtems_libio_t *iop, const void *buffer, size_t count ) { 888c: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED IMFS_jnode_t *jnode = iop->file_info; 8890: e5904038 ldr r4, [r0, #56] ; 0x38 <== NOT EXECUTED ssize_t IMFS_fifo_write( rtems_libio_t *iop, const void *buffer, size_t count ) { 8894: e1a03000 mov r3, r0 <== NOT EXECUTED IMFS_jnode_t *jnode = iop->file_info; int err = pipe_write(JNODE2PIPE(jnode), buffer, count, iop); 8898: e5940050 ldr r0, [r4, #80] ; 0x50 <== NOT EXECUTED 889c: eb000724 bl a534 <== NOT EXECUTED if (err > 0) { 88a0: e2505000 subs r5, r0, #0 <== NOT EXECUTED 88a4: da000006 ble 88c4 <== NOT EXECUTED IMFS_mtime_ctime_update(jnode); 88a8: e1a0000d mov r0, sp <== NOT EXECUTED 88ac: e3a01000 mov r1, #0 <== NOT EXECUTED 88b0: eb0001eb bl 9064 <== NOT EXECUTED 88b4: e59d3000 ldr r3, [sp] <== NOT EXECUTED 88b8: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED 88bc: e5843044 str r3, [r4, #68] ; 0x44 <== NOT EXECUTED 88c0: ea000004 b 88d8 <== NOT EXECUTED } IMFS_FIFO_RETURN(err); 88c4: 0a000003 beq 88d8 <== NOT EXECUTED 88c8: eb000ca0 bl bb50 <__errno> <== NOT EXECUTED 88cc: e2655000 rsb r5, r5, #0 <== NOT EXECUTED 88d0: e5805000 str r5, [r0] <== NOT EXECUTED 88d4: e3e05000 mvn r5, #0 <== NOT EXECUTED } 88d8: e1a00005 mov r0, r5 <== NOT EXECUTED 88dc: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED 0000d500 : ((IMFS_jnode_t *)( rtems_chain_head( jnode_get_control( jnode ) )->next)) int IMFS_fsunmount( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) { d500: e92d4070 push {r4, r5, r6, lr} /* * Traverse tree that starts at the mt_fs_root and deallocate memory * associated memory space */ jnode = (IMFS_jnode_t *)temp_mt_entry->mt_fs_root.node_access; d504: e1a0c000 mov ip, r0 d508: e5bc401c ldr r4, [ip, #28]! ((IMFS_jnode_t *)( rtems_chain_head( jnode_get_control( jnode ) )->next)) int IMFS_fsunmount( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) { d50c: e1a05000 mov r5, r0 d510: e24dd014 sub sp, sp, #20 * Traverse tree that starts at the mt_fs_root and deallocate memory * associated memory space */ jnode = (IMFS_jnode_t *)temp_mt_entry->mt_fs_root.node_access; loc = temp_mt_entry->mt_fs_root; d514: e8bc000f ldm ip!, {r0, r1, r2, r3} d518: e1a0e00d mov lr, sp d51c: e8ae000f stmia lr!, {r0, r1, r2, r3} d520: e59c3000 ldr r3, [ip] d524: e58e3000 str r3, [lr] /* * Set this to null to indicate that it is being unmounted. */ temp_mt_entry->mt_fs_root.node_access = NULL; d528: e3a03000 mov r3, #0 d52c: e585301c str r3, [r5, #28] do { next = jnode->Parent; loc.node_access = (void *)jnode; IMFS_Set_handlers( &loc ); d530: e1a0500d mov r5, sp d534: e1a0000d mov r0, sp temp_mt_entry->mt_fs_root.node_access = NULL; do { next = jnode->Parent; loc.node_access = (void *)jnode; d538: e58d4000 str r4, [sp] */ temp_mt_entry->mt_fs_root.node_access = NULL; do { next = jnode->Parent; d53c: e5946008 ldr r6, [r4, #8] loc.node_access = (void *)jnode; IMFS_Set_handlers( &loc ); d540: ebfffd8c bl cb78 if ( jnode->type != IMFS_DIRECTORY ) { d544: e594204c ldr r2, [r4, #76] ; 0x4c d548: e3520001 cmp r2, #1 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; d54c: e2843054 add r3, r4, #84 ; 0x54 d550: 1a000002 bne d560 d554: e5942050 ldr r2, [r4, #80] ; 0x50 d558: e1520003 cmp r2, r3 d55c: 1a000005 bne d578 result = IMFS_unlink( NULL, &loc ); if (result != 0) return -1; jnode = next; } else if ( jnode_has_no_children( jnode ) ) { result = IMFS_unlink( NULL, &loc ); d560: e3a00000 mov r0, #0 d564: e1a0100d mov r1, sp d568: ebffd474 bl 2740 if (result != 0) d56c: e3500000 cmp r0, #0 d570: 1a00000c bne d5a8 d574: e1a04006 mov r4, r6 return -1; jnode = next; } if ( jnode != NULL ) { d578: e3540000 cmp r4, #0 d57c: 0a00000b beq d5b0 if ( jnode->type == IMFS_DIRECTORY ) { d580: e594304c ldr r3, [r4, #76] ; 0x4c d584: e3530001 cmp r3, #1 d588: 1affffe9 bne d534 d58c: e5943050 ldr r3, [r4, #80] ; 0x50 d590: e2842054 add r2, r4, #84 ; 0x54 d594: e1530002 cmp r3, r2 d598: 0affffe5 beq d534 if ( jnode_has_children( jnode ) ) jnode = jnode_get_first_child( jnode ); } } } while (jnode != NULL); d59c: e2534000 subs r4, r3, #0 d5a0: 1affffe3 bne d534 d5a4: ea000001 b d5b0 <== NOT EXECUTED d5a8: e3e00000 mvn r0, #0 <== NOT EXECUTED d5ac: ea000000 b d5b4 <== NOT EXECUTED d5b0: e3a00000 mov r0, #0 return 0; } d5b4: e28dd014 add sp, sp, #20 d5b8: e8bd8070 pop {r4, r5, r6, pc} 00008b3c : IMFS_jnode_t *jnode; /* * determine/check value for imfs_memfile_bytes_per_block */ IMFS_determine_bytes_per_block(&imfs_memfile_bytes_per_block, 8b3c: e59fc0c8 ldr ip, [pc, #200] ; 8c0c 8b40: e59cc000 ldr ip, [ip] rtems_filesystem_mount_table_entry_t *temp_mt_entry, const rtems_filesystem_operations_table *op_table, const rtems_filesystem_file_handlers_r *memfile_handlers, const rtems_filesystem_file_handlers_r *directory_handlers ) { 8b44: e92d40f0 push {r4, r5, r6, r7, lr} 8b48: e1a06002 mov r6, r2 8b4c: e1a05003 mov r5, r3 8b50: e1a04000 mov r4, r0 8b54: e1a07001 mov r7, r1 IMFS_jnode_t *jnode; /* * determine/check value for imfs_memfile_bytes_per_block */ IMFS_determine_bytes_per_block(&imfs_memfile_bytes_per_block, 8b58: e3a02000 mov r2, #0 8b5c: e3a03010 mov r3, #16 int bit_mask; /* * check, whether requested bytes per block is valid */ for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) { 8b60: e153000c cmp r3, ip 8b64: e2822001 add r2, r2, #1 8b68: 0a000003 beq 8b7c 8b6c: e3520006 cmp r2, #6 8b70: e1a03083 lsl r3, r3, #1 8b74: 1afffff9 bne 8b60 8b78: e3a03080 mov r3, #128 ; 0x80 <== NOT EXECUTED if (bit_mask == requested_bytes_per_block) { is_valid = true; } } *dest_bytes_per_block = ((is_valid) 8b7c: e59f208c ldr r2, [pc, #140] ; 8c10 8b80: e5823000 str r3, [r2] /* * Create the root node * * NOTE: UNIX root is 755 and owned by root/root (0/0). */ temp_mt_entry->mt_fs_root.node_access = IMFS_create_root_node(); 8b84: eb000863 bl ad18 temp_mt_entry->mt_fs_root.handlers = directory_handlers; temp_mt_entry->mt_fs_root.ops = op_table; temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS; 8b88: e59fe084 ldr lr, [pc, #132] ; 8c14 /* * Create the root node * * NOTE: UNIX root is 755 and owned by root/root (0/0). */ temp_mt_entry->mt_fs_root.node_access = IMFS_create_root_node(); 8b8c: e584001c str r0, [r4, #28] temp_mt_entry->mt_fs_root.handlers = directory_handlers; temp_mt_entry->mt_fs_root.ops = op_table; temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS; 8b90: e8be000f ldm lr!, {r0, r1, r2, r3} 8b94: e284c038 add ip, r4, #56 ; 0x38 8b98: e8ac000f stmia ip!, {r0, r1, r2, r3} 8b9c: e8be000f ldm lr!, {r0, r1, r2, r3} 8ba0: e8ac000f stmia ip!, {r0, r1, r2, r3} 8ba4: e89e000f ldm lr, {r0, r1, r2, r3} * * NOTE: UNIX root is 755 and owned by root/root (0/0). */ temp_mt_entry->mt_fs_root.node_access = IMFS_create_root_node(); temp_mt_entry->mt_fs_root.handlers = directory_handlers; temp_mt_entry->mt_fs_root.ops = op_table; 8ba8: e5847028 str r7, [r4, #40] ; 0x28 temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS; 8bac: e88c000f stm ip, {r0, r1, r2, r3} * Create the root node * * NOTE: UNIX root is 755 and owned by root/root (0/0). */ temp_mt_entry->mt_fs_root.node_access = IMFS_create_root_node(); temp_mt_entry->mt_fs_root.handlers = directory_handlers; 8bb0: e5845024 str r5, [r4, #36] ; 0x24 temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS; /* * Create custom file system data. */ fs_info = calloc( 1, sizeof( IMFS_fs_info_t ) ); 8bb4: e3a00001 mov r0, #1 8bb8: e3a0100c mov r1, #12 8bbc: eb0000b2 bl 8e8c if ( !fs_info ) { 8bc0: e3500000 cmp r0, #0 8bc4: 1a000006 bne 8be4 free(temp_mt_entry->mt_fs_root.node_access); 8bc8: e594001c ldr r0, [r4, #28] <== NOT EXECUTED 8bcc: ebffe35d bl 1948 <== NOT EXECUTED rtems_set_errno_and_return_minus_one(ENOMEM); 8bd0: eb000bde bl bb50 <__errno> <== NOT EXECUTED 8bd4: e3a0300c mov r3, #12 <== NOT EXECUTED 8bd8: e5803000 str r3, [r0] <== NOT EXECUTED 8bdc: e3e00000 mvn r0, #0 <== NOT EXECUTED 8be0: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED fs_info->ino_count = 1; fs_info->memfile_handlers = memfile_handlers; fs_info->directory_handlers = directory_handlers; jnode = temp_mt_entry->mt_fs_root.node_access; jnode->st_ino = fs_info->ino_count; 8be4: e594201c ldr r2, [r4, #28] /* * Set st_ino for the root to 1. */ fs_info->ino_count = 1; 8be8: e3a03001 mov r3, #1 8bec: e5803000 str r3, [r0] fs_info->memfile_handlers = memfile_handlers; fs_info->directory_handlers = directory_handlers; 8bf0: e5805008 str r5, [r0, #8] /* * Set st_ino for the root to 1. */ fs_info->ino_count = 1; fs_info->memfile_handlers = memfile_handlers; 8bf4: e5806004 str r6, [r0, #4] fs_info = calloc( 1, sizeof( IMFS_fs_info_t ) ); if ( !fs_info ) { free(temp_mt_entry->mt_fs_root.node_access); rtems_set_errno_and_return_minus_one(ENOMEM); } temp_mt_entry->fs_info = fs_info; 8bf8: e5840034 str r0, [r4, #52] ; 0x34 fs_info->ino_count = 1; fs_info->memfile_handlers = memfile_handlers; fs_info->directory_handlers = directory_handlers; jnode = temp_mt_entry->mt_fs_root.node_access; jnode->st_ino = fs_info->ino_count; 8bfc: e5823038 str r3, [r2, #56] ; 0x38 /* Initialize POSIX FIFO/pipe module */ rtems_pipe_initialize(); 8c00: eb00061b bl a474 8c04: e3a00000 mov r0, #0 return 0; } 8c08: e8bd80f0 pop {r4, r5, r6, r7, pc} 8c0c: 00017584 .word 0x00017584 8c10: 00018ac8 .word 0x00018ac8 8c14: 00017fe8 .word 0x00017fe8 00002448 : int IMFS_link( rtems_filesystem_location_info_t *to_loc, /* IN */ rtems_filesystem_location_info_t *parent_loc, /* IN */ const char *token /* IN */ ) { 2448: e92d4070 push {r4, r5, r6, lr} int i; /* * Verify this node can be linked to. */ info.hard_link.link_node = to_loc->node_access; 244c: e5903000 ldr r3, [r0] int IMFS_link( rtems_filesystem_location_info_t *to_loc, /* IN */ rtems_filesystem_location_info_t *parent_loc, /* IN */ const char *token /* IN */ ) { 2450: e24dd048 sub sp, sp, #72 ; 0x48 int i; /* * Verify this node can be linked to. */ info.hard_link.link_node = to_loc->node_access; 2454: e58d3028 str r3, [sp, #40] ; 0x28 if ( info.hard_link.link_node->st_nlink >= LINK_MAX ) 2458: e1d333b4 ldrh r3, [r3, #52] ; 0x34 245c: e3530007 cmp r3, #7 int IMFS_link( rtems_filesystem_location_info_t *to_loc, /* IN */ rtems_filesystem_location_info_t *parent_loc, /* IN */ const char *token /* IN */ ) { 2460: e1a05001 mov r5, r1 2464: e1a06002 mov r6, r2 /* * Verify this node can be linked to. */ info.hard_link.link_node = to_loc->node_access; if ( info.hard_link.link_node->st_nlink >= LINK_MAX ) 2468: 9a000002 bls 2478 rtems_set_errno_and_return_minus_one( EMLINK ); 246c: eb0039bb bl 10b60 <__errno> 2470: e3a0301f mov r3, #31 2474: ea000012 b 24c4 /* * Remove any separators at the end of the string. */ IMFS_get_token( token, strlen( token ), new_name, &i ); 2478: e1a00002 mov r0, r2 247c: eb003d90 bl 11ac4 2480: e28d4004 add r4, sp, #4 2484: e1a01000 mov r1, r0 2488: e1a02004 mov r2, r4 248c: e28d3044 add r3, sp, #68 ; 0x44 2490: e1a00006 mov r0, r6 2494: eb002c70 bl d65c * was ONLY passed a NULL when we created the root node. We * added a new IMFS_create_root_node() so this path no longer * existed. The result was simpler code which should not have * this path. */ new_node = IMFS_create_node( 2498: e28dc028 add ip, sp, #40 ; 0x28 249c: e1a00005 mov r0, r5 24a0: e1a02004 mov r2, r4 24a4: e3a01003 mov r1, #3 24a8: e59f3054 ldr r3, [pc, #84] ; 2504 24ac: e58dc000 str ip, [sp] 24b0: eb002961 bl ca3c new_name, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if ( !new_node ) 24b4: e3500000 cmp r0, #0 24b8: 1a000004 bne 24d0 rtems_set_errno_and_return_minus_one( ENOMEM ); 24bc: eb0039a7 bl 10b60 <__errno> <== NOT EXECUTED 24c0: e3a0300c mov r3, #12 <== NOT EXECUTED 24c4: e5803000 str r3, [r0] 24c8: e3e00000 mvn r0, #0 24cc: ea00000a b 24fc /* * Increment the link count of the node being pointed to. */ info.hard_link.link_node->st_nlink++; 24d0: e59d3028 ldr r3, [sp, #40] ; 0x28 24d4: e1d323b4 ldrh r2, [r3, #52] ; 0x34 24d8: e2822001 add r2, r2, #1 24dc: e1c323b4 strh r2, [r3, #52] ; 0x34 IMFS_update_ctime( info.hard_link.link_node ); 24e0: e28d003c add r0, sp, #60 ; 0x3c 24e4: e3a01000 mov r1, #0 24e8: eb000240 bl 2df0 24ec: e59d203c ldr r2, [sp, #60] ; 0x3c 24f0: e59d3028 ldr r3, [sp, #40] ; 0x28 24f4: e5832048 str r2, [r3, #72] ; 0x48 24f8: e3a00000 mov r0, #0 return 0; } 24fc: e28dd048 add sp, sp, #72 ; 0x48 2500: e8bd8070 pop {r4, r5, r6, pc} 2504: 0000a1ff .word 0x0000a1ff 0000f840 : ) { block_p memory; block_p *block_entry_ptr; assert( the_jnode ); f840: e2503000 subs r3, r0, #0 MEMFILE_STATIC int IMFS_memfile_addblock( IMFS_jnode_t *the_jnode, unsigned int block ) { f844: e92d4030 push {r4, r5, lr} block_p memory; block_p *block_entry_ptr; assert( the_jnode ); f848: 059f0060 ldreq r0, [pc, #96] ; f8b0 f84c: 059f1060 ldreq r1, [pc, #96] ; f8b4 f850: 059f2060 ldreq r2, [pc, #96] ; f8b8 f854: 059f3060 ldreq r3, [pc, #96] ; f8bc f858: 0a000006 beq f878 if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE ); f85c: e593304c ldr r3, [r3, #76] ; 0x4c f860: e3530005 cmp r3, #5 f864: 0a000004 beq f87c f868: e59f0040 ldr r0, [pc, #64] ; f8b0 <== NOT EXECUTED f86c: e59f104c ldr r1, [pc, #76] ; f8c0 <== NOT EXECUTED f870: e59f2040 ldr r2, [pc, #64] ; f8b8 <== NOT EXECUTED f874: e59f3048 ldr r3, [pc, #72] ; f8c4 <== NOT EXECUTED f878: ebfff804 bl d890 <__assert_func> <== NOT EXECUTED if ( the_jnode->type != IMFS_MEMORY_FILE ) rtems_set_errno_and_return_minus_one( EIO ); block_entry_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 1 ); f87c: e3a02001 mov r2, #1 f880: ebfffeab bl f334 if ( *block_entry_ptr ) f884: e5904000 ldr r4, [r0] f888: e3540000 cmp r4, #0 assert( the_jnode->type == IMFS_MEMORY_FILE ); if ( the_jnode->type != IMFS_MEMORY_FILE ) rtems_set_errno_and_return_minus_one( EIO ); block_entry_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 1 ); f88c: e1a05000 mov r5, r0 if ( *block_entry_ptr ) f890: 13a00000 movne r0, #0 f894: 18bd8030 popne {r4, r5, pc} #if 0 fprintf(stdout, "%d %p", block, block_entry_ptr ); fflush(stdout); #endif memory = memfile_alloc_block(); f898: ebfffe98 bl f300 if ( !memory ) f89c: e3500000 cmp r0, #0 return 1; *block_entry_ptr = memory; f8a0: 15850000 strne r0, [r5] fprintf(stdout, "%d %p", block, block_entry_ptr ); fflush(stdout); #endif memory = memfile_alloc_block(); if ( !memory ) f8a4: 03a00001 moveq r0, #1 return 1; *block_entry_ptr = memory; f8a8: 11a00004 movne r0, r4 return 0; } f8ac: e8bd8030 pop {r4, r5, pc} f8b0: 0001de16 .word 0x0001de16 f8b4: 00000169 .word 0x00000169 f8b8: 0001d5e8 .word 0x0001d5e8 f8bc: 0001de5c .word 0x0001de5c f8c0: 0000016d .word 0x0000016d f8c4: 0001de66 .word 0x0001de66 0000f8c8 : MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, off_t new_length ) { f8c8: e92d4df1 push {r0, r4, r5, r6, r7, r8, sl, fp, lr} /* * Perform internal consistency checks */ assert( the_jnode ); f8cc: e2504000 subs r4, r0, #0 MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, off_t new_length ) { f8d0: e1a05001 mov r5, r1 f8d4: e1a06002 mov r6, r2 /* * Perform internal consistency checks */ assert( the_jnode ); f8d8: 059f0134 ldreq r0, [pc, #308] ; fa14 f8dc: 059f1134 ldreq r1, [pc, #308] ; fa18 f8e0: 059f2134 ldreq r2, [pc, #308] ; fa1c f8e4: 059f3134 ldreq r3, [pc, #308] ; fa20 f8e8: 0a000006 beq f908 if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE ); f8ec: e594304c ldr r3, [r4, #76] ; 0x4c f8f0: e3530005 cmp r3, #5 f8f4: 0a000004 beq f90c f8f8: e59f0114 ldr r0, [pc, #276] ; fa14 <== NOT EXECUTED f8fc: e59f1120 ldr r1, [pc, #288] ; fa24 <== NOT EXECUTED f900: e59f2114 ldr r2, [pc, #276] ; fa1c <== NOT EXECUTED f904: e59f311c ldr r3, [pc, #284] ; fa28 <== NOT EXECUTED f908: ebfff7e0 bl d890 <__assert_func> <== NOT EXECUTED if ( the_jnode->type != IMFS_MEMORY_FILE ) rtems_set_errno_and_return_minus_one( EIO ); if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE ) f90c: e59f3118 ldr r3, [pc, #280] ; fa2c f910: e593b000 ldr fp, [r3] f914: e1a0312b lsr r3, fp, #2 f918: e2832001 add r2, r3, #1 f91c: e0010293 mul r1, r3, r2 f920: e2811001 add r1, r1, #1 f924: e0020193 mul r2, r3, r1 f928: e3a03000 mov r3, #0 f92c: e1530006 cmp r3, r6 f930: e2422001 sub r2, r2, #1 f934: e003029b mul r3, fp, r2 f938: ca000005 bgt f954 f93c: 1a000001 bne f948 f940: e1530005 cmp r3, r5 f944: 8a000002 bhi f954 rtems_set_errno_and_return_minus_one( EINVAL ); f948: eb000484 bl 10b60 <__errno> <== NOT EXECUTED f94c: e3a03016 mov r3, #22 <== NOT EXECUTED f950: ea000025 b f9ec <== NOT EXECUTED if ( new_length <= the_jnode->info.file.size ) f954: e5948054 ldr r8, [r4, #84] ; 0x54 f958: e1560008 cmp r6, r8 f95c: e5947050 ldr r7, [r4, #80] ; 0x50 f960: ca000002 bgt f970 f964: 1a000028 bne fa0c f968: e1550007 cmp r5, r7 f96c: 9a000026 bls fa0c /* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK; f970: e1a0cfcb asr ip, fp, #31 f974: e1a0300c mov r3, ip f978: e1a0200b mov r2, fp f97c: e1a00005 mov r0, r5 f980: e1a01006 mov r1, r6 f984: e58dc000 str ip, [sp] f988: eb002cd2 bl 1acd8 <__divdi3> old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK; f98c: e59dc000 ldr ip, [sp] f990: e1a01008 mov r1, r8 /* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK; f994: e1a0a000 mov sl, r0 old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK; f998: e1a0200b mov r2, fp f99c: e1a00007 mov r0, r7 f9a0: e1a0300c mov r3, ip f9a4: eb002ccb bl 1acd8 <__divdi3> f9a8: e1a08000 mov r8, r0 f9ac: e1a07000 mov r7, r0 /* * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) { f9b0: ea000011 b f9fc if ( IMFS_memfile_addblock( the_jnode, block ) ) { f9b4: e1a00004 mov r0, r4 f9b8: e1a01007 mov r1, r7 f9bc: ebffff9f bl f840 f9c0: e3500000 cmp r0, #0 f9c4: 0a00000b beq f9f8 f9c8: ea000003 b f9dc <== NOT EXECUTED for ( ; block>=old_blocks ; block-- ) { IMFS_memfile_remove_block( the_jnode, block ); f9cc: e1a01007 mov r1, r7 <== NOT EXECUTED f9d0: e1a00004 mov r0, r4 <== NOT EXECUTED f9d4: ebfffefa bl f5c4 <== NOT EXECUTED * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) { if ( IMFS_memfile_addblock( the_jnode, block ) ) { for ( ; block>=old_blocks ; block-- ) { f9d8: e2477001 sub r7, r7, #1 <== NOT EXECUTED f9dc: e1570008 cmp r7, r8 <== NOT EXECUTED f9e0: 2afffff9 bcs f9cc <== NOT EXECUTED IMFS_memfile_remove_block( the_jnode, block ); } rtems_set_errno_and_return_minus_one( ENOSPC ); f9e4: eb00045d bl 10b60 <__errno> <== NOT EXECUTED f9e8: e3a0301c mov r3, #28 <== NOT EXECUTED f9ec: e5803000 str r3, [r0] <== NOT EXECUTED f9f0: e3e00000 mvn r0, #0 <== NOT EXECUTED f9f4: ea000005 b fa10 <== NOT EXECUTED /* * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) { f9f8: e2877001 add r7, r7, #1 f9fc: e157000a cmp r7, sl fa00: 9affffeb bls f9b4 /* * Set the new length of the file. */ the_jnode->info.file.size = new_length; fa04: e5846054 str r6, [r4, #84] ; 0x54 fa08: e5845050 str r5, [r4, #80] ; 0x50 fa0c: e3a00000 mov r0, #0 return 0; } fa10: e8bd8df8 pop {r3, r4, r5, r6, r7, r8, sl, fp, pc} fa14: 0001de16 .word 0x0001de16 fa18: 00000131 .word 0x00000131 fa1c: 0001d600 .word 0x0001d600 fa20: 0001de5c .word 0x0001de5c fa24: 00000135 .word 0x00000135 fa28: 0001de66 .word 0x0001de66 fa2c: 0001e1b0 .word 0x0001e1b0 0000f334 : #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) { f334: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} /* * Perform internal consistency checks */ assert( the_jnode ); f338: e2504000 subs r4, r0, #0 #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) { f33c: e1a06001 mov r6, r1 f340: e1a08002 mov r8, r2 /* * Perform internal consistency checks */ assert( the_jnode ); f344: 059f01e8 ldreq r0, [pc, #488] ; f534 f348: 03a01fe2 moveq r1, #904 ; 0x388 f34c: 059f21e4 ldreq r2, [pc, #484] ; f538 f350: 059f31e4 ldreq r3, [pc, #484] ; f53c f354: 0a000006 beq f374 if ( !the_jnode ) return NULL; assert( the_jnode->type == IMFS_MEMORY_FILE ); f358: e594304c ldr r3, [r4, #76] ; 0x4c f35c: e3530005 cmp r3, #5 f360: 0a000004 beq f378 f364: e59f01c8 ldr r0, [pc, #456] ; f534 <== NOT EXECUTED f368: e59f21c8 ldr r2, [pc, #456] ; f538 <== NOT EXECUTED f36c: e59f31cc ldr r3, [pc, #460] ; f540 <== NOT EXECUTED f370: e3a01fe3 mov r1, #908 ; 0x38c <== NOT EXECUTED f374: ebfff945 bl d890 <__assert_func> <== NOT EXECUTED /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { f378: e59f31c4 ldr r3, [pc, #452] ; f544 f37c: e5935000 ldr r5, [r3] f380: e1a05125 lsr r5, r5, #2 f384: e2453001 sub r3, r5, #1 f388: e1510003 cmp r1, r3 f38c: 8a00000e bhi f3cc fprintf(stdout, "(s %d) ", block ); fflush(stdout); #endif p = info->indirect; if ( malloc_it ) { f390: e3520000 cmp r2, #0 if ( my_block <= LAST_INDIRECT ) { #if 0 fprintf(stdout, "(s %d) ", block ); fflush(stdout); #endif p = info->indirect; f394: e5940058 ldr r0, [r4, #88] ; 0x58 if ( malloc_it ) { f398: 0a000007 beq f3bc if ( !p ) { f39c: e3500000 cmp r0, #0 f3a0: 1a000003 bne f3b4 p = memfile_alloc_block(); f3a4: ebffffd5 bl f300 if ( !p ) f3a8: e3500000 cmp r0, #0 f3ac: 0a00005e beq f52c return 0; info->indirect = p; f3b0: e5840058 str r0, [r4, #88] ; 0x58 } return &info->indirect[ my_block ]; f3b4: e5940058 ldr r0, [r4, #88] ; 0x58 f3b8: ea000001 b f3c4 } if ( !p ) f3bc: e3500000 cmp r0, #0 f3c0: 0a000059 beq f52c return 0; return &info->indirect[ my_block ]; f3c4: e0800106 add r0, r0, r6, lsl #2 f3c8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} /* * Is the block number in the doubly indirect portion? */ if ( my_block <= LAST_DOUBLY_INDIRECT ) { f3cc: e2852001 add r2, r5, #1 <== NOT EXECUTED f3d0: e0030295 mul r3, r5, r2 <== NOT EXECUTED f3d4: e2432001 sub r2, r3, #1 <== NOT EXECUTED f3d8: e1510002 cmp r1, r2 <== NOT EXECUTED f3dc: 8a00001b bhi f450 <== NOT EXECUTED #if 0 fprintf(stdout, "(d %d) ", block ); fflush(stdout); #endif my_block -= FIRST_DOUBLY_INDIRECT; f3e0: e0656001 rsb r6, r5, r1 <== NOT EXECUTED singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; f3e4: e1a00006 mov r0, r6 <== NOT EXECUTED f3e8: e1a01005 mov r1, r5 <== NOT EXECUTED f3ec: eb002b8c bl 1a224 <__umodsi3> <== NOT EXECUTED doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; f3f0: e1a01005 mov r1, r5 <== NOT EXECUTED fflush(stdout); #endif my_block -= FIRST_DOUBLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; f3f4: e1a0a000 mov sl, r0 <== NOT EXECUTED doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; f3f8: e1a00006 mov r0, r6 <== NOT EXECUTED f3fc: eb002af4 bl 19fd4 <__aeabi_uidiv> <== NOT EXECUTED p = info->doubly_indirect; if ( malloc_it ) { f400: e3580000 cmp r8, #0 <== NOT EXECUTED #endif my_block -= FIRST_DOUBLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; f404: e1a05000 mov r5, r0 <== NOT EXECUTED p = info->doubly_indirect; f408: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED if ( malloc_it ) { f40c: 0a000009 beq f438 <== NOT EXECUTED if ( !p ) { f410: e3530000 cmp r3, #0 <== NOT EXECUTED f414: 1a000003 bne f428 <== NOT EXECUTED p = memfile_alloc_block(); f418: ebffffb8 bl f300 <== NOT EXECUTED if ( !p ) f41c: e2503000 subs r3, r0, #0 <== NOT EXECUTED f420: 0a000041 beq f52c <== NOT EXECUTED return 0; info->doubly_indirect = p; f424: e584305c str r3, [r4, #92] ; 0x5c <== NOT EXECUTED } p1 = (block_p *)p[ doubly ]; f428: e7930105 ldr r0, [r3, r5, lsl #2] <== NOT EXECUTED f42c: e0835105 add r5, r3, r5, lsl #2 <== NOT EXECUTED if ( !p1 ) { f430: e3500000 cmp r0, #0 <== NOT EXECUTED f434: ea00002e b f4f4 <== NOT EXECUTED } return (block_p *)&p1[ singly ]; } if ( !p ) f438: e3530000 cmp r3, #0 <== NOT EXECUTED f43c: 0a00003a beq f52c <== NOT EXECUTED return 0; p = (block_p *)p[ doubly ]; f440: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED if ( !p ) f444: e3500000 cmp r0, #0 <== NOT EXECUTED f448: 1a000035 bne f524 <== NOT EXECUTED f44c: ea000036 b f52c <== NOT EXECUTED #endif /* * Is the block number in the triply indirect portion? */ if ( my_block <= LAST_TRIPLY_INDIRECT ) { f450: e2831001 add r1, r3, #1 <== NOT EXECUTED f454: e0020195 mul r2, r5, r1 <== NOT EXECUTED f458: e2422001 sub r2, r2, #1 <== NOT EXECUTED f45c: e1560002 cmp r6, r2 <== NOT EXECUTED f460: 8a000031 bhi f52c <== NOT EXECUTED my_block -= FIRST_TRIPLY_INDIRECT; f464: e0636006 rsb r6, r3, r6 <== NOT EXECUTED singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; f468: e1a01005 mov r1, r5 <== NOT EXECUTED f46c: e1a00006 mov r0, r6 <== NOT EXECUTED f470: eb002b6b bl 1a224 <__umodsi3> <== NOT EXECUTED doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; f474: e1a01005 mov r1, r5 <== NOT EXECUTED */ if ( my_block <= LAST_TRIPLY_INDIRECT ) { my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; f478: e1a0a000 mov sl, r0 <== NOT EXECUTED doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; f47c: e1a00006 mov r0, r6 <== NOT EXECUTED f480: eb002ad3 bl 19fd4 <__aeabi_uidiv> <== NOT EXECUTED triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; f484: e1a01005 mov r1, r5 <== NOT EXECUTED if ( my_block <= LAST_TRIPLY_INDIRECT ) { my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; f488: e1a06000 mov r6, r0 <== NOT EXECUTED triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; f48c: eb002ad0 bl 19fd4 <__aeabi_uidiv> <== NOT EXECUTED doubly %= IMFS_MEMFILE_BLOCK_SLOTS; f490: e1a01005 mov r1, r5 <== NOT EXECUTED if ( my_block <= LAST_TRIPLY_INDIRECT ) { my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; f494: e1a07000 mov r7, r0 <== NOT EXECUTED doubly %= IMFS_MEMFILE_BLOCK_SLOTS; f498: e1a00006 mov r0, r6 <== NOT EXECUTED f49c: eb002b60 bl 1a224 <__umodsi3> <== NOT EXECUTED p = info->triply_indirect; if ( malloc_it ) { f4a0: e3580000 cmp r8, #0 <== NOT EXECUTED my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; doubly %= IMFS_MEMFILE_BLOCK_SLOTS; f4a4: e1a05000 mov r5, r0 <== NOT EXECUTED p = info->triply_indirect; f4a8: e5943060 ldr r3, [r4, #96] ; 0x60 <== NOT EXECUTED if ( malloc_it ) { f4ac: 0a000016 beq f50c <== NOT EXECUTED if ( !p ) { f4b0: e3530000 cmp r3, #0 <== NOT EXECUTED f4b4: 1a000003 bne f4c8 <== NOT EXECUTED p = memfile_alloc_block(); f4b8: ebffff90 bl f300 <== NOT EXECUTED if ( !p ) f4bc: e2503000 subs r3, r0, #0 <== NOT EXECUTED f4c0: 0a000019 beq f52c <== NOT EXECUTED return 0; info->triply_indirect = p; f4c4: e5843060 str r3, [r4, #96] ; 0x60 <== NOT EXECUTED } p1 = (block_p *) p[ triply ]; f4c8: e7932107 ldr r2, [r3, r7, lsl #2] <== NOT EXECUTED if ( !p1 ) { f4cc: e3520000 cmp r2, #0 <== NOT EXECUTED if ( !p ) return 0; info->triply_indirect = p; } p1 = (block_p *) p[ triply ]; f4d0: e0837107 add r7, r3, r7, lsl #2 <== NOT EXECUTED if ( !p1 ) { f4d4: 1a000003 bne f4e8 <== NOT EXECUTED p1 = memfile_alloc_block(); f4d8: ebffff88 bl f300 <== NOT EXECUTED if ( !p1 ) f4dc: e2502000 subs r2, r0, #0 <== NOT EXECUTED f4e0: 0a000011 beq f52c <== NOT EXECUTED return 0; p[ triply ] = (block_p) p1; f4e4: e5872000 str r2, [r7] <== NOT EXECUTED } p2 = (block_p *)p1[ doubly ]; f4e8: e7920105 ldr r0, [r2, r5, lsl #2] <== NOT EXECUTED f4ec: e0825105 add r5, r2, r5, lsl #2 <== NOT EXECUTED if ( !p2 ) { f4f0: e3500000 cmp r0, #0 <== NOT EXECUTED f4f4: 1a00000a bne f524 <== NOT EXECUTED p2 = memfile_alloc_block(); f4f8: ebffff80 bl f300 <== NOT EXECUTED if ( !p2 ) f4fc: e3500000 cmp r0, #0 <== NOT EXECUTED return 0; p1[ doubly ] = (block_p) p2; f500: 15850000 strne r0, [r5] <== NOT EXECUTED } p2 = (block_p *)p1[ doubly ]; if ( !p2 ) { p2 = memfile_alloc_block(); if ( !p2 ) f504: 1a000006 bne f524 <== NOT EXECUTED f508: ea000007 b f52c <== NOT EXECUTED p1[ doubly ] = (block_p) p2; } return (block_p *)&p2[ singly ]; } if ( !p ) f50c: e3530000 cmp r3, #0 <== NOT EXECUTED f510: 0a000005 beq f52c <== NOT EXECUTED #if 0 fprintf(stdout, "(t %d %d %d %d %d) ", block, my_block, triply, doubly, singly ); fflush(stdout); #endif p1 = (block_p *) p[ triply ]; f514: e7933107 ldr r3, [r3, r7, lsl #2] <== NOT EXECUTED if ( !p1 ) f518: e3530000 cmp r3, #0 <== NOT EXECUTED f51c: 0a000002 beq f52c <== NOT EXECUTED p2 = (block_p *)p1[ doubly ]; if ( !p ) return 0; return (block_p *)&p2[ singly ]; f520: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED f524: e080010a add r0, r0, sl, lsl #2 <== NOT EXECUTED f528: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED f52c: e3a00000 mov r0, #0 <== NOT EXECUTED /* * This means the requested block number is out of range. */ return 0; } f530: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED f534: 0001de16 .word 0x0001de16 f538: 0001d578 .word 0x0001d578 f53c: 0001de5c .word 0x0001de5c f540: 0001de66 .word 0x0001de66 f544: 0001e1b0 .word 0x0001e1b0 0000fe50 : IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) { fe50: e92d4ff7 push {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} /* * Perform internal consistency checks */ assert( the_jnode ); fe54: e2504000 subs r4, r0, #0 IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) { fe58: e1a06003 mov r6, r3 fe5c: e1a08001 mov r8, r1 fe60: e1a09002 mov r9, r2 fe64: e59d7030 ldr r7, [sp, #48] ; 0x30 /* * Perform internal consistency checks */ assert( the_jnode ); fe68: 059f024c ldreq r0, [pc, #588] ; 100bc fe6c: 03a01f93 moveq r1, #588 ; 0x24c fe70: 059f2248 ldreq r2, [pc, #584] ; 100c0 fe74: 059f3248 ldreq r3, [pc, #584] ; 100c4 fe78: 0a000007 beq fe9c if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE || fe7c: e594304c ldr r3, [r4, #76] ; 0x4c fe80: e2432005 sub r2, r3, #5 fe84: e3520001 cmp r2, #1 fe88: 9a000004 bls fea0 fe8c: e59f0228 ldr r0, [pc, #552] ; 100bc <== NOT EXECUTED fe90: e59f1230 ldr r1, [pc, #560] ; 100c8 <== NOT EXECUTED fe94: e59f2224 ldr r2, [pc, #548] ; 100c0 <== NOT EXECUTED fe98: e59f322c ldr r3, [pc, #556] ; 100cc <== NOT EXECUTED fe9c: ebfff67b bl d890 <__assert_func> <== NOT EXECUTED /* * Error checks on arguments */ assert( dest ); fea0: e3560000 cmp r6, #0 fea4: 059f0210 ldreq r0, [pc, #528] ; 100bc fea8: 059f1220 ldreq r1, [pc, #544] ; 100d0 feac: 059f220c ldreq r2, [pc, #524] ; 100c0 feb0: 059f321c ldreq r3, [pc, #540] ; 100d4 feb4: 0afffff8 beq fe9c /* * If there is nothing to read, then quick exit. */ my_length = length; if ( !my_length ) feb8: e3570000 cmp r7, #0 febc: 1a000004 bne fed4 rtems_set_errno_and_return_minus_one( EINVAL ); fec0: eb000326 bl 10b60 <__errno> <== NOT EXECUTED fec4: e3a03016 mov r3, #22 <== NOT EXECUTED fec8: e5803000 str r3, [r0] <== NOT EXECUTED fecc: e3e07000 mvn r7, #0 <== NOT EXECUTED fed0: ea000077 b 100b4 <== NOT EXECUTED /* * Linear files (as created from a tar file are easier to handle * than block files). */ if (the_jnode->type == IMFS_LINEAR_FILE) { fed4: e3530006 cmp r3, #6 fed8: 1a000012 bne ff28 unsigned char *file_ptr; file_ptr = (unsigned char *)the_jnode->info.linearfile.direct; if (my_length > (the_jnode->info.linearfile.size - start)) fedc: e284b050 add fp, r4, #80 ; 0x50 <== NOT EXECUTED fee0: e89b0c00 ldm fp, {sl, fp} <== NOT EXECUTED fee4: e1a0200a mov r2, sl <== NOT EXECUTED fee8: e1a0300b mov r3, fp <== NOT EXECUTED feec: e3a01000 mov r1, #0 <== NOT EXECUTED fef0: e0522008 subs r2, r2, r8 <== NOT EXECUTED fef4: e0c33009 sbc r3, r3, r9 <== NOT EXECUTED fef8: e1510003 cmp r1, r3 <== NOT EXECUTED * than block files). */ if (the_jnode->type == IMFS_LINEAR_FILE) { unsigned char *file_ptr; file_ptr = (unsigned char *)the_jnode->info.linearfile.direct; fefc: e5941058 ldr r1, [r4, #88] ; 0x58 <== NOT EXECUTED if (my_length > (the_jnode->info.linearfile.size - start)) ff00: ca000002 bgt ff10 <== NOT EXECUTED ff04: 1a000002 bne ff14 <== NOT EXECUTED ff08: e1570002 cmp r7, r2 <== NOT EXECUTED ff0c: 9a000000 bls ff14 <== NOT EXECUTED my_length = the_jnode->info.linearfile.size - start; ff10: e068700a rsb r7, r8, sl <== NOT EXECUTED memcpy(dest, &file_ptr[start], my_length); ff14: e0811008 add r1, r1, r8 <== NOT EXECUTED ff18: e1a00006 mov r0, r6 <== NOT EXECUTED ff1c: e1a02007 mov r2, r7 <== NOT EXECUTED ff20: eb00051c bl 11398 <== NOT EXECUTED ff24: ea00005d b 100a0 <== NOT EXECUTED * If the last byte we are supposed to read is past the end of this * in memory file, then shorten the length to read. */ last_byte = start + length; if ( last_byte > the_jnode->info.file.size ) ff28: e5943054 ldr r3, [r4, #84] ; 0x54 ff2c: e3a02000 mov r2, #0 ff30: e1520003 cmp r2, r3 ff34: e5945050 ldr r5, [r4, #80] ; 0x50 /* * If the last byte we are supposed to read is past the end of this * in memory file, then shorten the length to read. */ last_byte = start + length; ff38: e1a03001 mov r3, r1 if ( last_byte > the_jnode->info.file.size ) ff3c: e0872001 add r2, r7, r1 ff40: ca000004 bgt ff58 ff44: 1a000001 bne ff50 ff48: e1520005 cmp r2, r5 ff4c: 8a000001 bhi ff58 ff50: e1a05007 mov r5, r7 ff54: ea000000 b ff5c my_length = the_jnode->info.file.size - start; ff58: e0635005 rsb r5, r3, r5 /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; ff5c: e59f3174 ldr r3, [pc, #372] ; 100d8 ff60: e593a000 ldr sl, [r3] ff64: e1a0b00a mov fp, sl ff68: e1a0cfcb asr ip, fp, #31 ff6c: e1a0300c mov r3, ip ff70: e1a00008 mov r0, r8 ff74: e1a0200b mov r2, fp ff78: e1a01009 mov r1, r9 ff7c: e58dc000 str ip, [sp] ff80: eb002c7e bl 1b180 <__moddi3> block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; ff84: e59dc000 ldr ip, [sp] /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; ff88: e1a07000 mov r7, r0 block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; ff8c: e1a01009 mov r1, r9 ff90: e1a00008 mov r0, r8 ff94: e1a0200b mov r2, fp ff98: e1a0300c mov r3, ip ff9c: eb002b4d bl 1acd8 <__divdi3> if ( start_offset ) { ffa0: e3570000 cmp r7, #0 /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; ffa4: e1a08000 mov r8, r0 if ( start_offset ) { ffa8: 0a000013 beq fffc to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK - start_offset; if ( to_copy > my_length ) to_copy = my_length; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); ffac: e1a00004 mov r0, r4 ffb0: e1a01008 mov r1, r8 ffb4: e3a02000 mov r2, #0 ffb8: ebfffcdd bl f334 assert( block_ptr ); ffbc: e3500000 cmp r0, #0 ffc0: 059f00f4 ldreq r0, [pc, #244] ; 100bc ffc4: 059f1110 ldreq r1, [pc, #272] ; 100dc ffc8: 0a00002c beq 10080 if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ start_offset ], to_copy ); ffcc: e5901000 ldr r1, [r0] */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; if ( start_offset ) { to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK - start_offset; ffd0: e067a00a rsb sl, r7, sl ffd4: e155000a cmp r5, sl ffd8: 31a0a005 movcc sl, r5 to_copy = my_length; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); assert( block_ptr ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ start_offset ], to_copy ); ffdc: e0811007 add r1, r1, r7 ffe0: e1a00006 mov r0, r6 ffe4: e1a0200a mov r2, sl ffe8: eb0004ea bl 11398 dest += to_copy; ffec: e086600a add r6, r6, sl block++; fff0: e2888001 add r8, r8, #1 my_length -= to_copy; fff4: e06a5005 rsb r5, sl, r5 fff8: e1a0700a mov r7, sl /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; fffc: e59f30d4 ldr r3, [pc, #212] ; 100d8 while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 10000: e1a09003 mov r9, r3 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; 10004: e593a000 ldr sl, [r3] while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 10008: ea00000f b 1004c block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 1000c: e1a00004 mov r0, r4 10010: e1a01008 mov r1, r8 10014: e3a02000 mov r2, #0 10018: ebfffcc5 bl f334 assert( block_ptr ); 1001c: e3500000 cmp r0, #0 10020: 059f0094 ldreq r0, [pc, #148] ; 100bc 10024: 059f10b4 ldreq r1, [pc, #180] ; 100e0 10028: 0a000014 beq 10080 if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy ); 1002c: e5901000 ldr r1, [r0] 10030: e1a0200a mov r2, sl 10034: e1a00006 mov r0, r6 10038: eb0004d6 bl 11398 dest += to_copy; 1003c: e086600a add r6, r6, sl block++; 10040: e2888001 add r8, r8, #1 my_length -= to_copy; 10044: e06a5005 rsb r5, sl, r5 copied += to_copy; 10048: e087700a add r7, r7, sl /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 1004c: e5993000 ldr r3, [r9] 10050: e1550003 cmp r5, r3 10054: 2affffec bcs 1000c * Phase 3: possibly the first part of one block */ assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); if ( my_length ) { 10058: e3550000 cmp r5, #0 1005c: 0a00000f beq 100a0 block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 10060: e1a01008 mov r1, r8 10064: e1a00004 mov r0, r4 10068: e3a02000 mov r2, #0 1006c: ebfffcb0 bl f334 assert( block_ptr ); 10070: e2503000 subs r3, r0, #0 10074: 1a000004 bne 1008c 10078: e59f003c ldr r0, [pc, #60] ; 100bc <== NOT EXECUTED 1007c: e59f1060 ldr r1, [pc, #96] ; 100e4 <== NOT EXECUTED 10080: e59f2038 ldr r2, [pc, #56] ; 100c0 <== NOT EXECUTED 10084: e59f305c ldr r3, [pc, #92] ; 100e8 <== NOT EXECUTED 10088: eaffff83 b fe9c <== NOT EXECUTED if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], my_length ); 1008c: e1a00006 mov r0, r6 10090: e5931000 ldr r1, [r3] 10094: e1a02005 mov r2, r5 10098: eb0004be bl 11398 copied += my_length; 1009c: e0857007 add r7, r5, r7 } IMFS_update_atime( the_jnode ); 100a0: e28d0004 add r0, sp, #4 100a4: e3a01000 mov r1, #0 100a8: ebffcb50 bl 2df0 100ac: e59d3004 ldr r3, [sp, #4] 100b0: e5843040 str r3, [r4, #64] ; 0x40 return copied; } 100b4: e1a00007 mov r0, r7 100b8: e8bd8ffe pop {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 100bc: 0001de16 .word 0x0001de16 100c0: 0001d628 .word 0x0001d628 100c4: 0001de5c .word 0x0001de5c 100c8: 00000251 .word 0x00000251 100cc: 0001ded0 .word 0x0001ded0 100d0: 0000025a .word 0x0000025a 100d4: 0001df1b .word 0x0001df1b 100d8: 0001e1b0 .word 0x0001e1b0 100dc: 00000296 .word 0x00000296 100e0: 000002a7 .word 0x000002a7 100e4: 000002b9 .word 0x000002b9 100e8: 0001de96 .word 0x0001de96 0000f610 : */ int IMFS_memfile_remove( IMFS_jnode_t *the_jnode ) { f610: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} /* * Perform internal consistency checks */ assert( the_jnode ); f614: e2504000 subs r4, r0, #0 f618: 059f012c ldreq r0, [pc, #300] ; f74c f61c: 059f112c ldreq r1, [pc, #300] ; f750 f620: 059f212c ldreq r2, [pc, #300] ; f754 f624: 059f312c ldreq r3, [pc, #300] ; f758 f628: 0a000006 beq f648 if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE ); f62c: e594304c ldr r3, [r4, #76] ; 0x4c f630: e3530005 cmp r3, #5 f634: 0a000004 beq f64c f638: e59f010c ldr r0, [pc, #268] ; f74c <== NOT EXECUTED f63c: e59f1118 ldr r1, [pc, #280] ; f75c <== NOT EXECUTED f640: e59f210c ldr r2, [pc, #268] ; f754 <== NOT EXECUTED f644: e59f3114 ldr r3, [pc, #276] ; f760 <== NOT EXECUTED f648: ebfff890 bl d890 <__assert_func> <== NOT EXECUTED /* * Eventually this could be set smarter at each call to * memfile_free_blocks_in_table to greatly speed this up. */ to_free = IMFS_MEMFILE_BLOCK_SLOTS; f64c: e59f2110 ldr r2, [pc, #272] ; f764 * + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; f650: e5943058 ldr r3, [r4, #88] ; 0x58 /* * Eventually this could be set smarter at each call to * memfile_free_blocks_in_table to greatly speed this up. */ to_free = IMFS_MEMFILE_BLOCK_SLOTS; f654: e5925000 ldr r5, [r2] * + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; f658: e3530000 cmp r3, #0 /* * Eventually this could be set smarter at each call to * memfile_free_blocks_in_table to greatly speed this up. */ to_free = IMFS_MEMFILE_BLOCK_SLOTS; f65c: e1a05125 lsr r5, r5, #2 */ info = &the_jnode->info.file; if ( info->indirect ) { memfile_free_blocks_in_table( &info->indirect, to_free ); f660: 12840058 addne r0, r4, #88 ; 0x58 f664: 11a01005 movne r1, r5 f668: 1bffffb6 blne f548 * + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; f66c: e594305c ldr r3, [r4, #92] ; 0x5c f670: e3530000 cmp r3, #0 f674: 13a06000 movne r6, #0 memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; i * + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; f67c: 1a000008 bne f6a4 f680: ea00000d b f6bc } if ( info->doubly_indirect ) { for ( i=0 ; idoubly_indirect[i] ) { f684: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED f688: e7932106 ldr r2, [r3, r6, lsl #2] <== NOT EXECUTED f68c: e3520000 cmp r2, #0 <== NOT EXECUTED f690: e1a00106 lsl r0, r6, #2 <== NOT EXECUTED memfile_free_blocks_in_table( f694: 10830000 addne r0, r3, r0 <== NOT EXECUTED f698: 11a01005 movne r1, r5 <== NOT EXECUTED f69c: 1bffffa9 blne f548 <== NOT EXECUTED memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; i <== NOT EXECUTED if ( info->doubly_indirect[i] ) { memfile_free_blocks_in_table( (block_p **)&info->doubly_indirect[i], to_free ); } } memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); f6b0: e284005c add r0, r4, #92 ; 0x5c <== NOT EXECUTED f6b4: e1a01005 mov r1, r5 <== NOT EXECUTED f6b8: ebffffa2 bl f548 <== NOT EXECUTED * + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; f6bc: e5943060 ldr r3, [r4, #96] ; 0x60 f6c0: e3530000 cmp r3, #0 f6c4: 13a06000 movne r6, #0 memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); } if ( info->triply_indirect ) { for ( i=0 ; i * + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; f6cc: 1a000016 bne f72c f6d0: ea00001b b f744 } if ( info->triply_indirect ) { for ( i=0 ; itriply_indirect[i]; f6d4: e5943060 ldr r3, [r4, #96] ; 0x60 <== NOT EXECUTED f6d8: e7937106 ldr r7, [r3, r6, lsl #2] <== NOT EXECUTED if ( !p ) /* ensure we have a valid pointer */ f6dc: e3570000 cmp r7, #0 <== NOT EXECUTED * + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; f6e0: e1a09106 lsl r9, r6, #2 <== NOT EXECUTED } if ( info->triply_indirect ) { for ( i=0 ; itriply_indirect[i]; if ( !p ) /* ensure we have a valid pointer */ f6e4: 0a000013 beq f738 <== NOT EXECUTED f6e8: e3a08000 mov r8, #0 <== NOT EXECUTED f6ec: ea000006 b f70c <== NOT EXECUTED break; for ( j=0 ; j <== NOT EXECUTED if ( info->triply_indirect ) { for ( i=0 ; itriply_indirect[i]; if ( !p ) /* ensure we have a valid pointer */ break; for ( j=0 ; j <== NOT EXECUTED if ( p[j] ) { memfile_free_blocks_in_table( (block_p **)&p[j], to_free); } } memfile_free_blocks_in_table( f718: e5940060 ldr r0, [r4, #96] ; 0x60 <== NOT EXECUTED f71c: e1a01005 mov r1, r5 <== NOT EXECUTED f720: e0800009 add r0, r0, r9 <== NOT EXECUTED f724: ebffff87 bl f548 <== NOT EXECUTED memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); } if ( info->triply_indirect ) { for ( i=0 ; i <== NOT EXECUTED } } memfile_free_blocks_in_table( (block_p **)&info->triply_indirect[i], to_free ); } memfile_free_blocks_in_table( f738: e2840060 add r0, r4, #96 ; 0x60 <== NOT EXECUTED f73c: e1a01005 mov r1, r5 <== NOT EXECUTED f740: ebffff80 bl f548 <== NOT EXECUTED (block_p **)&info->triply_indirect, to_free ); } return 0; } f744: e3a00000 mov r0, #0 f748: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} f74c: 0001de16 .word 0x0001de16 f750: 000001ee .word 0x000001ee f754: 0001d5d4 .word 0x0001d5d4 f758: 0001de5c .word 0x0001de5c f75c: 000001f2 .word 0x000001f2 f760: 0001de66 .word 0x0001de66 f764: 0001e1b0 .word 0x0001e1b0 0000f5c4 : MEMFILE_STATIC int IMFS_memfile_remove_block( IMFS_jnode_t *the_jnode, unsigned int block ) { f5c4: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED block_p *block_ptr; block_p ptr; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); f5c8: e3a02000 mov r2, #0 <== NOT EXECUTED f5cc: ebffff58 bl f334 <== NOT EXECUTED assert( block_ptr ); f5d0: e2503000 subs r3, r0, #0 <== NOT EXECUTED f5d4: 059f0024 ldreq r0, [pc, #36] ; f600 <== NOT EXECUTED f5d8: 059f1024 ldreq r1, [pc, #36] ; f604 <== NOT EXECUTED f5dc: 059f2024 ldreq r2, [pc, #36] ; f608 <== NOT EXECUTED f5e0: 059f3024 ldreq r3, [pc, #36] ; f60c <== NOT EXECUTED f5e4: 0bfff8a9 bleq d890 <__assert_func> <== NOT EXECUTED if ( block_ptr ) { ptr = *block_ptr; *block_ptr = 0; f5e8: e3a02000 mov r2, #0 <== NOT EXECUTED block_p ptr; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); assert( block_ptr ); if ( block_ptr ) { ptr = *block_ptr; f5ec: e5930000 ldr r0, [r3] <== NOT EXECUTED *block_ptr = 0; f5f0: e5832000 str r2, [r3] <== NOT EXECUTED memfile_free_block( ptr ); f5f4: ebffff39 bl f2e0 <== NOT EXECUTED } return 1; } f5f8: e3a00001 mov r0, #1 <== NOT EXECUTED f5fc: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED f600: 0001de16 .word 0x0001de16 f604: 00000196 .word 0x00000196 f608: 0001d5b8 .word 0x0001d5b8 f60c: 0001de96 .word 0x0001de96 0000fb20 : IMFS_jnode_t *the_jnode, off_t start, const unsigned char *source, unsigned int length ) { fb20: e92d4ff7 push {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} /* * Perform internal consistency checks */ assert( the_jnode ); fb24: e2504000 subs r4, r0, #0 IMFS_jnode_t *the_jnode, off_t start, const unsigned char *source, unsigned int length ) { fb28: e1a08001 mov r8, r1 fb2c: e1a0a002 mov sl, r2 fb30: e1a06003 mov r6, r3 fb34: e59d5030 ldr r5, [sp, #48] ; 0x30 /* * Perform internal consistency checks */ assert( the_jnode ); fb38: 059f0204 ldreq r0, [pc, #516] ; fd44 fb3c: 059f1204 ldreq r1, [pc, #516] ; fd48 fb40: 059f2204 ldreq r2, [pc, #516] ; fd4c fb44: 059f3204 ldreq r3, [pc, #516] ; fd50 fb48: 0a000006 beq fb68 if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE ); fb4c: e594304c ldr r3, [r4, #76] ; 0x4c fb50: e3530005 cmp r3, #5 fb54: 0a000004 beq fb6c fb58: e59f01e4 ldr r0, [pc, #484] ; fd44 <== NOT EXECUTED fb5c: e59f11f0 ldr r1, [pc, #496] ; fd54 <== NOT EXECUTED fb60: e59f21e4 ldr r2, [pc, #484] ; fd4c <== NOT EXECUTED fb64: e59f31ec ldr r3, [pc, #492] ; fd58 <== NOT EXECUTED fb68: ebfff748 bl d890 <__assert_func> <== NOT EXECUTED /* * Error check arguments */ assert( source ); fb6c: e3560000 cmp r6, #0 fb70: 059f01cc ldreq r0, [pc, #460] ; fd44 fb74: 059f11e0 ldreq r1, [pc, #480] ; fd5c fb78: 059f21cc ldreq r2, [pc, #460] ; fd4c fb7c: 059f31dc ldreq r3, [pc, #476] ; fd60 fb80: 0afffff8 beq fb68 /* * If there is nothing to write, then quick exit. */ my_length = length; if ( !my_length ) fb84: e3550000 cmp r5, #0 fb88: 1a000002 bne fb98 rtems_set_errno_and_return_minus_one( EINVAL ); fb8c: eb0003f3 bl 10b60 <__errno> <== NOT EXECUTED fb90: e3a03016 mov r3, #22 <== NOT EXECUTED fb94: ea00000e b fbd4 <== NOT EXECUTED * If the last byte we are supposed to write is past the end of this * in memory file, then extend the length. */ last_byte = start + length; if ( last_byte > the_jnode->info.file.size ) { fb98: e5943054 ldr r3, [r4, #84] ; 0x54 fb9c: e3530000 cmp r3, #0 fba0: e0851001 add r1, r5, r1 fba4: ba000003 blt fbb8 fba8: 1a00000c bne fbe0 fbac: e5943050 ldr r3, [r4, #80] ; 0x50 fbb0: e1530001 cmp r3, r1 fbb4: 2a000009 bcs fbe0 status = IMFS_memfile_extend( the_jnode, last_byte ); fbb8: e1a00004 mov r0, r4 fbbc: e3a02000 mov r2, #0 fbc0: ebffff40 bl f8c8 if ( status ) fbc4: e3500000 cmp r0, #0 fbc8: 0a000004 beq fbe0 rtems_set_errno_and_return_minus_one( ENOSPC ); fbcc: eb0003e3 bl 10b60 <__errno> <== NOT EXECUTED fbd0: e3a0301c mov r3, #28 <== NOT EXECUTED fbd4: e5803000 str r3, [r0] <== NOT EXECUTED fbd8: e3e07000 mvn r7, #0 <== NOT EXECUTED fbdc: ea000056 b fd3c <== NOT EXECUTED /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; fbe0: e59f317c ldr r3, [pc, #380] ; fd64 fbe4: e5939000 ldr r9, [r3] fbe8: e1a0b009 mov fp, r9 fbec: e1a0cfcb asr ip, fp, #31 fbf0: e1a0300c mov r3, ip fbf4: e1a00008 mov r0, r8 fbf8: e1a0200b mov r2, fp fbfc: e1a0100a mov r1, sl fc00: e58dc000 str ip, [sp] fc04: eb002d5d bl 1b180 <__moddi3> block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; fc08: e59dc000 ldr ip, [sp] /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; fc0c: e1a07000 mov r7, r0 block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; fc10: e1a0100a mov r1, sl fc14: e1a00008 mov r0, r8 fc18: e1a0200b mov r2, fp fc1c: e1a0300c mov r3, ip fc20: eb002c2c bl 1acd8 <__divdi3> if ( start_offset ) { fc24: e3570000 cmp r7, #0 /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; fc28: e1a08000 mov r8, r0 if ( start_offset ) { fc2c: 0a000013 beq fc80 to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK - start_offset; if ( to_copy > my_length ) to_copy = my_length; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); fc30: e1a01008 mov r1, r8 fc34: e1a00004 mov r0, r4 fc38: e3a02000 mov r2, #0 fc3c: ebfffdbc bl f334 assert( block_ptr ); fc40: e3500000 cmp r0, #0 fc44: 059f00f8 ldreq r0, [pc, #248] ; fd44 fc48: 03a01fc7 moveq r1, #796 ; 0x31c fc4c: 0a00002c beq fd04 if ( !block_ptr ) return copied; #if 0 fprintf(stdout, "write %d at %d in %d: %*s\n", to_copy, start_offset, block, to_copy, src ); #endif memcpy( &(*block_ptr)[ start_offset ], src, to_copy ); fc50: e5900000 ldr r0, [r0] */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; if ( start_offset ) { to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK - start_offset; fc54: e067a009 rsb sl, r7, r9 fc58: e15a0005 cmp sl, r5 fc5c: 21a0a005 movcs sl, r5 if ( !block_ptr ) return copied; #if 0 fprintf(stdout, "write %d at %d in %d: %*s\n", to_copy, start_offset, block, to_copy, src ); #endif memcpy( &(*block_ptr)[ start_offset ], src, to_copy ); fc60: e0800007 add r0, r0, r7 fc64: e1a01006 mov r1, r6 fc68: e1a0200a mov r2, sl fc6c: eb0005c9 bl 11398 src += to_copy; fc70: e086600a add r6, r6, sl block++; fc74: e2888001 add r8, r8, #1 my_length -= to_copy; fc78: e06a5005 rsb r5, sl, r5 copied += to_copy; fc7c: e1a0700a mov r7, sl /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; fc80: e59f30dc ldr r3, [pc, #220] ; fd64 while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { fc84: e1a09003 mov r9, r3 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; fc88: e593a000 ldr sl, [r3] while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { fc8c: ea00000f b fcd0 block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); fc90: e1a00004 mov r0, r4 fc94: e1a01008 mov r1, r8 fc98: e3a02000 mov r2, #0 fc9c: ebfffda4 bl f334 assert( block_ptr ); fca0: e3500000 cmp r0, #0 fca4: 059f0098 ldreq r0, [pc, #152] ; fd44 fca8: 03a01e33 moveq r1, #816 ; 0x330 fcac: 0a000014 beq fd04 if ( !block_ptr ) return copied; #if 0 fprintf(stdout, "write %d in %d: %*s\n", to_copy, block, to_copy, src ); #endif memcpy( &(*block_ptr)[ 0 ], src, to_copy ); fcb0: e1a01006 mov r1, r6 fcb4: e5900000 ldr r0, [r0] fcb8: e1a0200a mov r2, sl fcbc: eb0005b5 bl 11398 src += to_copy; fcc0: e086600a add r6, r6, sl block++; fcc4: e2888001 add r8, r8, #1 my_length -= to_copy; fcc8: e06a5005 rsb r5, sl, r5 * * This routine writes the specified data buffer into the in memory * file pointed to by the_jnode. The file is extended as needed. */ MEMFILE_STATIC ssize_t IMFS_memfile_write( fccc: e087700a add r7, r7, sl /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { fcd0: e5993000 ldr r3, [r9] fcd4: e1550003 cmp r5, r3 fcd8: 2affffec bcs fc90 */ assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); to_copy = my_length; if ( my_length ) { fcdc: e3550000 cmp r5, #0 fce0: 0a00000f beq fd24 block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); fce4: e1a01008 mov r1, r8 fce8: e1a00004 mov r0, r4 fcec: e3a02000 mov r2, #0 fcf0: ebfffd8f bl f334 assert( block_ptr ); fcf4: e3500000 cmp r0, #0 fcf8: 1a000004 bne fd10 fcfc: e59f0040 ldr r0, [pc, #64] ; fd44 <== NOT EXECUTED fd00: e59f1060 ldr r1, [pc, #96] ; fd68 <== NOT EXECUTED fd04: e59f2040 ldr r2, [pc, #64] ; fd4c <== NOT EXECUTED fd08: e59f305c ldr r3, [pc, #92] ; fd6c <== NOT EXECUTED fd0c: eaffff95 b fb68 <== NOT EXECUTED if ( !block_ptr ) return copied; #if 0 fprintf(stdout, "write %d in %d: %*s\n", to_copy, block, to_copy, src ); #endif memcpy( &(*block_ptr)[ 0 ], src, my_length ); fd10: e5900000 ldr r0, [r0] fd14: e1a01006 mov r1, r6 fd18: e1a02005 mov r2, r5 fd1c: eb00059d bl 11398 my_length = 0; copied += to_copy; fd20: e0877005 add r7, r7, r5 } IMFS_mtime_ctime_update( the_jnode ); fd24: e28d0004 add r0, sp, #4 fd28: e3a01000 mov r1, #0 fd2c: ebffcc2f bl 2df0 fd30: e59d3004 ldr r3, [sp, #4] fd34: e5843048 str r3, [r4, #72] ; 0x48 fd38: e5843044 str r3, [r4, #68] ; 0x44 return copied; } fd3c: e1a00007 mov r0, r7 fd40: e8bd8ffe pop {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} fd44: 0001de16 .word 0x0001de16 fd48: 000002e3 .word 0x000002e3 fd4c: 0001d614 .word 0x0001d614 fd50: 0001de5c .word 0x0001de5c fd54: 000002e7 .word 0x000002e7 fd58: 0001de66 .word 0x0001de66 fd5c: 000002ef .word 0x000002ef fd60: 0001dea0 .word 0x0001dea0 fd64: 0001e1b0 .word 0x0001e1b0 fd68: 00000346 .word 0x00000346 fd6c: 0001de96 .word 0x0001de96 00008c18 : const char *token, /* IN */ mode_t mode, /* IN */ dev_t dev, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN/OUT */ ) { 8c18: e92d40f0 push {r4, r5, r6, r7, lr} 8c1c: e24dd040 sub sp, sp, #64 ; 0x40 8c20: e1a04001 mov r4, r1 8c24: e1a07000 mov r7, r0 8c28: e1a06002 mov r6, r2 8c2c: e1a05003 mov r5, r3 IMFS_jnode_t *new_node; int result; char new_name[ IMFS_NAME_MAX + 1 ]; IMFS_types_union info; IMFS_get_token( token, strlen( token ), new_name, &result ); 8c30: eb000fb7 bl cb14 8c34: e28d303c add r3, sp, #60 ; 0x3c 8c38: e1a01000 mov r1, r0 8c3c: e28d2004 add r2, sp, #4 8c40: e1a00007 mov r0, r7 8c44: ebffff8a bl 8a74 /* * Figure out what type of IMFS node this is. */ if ( S_ISDIR(mode) ) 8c48: e2043a0f and r3, r4, #61440 ; 0xf000 8c4c: e3530901 cmp r3, #16384 ; 0x4000 8c50: 0a00000e beq 8c90 type = IMFS_DIRECTORY; else if ( S_ISREG(mode) ) 8c54: e3530902 cmp r3, #32768 ; 0x8000 8c58: 03a01005 moveq r1, #5 8c5c: 0a00000c beq 8c94 type = IMFS_MEMORY_FILE; else if ( S_ISBLK(mode) || S_ISCHR(mode) ) { 8c60: e3530a06 cmp r3, #24576 ; 0x6000 8c64: 13530a02 cmpne r3, #8192 ; 0x2000 type = IMFS_DEVICE; rtems_filesystem_split_dev_t( dev, info.device.major, info.device.minor ); 8c68: 058d6028 streq r6, [sp, #40] ; 0x28 8c6c: 058d502c streq r5, [sp, #44] ; 0x2c 8c70: 03a01002 moveq r1, #2 */ if ( S_ISDIR(mode) ) type = IMFS_DIRECTORY; else if ( S_ISREG(mode) ) type = IMFS_MEMORY_FILE; else if ( S_ISBLK(mode) || S_ISCHR(mode) ) { 8c74: 0a000006 beq 8c94 type = IMFS_DEVICE; rtems_filesystem_split_dev_t( dev, info.device.major, info.device.minor ); } else if (S_ISFIFO(mode)) 8c78: e3530a01 cmp r3, #4096 ; 0x1000 8c7c: 03a01007 moveq r1, #7 8c80: 0a000003 beq 8c94 type = IMFS_FIFO; else { rtems_set_errno_and_return_minus_one( EINVAL ); 8c84: eb000bb1 bl bb50 <__errno> <== NOT EXECUTED 8c88: e3a03016 mov r3, #22 <== NOT EXECUTED 8c8c: ea00000b b 8cc0 <== NOT EXECUTED 8c90: e3a01001 mov r1, #1 * was ONLY passed a NULL when we created the root node. We * added a new IMFS_create_root_node() so this path no longer * existed. The result was simpler code which should not have * this path. */ new_node = IMFS_create_node( 8c94: e28dc028 add ip, sp, #40 ; 0x28 8c98: e59d0054 ldr r0, [sp, #84] ; 0x54 8c9c: e1a03004 mov r3, r4 8ca0: e28d2004 add r2, sp, #4 8ca4: e58dc000 str ip, [sp] 8ca8: eb00082a bl ad58 new_name, mode, &info ); if ( !new_node ) 8cac: e3500000 cmp r0, #0 8cb0: 13a00000 movne r0, #0 8cb4: 1a000003 bne 8cc8 rtems_set_errno_and_return_minus_one( ENOMEM ); 8cb8: eb000ba4 bl bb50 <__errno> <== NOT EXECUTED 8cbc: e3a0300c mov r3, #12 <== NOT EXECUTED 8cc0: e5803000 str r3, [r0] <== NOT EXECUTED 8cc4: e3e00000 mvn r0, #0 <== NOT EXECUTED return 0; } 8cc8: e28dd040 add sp, sp, #64 ; 0x40 8ccc: e8bd80f0 pop {r4, r5, r6, r7, pc} 000025c0 : rtems_filesystem_mount_table_entry_t *mt_entry ) { IMFS_jnode_t *node; node = mt_entry->mt_point_node.node_access; 25c0: e5903008 ldr r3, [r0, #8] /* * Is the node that we are mounting onto a directory node ? */ if ( node->type != IMFS_DIRECTORY ) 25c4: e593204c ldr r2, [r3, #76] ; 0x4c 25c8: e3520001 cmp r2, #1 #include int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) { 25cc: e52de004 push {lr} ; (str lr, [sp, #-4]!) /* * Is the node that we are mounting onto a directory node ? */ if ( node->type != IMFS_DIRECTORY ) 25d0: 0a000004 beq 25e8 rtems_set_errno_and_return_minus_one( ENOTDIR ); 25d4: eb003961 bl 10b60 <__errno> <== NOT EXECUTED 25d8: e3a03014 mov r3, #20 <== NOT EXECUTED 25dc: e5803000 str r3, [r0] <== NOT EXECUTED 25e0: e3e00000 mvn r0, #0 <== NOT EXECUTED 25e4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED /* * Set mt_fs pointer to point to the mount table entry for * the mounted file system. */ node->info.directory.mt_fs = mt_entry; 25e8: e583005c str r0, [r3, #92] ; 0x5c 25ec: e3a00000 mov r0, #0 return 0; } 25f0: e49df004 pop {pc} ; (ldr pc, [sp], #4) 000031b4 : */ void IMFS_print_jnode( IMFS_jnode_t *the_jnode ) { 31b4: e92d4030 push {r4, r5, lr} assert( the_jnode ); 31b8: e2504000 subs r4, r0, #0 31bc: 059f0130 ldreq r0, [pc, #304] ; 32f4 31c0: 03a01038 moveq r1, #56 ; 0x38 31c4: 059f212c ldreq r2, [pc, #300] ; 32f8 31c8: 059f312c ldreq r3, [pc, #300] ; 32fc 31cc: 0a00002f beq 3290 fprintf(stdout, "%s", the_jnode->name ); 31d0: e59f5128 ldr r5, [pc, #296] ; 3300 31d4: e5953000 ldr r3, [r5] 31d8: e284000c add r0, r4, #12 31dc: e5931008 ldr r1, [r3, #8] 31e0: eb0034fe bl 105e0 switch( the_jnode->type ) { 31e4: e594204c ldr r2, [r4, #76] ; 0x4c 31e8: e2423001 sub r3, r2, #1 31ec: e3530006 cmp r3, #6 31f0: 979ff103 ldrls pc, [pc, r3, lsl #2] 31f4: ea000034 b 32cc <== NOT EXECUTED 31f8: 00003214 .word 0x00003214 <== NOT EXECUTED 31fc: 00003228 .word 0x00003228 <== NOT EXECUTED 3200: 00003270 .word 0x00003270 <== NOT EXECUTED 3204: 00003294 .word 0x00003294 <== NOT EXECUTED 3208: 00003258 .word 0x00003258 <== NOT EXECUTED 320c: 0000323c .word 0x0000323c <== NOT EXECUTED 3210: 000032b0 .word 0x000032b0 <== NOT EXECUTED case IMFS_DIRECTORY: fprintf(stdout, "/" ); 3214: e5953000 ldr r3, [r5] 3218: e3a0002f mov r0, #47 ; 0x2f 321c: e5931008 ldr r1, [r3, #8] 3220: eb0034a9 bl 104cc break; 3224: ea00002f b 32e8 case IMFS_DEVICE: fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")", 3228: e5952000 ldr r2, [r5] 322c: e5943054 ldr r3, [r4, #84] ; 0x54 3230: e5920008 ldr r0, [r2, #8] 3234: e59f10c8 ldr r1, [pc, #200] ; 3304 3238: ea000003 b 324c the_jnode->info.device.major, the_jnode->info.device.minor ); break; case IMFS_LINEAR_FILE: fprintf(stdout, " (file %" PRId32 " %p)", 323c: e5952000 ldr r2, [r5] <== NOT EXECUTED 3240: e5943058 ldr r3, [r4, #88] ; 0x58 <== NOT EXECUTED 3244: e5920008 ldr r0, [r2, #8] <== NOT EXECUTED 3248: e59f10b8 ldr r1, [pc, #184] ; 3308 <== NOT EXECUTED 324c: e5942050 ldr r2, [r4, #80] ; 0x50 3250: eb003481 bl 1045c (uint32_t)the_jnode->info.linearfile.size, the_jnode->info.linearfile.direct ); break; 3254: ea000023 b 32e8 the_jnode->info.file.indirect, the_jnode->info.file.doubly_indirect, the_jnode->info.file.triply_indirect ); #else fprintf(stdout, " (file %" PRId32 ")", 3258: e5953000 ldr r3, [r5] 325c: e5942050 ldr r2, [r4, #80] ; 0x50 3260: e5930008 ldr r0, [r3, #8] 3264: e59f10a0 ldr r1, [pc, #160] ; 330c 3268: eb00347b bl 1045c (uint32_t)the_jnode->info.file.size ); #endif break; 326c: ea00001d b 32e8 case IMFS_HARD_LINK: fprintf(stdout, " links not printed\n" ); 3270: e5953000 ldr r3, [r5] <== NOT EXECUTED 3274: e59f0094 ldr r0, [pc, #148] ; 3310 <== NOT EXECUTED 3278: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED 327c: eb0034d7 bl 105e0 <== NOT EXECUTED assert(0); 3280: e59f006c ldr r0, [pc, #108] ; 32f4 <== NOT EXECUTED 3284: e3a0105d mov r1, #93 ; 0x5d <== NOT EXECUTED 3288: e59f2068 ldr r2, [pc, #104] ; 32f8 <== NOT EXECUTED 328c: e59f3080 ldr r3, [pc, #128] ; 3314 <== NOT EXECUTED 3290: eb00020a bl 3ac0 <__assert_func> <== NOT EXECUTED break; case IMFS_SYM_LINK: fprintf(stdout, " links not printed\n" ); 3294: e5953000 ldr r3, [r5] <== NOT EXECUTED 3298: e59f0070 ldr r0, [pc, #112] ; 3310 <== NOT EXECUTED 329c: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED 32a0: eb0034ce bl 105e0 <== NOT EXECUTED assert(0); 32a4: e59f0048 ldr r0, [pc, #72] ; 32f4 <== NOT EXECUTED 32a8: e3a01062 mov r1, #98 ; 0x62 <== NOT EXECUTED 32ac: eafffff5 b 3288 <== NOT EXECUTED break; case IMFS_FIFO: fprintf(stdout, " FIFO not printed\n" ); 32b0: e5953000 ldr r3, [r5] <== NOT EXECUTED 32b4: e59f005c ldr r0, [pc, #92] ; 3318 <== NOT EXECUTED 32b8: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED 32bc: eb0034c7 bl 105e0 <== NOT EXECUTED assert(0); 32c0: e59f002c ldr r0, [pc, #44] ; 32f4 <== NOT EXECUTED 32c4: e3a01067 mov r1, #103 ; 0x67 <== NOT EXECUTED 32c8: eaffffee b 3288 <== NOT EXECUTED break; default: fprintf(stdout, " bad type %d\n", the_jnode->type ); 32cc: e5953000 ldr r3, [r5] <== NOT EXECUTED 32d0: e59f1044 ldr r1, [pc, #68] ; 331c <== NOT EXECUTED 32d4: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED 32d8: eb00345f bl 1045c <== NOT EXECUTED assert(0); 32dc: e59f0010 ldr r0, [pc, #16] ; 32f4 <== NOT EXECUTED 32e0: e3a0106c mov r1, #108 ; 0x6c <== NOT EXECUTED 32e4: eaffffe7 b 3288 <== NOT EXECUTED break; } puts(""); 32e8: e59f0030 ldr r0, [pc, #48] ; 3320 } 32ec: e8bd4030 pop {r4, r5, lr} default: fprintf(stdout, " bad type %d\n", the_jnode->type ); assert(0); break; } puts(""); 32f0: ea003b86 b 12110 32f4: 000218de .word 0x000218de 32f8: 00020648 .word 0x00020648 32fc: 00021927 .word 0x00021927 3300: 000200f0 .word 0x000200f0 3304: 00021931 .word 0x00021931 3308: 00021944 .word 0x00021944 330c: 00021953 .word 0x00021953 3310: 0002195f .word 0x0002195f 3314: 000212bd .word 0x000212bd 3318: 00021973 .word 0x00021973 331c: 00021986 .word 0x00021986 3320: 00021b17 .word 0x00021b17 00002600 : ) { IMFS_jnode_t *node; int i; node = loc->node_access; 2600: e5903000 ldr r3, [r0] if ( node->type != IMFS_SYM_LINK ) 2604: e593004c ldr r0, [r3, #76] ; 0x4c 2608: e3500004 cmp r0, #4 int IMFS_readlink( rtems_filesystem_location_info_t *loc, char *buf, /* OUT */ size_t bufsize ) { 260c: e52de004 push {lr} ; (str lr, [sp, #-4]!) IMFS_jnode_t *node; int i; node = loc->node_access; if ( node->type != IMFS_SYM_LINK ) 2610: 03a00000 moveq r0, #0 2614: 0a000006 beq 2634 rtems_set_errno_and_return_minus_one( EINVAL ); 2618: eb003950 bl 10b60 <__errno> <== NOT EXECUTED 261c: e3a03016 mov r3, #22 <== NOT EXECUTED 2620: e5803000 str r3, [r0] <== NOT EXECUTED 2624: e3e00000 mvn r0, #0 <== NOT EXECUTED 2628: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED for( i=0; ((iinfo.sym_link.name[i] != '\0')); i++ ) buf[i] = node->info.sym_link.name[i]; 262c: e7c1c000 strb ip, [r1, r0] node = loc->node_access; if ( node->type != IMFS_SYM_LINK ) rtems_set_errno_and_return_minus_one( EINVAL ); for( i=0; ((iinfo.sym_link.name[i] != '\0')); i++ ) 2630: e2800001 add r0, r0, #1 2634: e1500002 cmp r0, r2 2638: 249df004 popcs {pc} ; (ldrcs pc, [sp], #4) 263c: e593c050 ldr ip, [r3, #80] ; 0x50 2640: e7dcc000 ldrb ip, [ip, r0] 2644: e35c0000 cmp ip, #0 2648: 1afffff7 bne 262c buf[i] = node->info.sym_link.name[i]; return i; } 264c: e49df004 pop {pc} ; (ldr pc, [sp], #4) 00002650 : rtems_filesystem_location_info_t *old_parent_loc, /* IN */ rtems_filesystem_location_info_t *old_loc, /* IN */ rtems_filesystem_location_info_t *new_parent_loc, /* IN */ const char *new_name /* IN */ ) { 2650: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED IMFS_jnode_t *the_jnode; IMFS_jnode_t *new_parent; the_jnode = old_loc->node_access; 2654: e5914000 ldr r4, [r1] <== NOT EXECUTED rtems_filesystem_location_info_t *old_parent_loc, /* IN */ rtems_filesystem_location_info_t *old_loc, /* IN */ rtems_filesystem_location_info_t *new_parent_loc, /* IN */ const char *new_name /* IN */ ) { 2658: e1a05002 mov r5, r2 <== NOT EXECUTED IMFS_jnode_t *the_jnode; IMFS_jnode_t *new_parent; the_jnode = old_loc->node_access; strncpy( the_jnode->name, new_name, IMFS_NAME_MAX ); 265c: e1a01003 mov r1, r3 <== NOT EXECUTED 2660: e284000c add r0, r4, #12 <== NOT EXECUTED 2664: e3a02020 mov r2, #32 <== NOT EXECUTED 2668: eb003d2d bl 11b24 <== NOT EXECUTED if ( the_jnode->Parent != NULL ) 266c: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED 2670: e3530000 cmp r3, #0 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node ); 2674: 11a00004 movne r0, r4 <== NOT EXECUTED 2678: 1b001193 blne 6ccc <_Chain_Extract> <== NOT EXECUTED rtems_chain_extract( (rtems_chain_node *) the_jnode ); new_parent = new_parent_loc->node_access; 267c: e5953000 ldr r3, [r5] <== NOT EXECUTED RTEMS_INLINE_ROUTINE void rtems_chain_append( rtems_chain_control *the_chain, rtems_chain_node *the_node ) { _Chain_Append( the_chain, the_node ); 2680: e1a01004 mov r1, r4 <== NOT EXECUTED 2684: e2830050 add r0, r3, #80 ; 0x50 <== NOT EXECUTED the_jnode->Parent = new_parent; 2688: e5843008 str r3, [r4, #8] <== NOT EXECUTED 268c: eb001183 bl 6ca0 <_Chain_Append> <== NOT EXECUTED rtems_chain_append( &new_parent->info.directory.Entries, &the_jnode->Node ); /* * Update the time. */ IMFS_update_ctime( the_jnode ); 2690: e1a0000d mov r0, sp <== NOT EXECUTED 2694: e3a01000 mov r1, #0 <== NOT EXECUTED 2698: eb0001d4 bl 2df0 <== NOT EXECUTED 269c: e59d3000 ldr r3, [sp] <== NOT EXECUTED return 0; } 26a0: e3a00000 mov r0, #0 <== NOT EXECUTED rtems_chain_append( &new_parent->info.directory.Entries, &the_jnode->Node ); /* * Update the time. */ IMFS_update_ctime( the_jnode ); 26a4: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED return 0; } 26a8: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED 00008d84 : ) { IMFS_jnode_t *the_jnode; IMFS_device_t *io; the_jnode = loc->node_access; 8d84: e5903000 ldr r3, [r0] switch ( the_jnode->type ) { 8d88: e593204c ldr r2, [r3, #76] ; 0x4c 8d8c: e2422002 sub r2, r2, #2 int IMFS_stat( rtems_filesystem_location_info_t *loc, struct stat *buf ) { 8d90: e92d4800 push {fp, lr} IMFS_device_t *io; the_jnode = loc->node_access; switch ( the_jnode->type ) { 8d94: e3520005 cmp r2, #5 8d98: 979ff102 ldrls pc, [pc, r2, lsl #2] 8d9c: ea000012 b 8dec <== NOT EXECUTED 8da0: 00008db8 .word 0x00008db8 <== NOT EXECUTED 8da4: 00008dec .word 0x00008dec <== NOT EXECUTED 8da8: 00008dd8 .word 0x00008dd8 <== NOT EXECUTED 8dac: 00008dcc .word 0x00008dcc <== NOT EXECUTED 8db0: 00008dcc .word 0x00008dcc <== NOT EXECUTED 8db4: 00008dd8 .word 0x00008dd8 <== NOT EXECUTED case IMFS_DEVICE: io = &the_jnode->info.device; buf->st_rdev = rtems_filesystem_make_dev_t( io->major, io->minor ); 8db8: e5930054 ldr r0, [r3, #84] ; 0x54 rtems_device_minor_number _minor ) { union __rtems_dev_t temp; temp.__overlay.major = _major; 8dbc: e5932050 ldr r2, [r3, #80] ; 0x50 8dc0: e581001c str r0, [r1, #28] 8dc4: e5812018 str r2, [r1, #24] break; 8dc8: ea00000c b 8e00 case IMFS_LINEAR_FILE: case IMFS_MEMORY_FILE: buf->st_size = the_jnode->info.file.size; 8dcc: e283c050 add ip, r3, #80 ; 0x50 8dd0: e89c1800 ldm ip, {fp, ip} 8dd4: ea000001 b 8de0 case IMFS_SYM_LINK: buf->st_size = 0; break; case IMFS_FIFO: buf->st_size = 0; 8dd8: e3a0b000 mov fp, #0 <== NOT EXECUTED 8ddc: e3a0c000 mov ip, #0 <== NOT EXECUTED 8de0: e581b020 str fp, [r1, #32] 8de4: e581c024 str ip, [r1, #36] ; 0x24 break; 8de8: ea000004 b 8e00 default: rtems_set_errno_and_return_minus_one( ENOTSUP ); 8dec: eb000b57 bl bb50 <__errno> <== NOT EXECUTED 8df0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 8df4: e5803000 str r3, [r0] <== NOT EXECUTED 8df8: e3e00000 mvn r0, #0 <== NOT EXECUTED 8dfc: e8bd8800 pop {fp, pc} <== NOT EXECUTED break; } buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink; buf->st_ino = the_jnode->st_ino; 8e00: e5932038 ldr r2, [r3, #56] ; 0x38 8e04: e5812008 str r2, [r1, #8] buf->st_uid = the_jnode->st_uid; buf->st_gid = the_jnode->st_gid; buf->st_atime = the_jnode->stat_atime; 8e08: e5932040 ldr r2, [r3, #64] ; 0x40 8e0c: e5812028 str r2, [r1, #40] ; 0x28 rtems_set_errno_and_return_minus_one( ENOTSUP ); break; } buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink; 8e10: e1d3c3b4 ldrh ip, [r3, #52] ; 0x34 buf->st_ino = the_jnode->st_ino; buf->st_uid = the_jnode->st_uid; buf->st_gid = the_jnode->st_gid; buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime; 8e14: e5932044 ldr r2, [r3, #68] ; 0x44 rtems_set_errno_and_return_minus_one( ENOTSUP ); break; } buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink; 8e18: e1c1c1b0 strh ip, [r1, #16] buf->st_ino = the_jnode->st_ino; buf->st_uid = the_jnode->st_uid; buf->st_gid = the_jnode->st_gid; buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime; 8e1c: e5812030 str r2, [r1, #48] ; 0x30 default: rtems_set_errno_and_return_minus_one( ENOTSUP ); break; } buf->st_mode = the_jnode->st_mode; 8e20: e5932030 ldr r2, [r3, #48] ; 0x30 8e24: e581200c str r2, [r1, #12] buf->st_nlink = the_jnode->st_nlink; buf->st_ino = the_jnode->st_ino; buf->st_uid = the_jnode->st_uid; 8e28: e1d323bc ldrh r2, [r3, #60] ; 0x3c 8e2c: e1c121b2 strh r2, [r1, #18] buf->st_gid = the_jnode->st_gid; buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime; buf->st_ctime = the_jnode->stat_ctime; 8e30: e5930048 ldr r0, [r3, #72] ; 0x48 buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink; buf->st_ino = the_jnode->st_ino; buf->st_uid = the_jnode->st_uid; buf->st_gid = the_jnode->st_gid; 8e34: e1d333be ldrh r3, [r3, #62] ; 0x3e buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime; buf->st_ctime = the_jnode->stat_ctime; 8e38: e5810038 str r0, [r1, #56] ; 0x38 buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink; buf->st_ino = the_jnode->st_ino; buf->st_uid = the_jnode->st_uid; buf->st_gid = the_jnode->st_gid; 8e3c: e1c131b4 strh r3, [r1, #20] buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime; buf->st_ctime = the_jnode->stat_ctime; 8e40: e3a00000 mov r0, #0 return 0; } 8e44: e8bd8800 pop {fp, pc} 000026ac : int IMFS_symlink( rtems_filesystem_location_info_t *parent_loc, const char *link_name, const char *node_name ) { 26ac: e92d40f0 push {r4, r5, r6, r7, lr} 26b0: e1a05000 mov r5, r0 26b4: e24dd040 sub sp, sp, #64 ; 0x40 int i; /* * Remove any separators at the end of the string. */ IMFS_get_token( node_name, strlen( node_name ), new_name, &i ); 26b8: e1a00002 mov r0, r2 int IMFS_symlink( rtems_filesystem_location_info_t *parent_loc, const char *link_name, const char *node_name ) { 26bc: e1a07002 mov r7, r2 26c0: e1a06001 mov r6, r1 int i; /* * Remove any separators at the end of the string. */ IMFS_get_token( node_name, strlen( node_name ), new_name, &i ); 26c4: eb003cfe bl 11ac4 26c8: e28d4004 add r4, sp, #4 26cc: e1a01000 mov r1, r0 26d0: e1a02004 mov r2, r4 26d4: e28d303c add r3, sp, #60 ; 0x3c 26d8: e1a00007 mov r0, r7 26dc: eb002bde bl d65c /* * Duplicate link name */ info.sym_link.name = strdup(link_name); 26e0: e1a00006 mov r0, r6 26e4: eb003ce2 bl 11a74 if (info.sym_link.name == NULL) { 26e8: e3500000 cmp r0, #0 IMFS_get_token( node_name, strlen( node_name ), new_name, &i ); /* * Duplicate link name */ info.sym_link.name = strdup(link_name); 26ec: e58d0028 str r0, [sp, #40] ; 0x28 if (info.sym_link.name == NULL) { 26f0: 0a00000b beq 2724 * was ONLY passed a NULL when we created the root node. We * added a new IMFS_create_root_node() so this path no longer * existed. The result was simpler code which should not have * this path. */ new_node = IMFS_create_node( 26f4: e28dc028 add ip, sp, #40 ; 0x28 26f8: e1a00005 mov r0, r5 26fc: e1a02004 mov r2, r4 2700: e3a01004 mov r1, #4 2704: e59f3030 ldr r3, [pc, #48] ; 273c 2708: e58dc000 str ip, [sp] 270c: eb0028ca bl ca3c new_name, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if (new_node == NULL) { 2710: e3500000 cmp r0, #0 2714: 13a00000 movne r0, #0 2718: 1a000005 bne 2734 free(info.sym_link.name); 271c: e59d0028 ldr r0, [sp, #40] ; 0x28 <== NOT EXECUTED 2720: eb000189 bl 2d4c <== NOT EXECUTED rtems_set_errno_and_return_minus_one(ENOMEM); 2724: eb00390d bl 10b60 <__errno> <== NOT EXECUTED 2728: e3a0300c mov r3, #12 <== NOT EXECUTED 272c: e5803000 str r3, [r0] <== NOT EXECUTED 2730: e3e00000 mvn r0, #0 <== NOT EXECUTED } return 0; } 2734: e28dd040 add sp, sp, #64 ; 0x40 2738: e8bd80f0 pop {r4, r5, r6, r7, pc} 273c: 0000a1ff .word 0x0000a1ff 00002740 : int IMFS_unlink( rtems_filesystem_location_info_t *parentloc, /* IN */ rtems_filesystem_location_info_t *loc /* IN */ ) { 2740: e92d41f0 push {r4, r5, r6, r7, r8, lr} IMFS_jnode_t *node; rtems_filesystem_location_info_t the_link; int result = 0; node = loc->node_access; 2744: e5915000 ldr r5, [r1] /* * If this is the last last pointer to the node * free the node. */ if ( node->type == IMFS_HARD_LINK ) { 2748: e595304c ldr r3, [r5, #76] ; 0x4c 274c: e3530003 cmp r3, #3 int IMFS_unlink( rtems_filesystem_location_info_t *parentloc, /* IN */ rtems_filesystem_location_info_t *loc /* IN */ ) { 2750: e24dd01c sub sp, sp, #28 2754: e1a04001 mov r4, r1 2758: e1a06000 mov r6, r0 /* * If this is the last last pointer to the node * free the node. */ if ( node->type == IMFS_HARD_LINK ) { 275c: 1a000025 bne 27f8 if ( !node->info.hard_link.link_node ) 2760: e595e050 ldr lr, [r5, #80] ; 0x50 2764: e35e0000 cmp lr, #0 2768: 1a000003 bne 277c rtems_set_errno_and_return_minus_one( EINVAL ); 276c: eb0038fb bl 10b60 <__errno> <== NOT EXECUTED 2770: e3a03016 mov r3, #22 <== NOT EXECUTED 2774: e5803000 str r3, [r0] <== NOT EXECUTED 2778: ea000014 b 27d0 <== NOT EXECUTED the_link = *loc; 277c: e1a07001 mov r7, r1 2780: e8b7000f ldm r7!, {r0, r1, r2, r3} 2784: e1a0c00d mov ip, sp 2788: e8ac000f stmia ip!, {r0, r1, r2, r3} the_link.node_access = node->info.hard_link.link_node; 278c: e28d801c add r8, sp, #28 2790: e528e01c str lr, [r8, #-28]! if ( node->type == IMFS_HARD_LINK ) { if ( !node->info.hard_link.link_node ) rtems_set_errno_and_return_minus_one( EINVAL ); the_link = *loc; 2794: e5973000 ldr r3, [r7] the_link.node_access = node->info.hard_link.link_node; IMFS_Set_handlers( &the_link ); 2798: e1a0000d mov r0, sp if ( node->type == IMFS_HARD_LINK ) { if ( !node->info.hard_link.link_node ) rtems_set_errno_and_return_minus_one( EINVAL ); the_link = *loc; 279c: e58c3000 str r3, [ip] the_link.node_access = node->info.hard_link.link_node; IMFS_Set_handlers( &the_link ); 27a0: eb0028f4 bl cb78 /* * If removing the last hard link to a node, then we need * to remove the node that is a link and the node itself. */ if ( node->info.hard_link.link_node->st_nlink == 1) 27a4: e5953050 ldr r3, [r5, #80] ; 0x50 27a8: e1d323b4 ldrh r2, [r3, #52] ; 0x34 27ac: e3520001 cmp r2, #1 27b0: 1a000008 bne 27d8 { result = (*the_link.handlers->rmnod_h)( parentloc, &the_link ); 27b4: e1a0100d mov r1, sp 27b8: e1a00006 mov r0, r6 27bc: e59d3008 ldr r3, [sp, #8] 27c0: e1a0e00f mov lr, pc 27c4: e593f034 ldr pc, [r3, #52] ; 0x34 if ( result != 0 ) 27c8: e3500000 cmp r0, #0 27cc: 0a000009 beq 27f8 27d0: e3e00000 mvn r0, #0 27d4: ea00000c b 280c return -1; } else { node->info.hard_link.link_node->st_nlink --; 27d8: e2422001 sub r2, r2, #1 27dc: e1c323b4 strh r2, [r3, #52] ; 0x34 IMFS_update_ctime( node->info.hard_link.link_node ); 27e0: e28d0014 add r0, sp, #20 27e4: e3a01000 mov r1, #0 27e8: eb000180 bl 2df0 27ec: e5953050 ldr r3, [r5, #80] ; 0x50 27f0: e59d2014 ldr r2, [sp, #20] 27f4: e5832048 str r2, [r3, #72] ; 0x48 /* * Now actually free the node we were asked to free. */ result = (*loc->handlers->rmnod_h)( parentloc, loc ); 27f8: e1a00006 mov r0, r6 27fc: e1a01004 mov r1, r4 2800: e5943008 ldr r3, [r4, #8] 2804: e1a0e00f mov lr, pc 2808: e593f034 ldr pc, [r3, #52] ; 0x34 return result; } 280c: e28dd01c add sp, sp, #28 2810: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 00002814 : rtems_filesystem_mount_table_entry_t *mt_entry ) { IMFS_jnode_t *node; node = mt_entry->mt_point_node.node_access; 2814: e5903008 ldr r3, [r0, #8] /* * Is the node that we are mounting onto a directory node ? */ if ( node->type != IMFS_DIRECTORY ) 2818: e593204c ldr r2, [r3, #76] ; 0x4c 281c: e3520001 cmp r2, #1 #include int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) { 2820: e52de004 push {lr} ; (str lr, [sp, #-4]!) /* * Is the node that we are mounting onto a directory node ? */ if ( node->type != IMFS_DIRECTORY ) 2824: 0a000002 beq 2834 rtems_set_errno_and_return_minus_one( ENOTDIR ); 2828: eb0038cc bl 10b60 <__errno> <== NOT EXECUTED 282c: e3a03014 mov r3, #20 <== NOT EXECUTED 2830: ea000004 b 2848 <== NOT EXECUTED /* * Did the node indicate that there was a directory mounted here? */ if ( node->info.directory.mt_fs == NULL ) 2834: e593205c ldr r2, [r3, #92] ; 0x5c 2838: e3520000 cmp r2, #0 283c: 1a000004 bne 2854 rtems_set_errno_and_return_minus_one( EINVAL ); /* XXX */ 2840: eb0038c6 bl 10b60 <__errno> <== NOT EXECUTED 2844: e3a03016 mov r3, #22 <== NOT EXECUTED 2848: e5803000 str r3, [r0] <== NOT EXECUTED 284c: e3e00000 mvn r0, #0 <== NOT EXECUTED 2850: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED /* * Set the mt_fs pointer to indicate that there is no longer * a file system mounted to this point. */ node->info.directory.mt_fs = NULL; 2854: e3a00000 mov r0, #0 2858: e583005c str r0, [r3, #92] ; 0x5c return 0; } 285c: e49df004 pop {pc} ; (ldr pc, [sp], #4) 00001b28 : #endif /* * If configured, initialize the statistics support */ if ( rtems_malloc_statistics_helpers != NULL ) { 1b28: e59f30c8 ldr r3, [pc, #200] ; 1bf8 1b2c: e5933000 ldr r3, [r3] 1b30: e3530000 cmp r3, #0 void RTEMS_Malloc_Initialize( void *heap_begin, uintptr_t heap_size, size_t sbrk_amount ) { 1b34: e92d4070 push {r4, r5, r6, lr} 1b38: e1a04000 mov r4, r0 1b3c: e1a05001 mov r5, r1 1b40: e1a06002 mov r6, r2 /* * If configured, initialize the statistics support */ if ( rtems_malloc_statistics_helpers != NULL ) { (*rtems_malloc_statistics_helpers->initialize)(); 1b44: 11a0e00f movne lr, pc 1b48: 1593f000 ldrne pc, [r3] } /* * Initialize the garbage collection list to start with nothing on it. */ malloc_deferred_frees_initialize(); 1b4c: ebffffe1 bl 1ad8 /* * Initialize the optional sbrk support for extending the heap */ if ( rtems_malloc_sbrk_helpers != NULL ) { 1b50: e59f30a4 ldr r3, [pc, #164] ; 1bfc 1b54: e5933000 ldr r3, [r3] 1b58: e3530000 cmp r3, #0 1b5c: 0a000006 beq 1b7c void *new_heap_begin = (*rtems_malloc_sbrk_helpers->initialize)( 1b60: e1a00004 mov r0, r4 <== NOT EXECUTED 1b64: e1a01006 mov r1, r6 <== NOT EXECUTED 1b68: e1a0e00f mov lr, pc <== NOT EXECUTED 1b6c: e593f000 ldr pc, [r3] <== NOT EXECUTED heap_begin, sbrk_amount ); heap_size -= (uintptr_t) new_heap_begin - (uintptr_t) heap_begin; 1b70: e0845005 add r5, r4, r5 <== NOT EXECUTED 1b74: e0605005 rsb r5, r0, r5 <== NOT EXECUTED 1b78: e1a04000 mov r4, r0 <== NOT EXECUTED * of the time under UNIX because zero'ing memory when it is first * given to a process eliminates the chance of a process seeing data * left over from another process. This would be a security violation. */ if ( 1b7c: e59f307c ldr r3, [pc, #124] ; 1c00 1b80: e5d31000 ldrb r1, [r3] 1b84: e3510000 cmp r1, #0 1b88: 1a000005 bne 1ba4 !rtems_unified_work_area && rtems_configuration_get_do_zero_of_workspace() 1b8c: e59f3070 ldr r3, [pc, #112] ; 1c04 1b90: e5d33028 ldrb r3, [r3, #40] ; 0x28 1b94: e3530000 cmp r3, #0 ) { memset( heap_begin, 0, heap_size ); 1b98: 11a00004 movne r0, r4 1b9c: 11a02005 movne r2, r5 1ba0: 1b002a34 blne c478 * Unfortunately we cannot use assert if this fails because if this * has failed we do not have a heap and if we do not have a heap * STDIO cannot work because there will be no buffers. */ if ( !rtems_unified_work_area ) { 1ba4: e59f3054 ldr r3, [pc, #84] ; 1c00 1ba8: e5d33000 ldrb r3, [r3] 1bac: e3530000 cmp r3, #0 1bb0: 1a000008 bne 1bd8 void *area_begin, uintptr_t area_size, uintptr_t page_size ) { return _Heap_Initialize( heap, area_begin, area_size, page_size ); 1bb4: e59f304c ldr r3, [pc, #76] ; 1c08 1bb8: e1a01004 mov r1, r4 1bbc: e5930000 ldr r0, [r3] 1bc0: e1a02005 mov r2, r5 1bc4: e3a03004 mov r3, #4 1bc8: eb000f0c bl 5800 <_Heap_Initialize> RTEMS_Malloc_Heap, heap_begin, heap_size, CPU_HEAP_ALIGNMENT ); if ( status == 0 ) { 1bcc: e3500000 cmp r0, #0 rtems_fatal_error_occurred( RTEMS_NO_MEMORY ); 1bd0: 0280001a addeq r0, r0, #26 1bd4: 0b000d36 bleq 50b4 } } MSBUMP( space_available, _Protected_heap_Get_size(RTEMS_Malloc_Heap) ); 1bd8: e59f3028 ldr r3, [pc, #40] ; 1c08 1bdc: e59f4028 ldr r4, [pc, #40] ; 1c0c 1be0: e5930000 ldr r0, [r3] 1be4: e5945000 ldr r5, [r4] 1be8: eb0011db bl 635c <_Protected_heap_Get_size> 1bec: e0800005 add r0, r0, r5 1bf0: e5840000 str r0, [r4] printk( "\n" ); rtems_print_buffer( (heap_begin + heap_size) - 48, 48 ); rtems_fatal_error_occurred( RTEMS_NO_MEMORY ); } #endif } 1bf4: e8bd8070 pop {r4, r5, r6, pc} 1bf8: 000189a8 .word 0x000189a8 1bfc: 000189ac .word 0x000189ac 1c00: 000189a5 .word 0x000189a5 1c04: 00017634 .word 0x00017634 1c08: 0001758c .word 0x0001758c 1c0c: 00018cc8 .word 0x00018cc8 00002db8 : static rtems_printk_plugin_t print_handler; void Stack_check_Dump_threads_usage( Thread_Control *the_thread ) { 2db8: e92d47ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, lr}<== NOT EXECUTED void *high_water_mark; void *current; Stack_Control *stack; char name[5]; if ( !the_thread ) 2dbc: e250a000 subs sl, r0, #0 <== NOT EXECUTED 2dc0: 0a000043 beq 2ed4 <== NOT EXECUTED return; if ( !print_handler ) 2dc4: e59f310c ldr r3, [pc, #268] ; 2ed8 <== NOT EXECUTED 2dc8: e5937004 ldr r7, [r3, #4] <== NOT EXECUTED 2dcc: e3570000 cmp r7, #0 <== NOT EXECUTED 2dd0: 0a00003f beq 2ed4 <== NOT EXECUTED /* * Obtain interrupt stack information */ if (the_thread == (Thread_Control *) -1) { 2dd4: e37a0001 cmn sl, #1 <== NOT EXECUTED } else return; } else { stack = &the_thread->Start.Initial_stack; current = (void *)_CPU_Context_Get_SP( &the_thread->Registers ); 2dd8: 159a60f0 ldrne r6, [sl, #240] ; 0xf0 <== NOT EXECUTED current = 0; } else return; } else { stack = &the_thread->Start.Initial_stack; 2ddc: 128a40c0 addne r4, sl, #192 ; 0xc0 <== NOT EXECUTED /* * Obtain interrupt stack information */ if (the_thread == (Thread_Control *) -1) { 2de0: 1a000005 bne 2dfc <== NOT EXECUTED if (Stack_check_Interrupt_stack.area) { 2de4: e59f40f0 ldr r4, [pc, #240] ; 2edc <== NOT EXECUTED 2de8: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED 2dec: e3530000 cmp r3, #0 <== NOT EXECUTED 2df0: 13a06000 movne r6, #0 <== NOT EXECUTED 2df4: 11a0a006 movne sl, r6 <== NOT EXECUTED 2df8: 0a000035 beq 2ed4 <== NOT EXECUTED } else { stack = &the_thread->Start.Initial_stack; current = (void *)_CPU_Context_Get_SP( &the_thread->Registers ); } low = Stack_check_usable_stack_start(stack); 2dfc: e8940220 ldm r4, {r5, r9} <== NOT EXECUTED 2e00: e2899010 add r9, r9, #16 <== NOT EXECUTED size = Stack_check_usable_stack_size(stack); 2e04: e2455010 sub r5, r5, #16 <== NOT EXECUTED high_water_mark = Stack_check_find_high_water_mark(low, size); 2e08: e1a00009 mov r0, r9 <== NOT EXECUTED 2e0c: e1a01005 mov r1, r5 <== NOT EXECUTED 2e10: ebffffda bl 2d80 <== NOT EXECUTED if ( high_water_mark ) 2e14: e2508000 subs r8, r0, #0 <== NOT EXECUTED used = Stack_check_Calculate_used( low, size, high_water_mark ); 2e18: 10899005 addne r9, r9, r5 <== NOT EXECUTED 2e1c: 10688009 rsbne r8, r8, r9 <== NOT EXECUTED else used = 0; if ( the_thread ) { 2e20: e35a0000 cmp sl, #0 <== NOT EXECUTED 2e24: e59f30ac ldr r3, [pc, #172] ; 2ed8 <== NOT EXECUTED 2e28: 0a00000c beq 2e60 <== NOT EXECUTED (*print_handler)( 2e2c: e59aa008 ldr sl, [sl, #8] <== NOT EXECUTED 2e30: e28d2008 add r2, sp, #8 <== NOT EXECUTED 2e34: e1a0000a mov r0, sl <== NOT EXECUTED 2e38: e3a01005 mov r1, #5 <== NOT EXECUTED 2e3c: e5939008 ldr r9, [r3, #8] <== NOT EXECUTED 2e40: eb00152e bl 8300 <== NOT EXECUTED 2e44: e1a0200a mov r2, sl <== NOT EXECUTED 2e48: e1a03000 mov r3, r0 <== NOT EXECUTED 2e4c: e59f108c ldr r1, [pc, #140] ; 2ee0 <== NOT EXECUTED 2e50: e1a00009 mov r0, r9 <== NOT EXECUTED 2e54: e1a0e00f mov lr, pc <== NOT EXECUTED 2e58: e12fff17 bx r7 <== NOT EXECUTED 2e5c: ea000004 b 2e74 <== NOT EXECUTED "0x%08" PRIx32 " %4s", the_thread->Object.id, rtems_object_get_name( the_thread->Object.id, sizeof(name), name ) ); } else { (*print_handler)( print_context, "0x%08" PRIx32 " INTR", ~0 ); 2e60: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED 2e64: e59f1078 ldr r1, [pc, #120] ; 2ee4 <== NOT EXECUTED 2e68: e3e02000 mvn r2, #0 <== NOT EXECUTED 2e6c: e1a0e00f mov lr, pc <== NOT EXECUTED 2e70: e12fff17 bx r7 <== NOT EXECUTED } (*print_handler)( 2e74: e5943000 ldr r3, [r4] <== NOT EXECUTED 2e78: e5942004 ldr r2, [r4, #4] <== NOT EXECUTED 2e7c: e59f4054 ldr r4, [pc, #84] ; 2ed8 <== NOT EXECUTED 2e80: e58d6000 str r6, [sp] <== NOT EXECUTED 2e84: e58d5004 str r5, [sp, #4] <== NOT EXECUTED 2e88: e2433001 sub r3, r3, #1 <== NOT EXECUTED 2e8c: e0823003 add r3, r2, r3 <== NOT EXECUTED 2e90: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED 2e94: e59f104c ldr r1, [pc, #76] ; 2ee8 <== NOT EXECUTED 2e98: e1a0e00f mov lr, pc <== NOT EXECUTED 2e9c: e594f004 ldr pc, [r4, #4] <== NOT EXECUTED stack->area + stack->size - 1, current, size ); if (Stack_check_Initialized == 0) { 2ea0: e5943000 ldr r3, [r4] <== NOT EXECUTED 2ea4: e3530000 cmp r3, #0 <== NOT EXECUTED 2ea8: 1a000004 bne 2ec0 <== NOT EXECUTED (*print_handler)( print_context, "Unavailable\n" ); 2eac: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED 2eb0: e59f1034 ldr r1, [pc, #52] ; 2eec <== NOT EXECUTED 2eb4: e1a0e00f mov lr, pc <== NOT EXECUTED 2eb8: e594f004 ldr pc, [r4, #4] <== NOT EXECUTED 2ebc: ea000004 b 2ed4 <== NOT EXECUTED } else { (*print_handler)( print_context, "%8" PRId32 "\n", used ); 2ec0: e1a02008 mov r2, r8 <== NOT EXECUTED 2ec4: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED 2ec8: e59f1020 ldr r1, [pc, #32] ; 2ef0 <== NOT EXECUTED 2ecc: e1a0e00f mov lr, pc <== NOT EXECUTED 2ed0: e594f004 ldr pc, [r4, #4] <== NOT EXECUTED } } 2ed4: e8bd87ff pop {r0, r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, pc}<== NOT EXECUTED 2ed8: 0005cf7c .word 0x0005cf7c 2edc: 0005fbc8 .word 0x0005fbc8 2ee0: 000567d4 .word 0x000567d4 2ee4: 000567e1 .word 0x000567e1 2ee8: 000567ef .word 0x000567ef 2eec: 0005680d .word 0x0005680d 2ef0: 0005681a .word 0x0005681a 00002d80 : /* * start at lower memory and find first word that does not * match pattern */ base += PATTERN_SIZE_WORDS; 2d80: e2800010 add r0, r0, #16 <== NOT EXECUTED for (ebase = base + length; base < ebase; base++) 2d84: e3c11003 bic r1, r1, #3 <== NOT EXECUTED 2d88: e0801001 add r1, r0, r1 <== NOT EXECUTED if (*base != U32_PATTERN) 2d8c: e59f3020 ldr r3, [pc, #32] ; 2db4 <== NOT EXECUTED * start at lower memory and find first word that does not * match pattern */ base += PATTERN_SIZE_WORDS; for (ebase = base + length; base < ebase; base++) 2d90: ea000003 b 2da4 <== NOT EXECUTED if (*base != U32_PATTERN) 2d94: e5902000 ldr r2, [r0] <== NOT EXECUTED 2d98: e1520003 cmp r2, r3 <== NOT EXECUTED 2d9c: 112fff1e bxne lr <== NOT EXECUTED * start at lower memory and find first word that does not * match pattern */ base += PATTERN_SIZE_WORDS; for (ebase = base + length; base < ebase; base++) 2da0: e2800004 add r0, r0, #4 <== NOT EXECUTED 2da4: e1500001 cmp r0, r1 <== NOT EXECUTED 2da8: 3afffff9 bcc 2d94 <== NOT EXECUTED 2dac: e3a00000 mov r0, #0 <== NOT EXECUTED if (*base != U32_PATTERN) return (void *) base; #endif return (void *)0; } 2db0: e12fff1e bx lr <== NOT EXECUTED 2db4: a5a5a5a5 .word 0xa5a5a5a5 000098b4 <_CORE_mutex_Seize_interrupt_trylock>: { Thread_Control *executing; /* disabled when you get here */ executing = _Thread_Executing; 98b4: e59f3120 ldr r3, [pc, #288] ; 99dc <_CORE_mutex_Seize_interrupt_trylock+0x128> 98b8: e5933000 ldr r3, [r3] executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 98bc: e3a02000 mov r2, #0 98c0: e5832034 str r2, [r3, #52] ; 0x34 if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 98c4: e590c050 ldr ip, [r0, #80] ; 0x50 98c8: e15c0002 cmp ip, r2 #if defined(__RTEMS_DO_NOT_INLINE_CORE_MUTEX_SEIZE__) int _CORE_mutex_Seize_interrupt_trylock( CORE_mutex_Control *the_mutex, ISR_Level *level_p ) { 98cc: e52de004 push {lr} ; (str lr, [sp, #-4]!) 98d0: 0a00002c beq 9988 <_CORE_mutex_Seize_interrupt_trylock+0xd4> the_mutex->lock = CORE_MUTEX_LOCKED; 98d4: e5802050 str r2, [r0, #80] ; 0x50 */ RTEMS_INLINE_ROUTINE bool _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 98d8: e5902048 ldr r2, [r0, #72] ; 0x48 executing = _Thread_Executing; executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; if ( !_CORE_mutex_Is_locked( the_mutex ) ) { the_mutex->lock = CORE_MUTEX_LOCKED; the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 98dc: e593c008 ldr ip, [r3, #8] the_mutex->nest_count = 1; if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 98e0: e3520002 cmp r2, #2 executing = _Thread_Executing; executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; if ( !_CORE_mutex_Is_locked( the_mutex ) ) { the_mutex->lock = CORE_MUTEX_LOCKED; the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 98e4: e580c060 str ip, [r0, #96] ; 0x60 the_mutex->nest_count = 1; 98e8: e3a0c001 mov ip, #1 98ec: e580c054 str ip, [r0, #84] ; 0x54 executing = _Thread_Executing; executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; if ( !_CORE_mutex_Is_locked( the_mutex ) ) { the_mutex->lock = CORE_MUTEX_LOCKED; the_mutex->holder = executing; 98f0: e580305c str r3, [r0, #92] ; 0x5c the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 98f4: 0a000001 beq 9900 <_CORE_mutex_Seize_interrupt_trylock+0x4c> 98f8: e3520003 cmp r2, #3 98fc: 1a000004 bne 9914 <_CORE_mutex_Seize_interrupt_trylock+0x60> _Chain_Prepend_unprotected( &executing->lock_mutex, &the_mutex->queue.lock_queue ); the_mutex->queue.priority_before = executing->current_priority; #endif executing->resource_count++; 9900: e593c01c ldr ip, [r3, #28] } if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 9904: e3520003 cmp r2, #3 _Chain_Prepend_unprotected( &executing->lock_mutex, &the_mutex->queue.lock_queue ); the_mutex->queue.priority_before = executing->current_priority; #endif executing->resource_count++; 9908: e28c2001 add r2, ip, #1 990c: e583201c str r2, [r3, #28] } if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 9910: 0a000000 beq 9918 <_CORE_mutex_Seize_interrupt_trylock+0x64> _ISR_Enable( *level_p ); 9914: ea00002a b 99c4 <_CORE_mutex_Seize_interrupt_trylock+0x110> */ { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; 9918: e590204c ldr r2, [r0, #76] ; 0x4c current = executing->current_priority; 991c: e593c014 ldr ip, [r3, #20] if ( current == ceiling ) { 9920: e15c0002 cmp ip, r2 9924: 1a000000 bne 992c <_CORE_mutex_Seize_interrupt_trylock+0x78> _ISR_Enable( *level_p ); 9928: ea000025 b 99c4 <_CORE_mutex_Seize_interrupt_trylock+0x110> return 0; } if ( current > ceiling ) { 992c: 9a00000b bls 9960 <_CORE_mutex_Seize_interrupt_trylock+0xac> rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 9930: e59f30a8 ldr r3, [pc, #168] ; 99e0 <_CORE_mutex_Seize_interrupt_trylock+0x12c> 9934: e5932000 ldr r2, [r3] 9938: e2822001 add r2, r2, #1 993c: e5832000 str r2, [r3] 9940: e5913000 ldr r3, [r1] 9944: e129f003 msr CPSR_fc, r3 _Thread_Disable_dispatch(); _ISR_Enable( *level_p ); _Thread_Change_priority( 9948: e3a02000 mov r2, #0 994c: e590104c ldr r1, [r0, #76] ; 0x4c 9950: e590005c ldr r0, [r0, #92] ; 0x5c 9954: ebfff295 bl 63b0 <_Thread_Change_priority> the_mutex->holder, the_mutex->Attributes.priority_ceiling, false ); _Thread_Enable_dispatch(); 9958: ebfff3f5 bl 6934 <_Thread_Enable_dispatch> 995c: ea00001a b 99cc <_CORE_mutex_Seize_interrupt_trylock+0x118> return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 9960: e3a02006 mov r2, #6 9964: e5832034 str r2, [r3, #52] ; 0x34 the_mutex->lock = CORE_MUTEX_UNLOCKED; the_mutex->nest_count = 0; /* undo locking above */ 9968: e3a02000 mov r2, #0 996c: e5802054 str r2, [r0, #84] ; 0x54 _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 9970: e2822001 add r2, r2, #1 9974: e5802050 str r2, [r0, #80] ; 0x50 the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 9978: e593201c ldr r2, [r3, #28] 997c: e2422001 sub r2, r2, #1 9980: e583201c str r2, [r3, #28] _ISR_Enable( *level_p ); 9984: ea00000e b 99c4 <_CORE_mutex_Seize_interrupt_trylock+0x110> /* * At this point, we know the mutex was not available. If this thread * is the thread that has locked the mutex, let's see if we are allowed * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { 9988: e590205c ldr r2, [r0, #92] ; 0x5c 998c: e1520003 cmp r2, r3 9990: 1a00000f bne 99d4 <_CORE_mutex_Seize_interrupt_trylock+0x120> switch ( the_mutex->Attributes.lock_nesting_behavior ) { 9994: e5903040 ldr r3, [r0, #64] ; 0x40 9998: e3530000 cmp r3, #0 999c: 0a000002 beq 99ac <_CORE_mutex_Seize_interrupt_trylock+0xf8> 99a0: e3530001 cmp r3, #1 99a4: 1a00000a bne 99d4 <_CORE_mutex_Seize_interrupt_trylock+0x120> 99a8: ea000003 b 99bc <_CORE_mutex_Seize_interrupt_trylock+0x108><== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 99ac: e5903054 ldr r3, [r0, #84] ; 0x54 99b0: e2833001 add r3, r3, #1 99b4: e5803054 str r3, [r0, #84] ; 0x54 _ISR_Enable( *level_p ); 99b8: ea000001 b 99c4 <_CORE_mutex_Seize_interrupt_trylock+0x110> return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 99bc: e3a03002 mov r3, #2 <== NOT EXECUTED 99c0: e5823034 str r3, [r2, #52] ; 0x34 <== NOT EXECUTED 99c4: e5913000 ldr r3, [r1] 99c8: e129f003 msr CPSR_fc, r3 99cc: e3a00000 mov r0, #0 99d0: e49df004 pop {pc} ; (ldr pc, [sp], #4) 99d4: e3a00001 mov r0, #1 return _CORE_mutex_Seize_interrupt_trylock_body( the_mutex, level_p ); } 99d8: e49df004 pop {pc} ; (ldr pc, [sp], #4) 99dc: 00018ee0 .word 0x00018ee0 99e0: 00018e2c .word 0x00018e2c 00006e90 <_Thread_queue_Enqueue_priority>: Thread_blocking_operation_States _Thread_queue_Enqueue_priority ( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread, ISR_Level *level_p ) { 6e90: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} Priority_Control priority; States_Control block_state; _Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; 6e94: e5913014 ldr r3, [r1, #20] */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 6e98: e281503c add r5, r1, #60 ; 0x3c 6e9c: e5815038 str r5, [r1, #56] ; 0x38 the_chain->permanent_null = NULL; 6ea0: e3a05000 mov r5, #0 the_chain->last = _Chain_Head(the_chain); 6ea4: e281c038 add ip, r1, #56 ; 0x38 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 ) ) 6ea8: e3130020 tst r3, #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 ]; 6eac: e1a04323 lsr r4, r3, #6 RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL; 6eb0: e581503c str r5, [r1, #60] ; 0x3c 6eb4: e285500c add r5, r5, #12 the_chain->last = _Chain_Head(the_chain); 6eb8: e581c040 str ip, [r1, #64] ; 0x40 block_state = the_thread_queue->state; 6ebc: e5907038 ldr r7, [r0, #56] ; 0x38 _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 ]; 6ec0: e02c0495 mla ip, r5, r4, r0 the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; 6ec4: 159f8154 ldrne r8, [pc, #340] ; 7020 <_Thread_queue_Enqueue_priority+0x190> 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 ) ) 6ec8: 1a000023 bne 6f5c <_Thread_queue_Enqueue_priority+0xcc> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 6ecc: e28c8004 add r8, ip, #4 static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 6ed0: e10f5000 mrs r5, CPSR 6ed4: e3854080 orr r4, r5, #128 ; 0x80 6ed8: e129f004 msr CPSR_fc, r4 goto restart_reverse_search; restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->first; 6edc: e3e06000 mvn r6, #0 6ee0: e59c4000 ldr r4, [ip] while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) { 6ee4: ea00000b b 6f18 <_Thread_queue_Enqueue_priority+0x88> search_priority = search_thread->current_priority; 6ee8: e5946014 ldr r6, [r4, #20] if ( priority <= search_priority ) 6eec: e1530006 cmp r3, r6 6ef0: 9a00000a bls 6f20 <_Thread_queue_Enqueue_priority+0x90> static inline void arm_interrupt_flash( uint32_t level ) { uint32_t arm_switch_reg; asm volatile ( 6ef4: e10fa000 mrs sl, CPSR 6ef8: e129f005 msr CPSR_fc, r5 6efc: e129f00a msr CPSR_fc, sl 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) ) { 6f00: e594a010 ldr sl, [r4, #16] 6f04: e117000a tst r7, sl 6f08: 1a000001 bne 6f14 <_Thread_queue_Enqueue_priority+0x84> static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 6f0c: e129f005 msr CPSR_fc, r5 <== NOT EXECUTED 6f10: eaffffee b 6ed0 <_Thread_queue_Enqueue_priority+0x40> <== NOT EXECUTED _ISR_Enable( level ); goto restart_forward_search; } search_thread = (Thread_Control *)search_thread->Object.Node.next; 6f14: e5944000 ldr r4, [r4] 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 ) ) { 6f18: e1540008 cmp r4, r8 6f1c: 1afffff1 bne 6ee8 <_Thread_queue_Enqueue_priority+0x58> } search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state != 6f20: e590c030 ldr ip, [r0, #48] ; 0x30 6f24: e35c0001 cmp ip, #1 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 ) ) { 6f28: e1a0c005 mov ip, r5 } search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state != 6f2c: 1a000038 bne 7014 <_Thread_queue_Enqueue_priority+0x184> THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; if ( priority == search_priority ) 6f30: e1530006 cmp r3, r6 if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; 6f34: e3a03000 mov r3, #0 6f38: e5803030 str r3, [r0, #48] ; 0x30 if ( priority == search_priority ) 6f3c: 0a00002a beq 6fec <_Thread_queue_Enqueue_priority+0x15c> goto equal_priority; search_node = (Chain_Node *) search_thread; previous_node = search_node->previous; 6f40: e5943004 ldr r3, [r4, #4] the_node = (Chain_Node *) the_thread; the_node->next = search_node; 6f44: e5814000 str r4, [r1] the_node->previous = previous_node; 6f48: e5813004 str r3, [r1, #4] previous_node->next = the_node; search_node->previous = the_node; the_thread->Wait.queue = the_thread_queue; 6f4c: e5810044 str r0, [r1, #68] ; 0x44 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; 6f50: e5831000 str r1, [r3] search_node->previous = the_node; 6f54: e5841004 str r1, [r4, #4] the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); 6f58: ea000021 b 6fe4 <_Thread_queue_Enqueue_priority+0x154> return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; 6f5c: e5d86000 ldrb r6, [r8] 6f60: e2866001 add r6, r6, #1 static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 6f64: e10f5000 mrs r5, CPSR 6f68: e3854080 orr r4, r5, #128 ; 0x80 6f6c: e129f004 msr CPSR_fc, r4 _ISR_Disable( level ); search_thread = (Thread_Control *) header->last; 6f70: e59c4008 ldr r4, [ip, #8] while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) { 6f74: ea00000b b 6fa8 <_Thread_queue_Enqueue_priority+0x118> search_priority = search_thread->current_priority; 6f78: e5946014 ldr r6, [r4, #20] if ( priority >= search_priority ) 6f7c: e1530006 cmp r3, r6 6f80: 2a00000a bcs 6fb0 <_Thread_queue_Enqueue_priority+0x120> static inline void arm_interrupt_flash( uint32_t level ) { uint32_t arm_switch_reg; asm volatile ( 6f84: e10fa000 mrs sl, CPSR 6f88: e129f005 msr CPSR_fc, r5 6f8c: e129f00a msr CPSR_fc, sl 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) ) { 6f90: e594a010 ldr sl, [r4, #16] 6f94: e117000a tst r7, sl 6f98: 1a000001 bne 6fa4 <_Thread_queue_Enqueue_priority+0x114> static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 6f9c: e129f005 msr CPSR_fc, r5 6fa0: eaffffed b 6f5c <_Thread_queue_Enqueue_priority+0xcc> _ISR_Enable( level ); goto restart_reverse_search; } search_thread = (Thread_Control *) 6fa4: e5944004 ldr r4, [r4, #4] 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 ) ) { 6fa8: e154000c cmp r4, ip 6fac: 1afffff1 bne 6f78 <_Thread_queue_Enqueue_priority+0xe8> } search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state != 6fb0: e590c030 ldr ip, [r0, #48] ; 0x30 6fb4: e35c0001 cmp ip, #1 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 ) ) { 6fb8: e1a0c005 mov ip, r5 } search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state != 6fbc: 1a000014 bne 7014 <_Thread_queue_Enqueue_priority+0x184> THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; if ( priority == search_priority ) 6fc0: e1530006 cmp r3, r6 if ( the_thread_queue->sync_state != THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; 6fc4: e3a03000 mov r3, #0 6fc8: e5803030 str r3, [r0, #48] ; 0x30 if ( priority == search_priority ) 6fcc: 0a000006 beq 6fec <_Thread_queue_Enqueue_priority+0x15c> goto equal_priority; search_node = (Chain_Node *) search_thread; next_node = search_node->next; 6fd0: e5943000 ldr r3, [r4] the_node = (Chain_Node *) the_thread; the_node->next = next_node; the_node->previous = search_node; 6fd4: e8810018 stm r1, {r3, r4} search_node->next = the_node; next_node->previous = the_node; the_thread->Wait.queue = the_thread_queue; 6fd8: e5810044 str r0, [r1, #68] ; 0x44 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; 6fdc: e5841000 str r1, [r4] next_node->previous = the_node; 6fe0: e5831004 str r1, [r3, #4] 6fe4: e129f005 msr CPSR_fc, r5 6fe8: ea000007 b 700c <_Thread_queue_Enqueue_priority+0x17c> 6fec: e284403c add r4, r4, #60 ; 0x3c _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; 6ff0: e5943004 ldr r3, [r4, #4] the_node = (Chain_Node *) the_thread; the_node->next = search_node; 6ff4: e5814000 str r4, [r1] the_node->previous = previous_node; 6ff8: e5813004 str r3, [r1, #4] previous_node->next = the_node; search_node->previous = the_node; the_thread->Wait.queue = the_thread_queue; 6ffc: e5810044 str r0, [r1, #68] ; 0x44 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; 7000: e5831000 str r1, [r3] search_node->previous = the_node; 7004: e5841004 str r1, [r4, #4] 7008: e129f00c msr CPSR_fc, ip 700c: e3a00001 mov r0, #1 the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; 7010: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} * For example, the blocking thread could have been given * the mutex by an ISR or timed out. * * WARNING! Returning with interrupts disabled! */ *level_p = level; 7014: e582c000 str ip, [r2] return the_thread_queue->sync_state; 7018: e5900030 ldr r0, [r0, #48] ; 0x30 } 701c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 7020: 00017630 .word 0x00017630 00014a24 <_Timer_server_Body>: * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { 14a24: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 14a28: e24dd020 sub sp, sp, #32 14a2c: e28d3014 add r3, sp, #20 14a30: e28d5008 add r5, sp, #8 RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL; 14a34: e3a09000 mov r9, #0 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 14a38: e283a004 add sl, r3, #4 14a3c: e2858004 add r8, r5, #4 Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); 14a40: e58d301c str r3, [sp, #28] static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog ); 14a44: e2802008 add r2, r0, #8 static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog ); 14a48: e2803040 add r3, r0, #64 ; 0x40 */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 14a4c: e58da014 str sl, [sp, #20] the_chain->permanent_null = NULL; 14a50: e58d9018 str r9, [sp, #24] */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 14a54: e58d8008 str r8, [sp, #8] the_chain->permanent_null = NULL; 14a58: e58d900c str r9, [sp, #12] the_chain->last = _Chain_Head(the_chain); 14a5c: e58d5010 str r5, [sp, #16] static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog ); 14a60: e58d2004 str r2, [sp, #4] static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog ); 14a64: e58d3000 str r3, [sp] * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) { 14a68: e1a04000 mov r4, r0 */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); 14a6c: e280b030 add fp, r0, #48 ; 0x30 /* * 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 ); 14a70: e2807068 add r7, r0, #104 ; 0x68 { /* * 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; 14a74: e28d2014 add r2, sp, #20 14a78: e5842078 str r2, [r4, #120] ; 0x78 static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot; 14a7c: e59f2168 ldr r2, [pc, #360] ; 14bec <_Timer_server_Body+0x1c8> 14a80: e5923000 ldr r3, [r2] /* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; 14a84: e594103c ldr r1, [r4, #60] ; 0x3c watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); 14a88: e1a02005 mov r2, r5 14a8c: e0611003 rsb r1, r1, r3 /* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; 14a90: e584303c str r3, [r4, #60] ; 0x3c _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain ); 14a94: e1a0000b mov r0, fp 14a98: eb000ffd bl 18a94 <_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(); 14a9c: e59f314c ldr r3, [pc, #332] ; 14bf0 <_Timer_server_Body+0x1cc> Watchdog_Interval last_snapshot = watchdogs->last_snapshot; 14aa0: e5942074 ldr r2, [r4, #116] ; 0x74 static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch(); 14aa4: e5936000 ldr r6, [r3] /* * 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 ) { 14aa8: e1560002 cmp r6, r2 14aac: 9a000004 bls 14ac4 <_Timer_server_Body+0xa0> /* * 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 ); 14ab0: e0621006 rsb r1, r2, r6 14ab4: e1a00007 mov r0, r7 14ab8: e1a02005 mov r2, r5 14abc: eb000ff4 bl 18a94 <_Watchdog_Adjust_to_chain> 14ac0: ea000003 b 14ad4 <_Timer_server_Body+0xb0> /* * 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 ); 14ac4: 30662002 rsbcc r2, r6, r2 14ac8: 31a00007 movcc r0, r7 14acc: 33a01001 movcc r1, #1 14ad0: 3b000fc7 blcc 189f4 <_Watchdog_Adjust> } watchdogs->last_snapshot = snapshot; 14ad4: e5846074 str r6, [r4, #116] ; 0x74 } static void _Timer_server_Process_insertions( Timer_server_Control *ts ) { while ( true ) { Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain ); 14ad8: e5940078 ldr r0, [r4, #120] ; 0x78 14adc: eb000228 bl 15384 <_Chain_Get> if ( timer == NULL ) { 14ae0: e2501000 subs r1, r0, #0 14ae4: 0a00000a beq 14b14 <_Timer_server_Body+0xf0> static void _Timer_server_Insert_timer( Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { 14ae8: e5913038 ldr r3, [r1, #56] ; 0x38 14aec: e3530001 cmp r3, #1 _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); 14af0: 02811010 addeq r1, r1, #16 14af4: 01a0000b moveq r0, fp static void _Timer_server_Insert_timer( Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) { 14af8: 0a000003 beq 14b0c <_Timer_server_Body+0xe8> _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) { 14afc: e3530003 cmp r3, #3 14b00: 1afffff4 bne 14ad8 <_Timer_server_Body+0xb4> _Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker ); 14b04: e2811010 add r1, r1, #16 14b08: e1a00007 mov r0, r7 14b0c: eb00100d bl 18b48 <_Watchdog_Insert> 14b10: eafffff0 b 14ad8 <_Timer_server_Body+0xb4> static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 14b14: e10f3000 mrs r3, CPSR 14b18: e3832080 orr r2, r3, #128 ; 0x80 14b1c: e129f002 msr CPSR_fc, r2 * body loop. */ _Timer_server_Process_insertions( ts ); _ISR_Disable( level ); if ( _Chain_Is_empty( insert_chain ) ) { 14b20: e59d2014 ldr r2, [sp, #20] 14b24: e152000a cmp r2, sl 14b28: 1a000005 bne 14b44 <_Timer_server_Body+0x120> ts->insert_chain = NULL; 14b2c: e5841078 str r1, [r4, #120] ; 0x78 static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 14b30: e129f003 msr CPSR_fc, r3 _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 ) ) { 14b34: e59d3008 ldr r3, [sp, #8] 14b38: e1530008 cmp r3, r8 14b3c: 1a000002 bne 14b4c <_Timer_server_Body+0x128> 14b40: ea000015 b 14b9c <_Timer_server_Body+0x178> 14b44: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 14b48: eaffffcb b 14a7c <_Timer_server_Body+0x58> <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 14b4c: e10f2000 mrs r2, CPSR 14b50: e3823080 orr r3, r2, #128 ; 0x80 14b54: e129f003 msr CPSR_fc, r3 */ RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); 14b58: e59d3008 ldr r3, [sp, #8] */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) 14b5c: e1530008 cmp r3, r8 14b60: 0a00000b beq 14b94 <_Timer_server_Body+0x170> { Chain_Node *return_node; Chain_Node *new_first; return_node = the_chain->first; new_first = return_node->next; 14b64: e5931000 ldr r1, [r3] * It is essential that interrupts are disable here since an interrupt * service routine may remove a watchdog from the chain. */ _ISR_Disable( level ); watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain ); if ( watchdog != NULL ) { 14b68: e3530000 cmp r3, #0 the_chain->first = new_first; 14b6c: e58d1008 str r1, [sp, #8] new_first->previous = _Chain_Head(the_chain); 14b70: e5815004 str r5, [r1, #4] 14b74: 0a000006 beq 14b94 <_Timer_server_Body+0x170> watchdog->state = WATCHDOG_INACTIVE; 14b78: e5839008 str r9, [r3, #8] static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 14b7c: e129f002 msr CPSR_fc, r2 /* * 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 ); 14b80: e2830020 add r0, r3, #32 14b84: e8900003 ldm r0, {r0, r1} 14b88: e1a0e00f mov lr, pc 14b8c: e593f01c ldr pc, [r3, #28] } 14b90: eaffffed b 14b4c <_Timer_server_Body+0x128> 14b94: e129f002 msr CPSR_fc, r2 14b98: eaffffb5 b 14a74 <_Timer_server_Body+0x50> } else { ts->active = false; 14b9c: e5c4907c strb r9, [r4, #124] ; 0x7c 14ba0: e59f304c ldr r3, [pc, #76] ; 14bf4 <_Timer_server_Body+0x1d0> 14ba4: e5932000 ldr r2, [r3] 14ba8: e2822001 add r2, r2, #1 14bac: e5832000 str r2, [r3] /* * Block until there is something to do. */ _Thread_Disable_dispatch(); _Thread_Set_state( ts->thread, STATES_DELAYING ); 14bb0: e3a01008 mov r1, #8 14bb4: e5940000 ldr r0, [r4] 14bb8: eb000d42 bl 180c8 <_Thread_Set_state> _Timer_server_Reset_interval_system_watchdog( ts ); 14bbc: e1a00004 mov r0, r4 14bc0: ebffff6b bl 14974 <_Timer_server_Reset_interval_system_watchdog> _Timer_server_Reset_tod_system_watchdog( ts ); 14bc4: e1a00004 mov r0, r4 14bc8: ebffff7f bl 149cc <_Timer_server_Reset_tod_system_watchdog> _Thread_Enable_dispatch(); 14bcc: eb000aae bl 1768c <_Thread_Enable_dispatch> ts->active = true; 14bd0: e3a03001 mov r3, #1 14bd4: e5c4307c strb r3, [r4, #124] ; 0x7c static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog ); 14bd8: e59d0004 ldr r0, [sp, #4] 14bdc: eb001032 bl 18cac <_Watchdog_Remove> static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog ); 14be0: e59d0000 ldr r0, [sp] 14be4: eb001030 bl 18cac <_Watchdog_Remove> 14be8: eaffffa1 b 14a74 <_Timer_server_Body+0x50> 14bec: 00038864 .word 0x00038864 14bf0: 00038794 .word 0x00038794 14bf4: 0003870c .word 0x0003870c 00020930 <__kill>: #endif int __kill( pid_t pid, int sig ) { return 0; } 20930: e3a00000 mov r0, #0 <== NOT EXECUTED 20934: e12fff1e bx lr <== NOT EXECUTED 00016ca0 <_exit>: /* * If the toolset uses init/fini sections, then we need to * run the global destructors now. */ #if defined(__USE_INIT_FINI__) FINI_SYMBOL(); 16ca0: e1a04000 mov r4, r0 16ca4: eb000229 bl 17550 <___DTOR_END__> * We need to do the exit processing on the global reentrancy structure. * This has already been done on the per task reentrancy structure * associated with this task. */ libc_wrapup(); 16ca8: ebffffe0 bl 16c30 rtems_shutdown_executive(status); 16cac: e1a00004 mov r0, r4 16cb0: eb00003b bl 16da4 16cb4: eafffffe b 16cb4 <_exit+0x14> <== NOT EXECUTED 000332f0 <_fcntl_r>: int fd, int cmd, int arg ) { return fcntl( fd, cmd, arg ); 332f0: e1a00001 mov r0, r1 <== NOT EXECUTED 332f4: e1a01002 mov r1, r2 <== NOT EXECUTED 332f8: e1a02003 mov r2, r3 <== NOT EXECUTED 332fc: eaffff8b b 33130 <== NOT EXECUTED 00020910 <_getpid_r>: pid_t _getpid_r( struct _reent *ptr __attribute__((unused)) ) { return getpid(); } 20910: e3a00001 mov r0, #1 <== NOT EXECUTED 20914: e12fff1e bx lr <== NOT EXECUTED 000090bc <_gettimeofday>: int _gettimeofday( struct timeval *tp, struct timezone *tzp ) { return gettimeofday( tp, tzp ); 90bc: eaffffe8 b 9064 <== NOT EXECUTED 00020928 <_kill_r>: #include int _kill_r( struct _reent *ptr, pid_t pid, int sig ) { return 0; } 20928: e3a00000 mov r0, #0 <== NOT EXECUTED 2092c: e12fff1e bx lr <== NOT EXECUTED 00022ce8 <_link_r>: struct _reent *ptr __attribute__((unused)), const char *existing, const char *new ) { return link( existing, new ); 22ce8: e1a00001 mov r0, r1 <== NOT EXECUTED 22cec: e1a01002 mov r1, r2 <== NOT EXECUTED 22cf0: eaffff68 b 22a98 <== NOT EXECUTED 00022ee4 <_lstat_r>: struct _reent *ptr __attribute__((unused)), const char *path, struct stat *buf ) { return _STAT_NAME( path, buf ); 22ee4: e1a00001 mov r0, r1 <== NOT EXECUTED 22ee8: e1a01002 mov r1, r2 <== NOT EXECUTED 22eec: eaffffc4 b 22e04 <== NOT EXECUTED 00016d88 <_realloc_r>: struct _reent *ignored __attribute__((unused)), void *ptr, size_t size ) { return realloc( ptr, size ); 16d88: e1a00001 mov r0, r1 <== NOT EXECUTED 16d8c: e1a01002 mov r1, r2 <== NOT EXECUTED 16d90: ea00000e b 16dd0 <== NOT EXECUTED 00051d68 <_rename_r>: int _rename_r( struct _reent *ptr __attribute__((unused)), const char *old, const char *new ) { 51d68: e92d40f0 push {r4, r5, r6, r7, lr} <== NOT EXECUTED /* * Get the parent node of the old path to be renamed. Find the parent path. */ old_parent_pathlen = rtems_filesystem_dirname ( old ); 51d6c: e1a00001 mov r0, r1 <== NOT EXECUTED int _rename_r( struct _reent *ptr __attribute__((unused)), const char *old, const char *new ) { 51d70: e24dd044 sub sp, sp, #68 ; 0x44 <== NOT EXECUTED 51d74: e1a05001 mov r5, r1 <== NOT EXECUTED 51d78: e1a06002 mov r6, r2 <== NOT EXECUTED /* * Get the parent node of the old path to be renamed. Find the parent path. */ old_parent_pathlen = rtems_filesystem_dirname ( old ); 51d7c: ebfeca31 bl 4648 <== NOT EXECUTED if ( old_parent_pathlen == 0 ) 51d80: e2507000 subs r7, r0, #0 <== NOT EXECUTED 51d84: 1a000019 bne 51df0 <_rename_r+0x88> <== NOT EXECUTED rtems_filesystem_get_start_loc( old, &i, &old_parent_loc ); 51d88: e5d53000 ldrb r3, [r5] <== NOT EXECUTED 51d8c: e353002f cmp r3, #47 ; 0x2f <== NOT EXECUTED 51d90: 1353005c cmpne r3, #92 ; 0x5c <== NOT EXECUTED 51d94: 0a000001 beq 51da0 <_rename_r+0x38> <== NOT EXECUTED 51d98: e3530000 cmp r3, #0 <== NOT EXECUTED 51d9c: 1a000009 bne 51dc8 <_rename_r+0x60> <== NOT EXECUTED 51da0: e59f33ac ldr r3, [pc, #940] ; 52154 <_rename_r+0x3ec> <== NOT EXECUTED 51da4: e593e000 ldr lr, [r3] <== NOT EXECUTED 51da8: e28ee018 add lr, lr, #24 <== NOT EXECUTED 51dac: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 51db0: e28dc018 add ip, sp, #24 <== NOT EXECUTED 51db4: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 51db8: e59e3000 ldr r3, [lr] <== NOT EXECUTED 51dbc: e3a04000 mov r4, #0 <== NOT EXECUTED 51dc0: e58c3000 str r3, [ip] <== NOT EXECUTED 51dc4: ea000013 b 51e18 <_rename_r+0xb0> <== NOT EXECUTED 51dc8: e59f3384 ldr r3, [pc, #900] ; 52154 <_rename_r+0x3ec> <== NOT EXECUTED 51dcc: e593e000 ldr lr, [r3] <== NOT EXECUTED 51dd0: e28ee004 add lr, lr, #4 <== NOT EXECUTED 51dd4: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 51dd8: e28dc018 add ip, sp, #24 <== NOT EXECUTED 51ddc: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 51de0: e59e3000 ldr r3, [lr] <== NOT EXECUTED 51de4: e1a04007 mov r4, r7 <== NOT EXECUTED 51de8: e58c3000 str r3, [ip] <== NOT EXECUTED 51dec: ea000009 b 51e18 <_rename_r+0xb0> <== NOT EXECUTED else { result = rtems_filesystem_evaluate_path( old, old_parent_pathlen, 51df0: e3a0c000 mov ip, #0 <== NOT EXECUTED 51df4: e1a00005 mov r0, r5 <== NOT EXECUTED 51df8: e1a01007 mov r1, r7 <== NOT EXECUTED 51dfc: e3a02002 mov r2, #2 <== NOT EXECUTED 51e00: e28d3018 add r3, sp, #24 <== NOT EXECUTED 51e04: e58dc000 str ip, [sp] <== NOT EXECUTED 51e08: ebfeca56 bl 4768 <== NOT EXECUTED RTEMS_LIBIO_PERMS_WRITE, &old_parent_loc, false ); if ( result != 0 ) 51e0c: e3500000 cmp r0, #0 <== NOT EXECUTED 51e10: 03a04001 moveq r4, #1 <== NOT EXECUTED 51e14: 1a000025 bne 51eb0 <_rename_r+0x148> <== NOT EXECUTED /* * Start from the parent to find the node that should be under it. */ old_loc = old_parent_loc; 51e18: e28de018 add lr, sp, #24 <== NOT EXECUTED 51e1c: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 51e20: e28dc02c add ip, sp, #44 ; 0x2c <== NOT EXECUTED 51e24: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 51e28: e59e3000 ldr r3, [lr] <== NOT EXECUTED name = old + old_parent_pathlen; 51e2c: e0855007 add r5, r5, r7 <== NOT EXECUTED /* * Start from the parent to find the node that should be under it. */ old_loc = old_parent_loc; 51e30: e58c3000 str r3, [ip] <== NOT EXECUTED name = old + old_parent_pathlen; name += rtems_filesystem_prefix_separators( name, strlen( name ) ); 51e34: e1a00005 mov r0, r5 <== NOT EXECUTED /* * Start from the parent to find the node that should be under it. */ old_loc = old_parent_loc; name = old + old_parent_pathlen; 51e38: e58d5040 str r5, [sp, #64] ; 0x40 <== NOT EXECUTED name += rtems_filesystem_prefix_separators( name, strlen( name ) ); 51e3c: ebffb357 bl 3eba0 <== NOT EXECUTED 51e40: e1a01000 mov r1, r0 <== NOT EXECUTED 51e44: e1a00005 mov r0, r5 <== NOT EXECUTED 51e48: ebfec9f2 bl 4618 <== NOT EXECUTED 51e4c: e0855000 add r5, r5, r0 <== NOT EXECUTED result = rtems_filesystem_evaluate_relative_path( name , strlen( name ), 51e50: e1a00005 mov r0, r5 <== NOT EXECUTED * Start from the parent to find the node that should be under it. */ old_loc = old_parent_loc; name = old + old_parent_pathlen; name += rtems_filesystem_prefix_separators( name, strlen( name ) ); 51e54: e58d5040 str r5, [sp, #64] ; 0x40 <== NOT EXECUTED result = rtems_filesystem_evaluate_relative_path( name , strlen( name ), 51e58: ebffb350 bl 3eba0 <== NOT EXECUTED 51e5c: e3a0c000 mov ip, #0 <== NOT EXECUTED 51e60: e1a01000 mov r1, r0 <== NOT EXECUTED 51e64: e1a0200c mov r2, ip <== NOT EXECUTED 51e68: e1a00005 mov r0, r5 <== NOT EXECUTED 51e6c: e28d302c add r3, sp, #44 ; 0x2c <== NOT EXECUTED 51e70: e58dc000 str ip, [sp] <== NOT EXECUTED 51e74: ebfeca03 bl 4688 <== NOT EXECUTED 0, &old_loc, false ); if ( result != 0 ) { 51e78: e2505000 subs r5, r0, #0 <== NOT EXECUTED 51e7c: 0a00000d beq 51eb8 <_rename_r+0x150> <== NOT EXECUTED if ( free_old_parentloc ) 51e80: e3540000 cmp r4, #0 <== NOT EXECUTED 51e84: 0a000007 beq 51ea8 <_rename_r+0x140> <== NOT EXECUTED rtems_filesystem_freenode( &old_parent_loc ); 51e88: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 51e8c: e3530000 cmp r3, #0 <== NOT EXECUTED 51e90: 0a000004 beq 51ea8 <_rename_r+0x140> <== NOT EXECUTED 51e94: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 51e98: e3530000 cmp r3, #0 <== NOT EXECUTED 51e9c: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 51ea0: 11a0e00f movne lr, pc <== NOT EXECUTED 51ea4: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( result ); 51ea8: ebff98c2 bl 381b8 <__errno> <== NOT EXECUTED 51eac: e5805000 str r5, [r0] <== NOT EXECUTED 51eb0: e3e06000 mvn r6, #0 <== NOT EXECUTED 51eb4: ea0000a3 b 52148 <_rename_r+0x3e0> <== NOT EXECUTED /* * Get the parent of the new node we are renaming to. */ rtems_filesystem_get_start_loc( new, &i, &new_parent_loc ); 51eb8: e5d63000 ldrb r3, [r6] <== NOT EXECUTED 51ebc: e353002f cmp r3, #47 ; 0x2f <== NOT EXECUTED 51ec0: 1353005c cmpne r3, #92 ; 0x5c <== NOT EXECUTED 51ec4: 13a05000 movne r5, #0 <== NOT EXECUTED 51ec8: 03a05001 moveq r5, #1 <== NOT EXECUTED 51ecc: 0a000001 beq 51ed8 <_rename_r+0x170> <== NOT EXECUTED 51ed0: e3530000 cmp r3, #0 <== NOT EXECUTED 51ed4: 1a000009 bne 51f00 <_rename_r+0x198> <== NOT EXECUTED 51ed8: e59f3274 ldr r3, [pc, #628] ; 52154 <_rename_r+0x3ec> <== NOT EXECUTED 51edc: e593e000 ldr lr, [r3] <== NOT EXECUTED 51ee0: e28ee018 add lr, lr, #24 <== NOT EXECUTED 51ee4: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 51ee8: e28dc004 add ip, sp, #4 <== NOT EXECUTED 51eec: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 51ef0: e59e3000 ldr r3, [lr] <== NOT EXECUTED 51ef4: e3a00001 mov r0, #1 <== NOT EXECUTED 51ef8: e58c3000 str r3, [ip] <== NOT EXECUTED 51efc: ea000008 b 51f24 <_rename_r+0x1bc> <== NOT EXECUTED 51f00: e59f324c ldr r3, [pc, #588] ; 52154 <_rename_r+0x3ec> <== NOT EXECUTED 51f04: e593e000 ldr lr, [r3] <== NOT EXECUTED 51f08: e28ee004 add lr, lr, #4 <== NOT EXECUTED 51f0c: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 51f10: e28dc004 add ip, sp, #4 <== NOT EXECUTED 51f14: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 51f18: e59e3000 ldr r3, [lr] <== NOT EXECUTED 51f1c: e58c3000 str r3, [ip] <== NOT EXECUTED 51f20: e1a00005 mov r0, r5 <== NOT EXECUTED if ( !new_parent_loc.ops->evalformake_h ) { 51f24: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 51f28: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED 51f2c: e3530000 cmp r3, #0 <== NOT EXECUTED 51f30: 0a00004d beq 5206c <_rename_r+0x304> <== NOT EXECUTED rtems_filesystem_freenode( &old_parent_loc ); rtems_filesystem_freenode( &old_loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*new_parent_loc.ops->evalformake_h)( &new[i], &new_parent_loc, &name ); 51f34: e28d5004 add r5, sp, #4 <== NOT EXECUTED 51f38: e0860000 add r0, r6, r0 <== NOT EXECUTED 51f3c: e1a01005 mov r1, r5 <== NOT EXECUTED 51f40: e28d2040 add r2, sp, #64 ; 0x40 <== NOT EXECUTED 51f44: e1a0e00f mov lr, pc <== NOT EXECUTED 51f48: e12fff13 bx r3 <== NOT EXECUTED if ( result != 0 ) { 51f4c: e2506000 subs r6, r0, #0 <== NOT EXECUTED 51f50: 0a00001c beq 51fc8 <_rename_r+0x260> <== NOT EXECUTED rtems_filesystem_freenode( &new_parent_loc ); 51f54: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 51f58: e3530000 cmp r3, #0 <== NOT EXECUTED 51f5c: 0a000004 beq 51f74 <_rename_r+0x20c> <== NOT EXECUTED 51f60: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 51f64: e3530000 cmp r3, #0 <== NOT EXECUTED 51f68: 11a00005 movne r0, r5 <== NOT EXECUTED 51f6c: 11a0e00f movne lr, pc <== NOT EXECUTED 51f70: 112fff13 bxne r3 <== NOT EXECUTED if ( free_old_parentloc ) 51f74: e3540000 cmp r4, #0 <== NOT EXECUTED 51f78: 0a000007 beq 51f9c <_rename_r+0x234> <== NOT EXECUTED rtems_filesystem_freenode( &old_parent_loc ); 51f7c: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 51f80: e3530000 cmp r3, #0 <== NOT EXECUTED 51f84: 0a000004 beq 51f9c <_rename_r+0x234> <== NOT EXECUTED 51f88: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 51f8c: e3530000 cmp r3, #0 <== NOT EXECUTED 51f90: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 51f94: 11a0e00f movne lr, pc <== NOT EXECUTED 51f98: 112fff13 bxne r3 <== NOT EXECUTED rtems_filesystem_freenode( &old_loc ); 51f9c: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED 51fa0: e3530000 cmp r3, #0 <== NOT EXECUTED 51fa4: 0a000004 beq 51fbc <_rename_r+0x254> <== NOT EXECUTED 51fa8: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 51fac: e3530000 cmp r3, #0 <== NOT EXECUTED 51fb0: 128d002c addne r0, sp, #44 ; 0x2c <== NOT EXECUTED 51fb4: 11a0e00f movne lr, pc <== NOT EXECUTED 51fb8: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( result ); 51fbc: ebff987d bl 381b8 <__errno> <== NOT EXECUTED 51fc0: e5806000 str r6, [r0] <== NOT EXECUTED 51fc4: eaffffb9 b 51eb0 <_rename_r+0x148> <== NOT EXECUTED /* * Check to see if the caller is trying to rename across file system * boundaries. */ if ( old_parent_loc.mt_entry != new_parent_loc.mt_entry ) { 51fc8: e59d3014 ldr r3, [sp, #20] <== NOT EXECUTED 51fcc: e59d2028 ldr r2, [sp, #40] ; 0x28 <== NOT EXECUTED 51fd0: e1520003 cmp r2, r3 <== NOT EXECUTED 51fd4: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 51fd8: 0a00001b beq 5204c <_rename_r+0x2e4> <== NOT EXECUTED rtems_filesystem_freenode( &new_parent_loc ); 51fdc: e3530000 cmp r3, #0 <== NOT EXECUTED 51fe0: 0a000004 beq 51ff8 <_rename_r+0x290> <== NOT EXECUTED 51fe4: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 51fe8: e3530000 cmp r3, #0 <== NOT EXECUTED 51fec: 11a00005 movne r0, r5 <== NOT EXECUTED 51ff0: 11a0e00f movne lr, pc <== NOT EXECUTED 51ff4: 112fff13 bxne r3 <== NOT EXECUTED if ( free_old_parentloc ) 51ff8: e3540000 cmp r4, #0 <== NOT EXECUTED 51ffc: 0a000007 beq 52020 <_rename_r+0x2b8> <== NOT EXECUTED rtems_filesystem_freenode( &old_parent_loc ); 52000: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 52004: e3530000 cmp r3, #0 <== NOT EXECUTED 52008: 0a000004 beq 52020 <_rename_r+0x2b8> <== NOT EXECUTED 5200c: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 52010: e3530000 cmp r3, #0 <== NOT EXECUTED 52014: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 52018: 11a0e00f movne lr, pc <== NOT EXECUTED 5201c: 112fff13 bxne r3 <== NOT EXECUTED rtems_filesystem_freenode( &old_loc ); 52020: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED 52024: e3530000 cmp r3, #0 <== NOT EXECUTED 52028: 0a000004 beq 52040 <_rename_r+0x2d8> <== NOT EXECUTED 5202c: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 52030: e3530000 cmp r3, #0 <== NOT EXECUTED 52034: 128d002c addne r0, sp, #44 ; 0x2c <== NOT EXECUTED 52038: 11a0e00f movne lr, pc <== NOT EXECUTED 5203c: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EXDEV ); 52040: ebff985c bl 381b8 <__errno> <== NOT EXECUTED 52044: e3a03012 mov r3, #18 <== NOT EXECUTED 52048: ea00001b b 520bc <_rename_r+0x354> <== NOT EXECUTED } if ( !new_parent_loc.ops->rename_h ) { 5204c: e593c040 ldr ip, [r3, #64] ; 0x40 <== NOT EXECUTED 52050: e35c0000 cmp ip, #0 <== NOT EXECUTED 52054: 1a00001a bne 520c4 <_rename_r+0x35c> <== NOT EXECUTED rtems_filesystem_freenode( &new_parent_loc ); 52058: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 5205c: e3530000 cmp r3, #0 <== NOT EXECUTED 52060: 11a00005 movne r0, r5 <== NOT EXECUTED 52064: 11a0e00f movne lr, pc <== NOT EXECUTED 52068: 112fff13 bxne r3 <== NOT EXECUTED if ( free_old_parentloc ) 5206c: e3540000 cmp r4, #0 <== NOT EXECUTED 52070: 0a000007 beq 52094 <_rename_r+0x32c> <== NOT EXECUTED rtems_filesystem_freenode( &old_parent_loc ); 52074: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 52078: e3530000 cmp r3, #0 <== NOT EXECUTED 5207c: 0a000004 beq 52094 <_rename_r+0x32c> <== NOT EXECUTED 52080: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 52084: e3530000 cmp r3, #0 <== NOT EXECUTED 52088: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 5208c: 11a0e00f movne lr, pc <== NOT EXECUTED 52090: 112fff13 bxne r3 <== NOT EXECUTED rtems_filesystem_freenode( &old_loc ); 52094: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED 52098: e3530000 cmp r3, #0 <== NOT EXECUTED 5209c: 0a000004 beq 520b4 <_rename_r+0x34c> <== NOT EXECUTED 520a0: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 520a4: e3530000 cmp r3, #0 <== NOT EXECUTED 520a8: 128d002c addne r0, sp, #44 ; 0x2c <== NOT EXECUTED 520ac: 11a0e00f movne lr, pc <== NOT EXECUTED 520b0: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 520b4: ebff983f bl 381b8 <__errno> <== NOT EXECUTED 520b8: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 520bc: e5803000 str r3, [r0] <== NOT EXECUTED 520c0: eaffff7a b 51eb0 <_rename_r+0x148> <== NOT EXECUTED } result = (*new_parent_loc.ops->rename_h)( &old_parent_loc, &old_loc, &new_parent_loc, name ); 520c4: e59d3040 ldr r3, [sp, #64] ; 0x40 <== NOT EXECUTED 520c8: e28d0018 add r0, sp, #24 <== NOT EXECUTED 520cc: e28d102c add r1, sp, #44 ; 0x2c <== NOT EXECUTED 520d0: e1a02005 mov r2, r5 <== NOT EXECUTED 520d4: e1a0e00f mov lr, pc <== NOT EXECUTED 520d8: e12fff1c bx ip <== NOT EXECUTED rtems_filesystem_freenode( &new_parent_loc ); 520dc: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 520e0: e3530000 cmp r3, #0 <== NOT EXECUTED rtems_filesystem_freenode( &old_parent_loc ); rtems_filesystem_freenode( &old_loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*new_parent_loc.ops->rename_h)( &old_parent_loc, &old_loc, &new_parent_loc, name ); 520e4: e1a06000 mov r6, r0 <== NOT EXECUTED rtems_filesystem_freenode( &new_parent_loc ); 520e8: 0a000004 beq 52100 <_rename_r+0x398> <== NOT EXECUTED 520ec: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 520f0: e3530000 cmp r3, #0 <== NOT EXECUTED 520f4: 11a00005 movne r0, r5 <== NOT EXECUTED 520f8: 11a0e00f movne lr, pc <== NOT EXECUTED 520fc: 112fff13 bxne r3 <== NOT EXECUTED if ( free_old_parentloc ) 52100: e3540000 cmp r4, #0 <== NOT EXECUTED 52104: 0a000007 beq 52128 <_rename_r+0x3c0> <== NOT EXECUTED rtems_filesystem_freenode( &old_parent_loc ); 52108: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 5210c: e3530000 cmp r3, #0 <== NOT EXECUTED 52110: 0a000004 beq 52128 <_rename_r+0x3c0> <== NOT EXECUTED 52114: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 52118: e3530000 cmp r3, #0 <== NOT EXECUTED 5211c: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 52120: 11a0e00f movne lr, pc <== NOT EXECUTED 52124: 112fff13 bxne r3 <== NOT EXECUTED rtems_filesystem_freenode( &old_loc ); 52128: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED 5212c: e3530000 cmp r3, #0 <== NOT EXECUTED 52130: 0a000004 beq 52148 <_rename_r+0x3e0> <== NOT EXECUTED 52134: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 52138: e3530000 cmp r3, #0 <== NOT EXECUTED 5213c: 128d002c addne r0, sp, #44 ; 0x2c <== NOT EXECUTED 52140: 11a0e00f movne lr, pc <== NOT EXECUTED 52144: 112fff13 bxne r3 <== NOT EXECUTED return result; } 52148: e1a00006 mov r0, r6 <== NOT EXECUTED 5214c: e28dd044 add sp, sp, #68 ; 0x44 <== NOT EXECUTED 52150: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED 52154: 00052578 .word 0x00052578 00005c34 <_stat_r>: struct _reent *ptr __attribute__((unused)), const char *path, struct stat *buf ) { return _STAT_NAME( path, buf ); 5c34: e1a00001 mov r0, r1 <== NOT EXECUTED 5c38: e1a01002 mov r1, r2 <== NOT EXECUTED 5c3c: eaffffc4 b 5b54 <== NOT EXECUTED 0000bac4 <_unlink_r>: int _unlink_r( struct _reent *ptr __attribute__((unused)), const char *path ) { return unlink( path ); bac4: e1a00001 mov r0, r1 <== NOT EXECUTED bac8: eaffff5c b b840 <== NOT EXECUTED 00021854 : #include int chdir( const char *pathname ) { 21854: e92d4030 push {r4, r5, lr} rtems_filesystem_location_info_t loc; int result; if ( !pathname ) 21858: e2505000 subs r5, r0, #0 #include int chdir( const char *pathname ) { 2185c: e24dd018 sub sp, sp, #24 rtems_filesystem_location_info_t loc; int result; if ( !pathname ) 21860: 1a000002 bne 21870 rtems_set_errno_and_return_minus_one( EFAULT ); 21864: eb005a53 bl 381b8 <__errno> 21868: e3a0300e mov r3, #14 2186c: ea000025 b 21908 /* * Get the node where we wish to go. */ result = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true ); 21870: eb0074ca bl 3eba0 rtems_set_errno_and_return_minus_one( EFAULT ); /* * Get the node where we wish to go. */ result = rtems_filesystem_evaluate_path( 21874: e28d4004 add r4, sp, #4 21878: e3a0c001 mov ip, #1 pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true ); 2187c: e1a01000 mov r1, r0 rtems_set_errno_and_return_minus_one( EFAULT ); /* * Get the node where we wish to go. */ result = rtems_filesystem_evaluate_path( 21880: e1a0200c mov r2, ip 21884: e1a00005 mov r0, r5 21888: e1a03004 mov r3, r4 2188c: e58dc000 str ip, [sp] 21890: ebff8bb4 bl 4768 pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true ); if ( result != 0 ) 21894: e3500000 cmp r0, #0 21898: 1a00001b bne 2190c return -1; /* * Verify you can change directory into this node. */ if ( !loc.ops->node_type_h ) { 2189c: e59d2010 ldr r2, [sp, #16] 218a0: e5923010 ldr r3, [r2, #16] 218a4: e3530000 cmp r3, #0 218a8: 1a000007 bne 218cc rtems_filesystem_freenode( &loc ); 218ac: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 218b0: e3530000 cmp r3, #0 <== NOT EXECUTED 218b4: 11a00004 movne r0, r4 <== NOT EXECUTED 218b8: 11a0e00f movne lr, pc <== NOT EXECUTED 218bc: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 218c0: eb005a3c bl 381b8 <__errno> <== NOT EXECUTED 218c4: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 218c8: ea00000e b 21908 <== NOT EXECUTED } if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) { 218cc: e1a00004 mov r0, r4 218d0: e1a0e00f mov lr, pc 218d4: e12fff13 bx r3 218d8: e3500001 cmp r0, #1 218dc: 0a00000c beq 21914 rtems_filesystem_freenode( &loc ); 218e0: e59d3010 ldr r3, [sp, #16] 218e4: e3530000 cmp r3, #0 218e8: 0a000004 beq 21900 218ec: e593301c ldr r3, [r3, #28] 218f0: e3530000 cmp r3, #0 218f4: 11a00004 movne r0, r4 218f8: 11a0e00f movne lr, pc 218fc: 112fff13 bxne r3 rtems_set_errno_and_return_minus_one( ENOTDIR ); 21900: eb005a2c bl 381b8 <__errno> 21904: e3a03014 mov r3, #20 21908: e5803000 str r3, [r0] 2190c: e3e00000 mvn r0, #0 21910: ea000012 b 21960 } rtems_filesystem_freenode( &rtems_filesystem_current ); 21914: e59f304c ldr r3, [pc, #76] ; 21968 21918: e5930000 ldr r0, [r3] 2191c: e5903010 ldr r3, [r0, #16] 21920: e3530000 cmp r3, #0 21924: 0a000004 beq 2193c 21928: e593301c ldr r3, [r3, #28] 2192c: e3530000 cmp r3, #0 21930: 12800004 addne r0, r0, #4 21934: 11a0e00f movne lr, pc 21938: 112fff13 bxne r3 rtems_filesystem_current = loc; 2193c: e59f3024 ldr r3, [pc, #36] ; 21968 21940: e28d4004 add r4, sp, #4 21944: e593c000 ldr ip, [r3] 21948: e8b4000f ldm r4!, {r0, r1, r2, r3} 2194c: e28cc004 add ip, ip, #4 21950: e8ac000f stmia ip!, {r0, r1, r2, r3} 21954: e5943000 ldr r3, [r4] 21958: e58c3000 str r3, [ip] 2195c: e3a00000 mov r0, #0 return 0; } 21960: e28dd018 add sp, sp, #24 21964: e8bd8030 pop {r4, r5, pc} 21968: 00052578 .word 0x00052578 00004480 : int chmod( const char *path, mode_t mode ) { 4480: e92d4070 push {r4, r5, r6, lr} 4484: e24dd018 sub sp, sp, #24 4488: e1a05001 mov r5, r1 448c: e1a06000 mov r6, r0 int status; rtems_filesystem_location_info_t loc; int result; status = rtems_filesystem_evaluate_path( path, strlen( path ), 0, &loc, true ); 4490: eb00e9c2 bl 3eba0 4494: e28d4004 add r4, sp, #4 4498: e1a01000 mov r1, r0 449c: e3a0c001 mov ip, #1 44a0: e1a00006 mov r0, r6 44a4: e3a02000 mov r2, #0 44a8: e1a03004 mov r3, r4 44ac: e58dc000 str ip, [sp] 44b0: eb0000ac bl 4768 if ( status != 0 ) 44b4: e3500000 cmp r0, #0 44b8: 1a00000d bne 44f4 return -1; if ( !loc.handlers ){ 44bc: e59d300c ldr r3, [sp, #12] 44c0: e3530000 cmp r3, #0 44c4: 1a00000c bne 44fc rtems_filesystem_freenode( &loc ); 44c8: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 44cc: e3530000 cmp r3, #0 <== NOT EXECUTED 44d0: 0a000004 beq 44e8 <== NOT EXECUTED 44d4: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 44d8: e3530000 cmp r3, #0 <== NOT EXECUTED 44dc: 11a00004 movne r0, r4 <== NOT EXECUTED 44e0: 11a0e00f movne lr, pc <== NOT EXECUTED 44e4: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EBADF ); 44e8: eb00cf32 bl 381b8 <__errno> <== NOT EXECUTED 44ec: e3a03009 mov r3, #9 <== NOT EXECUTED 44f0: e5803000 str r3, [r0] <== NOT EXECUTED 44f4: e3e05000 mvn r5, #0 44f8: ea00001a b 4568 } if ( !loc.handlers->fchmod_h ){ 44fc: e593301c ldr r3, [r3, #28] 4500: e3530000 cmp r3, #0 4504: 1a00000a bne 4534 rtems_filesystem_freenode( &loc ); 4508: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 450c: e3530000 cmp r3, #0 <== NOT EXECUTED 4510: 0a000004 beq 4528 <== NOT EXECUTED 4514: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 4518: e3530000 cmp r3, #0 <== NOT EXECUTED 451c: 11a00004 movne r0, r4 <== NOT EXECUTED 4520: 11a0e00f movne lr, pc <== NOT EXECUTED 4524: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 4528: eb00cf22 bl 381b8 <__errno> <== NOT EXECUTED 452c: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 4530: eaffffee b 44f0 <== NOT EXECUTED } result = (*loc.handlers->fchmod_h)( &loc, mode ); 4534: e1a01005 mov r1, r5 4538: e1a00004 mov r0, r4 453c: e1a0e00f mov lr, pc 4540: e12fff13 bx r3 rtems_filesystem_freenode( &loc ); 4544: e59d3010 ldr r3, [sp, #16] 4548: e3530000 cmp r3, #0 if ( !loc.handlers->fchmod_h ){ rtems_filesystem_freenode( &loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.handlers->fchmod_h)( &loc, mode ); 454c: e1a05000 mov r5, r0 rtems_filesystem_freenode( &loc ); 4550: 0a000004 beq 4568 4554: e593301c ldr r3, [r3, #28] 4558: e3530000 cmp r3, #0 455c: 11a00004 movne r0, r4 4560: 11a0e00f movne lr, pc 4564: 112fff13 bxne r3 return result; } 4568: e1a00005 mov r0, r5 456c: e28dd018 add sp, sp, #24 4570: e8bd8070 pop {r4, r5, r6, pc} 0002196c : int chown( const char *path, uid_t owner, gid_t group ) { 2196c: e92d40f0 push {r4, r5, r6, r7, lr} 21970: e1a01801 lsl r1, r1, #16 21974: e24dd018 sub sp, sp, #24 21978: e1a02802 lsl r2, r2, #16 2197c: e1a06821 lsr r6, r1, #16 21980: e1a05822 lsr r5, r2, #16 21984: e1a07000 mov r7, r0 rtems_filesystem_location_info_t loc; int result; if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x00, &loc, true ) ) 21988: eb007484 bl 3eba0 2198c: e28d4004 add r4, sp, #4 21990: e1a01000 mov r1, r0 21994: e3a0c001 mov ip, #1 21998: e1a00007 mov r0, r7 2199c: e3a02000 mov r2, #0 219a0: e1a03004 mov r3, r4 219a4: e58dc000 str ip, [sp] 219a8: ebff8b6e bl 4768 219ac: e3500000 cmp r0, #0 219b0: 1a00000b bne 219e4 return -1; if ( !loc.ops->chown_h ) { 219b4: e59d2010 ldr r2, [sp, #16] 219b8: e5923018 ldr r3, [r2, #24] 219bc: e3530000 cmp r3, #0 219c0: 1a000009 bne 219ec rtems_filesystem_freenode( &loc ); 219c4: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 219c8: e3530000 cmp r3, #0 <== NOT EXECUTED 219cc: 11a00004 movne r0, r4 <== NOT EXECUTED 219d0: 11a0e00f movne lr, pc <== NOT EXECUTED 219d4: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 219d8: eb0059f6 bl 381b8 <__errno> <== NOT EXECUTED 219dc: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 219e0: e5803000 str r3, [r0] <== NOT EXECUTED 219e4: e3e05000 mvn r5, #0 219e8: ea00000d b 21a24 } result = (*loc.ops->chown_h)( &loc, owner, group ); 219ec: e1a02005 mov r2, r5 219f0: e1a01006 mov r1, r6 219f4: e1a00004 mov r0, r4 219f8: e1a0e00f mov lr, pc 219fc: e12fff13 bx r3 rtems_filesystem_freenode( &loc ); 21a00: e59d3010 ldr r3, [sp, #16] 21a04: e3530000 cmp r3, #0 if ( !loc.ops->chown_h ) { rtems_filesystem_freenode( &loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->chown_h)( &loc, owner, group ); 21a08: e1a05000 mov r5, r0 rtems_filesystem_freenode( &loc ); 21a0c: 0a000004 beq 21a24 21a10: e593301c ldr r3, [r3, #28] 21a14: e3530000 cmp r3, #0 21a18: 11a00004 movne r0, r4 21a1c: 11a0e00f movne lr, pc 21a20: 112fff13 bxne r3 return result; } 21a24: e1a00005 mov r0, r5 21a28: e28dd018 add sp, sp, #24 21a2c: e8bd80f0 pop {r4, r5, r6, r7, pc} 00021a30 : #include int chroot( const char *pathname ) { 21a30: e92d4070 push {r4, r5, r6, lr} int result; rtems_filesystem_location_info_t loc; /* an automatic call to new private env the first time */ if (rtems_current_user_env == &rtems_global_user_env) { 21a34: e59f50d4 ldr r5, [pc, #212] ; 21b10 21a38: e59f30d4 ldr r3, [pc, #212] ; 21b14 21a3c: e5954000 ldr r4, [r5] 21a40: e1540003 cmp r4, r3 #include int chroot( const char *pathname ) { 21a44: e24dd018 sub sp, sp, #24 21a48: e1a06000 mov r6, r0 int result; rtems_filesystem_location_info_t loc; /* an automatic call to new private env the first time */ if (rtems_current_user_env == &rtems_global_user_env) { 21a4c: 1a000007 bne 21a70 rtems_libio_set_private_env(); /* try to set a new private env*/ 21a50: eb0005d8 bl 231b8 if (rtems_current_user_env == &rtems_global_user_env) /* not ok */ 21a54: e5953000 ldr r3, [r5] 21a58: e1530004 cmp r3, r4 21a5c: 1a000003 bne 21a70 rtems_set_errno_and_return_minus_one( ENOTSUP ); 21a60: eb0059d4 bl 381b8 <__errno> <== NOT EXECUTED 21a64: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 21a68: e5803000 str r3, [r0] <== NOT EXECUTED 21a6c: ea000008 b 21a94 <== NOT EXECUTED } result = chdir(pathname); 21a70: e1a00006 mov r0, r6 21a74: ebffff76 bl 21854 if (result) { 21a78: e250c000 subs ip, r0, #0 21a7c: 0a000006 beq 21a9c rtems_set_errno_and_return_minus_one( errno ); 21a80: eb0059cc bl 381b8 <__errno> <== NOT EXECUTED 21a84: e1a04000 mov r4, r0 <== NOT EXECUTED 21a88: eb0059ca bl 381b8 <__errno> <== NOT EXECUTED 21a8c: e5903000 ldr r3, [r0] <== NOT EXECUTED 21a90: e5843000 str r3, [r4] <== NOT EXECUTED 21a94: e3e00000 mvn r0, #0 <== NOT EXECUTED 21a98: ea00001a b 21b08 <== NOT EXECUTED } /* clone the new root location */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) { 21a9c: e1a0200c mov r2, ip 21aa0: e59f0070 ldr r0, [pc, #112] ; 21b18 21aa4: e3a01001 mov r1, #1 21aa8: e28d3004 add r3, sp, #4 21aac: e58dc000 str ip, [sp] 21ab0: ebff8b2c bl 4768 21ab4: e3500000 cmp r0, #0 21ab8: 1afffff0 bne 21a80 /* our cwd has changed, though - but there is no easy way of return :-( */ rtems_set_errno_and_return_minus_one( errno ); } rtems_filesystem_freenode(&rtems_filesystem_root); 21abc: e59f304c ldr r3, [pc, #76] ; 21b10 21ac0: e5930000 ldr r0, [r3] 21ac4: e5903024 ldr r3, [r0, #36] ; 0x24 21ac8: e3530000 cmp r3, #0 21acc: 0a000004 beq 21ae4 21ad0: e593301c ldr r3, [r3, #28] 21ad4: e3530000 cmp r3, #0 21ad8: 12800018 addne r0, r0, #24 21adc: 11a0e00f movne lr, pc 21ae0: 112fff13 bxne r3 rtems_filesystem_root = loc; 21ae4: e59f3024 ldr r3, [pc, #36] ; 21b10 21ae8: e28d4004 add r4, sp, #4 21aec: e593c000 ldr ip, [r3] 21af0: e8b4000f ldm r4!, {r0, r1, r2, r3} 21af4: e28cc018 add ip, ip, #24 21af8: e8ac000f stmia ip!, {r0, r1, r2, r3} 21afc: e5943000 ldr r3, [r4] 21b00: e58c3000 str r3, [ip] 21b04: e3a00000 mov r0, #0 return 0; } 21b08: e28dd018 add sp, sp, #24 21b0c: e8bd8070 pop {r4, r5, r6, pc} 21b10: 00052578 .word 0x00052578 21b14: 0005fc2c .word 0x0005fc2c 21b18: 00057998 .word 0x00057998 00007fa4 : const char *pathname, int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc ) { 7fa4: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } /* get the device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; 7fa8: e5935000 ldr r5, [r3] if (!device_name_table) 7fac: e3550000 cmp r5, #0 const char *pathname, int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc ) { 7fb0: e1a04003 mov r4, r3 7fb4: e1a09000 mov r9, r0 7fb8: e1a08001 mov r8, r1 rtems_set_errno_and_return_minus_one( EIO ); } /* get the device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; if (!device_name_table) 7fbc: 13a06000 movne r6, #0 rtems_set_errno_and_return_minus_one( EFAULT ); for (i = 0; i < rtems_device_table_size; i++) { 7fc0: 159fa090 ldrne sl, [pc, #144] ; 8058 rtems_set_errno_and_return_minus_one( EIO ); } /* get the device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; if (!device_name_table) 7fc4: 1a000019 bne 8030 rtems_set_errno_and_return_minus_one( EFAULT ); 7fc8: eb000601 bl 97d4 <__errno> <== NOT EXECUTED 7fcc: e3a0300e mov r3, #14 <== NOT EXECUTED 7fd0: e5803000 str r3, [r0] <== NOT EXECUTED 7fd4: e3e00000 mvn r0, #0 <== NOT EXECUTED 7fd8: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED for (i = 0; i < rtems_device_table_size; i++) { if (!device_name_table[i].device_name) 7fdc: e5957000 ldr r7, [r5] 7fe0: e2571000 subs r1, r7, #0 7fe4: 0a00000f beq 8028 continue; if (strncmp(pathname, device_name_table[i].device_name, pathnamelen) != 0) 7fe8: eb0009af bl a6ac 7fec: e3500000 cmp r0, #0 7ff0: 1a00000c bne 8028 continue; if (device_name_table[i].device_name[pathnamelen] != '\0') 7ff4: e7d70008 ldrb r0, [r7, r8] 7ff8: e3500000 cmp r0, #0 7ffc: 1a000009 bne 8028 /* find the device, set proper values */ pathloc->node_access = (void *)&device_name_table[i]; pathloc->handlers = &devFS_file_handlers; pathloc->ops = &devFS_ops; pathloc->mt_entry = rtems_filesystem_root.mt_entry; 8000: e59f3054 ldr r3, [pc, #84] ; 805c 8004: e5933000 ldr r3, [r3] 8008: e5933028 ldr r3, [r3, #40] ; 0x28 800c: e5843010 str r3, [r4, #16] if (device_name_table[i].device_name[pathnamelen] != '\0') continue; /* find the device, set proper values */ pathloc->node_access = (void *)&device_name_table[i]; pathloc->handlers = &devFS_file_handlers; 8010: e59f3048 ldr r3, [pc, #72] ; 8060 8014: e5843008 str r3, [r4, #8] pathloc->ops = &devFS_ops; 8018: e59f3044 ldr r3, [pc, #68] ; 8064 if (device_name_table[i].device_name[pathnamelen] != '\0') continue; /* find the device, set proper values */ pathloc->node_access = (void *)&device_name_table[i]; 801c: e5845000 str r5, [r4] pathloc->handlers = &devFS_file_handlers; pathloc->ops = &devFS_ops; 8020: e584300c str r3, [r4, #12] pathloc->mt_entry = rtems_filesystem_root.mt_entry; return 0; 8024: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} /* get the device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; if (!device_name_table) rtems_set_errno_and_return_minus_one( EFAULT ); for (i = 0; i < rtems_device_table_size; i++) { 8028: e2866001 add r6, r6, #1 802c: e2855014 add r5, r5, #20 8030: e59a3000 ldr r3, [sl] 8034: e1560003 cmp r6, r3 if (!device_name_table[i].device_name) continue; if (strncmp(pathname, device_name_table[i].device_name, pathnamelen) != 0) 8038: e1a00009 mov r0, r9 803c: e1a02008 mov r2, r8 /* get the device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; if (!device_name_table) rtems_set_errno_and_return_minus_one( EFAULT ); for (i = 0; i < rtems_device_table_size; i++) { 8040: 3affffe5 bcc 7fdc pathloc->mt_entry = rtems_filesystem_root.mt_entry; return 0; } /* no such file or directory */ rtems_set_errno_and_return_minus_one( ENOENT ); 8044: eb0005e2 bl 97d4 <__errno> 8048: e3a03002 mov r3, #2 804c: e5803000 str r3, [r0] 8050: e3e00000 mvn r0, #0 } 8054: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} 8058: 0000c304 .word 0x0000c304 805c: 0000c4ec .word 0x0000c4ec 8060: 0000c458 .word 0x0000c458 8064: 0000c490 .word 0x0000c490 00001234 : int devFS_initialize( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) { 1234: e92d40f0 push {r4, r5, r6, r7, lr} rtems_device_name_t *device_name_table; /* allocate device only filesystem name table */ device_name_table = (rtems_device_name_t *)_Workspace_Allocate( 1238: e59f7058 ldr r7, [pc, #88] ; 1298 123c: e5973000 ldr r3, [r7] 1240: e3a06014 mov r6, #20 int devFS_initialize( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) { 1244: e1a04000 mov r4, r0 rtems_device_name_t *device_name_table; /* allocate device only filesystem name table */ device_name_table = (rtems_device_name_t *)_Workspace_Allocate( 1248: e0000396 mul r0, r6, r3 124c: eb001a28 bl 7af4 <_Workspace_Allocate> sizeof( rtems_device_name_t ) * ( rtems_device_table_size ) ); /* no memory for device filesystem */ if (!device_name_table) 1250: e2505000 subs r5, r0, #0 1254: 1a000004 bne 126c rtems_set_errno_and_return_minus_one( ENOMEM ); 1258: eb00215d bl 97d4 <__errno> <== NOT EXECUTED 125c: e3a0300c mov r3, #12 <== NOT EXECUTED 1260: e5803000 str r3, [r0] <== NOT EXECUTED 1264: e3e00000 mvn r0, #0 <== NOT EXECUTED 1268: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED memset( 126c: e5972000 ldr r2, [r7] 1270: e3a01000 mov r1, #0 1274: e0020296 mul r2, r6, r2 1278: eb002383 bl a08c device_name_table, 0, sizeof( rtems_device_name_t ) * ( rtems_device_table_size ) ); /* set file handlers */ temp_mt_entry->mt_fs_root.handlers = &devFS_file_handlers; 127c: e59f3018 ldr r3, [pc, #24] ; 129c temp_mt_entry->mt_fs_root.ops = &devFS_ops; 1280: e2832038 add r2, r3, #56 ; 0x38 /* Set the node_access to device name table */ temp_mt_entry->mt_fs_root.node_access = (void *)device_name_table; 1284: e584501c str r5, [r4, #28] sizeof( rtems_device_name_t ) * ( rtems_device_table_size ) ); /* set file handlers */ temp_mt_entry->mt_fs_root.handlers = &devFS_file_handlers; temp_mt_entry->mt_fs_root.ops = &devFS_ops; 1288: e5842028 str r2, [r4, #40] ; 0x28 device_name_table, 0, sizeof( rtems_device_name_t ) * ( rtems_device_table_size ) ); /* set file handlers */ temp_mt_entry->mt_fs_root.handlers = &devFS_file_handlers; 128c: e5843024 str r3, [r4, #36] ; 0x24 temp_mt_entry->mt_fs_root.ops = &devFS_ops; /* Set the node_access to device name table */ temp_mt_entry->mt_fs_root.node_access = (void *)device_name_table; 1290: e3a00000 mov r0, #0 return 0; } 1294: e8bd80f0 pop {r4, r5, r6, r7, pc} 1298: 0000c304 .word 0x0000c304 129c: 0000c458 .word 0x0000c458 000012a0 : const char *path, mode_t mode, dev_t dev, rtems_filesystem_location_info_t *pathloc ) { 12a0: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} 12a4: e1a04000 mov r4, r0 * condition and do not create the '/dev' and the 'path' * actually passed in is 'dev', not '/dev'. Just return 0 to * indicate we are OK. */ if ((path[0] == 'd') && (path[1] == 'e') && 12a8: e5d00000 ldrb r0, [r0] 12ac: e3500064 cmp r0, #100 ; 0x64 const char *path, mode_t mode, dev_t dev, rtems_filesystem_location_info_t *pathloc ) { 12b0: e1a05001 mov r5, r1 12b4: e58d2000 str r2, [sp] 12b8: e1a09003 mov r9, r3 * condition and do not create the '/dev' and the 'path' * actually passed in is 'dev', not '/dev'. Just return 0 to * indicate we are OK. */ if ((path[0] == 'd') && (path[1] == 'e') && 12bc: 1a000008 bne 12e4 12c0: e5d43001 ldrb r3, [r4, #1] 12c4: e3530065 cmp r3, #101 ; 0x65 12c8: 1a000005 bne 12e4 (path[2] == 'v') && (path[3] == '\0')) 12cc: e5d43002 ldrb r3, [r4, #2] 12d0: e3530076 cmp r3, #118 ; 0x76 12d4: 1a000002 bne 12e4 12d8: e5d40003 ldrb r0, [r4, #3] 12dc: e3500000 cmp r0, #0 12e0: 0a000039 beq 13cc return 0; /* must be a character device or a block device */ if (!S_ISBLK(mode) && !S_ISCHR(mode)) 12e4: e205aa0f and sl, r5, #61440 ; 0xf000 12e8: e35a0a02 cmp sl, #8192 ; 0x2000 12ec: 135a0a06 cmpne sl, #24576 ; 0x6000 12f0: 03a0a000 moveq sl, #0 12f4: 13a0a001 movne sl, #1 12f8: 0a000002 beq 1308 rtems_set_errno_and_return_minus_one( EINVAL ); 12fc: eb002134 bl 97d4 <__errno> <== NOT EXECUTED 1300: e3a03016 mov r3, #22 <== NOT EXECUTED 1304: ea000008 b 132c <== NOT EXECUTED else rtems_filesystem_split_dev_t(dev, major, minor); /* Find an empty slot in device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; 1308: e59d3028 ldr r3, [sp, #40] ; 0x28 130c: e5936000 ldr r6, [r3] if (!device_name_table) 1310: e3560000 cmp r6, #0 1314: 13e07000 mvnne r7, #0 1318: 11a0800a movne r8, sl rtems_set_errno_and_return_minus_one( EFAULT ); for (slot = -1, i = 0; i < rtems_device_table_size; i++){ 131c: 159fb0ac ldrne fp, [pc, #172] ; 13d0 1320: 1a000010 bne 1368 rtems_filesystem_split_dev_t(dev, major, minor); /* Find an empty slot in device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; if (!device_name_table) rtems_set_errno_and_return_minus_one( EFAULT ); 1324: eb00212a bl 97d4 <__errno> <== NOT EXECUTED 1328: e3a0300e mov r3, #14 <== NOT EXECUTED 132c: e5803000 str r3, [r0] <== NOT EXECUTED 1330: e3e00000 mvn r0, #0 <== NOT EXECUTED 1334: ea000024 b 13cc <== NOT EXECUTED for (slot = -1, i = 0; i < rtems_device_table_size; i++){ if (device_name_table[i].device_name == NULL) 1338: e796300a ldr r3, [r6, sl] 133c: e2531000 subs r1, r3, #0 1340: 0a000005 beq 135c slot = i; else if (strcmp(path, device_name_table[i].device_name) == 0) 1344: eb0023f8 bl a32c <== NOT EXECUTED 1348: e3500000 cmp r0, #0 <== NOT EXECUTED 134c: 1a000003 bne 1360 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EEXIST ); 1350: eb00211f bl 97d4 <__errno> <== NOT EXECUTED 1354: e3a03011 mov r3, #17 <== NOT EXECUTED 1358: eafffff3 b 132c <== NOT EXECUTED 135c: e1a07008 mov r7, r8 /* Find an empty slot in device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; if (!device_name_table) rtems_set_errno_and_return_minus_one( EFAULT ); for (slot = -1, i = 0; i < rtems_device_table_size; i++){ 1360: e2888001 add r8, r8, #1 1364: e28aa014 add sl, sl, #20 1368: e59b3000 ldr r3, [fp] 136c: e1580003 cmp r8, r3 if (device_name_table[i].device_name == NULL) slot = i; else if (strcmp(path, device_name_table[i].device_name) == 0) 1370: e1a00004 mov r0, r4 /* Find an empty slot in device name table */ device_name_table = (rtems_device_name_t *)pathloc->node_access; if (!device_name_table) rtems_set_errno_and_return_minus_one( EFAULT ); for (slot = -1, i = 0; i < rtems_device_table_size; i++){ 1374: 3affffef bcc 1338 else if (strcmp(path, device_name_table[i].device_name) == 0) rtems_set_errno_and_return_minus_one( EEXIST ); } if (slot == -1) 1378: e3770001 cmn r7, #1 137c: 1a000004 bne 1394 rtems_set_errno_and_return_minus_one( ENOMEM ); 1380: eb002113 bl 97d4 <__errno> <== NOT EXECUTED 1384: e3a0300c mov r3, #12 <== NOT EXECUTED 1388: e5803000 str r3, [r0] <== NOT EXECUTED 138c: e1a00007 mov r0, r7 <== NOT EXECUTED 1390: ea00000d b 13cc <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 1394: e10f8000 mrs r8, CPSR 1398: e3883080 orr r3, r8, #128 ; 0x80 139c: e129f003 msr CPSR_fc, r3 _ISR_Disable(level); device_name_table[slot].device_name = (char *)path; 13a0: e3a02014 mov r2, #20 13a4: e0030792 mul r3, r2, r7 device_name_table[slot].device_name_length = strlen(path); 13a8: e1a00004 mov r0, r4 if (slot == -1) rtems_set_errno_and_return_minus_one( ENOMEM ); _ISR_Disable(level); device_name_table[slot].device_name = (char *)path; 13ac: e7864003 str r4, [r6, r3] 13b0: e0866003 add r6, r6, r3 device_name_table[slot].device_name_length = strlen(path); 13b4: eb0024a4 bl a64c device_name_table[slot].major = major; 13b8: e59d3000 ldr r3, [sp] device_name_table[slot].minor = minor; device_name_table[slot].mode = mode; 13bc: e5865010 str r5, [r6, #16] if (slot == -1) rtems_set_errno_and_return_minus_one( ENOMEM ); _ISR_Disable(level); device_name_table[slot].device_name = (char *)path; device_name_table[slot].device_name_length = strlen(path); 13c0: e9860209 stmib r6, {r0, r3, r9} static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 13c4: e129f008 msr CPSR_fc, r8 13c8: e3a00000 mov r0, #0 device_name_table[slot].minor = minor; device_name_table[slot].mode = mode; _ISR_Enable(level); return 0; } 13cc: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 13d0: 0000c304 .word 0x0000c304 00001450 : ssize_t devFS_read( rtems_libio_t *iop, void *buffer, size_t count ) { 1450: e92d487f push {r0, r1, r2, r3, r4, r5, r6, fp, lr} <== NOT EXECUTED 1454: e1a03000 mov r3, r0 <== NOT EXECUTED args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags; 1458: e5900014 ldr r0, [r0, #20] <== NOT EXECUTED np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; 145c: e58d2010 str r2, [sp, #16] <== NOT EXECUTED args.flags = iop->flags; args.bytes_moved = 0; 1460: e3a02000 mov r2, #0 <== NOT EXECUTED 1464: e58d2018 str r2, [sp, #24] <== NOT EXECUTED args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags; 1468: e58d0014 str r0, [sp, #20] <== NOT EXECUTED { rtems_libio_rw_args_t args; rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; 146c: e5932038 ldr r2, [r3, #56] ; 0x38 <== NOT EXECUTED args.iop = iop; args.offset = iop->offset; 1470: e283c00c add ip, r3, #12 <== NOT EXECUTED 1474: e89c1800 ldm ip, {fp, ip} <== NOT EXECUTED args.buffer = buffer; 1478: e58d100c str r1, [sp, #12] <== NOT EXECUTED args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_read( 147c: e2820008 add r0, r2, #8 <== NOT EXECUTED 1480: e8900003 ldm r0, {r0, r1} <== NOT EXECUTED 1484: e1a0200d mov r2, sp <== NOT EXECUTED rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset; 1488: e98d1800 stmib sp, {fp, ip} <== NOT EXECUTED rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop; 148c: e58d3000 str r3, [sp] <== NOT EXECUTED args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_read( 1490: eb000f5a bl 5200 <== NOT EXECUTED np->major, np->minor, (void *) &args ); if ( status ) 1494: e3500000 cmp r0, #0 <== NOT EXECUTED return rtems_deviceio_errno(status); return (ssize_t) args.bytes_moved; 1498: 059d0018 ldreq r0, [sp, #24] <== NOT EXECUTED np->minor, (void *) &args ); if ( status ) return rtems_deviceio_errno(status); 149c: 1b001af1 blne 8068 <== NOT EXECUTED return (ssize_t) args.bytes_moved; } 14a0: e28dd01c add sp, sp, #28 <== NOT EXECUTED 14a4: e8bd8800 pop {fp, pc} <== NOT EXECUTED 000014a8 : struct stat *buf ) { rtems_device_name_t *the_dev; the_dev = (rtems_device_name_t *)loc->node_access; 14a8: e5903000 ldr r3, [r0] if (!the_dev) 14ac: e3530000 cmp r3, #0 int devFS_stat( rtems_filesystem_location_info_t *loc, struct stat *buf ) { 14b0: e52de004 push {lr} ; (str lr, [sp, #-4]!) rtems_device_name_t *the_dev; the_dev = (rtems_device_name_t *)loc->node_access; if (!the_dev) 14b4: 1a000004 bne 14cc rtems_set_errno_and_return_minus_one( EFAULT ); 14b8: eb0020c5 bl 97d4 <__errno> <== NOT EXECUTED 14bc: e3a0300e mov r3, #14 <== NOT EXECUTED 14c0: e5803000 str r3, [r0] <== NOT EXECUTED 14c4: e3e00000 mvn r0, #0 <== NOT EXECUTED 14c8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED buf->st_rdev = rtems_filesystem_make_dev_t( the_dev->major, the_dev->minor ); buf->st_mode = the_dev->mode; 14cc: e5930010 ldr r0, [r3, #16] the_dev = (rtems_device_name_t *)loc->node_access; if (!the_dev) rtems_set_errno_and_return_minus_one( EFAULT ); buf->st_rdev = rtems_filesystem_make_dev_t( the_dev->major, the_dev->minor ); 14d0: e593200c ldr r2, [r3, #12] rtems_device_minor_number _minor ) { union __rtems_dev_t temp; temp.__overlay.major = _major; 14d4: e5933008 ldr r3, [r3, #8] buf->st_mode = the_dev->mode; 14d8: e581000c str r0, [r1, #12] the_dev = (rtems_device_name_t *)loc->node_access; if (!the_dev) rtems_set_errno_and_return_minus_one( EFAULT ); buf->st_rdev = rtems_filesystem_make_dev_t( the_dev->major, the_dev->minor ); 14dc: e5813018 str r3, [r1, #24] 14e0: e581201c str r2, [r1, #28] buf->st_mode = the_dev->mode; 14e4: e3a00000 mov r0, #0 return 0; } 14e8: e49df004 pop {pc} ; (ldr pc, [sp], #4) 0000a3b4 : ssize_t device_read( rtems_libio_t *iop, void *buffer, size_t count ) { a3b4: e92d487f push {r0, r1, r2, r3, r4, r5, r6, fp, lr} <== NOT EXECUTED args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags; a3b8: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset; a3bc: e280c00c add ip, r0, #12 <== NOT EXECUTED a3c0: e89c1800 ldm ip, {fp, ip} <== NOT EXECUTED args.buffer = buffer; args.count = count; args.flags = iop->flags; a3c4: e58d3014 str r3, [sp, #20] <== NOT EXECUTED IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset; a3c8: e98d1800 stmib sp, {fp, ip} <== NOT EXECUTED args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; a3cc: e3a03000 mov r3, #0 <== NOT EXECUTED the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; a3d0: e58d2010 str r2, [sp, #16] <== NOT EXECUTED args.flags = iop->flags; args.bytes_moved = 0; a3d4: e58d3018 str r3, [sp, #24] <== NOT EXECUTED the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset; args.buffer = buffer; a3d8: e58d100c str r1, [sp, #12] <== NOT EXECUTED rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop; a3dc: e58d0000 str r0, [sp] <== NOT EXECUTED { rtems_libio_rw_args_t args; rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; a3e0: e5903038 ldr r3, [r0, #56] ; 0x38 <== NOT EXECUTED args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_read( a3e4: e1a0200d mov r2, sp <== NOT EXECUTED a3e8: e2830050 add r0, r3, #80 ; 0x50 <== NOT EXECUTED a3ec: e8900003 ldm r0, {r0, r1} <== NOT EXECUTED a3f0: eb0003eb bl b3a4 <== NOT EXECUTED the_jnode->info.device.major, the_jnode->info.device.minor, (void *) &args ); if ( status ) a3f4: e3500000 cmp r0, #0 <== NOT EXECUTED return rtems_deviceio_errno(status); return (ssize_t) args.bytes_moved; a3f8: 059d0018 ldreq r0, [sp, #24] <== NOT EXECUTED the_jnode->info.device.minor, (void *) &args ); if ( status ) return rtems_deviceio_errno(status); a3fc: 1b0004fb blne b7f0 <== NOT EXECUTED return (ssize_t) args.bytes_moved; } a400: e28dd01c add sp, sp, #28 <== NOT EXECUTED a404: e8bd8800 pop {fp, pc} <== NOT EXECUTED 00003368 : drainOutput (struct rtems_termios_tty *tty) { rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) { 3368: e59030b4 ldr r3, [r0, #180] ; 0xb4 336c: e3530000 cmp r3, #0 /* * Drain output queue */ static void drainOutput (struct rtems_termios_tty *tty) { 3370: e92d4030 push {r4, r5, lr} 3374: e1a04000 mov r4, r0 rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) { 3378: 08bd8030 popeq {r4, r5, pc} static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 337c: e10f3000 mrs r3, CPSR <== NOT EXECUTED 3380: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 3384: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED rtems_interrupt_disable (level); while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) { tty->rawOutBufState = rob_wait; 3388: e3a05002 mov r5, #2 <== NOT EXECUTED rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) { rtems_interrupt_disable (level); while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) { 338c: ea00000a b 33bc <== NOT EXECUTED tty->rawOutBufState = rob_wait; 3390: e5845094 str r5, [r4, #148] ; 0x94 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 3394: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED rtems_interrupt_enable (level); sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore, 3398: e3a01000 mov r1, #0 <== NOT EXECUTED 339c: e594008c ldr r0, [r4, #140] ; 0x8c <== NOT EXECUTED 33a0: e1a02001 mov r2, r1 <== NOT EXECUTED 33a4: eb0005af bl 4a68 <== NOT EXECUTED RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) 33a8: e3500000 cmp r0, #0 <== NOT EXECUTED rtems_fatal_error_occurred (sc); 33ac: 1b000740 blne 50b4 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 33b0: e10f3000 mrs r3, CPSR <== NOT EXECUTED 33b4: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 33b8: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) { rtems_interrupt_disable (level); while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) { 33bc: e5941084 ldr r1, [r4, #132] ; 0x84 <== NOT EXECUTED 33c0: e5942080 ldr r2, [r4, #128] ; 0x80 <== NOT EXECUTED 33c4: e1510002 cmp r1, r2 <== NOT EXECUTED 33c8: 1afffff0 bne 3390 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 33cc: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 33d0: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED 00002530 : int dup2( int fildes, int fildes2 ) { 2530: e92d4070 push {r4, r5, r6, lr} 2534: e24dd048 sub sp, sp, #72 ; 0x48 2538: e1a04001 mov r4, r1 /* * If fildes is not valid, then fildes2 should not be closed. */ status = fstat( fildes, &buf ); 253c: e1a0100d mov r1, sp int dup2( int fildes, int fildes2 ) { 2540: e1a06000 mov r6, r0 /* * If fildes is not valid, then fildes2 should not be closed. */ status = fstat( fildes, &buf ); 2544: eb00019b bl 2bb8 if ( status == -1 ) 2548: e3700001 cmn r0, #1 /* * If fildes is not valid, then fildes2 should not be closed. */ status = fstat( fildes, &buf ); 254c: e1a0500d mov r5, sp if ( status == -1 ) 2550: 0a000009 beq 257c /* * If fildes2 is not valid, then we should not do anything either. */ status = fstat( fildes2, &buf ); 2554: e1a0100d mov r1, sp 2558: e1a00004 mov r0, r4 255c: eb000195 bl 2bb8 if ( status == -1 ) 2560: e3700001 cmn r0, #1 2564: 0a000004 beq 257c /* * This fcntl handles everything else. */ return fcntl( fildes, F_DUPFD, fildes2 ); 2568: e1a00006 mov r0, r6 <== NOT EXECUTED 256c: e1a02004 mov r2, r4 <== NOT EXECUTED 2570: e3a01000 mov r1, #0 <== NOT EXECUTED 2574: eb00008d bl 27b0 <== NOT EXECUTED 2578: ea000000 b 2580 <== NOT EXECUTED 257c: e3e00000 mvn r0, #0 } 2580: e28dd048 add sp, sp, #72 ; 0x48 2584: e8bd8070 pop {r4, r5, r6, pc} 00002e68 : * Echo a typed character */ static void echo (unsigned char c, struct rtems_termios_tty *tty) { if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) { 2e68: e591303c ldr r3, [r1, #60] ; 0x3c <== NOT EXECUTED 2e6c: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED /* * Echo a typed character */ static void echo (unsigned char c, struct rtems_termios_tty *tty) { 2e70: e92d4011 push {r0, r4, lr} <== NOT EXECUTED 2e74: e1a04001 mov r4, r1 <== NOT EXECUTED 2e78: e20000ff and r0, r0, #255 ; 0xff <== NOT EXECUTED if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) { 2e7c: 0a000015 beq 2ed8 <== NOT EXECUTED 2e80: e59f305c ldr r3, [pc, #92] ; 2ee4 <== NOT EXECUTED 2e84: e5933000 ldr r3, [r3] <== NOT EXECUTED 2e88: e0833000 add r3, r3, r0 <== NOT EXECUTED 2e8c: e5d32001 ldrb r2, [r3, #1] <== NOT EXECUTED 2e90: e2503009 subs r3, r0, #9 <== NOT EXECUTED 2e94: 13a03001 movne r3, #1 <== NOT EXECUTED 2e98: e01332a2 ands r3, r3, r2, lsr #5 <== NOT EXECUTED 2e9c: 0a00000d beq 2ed8 <== NOT EXECUTED 2ea0: e350000a cmp r0, #10 <== NOT EXECUTED 2ea4: 0a00000b beq 2ed8 <== NOT EXECUTED char echobuf[2]; echobuf[0] = '^'; echobuf[1] = c ^ 0x40; 2ea8: e2203040 eor r3, r0, #64 ; 0x40 <== NOT EXECUTED echo (unsigned char c, struct rtems_termios_tty *tty) { if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) { char echobuf[2]; echobuf[0] = '^'; 2eac: e3a0c05e mov ip, #94 ; 0x5e <== NOT EXECUTED echobuf[1] = c ^ 0x40; rtems_termios_puts (echobuf, 2, tty); 2eb0: e1a0000d mov r0, sp <== NOT EXECUTED 2eb4: e3a01002 mov r1, #2 <== NOT EXECUTED 2eb8: e1a02004 mov r2, r4 <== NOT EXECUTED { if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) { char echobuf[2]; echobuf[0] = '^'; echobuf[1] = c ^ 0x40; 2ebc: e5cd3001 strb r3, [sp, #1] <== NOT EXECUTED echo (unsigned char c, struct rtems_termios_tty *tty) { if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) { char echobuf[2]; echobuf[0] = '^'; 2ec0: e5cdc000 strb ip, [sp] <== NOT EXECUTED echobuf[1] = c ^ 0x40; rtems_termios_puts (echobuf, 2, tty); 2ec4: ebffff4d bl 2c00 <== NOT EXECUTED tty->column += 2; 2ec8: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 2ecc: e2833002 add r3, r3, #2 <== NOT EXECUTED 2ed0: e5843028 str r3, [r4, #40] ; 0x28 <== NOT EXECUTED * Echo a typed character */ static void echo (unsigned char c, struct rtems_termios_tty *tty) { if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) { 2ed4: ea000001 b 2ee0 <== NOT EXECUTED echobuf[1] = c ^ 0x40; rtems_termios_puts (echobuf, 2, tty); tty->column += 2; } else { oproc (c, tty); 2ed8: e1a01004 mov r1, r4 <== NOT EXECUTED 2edc: ebffff8b bl 2d10 <== NOT EXECUTED } } 2ee0: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED 2ee4: 0001777c .word 0x0001777c 000220c4 : group_fp = fopen("/etc/group", "r"); } void endgrent(void) { if (group_fp != NULL) 220c4: e59f300c ldr r3, [pc, #12] ; 220d8 <== NOT EXECUTED 220c8: e5930000 ldr r0, [r3] <== NOT EXECUTED 220cc: e3500000 cmp r0, #0 <== NOT EXECUTED 220d0: 012fff1e bxeq lr <== NOT EXECUTED fclose(group_fp); 220d4: ea005884 b 382ec <== NOT EXECUTED 220d8: 0005f784 .word 0x0005f784 000220dc : passwd_fp = fopen("/etc/passwd", "r"); } void endpwent(void) { if (passwd_fp != NULL) 220dc: e59f300c ldr r3, [pc, #12] ; 220f0 <== NOT EXECUTED 220e0: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED 220e4: e3500000 cmp r0, #0 <== NOT EXECUTED 220e8: 012fff1e bxeq lr <== NOT EXECUTED fclose(passwd_fp); 220ec: ea00587e b 382ec <== NOT EXECUTED 220f0: 0005f784 .word 0x0005f784 00002ee8 : * FIXME: Some of the tests should check for IEXTEN, too. */ static void erase (struct rtems_termios_tty *tty, int lineFlag) { if (tty->ccount == 0) 2ee8: e5903020 ldr r3, [r0, #32] <== NOT EXECUTED 2eec: e3530000 cmp r3, #0 <== NOT EXECUTED * FIXME: Needs support for WERASE and ECHOPRT. * FIXME: Some of the tests should check for IEXTEN, too. */ static void erase (struct rtems_termios_tty *tty, int lineFlag) { 2ef0: e92d41f0 push {r4, r5, r6, r7, r8, lr} <== NOT EXECUTED 2ef4: e1a04000 mov r4, r0 <== NOT EXECUTED 2ef8: e1a07001 mov r7, r1 <== NOT EXECUTED if (tty->ccount == 0) 2efc: 08bd81f0 popeq {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED return; if (lineFlag) { 2f00: e3510000 cmp r1, #0 <== NOT EXECUTED 2f04: 0a000062 beq 3094 <== NOT EXECUTED if (!(tty->termios.c_lflag & ECHO)) { 2f08: e590303c ldr r3, [r0, #60] ; 0x3c <== NOT EXECUTED 2f0c: e2132008 ands r2, r3, #8 <== NOT EXECUTED tty->ccount = 0; 2f10: 05802020 streq r2, [r0, #32] <== NOT EXECUTED erase (struct rtems_termios_tty *tty, int lineFlag) { if (tty->ccount == 0) return; if (lineFlag) { if (!(tty->termios.c_lflag & ECHO)) { 2f14: 08bd81f0 popeq {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED tty->ccount = 0; return; } if (!(tty->termios.c_lflag & ECHOE)) { 2f18: e2133010 ands r3, r3, #16 <== NOT EXECUTED 2f1c: 1a00005c bne 3094 <== NOT EXECUTED tty->ccount = 0; 2f20: e5803020 str r3, [r0, #32] <== NOT EXECUTED echo (tty->termios.c_cc[VKILL], tty); 2f24: e1a01004 mov r1, r4 <== NOT EXECUTED 2f28: e5d00044 ldrb r0, [r0, #68] ; 0x44 <== NOT EXECUTED 2f2c: ebffffcd bl 2e68 <== NOT EXECUTED if (tty->termios.c_lflag & ECHOK) 2f30: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 2f34: e3130020 tst r3, #32 <== NOT EXECUTED echo ('\n', tty); 2f38: 11a01004 movne r1, r4 <== NOT EXECUTED 2f3c: 13a0000a movne r0, #10 <== NOT EXECUTED return; } if (!(tty->termios.c_lflag & ECHOE)) { tty->ccount = 0; echo (tty->termios.c_cc[VKILL], tty); if (tty->termios.c_lflag & ECHOK) 2f40: 08bd81f0 popeq {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED 2f44: ea00000c b 2f7c <== NOT EXECUTED echo ('\n', tty); return; } } while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount]; 2f48: e2411001 sub r1, r1, #1 <== NOT EXECUTED if (tty->termios.c_lflag & ECHO) { 2f4c: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED echo ('\n', tty); return; } } while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount]; 2f50: e5841020 str r1, [r4, #32] <== NOT EXECUTED 2f54: e594201c ldr r2, [r4, #28] <== NOT EXECUTED if (tty->termios.c_lflag & ECHO) { 2f58: e3130008 tst r3, #8 <== NOT EXECUTED echo ('\n', tty); return; } } while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount]; 2f5c: e7d25001 ldrb r5, [r2, r1] <== NOT EXECUTED if (tty->termios.c_lflag & ECHO) { 2f60: 0a000048 beq 3088 <== NOT EXECUTED if (!lineFlag && !(tty->termios.c_lflag & ECHOE)) { 2f64: e3570000 cmp r7, #0 <== NOT EXECUTED 2f68: 1a000005 bne 2f84 <== NOT EXECUTED 2f6c: e3130010 tst r3, #16 <== NOT EXECUTED 2f70: 1a000003 bne 2f84 <== NOT EXECUTED echo (tty->termios.c_cc[VERASE], tty); 2f74: e5d40043 ldrb r0, [r4, #67] ; 0x43 <== NOT EXECUTED 2f78: e1a01004 mov r1, r4 <== NOT EXECUTED } } if (!lineFlag) break; } } 2f7c: e8bd41f0 pop {r4, r5, r6, r7, r8, lr} <== NOT EXECUTED while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount]; if (tty->termios.c_lflag & ECHO) { if (!lineFlag && !(tty->termios.c_lflag & ECHOE)) { echo (tty->termios.c_cc[VERASE], tty); 2f80: eaffffb8 b 2e68 <== NOT EXECUTED } else if (c == '\t') { 2f84: e3550009 cmp r5, #9 <== NOT EXECUTED 2f88: 1a000020 bne 3010 <== NOT EXECUTED c = tty->cbuf[i++]; if (c == '\t') { col = (col | 7) + 1; } else if (iscntrl (c)) { if (tty->termios.c_lflag & ECHOCTL) 2f8c: e2033c02 and r3, r3, #512 ; 0x200 <== NOT EXECUTED if (tty->termios.c_lflag & ECHO) { if (!lineFlag && !(tty->termios.c_lflag & ECHOE)) { echo (tty->termios.c_cc[VERASE], tty); } else if (c == '\t') { int col = tty->read_start_column; 2f90: e594502c ldr r5, [r4, #44] ; 0x2c <== NOT EXECUTED while (i != tty->ccount) { c = tty->cbuf[i++]; if (c == '\t') { col = (col | 7) + 1; } else if (iscntrl (c)) { 2f94: e596c000 ldr ip, [r6] <== NOT EXECUTED 2f98: e3a02000 mov r2, #0 <== NOT EXECUTED int i = 0; /* * Find the character before the tab */ while (i != tty->ccount) { 2f9c: ea00000d b 2fd8 <== NOT EXECUTED c = tty->cbuf[i++]; 2fa0: e594001c ldr r0, [r4, #28] <== NOT EXECUTED 2fa4: e7d00002 ldrb r0, [r0, r2] <== NOT EXECUTED if (c == '\t') { 2fa8: e3500009 cmp r0, #9 <== NOT EXECUTED col = (col | 7) + 1; } else if (iscntrl (c)) { 2fac: e08c8000 add r8, ip, r0 <== NOT EXECUTED * Find the character before the tab */ while (i != tty->ccount) { c = tty->cbuf[i++]; if (c == '\t') { col = (col | 7) + 1; 2fb0: 03855007 orreq r5, r5, #7 <== NOT EXECUTED /* * Find the character before the tab */ while (i != tty->ccount) { c = tty->cbuf[i++]; if (c == '\t') { 2fb4: 0a000005 beq 2fd0 <== NOT EXECUTED col = (col | 7) + 1; } else if (iscntrl (c)) { 2fb8: e5d80001 ldrb r0, [r8, #1] <== NOT EXECUTED 2fbc: e3100020 tst r0, #32 <== NOT EXECUTED 2fc0: 0a000002 beq 2fd0 <== NOT EXECUTED if (tty->termios.c_lflag & ECHOCTL) 2fc4: e3530000 cmp r3, #0 <== NOT EXECUTED col += 2; 2fc8: 12855002 addne r5, r5, #2 <== NOT EXECUTED 2fcc: ea000000 b 2fd4 <== NOT EXECUTED } else { col++; 2fd0: e2855001 add r5, r5, #1 <== NOT EXECUTED /* * Find the character before the tab */ while (i != tty->ccount) { c = tty->cbuf[i++]; 2fd4: e2822001 add r2, r2, #1 <== NOT EXECUTED int i = 0; /* * Find the character before the tab */ while (i != tty->ccount) { 2fd8: e1520001 cmp r2, r1 <== NOT EXECUTED 2fdc: 1affffef bne 2fa0 <== NOT EXECUTED 2fe0: ea000006 b 3000 <== NOT EXECUTED /* * Back up over the tab */ while (tty->column > col) { rtems_termios_puts ("\b", 1, tty); 2fe4: e59f00bc ldr r0, [pc, #188] ; 30a8 <== NOT EXECUTED 2fe8: e3a01001 mov r1, #1 <== NOT EXECUTED 2fec: e1a02004 mov r2, r4 <== NOT EXECUTED 2ff0: ebffff02 bl 2c00 <== NOT EXECUTED tty->column--; 2ff4: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 2ff8: e2433001 sub r3, r3, #1 <== NOT EXECUTED 2ffc: e5843028 str r3, [r4, #40] ; 0x28 <== NOT EXECUTED } /* * Back up over the tab */ while (tty->column > col) { 3000: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 3004: e1530005 cmp r3, r5 <== NOT EXECUTED 3008: cafffff5 bgt 2fe4 <== NOT EXECUTED 300c: ea00001d b 3088 <== NOT EXECUTED rtems_termios_puts ("\b", 1, tty); tty->column--; } } else { if (iscntrl (c) && (tty->termios.c_lflag & ECHOCTL)) { 3010: e5962000 ldr r2, [r6] <== NOT EXECUTED 3014: e2855001 add r5, r5, #1 <== NOT EXECUTED 3018: e7d22005 ldrb r2, [r2, r5] <== NOT EXECUTED 301c: e3120020 tst r2, #32 <== NOT EXECUTED 3020: 0a000009 beq 304c <== NOT EXECUTED 3024: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED 3028: 0a000007 beq 304c <== NOT EXECUTED rtems_termios_puts ("\b \b", 3, tty); 302c: e59f0078 ldr r0, [pc, #120] ; 30ac <== NOT EXECUTED 3030: e3a01003 mov r1, #3 <== NOT EXECUTED 3034: e1a02004 mov r2, r4 <== NOT EXECUTED 3038: ebfffef0 bl 2c00 <== NOT EXECUTED if (tty->column) 303c: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 3040: e3530000 cmp r3, #0 <== NOT EXECUTED tty->column--; 3044: 12433001 subne r3, r3, #1 <== NOT EXECUTED 3048: 15843028 strne r3, [r4, #40] ; 0x28 <== NOT EXECUTED } if (!iscntrl (c) || (tty->termios.c_lflag & ECHOCTL)) { 304c: e5963000 ldr r3, [r6] <== NOT EXECUTED 3050: e7d33005 ldrb r3, [r3, r5] <== NOT EXECUTED 3054: e3130020 tst r3, #32 <== NOT EXECUTED 3058: 0a000002 beq 3068 <== NOT EXECUTED 305c: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 3060: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED 3064: 0a000007 beq 3088 <== NOT EXECUTED rtems_termios_puts ("\b \b", 3, tty); 3068: e59f003c ldr r0, [pc, #60] ; 30ac <== NOT EXECUTED 306c: e3a01003 mov r1, #3 <== NOT EXECUTED 3070: e1a02004 mov r2, r4 <== NOT EXECUTED 3074: ebfffee1 bl 2c00 <== NOT EXECUTED if (tty->column) 3078: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 307c: e3530000 cmp r3, #0 <== NOT EXECUTED tty->column--; 3080: 12433001 subne r3, r3, #1 <== NOT EXECUTED 3084: 15843028 strne r3, [r4, #40] ; 0x28 <== NOT EXECUTED } } } if (!lineFlag) 3088: e3570000 cmp r7, #0 <== NOT EXECUTED 308c: 1a000001 bne 3098 <== NOT EXECUTED 3090: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED 3094: e59f6014 ldr r6, [pc, #20] ; 30b0 <== NOT EXECUTED if (tty->termios.c_lflag & ECHOK) echo ('\n', tty); return; } } while (tty->ccount) { 3098: e5941020 ldr r1, [r4, #32] <== NOT EXECUTED 309c: e3510000 cmp r1, #0 <== NOT EXECUTED 30a0: 1affffa8 bne 2f48 <== NOT EXECUTED 30a4: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED 30a8: 00018507 .word 0x00018507 30ac: 00018505 .word 0x00018505 30b0: 0001777c .word 0x0001777c 00032fb8 : #include int fchdir( int fd ) { 32fb8: e92d40f0 push {r4, r5, r6, r7, lr} <== NOT EXECUTED rtems_libio_t *iop; rtems_filesystem_location_info_t loc, saved; rtems_libio_check_fd( fd ); 32fbc: e59f315c ldr r3, [pc, #348] ; 33120 <== NOT EXECUTED 32fc0: e5933000 ldr r3, [r3] <== NOT EXECUTED 32fc4: e1500003 cmp r0, r3 <== NOT EXECUTED #include int fchdir( int fd ) { 32fc8: e24dd02c sub sp, sp, #44 ; 0x2c <== NOT EXECUTED rtems_libio_t *iop; rtems_filesystem_location_info_t loc, saved; rtems_libio_check_fd( fd ); 32fcc: 2a000005 bcs 32fe8 <== NOT EXECUTED iop = rtems_libio_iop( fd ); 32fd0: e59f314c ldr r3, [pc, #332] ; 33124 <== NOT EXECUTED 32fd4: e5934000 ldr r4, [r3] <== NOT EXECUTED 32fd8: e0844300 add r4, r4, r0, lsl #6 <== NOT EXECUTED rtems_libio_check_is_open(iop); 32fdc: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED 32fe0: e3130c01 tst r3, #256 ; 0x100 <== NOT EXECUTED 32fe4: 1a000002 bne 32ff4 <== NOT EXECUTED 32fe8: eb001472 bl 381b8 <__errno> <== NOT EXECUTED 32fec: e3a03009 mov r3, #9 <== NOT EXECUTED 32ff0: ea000016 b 33050 <== NOT EXECUTED /* * Now process the fchmod(). */ rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ ); 32ff4: e3130002 tst r3, #2 <== NOT EXECUTED 32ff8: 1a000002 bne 33008 <== NOT EXECUTED 32ffc: eb00146d bl 381b8 <__errno> <== NOT EXECUTED 33000: e3a03016 mov r3, #22 <== NOT EXECUTED 33004: ea000011 b 33050 <== NOT EXECUTED /* * Verify you can change directory into this node. */ if ( !iop->pathinfo.ops ) { 33008: e5943024 ldr r3, [r4, #36] ; 0x24 <== NOT EXECUTED 3300c: e3530000 cmp r3, #0 <== NOT EXECUTED 33010: 0a000002 beq 33020 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); } if ( !iop->pathinfo.ops->node_type_h ) { 33014: e5933010 ldr r3, [r3, #16] <== NOT EXECUTED 33018: e3530000 cmp r3, #0 <== NOT EXECUTED 3301c: 1a000002 bne 3302c <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 33020: eb001464 bl 381b8 <__errno> <== NOT EXECUTED 33024: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 33028: ea000008 b 33050 <== NOT EXECUTED } if ( (*iop->pathinfo.ops->node_type_h)( &iop->pathinfo ) != 3302c: e2844018 add r4, r4, #24 <== NOT EXECUTED 33030: e1a00004 mov r0, r4 <== NOT EXECUTED 33034: e1a0e00f mov lr, pc <== NOT EXECUTED 33038: e12fff13 bx r3 <== NOT EXECUTED 3303c: e3500001 cmp r0, #1 <== NOT EXECUTED 33040: e1a06000 mov r6, r0 <== NOT EXECUTED 33044: 0a000003 beq 33058 <== NOT EXECUTED RTEMS_FILESYSTEM_DIRECTORY ) { rtems_set_errno_and_return_minus_one( ENOTDIR ); 33048: eb00145a bl 381b8 <__errno> <== NOT EXECUTED 3304c: e3a03014 mov r3, #20 <== NOT EXECUTED 33050: e5803000 str r3, [r0] <== NOT EXECUTED 33054: ea00001c b 330cc <== NOT EXECUTED * but note the race condition. Threads who * share their rtems_filesystem_current better * be synchronized! */ saved = rtems_filesystem_current; 33058: e59f50c8 ldr r5, [pc, #200] ; 33128 <== NOT EXECUTED 3305c: e5957000 ldr r7, [r5] <== NOT EXECUTED 33060: e287c004 add ip, r7, #4 <== NOT EXECUTED 33064: e8bc000f ldm ip!, {r0, r1, r2, r3} <== NOT EXECUTED 33068: e28de004 add lr, sp, #4 <== NOT EXECUTED 3306c: e8ae000f stmia lr!, {r0, r1, r2, r3} <== NOT EXECUTED 33070: e59c3000 ldr r3, [ip] <== NOT EXECUTED 33074: e58e3000 str r3, [lr] <== NOT EXECUTED rtems_filesystem_current = iop->pathinfo; 33078: e8b4000f ldm r4!, {r0, r1, r2, r3} <== NOT EXECUTED 3307c: e287e004 add lr, r7, #4 <== NOT EXECUTED 33080: e8ae000f stmia lr!, {r0, r1, r2, r3} <== NOT EXECUTED 33084: e5943000 ldr r3, [r4] <== NOT EXECUTED /* clone the current node */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) { 33088: e3a0e000 mov lr, #0 <== NOT EXECUTED * share their rtems_filesystem_current better * be synchronized! */ saved = rtems_filesystem_current; rtems_filesystem_current = iop->pathinfo; 3308c: e58c3000 str r3, [ip] <== NOT EXECUTED /* clone the current node */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) { 33090: e1a01006 mov r1, r6 <== NOT EXECUTED 33094: e1a0200e mov r2, lr <== NOT EXECUTED 33098: e59f008c ldr r0, [pc, #140] ; 3312c <== NOT EXECUTED 3309c: e28d3018 add r3, sp, #24 <== NOT EXECUTED 330a0: e58de000 str lr, [sp] <== NOT EXECUTED 330a4: ebff45af bl 4768 <== NOT EXECUTED 330a8: e3500000 cmp r0, #0 <== NOT EXECUTED 330ac: 0a000008 beq 330d4 <== NOT EXECUTED /* cloning failed; restore original and bail out */ rtems_filesystem_current = saved; 330b0: e595c000 ldr ip, [r5] <== NOT EXECUTED 330b4: e28d4004 add r4, sp, #4 <== NOT EXECUTED 330b8: e8b4000f ldm r4!, {r0, r1, r2, r3} <== NOT EXECUTED 330bc: e28cc004 add ip, ip, #4 <== NOT EXECUTED 330c0: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 330c4: e5943000 ldr r3, [r4] <== NOT EXECUTED 330c8: e58c3000 str r3, [ip] <== NOT EXECUTED 330cc: e3e00000 mvn r0, #0 <== NOT EXECUTED return -1; 330d0: ea000010 b 33118 <== NOT EXECUTED } /* release the old one */ rtems_filesystem_freenode( &saved ); 330d4: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 330d8: e3530000 cmp r3, #0 <== NOT EXECUTED 330dc: 0a000004 beq 330f4 <== NOT EXECUTED 330e0: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 330e4: e3530000 cmp r3, #0 <== NOT EXECUTED 330e8: 128d0004 addne r0, sp, #4 <== NOT EXECUTED 330ec: 11a0e00f movne lr, pc <== NOT EXECUTED 330f0: 112fff13 bxne r3 <== NOT EXECUTED rtems_filesystem_current = loc; 330f4: e59f302c ldr r3, [pc, #44] ; 33128 <== NOT EXECUTED 330f8: e28d4018 add r4, sp, #24 <== NOT EXECUTED 330fc: e593c000 ldr ip, [r3] <== NOT EXECUTED 33100: e8b4000f ldm r4!, {r0, r1, r2, r3} <== NOT EXECUTED 33104: e28cc004 add ip, ip, #4 <== NOT EXECUTED 33108: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 3310c: e5943000 ldr r3, [r4] <== NOT EXECUTED 33110: e58c3000 str r3, [ip] <== NOT EXECUTED 33114: e3a00000 mov r0, #0 <== NOT EXECUTED return 0; } 33118: e28dd02c add sp, sp, #44 ; 0x2c <== NOT EXECUTED 3311c: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED 33120: 000522a0 .word 0x000522a0 33124: 0005fbd0 .word 0x0005fbd0 33128: 00052578 .word 0x00052578 3312c: 00057998 .word 0x00057998 00021d24 : mode_t mode ) { rtems_libio_t *iop; rtems_libio_check_fd( fd ); 21d24: e59f307c ldr r3, [pc, #124] ; 21da8 <== NOT EXECUTED 21d28: e5932000 ldr r2, [r3] <== NOT EXECUTED 21d2c: e1500002 cmp r0, r2 <== NOT EXECUTED int fchmod( int fd, mode_t mode ) { 21d30: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_libio_t *iop; rtems_libio_check_fd( fd ); 21d34: 2a000005 bcs 21d50 <== NOT EXECUTED iop = rtems_libio_iop( fd ); 21d38: e59f306c ldr r3, [pc, #108] ; 21dac <== NOT EXECUTED 21d3c: e5933000 ldr r3, [r3] <== NOT EXECUTED 21d40: e0833300 add r3, r3, r0, lsl #6 <== NOT EXECUTED rtems_libio_check_is_open(iop); 21d44: e5932014 ldr r2, [r3, #20] <== NOT EXECUTED 21d48: e3120c01 tst r2, #256 ; 0x100 <== NOT EXECUTED 21d4c: 1a000002 bne 21d5c <== NOT EXECUTED 21d50: eb005918 bl 381b8 <__errno> <== NOT EXECUTED 21d54: e3a03009 mov r3, #9 <== NOT EXECUTED 21d58: ea00000a b 21d88 <== NOT EXECUTED /* * Now process the fchmod(). */ rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE ); 21d5c: e3120004 tst r2, #4 <== NOT EXECUTED 21d60: 1a000002 bne 21d70 <== NOT EXECUTED 21d64: eb005913 bl 381b8 <__errno> <== NOT EXECUTED 21d68: e3a03016 mov r3, #22 <== NOT EXECUTED 21d6c: ea000005 b 21d88 <== NOT EXECUTED if ( !iop->handlers->fchmod_h ) 21d70: e593203c ldr r2, [r3, #60] ; 0x3c <== NOT EXECUTED 21d74: e592201c ldr r2, [r2, #28] <== NOT EXECUTED 21d78: e3520000 cmp r2, #0 <== NOT EXECUTED 21d7c: 1a000004 bne 21d94 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 21d80: eb00590c bl 381b8 <__errno> <== NOT EXECUTED 21d84: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 21d88: e5803000 str r3, [r0] <== NOT EXECUTED 21d8c: e3e00000 mvn r0, #0 <== NOT EXECUTED 21d90: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED return (*iop->pathinfo.handlers->fchmod_h)( &iop->pathinfo, mode ); 21d94: e2830018 add r0, r3, #24 <== NOT EXECUTED 21d98: e5933020 ldr r3, [r3, #32] <== NOT EXECUTED 21d9c: e1a0e00f mov lr, pc <== NOT EXECUTED 21da0: e593f01c ldr pc, [r3, #28] <== NOT EXECUTED } 21da4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED 21da8: 000522a0 .word 0x000522a0 21dac: 0005fbd0 .word 0x0005fbd0 00021db0 : gid_t group ) { rtems_libio_t *iop; rtems_libio_check_fd( fd ); 21db0: e59f3088 ldr r3, [pc, #136] ; 21e40 <== NOT EXECUTED 21db4: e5933000 ldr r3, [r3] <== NOT EXECUTED int fchown( int fd, uid_t owner, gid_t group ) { 21db8: e1a01801 lsl r1, r1, #16 <== NOT EXECUTED 21dbc: e1a02802 lsl r2, r2, #16 <== NOT EXECUTED rtems_libio_t *iop; rtems_libio_check_fd( fd ); 21dc0: e1500003 cmp r0, r3 <== NOT EXECUTED int fchown( int fd, uid_t owner, gid_t group ) { 21dc4: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED 21dc8: e1a01821 lsr r1, r1, #16 <== NOT EXECUTED 21dcc: e1a02822 lsr r2, r2, #16 <== NOT EXECUTED rtems_libio_t *iop; rtems_libio_check_fd( fd ); 21dd0: 2a000005 bcs 21dec <== NOT EXECUTED iop = rtems_libio_iop( fd ); 21dd4: e59f3068 ldr r3, [pc, #104] ; 21e44 <== NOT EXECUTED 21dd8: e5933000 ldr r3, [r3] <== NOT EXECUTED 21ddc: e0830300 add r0, r3, r0, lsl #6 <== NOT EXECUTED rtems_libio_check_is_open(iop); 21de0: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED 21de4: e3130c01 tst r3, #256 ; 0x100 <== NOT EXECUTED 21de8: 1a000002 bne 21df8 <== NOT EXECUTED 21dec: eb0058f1 bl 381b8 <__errno> <== NOT EXECUTED 21df0: e3a03009 mov r3, #9 <== NOT EXECUTED 21df4: ea00000a b 21e24 <== NOT EXECUTED rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE ); 21df8: e3130004 tst r3, #4 <== NOT EXECUTED 21dfc: 1a000002 bne 21e0c <== NOT EXECUTED 21e00: eb0058ec bl 381b8 <__errno> <== NOT EXECUTED 21e04: e3a03016 mov r3, #22 <== NOT EXECUTED 21e08: ea000005 b 21e24 <== NOT EXECUTED if ( !iop->pathinfo.ops->chown_h ) 21e0c: e5903024 ldr r3, [r0, #36] ; 0x24 <== NOT EXECUTED 21e10: e5933018 ldr r3, [r3, #24] <== NOT EXECUTED 21e14: e3530000 cmp r3, #0 <== NOT EXECUTED 21e18: 1a000004 bne 21e30 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 21e1c: eb0058e5 bl 381b8 <__errno> <== NOT EXECUTED 21e20: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 21e24: e5803000 str r3, [r0] <== NOT EXECUTED 21e28: e3e00000 mvn r0, #0 <== NOT EXECUTED 21e2c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED return (*iop->pathinfo.ops->chown_h)( &iop->pathinfo, owner, group ); 21e30: e2800018 add r0, r0, #24 <== NOT EXECUTED 21e34: e1a0e00f mov lr, pc <== NOT EXECUTED 21e38: e12fff13 bx r3 <== NOT EXECUTED } 21e3c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED 21e40: 000522a0 .word 0x000522a0 21e44: 0005fbd0 .word 0x0005fbd0 00033130 : int fcntl( int fd, int cmd, ... ) { 33130: e92d000e push {r1, r2, r3} 33134: e92d40f1 push {r0, r4, r5, r6, r7, lr} int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd ); 33138: e59f31a4 ldr r3, [pc, #420] ; 332e4 3313c: e5933000 ldr r3, [r3] ... ) { int ret; va_list ap; va_start( ap, cmd ); 33140: e28d201c add r2, sp, #28 int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd ); 33144: e1500003 cmp r0, r3 ... ) { int ret; va_list ap; va_start( ap, cmd ); 33148: e58d2000 str r2, [sp] int fcntl( int fd, int cmd, ... ) { 3314c: e59d7018 ldr r7, [sp, #24] int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd ); 33150: 2a000005 bcs 3316c iop = rtems_libio_iop( fd ); 33154: e59f118c ldr r1, [pc, #396] ; 332e8 33158: e591c000 ldr ip, [r1] 3315c: e08c4300 add r4, ip, r0, lsl #6 rtems_libio_check_is_open(iop); 33160: e5940014 ldr r0, [r4, #20] 33164: e3100c01 tst r0, #256 ; 0x100 33168: 1a000002 bne 33178 3316c: eb001411 bl 381b8 <__errno> <== NOT EXECUTED 33170: e3a03009 mov r3, #9 <== NOT EXECUTED 33174: ea000045 b 33290 <== NOT EXECUTED /* * This switch should contain all the cases from POSIX. */ switch ( cmd ) { 33178: e3570009 cmp r7, #9 3317c: 979ff107 ldrls pc, [pc, r7, lsl #2] 33180: ea000040 b 33288 33184: 000331ac .word 0x000331ac <== NOT EXECUTED 33188: 00033218 .word 0x00033218 <== NOT EXECUTED 3318c: 00033224 .word 0x00033224 <== NOT EXECUTED 33190: 00033244 .word 0x00033244 <== NOT EXECUTED 33194: 00033250 .word 0x00033250 <== NOT EXECUTED 33198: 0003327c .word 0x0003327c <== NOT EXECUTED 3319c: 0003327c .word 0x0003327c <== NOT EXECUTED 331a0: 0003327c .word 0x0003327c <== NOT EXECUTED 331a4: 0003327c .word 0x0003327c <== NOT EXECUTED 331a8: 0003327c .word 0x0003327c <== NOT EXECUTED case F_DUPFD: /* dup */ fd2 = va_arg( ap, int ); 331ac: e5922000 ldr r2, [r2] if ( fd2 ) 331b0: e3520000 cmp r2, #0 331b4: 0a000003 beq 331c8 diop = rtems_libio_iop( fd2 ); 331b8: e1520003 cmp r2, r3 <== NOT EXECUTED 331bc: 23a0c000 movcs ip, #0 <== NOT EXECUTED 331c0: 308cc302 addcc ip, ip, r2, lsl #6 <== NOT EXECUTED 331c4: ea000002 b 331d4 <== NOT EXECUTED else { /* allocate a file control block */ diop = rtems_libio_allocate(); 331c8: ebff4674 bl 4ba0 if ( diop == 0 ) { 331cc: e250c000 subs ip, r0, #0 331d0: 0a00003e beq 332d0 } diop->handlers = iop->handlers; diop->file_info = iop->file_info; diop->flags = iop->flags; diop->pathinfo = iop->pathinfo; 331d4: e2846018 add r6, r4, #24 331d8: e8b6000f ldm r6!, {r0, r1, r2, r3} 331dc: e28c5018 add r5, ip, #24 331e0: e8a5000f stmia r5!, {r0, r1, r2, r3} ret = (int) (diop - rtems_libio_iops); 331e4: e59f30fc ldr r3, [pc, #252] ; 332e8 331e8: e5933000 ldr r3, [r3] } diop->handlers = iop->handlers; diop->file_info = iop->file_info; diop->flags = iop->flags; diop->pathinfo = iop->pathinfo; 331ec: e5966000 ldr r6, [r6] ret = -1; break; } } diop->handlers = iop->handlers; 331f0: e594003c ldr r0, [r4, #60] ; 0x3c diop->file_info = iop->file_info; 331f4: e5941038 ldr r1, [r4, #56] ; 0x38 diop->flags = iop->flags; 331f8: e5942014 ldr r2, [r4, #20] diop->pathinfo = iop->pathinfo; ret = (int) (diop - rtems_libio_iops); 331fc: e063300c rsb r3, r3, ip } diop->handlers = iop->handlers; diop->file_info = iop->file_info; diop->flags = iop->flags; diop->pathinfo = iop->pathinfo; 33200: e5856000 str r6, [r5] ret = -1; break; } } diop->handlers = iop->handlers; 33204: e58c003c str r0, [ip, #60] ; 0x3c diop->file_info = iop->file_info; 33208: e58c1038 str r1, [ip, #56] ; 0x38 diop->flags = iop->flags; 3320c: e58c2014 str r2, [ip, #20] diop->pathinfo = iop->pathinfo; ret = (int) (diop - rtems_libio_iops); 33210: e1a05343 asr r5, r3, #6 33214: ea00001f b 33298 break; case F_GETFD: /* get f_flags */ ret = ((iop->flags & LIBIO_FLAGS_CLOSE_ON_EXEC) != 0); 33218: e1a055a0 lsr r5, r0, #11 3321c: e2055001 and r5, r5, #1 33220: ea00001e b 332a0 * if a new process is exec()'ed. Since RTEMS does not support * processes, then we can ignore this one except to make * F_GETFD work. */ if ( va_arg( ap, int ) ) 33224: e5925000 ldr r5, [r2] 33228: e3550000 cmp r5, #0 iop->flags |= LIBIO_FLAGS_CLOSE_ON_EXEC; 3322c: 13800b02 orrne r0, r0, #2048 ; 0x800 else iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC; 33230: 03c00b02 biceq r0, r0, #2048 ; 0x800 * processes, then we can ignore this one except to make * F_GETFD work. */ if ( va_arg( ap, int ) ) iop->flags |= LIBIO_FLAGS_CLOSE_ON_EXEC; 33234: 15840014 strne r0, [r4, #20] else iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC; 33238: 05840014 streq r0, [r4, #20] * if a new process is exec()'ed. Since RTEMS does not support * processes, then we can ignore this one except to make * F_GETFD work. */ if ( va_arg( ap, int ) ) 3323c: 0a000017 beq 332a0 33240: ea00000b b 33274 else iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC; break; case F_GETFL: /* more flags (cloexec) */ ret = rtems_libio_to_fcntl_flags( iop->flags ); 33244: ebff45f7 bl 4a28 33248: e1a05000 mov r5, r0 3324c: ea000011 b 33298 break; case F_SETFL: flags = rtems_libio_fcntl_flags( va_arg( ap, int ) ); 33250: e5920000 ldr r0, [r2] 33254: ebff4677 bl 4c38 /* * XXX If we are turning on append, should we seek to the end? */ iop->flags = (iop->flags & ~mask) | (flags & mask); 33258: e5943014 ldr r3, [r4, #20] 3325c: e59f2088 ldr r2, [pc, #136] ; 332ec 33260: e3c33c02 bic r3, r3, #512 ; 0x200 33264: e0002002 and r2, r0, r2 33268: e3c33001 bic r3, r3, #1 3326c: e1823003 orr r3, r2, r3 33270: e5843014 str r3, [r4, #20] 33274: e3a05000 mov r5, #0 33278: ea000008 b 332a0 errno = ENOTSUP; ret = -1; break; case F_GETOWN: /* for sockets. */ errno = ENOTSUP; 3327c: eb0013cd bl 381b8 <__errno> 33280: e3a03086 mov r3, #134 ; 0x86 33284: ea000001 b 33290 ret = -1; break; default: errno = EINVAL; 33288: eb0013ca bl 381b8 <__errno> 3328c: e3a03016 mov r3, #22 33290: e5803000 str r3, [r0] 33294: ea00000d b 332d0 /* * If we got this far successfully, then we give the optional * filesystem specific handler a chance to process this. */ if (ret >= 0) { 33298: e3550000 cmp r5, #0 3329c: ba00000c blt 332d4 if (iop->handlers->fcntl_h) { 332a0: e594303c ldr r3, [r4, #60] ; 0x3c 332a4: e5933030 ldr r3, [r3, #48] ; 0x30 332a8: e3530000 cmp r3, #0 332ac: 0a000008 beq 332d4 int err = (*iop->handlers->fcntl_h)( cmd, iop ); 332b0: e1a01004 mov r1, r4 332b4: e1a00007 mov r0, r7 332b8: e1a0e00f mov lr, pc 332bc: e12fff13 bx r3 if (err) { 332c0: e2504000 subs r4, r0, #0 332c4: 0a000002 beq 332d4 errno = err; 332c8: eb0013ba bl 381b8 <__errno> <== NOT EXECUTED 332cc: e5804000 str r4, [r0] <== NOT EXECUTED 332d0: e3e05000 mvn r5, #0 va_list ap; va_start( ap, cmd ); ret = vfcntl(fd,cmd,ap); va_end(ap); return ret; } 332d4: e1a00005 mov r0, r5 332d8: e8bd40f8 pop {r3, r4, r5, r6, r7, lr} 332dc: e28dd00c add sp, sp, #12 332e0: e12fff1e bx lr 332e4: 000522a0 .word 0x000522a0 332e8: 0005fbd0 .word 0x0005fbd0 332ec: 00000201 .word 0x00000201 0000a964 : ) { pipe_control_t *pipe; int err = 0; if (rtems_semaphore_obtain(rtems_pipe_semaphore, a964: e59f3324 ldr r3, [pc, #804] ; ac90 */ int fifo_open( pipe_control_t **pipep, rtems_libio_t *iop ) { a968: e92d45f3 push {r0, r1, r4, r5, r6, r7, r8, sl, lr} a96c: e1a08001 mov r8, r1 ) { pipe_control_t *pipe; int err = 0; if (rtems_semaphore_obtain(rtems_pipe_semaphore, a970: e3a01000 mov r1, #0 */ int fifo_open( pipe_control_t **pipep, rtems_libio_t *iop ) { a974: e1a07000 mov r7, r0 ) { pipe_control_t *pipe; int err = 0; if (rtems_semaphore_obtain(rtems_pipe_semaphore, a978: e1a02001 mov r2, r1 a97c: e5930000 ldr r0, [r3] a980: ebffe838 bl 4a68 a984: e250a000 subs sl, r0, #0 a988: 13e06003 mvnne r6, #3 a98c: 1a0000bd bne ac88 RTEMS_WAIT, RTEMS_NO_TIMEOUT) != RTEMS_SUCCESSFUL) return -EINTR; pipe = *pipep; a990: e5974000 ldr r4, [r7] <== NOT EXECUTED if (pipe == NULL) { a994: e3540000 cmp r4, #0 <== NOT EXECUTED a998: 1a00003e bne aa98 <== NOT EXECUTED { static char c = 'a'; pipe_control_t *pipe; int err = -ENOMEM; pipe = malloc(sizeof(pipe_control_t)); a99c: e3a00034 mov r0, #52 ; 0x34 <== NOT EXECUTED a9a0: ebffdc9a bl 1c10 <== NOT EXECUTED if (pipe == NULL) a9a4: e3500000 cmp r0, #0 <== NOT EXECUTED { static char c = 'a'; pipe_control_t *pipe; int err = -ENOMEM; pipe = malloc(sizeof(pipe_control_t)); a9a8: e1a05000 mov r5, r0 <== NOT EXECUTED a9ac: e1a04000 mov r4, r0 <== NOT EXECUTED if (pipe == NULL) a9b0: 03e0600b mvneq r6, #11 <== NOT EXECUTED a9b4: 0a000045 beq aad0 <== NOT EXECUTED return err; memset(pipe, 0, sizeof(pipe_control_t)); a9b8: e1a0100a mov r1, sl <== NOT EXECUTED a9bc: e3a02034 mov r2, #52 ; 0x34 <== NOT EXECUTED a9c0: eb0006ac bl c478 <== NOT EXECUTED pipe->Size = PIPE_BUF; a9c4: e3a03c02 mov r3, #512 ; 0x200 <== NOT EXECUTED pipe->Buffer = malloc(pipe->Size); a9c8: e1a00003 mov r0, r3 <== NOT EXECUTED pipe = malloc(sizeof(pipe_control_t)); if (pipe == NULL) return err; memset(pipe, 0, sizeof(pipe_control_t)); pipe->Size = PIPE_BUF; a9cc: e5853004 str r3, [r5, #4] <== NOT EXECUTED pipe->Buffer = malloc(pipe->Size); a9d0: ebffdc8e bl 1c10 <== NOT EXECUTED if (! pipe->Buffer) a9d4: e3500000 cmp r0, #0 <== NOT EXECUTED if (pipe == NULL) return err; memset(pipe, 0, sizeof(pipe_control_t)); pipe->Size = PIPE_BUF; pipe->Buffer = malloc(pipe->Size); a9d8: e5850000 str r0, [r5] <== NOT EXECUTED if (! pipe->Buffer) a9dc: 03e0600b mvneq r6, #11 <== NOT EXECUTED a9e0: 0a000029 beq aa8c <== NOT EXECUTED goto err_buf; err = -EINTR; if (rtems_barrier_create( a9e4: e59f62a8 ldr r6, [pc, #680] ; ac94 <== NOT EXECUTED a9e8: e59f02a8 ldr r0, [pc, #680] ; ac98 <== NOT EXECUTED a9ec: e5d63000 ldrb r3, [r6] <== NOT EXECUTED a9f0: e1a0100a mov r1, sl <== NOT EXECUTED a9f4: e1830000 orr r0, r3, r0 <== NOT EXECUTED a9f8: e1a0200a mov r2, sl <== NOT EXECUTED a9fc: e285302c add r3, r5, #44 ; 0x2c <== NOT EXECUTED aa00: eb000164 bl af98 <== NOT EXECUTED aa04: e2501000 subs r1, r0, #0 <== NOT EXECUTED aa08: 1a00001c bne aa80 <== NOT EXECUTED rtems_build_name ('P', 'I', 'r', c), RTEMS_BARRIER_MANUAL_RELEASE, 0, &pipe->readBarrier) != RTEMS_SUCCESSFUL) goto err_rbar; if (rtems_barrier_create( aa0c: e5d63000 ldrb r3, [r6] <== NOT EXECUTED aa10: e59f0284 ldr r0, [pc, #644] ; ac9c <== NOT EXECUTED aa14: e1a02001 mov r2, r1 <== NOT EXECUTED aa18: e1830000 orr r0, r3, r0 <== NOT EXECUTED aa1c: e2853030 add r3, r5, #48 ; 0x30 <== NOT EXECUTED aa20: eb00015c bl af98 <== NOT EXECUTED aa24: e2503000 subs r3, r0, #0 <== NOT EXECUTED aa28: 1a000012 bne aa78 <== NOT EXECUTED rtems_build_name ('P', 'I', 'w', c), RTEMS_BARRIER_MANUAL_RELEASE, 0, &pipe->writeBarrier) != RTEMS_SUCCESSFUL) goto err_wbar; if (rtems_semaphore_create( aa2c: e5d62000 ldrb r2, [r6] <== NOT EXECUTED aa30: e59f0268 ldr r0, [pc, #616] ; aca0 <== NOT EXECUTED aa34: e285c028 add ip, r5, #40 ; 0x28 <== NOT EXECUTED aa38: e1820000 orr r0, r2, r0 <== NOT EXECUTED aa3c: e3a01001 mov r1, #1 <== NOT EXECUTED aa40: e3a02010 mov r2, #16 <== NOT EXECUTED aa44: e58dc000 str ip, [sp] <== NOT EXECUTED aa48: ebffe774 bl 4820 <== NOT EXECUTED aa4c: e3500000 cmp r0, #0 <== NOT EXECUTED aa50: 1a000006 bne aa70 <== NOT EXECUTED #ifdef RTEMS_POSIX_API pipe_interruptible(pipe); #endif *pipep = pipe; if (c ++ == 'z') aa54: e5d63000 ldrb r3, [r6] <== NOT EXECUTED aa58: e353007a cmp r3, #122 ; 0x7a <== NOT EXECUTED aa5c: e2833001 add r3, r3, #1 <== NOT EXECUTED aa60: e5c63000 strb r3, [r6] <== NOT EXECUTED c = 'a'; aa64: 03a03061 moveq r3, #97 ; 0x61 <== NOT EXECUTED aa68: 05c63000 strbeq r3, [r6] <== NOT EXECUTED aa6c: ea000009 b aa98 <== NOT EXECUTED return 0; err_sem: rtems_barrier_delete(pipe->writeBarrier); aa70: e5950030 ldr r0, [r5, #48] ; 0x30 <== NOT EXECUTED aa74: eb000175 bl b050 <== NOT EXECUTED err_wbar: rtems_barrier_delete(pipe->readBarrier); aa78: e595002c ldr r0, [r5, #44] ; 0x2c <== NOT EXECUTED aa7c: eb000173 bl b050 <== NOT EXECUTED err_rbar: free(pipe->Buffer); aa80: e5950000 ldr r0, [r5] <== NOT EXECUTED aa84: ebffdbaf bl 1948 <== NOT EXECUTED aa88: e3e06003 mvn r6, #3 <== NOT EXECUTED err_buf: free(pipe); aa8c: e1a00005 mov r0, r5 <== NOT EXECUTED aa90: ebffdbac bl 1948 <== NOT EXECUTED aa94: ea00000d b aad0 <== NOT EXECUTED err = pipe_alloc(&pipe); if (err) goto out; } if (! PIPE_LOCK(pipe)) aa98: e3a01000 mov r1, #0 <== NOT EXECUTED aa9c: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED aaa0: e1a02001 mov r2, r1 <== NOT EXECUTED aaa4: ebffe7ef bl 4a68 <== NOT EXECUTED err = -EINTR; if (*pipep == NULL) { aaa8: e5973000 ldr r3, [r7] <== NOT EXECUTED err = pipe_alloc(&pipe); if (err) goto out; } if (! PIPE_LOCK(pipe)) aaac: e3500000 cmp r0, #0 <== NOT EXECUTED aab0: 01a06000 moveq r6, r0 <== NOT EXECUTED aab4: 13e06003 mvnne r6, #3 <== NOT EXECUTED err = -EINTR; if (*pipep == NULL) { aab8: e3530000 cmp r3, #0 <== NOT EXECUTED aabc: 1a000003 bne aad0 <== NOT EXECUTED if (err) aac0: e3560000 cmp r6, #0 <== NOT EXECUTED pipe_free(pipe); else *pipep = pipe; aac4: 05874000 streq r4, [r7] <== NOT EXECUTED if (! PIPE_LOCK(pipe)) err = -EINTR; if (*pipep == NULL) { if (err) pipe_free(pipe); aac8: 11a00004 movne r0, r4 <== NOT EXECUTED aacc: 1bffff58 blne a834 <== NOT EXECUTED else *pipep = pipe; } out: rtems_semaphore_release(rtems_pipe_semaphore); aad0: e59f31b8 ldr r3, [pc, #440] ; ac90 <== NOT EXECUTED aad4: e5930000 ldr r0, [r3] <== NOT EXECUTED aad8: ebffe828 bl 4b80 <== NOT EXECUTED pipe_control_t *pipe; uint prevCounter; int err; err = pipe_new(pipep); if (err) aadc: e3560000 cmp r6, #0 <== NOT EXECUTED aae0: 1a000068 bne ac88 <== NOT EXECUTED return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { aae4: e5982014 ldr r2, [r8, #20] <== NOT EXECUTED aae8: e2023006 and r3, r2, #6 <== NOT EXECUTED aaec: e3530004 cmp r3, #4 <== NOT EXECUTED int err; err = pipe_new(pipep); if (err) return err; pipe = *pipep; aaf0: e5974000 ldr r4, [r7] <== NOT EXECUTED switch (LIBIO_ACCMODE(iop)) { aaf4: 0a000024 beq ab8c <== NOT EXECUTED aaf8: e3530006 cmp r3, #6 <== NOT EXECUTED aafc: 0a000046 beq ac1c <== NOT EXECUTED ab00: e3530002 cmp r3, #2 <== NOT EXECUTED ab04: 1a000058 bne ac6c <== NOT EXECUTED case LIBIO_FLAGS_READ: pipe->readerCounter ++; if (pipe->Readers ++ == 0) ab08: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { case LIBIO_FLAGS_READ: pipe->readerCounter ++; ab0c: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED if (pipe->Readers ++ == 0) ab10: e3530000 cmp r3, #0 <== NOT EXECUTED return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { case LIBIO_FLAGS_READ: pipe->readerCounter ++; ab14: e2822001 add r2, r2, #1 <== NOT EXECUTED if (pipe->Readers ++ == 0) ab18: e2833001 add r3, r3, #1 <== NOT EXECUTED return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { case LIBIO_FLAGS_READ: pipe->readerCounter ++; ab1c: e5842020 str r2, [r4, #32] <== NOT EXECUTED if (pipe->Readers ++ == 0) ab20: e5843010 str r3, [r4, #16] <== NOT EXECUTED PIPE_WAKEUPWRITERS(pipe); ab24: 05940030 ldreq r0, [r4, #48] ; 0x30 <== NOT EXECUTED ab28: 028d1004 addeq r1, sp, #4 <== NOT EXECUTED ab2c: 0b00015f bleq b0b0 <== NOT EXECUTED if (pipe->Writers == 0) { ab30: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED ab34: e3530000 cmp r3, #0 <== NOT EXECUTED ab38: 1a00004b bne ac6c <== NOT EXECUTED /* Not an error */ if (LIBIO_NODELAY(iop)) ab3c: e5983014 ldr r3, [r8, #20] <== NOT EXECUTED ab40: e3130001 tst r3, #1 <== NOT EXECUTED ab44: 1a000048 bne ac6c <== NOT EXECUTED break; prevCounter = pipe->writerCounter; ab48: e5945024 ldr r5, [r4, #36] ; 0x24 <== NOT EXECUTED err = -EINTR; /* Wait until a writer opens the pipe */ do { PIPE_UNLOCK(pipe); ab4c: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED ab50: ebffe80a bl 4b80 <== NOT EXECUTED if (! PIPE_READWAIT(pipe)) ab54: e3a01000 mov r1, #0 <== NOT EXECUTED ab58: e594002c ldr r0, [r4, #44] ; 0x2c <== NOT EXECUTED ab5c: eb000169 bl b108 <== NOT EXECUTED ab60: e2501000 subs r1, r0, #0 <== NOT EXECUTED goto out_error; if (! PIPE_LOCK(pipe)) ab64: e1a02001 mov r2, r1 <== NOT EXECUTED prevCounter = pipe->writerCounter; err = -EINTR; /* Wait until a writer opens the pipe */ do { PIPE_UNLOCK(pipe); if (! PIPE_READWAIT(pipe)) ab68: 1a000042 bne ac78 <== NOT EXECUTED goto out_error; if (! PIPE_LOCK(pipe)) ab6c: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED ab70: ebffe7bc bl 4a68 <== NOT EXECUTED ab74: e3500000 cmp r0, #0 <== NOT EXECUTED ab78: 1a00003e bne ac78 <== NOT EXECUTED goto out_error; } while (prevCounter == pipe->writerCounter); ab7c: e5943024 ldr r3, [r4, #36] ; 0x24 <== NOT EXECUTED ab80: e1550003 cmp r5, r3 <== NOT EXECUTED ab84: 0afffff0 beq ab4c <== NOT EXECUTED ab88: ea000037 b ac6c <== NOT EXECUTED } break; case LIBIO_FLAGS_WRITE: if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) { ab8c: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED ab90: e3530000 cmp r3, #0 <== NOT EXECUTED ab94: 1a000002 bne aba4 <== NOT EXECUTED ab98: e3120001 tst r2, #1 <== NOT EXECUTED ab9c: 13e06005 mvnne r6, #5 <== NOT EXECUTED aba0: 1a000035 bne ac7c <== NOT EXECUTED err = -ENXIO; goto out_error; } pipe->writerCounter ++; if (pipe->Writers ++ == 0) aba4: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) { err = -ENXIO; goto out_error; } pipe->writerCounter ++; aba8: e5942024 ldr r2, [r4, #36] ; 0x24 <== NOT EXECUTED if (pipe->Writers ++ == 0) abac: e3530000 cmp r3, #0 <== NOT EXECUTED if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) { err = -ENXIO; goto out_error; } pipe->writerCounter ++; abb0: e2822001 add r2, r2, #1 <== NOT EXECUTED if (pipe->Writers ++ == 0) abb4: e2833001 add r3, r3, #1 <== NOT EXECUTED if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) { err = -ENXIO; goto out_error; } pipe->writerCounter ++; abb8: e5842024 str r2, [r4, #36] ; 0x24 <== NOT EXECUTED if (pipe->Writers ++ == 0) abbc: e5843014 str r3, [r4, #20] <== NOT EXECUTED PIPE_WAKEUPREADERS(pipe); abc0: 0594002c ldreq r0, [r4, #44] ; 0x2c <== NOT EXECUTED abc4: 028d1004 addeq r1, sp, #4 <== NOT EXECUTED abc8: 0b000138 bleq b0b0 <== NOT EXECUTED if (pipe->Readers == 0) { abcc: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED abd0: e3530000 cmp r3, #0 <== NOT EXECUTED abd4: 1a000024 bne ac6c <== NOT EXECUTED prevCounter = pipe->readerCounter; abd8: e5945020 ldr r5, [r4, #32] <== NOT EXECUTED err = -EINTR; do { PIPE_UNLOCK(pipe); abdc: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED abe0: ebffe7e6 bl 4b80 <== NOT EXECUTED if (! PIPE_WRITEWAIT(pipe)) abe4: e3a01000 mov r1, #0 <== NOT EXECUTED abe8: e5940030 ldr r0, [r4, #48] ; 0x30 <== NOT EXECUTED abec: eb000145 bl b108 <== NOT EXECUTED abf0: e2501000 subs r1, r0, #0 <== NOT EXECUTED goto out_error; if (! PIPE_LOCK(pipe)) abf4: e1a02001 mov r2, r1 <== NOT EXECUTED if (pipe->Readers == 0) { prevCounter = pipe->readerCounter; err = -EINTR; do { PIPE_UNLOCK(pipe); if (! PIPE_WRITEWAIT(pipe)) abf8: 1a00001e bne ac78 <== NOT EXECUTED goto out_error; if (! PIPE_LOCK(pipe)) abfc: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED ac00: ebffe798 bl 4a68 <== NOT EXECUTED ac04: e3500000 cmp r0, #0 <== NOT EXECUTED ac08: 1a00001a bne ac78 <== NOT EXECUTED goto out_error; } while (prevCounter == pipe->readerCounter); ac0c: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED ac10: e1550003 cmp r5, r3 <== NOT EXECUTED ac14: 0afffff0 beq abdc <== NOT EXECUTED ac18: ea000013 b ac6c <== NOT EXECUTED } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) ac1c: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED } while (prevCounter == pipe->readerCounter); } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; ac20: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED if (pipe->Readers ++ == 0) ac24: e3530000 cmp r3, #0 <== NOT EXECUTED } while (prevCounter == pipe->readerCounter); } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; ac28: e2822001 add r2, r2, #1 <== NOT EXECUTED if (pipe->Readers ++ == 0) ac2c: e2833001 add r3, r3, #1 <== NOT EXECUTED } while (prevCounter == pipe->readerCounter); } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; ac30: e5842020 str r2, [r4, #32] <== NOT EXECUTED if (pipe->Readers ++ == 0) ac34: e5843010 str r3, [r4, #16] <== NOT EXECUTED PIPE_WAKEUPWRITERS(pipe); ac38: 05940030 ldreq r0, [r4, #48] ; 0x30 <== NOT EXECUTED ac3c: 028d1004 addeq r1, sp, #4 <== NOT EXECUTED ac40: 0b00011a bleq b0b0 <== NOT EXECUTED pipe->writerCounter ++; if (pipe->Writers ++ == 0) ac44: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) PIPE_WAKEUPWRITERS(pipe); pipe->writerCounter ++; ac48: e5942024 ldr r2, [r4, #36] ; 0x24 <== NOT EXECUTED if (pipe->Writers ++ == 0) ac4c: e3530000 cmp r3, #0 <== NOT EXECUTED case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) PIPE_WAKEUPWRITERS(pipe); pipe->writerCounter ++; ac50: e2822001 add r2, r2, #1 <== NOT EXECUTED if (pipe->Writers ++ == 0) ac54: e2833001 add r3, r3, #1 <== NOT EXECUTED case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) PIPE_WAKEUPWRITERS(pipe); pipe->writerCounter ++; ac58: e5842024 str r2, [r4, #36] ; 0x24 <== NOT EXECUTED if (pipe->Writers ++ == 0) ac5c: e5843014 str r3, [r4, #20] <== NOT EXECUTED PIPE_WAKEUPREADERS(pipe); ac60: 0594002c ldreq r0, [r4, #44] ; 0x2c <== NOT EXECUTED ac64: 028d1004 addeq r1, sp, #4 <== NOT EXECUTED ac68: 0b000110 bleq b0b0 <== NOT EXECUTED break; } PIPE_UNLOCK(pipe); ac6c: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED ac70: ebffe7c2 bl 4b80 <== NOT EXECUTED return 0; ac74: ea000003 b ac88 <== NOT EXECUTED ac78: e3e06003 mvn r6, #3 <== NOT EXECUTED out_error: pipe_release(pipep, iop); ac7c: e1a00007 mov r0, r7 <== NOT EXECUTED ac80: e1a01008 mov r1, r8 <== NOT EXECUTED ac84: ebfffef7 bl a868 <== NOT EXECUTED return err; } ac88: e1a00006 mov r0, r6 ac8c: e8bd85fc pop {r2, r3, r4, r5, r6, r7, r8, sl, pc} ac90: 00018acc .word 0x00018acc ac94: 00017768 .word 0x00017768 ac98: 50497200 .word 0x50497200 ac9c: 50497700 .word 0x50497700 aca0: 50497300 .word 0x50497300 000239c8 : /* * Search the mount table for any mount entries referencing this * mount entry. */ for ( the_node = rtems_filesystem_mount_table_control.first; 239c8: e59f3030 ldr r3, [pc, #48] ; 23a00 <== NOT EXECUTED 239cc: e4932004 ldr r2, [r3], #4 <== NOT EXECUTED 239d0: ea000006 b 239f0 <== NOT EXECUTED !rtems_chain_is_tail( &rtems_filesystem_mount_table_control, the_node ); the_node = the_node->next ) { the_mount_entry = ( rtems_filesystem_mount_table_entry_t * )the_node; if (the_mount_entry->mt_point_node.mt_entry == fs_root_loc->mt_entry ) { 239d4: e592c018 ldr ip, [r2, #24] <== NOT EXECUTED 239d8: e5910010 ldr r0, [r1, #16] <== NOT EXECUTED 239dc: e15c0000 cmp ip, r0 <== NOT EXECUTED 239e0: 1a000001 bne 239ec <== NOT EXECUTED 239e4: e3a00001 mov r0, #1 <== NOT EXECUTED 239e8: e12fff1e bx lr <== NOT EXECUTED * mount entry. */ for ( the_node = rtems_filesystem_mount_table_control.first; !rtems_chain_is_tail( &rtems_filesystem_mount_table_control, the_node ); the_node = the_node->next ) { 239ec: e5922000 ldr r2, [r2] <== NOT EXECUTED 239f0: e1520003 cmp r2, r3 <== NOT EXECUTED 239f4: 1afffff6 bne 239d4 <== NOT EXECUTED 239f8: e3a00000 mov r0, #0 <== NOT EXECUTED return true; } } return false; } 239fc: e12fff1e bx lr <== NOT EXECUTED 23a00: 0005fc14 .word 0x0005fc14 00002a04 : { long return_value; rtems_libio_t *iop; rtems_filesystem_limits_and_options_t *the_limits; rtems_libio_check_fd(fd); 2a04: e59f3100 ldr r3, [pc, #256] ; 2b0c 2a08: e5933000 ldr r3, [r3] 2a0c: e1500003 cmp r0, r3 long fpathconf( int fd, int name ) { 2a10: e52de004 push {lr} ; (str lr, [sp, #-4]!) long return_value; rtems_libio_t *iop; rtems_filesystem_limits_and_options_t *the_limits; rtems_libio_check_fd(fd); 2a14: 2a000005 bcs 2a30 iop = rtems_libio_iop(fd); 2a18: e59f30f0 ldr r3, [pc, #240] ; 2b10 2a1c: e5933000 ldr r3, [r3] 2a20: e0830300 add r0, r3, r0, lsl #6 rtems_libio_check_is_open(iop); 2a24: e5903014 ldr r3, [r0, #20] 2a28: e3130c01 tst r3, #256 ; 0x100 2a2c: 1a000002 bne 2a3c 2a30: eb002dc9 bl e15c <__errno> 2a34: e3a03009 mov r3, #9 2a38: ea000003 b 2a4c rtems_libio_check_permissions(iop, LIBIO_FLAGS_READ); 2a3c: e3130002 tst r3, #2 2a40: 1a000004 bne 2a58 2a44: eb002dc4 bl e15c <__errno> <== NOT EXECUTED 2a48: e3a03016 mov r3, #22 <== NOT EXECUTED 2a4c: e5803000 str r3, [r0] 2a50: e3e00000 mvn r0, #0 2a54: e49df004 pop {pc} ; (ldr pc, [sp], #4) /* * Now process the information request. */ the_limits = &iop->pathinfo.mt_entry->pathconf_limits_and_options; 2a58: e5903028 ldr r3, [r0, #40] ; 0x28 switch ( name ) { 2a5c: e351000b cmp r1, #11 2a60: 979ff101 ldrls pc, [pc, r1, lsl #2] 2a64: ea000023 b 2af8 2a68: 00002a98 .word 0x00002a98 <== NOT EXECUTED 2a6c: 00002aa0 .word 0x00002aa0 <== NOT EXECUTED 2a70: 00002aa8 .word 0x00002aa8 <== NOT EXECUTED 2a74: 00002ab0 .word 0x00002ab0 <== NOT EXECUTED 2a78: 00002ab8 .word 0x00002ab8 <== NOT EXECUTED 2a7c: 00002ac0 .word 0x00002ac0 <== NOT EXECUTED 2a80: 00002ac8 .word 0x00002ac8 <== NOT EXECUTED 2a84: 00002ad0 .word 0x00002ad0 <== NOT EXECUTED 2a88: 00002ad8 .word 0x00002ad8 <== NOT EXECUTED 2a8c: 00002ae0 .word 0x00002ae0 <== NOT EXECUTED 2a90: 00002ae8 .word 0x00002ae8 <== NOT EXECUTED 2a94: 00002af0 .word 0x00002af0 <== NOT EXECUTED case _PC_LINK_MAX: return_value = the_limits->link_max; 2a98: e5930038 ldr r0, [r3, #56] ; 0x38 break; 2a9c: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_MAX_CANON: return_value = the_limits->max_canon; 2aa0: e593003c ldr r0, [r3, #60] ; 0x3c break; 2aa4: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_MAX_INPUT: return_value = the_limits->max_input; 2aa8: e5930040 ldr r0, [r3, #64] ; 0x40 break; 2aac: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_NAME_MAX: return_value = the_limits->name_max; 2ab0: e5930044 ldr r0, [r3, #68] ; 0x44 break; 2ab4: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_PATH_MAX: return_value = the_limits->path_max; 2ab8: e5930048 ldr r0, [r3, #72] ; 0x48 break; 2abc: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_PIPE_BUF: return_value = the_limits->pipe_buf; 2ac0: e593004c ldr r0, [r3, #76] ; 0x4c break; 2ac4: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_CHOWN_RESTRICTED: return_value = the_limits->posix_chown_restrictions; 2ac8: e5930054 ldr r0, [r3, #84] ; 0x54 break; 2acc: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_NO_TRUNC: return_value = the_limits->posix_no_trunc; 2ad0: e5930058 ldr r0, [r3, #88] ; 0x58 break; 2ad4: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_VDISABLE: return_value = the_limits->posix_vdisable; 2ad8: e5930064 ldr r0, [r3, #100] ; 0x64 break; 2adc: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_ASYNC_IO: return_value = the_limits->posix_async_io; 2ae0: e5930050 ldr r0, [r3, #80] ; 0x50 break; 2ae4: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_PRIO_IO: return_value = the_limits->posix_prio_io; 2ae8: e593005c ldr r0, [r3, #92] ; 0x5c break; 2aec: e49df004 pop {pc} ; (ldr pc, [sp], #4) case _PC_SYNC_IO: return_value = the_limits->posix_sync_io; 2af0: e5930060 ldr r0, [r3, #96] ; 0x60 break; 2af4: e49df004 pop {pc} ; (ldr pc, [sp], #4) default: rtems_set_errno_and_return_minus_one( EINVAL ); 2af8: eb002d97 bl e15c <__errno> 2afc: e3a03016 mov r3, #22 2b00: e5803000 str r3, [r0] 2b04: e3e00000 mvn r0, #0 break; } return return_value; } 2b08: e49df004 pop {pc} ; (ldr pc, [sp], #4) 2b0c: 0001af40 .word 0x0001af40 2b10: 0001c9d8 .word 0x0001c9d8 00001948 : void free( void *ptr ) { MSBUMP(free_calls, 1); 1948: e59f3088 ldr r3, [pc, #136] ; 19d8 194c: e593200c ldr r2, [r3, #12] 1950: e92d4030 push {r4, r5, lr} 1954: e2822001 add r2, r2, #1 if ( !ptr ) 1958: e2504000 subs r4, r0, #0 void free( void *ptr ) { MSBUMP(free_calls, 1); 195c: e583200c str r2, [r3, #12] if ( !ptr ) 1960: 08bd8030 popeq {r4, r5, pc} /* * Do not attempt to free memory if in a critical section or ISR. */ if ( _System_state_Is_up(_System_state_Get()) && 1964: e59f3070 ldr r3, [pc, #112] ; 19dc 1968: e5933000 ldr r3, [r3] 196c: e3530003 cmp r3, #3 1970: 1a000005 bne 198c 1974: eb00004b bl 1aa8 1978: e3500000 cmp r0, #0 197c: 1a000002 bne 198c !malloc_is_system_state_OK() ) { malloc_deferred_free(ptr); 1980: e1a00004 mov r0, r4 <== NOT EXECUTED RTEMS_Malloc_Heap->area_begin, RTEMS_Malloc_Heap->area_end ); } } 1984: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED * Do not attempt to free memory if in a critical section or ISR. */ if ( _System_state_Is_up(_System_state_Get()) && !malloc_is_system_state_OK() ) { malloc_deferred_free(ptr); 1988: ea000059 b 1af4 <== NOT EXECUTED #endif /* * If configured, update the statistics */ if ( rtems_malloc_statistics_helpers ) 198c: e59f304c ldr r3, [pc, #76] ; 19e0 1990: e5933000 ldr r3, [r3] 1994: e3530000 cmp r3, #0 (*rtems_malloc_statistics_helpers->at_free)(ptr); 1998: 11a00004 movne r0, r4 199c: 11a0e00f movne lr, pc 19a0: 1593f008 ldrne pc, [r3, #8] if ( !_Protected_heap_Free( RTEMS_Malloc_Heap, ptr ) ) { 19a4: e59f5038 ldr r5, [pc, #56] ; 19e4 19a8: e1a01004 mov r1, r4 19ac: e5950000 ldr r0, [r5] 19b0: eb00125a bl 6320 <_Protected_heap_Free> 19b4: e3500000 cmp r0, #0 19b8: 18bd8030 popne {r4, r5, pc} printk( "Program heap: free of bad pointer %p -- range %p - %p \n", ptr, RTEMS_Malloc_Heap->area_begin, 19bc: e5952000 ldr r2, [r5] <== NOT EXECUTED */ if ( rtems_malloc_statistics_helpers ) (*rtems_malloc_statistics_helpers->at_free)(ptr); if ( !_Protected_heap_Free( RTEMS_Malloc_Heap, ptr ) ) { printk( "Program heap: free of bad pointer %p -- range %p - %p \n", 19c0: e59f0020 ldr r0, [pc, #32] ; 19e8 <== NOT EXECUTED 19c4: e2822018 add r2, r2, #24 <== NOT EXECUTED 19c8: e892000c ldm r2, {r2, r3} <== NOT EXECUTED 19cc: e1a01004 mov r1, r4 <== NOT EXECUTED RTEMS_Malloc_Heap->area_begin, RTEMS_Malloc_Heap->area_end ); } } 19d0: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED */ if ( rtems_malloc_statistics_helpers ) (*rtems_malloc_statistics_helpers->at_free)(ptr); if ( !_Protected_heap_Free( RTEMS_Malloc_Heap, ptr ) ) { printk( "Program heap: free of bad pointer %p -- range %p - %p \n", 19d4: ea000320 b 265c <== NOT EXECUTED 19d8: 00018cc8 .word 0x00018cc8 19dc: 00018fd0 .word 0x00018fd0 19e0: 000189a8 .word 0x000189a8 19e4: 0001758c .word 0x0001758c 19e8: 000184c2 .word 0x000184c2 000230b0 : static void free_user_env(void *venv) { rtems_user_env_t *env = (rtems_user_env_t*) venv ; if (env != &rtems_global_user_env 230b0: e59f3058 ldr r3, [pc, #88] ; 23110 <== NOT EXECUTED 230b4: e1500003 cmp r0, r3 <== NOT EXECUTED * NOTE: this must be called with * thread dispatching disabled! */ static void free_user_env(void *venv) { 230b8: e92d4010 push {r4, lr} <== NOT EXECUTED 230bc: e1a04000 mov r4, r0 <== NOT EXECUTED rtems_user_env_t *env = (rtems_user_env_t*) venv ; if (env != &rtems_global_user_env 230c0: 08bd8010 popeq {r4, pc} <== NOT EXECUTED #ifdef HAVE_USERENV_REFCNT && --env->refcnt <= 0 #endif ) { rtems_filesystem_freenode( &env->current_directory); 230c4: e5903010 ldr r3, [r0, #16] <== NOT EXECUTED 230c8: e3530000 cmp r3, #0 <== NOT EXECUTED 230cc: 0a000004 beq 230e4 <== NOT EXECUTED 230d0: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 230d4: e3530000 cmp r3, #0 <== NOT EXECUTED 230d8: 12800004 addne r0, r0, #4 <== NOT EXECUTED 230dc: 11a0e00f movne lr, pc <== NOT EXECUTED 230e0: 112fff13 bxne r3 <== NOT EXECUTED rtems_filesystem_freenode( &env->root_directory); 230e4: e5943024 ldr r3, [r4, #36] ; 0x24 <== NOT EXECUTED 230e8: e3530000 cmp r3, #0 <== NOT EXECUTED 230ec: 0a000004 beq 23104 <== NOT EXECUTED 230f0: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 230f4: e3530000 cmp r3, #0 <== NOT EXECUTED 230f8: 12840018 addne r0, r4, #24 <== NOT EXECUTED 230fc: 11a0e00f movne lr, pc <== NOT EXECUTED 23100: 112fff13 bxne r3 <== NOT EXECUTED free(env); 23104: e1a00004 mov r0, r4 <== NOT EXECUTED } } 23108: e8bd4010 pop {r4, lr} <== NOT EXECUTED && --env->refcnt <= 0 #endif ) { rtems_filesystem_freenode( &env->current_directory); rtems_filesystem_freenode( &env->root_directory); free(env); 2310c: eaff85c8 b 4834 <== NOT EXECUTED 23110: 0005fc2c .word 0x0005fc2c 00016a5c : int fstat( int fd, struct stat *sbuf ) { 16a5c: e92d4030 push {r4, r5, lr} /* * Check to see if we were passed a valid pointer. */ if ( !sbuf ) 16a60: e2515000 subs r5, r1, #0 16a64: 1a000002 bne 16a74 rtems_set_errno_and_return_minus_one( EFAULT ); 16a68: ebffd438 bl bb50 <__errno> 16a6c: e3a0300e mov r3, #14 16a70: ea000014 b 16ac8 /* * Now process the stat() request. */ iop = rtems_libio_iop( fd ); 16a74: e59f3080 ldr r3, [pc, #128] ; 16afc 16a78: e5933000 ldr r3, [r3] 16a7c: e1500003 cmp r0, r3 16a80: 2a000008 bcs 16aa8 16a84: e59f3074 ldr r3, [pc, #116] ; 16b00 16a88: e5934000 ldr r4, [r3] 16a8c: e0844300 add r4, r4, r0, lsl #6 rtems_libio_check_fd( fd ); rtems_libio_check_is_open(iop); 16a90: e5943014 ldr r3, [r4, #20] 16a94: e3130c01 tst r3, #256 ; 0x100 16a98: 0a000002 beq 16aa8 if ( !iop->handlers ) 16a9c: e594303c ldr r3, [r4, #60] ; 0x3c 16aa0: e3530000 cmp r3, #0 16aa4: 1a000002 bne 16ab4 rtems_set_errno_and_return_minus_one( EBADF ); 16aa8: ebffd428 bl bb50 <__errno> 16aac: e3a03009 mov r3, #9 16ab0: ea000004 b 16ac8 if ( !iop->handlers->fstat_h ) 16ab4: e5933018 ldr r3, [r3, #24] 16ab8: e3530000 cmp r3, #0 16abc: 1a000004 bne 16ad4 rtems_set_errno_and_return_minus_one( ENOTSUP ); 16ac0: ebffd422 bl bb50 <__errno> <== NOT EXECUTED 16ac4: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 16ac8: e5803000 str r3, [r0] 16acc: e3e00000 mvn r0, #0 16ad0: e8bd8030 pop {r4, r5, pc} /* * Zero out the stat structure so the various support * versions of stat don't have to. */ memset( sbuf, 0, sizeof(struct stat) ); 16ad4: e3a01000 mov r1, #0 16ad8: e3a02048 mov r2, #72 ; 0x48 16adc: e1a00005 mov r0, r5 16ae0: ebffd664 bl c478 return (*iop->handlers->fstat_h)( &iop->pathinfo, sbuf ); 16ae4: e2840018 add r0, r4, #24 16ae8: e1a01005 mov r1, r5 16aec: e594303c ldr r3, [r4, #60] ; 0x3c 16af0: e1a0e00f mov lr, pc 16af4: e593f018 ldr pc, [r3, #24] } 16af8: e8bd8030 pop {r4, r5, pc} 16afc: 00017580 .word 0x00017580 16b00: 00018cb0 .word 0x00018cb0 00021efc : int fd ) { rtems_libio_t *iop; rtems_libio_check_fd( fd ); 21efc: e59f307c ldr r3, [pc, #124] ; 21f80 21f00: e5933000 ldr r3, [r3] 21f04: e1500003 cmp r0, r3 #include int fsync( int fd ) { 21f08: e52de004 push {lr} ; (str lr, [sp, #-4]!) rtems_libio_t *iop; rtems_libio_check_fd( fd ); 21f0c: 2a00000d bcs 21f48 iop = rtems_libio_iop( fd ); 21f10: e59f306c ldr r3, [pc, #108] ; 21f84 21f14: e5933000 ldr r3, [r3] 21f18: e0830300 add r0, r3, r0, lsl #6 rtems_libio_check_is_open(iop); 21f1c: e5903014 ldr r3, [r0, #20] 21f20: e3130c01 tst r3, #256 ; 0x100 21f24: 0a000007 beq 21f48 rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE ); 21f28: e3130004 tst r3, #4 21f2c: 1a000002 bne 21f3c 21f30: eb0058a0 bl 381b8 <__errno> 21f34: e3a03016 mov r3, #22 21f38: ea00000a b 21f68 /* * Now process the fsync(). */ if ( !iop->handlers ) 21f3c: e590303c ldr r3, [r0, #60] ; 0x3c 21f40: e3530000 cmp r3, #0 21f44: 1a000002 bne 21f54 rtems_set_errno_and_return_minus_one( EBADF ); 21f48: eb00589a bl 381b8 <__errno> <== NOT EXECUTED 21f4c: e3a03009 mov r3, #9 <== NOT EXECUTED 21f50: ea000004 b 21f68 <== NOT EXECUTED if ( !iop->handlers->fsync_h ) 21f54: e5933028 ldr r3, [r3, #40] ; 0x28 21f58: e3530000 cmp r3, #0 21f5c: 1a000004 bne 21f74 rtems_set_errno_and_return_minus_one( ENOTSUP ); 21f60: eb005894 bl 381b8 <__errno> 21f64: e3a03086 mov r3, #134 ; 0x86 21f68: e5803000 str r3, [r0] 21f6c: e3e00000 mvn r0, #0 21f70: e49df004 pop {pc} ; (ldr pc, [sp], #4) return (*iop->handlers->fsync_h)( iop ); 21f74: e1a0e00f mov lr, pc 21f78: e12fff13 bx r3 } 21f7c: e49df004 pop {pc} ; (ldr pc, [sp], #4) 21f80: 000522a0 .word 0x000522a0 21f84: 0005fbd0 .word 0x0005fbd0 00008f7c : int ftruncate( int fd, off_t length ) { 8f7c: e92d4070 push {r4, r5, r6, lr} rtems_libio_t *iop; rtems_filesystem_location_info_t loc; rtems_libio_check_fd( fd ); 8f80: e59f30d4 ldr r3, [pc, #212] ; 905c 8f84: e5933000 ldr r3, [r3] 8f88: e1500003 cmp r0, r3 int ftruncate( int fd, off_t length ) { 8f8c: e24dd014 sub sp, sp, #20 8f90: e1a05001 mov r5, r1 8f94: e1a06002 mov r6, r2 rtems_libio_t *iop; rtems_filesystem_location_info_t loc; rtems_libio_check_fd( fd ); 8f98: 2a000005 bcs 8fb4 iop = rtems_libio_iop( fd ); 8f9c: e59f30bc ldr r3, [pc, #188] ; 9060 8fa0: e5934000 ldr r4, [r3] 8fa4: e0844300 add r4, r4, r0, lsl #6 rtems_libio_check_is_open(iop); 8fa8: e5943014 ldr r3, [r4, #20] 8fac: e3130c01 tst r3, #256 ; 0x100 8fb0: 1a000002 bne 8fc0 8fb4: eb000ae5 bl bb50 <__errno> <== NOT EXECUTED 8fb8: e3a03009 mov r3, #9 <== NOT EXECUTED 8fbc: ea00001c b 9034 <== NOT EXECUTED /* * Make sure we are not working on a directory */ loc = iop->pathinfo; 8fc0: e284e018 add lr, r4, #24 8fc4: e8be000f ldm lr!, {r0, r1, r2, r3} 8fc8: e1a0c00d mov ip, sp 8fcc: e8ac000f stmia ip!, {r0, r1, r2, r3} if ( !loc.ops->node_type_h ) 8fd0: e5933010 ldr r3, [r3, #16] /* * Make sure we are not working on a directory */ loc = iop->pathinfo; 8fd4: e59e2000 ldr r2, [lr] if ( !loc.ops->node_type_h ) 8fd8: e3530000 cmp r3, #0 /* * Make sure we are not working on a directory */ loc = iop->pathinfo; 8fdc: e58c2000 str r2, [ip] if ( !loc.ops->node_type_h ) 8fe0: 0a000011 beq 902c rtems_set_errno_and_return_minus_one( ENOTSUP ); if ( (*loc.ops->node_type_h)( &loc ) == RTEMS_FILESYSTEM_DIRECTORY ) 8fe4: e1a0000d mov r0, sp 8fe8: e1a0e00f mov lr, pc 8fec: e12fff13 bx r3 8ff0: e3500001 cmp r0, #1 8ff4: 1a000002 bne 9004 rtems_set_errno_and_return_minus_one( EISDIR ); 8ff8: eb000ad4 bl bb50 <__errno> 8ffc: e3a03015 mov r3, #21 9000: ea00000b b 9034 rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE ); 9004: e5943014 ldr r3, [r4, #20] 9008: e3130004 tst r3, #4 900c: 1a000002 bne 901c 9010: eb000ace bl bb50 <__errno> <== NOT EXECUTED 9014: e3a03016 mov r3, #22 <== NOT EXECUTED 9018: ea000005 b 9034 <== NOT EXECUTED if ( !iop->handlers->ftruncate_h ) 901c: e594303c ldr r3, [r4, #60] ; 0x3c 9020: e5933020 ldr r3, [r3, #32] 9024: e3530000 cmp r3, #0 9028: 1a000004 bne 9040 rtems_set_errno_and_return_minus_one( ENOTSUP ); 902c: eb000ac7 bl bb50 <__errno> <== NOT EXECUTED 9030: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 9034: e5803000 str r3, [r0] 9038: e3e00000 mvn r0, #0 903c: ea000004 b 9054 return (*iop->handlers->ftruncate_h)( iop, length ); 9040: e1a00004 mov r0, r4 9044: e1a01005 mov r1, r5 9048: e1a02006 mov r2, r6 904c: e1a0e00f mov lr, pc 9050: e12fff13 bx r3 } 9054: e28dd014 add sp, sp, #20 9058: e8bd8070 pop {r4, r5, r6, pc} 905c: 00017580 .word 0x00017580 9060: 00018cb0 .word 0x00018cb0 00051c6c : /* * Get the file control block structure associated with the file descriptor */ iop = rtems_libio_iop( dd_fd ); 51c6c: e59f30a8 ldr r3, [pc, #168] ; 51d1c 51c70: e5933000 ldr r3, [r3] 51c74: e1500003 cmp r0, r3 51c78: 359f30a0 ldrcc r3, [pc, #160] ; 51d20 int getdents( int dd_fd, char *dd_buf, int dd_len ) { 51c7c: e92d4070 push {r4, r5, r6, lr} /* * Get the file control block structure associated with the file descriptor */ iop = rtems_libio_iop( dd_fd ); 51c80: 35934000 ldrcc r4, [r3] 51c84: 23a04000 movcs r4, #0 51c88: 30844300 addcc r4, r4, r0, lsl #6 /* * Make sure we are working on a directory */ loc = iop->pathinfo; 51c8c: e284e018 add lr, r4, #24 int getdents( int dd_fd, char *dd_buf, int dd_len ) { 51c90: e24dd014 sub sp, sp, #20 51c94: e1a06001 mov r6, r1 51c98: e1a05002 mov r5, r2 iop = rtems_libio_iop( dd_fd ); /* * Make sure we are working on a directory */ loc = iop->pathinfo; 51c9c: e8be000f ldm lr!, {r0, r1, r2, r3} 51ca0: e1a0c00d mov ip, sp 51ca4: e8ac000f stmia ip!, {r0, r1, r2, r3} if ( !loc.ops->node_type_h ) 51ca8: e5933010 ldr r3, [r3, #16] iop = rtems_libio_iop( dd_fd ); /* * Make sure we are working on a directory */ loc = iop->pathinfo; 51cac: e59e2000 ldr r2, [lr] if ( !loc.ops->node_type_h ) 51cb0: e3530000 cmp r3, #0 iop = rtems_libio_iop( dd_fd ); /* * Make sure we are working on a directory */ loc = iop->pathinfo; 51cb4: e58c2000 str r2, [ip] if ( !loc.ops->node_type_h ) 51cb8: 0a00000d beq 51cf4 rtems_set_errno_and_return_minus_one( ENOTSUP ); if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) 51cbc: e1a0000d mov r0, sp 51cc0: e1a0e00f mov lr, pc 51cc4: e12fff13 bx r3 51cc8: e3500001 cmp r0, #1 51ccc: 0a000004 beq 51ce4 rtems_set_errno_and_return_minus_one( ENOTDIR ); 51cd0: ebff9938 bl 381b8 <__errno> 51cd4: e3a03014 mov r3, #20 51cd8: e5803000 str r3, [r0] 51cdc: e3e00000 mvn r0, #0 51ce0: ea00000b b 51d14 /* * Return the number of bytes that were actually transfered as a result * of the read attempt. */ if ( !iop->handlers->read_h ) 51ce4: e594303c ldr r3, [r4, #60] ; 0x3c 51ce8: e5933008 ldr r3, [r3, #8] 51cec: e3530000 cmp r3, #0 51cf0: 1a000002 bne 51d00 rtems_set_errno_and_return_minus_one( ENOTSUP ); 51cf4: ebff992f bl 381b8 <__errno> <== NOT EXECUTED 51cf8: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 51cfc: eafffff5 b 51cd8 <== NOT EXECUTED return (*iop->handlers->read_h)( iop, dd_buf, dd_len ); 51d00: e1a00004 mov r0, r4 51d04: e1a01006 mov r1, r6 51d08: e1a02005 mov r2, r5 51d0c: e1a0e00f mov lr, pc 51d10: e12fff13 bx r3 } 51d14: e28dd014 add sp, sp, #20 51d18: e8bd8070 pop {r4, r5, r6, pc} 51d1c: 000522a0 .word 0x000522a0 51d20: 0005fbd0 .word 0x0005fbd0 00022098 : * 4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs, * P1003.1b-1993, p. 84 */ gid_t getgid( void ) { 22098: e59f3008 ldr r3, [pc, #8] ; 220a8 <== NOT EXECUTED 2209c: e5933000 ldr r3, [r3] <== NOT EXECUTED return _POSIX_types_Gid; } 220a0: e1d303b4 ldrh r0, [r3, #52] ; 0x34 <== NOT EXECUTED 220a4: e12fff1e bx lr <== NOT EXECUTED 220a8: 00052578 .word 0x00052578 000226a0 : struct group *grp, char *buffer, size_t bufsize, struct group **result ) { 226a0: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} 226a4: e59da01c ldr sl, [sp, #28] 226a8: e1a06000 mov r6, r0 226ac: e1a07001 mov r7, r1 226b0: e1a04002 mov r4, r2 226b4: e1a08003 mov r8, r3 FILE *fp; int match; init_etc_passwd_group(); 226b8: ebffffb7 bl 2259c if ((fp = fopen("/etc/group", "r")) == NULL) { 226bc: e59f00a4 ldr r0, [pc, #164] ; 22768 226c0: e59f10a4 ldr r1, [pc, #164] ; 2276c 226c4: eb00592b bl 38b78 226c8: e2505000 subs r5, r0, #0 226cc: 1a000003 bne 226e0 errno = EINVAL; 226d0: eb0056b8 bl 381b8 <__errno> <== NOT EXECUTED 226d4: e3a03016 mov r3, #22 <== NOT EXECUTED 226d8: e5803000 str r3, [r0] <== NOT EXECUTED 226dc: ea00000c b 22714 <== NOT EXECUTED return -1; } for(;;) { if (!scangr(fp, grp, buffer, bufsize)) { 226e0: e1a01004 mov r1, r4 226e4: e1a02008 mov r2, r8 226e8: e1a0300a mov r3, sl 226ec: e1a00005 mov r0, r5 226f0: ebfffef2 bl 222c0 226f4: e3500000 cmp r0, #0 errno = EINVAL; fclose(fp); return -1; } if (name) { match = (strcmp(grp->gr_name, name) == 0); 226f8: e1a01006 mov r1, r6 if ((fp = fopen("/etc/group", "r")) == NULL) { errno = EINVAL; return -1; } for(;;) { if (!scangr(fp, grp, buffer, bufsize)) { 226fc: 1a000006 bne 2271c errno = EINVAL; 22700: eb0056ac bl 381b8 <__errno> <== NOT EXECUTED 22704: e3a03016 mov r3, #22 <== NOT EXECUTED 22708: e5803000 str r3, [r0] <== NOT EXECUTED fclose(fp); 2270c: e1a00005 mov r0, r5 <== NOT EXECUTED 22710: eb0056f5 bl 382ec <== NOT EXECUTED 22714: e3e00000 mvn r0, #0 <== NOT EXECUTED return -1; 22718: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED } if (name) { 2271c: e3560000 cmp r6, #0 22720: 0a000004 beq 22738 match = (strcmp(grp->gr_name, name) == 0); 22724: e5940000 ldr r0, [r4] 22728: eb006eb4 bl 3e200 2272c: e2700001 rsbs r0, r0, #1 22730: 33a00000 movcc r0, #0 22734: ea000003 b 22748 } else { match = (grp->gr_gid == gid); 22738: e1d400b8 ldrh r0, [r4, #8] <== NOT EXECUTED 2273c: e1500007 cmp r0, r7 <== NOT EXECUTED 22740: 13a00000 movne r0, #0 <== NOT EXECUTED 22744: 03a00001 moveq r0, #1 <== NOT EXECUTED } if (match) { 22748: e3500000 cmp r0, #0 2274c: 0affffe3 beq 226e0 fclose(fp); 22750: e1a00005 mov r0, r5 22754: eb0056e4 bl 382ec *result = grp; 22758: e59d3020 ldr r3, [sp, #32] 2275c: e3a00000 mov r0, #0 22760: e5834000 str r4, [r3] } } fclose(fp); errno = EINVAL; return -1; } 22764: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 22768: 00056520 .word 0x00056520 2276c: 00057113 .word 0x00057113 000223f8 : return NULL; return p; } struct group *getgrent(void) { 223f8: e92d4010 push {r4, lr} <== NOT EXECUTED if (group_fp == NULL) 223fc: e59f402c ldr r4, [pc, #44] ; 22430 <== NOT EXECUTED 22400: e5940000 ldr r0, [r4] <== NOT EXECUTED 22404: e3500000 cmp r0, #0 <== NOT EXECUTED 22408: 0a000006 beq 22428 <== NOT EXECUTED return NULL; if (!scangr(group_fp, &grent, grbuf, sizeof grbuf)) 2240c: e2841008 add r1, r4, #8 <== NOT EXECUTED 22410: e2842018 add r2, r4, #24 <== NOT EXECUTED 22414: e3a030c8 mov r3, #200 ; 0xc8 <== NOT EXECUTED 22418: ebffffa8 bl 222c0 <== NOT EXECUTED 2241c: e3500000 cmp r0, #0 <== NOT EXECUTED 22420: 12840008 addne r0, r4, #8 <== NOT EXECUTED 22424: 18bd8010 popne {r4, pc} <== NOT EXECUTED 22428: e3a00000 mov r0, #0 <== NOT EXECUTED return NULL; return &grent; } 2242c: e8bd8010 pop {r4, pc} <== NOT EXECUTED 22430: 0005f784 .word 0x0005f784 000227a4 : struct group *getgrgid( gid_t gid ) { 227a4: e92d4003 push {r0, r1, lr} <== NOT EXECUTED struct group *p; if(getgrgid_r(gid, &grent, grbuf, sizeof grbuf, &p)) 227a8: e59f1028 ldr r1, [pc, #40] ; 227d8 <== NOT EXECUTED } struct group *getgrgid( gid_t gid ) { 227ac: e1a00800 lsl r0, r0, #16 <== NOT EXECUTED struct group *p; if(getgrgid_r(gid, &grent, grbuf, sizeof grbuf, &p)) 227b0: e28dc004 add ip, sp, #4 <== NOT EXECUTED 227b4: e2812010 add r2, r1, #16 <== NOT EXECUTED 227b8: e3a030c8 mov r3, #200 ; 0xc8 <== NOT EXECUTED 227bc: e1a00820 lsr r0, r0, #16 <== NOT EXECUTED 227c0: e58dc000 str ip, [sp] <== NOT EXECUTED 227c4: ebffffe9 bl 22770 <== NOT EXECUTED 227c8: e3500000 cmp r0, #0 <== NOT EXECUTED 227cc: 13a00000 movne r0, #0 <== NOT EXECUTED return NULL; return p; 227d0: 059d0004 ldreq r0, [sp, #4] <== NOT EXECUTED } 227d4: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED 227d8: 0005f78c .word 0x0005f78c 00022770 : struct group *grp, char *buffer, size_t bufsize, struct group **result ) { 22770: e92d4003 push {r0, r1, lr} <== NOT EXECUTED 22774: e1a0c002 mov ip, r2 <== NOT EXECUTED 22778: e1a0e001 mov lr, r1 <== NOT EXECUTED return getgr_r(NULL, gid, grp, buffer, bufsize, result); 2277c: e58d3000 str r3, [sp] <== NOT EXECUTED struct group *grp, char *buffer, size_t bufsize, struct group **result ) { 22780: e1a01800 lsl r1, r0, #16 <== NOT EXECUTED return getgr_r(NULL, gid, grp, buffer, bufsize, result); 22784: e1a0300c mov r3, ip <== NOT EXECUTED 22788: e59dc00c ldr ip, [sp, #12] <== NOT EXECUTED 2278c: e1a01821 lsr r1, r1, #16 <== NOT EXECUTED 22790: e1a0200e mov r2, lr <== NOT EXECUTED 22794: e3a00000 mov r0, #0 <== NOT EXECUTED 22798: e58dc004 str ip, [sp, #4] <== NOT EXECUTED 2279c: ebffffbf bl 226a0 <== NOT EXECUTED } 227a0: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED 00020908 : */ pid_t getpid( void ) { return _Objects_Local_node; } 20908: e3a00001 mov r0, #1 <== NOT EXECUTED 2090c: e12fff1e bx lr <== NOT EXECUTED 00022870 : struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) { 22870: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} 22874: e59da01c ldr sl, [sp, #28] 22878: e1a06000 mov r6, r0 2287c: e1a07001 mov r7, r1 22880: e1a04002 mov r4, r2 22884: e1a08003 mov r8, r3 FILE *fp; int match; init_etc_passwd_group(); 22888: ebffff43 bl 2259c if ((fp = fopen("/etc/passwd", "r")) == NULL) { 2288c: e59f00a4 ldr r0, [pc, #164] ; 22938 22890: e59f10a4 ldr r1, [pc, #164] ; 2293c 22894: eb0058b7 bl 38b78 22898: e2505000 subs r5, r0, #0 2289c: 1a000003 bne 228b0 errno = EINVAL; 228a0: eb005644 bl 381b8 <__errno> <== NOT EXECUTED 228a4: e3a03016 mov r3, #22 <== NOT EXECUTED 228a8: e5803000 str r3, [r0] <== NOT EXECUTED 228ac: ea00000c b 228e4 <== NOT EXECUTED return -1; } for(;;) { if (!scanpw(fp, pwd, buffer, bufsize)) { 228b0: e1a01004 mov r1, r4 228b4: e1a02008 mov r2, r8 228b8: e1a0300a mov r3, sl 228bc: e1a00005 mov r0, r5 228c0: ebfffedb bl 22434 228c4: e3500000 cmp r0, #0 errno = EINVAL; fclose(fp); return -1; } if (name) { match = (strcmp(pwd->pw_name, name) == 0); 228c8: e1a01006 mov r1, r6 if ((fp = fopen("/etc/passwd", "r")) == NULL) { errno = EINVAL; return -1; } for(;;) { if (!scanpw(fp, pwd, buffer, bufsize)) { 228cc: 1a000006 bne 228ec errno = EINVAL; 228d0: eb005638 bl 381b8 <__errno> <== NOT EXECUTED 228d4: e3a03016 mov r3, #22 <== NOT EXECUTED 228d8: e5803000 str r3, [r0] <== NOT EXECUTED fclose(fp); 228dc: e1a00005 mov r0, r5 <== NOT EXECUTED 228e0: eb005681 bl 382ec <== NOT EXECUTED 228e4: e3e00000 mvn r0, #0 <== NOT EXECUTED return -1; 228e8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED } if (name) { 228ec: e3560000 cmp r6, #0 228f0: 0a000004 beq 22908 match = (strcmp(pwd->pw_name, name) == 0); 228f4: e5940000 ldr r0, [r4] 228f8: eb006e40 bl 3e200 228fc: e2700001 rsbs r0, r0, #1 22900: 33a00000 movcc r0, #0 22904: ea000003 b 22918 } else { match = (pwd->pw_uid == uid); 22908: e1d400b8 ldrh r0, [r4, #8] <== NOT EXECUTED 2290c: e1500007 cmp r0, r7 <== NOT EXECUTED 22910: 13a00000 movne r0, #0 <== NOT EXECUTED 22914: 03a00001 moveq r0, #1 <== NOT EXECUTED } if (match) { 22918: e3500000 cmp r0, #0 2291c: 0affffe3 beq 228b0 fclose(fp); 22920: e1a00005 mov r0, r5 22924: eb005670 bl 382ec *result = pwd; 22928: e59d3020 ldr r3, [sp, #32] 2292c: e3a00000 mov r0, #0 22930: e5834000 str r4, [r3] } } fclose(fp); errno = EINVAL; return -1; } 22934: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 22938: 00056472 .word 0x00056472 2293c: 00057113 .word 0x00057113 00022560 : return NULL; return p; } struct passwd *getpwent(void) { 22560: e92d4010 push {r4, lr} <== NOT EXECUTED if (passwd_fp == NULL) 22564: e59f402c ldr r4, [pc, #44] ; 22598 <== NOT EXECUTED 22568: e5940004 ldr r0, [r4, #4] <== NOT EXECUTED 2256c: e3500000 cmp r0, #0 <== NOT EXECUTED 22570: 0a000006 beq 22590 <== NOT EXECUTED return NULL; if (!scanpw(passwd_fp, &pwent, pwbuf, sizeof pwbuf)) 22574: e28410e0 add r1, r4, #224 ; 0xe0 <== NOT EXECUTED 22578: e28420fc add r2, r4, #252 ; 0xfc <== NOT EXECUTED 2257c: e3a030c8 mov r3, #200 ; 0xc8 <== NOT EXECUTED 22580: ebffffab bl 22434 <== NOT EXECUTED 22584: e3500000 cmp r0, #0 <== NOT EXECUTED 22588: 128400e0 addne r0, r4, #224 ; 0xe0 <== NOT EXECUTED 2258c: 18bd8010 popne {r4, pc} <== NOT EXECUTED 22590: e3a00000 mov r0, #0 <== NOT EXECUTED return NULL; return &pwent; } 22594: e8bd8010 pop {r4, pc} <== NOT EXECUTED 22598: 0005f784 .word 0x0005f784 00022974 : struct passwd *getpwuid( uid_t uid ) { 22974: e92d4003 push {r0, r1, lr} <== NOT EXECUTED struct passwd *p; if(getpwuid_r(uid, &pwent, pwbuf, sizeof pwbuf, &p)) 22978: e59f1028 ldr r1, [pc, #40] ; 229a8 <== NOT EXECUTED } struct passwd *getpwuid( uid_t uid ) { 2297c: e1a00800 lsl r0, r0, #16 <== NOT EXECUTED struct passwd *p; if(getpwuid_r(uid, &pwent, pwbuf, sizeof pwbuf, &p)) 22980: e28dc004 add ip, sp, #4 <== NOT EXECUTED 22984: e281201c add r2, r1, #28 <== NOT EXECUTED 22988: e3a030c8 mov r3, #200 ; 0xc8 <== NOT EXECUTED 2298c: e1a00820 lsr r0, r0, #16 <== NOT EXECUTED 22990: e58dc000 str ip, [sp] <== NOT EXECUTED 22994: ebffffe9 bl 22940 <== NOT EXECUTED 22998: e3500000 cmp r0, #0 <== NOT EXECUTED 2299c: 13a00000 movne r0, #0 <== NOT EXECUTED return NULL; return p; 229a0: 059d0004 ldreq r0, [sp, #4] <== NOT EXECUTED } 229a4: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED 229a8: 0005f864 .word 0x0005f864 00022940 : struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) { 22940: e92d4003 push {r0, r1, lr} <== NOT EXECUTED 22944: e1a0c002 mov ip, r2 <== NOT EXECUTED 22948: e1a0e001 mov lr, r1 <== NOT EXECUTED return getpw_r(NULL, uid, pwd, buffer, bufsize, result); 2294c: e58d3000 str r3, [sp] <== NOT EXECUTED struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) { 22950: e1a01800 lsl r1, r0, #16 <== NOT EXECUTED return getpw_r(NULL, uid, pwd, buffer, bufsize, result); 22954: e1a0300c mov r3, ip <== NOT EXECUTED 22958: e59dc00c ldr ip, [sp, #12] <== NOT EXECUTED 2295c: e1a01821 lsr r1, r1, #16 <== NOT EXECUTED 22960: e1a0200e mov r2, lr <== NOT EXECUTED 22964: e3a00000 mov r0, #0 <== NOT EXECUTED 22968: e58dc004 str ip, [sp, #4] <== NOT EXECUTED 2296c: ebffffbf bl 22870 <== NOT EXECUTED } 22970: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED 00009064 : */ int gettimeofday( struct timeval *tp, void * __tz __attribute__((unused)) ) { 9064: e92d4033 push {r0, r1, r4, r5, lr} /* struct timezone* tzp = (struct timezone*) __tz; */ if ( !tp ) { 9068: e2504000 subs r4, r0, #0 906c: 1a000004 bne 9084 errno = EFAULT; 9070: eb000ab6 bl bb50 <__errno> <== NOT EXECUTED 9074: e3a0300e mov r3, #14 <== NOT EXECUTED 9078: e5803000 str r3, [r0] <== NOT EXECUTED 907c: e3e00000 mvn r0, #0 <== NOT EXECUTED return -1; 9080: ea00000c b 90b8 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 9084: e10f5000 mrs r5, CPSR 9088: e3853080 orr r3, r5, #128 ; 0x80 908c: e129f003 msr CPSR_fc, r3 ISR_Level level; struct timespec now; suseconds_t useconds; _ISR_Disable(level); _TOD_Get( &now ); 9090: e1a0000d mov r0, sp 9094: eb000252 bl 99e4 <_TOD_Get> static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 9098: e129f005 msr CPSR_fc, r5 _ISR_Enable(level); useconds = (suseconds_t)now.tv_nsec; useconds /= (suseconds_t)TOD_NANOSECONDS_PER_MICROSECOND; time->tv_sec = now.tv_sec; 909c: e59d3000 ldr r3, [sp] _ISR_Disable(level); _TOD_Get( &now ); _ISR_Enable(level); useconds = (suseconds_t)now.tv_nsec; 90a0: e59d0004 ldr r0, [sp, #4] useconds /= (suseconds_t)TOD_NANOSECONDS_PER_MICROSECOND; time->tv_sec = now.tv_sec; time->tv_usec = useconds; 90a4: e3a01ffa mov r1, #1000 ; 0x3e8 _ISR_Enable(level); useconds = (suseconds_t)now.tv_nsec; useconds /= (suseconds_t)TOD_NANOSECONDS_PER_MICROSECOND; time->tv_sec = now.tv_sec; 90a8: e5843000 str r3, [r4] time->tv_usec = useconds; 90ac: eb00305e bl 1522c <__aeabi_idiv> 90b0: e5840004 str r0, [r4, #4] 90b4: e3a00000 mov r0, #0 * with Eric Norum, this is how GNU/Linux, Solaris, and MacOS X * do it. This puts us in good company. */ return 0; } 90b8: e8bd803c pop {r2, r3, r4, r5, pc} 00004940 : * 4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs, * P1003.1b-1993, p. 84 */ uid_t getuid( void ) { 4940: e59f3008 ldr r3, [pc, #8] ; 4950 <== NOT EXECUTED 4944: e5933000 ldr r3, [r3] <== NOT EXECUTED return _POSIX_types_Uid; } 4948: e1d303b2 ldrh r0, [r3, #50] ; 0x32 <== NOT EXECUTED 494c: e12fff1e bx lr <== NOT EXECUTED 4950: 00052578 .word 0x00052578 0000518c : int ioctl( int fd, ioctl_command_t command, ... ) { 518c: e92d000e push {r1, r2, r3} va_list ap; rtems_status_code rc; rtems_libio_t *iop; void *buffer; rtems_libio_check_fd( fd ); 5190: e59f3080 ldr r3, [pc, #128] ; 5218 5194: e5933000 ldr r3, [r3] 5198: e1500003 cmp r0, r3 int ioctl( int fd, ioctl_command_t command, ... ) { 519c: e92d4001 push {r0, lr} va_list ap; rtems_status_code rc; rtems_libio_t *iop; void *buffer; rtems_libio_check_fd( fd ); 51a0: 2a00000b bcs 51d4 iop = rtems_libio_iop( fd ); 51a4: e59f3070 ldr r3, [pc, #112] ; 521c 51a8: e5933000 ldr r3, [r3] 51ac: e0830300 add r0, r3, r0, lsl #6 rtems_libio_check_is_open(iop); 51b0: e5903014 ldr r3, [r0, #20] 51b4: e3130c01 tst r3, #256 ; 0x100 51b8: 0a000005 beq 51d4 /* * Now process the ioctl(). */ if ( !iop->handlers ) 51bc: e590303c ldr r3, [r0, #60] ; 0x3c iop = rtems_libio_iop( fd ); rtems_libio_check_is_open(iop); va_start(ap, command); buffer = va_arg(ap, void *); 51c0: e28d2010 add r2, sp, #16 /* * Now process the ioctl(). */ if ( !iop->handlers ) 51c4: e3530000 cmp r3, #0 iop = rtems_libio_iop( fd ); rtems_libio_check_is_open(iop); va_start(ap, command); buffer = va_arg(ap, void *); 51c8: e58d2000 str r2, [sp] 51cc: e59d200c ldr r2, [sp, #12] /* * Now process the ioctl(). */ if ( !iop->handlers ) 51d0: 1a000002 bne 51e0 rtems_set_errno_and_return_minus_one( EBADF ); 51d4: eb002f5a bl 10f44 <__errno> 51d8: e3a03009 mov r3, #9 51dc: ea000004 b 51f4 if ( !iop->handlers->ioctl_h ) 51e0: e5933010 ldr r3, [r3, #16] 51e4: e3530000 cmp r3, #0 51e8: 1a000004 bne 5200 rtems_set_errno_and_return_minus_one( ENOTSUP ); 51ec: eb002f54 bl 10f44 <__errno> <== NOT EXECUTED 51f0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 51f4: e5803000 str r3, [r0] 51f8: e3e00000 mvn r0, #0 51fc: ea000002 b 520c rc = (*iop->handlers->ioctl_h)( iop, command, buffer ); 5200: e59d1008 ldr r1, [sp, #8] 5204: e1a0e00f mov lr, pc 5208: e12fff13 bx r3 return rc; } 520c: e8bd4008 pop {r3, lr} 5210: e28dd00c add sp, sp, #12 5214: e12fff1e bx lr 5218: 0001ce40 .word 0x0001ce40 521c: 0001e980 .word 0x0001e980 000030b4 : * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) { if (tty->termios.c_iflag & ISTRIP) 30b4: e5913030 ldr r3, [r1, #48] ; 0x30 <== NOT EXECUTED 30b8: e3130020 tst r3, #32 <== NOT EXECUTED /* * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) { 30bc: e92d4030 push {r4, r5, lr} <== NOT EXECUTED 30c0: e20050ff and r5, r0, #255 ; 0xff <== NOT EXECUTED if (tty->termios.c_iflag & ISTRIP) c &= 0x7f; 30c4: 1200507f andne r5, r0, #127 ; 0x7f <== NOT EXECUTED if (tty->termios.c_iflag & IUCLC) 30c8: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED /* * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) { 30cc: e1a04001 mov r4, r1 <== NOT EXECUTED if (tty->termios.c_iflag & ISTRIP) c &= 0x7f; if (tty->termios.c_iflag & IUCLC) 30d0: 0a000007 beq 30f4 <== NOT EXECUTED c = tolower (c); 30d4: e59f2164 ldr r2, [pc, #356] ; 3240 <== NOT EXECUTED 30d8: e5922000 ldr r2, [r2] <== NOT EXECUTED 30dc: e0822005 add r2, r2, r5 <== NOT EXECUTED 30e0: e5d22001 ldrb r2, [r2, #1] <== NOT EXECUTED 30e4: e2022003 and r2, r2, #3 <== NOT EXECUTED 30e8: e3520001 cmp r2, #1 <== NOT EXECUTED 30ec: 02855020 addeq r5, r5, #32 <== NOT EXECUTED 30f0: e20550ff and r5, r5, #255 ; 0xff <== NOT EXECUTED if (c == '\r') { 30f4: e355000d cmp r5, #13 <== NOT EXECUTED 30f8: 1a000005 bne 3114 <== NOT EXECUTED if (tty->termios.c_iflag & IGNCR) 30fc: e3130080 tst r3, #128 ; 0x80 <== NOT EXECUTED 3100: 1a00004c bne 3238 <== NOT EXECUTED return 0; if (tty->termios.c_iflag & ICRNL) 3104: e3130c01 tst r3, #256 ; 0x100 <== NOT EXECUTED 3108: 03a0500d moveq r5, #13 <== NOT EXECUTED 310c: 13a0500a movne r5, #10 <== NOT EXECUTED 3110: ea000007 b 3134 <== NOT EXECUTED c = '\n'; } else if ((c == '\n') && (tty->termios.c_iflag & INLCR)) { 3114: e355000a cmp r5, #10 <== NOT EXECUTED 3118: 1a000003 bne 312c <== NOT EXECUTED 311c: e3130040 tst r3, #64 ; 0x40 <== NOT EXECUTED 3120: 03a0500a moveq r5, #10 <== NOT EXECUTED 3124: 13a0500d movne r5, #13 <== NOT EXECUTED 3128: ea000001 b 3134 <== NOT EXECUTED c = '\r'; } if ((c != '\0') && (tty->termios.c_lflag & ICANON)) { 312c: e3550000 cmp r5, #0 <== NOT EXECUTED 3130: 0a00002e beq 31f0 <== NOT EXECUTED 3134: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 3138: e3130002 tst r3, #2 <== NOT EXECUTED 313c: 0a00002b beq 31f0 <== NOT EXECUTED if (c == tty->termios.c_cc[VERASE]) { 3140: e5d42043 ldrb r2, [r4, #67] ; 0x43 <== NOT EXECUTED 3144: e1520005 cmp r2, r5 <== NOT EXECUTED erase (tty, 0); 3148: 01a00004 moveq r0, r4 <== NOT EXECUTED 314c: 03a01000 moveq r1, #0 <== NOT EXECUTED } else if ((c == '\n') && (tty->termios.c_iflag & INLCR)) { c = '\r'; } if ((c != '\0') && (tty->termios.c_lflag & ICANON)) { if (c == tty->termios.c_cc[VERASE]) { 3150: 0a000004 beq 3168 <== NOT EXECUTED erase (tty, 0); return 0; } else if (c == tty->termios.c_cc[VKILL]) { 3154: e5d42044 ldrb r2, [r4, #68] ; 0x44 <== NOT EXECUTED 3158: e1520005 cmp r2, r5 <== NOT EXECUTED 315c: 1a000003 bne 3170 <== NOT EXECUTED erase (tty, 1); 3160: e1a00004 mov r0, r4 <== NOT EXECUTED 3164: e3a01001 mov r1, #1 <== NOT EXECUTED 3168: ebffff5e bl 2ee8 <== NOT EXECUTED 316c: ea00002f b 3230 <== NOT EXECUTED return 0; } else if (c == tty->termios.c_cc[VEOF]) { 3170: e5d42045 ldrb r2, [r4, #69] ; 0x45 <== NOT EXECUTED 3174: e1520005 cmp r2, r5 <== NOT EXECUTED 3178: 0a00001a beq 31e8 <== NOT EXECUTED return 1; } else if (c == '\n') { 317c: e355000a cmp r5, #10 <== NOT EXECUTED 3180: 1a000009 bne 31ac <== NOT EXECUTED if (tty->termios.c_lflag & (ECHO | ECHONL)) 3184: e3130048 tst r3, #72 ; 0x48 <== NOT EXECUTED echo (c, tty); 3188: 11a00005 movne r0, r5 <== NOT EXECUTED 318c: 11a01004 movne r1, r4 <== NOT EXECUTED 3190: 1bffff34 blne 2e68 <== NOT EXECUTED tty->cbuf[tty->ccount++] = c; 3194: e284101c add r1, r4, #28 <== NOT EXECUTED 3198: e891000a ldm r1, {r1, r3} <== NOT EXECUTED 319c: e3a0000a mov r0, #10 <== NOT EXECUTED 31a0: e2832001 add r2, r3, #1 <== NOT EXECUTED 31a4: e7c10003 strb r0, [r1, r3] <== NOT EXECUTED 31a8: ea00000d b 31e4 <== NOT EXECUTED return 1; } else if ((c == tty->termios.c_cc[VEOL]) 31ac: e5d4204c ldrb r2, [r4, #76] ; 0x4c <== NOT EXECUTED 31b0: e1520005 cmp r2, r5 <== NOT EXECUTED 31b4: 0a000002 beq 31c4 <== NOT EXECUTED || (c == tty->termios.c_cc[VEOL2])) { 31b8: e5d42051 ldrb r2, [r4, #81] ; 0x51 <== NOT EXECUTED 31bc: e1520005 cmp r2, r5 <== NOT EXECUTED 31c0: 1a00000a bne 31f0 <== NOT EXECUTED if (tty->termios.c_lflag & ECHO) 31c4: e3130008 tst r3, #8 <== NOT EXECUTED echo (c, tty); 31c8: 11a00005 movne r0, r5 <== NOT EXECUTED 31cc: 11a01004 movne r1, r4 <== NOT EXECUTED 31d0: 1bffff24 blne 2e68 <== NOT EXECUTED tty->cbuf[tty->ccount++] = c; 31d4: e284101c add r1, r4, #28 <== NOT EXECUTED 31d8: e891000a ldm r1, {r1, r3} <== NOT EXECUTED 31dc: e7c15003 strb r5, [r1, r3] <== NOT EXECUTED 31e0: e2832001 add r2, r3, #1 <== NOT EXECUTED 31e4: e5842020 str r2, [r4, #32] <== NOT EXECUTED 31e8: e3a00001 mov r0, #1 <== NOT EXECUTED return 1; 31ec: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED } /* * FIXME: Should do IMAXBEL handling somehow */ if (tty->ccount < (CBUFSIZE-1)) { 31f0: e59f304c ldr r3, [pc, #76] ; 3244 <== NOT EXECUTED 31f4: e5933000 ldr r3, [r3] <== NOT EXECUTED 31f8: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED 31fc: e2433001 sub r3, r3, #1 <== NOT EXECUTED 3200: e1520003 cmp r2, r3 <== NOT EXECUTED 3204: aa00000b bge 3238 <== NOT EXECUTED if (tty->termios.c_lflag & ECHO) 3208: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 320c: e3130008 tst r3, #8 <== NOT EXECUTED echo (c, tty); 3210: 11a00005 movne r0, r5 <== NOT EXECUTED 3214: 11a01004 movne r1, r4 <== NOT EXECUTED 3218: 1bffff12 blne 2e68 <== NOT EXECUTED tty->cbuf[tty->ccount++] = c; 321c: e284101c add r1, r4, #28 <== NOT EXECUTED 3220: e891000a ldm r1, {r1, r3} <== NOT EXECUTED 3224: e2832001 add r2, r3, #1 <== NOT EXECUTED 3228: e7c15003 strb r5, [r1, r3] <== NOT EXECUTED 322c: e5842020 str r2, [r4, #32] <== NOT EXECUTED 3230: e3a00000 mov r0, #0 <== NOT EXECUTED 3234: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED 3238: e3a00000 mov r0, #0 <== NOT EXECUTED } return 0; } 323c: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED 3240: 0001777c .word 0x0001777c 3244: 00017704 .word 0x00017704 00020920 : #if !defined(RTEMS_POSIX_API) int kill( pid_t pid, int sig ) { return 0; } 20920: e3a00000 mov r0, #0 <== NOT EXECUTED 20924: e12fff1e bx lr <== NOT EXECUTED 00022a98 : int link( const char *existing, const char *new ) { 22a98: e92d4030 push {r4, r5, lr} 22a9c: e24dd030 sub sp, sp, #48 ; 0x30 22aa0: e1a04001 mov r4, r1 22aa4: e1a05000 mov r5, r0 /* * Get the node we are linking to. */ result = rtems_filesystem_evaluate_path( existing, strlen( existing ), 22aa8: eb00703c bl 3eba0 22aac: e3a0c001 mov ip, #1 22ab0: e1a01000 mov r1, r0 22ab4: e3a02000 mov r2, #0 22ab8: e1a00005 mov r0, r5 22abc: e28d3018 add r3, sp, #24 22ac0: e58dc000 str ip, [sp] 22ac4: ebff8727 bl 4768 0, &existing_loc, true ); if ( result != 0 ) 22ac8: e3500000 cmp r0, #0 22acc: 1a00002a bne 22b7c /* * Get the parent of the node we are creating. */ rtems_filesystem_get_start_loc( new, &i, &parent_loc ); 22ad0: e5d43000 ldrb r3, [r4] 22ad4: e353002f cmp r3, #47 ; 0x2f 22ad8: 1353005c cmpne r3, #92 ; 0x5c 22adc: 13a05000 movne r5, #0 22ae0: 03a05001 moveq r5, #1 22ae4: 0a000001 beq 22af0 22ae8: e3530000 cmp r3, #0 22aec: 1a000009 bne 22b18 22af0: e59f31ec ldr r3, [pc, #492] ; 22ce4 22af4: e593e000 ldr lr, [r3] 22af8: e28ee018 add lr, lr, #24 22afc: e8be000f ldm lr!, {r0, r1, r2, r3} 22b00: e28dc004 add ip, sp, #4 22b04: e8ac000f stmia ip!, {r0, r1, r2, r3} 22b08: e59e3000 ldr r3, [lr] 22b0c: e3a00001 mov r0, #1 22b10: e58c3000 str r3, [ip] 22b14: ea000008 b 22b3c 22b18: e59f31c4 ldr r3, [pc, #452] ; 22ce4 22b1c: e593e000 ldr lr, [r3] 22b20: e28ee004 add lr, lr, #4 22b24: e8be000f ldm lr!, {r0, r1, r2, r3} 22b28: e28dc004 add ip, sp, #4 22b2c: e8ac000f stmia ip!, {r0, r1, r2, r3} 22b30: e59e3000 ldr r3, [lr] 22b34: e58c3000 str r3, [ip] 22b38: e1a00005 mov r0, r5 if ( !parent_loc.ops->evalformake_h ) { 22b3c: e59d3010 ldr r3, [sp, #16] 22b40: e5933004 ldr r3, [r3, #4] 22b44: e3530000 cmp r3, #0 22b48: 1a00000d bne 22b84 rtems_filesystem_freenode( &existing_loc ); 22b4c: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 22b50: e3530000 cmp r3, #0 <== NOT EXECUTED 22b54: 0a000005 beq 22b70 <== NOT EXECUTED 22b58: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 22b5c: e3530000 cmp r3, #0 <== NOT EXECUTED 22b60: 0a000002 beq 22b70 <== NOT EXECUTED 22b64: e28d0018 add r0, sp, #24 <== NOT EXECUTED 22b68: e1a0e00f mov lr, pc <== NOT EXECUTED 22b6c: e12fff13 bx r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 22b70: eb005590 bl 381b8 <__errno> <== NOT EXECUTED 22b74: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 22b78: e5803000 str r3, [r0] 22b7c: e3e05000 mvn r5, #0 22b80: ea000054 b 22cd8 } result = (*parent_loc.ops->evalformake_h)( &new[i], &parent_loc, &name_start ); 22b84: e28d5004 add r5, sp, #4 22b88: e0840000 add r0, r4, r0 22b8c: e1a01005 mov r1, r5 22b90: e28d202c add r2, sp, #44 ; 0x2c 22b94: e1a0e00f mov lr, pc 22b98: e12fff13 bx r3 if ( result != 0 ) { 22b9c: e2504000 subs r4, r0, #0 22ba0: 0a00000a beq 22bd0 rtems_filesystem_freenode( &existing_loc ); 22ba4: e59d3024 ldr r3, [sp, #36] ; 0x24 22ba8: e3530000 cmp r3, #0 22bac: 0a000004 beq 22bc4 22bb0: e593301c ldr r3, [r3, #28] 22bb4: e3530000 cmp r3, #0 22bb8: 128d0018 addne r0, sp, #24 22bbc: 11a0e00f movne lr, pc 22bc0: 112fff13 bxne r3 rtems_set_errno_and_return_minus_one( result ); 22bc4: eb00557b bl 381b8 <__errno> 22bc8: e5804000 str r4, [r0] 22bcc: eaffffea b 22b7c /* * Check to see if the caller is trying to link across file system * boundaries. */ if ( parent_loc.mt_entry != existing_loc.mt_entry ) { 22bd0: e59d3028 ldr r3, [sp, #40] ; 0x28 22bd4: e59d2014 ldr r2, [sp, #20] 22bd8: e1520003 cmp r2, r3 22bdc: 0a000012 beq 22c2c rtems_filesystem_freenode( &existing_loc ); 22be0: e59d3024 ldr r3, [sp, #36] ; 0x24 22be4: e3530000 cmp r3, #0 22be8: 0a000004 beq 22c00 22bec: e593301c ldr r3, [r3, #28] 22bf0: e3530000 cmp r3, #0 22bf4: 128d0018 addne r0, sp, #24 22bf8: 11a0e00f movne lr, pc 22bfc: 112fff13 bxne r3 rtems_filesystem_freenode( &parent_loc ); 22c00: e59d3010 ldr r3, [sp, #16] 22c04: e3530000 cmp r3, #0 22c08: 0a000004 beq 22c20 22c0c: e593301c ldr r3, [r3, #28] 22c10: e3530000 cmp r3, #0 22c14: 128d0004 addne r0, sp, #4 22c18: 11a0e00f movne lr, pc 22c1c: 112fff13 bxne r3 rtems_set_errno_and_return_minus_one( EXDEV ); 22c20: eb005564 bl 381b8 <__errno> 22c24: e3a03012 mov r3, #18 22c28: eaffffd2 b 22b78 } if ( !parent_loc.ops->link_h ) { 22c2c: e59d3010 ldr r3, [sp, #16] 22c30: e5933008 ldr r3, [r3, #8] 22c34: e3530000 cmp r3, #0 22c38: 1a00000f bne 22c7c rtems_filesystem_freenode( &existing_loc ); 22c3c: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 22c40: e3530000 cmp r3, #0 <== NOT EXECUTED 22c44: 0a000004 beq 22c5c <== NOT EXECUTED 22c48: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 22c4c: e3530000 cmp r3, #0 <== NOT EXECUTED 22c50: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 22c54: 11a0e00f movne lr, pc <== NOT EXECUTED 22c58: 112fff13 bxne r3 <== NOT EXECUTED rtems_filesystem_freenode( &parent_loc ); 22c5c: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 22c60: e3530000 cmp r3, #0 <== NOT EXECUTED 22c64: 0affffc1 beq 22b70 <== NOT EXECUTED 22c68: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 22c6c: e3530000 cmp r3, #0 <== NOT EXECUTED 22c70: 128d0004 addne r0, sp, #4 <== NOT EXECUTED 22c74: 1affffbb bne 22b68 <== NOT EXECUTED 22c78: eaffffbc b 22b70 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*parent_loc.ops->link_h)( &existing_loc, &parent_loc, name_start ); 22c7c: e28d4018 add r4, sp, #24 22c80: e1a01005 mov r1, r5 22c84: e1a00004 mov r0, r4 22c88: e59d202c ldr r2, [sp, #44] ; 0x2c 22c8c: e1a0e00f mov lr, pc 22c90: e12fff13 bx r3 rtems_filesystem_freenode( &existing_loc ); 22c94: e59d3024 ldr r3, [sp, #36] ; 0x24 22c98: e3530000 cmp r3, #0 rtems_filesystem_freenode( &existing_loc ); rtems_filesystem_freenode( &parent_loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*parent_loc.ops->link_h)( &existing_loc, &parent_loc, name_start ); 22c9c: e1a05000 mov r5, r0 rtems_filesystem_freenode( &existing_loc ); 22ca0: 0a000004 beq 22cb8 22ca4: e593301c ldr r3, [r3, #28] 22ca8: e3530000 cmp r3, #0 22cac: 11a00004 movne r0, r4 22cb0: 11a0e00f movne lr, pc 22cb4: 112fff13 bxne r3 rtems_filesystem_freenode( &parent_loc ); 22cb8: e59d3010 ldr r3, [sp, #16] 22cbc: e3530000 cmp r3, #0 22cc0: 0a000004 beq 22cd8 22cc4: e593301c ldr r3, [r3, #28] 22cc8: e3530000 cmp r3, #0 22ccc: 128d0004 addne r0, sp, #4 22cd0: 11a0e00f movne lr, pc 22cd4: 112fff13 bxne r3 return result; } 22cd8: e1a00005 mov r0, r5 22cdc: e28dd030 add sp, sp, #48 ; 0x30 22ce0: e8bd8030 pop {r4, r5, pc} 22ce4: 00052578 .word 0x00052578 00016b18 : { rtems_libio_t *iop; off_t old_offset; off_t status; rtems_libio_check_fd( fd ); 16b18: e59fc0ec ldr ip, [pc, #236] ; 16c0c 16b1c: e59cc000 ldr ip, [ip] 16b20: e150000c cmp r0, ip off_t lseek( int fd, off_t offset, int whence ) { 16b24: e92d4870 push {r4, r5, r6, fp, lr} rtems_libio_t *iop; off_t old_offset; off_t status; rtems_libio_check_fd( fd ); 16b28: 2a000005 bcs 16b44 iop = rtems_libio_iop( fd ); 16b2c: e59fc0dc ldr ip, [pc, #220] ; 16c10 16b30: e59c4000 ldr r4, [ip] 16b34: e0844300 add r4, r4, r0, lsl #6 rtems_libio_check_is_open(iop); 16b38: e5940014 ldr r0, [r4, #20] 16b3c: e3100c01 tst r0, #256 ; 0x100 16b40: 1a000002 bne 16b50 16b44: ebffd401 bl bb50 <__errno> <== NOT EXECUTED 16b48: e3a03009 mov r3, #9 <== NOT EXECUTED 16b4c: ea00001c b 16bc4 <== NOT EXECUTED /* * Check as many errors as possible before touching iop->offset. */ if ( !iop->handlers->lseek_h ) 16b50: e594003c ldr r0, [r4, #60] ; 0x3c 16b54: e5900014 ldr r0, [r0, #20] 16b58: e3500000 cmp r0, #0 16b5c: 1a000002 bne 16b6c rtems_set_errno_and_return_minus_one( ENOTSUP ); 16b60: ebffd3fa bl bb50 <__errno> <== NOT EXECUTED 16b64: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 16b68: ea000015 b 16bc4 <== NOT EXECUTED /* * Now process the lseek(). */ old_offset = iop->offset; switch ( whence ) { 16b6c: e3530001 cmp r3, #1 /* * Now process the lseek(). */ old_offset = iop->offset; 16b70: e284600c add r6, r4, #12 16b74: e8960060 ldm r6, {r5, r6} switch ( whence ) { 16b78: 0a000006 beq 16b98 16b7c: e3530002 cmp r3, #2 16b80: 0a000007 beq 16ba4 16b84: e3530000 cmp r3, #0 16b88: 1a00000b bne 16bbc case SEEK_SET: iop->offset = offset; 16b8c: e584100c str r1, [r4, #12] 16b90: e5842010 str r2, [r4, #16] break; 16b94: ea00000e b 16bd4 case SEEK_CUR: iop->offset += offset; 16b98: e091b005 adds fp, r1, r5 16b9c: e0a2c006 adc ip, r2, r6 16ba0: ea000002 b 16bb0 break; case SEEK_END: iop->offset = iop->size + offset; 16ba4: e9941800 ldmib r4, {fp, ip} 16ba8: e09bb001 adds fp, fp, r1 16bac: e0acc002 adc ip, ip, r2 16bb0: e584b00c str fp, [r4, #12] 16bb4: e584c010 str ip, [r4, #16] break; 16bb8: ea000005 b 16bd4 default: rtems_set_errno_and_return_minus_one( EINVAL ); 16bbc: ebffd3e3 bl bb50 <__errno> 16bc0: e3a03016 mov r3, #22 16bc4: e5803000 str r3, [r0] 16bc8: e3e02000 mvn r2, #0 16bcc: e3e03000 mvn r3, #0 16bd0: ea00000a b 16c00 /* * At this time, handlers assume iop->offset has the desired * new offset. */ status = (*iop->handlers->lseek_h)( iop, offset, whence ); 16bd4: e594c03c ldr ip, [r4, #60] ; 0x3c 16bd8: e1a00004 mov r0, r4 16bdc: e1a0e00f mov lr, pc 16be0: e59cf014 ldr pc, [ip, #20] if ( status == (off_t) -1 ) 16be4: e3700001 cmn r0, #1 /* * At this time, handlers assume iop->offset has the desired * new offset. */ status = (*iop->handlers->lseek_h)( iop, offset, whence ); 16be8: e1a02000 mov r2, r0 16bec: e1a03001 mov r3, r1 if ( status == (off_t) -1 ) 16bf0: 1a000002 bne 16c00 16bf4: e3710001 cmn r1, #1 iop->offset = old_offset; 16bf8: 0584500c streq r5, [r4, #12] 16bfc: 05846010 streq r6, [r4, #16] /* * So if the operation failed, we have to restore iop->offset. */ return status; } 16c00: e1a01003 mov r1, r3 16c04: e1a00002 mov r0, r2 16c08: e8bd8870 pop {r4, r5, r6, fp, pc} 16c0c: 00017580 .word 0x00017580 16c10: 00018cb0 .word 0x00018cb0 00022e04 : int _STAT_NAME( const char *path, struct stat *buf ) { 22e04: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED /* * Check to see if we were passed a valid pointer. */ if ( !buf ) 22e08: e2515000 subs r5, r1, #0 <== NOT EXECUTED int _STAT_NAME( const char *path, struct stat *buf ) { 22e0c: e24dd018 sub sp, sp, #24 <== NOT EXECUTED 22e10: e1a06000 mov r6, r0 <== NOT EXECUTED /* * Check to see if we were passed a valid pointer. */ if ( !buf ) 22e14: 1a000002 bne 22e24 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EFAULT ); 22e18: eb0054e6 bl 381b8 <__errno> <== NOT EXECUTED 22e1c: e3a0300e mov r3, #14 <== NOT EXECUTED 22e20: ea000018 b 22e88 <== NOT EXECUTED status = rtems_filesystem_evaluate_path( path, strlen( path ), 22e24: eb006f5d bl 3eba0 <== NOT EXECUTED 22e28: e28d4004 add r4, sp, #4 <== NOT EXECUTED 22e2c: e3a0c000 mov ip, #0 <== NOT EXECUTED 22e30: e1a01000 mov r1, r0 <== NOT EXECUTED 22e34: e1a0200c mov r2, ip <== NOT EXECUTED 22e38: e1a00006 mov r0, r6 <== NOT EXECUTED 22e3c: e1a03004 mov r3, r4 <== NOT EXECUTED 22e40: e58dc000 str ip, [sp] <== NOT EXECUTED 22e44: ebff8647 bl 4768 <== NOT EXECUTED 0, &loc, _STAT_FOLLOW_LINKS ); if ( status != 0 ) 22e48: e2501000 subs r1, r0, #0 <== NOT EXECUTED 22e4c: 1a00000e bne 22e8c <== NOT EXECUTED return -1; if ( !loc.handlers->fstat_h ){ 22e50: e59d300c ldr r3, [sp, #12] <== NOT EXECUTED 22e54: e5933018 ldr r3, [r3, #24] <== NOT EXECUTED 22e58: e3530000 cmp r3, #0 <== NOT EXECUTED 22e5c: 1a00000c bne 22e94 <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 22e60: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 22e64: e3530000 cmp r3, #0 <== NOT EXECUTED 22e68: 0a000004 beq 22e80 <== NOT EXECUTED 22e6c: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 22e70: e3530000 cmp r3, #0 <== NOT EXECUTED 22e74: 11a00004 movne r0, r4 <== NOT EXECUTED 22e78: 11a0e00f movne lr, pc <== NOT EXECUTED 22e7c: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 22e80: eb0054cc bl 381b8 <__errno> <== NOT EXECUTED 22e84: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 22e88: e5803000 str r3, [r0] <== NOT EXECUTED 22e8c: e3e05000 mvn r5, #0 <== NOT EXECUTED 22e90: ea000010 b 22ed8 <== NOT EXECUTED /* * Zero out the stat structure so the various support * versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) ); 22e94: e3a02048 mov r2, #72 ; 0x48 <== NOT EXECUTED 22e98: e1a00005 mov r0, r5 <== NOT EXECUTED 22e9c: eb00617d bl 3b498 <== NOT EXECUTED status = (*loc.handlers->fstat_h)( &loc, buf ); 22ea0: e1a01005 mov r1, r5 <== NOT EXECUTED 22ea4: e59d300c ldr r3, [sp, #12] <== NOT EXECUTED 22ea8: e1a00004 mov r0, r4 <== NOT EXECUTED 22eac: e1a0e00f mov lr, pc <== NOT EXECUTED 22eb0: e593f018 ldr pc, [r3, #24] <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 22eb4: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 22eb8: e3530000 cmp r3, #0 <== NOT EXECUTED * versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) ); status = (*loc.handlers->fstat_h)( &loc, buf ); 22ebc: e1a05000 mov r5, r0 <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 22ec0: 0a000004 beq 22ed8 <== NOT EXECUTED 22ec4: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 22ec8: e3530000 cmp r3, #0 <== NOT EXECUTED 22ecc: 11a00004 movne r0, r4 <== NOT EXECUTED 22ed0: 11a0e00f movne lr, pc <== NOT EXECUTED 22ed4: 112fff13 bxne r3 <== NOT EXECUTED return status; } 22ed8: e1a00005 mov r0, r5 <== NOT EXECUTED 22edc: e28dd018 add sp, sp, #24 <== NOT EXECUTED 22ee0: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED 00001c10 : size_t size ) { void *return_this; MSBUMP(malloc_calls, 1); 1c10: e59f30d8 ldr r3, [pc, #216] ; 1cf0 1c14: e5932004 ldr r2, [r3, #4] 1c18: e2822001 add r2, r2, #1 1c1c: e92d4070 push {r4, r5, r6, lr} 1c20: e5832004 str r2, [r3, #4] 1c24: e1a04000 mov r4, r0 /* * If some free's have been deferred, then do them now. */ malloc_deferred_frees_process(); 1c28: ebffffb5 bl 1b04 /* * Validate the parameters */ if ( !size ) 1c2c: e3540000 cmp r4, #0 1c30: 0a00002b beq 1ce4 return (void *) 0; /* * Do not attempt to allocate memory if not in correct system state. */ if ( _System_state_Is_up(_System_state_Get()) && 1c34: e59f30b8 ldr r3, [pc, #184] ; 1cf4 1c38: e5933000 ldr r3, [r3] 1c3c: e3530003 cmp r3, #3 1c40: 1a000002 bne 1c50 1c44: ebffff97 bl 1aa8 1c48: e3500000 cmp r0, #0 1c4c: 0a000024 beq 1ce4 RTEMS_INLINE_ROUTINE void *_Protected_heap_Allocate( Heap_Control *heap, uintptr_t size ) { return _Protected_heap_Allocate_aligned_with_boundary( heap, size, 0, 0 ); 1c50: e59f30a0 ldr r3, [pc, #160] ; 1cf8 1c54: e3a02000 mov r2, #0 1c58: e5930000 ldr r0, [r3] 1c5c: e1a01004 mov r1, r4 1c60: e1a03002 mov r3, r2 1c64: eb00119a bl 62d4 <_Protected_heap_Allocate_aligned_with_boundary> * If this fails then return a NULL pointer. */ return_this = _Protected_heap_Allocate( RTEMS_Malloc_Heap, size ); if ( !return_this ) { 1c68: e2506000 subs r6, r0, #0 if (rtems_malloc_sbrk_helpers) return_this = (*rtems_malloc_sbrk_helpers->extend)( size ); if ( !return_this ) { errno = ENOMEM; return (void *) 0; 1c6c: 11a05006 movne r5, r6 * If this fails then return a NULL pointer. */ return_this = _Protected_heap_Allocate( RTEMS_Malloc_Heap, size ); if ( !return_this ) { 1c70: 1a00000c bne 1ca8 if (rtems_malloc_sbrk_helpers) 1c74: e59f3080 ldr r3, [pc, #128] ; 1cfc 1c78: e5933000 ldr r3, [r3] 1c7c: e3530000 cmp r3, #0 1c80: 0a000004 beq 1c98 return_this = (*rtems_malloc_sbrk_helpers->extend)( size ); 1c84: e1a00004 mov r0, r4 <== NOT EXECUTED 1c88: e1a0e00f mov lr, pc <== NOT EXECUTED 1c8c: e593f004 ldr pc, [r3, #4] <== NOT EXECUTED if ( !return_this ) { 1c90: e2505000 subs r5, r0, #0 <== NOT EXECUTED 1c94: 1a000003 bne 1ca8 <== NOT EXECUTED errno = ENOMEM; 1c98: eb0027ac bl bb50 <__errno> 1c9c: e3a0300c mov r3, #12 1ca0: e5803000 str r3, [r0] return (void *) 0; 1ca4: ea00000f b 1ce8 } /* * If the user wants us to dirty the allocated memory, then do it. */ if ( rtems_malloc_dirty_helper ) 1ca8: e59f3050 ldr r3, [pc, #80] ; 1d00 1cac: e5933000 ldr r3, [r3] 1cb0: e3530000 cmp r3, #0 (*rtems_malloc_dirty_helper)( return_this, size ); 1cb4: 11a01004 movne r1, r4 1cb8: 11a00005 movne r0, r5 1cbc: 11a0e00f movne lr, pc 1cc0: 1593f000 ldrne pc, [r3] /* * If configured, update the statistics */ if ( rtems_malloc_statistics_helpers ) 1cc4: e59f3038 ldr r3, [pc, #56] ; 1d04 1cc8: e5933000 ldr r3, [r3] 1ccc: e3530000 cmp r3, #0 (*rtems_malloc_statistics_helpers->at_malloc)(return_this); 1cd0: 11a00005 movne r0, r5 1cd4: 11a0e00f movne lr, pc 1cd8: 1593f004 ldrne pc, [r3, #4] 1cdc: e1a06005 mov r6, r5 1ce0: ea000000 b 1ce8 1ce4: e3a06000 mov r6, #0 <== NOT EXECUTED if (rtems_malloc_boundary_helpers) (*rtems_malloc_boundary_helpers->at_malloc)(return_this, size); #endif return return_this; } 1ce8: e1a00006 mov r0, r6 1cec: e8bd8070 pop {r4, r5, r6, pc} 1cf0: 00018cc8 .word 0x00018cc8 1cf4: 00018fd0 .word 0x00018fd0 1cf8: 0001758c .word 0x0001758c 1cfc: 000189ac .word 0x000189ac 1d00: 000189b0 .word 0x000189b0 1d04: 000189a8 .word 0x000189a8 00001af4 : } void malloc_deferred_free( void *pointer ) { 1af4: e1a01000 mov r1, r0 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void rtems_chain_append( rtems_chain_control *the_chain, rtems_chain_node *the_node ) { _Chain_Append( the_chain, the_node ); 1af8: e59f0000 ldr r0, [pc, #0] ; 1b00 <== NOT EXECUTED 1afc: ea000e14 b 5354 <_Chain_Append> <== NOT EXECUTED 1b00: 00018cbc .word 0x00018cbc 00001b04 : { rtems_chain_initialize_empty(&RTEMS_Malloc_GC_list); } void malloc_deferred_frees_process(void) { 1b04: e52de004 push {lr} ; (str lr, [sp, #-4]!) rtems_chain_node *to_be_freed; /* * If some free's have been deferred, then do them now. */ while ((to_be_freed = rtems_chain_get(&RTEMS_Malloc_GC_list)) != NULL) 1b08: ea000000 b 1b10 free(to_be_freed); 1b0c: ebffff8d bl 1948 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get( rtems_chain_control *the_chain ) { return _Chain_Get( the_chain ); 1b10: e59f000c ldr r0, [pc, #12] ; 1b24 1b14: eb000e19 bl 5380 <_Chain_Get> rtems_chain_node *to_be_freed; /* * If some free's have been deferred, then do them now. */ while ((to_be_freed = rtems_chain_get(&RTEMS_Malloc_GC_list)) != NULL) 1b18: e3500000 cmp r0, #0 1b1c: 1afffffa bne 1b0c free(to_be_freed); } 1b20: e49df004 pop {pc} ; (ldr pc, [sp], #4) 1b24: 00018cbc .word 0x00018cbc 0000fa30 : int memfile_ftruncate( rtems_libio_t *iop, rtems_off64_t length ) { fa30: e92d4013 push {r0, r1, r4, lr} IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; fa34: e5904038 ldr r4, [r0, #56] ; 0x38 * POSIX 1003.1b does not specify what happens if you truncate a file * and the new length is greater than the current size. We treat this * as an extend operation. */ if ( length > the_jnode->info.file.size ) fa38: e5943054 ldr r3, [r4, #84] ; 0x54 fa3c: e1530002 cmp r3, r2 fa40: ba000003 blt fa54 fa44: 1a000005 bne fa60 fa48: e5943050 ldr r3, [r4, #80] ; 0x50 fa4c: e1530001 cmp r3, r1 fa50: 2a000002 bcs fa60 return IMFS_memfile_extend( the_jnode, length ); fa54: e1a00004 mov r0, r4 <== NOT EXECUTED fa58: ebffff9a bl f8c8 <== NOT EXECUTED fa5c: ea000008 b fa84 <== NOT EXECUTED * The in-memory files do not currently reclaim memory until the file is * deleted. So we leave the previously allocated blocks in place for * future use and just set the length. */ the_jnode->info.file.size = length; fa60: e5841050 str r1, [r4, #80] ; 0x50 fa64: e5842054 str r2, [r4, #84] ; 0x54 iop->size = the_jnode->info.file.size; fa68: e9800006 stmib r0, {r1, r2} IMFS_update_atime( the_jnode ); fa6c: e3a01000 mov r1, #0 fa70: e1a0000d mov r0, sp fa74: ebffccdd bl 2df0 fa78: e59d3000 ldr r3, [sp] fa7c: e5843040 str r3, [r4, #64] ; 0x40 fa80: e3a00000 mov r0, #0 return 0; } fa84: e8bd801c pop {r2, r3, r4, pc} 0000fa88 : rtems_off64_t memfile_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) { fa88: e92d4030 push {r4, r5, lr} IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; fa8c: e5905038 ldr r5, [r0, #56] ; 0x38 if (the_jnode->type == IMFS_LINEAR_FILE) { fa90: e595304c ldr r3, [r5, #76] ; 0x4c fa94: e3530006 cmp r3, #6 rtems_off64_t memfile_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) { fa98: e1a04000 mov r4, r0 IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; if (the_jnode->type == IMFS_LINEAR_FILE) { fa9c: 1a00000b bne fad0 if (iop->offset > the_jnode->info.linearfile.size) faa0: e5902010 ldr r2, [r0, #16] <== NOT EXECUTED faa4: e5953054 ldr r3, [r5, #84] ; 0x54 <== NOT EXECUTED faa8: e1520003 cmp r2, r3 <== NOT EXECUTED faac: e5952050 ldr r2, [r5, #80] ; 0x50 <== NOT EXECUTED fab0: ca000003 bgt fac4 <== NOT EXECUTED fab4: 1a000014 bne fb0c <== NOT EXECUTED fab8: e590100c ldr r1, [r0, #12] <== NOT EXECUTED fabc: e1510002 cmp r1, r2 <== NOT EXECUTED fac0: 9a000011 bls fb0c <== NOT EXECUTED iop->offset = the_jnode->info.linearfile.size; fac4: e584200c str r2, [r4, #12] <== NOT EXECUTED fac8: e5843010 str r3, [r4, #16] <== NOT EXECUTED facc: ea00000e b fb0c <== NOT EXECUTED } else { /* Must be a block file (IMFS_MEMORY_FILE). */ if (IMFS_memfile_extend( the_jnode, iop->offset )) fad0: e1a00005 mov r0, r5 fad4: e284200c add r2, r4, #12 fad8: e8920006 ldm r2, {r1, r2} fadc: ebffff79 bl f8c8 fae0: e3500000 cmp r0, #0 fae4: 0a000005 beq fb00 rtems_set_errno_and_return_minus_one( ENOSPC ); fae8: eb00041c bl 10b60 <__errno> <== NOT EXECUTED faec: e3a0301c mov r3, #28 <== NOT EXECUTED faf0: e5803000 str r3, [r0] <== NOT EXECUTED faf4: e3e04000 mvn r4, #0 <== NOT EXECUTED faf8: e3e03000 mvn r3, #0 <== NOT EXECUTED fafc: ea000004 b fb14 <== NOT EXECUTED iop->size = the_jnode->info.file.size; fb00: e2853050 add r3, r5, #80 ; 0x50 fb04: e893000c ldm r3, {r2, r3} fb08: e984000c stmib r4, {r2, r3} } return iop->offset; fb0c: e284400c add r4, r4, #12 fb10: e8940018 ldm r4, {r3, r4} } fb14: e1a01004 mov r1, r4 fb18: e1a00003 mov r0, r3 fb1c: e8bd8030 pop {r4, r5, pc} 0000fdac : the_jnode = iop->file_info; /* * Perform 'copy on write' for linear files */ if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND)) fdac: e5903014 ldr r3, [r0, #20] fdb0: e3130f81 tst r3, #516 ; 0x204 rtems_libio_t *iop, const char *pathname, uint32_t flag, uint32_t mode ) { fdb4: e92d4031 push {r0, r4, r5, lr} fdb8: e1a05000 mov r5, r0 IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; fdbc: e5904038 ldr r4, [r0, #56] ; 0x38 /* * Perform 'copy on write' for linear files */ if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND)) fdc0: 0a000017 beq fe24 && (the_jnode->type == IMFS_LINEAR_FILE)) { fdc4: e594304c ldr r3, [r4, #76] ; 0x4c fdc8: e3530006 cmp r3, #6 fdcc: 1a000014 bne fe24 uint32_t count = the_jnode->info.linearfile.size; fdd0: e594c050 ldr ip, [r4, #80] ; 0x50 <== NOT EXECUTED const unsigned char *buffer = the_jnode->info.linearfile.direct; the_jnode->type = IMFS_MEMORY_FILE; the_jnode->info.file.size = 0; the_jnode->info.file.indirect = 0; fdd4: e3a02000 mov r2, #0 <== NOT EXECUTED if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND)) && (the_jnode->type == IMFS_LINEAR_FILE)) { uint32_t count = the_jnode->info.linearfile.size; const unsigned char *buffer = the_jnode->info.linearfile.direct; the_jnode->type = IMFS_MEMORY_FILE; fdd8: e3a03005 mov r3, #5 <== NOT EXECUTED the_jnode->info.file.size = 0; fddc: e3a00000 mov r0, #0 <== NOT EXECUTED fde0: e3a01000 mov r1, #0 <== NOT EXECUTED the_jnode->info.file.indirect = 0; the_jnode->info.file.doubly_indirect = 0; the_jnode->info.file.triply_indirect = 0; if ((count != 0) fde4: e35c0000 cmp ip, #0 <== NOT EXECUTED if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND)) && (the_jnode->type == IMFS_LINEAR_FILE)) { uint32_t count = the_jnode->info.linearfile.size; const unsigned char *buffer = the_jnode->info.linearfile.direct; the_jnode->type = IMFS_MEMORY_FILE; fde8: e584304c str r3, [r4, #76] ; 0x4c <== NOT EXECUTED the_jnode->info.file.size = 0; the_jnode->info.file.indirect = 0; the_jnode->info.file.doubly_indirect = 0; the_jnode->info.file.triply_indirect = 0; fdec: e5842060 str r2, [r4, #96] ; 0x60 <== NOT EXECUTED * Perform 'copy on write' for linear files */ if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND)) && (the_jnode->type == IMFS_LINEAR_FILE)) { uint32_t count = the_jnode->info.linearfile.size; const unsigned char *buffer = the_jnode->info.linearfile.direct; fdf0: e5943058 ldr r3, [r4, #88] ; 0x58 <== NOT EXECUTED the_jnode->type = IMFS_MEMORY_FILE; the_jnode->info.file.size = 0; fdf4: e5840050 str r0, [r4, #80] ; 0x50 <== NOT EXECUTED fdf8: e5841054 str r1, [r4, #84] ; 0x54 <== NOT EXECUTED the_jnode->info.file.indirect = 0; the_jnode->info.file.doubly_indirect = 0; fdfc: e584205c str r2, [r4, #92] ; 0x5c <== NOT EXECUTED uint32_t count = the_jnode->info.linearfile.size; const unsigned char *buffer = the_jnode->info.linearfile.direct; the_jnode->type = IMFS_MEMORY_FILE; the_jnode->info.file.size = 0; the_jnode->info.file.indirect = 0; fe00: e5842058 str r2, [r4, #88] ; 0x58 <== NOT EXECUTED the_jnode->info.file.doubly_indirect = 0; the_jnode->info.file.triply_indirect = 0; if ((count != 0) fe04: 0a000006 beq fe24 <== NOT EXECUTED && (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1)) fe08: e1a02001 mov r2, r1 <== NOT EXECUTED fe0c: e1a01000 mov r1, r0 <== NOT EXECUTED fe10: e1a00004 mov r0, r4 <== NOT EXECUTED fe14: e58dc000 str ip, [sp] <== NOT EXECUTED fe18: ebffff40 bl fb20 <== NOT EXECUTED the_jnode->type = IMFS_MEMORY_FILE; the_jnode->info.file.size = 0; the_jnode->info.file.indirect = 0; the_jnode->info.file.doubly_indirect = 0; the_jnode->info.file.triply_indirect = 0; if ((count != 0) fe1c: e3700001 cmn r0, #1 <== NOT EXECUTED fe20: 0a000009 beq fe4c <== NOT EXECUTED && (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1)) return -1; } if (iop->flags & LIBIO_FLAGS_APPEND) fe24: e5953014 ldr r3, [r5, #20] fe28: e3130c02 tst r3, #512 ; 0x200 iop->offset = the_jnode->info.file.size; fe2c: 12843050 addne r3, r4, #80 ; 0x50 fe30: 1893000c ldmne r3, {r2, r3} fe34: 1585200c strne r2, [r5, #12] fe38: 15853010 strne r3, [r5, #16] iop->size = the_jnode->info.file.size; fe3c: e2844050 add r4, r4, #80 ; 0x50 fe40: e8940018 ldm r4, {r3, r4} fe44: e9850018 stmib r5, {r3, r4} fe48: e3a00000 mov r0, #0 return 0; } fe4c: e8bd8038 pop {r3, r4, r5, pc} 00001d18 : int mknod( const char *pathname, mode_t mode, dev_t dev ) { 1d18: e92d41f0 push {r4, r5, r6, r7, r8, lr} rtems_filesystem_location_info_t temp_loc; int i; const char *name_start; int result; if ( !(mode & (S_IFREG|S_IFCHR|S_IFBLK|S_IFIFO) ) ) 1d1c: e3110a0f tst r1, #61440 ; 0xf000 int mknod( const char *pathname, mode_t mode, dev_t dev ) { 1d20: e24dd01c sub sp, sp, #28 1d24: e1a05001 mov r5, r1 1d28: e1a06000 mov r6, r0 1d2c: e1a07002 mov r7, r2 1d30: e1a08003 mov r8, r3 rtems_filesystem_location_info_t temp_loc; int i; const char *name_start; int result; if ( !(mode & (S_IFREG|S_IFCHR|S_IFBLK|S_IFIFO) ) ) 1d34: 1a000002 bne 1d44 rtems_set_errno_and_return_minus_one( EINVAL ); 1d38: eb002784 bl bb50 <__errno> <== NOT EXECUTED 1d3c: e3a03016 mov r3, #22 <== NOT EXECUTED 1d40: ea000020 b 1dc8 <== NOT EXECUTED rtems_filesystem_get_start_loc( pathname, &i, &temp_loc ); 1d44: e5d03000 ldrb r3, [r0] 1d48: e353002f cmp r3, #47 ; 0x2f 1d4c: 1353005c cmpne r3, #92 ; 0x5c 1d50: 13a04000 movne r4, #0 1d54: 03a04001 moveq r4, #1 1d58: 0a000001 beq 1d64 1d5c: e3530000 cmp r3, #0 1d60: 1a000009 bne 1d8c 1d64: e59f3100 ldr r3, [pc, #256] ; 1e6c 1d68: e593e000 ldr lr, [r3] 1d6c: e28ee018 add lr, lr, #24 1d70: e8be000f ldm lr!, {r0, r1, r2, r3} 1d74: e28dc004 add ip, sp, #4 1d78: e8ac000f stmia ip!, {r0, r1, r2, r3} 1d7c: e59e3000 ldr r3, [lr] 1d80: e3a00001 mov r0, #1 1d84: e58c3000 str r3, [ip] 1d88: ea000008 b 1db0 1d8c: e59f30d8 ldr r3, [pc, #216] ; 1e6c 1d90: e593e000 ldr lr, [r3] 1d94: e28ee004 add lr, lr, #4 1d98: e8be000f ldm lr!, {r0, r1, r2, r3} 1d9c: e28dc004 add ip, sp, #4 1da0: e8ac000f stmia ip!, {r0, r1, r2, r3} 1da4: e59e3000 ldr r3, [lr] 1da8: e58c3000 str r3, [ip] 1dac: e1a00004 mov r0, r4 if ( !temp_loc.ops->evalformake_h ) { 1db0: e59d3010 ldr r3, [sp, #16] 1db4: e5933004 ldr r3, [r3, #4] 1db8: e3530000 cmp r3, #0 1dbc: 1a000004 bne 1dd4 rtems_set_errno_and_return_minus_one( ENOTSUP ); 1dc0: eb002762 bl bb50 <__errno> <== NOT EXECUTED 1dc4: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 1dc8: e5803000 str r3, [r0] <== NOT EXECUTED 1dcc: e3e05000 mvn r5, #0 1dd0: ea000022 b 1e60 } result = (*temp_loc.ops->evalformake_h)( 1dd4: e28d4004 add r4, sp, #4 1dd8: e0860000 add r0, r6, r0 1ddc: e1a01004 mov r1, r4 1de0: e28d2018 add r2, sp, #24 1de4: e1a0e00f mov lr, pc 1de8: e12fff13 bx r3 &pathname[i], &temp_loc, &name_start ); if ( result != 0 ) 1dec: e3500000 cmp r0, #0 1df0: 1afffff5 bne 1dcc return -1; if ( !temp_loc.ops->mknod_h ) { 1df4: e59d3010 ldr r3, [sp, #16] 1df8: e593c014 ldr ip, [r3, #20] 1dfc: e35c0000 cmp ip, #0 1e00: 1a000006 bne 1e20 rtems_filesystem_freenode( &temp_loc ); 1e04: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 1e08: e3530000 cmp r3, #0 <== NOT EXECUTED 1e0c: 0affffeb beq 1dc0 <== NOT EXECUTED 1e10: e1a00004 mov r0, r4 <== NOT EXECUTED 1e14: e1a0e00f mov lr, pc <== NOT EXECUTED 1e18: e12fff13 bx r3 <== NOT EXECUTED 1e1c: eaffffe7 b 1dc0 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*temp_loc.ops->mknod_h)( name_start, mode, dev, &temp_loc ); 1e20: e1a01005 mov r1, r5 1e24: e1a03008 mov r3, r8 1e28: e58d4000 str r4, [sp] 1e2c: e1a02007 mov r2, r7 1e30: e59d0018 ldr r0, [sp, #24] 1e34: e1a0e00f mov lr, pc 1e38: e12fff1c bx ip rtems_filesystem_freenode( &temp_loc ); 1e3c: e59d3010 ldr r3, [sp, #16] 1e40: e3530000 cmp r3, #0 if ( !temp_loc.ops->mknod_h ) { rtems_filesystem_freenode( &temp_loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*temp_loc.ops->mknod_h)( name_start, mode, dev, &temp_loc ); 1e44: e1a05000 mov r5, r0 rtems_filesystem_freenode( &temp_loc ); 1e48: 0a000004 beq 1e60 1e4c: e593301c ldr r3, [r3, #28] 1e50: e3530000 cmp r3, #0 1e54: 11a00004 movne r0, r4 1e58: 11a0e00f movne lr, pc 1e5c: 112fff13 bxne r3 return result; } 1e60: e1a00005 mov r0, r5 1e64: e28dd01c add sp, sp, #28 1e68: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 1e6c: 00017718 .word 0x00017718 00001e8c : const rtems_filesystem_operations_table *fs_ops, rtems_filesystem_options_t options, const char *device, const char *mount_point ) { 1e8c: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} /* * Is there a file system operations table? */ if ( fs_ops == NULL ) { 1e90: e2517000 subs r7, r1, #0 const rtems_filesystem_operations_table *fs_ops, rtems_filesystem_options_t options, const char *device, const char *mount_point ) { 1e94: e24dd018 sub sp, sp, #24 1e98: e1a06000 mov r6, r0 1e9c: e1a09002 mov r9, r2 1ea0: e1a0b003 mov fp, r3 1ea4: e59da03c ldr sl, [sp, #60] ; 0x3c /* * Is there a file system operations table? */ if ( fs_ops == NULL ) { 1ea8: 0a000001 beq 1eb4 /* * Are the file system options valid? */ if ( options != RTEMS_FILESYSTEM_READ_ONLY && 1eac: e3520001 cmp r2, #1 1eb0: 9a000002 bls 1ec0 options != RTEMS_FILESYSTEM_READ_WRITE ) { errno = EINVAL; 1eb4: eb002725 bl bb50 <__errno> 1eb8: e3a03016 mov r3, #22 1ebc: ea000014 b 1f14 return -1; } /* Do they support being mounted at all ? */ if ( !fs_ops->fsmount_me_h ) { 1ec0: e5975024 ldr r5, [r7, #36] ; 0x24 1ec4: e3550000 cmp r5, #0 1ec8: 1a000004 bne 1ee0 errno = ENOTSUP; 1ecc: eb00271f bl bb50 <__errno> <== NOT EXECUTED 1ed0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 1ed4: e5803000 str r3, [r0] <== NOT EXECUTED 1ed8: e1a08005 mov r8, r5 <== NOT EXECUTED goto cleanup_and_bail; 1edc: ea00006d b 2098 <== NOT EXECUTED /* * Allocate a mount table entry */ size = sizeof(rtems_filesystem_mount_table_entry_t); if ( device ) 1ee0: e3530000 cmp r3, #0 1ee4: 03a0006c moveq r0, #108 ; 0x6c 1ee8: 0a000002 beq 1ef8 size += strlen( device ) + 1; 1eec: e1a00003 mov r0, r3 <== NOT EXECUTED 1ef0: eb002b07 bl cb14 <== NOT EXECUTED 1ef4: e280006d add r0, r0, #109 ; 0x6d <== NOT EXECUTED temp_mt_entry = malloc( size ); 1ef8: ebffff44 bl 1c10 if ( !temp_mt_entry ) { 1efc: e3500000 cmp r0, #0 */ size = sizeof(rtems_filesystem_mount_table_entry_t); if ( device ) size += strlen( device ) + 1; temp_mt_entry = malloc( size ); 1f00: e1a04000 mov r4, r0 1f04: e1a08000 mov r8, r0 if ( !temp_mt_entry ) { 1f08: 1a000003 bne 1f1c errno = ENOMEM; 1f0c: eb00270f bl bb50 <__errno> <== NOT EXECUTED 1f10: e3a0300c mov r3, #12 <== NOT EXECUTED 1f14: e5803000 str r3, [r0] 1f18: ea00006a b 20c8 return -1; } temp_mt_entry->mt_fs_root.mt_entry = temp_mt_entry; temp_mt_entry->options = options; if ( device ) { 1f1c: e35b0000 cmp fp, #0 errno = ENOMEM; return -1; } temp_mt_entry->mt_fs_root.mt_entry = temp_mt_entry; temp_mt_entry->options = options; 1f20: e5809030 str r9, [r0, #48] ; 0x30 if ( !temp_mt_entry ) { errno = ENOMEM; return -1; } temp_mt_entry->mt_fs_root.mt_entry = temp_mt_entry; 1f24: e584002c str r0, [r4, #44] ; 0x2c if ( device ) { temp_mt_entry->dev = (char *)temp_mt_entry + sizeof( rtems_filesystem_mount_table_entry_t ); strcpy( temp_mt_entry->dev, device ); } else temp_mt_entry->dev = 0; 1f28: 0580b068 streq fp, [r0, #104] ; 0x68 temp_mt_entry->mt_fs_root.mt_entry = temp_mt_entry; temp_mt_entry->options = options; if ( device ) { temp_mt_entry->dev = (char *)temp_mt_entry + sizeof( rtems_filesystem_mount_table_entry_t ); 1f2c: 1280306c addne r3, r0, #108 ; 0x6c strcpy( temp_mt_entry->dev, device ); 1f30: 11a00003 movne r0, r3 1f34: 11a0100b movne r1, fp } temp_mt_entry->mt_fs_root.mt_entry = temp_mt_entry; temp_mt_entry->options = options; if ( device ) { temp_mt_entry->dev = 1f38: 15843068 strne r3, [r4, #104] ; 0x68 (char *)temp_mt_entry + sizeof( rtems_filesystem_mount_table_entry_t ); strcpy( temp_mt_entry->dev, device ); 1f3c: 1b002ab8 blne ca24 /* * The mount_point should be a directory with read/write/execute * permissions in the existing tree. */ if ( mount_point ) { 1f40: e35a0000 cmp sl, #0 1f44: 0a000035 beq 2020 if ( rtems_filesystem_evaluate_path( mount_point, strlen( mount_point ), RTEMS_LIBIO_PERMS_RWX, &loc, true ) == -1 ) 1f48: e1a0000a mov r0, sl 1f4c: eb002af0 bl cb14 * permissions in the existing tree. */ if ( mount_point ) { if ( rtems_filesystem_evaluate_path( 1f50: e28d5004 add r5, sp, #4 mount_point, strlen( mount_point ), RTEMS_LIBIO_PERMS_RWX, &loc, true ) == -1 ) 1f54: e1a01000 mov r1, r0 * permissions in the existing tree. */ if ( mount_point ) { if ( rtems_filesystem_evaluate_path( 1f58: e3a0c001 mov ip, #1 1f5c: e1a0000a mov r0, sl 1f60: e3a02007 mov r2, #7 1f64: e1a03005 mov r3, r5 1f68: e58dc000 str ip, [sp] 1f6c: ebfffe42 bl 187c 1f70: e3700001 cmn r0, #1 1f74: 0a000046 beq 2094 /* * Test for node_type_h */ if (!loc.ops->node_type_h) { 1f78: e59d3010 ldr r3, [sp, #16] 1f7c: e5933010 ldr r3, [r3, #16] 1f80: e3530000 cmp r3, #0 1f84: 1a000002 bne 1f94 errno = ENOTSUP; 1f88: eb0026f0 bl bb50 <__errno> <== NOT EXECUTED 1f8c: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 1f90: ea000006 b 1fb0 <== NOT EXECUTED /* * Test to see if it is a directory */ if ( loc.ops->node_type_h( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) { 1f94: e1a00005 mov r0, r5 1f98: e1a0e00f mov lr, pc 1f9c: e12fff13 bx r3 1fa0: e3500001 cmp r0, #1 1fa4: 0a000003 beq 1fb8 errno = ENOTDIR; 1fa8: eb0026e8 bl bb50 <__errno> 1fac: e3a03014 mov r3, #20 1fb0: e5803000 str r3, [r0] goto cleanup_and_bail; 1fb4: ea000037 b 2098 /* * For each mount table entry */ for ( the_node = rtems_filesystem_mount_table_control.first; 1fb8: e59f2140 ldr r2, [pc, #320] ; 2100 !rtems_chain_is_tail( &rtems_filesystem_mount_table_control, the_node ); the_node = the_node->next ) { the_mount_entry = (rtems_filesystem_mount_table_entry_t *) the_node; if ( the_mount_entry->mt_fs_root.node_access == loc->node_access ) 1fbc: e59d1004 ldr r1, [sp, #4] /* * For each mount table entry */ for ( the_node = rtems_filesystem_mount_table_control.first; 1fc0: e4923004 ldr r3, [r2], #4 1fc4: ea000003 b 1fd8 !rtems_chain_is_tail( &rtems_filesystem_mount_table_control, the_node ); the_node = the_node->next ) { the_mount_entry = (rtems_filesystem_mount_table_entry_t *) the_node; if ( the_mount_entry->mt_fs_root.node_access == loc->node_access ) 1fc8: e593001c ldr r0, [r3, #28] 1fcc: e1500001 cmp r0, r1 1fd0: 0a000003 beq 1fe4 * For each mount table entry */ for ( the_node = rtems_filesystem_mount_table_control.first; !rtems_chain_is_tail( &rtems_filesystem_mount_table_control, the_node ); the_node = the_node->next ) { 1fd4: e5933000 ldr r3, [r3] */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 1fd8: e1530002 cmp r3, r2 1fdc: 1afffff9 bne 1fc8 1fe0: ea00003b b 20d4 /* * You can only mount one file system onto a single mount point. */ if ( Is_node_fs_root( &loc ) ){ errno = EBUSY; 1fe4: eb0026d9 bl bb50 <__errno> 1fe8: e3a03010 mov r3, #16 1fec: ea000001 b 1ff8 * This link to the parent is only done when we are dealing with system * below the base file system */ if ( !loc.ops->mount_h ){ errno = ENOTSUP; 1ff0: eb0026d6 bl bb50 <__errno> <== NOT EXECUTED 1ff4: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 1ff8: e5803000 str r3, [r0] 1ffc: e28d5004 add r5, sp, #4 goto cleanup_and_bail; 2000: ea000024 b 2098 } if ( loc.ops->mount_h( temp_mt_entry ) ) { 2004: e1a00004 mov r0, r4 2008: e1a0e00f mov lr, pc 200c: e12fff13 bx r3 2010: e3500000 cmp r0, #0 2014: e28d5004 add r5, sp, #4 2018: 0a000008 beq 2040 201c: ea00001d b 2098 <== NOT EXECUTED * This is a mount of the base file system --> The * mt_point_node.node_access will be set to null to indicate that this * is the root of the entire file system. */ temp_mt_entry->mt_fs_root.node_access = NULL; 2020: e584a01c str sl, [r4, #28] temp_mt_entry->mt_fs_root.handlers = NULL; 2024: e584a024 str sl, [r4, #36] ; 0x24 temp_mt_entry->mt_fs_root.ops = NULL; 2028: e584a028 str sl, [r4, #40] ; 0x28 temp_mt_entry->mt_point_node.node_access = NULL; 202c: e584a008 str sl, [r4, #8] temp_mt_entry->mt_point_node.handlers = NULL; 2030: e584a010 str sl, [r4, #16] temp_mt_entry->mt_point_node.ops = NULL; 2034: e584a014 str sl, [r4, #20] temp_mt_entry->mt_point_node.mt_entry = NULL; 2038: e584a018 str sl, [r4, #24] 203c: e1a0500a mov r5, sl } if ( fs_ops->fsmount_me_h( temp_mt_entry ) ) { 2040: e1a00004 mov r0, r4 2044: e1a0e00f mov lr, pc 2048: e597f024 ldr pc, [r7, #36] ; 0x24 204c: e2507000 subs r7, r0, #0 2050: 0a000007 beq 2074 /* try to undo the mount operation */ if ( loc.ops->unmount_h ) { 2054: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 2058: e5933028 ldr r3, [r3, #40] ; 0x28 <== NOT EXECUTED 205c: e3530000 cmp r3, #0 <== NOT EXECUTED 2060: 0a00000c beq 2098 <== NOT EXECUTED loc.ops->unmount_h( temp_mt_entry ); 2064: e1a00004 mov r0, r4 <== NOT EXECUTED 2068: e1a0e00f mov lr, pc <== NOT EXECUTED 206c: e12fff13 bx r3 <== NOT EXECUTED 2070: ea000008 b 2098 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void rtems_chain_append( rtems_chain_control *the_chain, rtems_chain_node *the_node ) { _Chain_Append( the_chain, the_node ); 2074: e59f0084 ldr r0, [pc, #132] ; 2100 2078: e1a01004 mov r1, r4 207c: eb000cb4 bl 5354 <_Chain_Append> */ rtems_chain_append( &rtems_filesystem_mount_table_control, &temp_mt_entry->Node ); if ( mt_entry ) 2080: e3560000 cmp r6, #0 2084: 01a00006 moveq r0, r6 *mt_entry = temp_mt_entry; 2088: 15864000 strne r4, [r6] 208c: 11a00007 movne r0, r7 2090: ea00000d b 20cc 2094: e3a05000 mov r5, #0 <== NOT EXECUTED return 0; cleanup_and_bail: free( temp_mt_entry ); 2098: e1a00008 mov r0, r8 209c: ebfffe29 bl 1948 if ( loc_to_free ) 20a0: e3550000 cmp r5, #0 20a4: 0a000007 beq 20c8 rtems_filesystem_freenode( loc_to_free ); 20a8: e595300c ldr r3, [r5, #12] 20ac: e3530000 cmp r3, #0 20b0: 0a000004 beq 20c8 20b4: e593301c ldr r3, [r3, #28] 20b8: e3530000 cmp r3, #0 20bc: 11a00005 movne r0, r5 20c0: 11a0e00f movne lr, pc 20c4: 112fff13 bxne r3 20c8: e3e00000 mvn r0, #0 return -1; } 20cc: e28dd018 add sp, sp, #24 20d0: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} * traverse the tree. */ temp_mt_entry->mt_point_node.node_access = loc.node_access; temp_mt_entry->mt_point_node.handlers = loc.handlers; temp_mt_entry->mt_point_node.ops = loc.ops; 20d4: e59d2010 ldr r2, [sp, #16] * may have been allocated in loc should not be sent to freenode * until the system is unmounted. It may be needed to correctly * traverse the tree. */ temp_mt_entry->mt_point_node.node_access = loc.node_access; 20d8: e5841008 str r1, [r4, #8] temp_mt_entry->mt_point_node.handlers = loc.handlers; 20dc: e59d100c ldr r1, [sp, #12] /* * This link to the parent is only done when we are dealing with system * below the base file system */ if ( !loc.ops->mount_h ){ 20e0: e5923020 ldr r3, [r2, #32] * until the system is unmounted. It may be needed to correctly * traverse the tree. */ temp_mt_entry->mt_point_node.node_access = loc.node_access; temp_mt_entry->mt_point_node.handlers = loc.handlers; 20e4: e5841010 str r1, [r4, #16] temp_mt_entry->mt_point_node.ops = loc.ops; temp_mt_entry->mt_point_node.mt_entry = loc.mt_entry; 20e8: e59d1014 ldr r1, [sp, #20] /* * This link to the parent is only done when we are dealing with system * below the base file system */ if ( !loc.ops->mount_h ){ 20ec: e3530000 cmp r3, #0 */ temp_mt_entry->mt_point_node.node_access = loc.node_access; temp_mt_entry->mt_point_node.handlers = loc.handlers; temp_mt_entry->mt_point_node.ops = loc.ops; temp_mt_entry->mt_point_node.mt_entry = loc.mt_entry; 20f0: e5841018 str r1, [r4, #24] * traverse the tree. */ temp_mt_entry->mt_point_node.node_access = loc.node_access; temp_mt_entry->mt_point_node.handlers = loc.handlers; temp_mt_entry->mt_point_node.ops = loc.ops; 20f4: e5842014 str r2, [r4, #20] /* * This link to the parent is only done when we are dealing with system * below the base file system */ if ( !loc.ops->mount_h ){ 20f8: 1affffc1 bne 2004 20fc: eaffffbb b 1ff0 <== NOT EXECUTED 2100: 00018cf4 .word 0x00018cf4 00002174 : */ int newlib_free_buffers( FILE *fp ) { 2174: e92d4010 push {r4, lr} 2178: e1a04000 mov r4, r0 switch ( fileno(fp) ) { 217c: eb002772 bl bf4c 2180: e3500002 cmp r0, #2 2184: 8a00000b bhi 21b8 case 0: case 1: case 2: if (fp->_flags & __SMBF) { 2188: e1d430bc ldrh r3, [r4, #12] 218c: e3130080 tst r3, #128 ; 0x80 2190: 0a00000a beq 21c0 free( fp->_bf._base ); 2194: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 2198: ebfffdea bl 1948 <== NOT EXECUTED fp->_flags &= ~__SMBF; 219c: e1d420bc ldrh r2, [r4, #12] <== NOT EXECUTED fp->_bf._base = fp->_p = (unsigned char *) NULL; 21a0: e3a03000 mov r3, #0 <== NOT EXECUTED case 0: case 1: case 2: if (fp->_flags & __SMBF) { free( fp->_bf._base ); fp->_flags &= ~__SMBF; 21a4: e3c22080 bic r2, r2, #128 ; 0x80 <== NOT EXECUTED fp->_bf._base = fp->_p = (unsigned char *) NULL; 21a8: e5843010 str r3, [r4, #16] <== NOT EXECUTED case 0: case 1: case 2: if (fp->_flags & __SMBF) { free( fp->_bf._base ); fp->_flags &= ~__SMBF; 21ac: e1c420bc strh r2, [r4, #12] <== NOT EXECUTED fp->_bf._base = fp->_p = (unsigned char *) NULL; 21b0: e5843000 str r3, [r4] <== NOT EXECUTED 21b4: ea000001 b 21c0 <== NOT EXECUTED } break; default: fclose(fp); 21b8: e1a00004 mov r0, r4 <== NOT EXECUTED 21bc: eb0026b0 bl bc84 <== NOT EXECUTED } return 0; } 21c0: e3a00000 mov r0, #0 21c4: e8bd8010 pop {r4, pc} 000023e8 : int open( const char *pathname, int flags, ... ) { 23e8: e92d000e push {r1, r2, r3} 23ec: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} 23f0: e24dd01c sub sp, sp, #28 23f4: e59d503c ldr r5, [sp, #60] ; 0x3c /* * Set the Evaluation flags */ eval_flags = 0; status = flags + 1; 23f8: e2853001 add r3, r5, #1 if ( ( status & _FREAD ) == _FREAD ) 23fc: e2138001 ands r8, r3, #1 2400: 13a08004 movne r8, #4 eval_flags |= RTEMS_LIBIO_PERMS_READ; if ( ( status & _FWRITE ) == _FWRITE ) 2404: e3130002 tst r3, #2 eval_flags |= RTEMS_LIBIO_PERMS_WRITE; va_start(ap, flags); mode = va_arg( ap, int ); 2408: e28d3044 add r3, sp, #68 ; 0x44 eval_flags = 0; status = flags + 1; if ( ( status & _FREAD ) == _FREAD ) eval_flags |= RTEMS_LIBIO_PERMS_READ; if ( ( status & _FWRITE ) == _FWRITE ) eval_flags |= RTEMS_LIBIO_PERMS_WRITE; 240c: 13888002 orrne r8, r8, #2 int open( const char *pathname, int flags, ... ) { 2410: e1a06000 mov r6, r0 eval_flags |= RTEMS_LIBIO_PERMS_WRITE; va_start(ap, flags); mode = va_arg( ap, int ); 2414: e58d3018 str r3, [sp, #24] 2418: e59d9040 ldr r9, [sp, #64] ; 0x40 * code does not require changes here since network file * descriptors are obtained using socket(), not open(). */ /* allocate a file control block */ iop = rtems_libio_allocate(); 241c: eb001b88 bl 9244 if ( iop == 0 ) { 2420: e2504000 subs r4, r0, #0 2424: 03a05017 moveq r5, #23 2428: 0a000077 beq 260c /* * See if the file exists. */ status = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), eval_flags, &loc, true ); 242c: e1a00006 mov r0, r6 2430: eb0029b7 bl cb14 /* * See if the file exists. */ status = rtems_filesystem_evaluate_path( 2434: e28d7004 add r7, sp, #4 pathname, strlen( pathname ), eval_flags, &loc, true ); 2438: e1a01000 mov r1, r0 /* * See if the file exists. */ status = rtems_filesystem_evaluate_path( 243c: e1a02008 mov r2, r8 2440: e1a00006 mov r0, r6 2444: e3a08001 mov r8, #1 2448: e1a03007 mov r3, r7 244c: e58d8000 str r8, [sp] 2450: ebfffd09 bl 187c pathname, strlen( pathname ), eval_flags, &loc, true ); if ( status == -1 ) { 2454: e3700001 cmn r0, #1 2458: 1a00001f bne 24dc if ( errno != ENOENT ) { 245c: eb0025bb bl bb50 <__errno> 2460: e5903000 ldr r3, [r0] 2464: e3530002 cmp r3, #2 2468: 1a00000a bne 2498 rc = errno; goto done; } /* If the file does not exist and we are not trying to create it--> error */ if ( !(flags & O_CREAT) ) { 246c: e215ac02 ands sl, r5, #512 ; 0x200 2470: 01a0700a moveq r7, sl 2474: 01a05003 moveq r5, r3 2478: 0a000056 beq 25d8 rc = ENOENT; goto done; } /* Create the node for the new regular file */ rc = mknod( pathname, S_IFREG | mode, 0LL ); 247c: e1a00006 mov r0, r6 2480: e3891902 orr r1, r9, #32768 ; 0x8000 2484: e3a02000 mov r2, #0 2488: e3a03000 mov r3, #0 248c: ebfffe21 bl 1d18 if ( rc ) { 2490: e250a000 subs sl, r0, #0 2494: 0a000003 beq 24a8 rc = errno; 2498: eb0025ac bl bb50 <__errno> 249c: e3a07000 mov r7, #0 24a0: e5905000 ldr r5, [r0] goto done; 24a4: ea000049 b 25d0 } /* Sanity check to see if the file name exists after the mknod() */ status = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), 0x0, &loc, true ); 24a8: e1a00006 mov r0, r6 24ac: eb002998 bl cb14 24b0: e1a03007 mov r3, r7 24b4: e1a01000 mov r1, r0 24b8: e1a0200a mov r2, sl 24bc: e1a00006 mov r0, r6 24c0: e58d8000 str r8, [sp] 24c4: ebfffcec bl 187c if ( status != 0 ) { /* The file did not exist */ 24c8: e3500000 cmp r0, #0 24cc: 11a0700a movne r7, sl 24d0: 13a0500d movne r5, #13 24d4: 1a00003f bne 25d8 24d8: ea000003 b 24ec rc = EACCES; goto done; } } else if ((flags & (O_EXCL|O_CREAT)) == (O_EXCL|O_CREAT)) { 24dc: e2053c0a and r3, r5, #2560 ; 0xa00 24e0: e3530c0a cmp r3, #2560 ; 0xa00 24e4: 03a05011 moveq r5, #17 24e8: 0a00003a beq 25d8 * Fill in the file control block based on the loc structure * returned by successful path evaluation. */ iop->handlers = loc.handlers; iop->file_info = loc.node_access; 24ec: e28d701c add r7, sp, #28 24f0: e5373018 ldr r3, [r7, #-24]! 24f4: e5843038 str r3, [r4, #56] ; 0x38 /* * Fill in the file control block based on the loc structure * returned by successful path evaluation. */ iop->handlers = loc.handlers; 24f8: e59d300c ldr r3, [sp, #12] iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags ); 24fc: e1a00005 mov r0, r5 /* * Fill in the file control block based on the loc structure * returned by successful path evaluation. */ iop->handlers = loc.handlers; 2500: e584303c str r3, [r4, #60] ; 0x3c iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags ); 2504: e5948014 ldr r8, [r4, #20] 2508: eb001b73 bl 92dc 250c: e180e008 orr lr, r0, r8 iop->pathinfo = loc; 2510: e8b7000f ldm r7!, {r0, r1, r2, r3} 2514: e284c018 add ip, r4, #24 2518: e8ac000f stmia ip!, {r0, r1, r2, r3} if ( !iop->handlers || !iop->handlers->open_h ) { 251c: e594303c ldr r3, [r4, #60] ; 0x3c */ iop->handlers = loc.handlers; iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags ); iop->pathinfo = loc; 2520: e5972000 ldr r2, [r7] if ( !iop->handlers || !iop->handlers->open_h ) { 2524: e3530000 cmp r3, #0 */ iop->handlers = loc.handlers; iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags ); iop->pathinfo = loc; 2528: e58c2000 str r2, [ip] * returned by successful path evaluation. */ iop->handlers = loc.handlers; iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags ); 252c: e584e014 str lr, [r4, #20] iop->pathinfo = loc; if ( !iop->handlers || !iop->handlers->open_h ) { 2530: 0a000041 beq 263c 2534: e593c000 ldr ip, [r3] 2538: e35c0000 cmp ip, #0 253c: 0a00003e beq 263c rc = ENOTSUP; goto done; } rc = (*iop->handlers->open_h)( iop, pathname, flags, mode ); 2540: e1a01006 mov r1, r6 2544: e1a03009 mov r3, r9 2548: e1a00004 mov r0, r4 254c: e1a02005 mov r2, r5 2550: e1a0e00f mov lr, pc 2554: e12fff1c bx ip if ( rc ) { 2558: e3500000 cmp r0, #0 255c: 0a000003 beq 2570 rc = errno; 2560: eb00257a bl bb50 <__errno> 2564: e28d7004 add r7, sp, #4 2568: e5905000 ldr r5, [r0] goto done; 256c: ea000017 b 25d0 /* * Optionally truncate the file. */ if ( (flags & O_TRUNC) == O_TRUNC ) { 2570: e3150b01 tst r5, #1024 ; 0x400 2574: 0a000028 beq 261c rc = ftruncate( iop - rtems_libio_iops, 0 ); 2578: e59f30c8 ldr r3, [pc, #200] ; 2648 257c: e5930000 ldr r0, [r3] 2580: e0600004 rsb r0, r0, r4 2584: e1a00340 asr r0, r0, #6 2588: e3a01000 mov r1, #0 258c: e3a02000 mov r2, #0 2590: eb001a79 bl 8f7c if ( rc ) { 2594: e2505000 subs r5, r0, #0 2598: 0a00001f beq 261c if(errno) rc = errno; 259c: eb00256b bl bb50 <__errno> <== NOT EXECUTED 25a0: e5903000 ldr r3, [r0] <== NOT EXECUTED 25a4: e3530000 cmp r3, #0 <== NOT EXECUTED 25a8: 0a000001 beq 25b4 <== NOT EXECUTED 25ac: eb002567 bl bb50 <__errno> <== NOT EXECUTED 25b0: e5905000 ldr r5, [r0] <== NOT EXECUTED close( iop - rtems_libio_iops ); 25b4: e59f308c ldr r3, [pc, #140] ; 2648 <== NOT EXECUTED 25b8: e5933000 ldr r3, [r3] <== NOT EXECUTED 25bc: e0634004 rsb r4, r3, r4 <== NOT EXECUTED 25c0: e1a00344 asr r0, r4, #6 <== NOT EXECUTED 25c4: eb001a43 bl 8ed8 <== NOT EXECUTED 25c8: e3a04000 mov r4, #0 <== NOT EXECUTED 25cc: e1a07004 mov r7, r4 <== NOT EXECUTED */ done: va_end(ap); if ( rc ) { 25d0: e3550000 cmp r5, #0 25d4: 0a000010 beq 261c if ( iop ) 25d8: e3540000 cmp r4, #0 rtems_libio_free( iop ); 25dc: 11a00004 movne r0, r4 25e0: 1b001b07 blne 9204 if ( loc_to_free ) 25e4: e3570000 cmp r7, #0 25e8: 0a000007 beq 260c rtems_filesystem_freenode( loc_to_free ); 25ec: e597300c ldr r3, [r7, #12] 25f0: e3530000 cmp r3, #0 25f4: 0a000004 beq 260c 25f8: e593301c ldr r3, [r3, #28] 25fc: e3530000 cmp r3, #0 2600: 11a00007 movne r0, r7 2604: 11a0e00f movne lr, pc 2608: 112fff13 bxne r3 rtems_set_errno_and_return_minus_one( rc ); 260c: eb00254f bl bb50 <__errno> 2610: e5805000 str r5, [r0] 2614: e3e00000 mvn r0, #0 2618: ea000003 b 262c } return iop - rtems_libio_iops; 261c: e59f3024 ldr r3, [pc, #36] ; 2648 2620: e5930000 ldr r0, [r3] 2624: e0604004 rsb r4, r0, r4 2628: e1a00344 asr r0, r4, #6 } 262c: e28dd01c add sp, sp, #28 2630: e8bd47f0 pop {r4, r5, r6, r7, r8, r9, sl, lr} 2634: e28dd00c add sp, sp, #12 2638: e12fff1e bx lr if ( loc_to_free ) rtems_filesystem_freenode( loc_to_free ); rtems_set_errno_and_return_minus_one( rc ); } return iop - rtems_libio_iops; 263c: e28d7004 add r7, sp, #4 <== NOT EXECUTED 2640: e3a05086 mov r5, #134 ; 0x86 <== NOT EXECUTED 2644: eaffffe3 b 25d8 <== NOT EXECUTED 2648: 00018cb0 .word 0x00018cb0 00002384 : int stderr_fd; /* * Attempt to open /dev/console. */ if ((stdin_fd = open("/dev/console", O_RDONLY, 0)) == -1) { 2384: e3a01000 mov r1, #0 /* * This is a replaceable stub which opens the console, if present. */ void open_dev_console(void) { 2388: e52de004 push {lr} ; (str lr, [sp, #-4]!) int stderr_fd; /* * Attempt to open /dev/console. */ if ((stdin_fd = open("/dev/console", O_RDONLY, 0)) == -1) { 238c: e59f0048 ldr r0, [pc, #72] ; 23dc 2390: e1a02001 mov r2, r1 2394: eb000013 bl 23e8 2398: e3700001 cmn r0, #1 239c: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) /* * But if we find /dev/console once, we better find it twice more * or something is REALLY wrong. */ if ((stdout_fd = open("/dev/console", O_WRONLY, 0)) == -1) 23a0: e59f0034 ldr r0, [pc, #52] ; 23dc 23a4: e3a01001 mov r1, #1 23a8: e3a02000 mov r2, #0 23ac: eb00000d bl 23e8 23b0: e3700001 cmn r0, #1 rtems_fatal_error_occurred( 0x55544431 ); /* error STD1 */ 23b4: 059f0024 ldreq r0, [pc, #36] ; 23e0 /* * But if we find /dev/console once, we better find it twice more * or something is REALLY wrong. */ if ((stdout_fd = open("/dev/console", O_WRONLY, 0)) == -1) 23b8: 0a000006 beq 23d8 rtems_fatal_error_occurred( 0x55544431 ); /* error STD1 */ if ((stderr_fd = open("/dev/console", O_WRONLY, 0)) == -1) 23bc: e59f0018 ldr r0, [pc, #24] ; 23dc 23c0: e3a01001 mov r1, #1 23c4: e3a02000 mov r2, #0 23c8: eb000006 bl 23e8 23cc: e3700001 cmn r0, #1 23d0: 149df004 popne {pc} ; (ldrne pc, [sp], #4) rtems_fatal_error_occurred( 0x55544432 ); /* error STD2 */ 23d4: e59f0008 ldr r0, [pc, #8] ; 23e4 <== NOT EXECUTED 23d8: eb000b35 bl 50b4 <== NOT EXECUTED 23dc: 0001847b .word 0x0001847b 23e0: 55544431 .word 0x55544431 23e4: 55544432 .word 0x55544432 00002d10 : /* * Handle output processing */ static void oproc (unsigned char c, struct rtems_termios_tty *tty) { 2d10: e92d4011 push {r0, r4, lr} int i; if (tty->termios.c_oflag & OPOST) { 2d14: e5913034 ldr r3, [r1, #52] ; 0x34 2d18: e3130001 tst r3, #1 /* * Handle output processing */ static void oproc (unsigned char c, struct rtems_termios_tty *tty) { 2d1c: e1a04001 mov r4, r1 2d20: e5cd0000 strb r0, [sp] int i; if (tty->termios.c_oflag & OPOST) { 2d24: 0a000047 beq 2e48 switch (c) { 2d28: e5dd2000 ldrb r2, [sp] 2d2c: e2421008 sub r1, r2, #8 2d30: e3510005 cmp r1, #5 2d34: 979ff101 ldrls pc, [pc, r1, lsl #2] 2d38: ea00002e b 2df8 2d3c: 00002de4 .word 0x00002de4 <== NOT EXECUTED 2d40: 00002db8 .word 0x00002db8 <== NOT EXECUTED 2d44: 00002d54 .word 0x00002d54 <== NOT EXECUTED 2d48: 00002df8 .word 0x00002df8 <== NOT EXECUTED 2d4c: 00002df8 .word 0x00002df8 <== NOT EXECUTED 2d50: 00002d80 .word 0x00002d80 <== NOT EXECUTED case '\n': if (tty->termios.c_oflag & ONLRET) 2d54: e3130020 tst r3, #32 tty->column = 0; 2d58: 13a03000 movne r3, #0 2d5c: 15843028 strne r3, [r4, #40] ; 0x28 if (tty->termios.c_oflag & ONLCR) { 2d60: e5943034 ldr r3, [r4, #52] ; 0x34 2d64: e3130004 tst r3, #4 2d68: 0a000036 beq 2e48 rtems_termios_puts ("\r", 1, tty); 2d6c: e59f00e8 ldr r0, [pc, #232] ; 2e5c 2d70: e3a01001 mov r1, #1 2d74: e1a02004 mov r2, r4 2d78: ebffffa0 bl 2c00 2d7c: ea00000b b 2db0 tty->column = 0; } break; case '\r': if ((tty->termios.c_oflag & ONOCR) && (tty->column == 0)) 2d80: e3130010 tst r3, #16 <== NOT EXECUTED 2d84: 0a000002 beq 2d94 <== NOT EXECUTED 2d88: e5942028 ldr r2, [r4, #40] ; 0x28 <== NOT EXECUTED 2d8c: e3520000 cmp r2, #0 <== NOT EXECUTED 2d90: 0a000030 beq 2e58 <== NOT EXECUTED return; if (tty->termios.c_oflag & OCRNL) { 2d94: e2132008 ands r2, r3, #8 <== NOT EXECUTED c = '\n'; if (tty->termios.c_oflag & ONLRET) tty->column = 0; break; } tty->column = 0; 2d98: 05842028 streq r2, [r4, #40] ; 0x28 <== NOT EXECUTED break; case '\r': if ((tty->termios.c_oflag & ONOCR) && (tty->column == 0)) return; if (tty->termios.c_oflag & OCRNL) { 2d9c: 0a000029 beq 2e48 <== NOT EXECUTED c = '\n'; if (tty->termios.c_oflag & ONLRET) 2da0: e3130020 tst r3, #32 <== NOT EXECUTED case '\r': if ((tty->termios.c_oflag & ONOCR) && (tty->column == 0)) return; if (tty->termios.c_oflag & OCRNL) { c = '\n'; 2da4: e3a0300a mov r3, #10 <== NOT EXECUTED 2da8: e5cd3000 strb r3, [sp] <== NOT EXECUTED if (tty->termios.c_oflag & ONLRET) 2dac: 0a000025 beq 2e48 <== NOT EXECUTED tty->column = 0; 2db0: e3a03000 mov r3, #0 2db4: ea000022 b 2e44 } tty->column = 0; break; case '\t': i = 8 - (tty->column & 7); 2db8: e5942028 ldr r2, [r4, #40] ; 0x28 if ((tty->termios.c_oflag & TABDLY) == XTABS) { 2dbc: e2033b06 and r3, r3, #6144 ; 0x1800 } tty->column = 0; break; case '\t': i = 8 - (tty->column & 7); 2dc0: e2021007 and r1, r2, #7 if ((tty->termios.c_oflag & TABDLY) == XTABS) { 2dc4: e3530b06 cmp r3, #6144 ; 0x1800 } tty->column = 0; break; case '\t': i = 8 - (tty->column & 7); 2dc8: e2611008 rsb r1, r1, #8 2dcc: e0813002 add r3, r1, r2 if ((tty->termios.c_oflag & TABDLY) == XTABS) { 2dd0: 1a00001b bne 2e44 tty->column += i; 2dd4: e5843028 str r3, [r4, #40] ; 0x28 rtems_termios_puts ( " ", i, tty); 2dd8: e1a02004 mov r2, r4 2ddc: e59f007c ldr r0, [pc, #124] ; 2e60 2de0: ea00001b b 2e54 } tty->column += i; break; case '\b': if (tty->column > 0) 2de4: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 2de8: e3530000 cmp r3, #0 <== NOT EXECUTED tty->column--; 2dec: c2433001 subgt r3, r3, #1 <== NOT EXECUTED } tty->column += i; break; case '\b': if (tty->column > 0) 2df0: ca000013 bgt 2e44 <== NOT EXECUTED 2df4: ea000013 b 2e48 <== NOT EXECUTED tty->column--; break; default: if (tty->termios.c_oflag & OLCUC) 2df8: e3130002 tst r3, #2 2dfc: 0a000007 beq 2e20 c = toupper(c); 2e00: e59f305c ldr r3, [pc, #92] ; 2e64 <== NOT EXECUTED 2e04: e5933000 ldr r3, [r3] <== NOT EXECUTED 2e08: e0833002 add r3, r3, r2 <== NOT EXECUTED 2e0c: e5d33001 ldrb r3, [r3, #1] <== NOT EXECUTED 2e10: e2033003 and r3, r3, #3 <== NOT EXECUTED 2e14: e3530002 cmp r3, #2 <== NOT EXECUTED 2e18: 02422020 subeq r2, r2, #32 <== NOT EXECUTED 2e1c: e5cd2000 strb r2, [sp] <== NOT EXECUTED if (!iscntrl(c)) 2e20: e59f303c ldr r3, [pc, #60] ; 2e64 2e24: e5932000 ldr r2, [r3] 2e28: e5dd3000 ldrb r3, [sp] 2e2c: e0823003 add r3, r2, r3 2e30: e5d33001 ldrb r3, [r3, #1] 2e34: e3130020 tst r3, #32 2e38: 1a000002 bne 2e48 tty->column++; 2e3c: e5943028 ldr r3, [r4, #40] ; 0x28 2e40: e2833001 add r3, r3, #1 2e44: e5843028 str r3, [r4, #40] ; 0x28 break; } } rtems_termios_puts (&c, 1, tty); 2e48: e1a02004 mov r2, r4 2e4c: e1a0000d mov r0, sp 2e50: e3a01001 mov r1, #1 2e54: ebffff69 bl 2c00 } 2e58: e8bd8018 pop {r3, r4, pc} 2e5c: 0001862b .word 0x0001862b 2e60: 000184fc .word 0x000184fc 2e64: 0001777c .word 0x0001777c 0000b674 : * Called by pipe() to create an anonymous pipe. */ int pipe_create( int filsdes[2] ) { b674: e92d4070 push {r4, r5, r6, lr} b678: e24dd028 sub sp, sp, #40 ; 0x28 rtems_filesystem_location_info_t loc; rtems_libio_t *iop; int err = 0; /* Create /tmp if not exists */ if (rtems_filesystem_evaluate_path("/tmp", 3, RTEMS_LIBIO_PERMS_RWX, &loc, TRUE) b67c: e28d5004 add r5, sp, #4 b680: e3a0c001 mov ip, #1 * Called by pipe() to create an anonymous pipe. */ int pipe_create( int filsdes[2] ) { b684: e1a04000 mov r4, r0 rtems_filesystem_location_info_t loc; rtems_libio_t *iop; int err = 0; /* Create /tmp if not exists */ if (rtems_filesystem_evaluate_path("/tmp", 3, RTEMS_LIBIO_PERMS_RWX, &loc, TRUE) b688: e3a01003 mov r1, #3 b68c: e59f0140 ldr r0, [pc, #320] ; b7d4 b690: e3a02007 mov r2, #7 b694: e1a03005 mov r3, r5 b698: e58dc000 str ip, [sp] b69c: ebffd876 bl 187c b6a0: e3500000 cmp r0, #0 b6a4: 0a000009 beq b6d0 != 0) { if (errno != ENOENT) b6a8: eb000128 bl bb50 <__errno> b6ac: e5903000 ldr r3, [r0] b6b0: e3530002 cmp r3, #2 b6b4: 1a000043 bne b7c8 return -1; if (mkdir("/tmp", S_IRWXU|S_IRWXG|S_IRWXO|S_ISVTX) != 0) b6b8: e59f0114 ldr r0, [pc, #276] ; b7d4 b6bc: e59f1114 ldr r1, [pc, #276] ; b7d8 b6c0: ebffd990 bl 1d08 b6c4: e3500000 cmp r0, #0 b6c8: 0a000008 beq b6f0 b6cc: ea00003d b b7c8 <== NOT EXECUTED return -1; } else rtems_filesystem_freenode(&loc); b6d0: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED b6d4: e3530000 cmp r3, #0 <== NOT EXECUTED b6d8: 0a000004 beq b6f0 <== NOT EXECUTED b6dc: e593301c ldr r3, [r3, #28] <== NOT EXECUTED b6e0: e3530000 cmp r3, #0 <== NOT EXECUTED b6e4: 11a00005 movne r0, r5 <== NOT EXECUTED b6e8: 11a0e00f movne lr, pc <== NOT EXECUTED b6ec: 112fff13 bxne r3 <== NOT EXECUTED /* /tmp/.fifoXXXX */ char fifopath[15]; memcpy(fifopath, "/tmp/.fifo", 10); b6f0: e28d5018 add r5, sp, #24 b6f4: e59f10e0 ldr r1, [pc, #224] ; b7dc b6f8: e3a0200a mov r2, #10 b6fc: e1a00005 mov r0, r5 b700: eb000320 bl c388 sprintf(fifopath + 10, "%04x", rtems_pipe_no ++); b704: e59f30d4 ldr r3, [pc, #212] ; b7e0 b708: e1d3c0b0 ldrh ip, [r3] b70c: e1a0200c mov r2, ip b710: e28cc001 add ip, ip, #1 b714: e59f10c8 ldr r1, [pc, #200] ; b7e4 b718: e1c3c0b0 strh ip, [r3] b71c: e285000a add r0, r5, #10 b720: eb0003be bl c620 /* Try creating FIFO file until find an available file name */ while (mkfifo(fifopath, S_IRUSR|S_IWUSR) != 0) { b724: e1a00005 mov r0, r5 b728: e3a01d06 mov r1, #384 ; 0x180 b72c: eb00003f bl b830 b730: e2506000 subs r6, r0, #0 b734: 0a000001 beq b740 if (errno != EEXIST){ b738: eb000104 bl bb50 <__errno> <== NOT EXECUTED b73c: ea000021 b b7c8 <== NOT EXECUTED return -1; sprintf(fifopath + 10, "%04x", rtems_pipe_no ++); } /* Non-blocking open to avoid waiting for writers */ filsdes[0] = open(fifopath, O_RDONLY | O_NONBLOCK); b740: e1a00005 mov r0, r5 b744: e3a01901 mov r1, #16384 ; 0x4000 b748: ebffdb26 bl 23e8 if (filsdes[0] < 0) { b74c: e3500000 cmp r0, #0 return -1; sprintf(fifopath + 10, "%04x", rtems_pipe_no ++); } /* Non-blocking open to avoid waiting for writers */ filsdes[0] = open(fifopath, O_RDONLY | O_NONBLOCK); b750: e5840000 str r0, [r4] if (filsdes[0] < 0) { b754: aa000003 bge b768 err = errno; b758: eb0000fc bl bb50 <__errno> b75c: e5906000 ldr r6, [r0] /* Delete file at errors, or else if pipe is successfully created the file node will be deleted after it is closed by all. */ unlink(fifopath); b760: e1a00005 mov r0, r5 b764: ea000014 b b7bc } else { /* Reset open file to blocking mode */ iop = rtems_libio_iop(filsdes[0]); b768: e59f3078 ldr r3, [pc, #120] ; b7e8 <== NOT EXECUTED b76c: e5933000 ldr r3, [r3] <== NOT EXECUTED b770: e1500003 cmp r0, r3 <== NOT EXECUTED b774: 359f3070 ldrcc r3, [pc, #112] ; b7ec <== NOT EXECUTED b778: 35936000 ldrcc r6, [r3] <== NOT EXECUTED b77c: 30866300 addcc r6, r6, r0, lsl #6 <== NOT EXECUTED iop->flags &= ~LIBIO_FLAGS_NO_DELAY; b780: e5963014 ldr r3, [r6, #20] <== NOT EXECUTED b784: e3c33001 bic r3, r3, #1 <== NOT EXECUTED b788: e5863014 str r3, [r6, #20] <== NOT EXECUTED filsdes[1] = open(fifopath, O_WRONLY); b78c: e28d0018 add r0, sp, #24 <== NOT EXECUTED b790: e3a01001 mov r1, #1 <== NOT EXECUTED b794: ebffdb13 bl 23e8 <== NOT EXECUTED if (filsdes[1] < 0) { b798: e3500000 cmp r0, #0 <== NOT EXECUTED else { /* Reset open file to blocking mode */ iop = rtems_libio_iop(filsdes[0]); iop->flags &= ~LIBIO_FLAGS_NO_DELAY; filsdes[1] = open(fifopath, O_WRONLY); b79c: e5840004 str r0, [r4, #4] <== NOT EXECUTED if (filsdes[1] < 0) { b7a0: a3a06000 movge r6, #0 <== NOT EXECUTED b7a4: aa000003 bge b7b8 <== NOT EXECUTED err = errno; b7a8: eb0000e8 bl bb50 <__errno> <== NOT EXECUTED b7ac: e5906000 ldr r6, [r0] <== NOT EXECUTED close(filsdes[0]); b7b0: e5940000 ldr r0, [r4] <== NOT EXECUTED b7b4: ebfff5c7 bl 8ed8 <== NOT EXECUTED } unlink(fifopath); b7b8: e28d0018 add r0, sp, #24 <== NOT EXECUTED b7bc: eb00001f bl b840 } rtems_set_errno_and_return_minus_one(err); b7c0: eb0000e2 bl bb50 <__errno> b7c4: e5806000 str r6, [r0] } b7c8: e3e00000 mvn r0, #0 b7cc: e28dd028 add sp, sp, #40 ; 0x28 b7d0: e8bd8070 pop {r4, r5, r6, pc} b7d4: 0001873c .word 0x0001873c b7d8: 000003ff .word 0x000003ff b7dc: 00018741 .word 0x00018741 b7e0: 00018ad2 .word 0x00018ad2 b7e4: 0001874c .word 0x0001874c b7e8: 00017580 .word 0x00017580 b7ec: 00018cb0 .word 0x00018cb0 0000a834 : /* Called with rtems_pipe_semaphore held. */ static inline void pipe_free( pipe_control_t *pipe ) { a834: e92d4010 push {r4, lr} <== NOT EXECUTED a838: e1a04000 mov r4, r0 <== NOT EXECUTED rtems_barrier_delete(pipe->readBarrier); a83c: e590002c ldr r0, [r0, #44] ; 0x2c <== NOT EXECUTED a840: eb000202 bl b050 <== NOT EXECUTED rtems_barrier_delete(pipe->writeBarrier); a844: e5940030 ldr r0, [r4, #48] ; 0x30 <== NOT EXECUTED a848: eb000200 bl b050 <== NOT EXECUTED rtems_semaphore_delete(pipe->Semaphore); a84c: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED a850: ebffe85d bl 49cc <== NOT EXECUTED free(pipe->Buffer); a854: e5940000 ldr r0, [r4] <== NOT EXECUTED a858: ebffdc3a bl 1948 <== NOT EXECUTED free(pipe); a85c: e1a00004 mov r0, r4 <== NOT EXECUTED } a860: e8bd4010 pop {r4, lr} <== NOT EXECUTED { rtems_barrier_delete(pipe->readBarrier); rtems_barrier_delete(pipe->writeBarrier); rtems_semaphore_delete(pipe->Semaphore); free(pipe->Buffer); free(pipe); a864: eaffdc37 b 1948 <== NOT EXECUTED 0000a4d4 : uint32_t cmd, void *buffer, rtems_libio_t *iop ) { if (cmd == FIONREAD) { a4d4: e59f3054 ldr r3, [pc, #84] ; a530 <== NOT EXECUTED a4d8: e1510003 cmp r1, r3 <== NOT EXECUTED pipe_control_t *pipe, uint32_t cmd, void *buffer, rtems_libio_t *iop ) { a4dc: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED a4e0: e1a04000 mov r4, r0 <== NOT EXECUTED a4e4: e1a05002 mov r5, r2 <== NOT EXECUTED if (cmd == FIONREAD) { a4e8: 13e00015 mvnne r0, #21 <== NOT EXECUTED a4ec: 18bd8070 popne {r4, r5, r6, pc} <== NOT EXECUTED if (buffer == NULL) a4f0: e3520000 cmp r2, #0 <== NOT EXECUTED a4f4: 03e0000d mvneq r0, #13 <== NOT EXECUTED a4f8: 08bd8070 popeq {r4, r5, r6, pc} <== NOT EXECUTED return -EFAULT; if (! PIPE_LOCK(pipe)) a4fc: e3a01000 mov r1, #0 <== NOT EXECUTED a500: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED a504: e1a02001 mov r2, r1 <== NOT EXECUTED a508: ebffe956 bl 4a68 <== NOT EXECUTED a50c: e2506000 subs r6, r0, #0 <== NOT EXECUTED a510: 13e00003 mvnne r0, #3 <== NOT EXECUTED a514: 18bd8070 popne {r4, r5, r6, pc} <== NOT EXECUTED return -EINTR; /* Return length of pipe */ *(uint *)buffer = pipe->Length; a518: e594300c ldr r3, [r4, #12] <== NOT EXECUTED PIPE_UNLOCK(pipe); a51c: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED if (! PIPE_LOCK(pipe)) return -EINTR; /* Return length of pipe */ *(uint *)buffer = pipe->Length; a520: e5853000 str r3, [r5] <== NOT EXECUTED PIPE_UNLOCK(pipe); a524: ebffe995 bl 4b80 <== NOT EXECUTED a528: e1a00006 mov r0, r6 <== NOT EXECUTED return 0; } return -EINVAL; } a52c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED a530: 4004667f .word 0x4004667f 0000a46c : rtems_libio_t *iop ) { /* Seek on pipe is not supported */ return -ESPIPE; } a46c: e3e0001c mvn r0, #28 <== NOT EXECUTED a470: e12fff1e bx lr <== NOT EXECUTED 0000a6c4 : pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) { a6c4: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} <== NOT EXECUTED a6c8: e1a09001 mov r9, r1 <== NOT EXECUTED int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe)) a6cc: e3a01000 mov r1, #0 <== NOT EXECUTED pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) { a6d0: e1a04000 mov r4, r0 <== NOT EXECUTED a6d4: e1a05002 mov r5, r2 <== NOT EXECUTED int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe)) a6d8: e5900028 ldr r0, [r0, #40] ; 0x28 <== NOT EXECUTED a6dc: e1a02001 mov r2, r1 <== NOT EXECUTED pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) { a6e0: e1a0a003 mov sl, r3 <== NOT EXECUTED int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe)) a6e4: ebffe8df bl 4a68 <== NOT EXECUTED a6e8: e2506000 subs r6, r0, #0 <== NOT EXECUTED a6ec: 13e06003 mvnne r6, #3 <== NOT EXECUTED /* For buffering optimization */ if (PIPE_EMPTY(pipe)) pipe->Start = 0; if (pipe->waitingWriters > 0) PIPE_WAKEUPWRITERS(pipe); a6f0: 01a0b00d moveq fp, sp <== NOT EXECUTED rtems_libio_t *iop ) { int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe)) a6f4: 0a000045 beq a810 <== NOT EXECUTED a6f8: ea00004b b a82c <== NOT EXECUTED return -EINTR; while (read < count) { while (PIPE_EMPTY(pipe)) { /* Not an error */ if (pipe->Writers == 0) a6fc: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED a700: e3530000 cmp r3, #0 <== NOT EXECUTED a704: 0a000043 beq a818 <== NOT EXECUTED goto out_locked; if (LIBIO_NODELAY(iop)) { a708: e59a7014 ldr r7, [sl, #20] <== NOT EXECUTED a70c: e2177001 ands r7, r7, #1 <== NOT EXECUTED a710: 13e0700a mvnne r7, #10 <== NOT EXECUTED a714: 1a000040 bne a81c <== NOT EXECUTED ret = -EAGAIN; goto out_locked; } /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++; a718: e5943018 ldr r3, [r4, #24] <== NOT EXECUTED a71c: e2833001 add r3, r3, #1 <== NOT EXECUTED a720: e5843018 str r3, [r4, #24] <== NOT EXECUTED PIPE_UNLOCK(pipe); a724: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED a728: ebffe914 bl 4b80 <== NOT EXECUTED if (! PIPE_READWAIT(pipe)) a72c: e1a01007 mov r1, r7 <== NOT EXECUTED a730: e594002c ldr r0, [r4, #44] ; 0x2c <== NOT EXECUTED a734: eb000273 bl b108 <== NOT EXECUTED ret = -EINTR; if (! PIPE_LOCK(pipe)) { a738: e1a01007 mov r1, r7 <== NOT EXECUTED a73c: e1a02001 mov r2, r1 <== NOT EXECUTED } /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++; PIPE_UNLOCK(pipe); if (! PIPE_READWAIT(pipe)) a740: e2507000 subs r7, r0, #0 <== NOT EXECUTED ret = -EINTR; if (! PIPE_LOCK(pipe)) { a744: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED } /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++; PIPE_UNLOCK(pipe); if (! PIPE_READWAIT(pipe)) a748: 13e07003 mvnne r7, #3 <== NOT EXECUTED ret = -EINTR; if (! PIPE_LOCK(pipe)) { a74c: ebffe8c5 bl 4a68 <== NOT EXECUTED a750: e3500000 cmp r0, #0 <== NOT EXECUTED a754: 13e07003 mvnne r7, #3 <== NOT EXECUTED a758: 1a000031 bne a824 <== NOT EXECUTED /* WARN waitingReaders not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingReaders --; a75c: e5943018 ldr r3, [r4, #24] <== NOT EXECUTED if (ret != 0) a760: e3570000 cmp r7, #0 <== NOT EXECUTED if (! PIPE_LOCK(pipe)) { /* WARN waitingReaders not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingReaders --; a764: e2433001 sub r3, r3, #1 <== NOT EXECUTED a768: e5843018 str r3, [r4, #24] <== NOT EXECUTED if (ret != 0) a76c: 1a00002a bne a81c <== NOT EXECUTED if (! PIPE_LOCK(pipe)) return -EINTR; while (read < count) { while (PIPE_EMPTY(pipe)) { a770: e594200c ldr r2, [r4, #12] <== NOT EXECUTED a774: e3520000 cmp r2, #0 <== NOT EXECUTED a778: 0affffdf beq a6fc <== NOT EXECUTED goto out_locked; } /* Read chunk bytes */ chunk = MIN(count - read, pipe->Length); chunk1 = pipe->Size - pipe->Start; a77c: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED a780: e5948004 ldr r8, [r4, #4] <== NOT EXECUTED if (ret != 0) goto out_locked; } /* Read chunk bytes */ chunk = MIN(count - read, pipe->Length); a784: e0667005 rsb r7, r6, r5 <== NOT EXECUTED a788: e1520007 cmp r2, r7 <== NOT EXECUTED a78c: 31a07002 movcc r7, r2 <== NOT EXECUTED chunk1 = pipe->Size - pipe->Start; a790: e0638008 rsb r8, r3, r8 <== NOT EXECUTED a794: e5941000 ldr r1, [r4] <== NOT EXECUTED if (chunk > chunk1) { a798: e1570008 cmp r7, r8 <== NOT EXECUTED a79c: e0890006 add r0, r9, r6 <== NOT EXECUTED memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk1); memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1); } else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk); a7a0: d0811003 addle r1, r1, r3 <== NOT EXECUTED a7a4: d1a02007 movle r2, r7 <== NOT EXECUTED } /* Read chunk bytes */ chunk = MIN(count - read, pipe->Length); chunk1 = pipe->Size - pipe->Start; if (chunk > chunk1) { a7a8: da000006 ble a7c8 <== NOT EXECUTED memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk1); a7ac: e0811003 add r1, r1, r3 <== NOT EXECUTED a7b0: e1a02008 mov r2, r8 <== NOT EXECUTED a7b4: eb0006f3 bl c388 <== NOT EXECUTED memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1); a7b8: e0860008 add r0, r6, r8 <== NOT EXECUTED a7bc: e5941000 ldr r1, [r4] <== NOT EXECUTED a7c0: e0890000 add r0, r9, r0 <== NOT EXECUTED a7c4: e0682007 rsb r2, r8, r7 <== NOT EXECUTED } else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk); a7c8: eb0006ee bl c388 <== NOT EXECUTED pipe->Start += chunk; a7cc: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED a7d0: e0870000 add r0, r7, r0 <== NOT EXECUTED a7d4: e5840008 str r0, [r4, #8] <== NOT EXECUTED pipe->Start %= pipe->Size; a7d8: e5941004 ldr r1, [r4, #4] <== NOT EXECUTED a7dc: eb002ae2 bl 1536c <__umodsi3> <== NOT EXECUTED pipe->Length -= chunk; a7e0: e594300c ldr r3, [r4, #12] <== NOT EXECUTED a7e4: e0673003 rsb r3, r7, r3 <== NOT EXECUTED /* For buffering optimization */ if (PIPE_EMPTY(pipe)) a7e8: e3530000 cmp r3, #0 <== NOT EXECUTED } else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk); pipe->Start += chunk; pipe->Start %= pipe->Size; a7ec: e5840008 str r0, [r4, #8] <== NOT EXECUTED pipe->Length -= chunk; a7f0: e584300c str r3, [r4, #12] <== NOT EXECUTED /* For buffering optimization */ if (PIPE_EMPTY(pipe)) pipe->Start = 0; a7f4: 05843008 streq r3, [r4, #8] <== NOT EXECUTED if (pipe->waitingWriters > 0) a7f8: e594301c ldr r3, [r4, #28] <== NOT EXECUTED a7fc: e3530000 cmp r3, #0 <== NOT EXECUTED PIPE_WAKEUPWRITERS(pipe); a800: 15940030 ldrne r0, [r4, #48] ; 0x30 <== NOT EXECUTED a804: 11a0100d movne r1, sp <== NOT EXECUTED a808: 1b000228 blne b0b0 <== NOT EXECUTED read += chunk; a80c: e0866007 add r6, r6, r7 <== NOT EXECUTED int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe)) return -EINTR; while (read < count) { a810: e1560005 cmp r6, r5 <== NOT EXECUTED a814: 3affffd5 bcc a770 <== NOT EXECUTED a818: e3a07000 mov r7, #0 <== NOT EXECUTED PIPE_WAKEUPWRITERS(pipe); read += chunk; } out_locked: PIPE_UNLOCK(pipe); a81c: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED a820: ebffe8d6 bl 4b80 <== NOT EXECUTED out_nolock: if (read > 0) a824: e3560000 cmp r6, #0 <== NOT EXECUTED a828: d1a06007 movle r6, r7 <== NOT EXECUTED return read; return ret; } a82c: e1a00006 mov r0, r6 <== NOT EXECUTED a830: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED 0000a868 : */ int pipe_release( pipe_control_t **pipep, rtems_libio_t *iop ) { a868: e92d40f1 push {r0, r4, r5, r6, r7, lr} <== NOT EXECUTED pipe_control_t *pipe = *pipep; a86c: e5904000 ldr r4, [r0] <== NOT EXECUTED */ int pipe_release( pipe_control_t **pipep, rtems_libio_t *iop ) { a870: e1a05001 mov r5, r1 <== NOT EXECUTED pipe_control_t *pipe = *pipep; uint32_t mode; rtems_status_code sc; sc = rtems_semaphore_obtain(pipe->Semaphore, a874: e3a01000 mov r1, #0 <== NOT EXECUTED */ int pipe_release( pipe_control_t **pipep, rtems_libio_t *iop ) { a878: e1a06000 mov r6, r0 <== NOT EXECUTED pipe_control_t *pipe = *pipep; uint32_t mode; rtems_status_code sc; sc = rtems_semaphore_obtain(pipe->Semaphore, a87c: e1a02001 mov r2, r1 <== NOT EXECUTED a880: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED a884: ebffe877 bl 4a68 <== NOT EXECUTED RTEMS_WAIT, RTEMS_NO_TIMEOUT); /* WARN pipe not released! */ if(sc != RTEMS_SUCCESSFUL) a888: e3500000 cmp r0, #0 <== NOT EXECUTED a88c: 1a000010 bne a8d4 <== NOT EXECUTED rtems_fatal_error_occurred(sc); mode = LIBIO_ACCMODE(iop); a890: e5955014 ldr r5, [r5, #20] <== NOT EXECUTED if (mode & LIBIO_FLAGS_READ) a894: e3150002 tst r5, #2 <== NOT EXECUTED pipe->Readers --; a898: 15943010 ldrne r3, [r4, #16] <== NOT EXECUTED RTEMS_WAIT, RTEMS_NO_TIMEOUT); /* WARN pipe not released! */ if(sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred(sc); mode = LIBIO_ACCMODE(iop); a89c: e2055006 and r5, r5, #6 <== NOT EXECUTED if (mode & LIBIO_FLAGS_READ) pipe->Readers --; a8a0: 12433001 subne r3, r3, #1 <== NOT EXECUTED a8a4: 15843010 strne r3, [r4, #16] <== NOT EXECUTED if (mode & LIBIO_FLAGS_WRITE) a8a8: e3150004 tst r5, #4 <== NOT EXECUTED pipe->Writers --; a8ac: 15943014 ldrne r3, [r4, #20] <== NOT EXECUTED a8b0: 12433001 subne r3, r3, #1 <== NOT EXECUTED a8b4: 15843014 strne r3, [r4, #20] <== NOT EXECUTED sc = rtems_semaphore_obtain(rtems_pipe_semaphore, a8b8: e59f30a0 ldr r3, [pc, #160] ; a960 <== NOT EXECUTED a8bc: e3a01000 mov r1, #0 <== NOT EXECUTED a8c0: e5930000 ldr r0, [r3] <== NOT EXECUTED a8c4: e1a02001 mov r2, r1 <== NOT EXECUTED a8c8: ebffe866 bl 4a68 <== NOT EXECUTED RTEMS_WAIT, RTEMS_NO_TIMEOUT); /* WARN pipe not freed and pipep not set to NULL! */ if(sc != RTEMS_SUCCESSFUL) a8cc: e3500000 cmp r0, #0 <== NOT EXECUTED a8d0: 0a000000 beq a8d8 <== NOT EXECUTED rtems_fatal_error_occurred(sc); a8d4: ebffe9f6 bl 50b4 <== NOT EXECUTED PIPE_UNLOCK(pipe); a8d8: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED a8dc: ebffe8a7 bl 4b80 <== NOT EXECUTED if (pipe->Readers == 0 && pipe->Writers == 0) { a8e0: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED a8e4: e3530000 cmp r3, #0 <== NOT EXECUTED a8e8: 1a000006 bne a908 <== NOT EXECUTED a8ec: e5947014 ldr r7, [r4, #20] <== NOT EXECUTED a8f0: e3570000 cmp r7, #0 <== NOT EXECUTED a8f4: 1a000003 bne a908 <== NOT EXECUTED #if 0 /* To delete an anonymous pipe file when all users closed it */ if (pipe->Anonymous) delfile = TRUE; #endif pipe_free(pipe); a8f8: e1a00004 mov r0, r4 <== NOT EXECUTED a8fc: ebffffcc bl a834 <== NOT EXECUTED *pipep = NULL; a900: e5867000 str r7, [r6] <== NOT EXECUTED if(sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred(sc); PIPE_UNLOCK(pipe); if (pipe->Readers == 0 && pipe->Writers == 0) { a904: ea000010 b a94c <== NOT EXECUTED delfile = TRUE; #endif pipe_free(pipe); *pipep = NULL; } else if (pipe->Readers == 0 && mode != LIBIO_FLAGS_WRITE) a908: e2552004 subs r2, r5, #4 <== NOT EXECUTED a90c: 13a02001 movne r2, #1 <== NOT EXECUTED a910: e3530000 cmp r3, #0 <== NOT EXECUTED a914: 13a02000 movne r2, #0 <== NOT EXECUTED a918: e3520000 cmp r2, #0 <== NOT EXECUTED /* Notify waiting Writers that all their partners left */ PIPE_WAKEUPWRITERS(pipe); a91c: 15940030 ldrne r0, [r4, #48] ; 0x30 <== NOT EXECUTED delfile = TRUE; #endif pipe_free(pipe); *pipep = NULL; } else if (pipe->Readers == 0 && mode != LIBIO_FLAGS_WRITE) a920: 1a000007 bne a944 <== NOT EXECUTED /* Notify waiting Writers that all their partners left */ PIPE_WAKEUPWRITERS(pipe); else if (pipe->Writers == 0 && mode != LIBIO_FLAGS_READ) a924: e5942014 ldr r2, [r4, #20] <== NOT EXECUTED a928: e2553002 subs r3, r5, #2 <== NOT EXECUTED a92c: 13a03001 movne r3, #1 <== NOT EXECUTED a930: e3520000 cmp r2, #0 <== NOT EXECUTED a934: 13a03000 movne r3, #0 <== NOT EXECUTED a938: e3530000 cmp r3, #0 <== NOT EXECUTED a93c: 0a000002 beq a94c <== NOT EXECUTED PIPE_WAKEUPREADERS(pipe); a940: e594002c ldr r0, [r4, #44] ; 0x2c <== NOT EXECUTED a944: e1a0100d mov r1, sp <== NOT EXECUTED a948: eb0001d8 bl b0b0 <== NOT EXECUTED rtems_semaphore_release(rtems_pipe_semaphore); a94c: e59f300c ldr r3, [pc, #12] ; a960 <== NOT EXECUTED a950: e5930000 ldr r0, [r3] <== NOT EXECUTED a954: ebffe889 bl 4b80 <== NOT EXECUTED if(iop->pathinfo.ops->unlink_h(&iop->pathinfo)) return -errno; #endif return 0; } a958: e3a00000 mov r0, #0 <== NOT EXECUTED a95c: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} <== NOT EXECUTED a960: 00018acc .word 0x00018acc 0000a534 : pipe_control_t *pipe, const void *buffer, size_t count, rtems_libio_t *iop ) { a534: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} <== NOT EXECUTED int chunk, chunk1, written = 0, ret = 0; /* Write nothing */ if (count == 0) a538: e2525000 subs r5, r2, #0 <== NOT EXECUTED pipe_control_t *pipe, const void *buffer, size_t count, rtems_libio_t *iop ) { a53c: e1a04000 mov r4, r0 <== NOT EXECUTED a540: e1a0b001 mov fp, r1 <== NOT EXECUTED a544: e1a08003 mov r8, r3 <== NOT EXECUTED int chunk, chunk1, written = 0, ret = 0; /* Write nothing */ if (count == 0) a548: 01a06005 moveq r6, r5 <== NOT EXECUTED a54c: 0a00005a beq a6bc <== NOT EXECUTED return 0; if (! PIPE_LOCK(pipe)) a550: e3a01000 mov r1, #0 <== NOT EXECUTED a554: e5900028 ldr r0, [r0, #40] ; 0x28 <== NOT EXECUTED a558: e1a02001 mov r2, r1 <== NOT EXECUTED a55c: ebffe941 bl 4a68 <== NOT EXECUTED a560: e3500000 cmp r0, #0 <== NOT EXECUTED a564: 13e06003 mvnne r6, #3 <== NOT EXECUTED a568: 1a000053 bne a6bc <== NOT EXECUTED return -EINTR; if (pipe->Readers == 0) { a56c: e5946010 ldr r6, [r4, #16] <== NOT EXECUTED a570: e3560000 cmp r6, #0 <== NOT EXECUTED a574: 0a000022 beq a604 <== NOT EXECUTED ret = -EPIPE; goto out_locked; } /* Write of PIPE_BUF bytes or less shall not be interleaved */ chunk = count <= pipe->Size ? count : 1; a578: e5949004 ldr r9, [r4, #4] <== NOT EXECUTED a57c: e1550009 cmp r5, r9 <== NOT EXECUTED a580: 91a09005 movls r9, r5 <== NOT EXECUTED a584: 83a09001 movhi r9, #1 <== NOT EXECUTED a588: e1a06000 mov r6, r0 <== NOT EXECUTED a58c: ea000043 b a6a0 <== NOT EXECUTED while (written < count) { while (PIPE_SPACE(pipe) < chunk) { if (LIBIO_NODELAY(iop)) { a590: e5987014 ldr r7, [r8, #20] <== NOT EXECUTED a594: e2177001 ands r7, r7, #1 <== NOT EXECUTED a598: 13e0700a mvnne r7, #10 <== NOT EXECUTED a59c: 1a000042 bne a6ac <== NOT EXECUTED ret = -EAGAIN; goto out_locked; } /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++; a5a0: e594301c ldr r3, [r4, #28] <== NOT EXECUTED a5a4: e2833001 add r3, r3, #1 <== NOT EXECUTED a5a8: e584301c str r3, [r4, #28] <== NOT EXECUTED PIPE_UNLOCK(pipe); a5ac: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED a5b0: ebffe972 bl 4b80 <== NOT EXECUTED if (! PIPE_WRITEWAIT(pipe)) a5b4: e1a01007 mov r1, r7 <== NOT EXECUTED a5b8: e5940030 ldr r0, [r4, #48] ; 0x30 <== NOT EXECUTED a5bc: eb0002d1 bl b108 <== NOT EXECUTED ret = -EINTR; if (! PIPE_LOCK(pipe)) { a5c0: e1a01007 mov r1, r7 <== NOT EXECUTED a5c4: e1a02001 mov r2, r1 <== NOT EXECUTED } /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++; PIPE_UNLOCK(pipe); if (! PIPE_WRITEWAIT(pipe)) a5c8: e2507000 subs r7, r0, #0 <== NOT EXECUTED ret = -EINTR; if (! PIPE_LOCK(pipe)) { a5cc: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED } /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++; PIPE_UNLOCK(pipe); if (! PIPE_WRITEWAIT(pipe)) a5d0: 13e07003 mvnne r7, #3 <== NOT EXECUTED ret = -EINTR; if (! PIPE_LOCK(pipe)) { a5d4: ebffe923 bl 4a68 <== NOT EXECUTED a5d8: e3500000 cmp r0, #0 <== NOT EXECUTED a5dc: 13e07003 mvnne r7, #3 <== NOT EXECUTED a5e0: 1a000033 bne a6b4 <== NOT EXECUTED /* WARN waitingWriters not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingWriters --; a5e4: e594301c ldr r3, [r4, #28] <== NOT EXECUTED if (ret != 0) a5e8: e3570000 cmp r7, #0 <== NOT EXECUTED if (! PIPE_LOCK(pipe)) { /* WARN waitingWriters not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingWriters --; a5ec: e2433001 sub r3, r3, #1 <== NOT EXECUTED a5f0: e584301c str r3, [r4, #28] <== NOT EXECUTED if (ret != 0) a5f4: 1a00002c bne a6ac <== NOT EXECUTED goto out_locked; if (pipe->Readers == 0) { a5f8: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED a5fc: e3530000 cmp r3, #0 <== NOT EXECUTED a600: 1a000001 bne a60c <== NOT EXECUTED a604: e3e0701f mvn r7, #31 <== NOT EXECUTED a608: ea000027 b a6ac <== NOT EXECUTED /* Write of PIPE_BUF bytes or less shall not be interleaved */ chunk = count <= pipe->Size ? count : 1; while (written < count) { while (PIPE_SPACE(pipe) < chunk) { a60c: e594a004 ldr sl, [r4, #4] <== NOT EXECUTED a610: e594200c ldr r2, [r4, #12] <== NOT EXECUTED a614: e062300a rsb r3, r2, sl <== NOT EXECUTED a618: e1530009 cmp r3, r9 <== NOT EXECUTED a61c: 3affffdb bcc a590 <== NOT EXECUTED goto out_locked; } } chunk = MIN(count - written, PIPE_SPACE(pipe)); chunk1 = pipe->Size - PIPE_WSTART(pipe); a620: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED a624: e1a0100a mov r1, sl <== NOT EXECUTED a628: e0820000 add r0, r2, r0 <== NOT EXECUTED ret = -EPIPE; goto out_locked; } } chunk = MIN(count - written, PIPE_SPACE(pipe)); a62c: e0667005 rsb r7, r6, r5 <== NOT EXECUTED a630: e1530007 cmp r3, r7 <== NOT EXECUTED a634: 31a07003 movcc r7, r3 <== NOT EXECUTED chunk1 = pipe->Size - PIPE_WSTART(pipe); a638: eb002b4b bl 1536c <__umodsi3> <== NOT EXECUTED a63c: e5943000 ldr r3, [r4] <== NOT EXECUTED a640: e060a00a rsb sl, r0, sl <== NOT EXECUTED if (chunk > chunk1) { a644: e157000a cmp r7, sl <== NOT EXECUTED a648: e08b1006 add r1, fp, r6 <== NOT EXECUTED memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk1); memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1); } else memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk); a64c: d0830000 addle r0, r3, r0 <== NOT EXECUTED a650: d1a02007 movle r2, r7 <== NOT EXECUTED } } chunk = MIN(count - written, PIPE_SPACE(pipe)); chunk1 = pipe->Size - PIPE_WSTART(pipe); if (chunk > chunk1) { a654: da000006 ble a674 <== NOT EXECUTED memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk1); a658: e1a0200a mov r2, sl <== NOT EXECUTED a65c: e0830000 add r0, r3, r0 <== NOT EXECUTED a660: eb000748 bl c388 <== NOT EXECUTED memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1); a664: e08a1006 add r1, sl, r6 <== NOT EXECUTED a668: e5940000 ldr r0, [r4] <== NOT EXECUTED a66c: e08b1001 add r1, fp, r1 <== NOT EXECUTED a670: e06a2007 rsb r2, sl, r7 <== NOT EXECUTED } else memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk); a674: eb000743 bl c388 <== NOT EXECUTED pipe->Length += chunk; a678: e594300c ldr r3, [r4, #12] <== NOT EXECUTED if (pipe->waitingReaders > 0) a67c: e5942018 ldr r2, [r4, #24] <== NOT EXECUTED memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1); } else memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk); pipe->Length += chunk; a680: e0833007 add r3, r3, r7 <== NOT EXECUTED if (pipe->waitingReaders > 0) a684: e3520000 cmp r2, #0 <== NOT EXECUTED memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1); } else memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk); pipe->Length += chunk; a688: e584300c str r3, [r4, #12] <== NOT EXECUTED if (pipe->waitingReaders > 0) PIPE_WAKEUPREADERS(pipe); a68c: 1594002c ldrne r0, [r4, #44] ; 0x2c <== NOT EXECUTED a690: 11a0100d movne r1, sp <== NOT EXECUTED a694: 1b000285 blne b0b0 <== NOT EXECUTED written += chunk; a698: e0866007 add r6, r6, r7 <== NOT EXECUTED a69c: e3a09001 mov r9, #1 <== NOT EXECUTED } /* Write of PIPE_BUF bytes or less shall not be interleaved */ chunk = count <= pipe->Size ? count : 1; while (written < count) { a6a0: e1560005 cmp r6, r5 <== NOT EXECUTED a6a4: 3affffd8 bcc a60c <== NOT EXECUTED a6a8: e3a07000 mov r7, #0 <== NOT EXECUTED /* Write of more than PIPE_BUF bytes can be interleaved */ chunk = 1; } out_locked: PIPE_UNLOCK(pipe); a6ac: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED a6b0: ebffe932 bl 4b80 <== NOT EXECUTED /* Signal SIGPIPE */ if (ret == -EPIPE) kill(getpid(), SIGPIPE); #endif if (written > 0) a6b4: e3560000 cmp r6, #0 <== NOT EXECUTED a6b8: d1a06007 movle r6, r7 <== NOT EXECUTED return written; return ret; } a6bc: e1a00006 mov r0, r6 <== NOT EXECUTED a6c0: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED 00016cb8 : ) { ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd ); 16cb8: e59f30b0 ldr r3, [pc, #176] ; 16d70 16cbc: e5933000 ldr r3, [r3] 16cc0: e1500003 cmp r0, r3 ssize_t read( int fd, void *buffer, size_t count ) { 16cc4: e92d4070 push {r4, r5, r6, lr} 16cc8: e1a05001 mov r5, r1 ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd ); 16ccc: 2a000005 bcs 16ce8 iop = rtems_libio_iop( fd ); 16cd0: e59f309c ldr r3, [pc, #156] ; 16d74 16cd4: e5934000 ldr r4, [r3] 16cd8: e0844300 add r4, r4, r0, lsl #6 rtems_libio_check_is_open( iop ); 16cdc: e5943014 ldr r3, [r4, #20] 16ce0: e3130c01 tst r3, #256 ; 0x100 16ce4: 1a000002 bne 16cf4 16ce8: ebffd398 bl bb50 <__errno> 16cec: e3a03009 mov r3, #9 16cf0: ea00000f b 16d34 rtems_libio_check_buffer( buffer ); 16cf4: e3510000 cmp r1, #0 16cf8: 0a000004 beq 16d10 rtems_libio_check_count( count ); 16cfc: e3520000 cmp r2, #0 16d00: 01a00002 moveq r0, r2 16d04: 08bd8070 popeq {r4, r5, r6, pc} rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ ); 16d08: e3130002 tst r3, #2 16d0c: 1a000002 bne 16d1c 16d10: ebffd38e bl bb50 <__errno> <== NOT EXECUTED 16d14: e3a03016 mov r3, #22 <== NOT EXECUTED 16d18: ea000005 b 16d34 <== NOT EXECUTED /* * Now process the read(). */ if ( !iop->handlers->read_h ) 16d1c: e594303c ldr r3, [r4, #60] ; 0x3c 16d20: e5933008 ldr r3, [r3, #8] 16d24: e3530000 cmp r3, #0 16d28: 1a000004 bne 16d40 rtems_set_errno_and_return_minus_one( ENOTSUP ); 16d2c: ebffd387 bl bb50 <__errno> <== NOT EXECUTED 16d30: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 16d34: e5803000 str r3, [r0] 16d38: e3e00000 mvn r0, #0 16d3c: e8bd8070 pop {r4, r5, r6, pc} rc = (*iop->handlers->read_h)( iop, buffer, count ); 16d40: e1a00004 mov r0, r4 16d44: e1a0e00f mov lr, pc 16d48: e12fff13 bx r3 if ( rc > 0 ) 16d4c: e3500000 cmp r0, #0 16d50: d8bd8070 pople {r4, r5, r6, pc} iop->offset += rc; 16d54: e284600c add r6, r4, #12 16d58: e8960060 ldm r6, {r5, r6} 16d5c: e0952000 adds r2, r5, r0 16d60: e0a63fc0 adc r3, r6, r0, asr #31 16d64: e584200c str r2, [r4, #12] 16d68: e5843010 str r3, [r4, #16] return rc; } 16d6c: e8bd8070 pop {r4, r5, r6, pc} 16d70: 00017580 .word 0x00017580 16d74: 00018cb0 .word 0x00018cb0 000232f8 : ssize_t readlink( const char *pathname, char *buf, size_t bufsize ) { 232f8: e92d40f0 push {r4, r5, r6, r7, lr} rtems_filesystem_location_info_t loc; int result; if (!buf) 232fc: e2516000 subs r6, r1, #0 ssize_t readlink( const char *pathname, char *buf, size_t bufsize ) { 23300: e24dd018 sub sp, sp, #24 23304: e1a05002 mov r5, r2 23308: e1a07000 mov r7, r0 rtems_filesystem_location_info_t loc; int result; if (!buf) 2330c: 1a000002 bne 2331c rtems_set_errno_and_return_minus_one( EFAULT ); 23310: eb0053a8 bl 381b8 <__errno> <== NOT EXECUTED 23314: e3a0300e mov r3, #14 <== NOT EXECUTED 23318: ea000028 b 233c0 <== NOT EXECUTED result = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), 2331c: eb006e1f bl 3eba0 23320: e28d4004 add r4, sp, #4 23324: e3a0c000 mov ip, #0 23328: e1a01000 mov r1, r0 2332c: e1a0200c mov r2, ip 23330: e1a00007 mov r0, r7 23334: e1a03004 mov r3, r4 23338: e58dc000 str ip, [sp] 2333c: ebff8509 bl 4768 0, &loc, false ); if ( result != 0 ) 23340: e3500000 cmp r0, #0 23344: 1a00001e bne 233c4 return -1; if ( !loc.ops->node_type_h ){ 23348: e59d2010 ldr r2, [sp, #16] 2334c: e5923010 ldr r3, [r2, #16] 23350: e3530000 cmp r3, #0 23354: 0a000012 beq 233a4 rtems_filesystem_freenode( &loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_SYM_LINK ){ 23358: e1a00004 mov r0, r4 2335c: e1a0e00f mov lr, pc 23360: e12fff13 bx r3 23364: e3500004 cmp r0, #4 23368: e59d2010 ldr r2, [sp, #16] 2336c: 0a000009 beq 23398 rtems_filesystem_freenode( &loc ); 23370: e3520000 cmp r2, #0 23374: 0a000004 beq 2338c 23378: e592301c ldr r3, [r2, #28] 2337c: e3530000 cmp r3, #0 23380: 11a00004 movne r0, r4 23384: 11a0e00f movne lr, pc 23388: 112fff13 bxne r3 rtems_set_errno_and_return_minus_one( EINVAL ); 2338c: eb005389 bl 381b8 <__errno> 23390: e3a03016 mov r3, #22 23394: ea000009 b 233c0 } if ( !loc.ops->readlink_h ){ 23398: e592303c ldr r3, [r2, #60] ; 0x3c 2339c: e3530000 cmp r3, #0 233a0: 1a000009 bne 233cc rtems_filesystem_freenode( &loc ); 233a4: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 233a8: e3530000 cmp r3, #0 <== NOT EXECUTED 233ac: 11a00004 movne r0, r4 <== NOT EXECUTED 233b0: 11a0e00f movne lr, pc <== NOT EXECUTED 233b4: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 233b8: eb00537e bl 381b8 <__errno> <== NOT EXECUTED 233bc: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 233c0: e5803000 str r3, [r0] 233c4: e3e05000 mvn r5, #0 233c8: ea00000d b 23404 } result = (*loc.ops->readlink_h)( &loc, buf, bufsize ); 233cc: e1a02005 mov r2, r5 233d0: e1a01006 mov r1, r6 233d4: e1a00004 mov r0, r4 233d8: e1a0e00f mov lr, pc 233dc: e12fff13 bx r3 rtems_filesystem_freenode( &loc ); 233e0: e59d3010 ldr r3, [sp, #16] 233e4: e3530000 cmp r3, #0 if ( !loc.ops->readlink_h ){ rtems_filesystem_freenode( &loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->readlink_h)( &loc, buf, bufsize ); 233e8: e1a05000 mov r5, r0 rtems_filesystem_freenode( &loc ); 233ec: 0a000004 beq 23404 233f0: e593301c ldr r3, [r3, #28] 233f4: e3530000 cmp r3, #0 233f8: 11a00004 movne r0, r4 233fc: 11a0e00f movne lr, pc 23400: 112fff13 bxne r3 return result; } 23404: e1a00005 mov r0, r5 23408: e28dd018 add sp, sp, #24 2340c: e8bd80f0 pop {r4, r5, r6, r7, pc} 00003918 : int v; int bytes; rtems_libio_t *iop; bool all_zeros; rtems_libio_check_fd( fd ); 3918: e59f3144 ldr r3, [pc, #324] ; 3a64 391c: e5933000 ldr r3, [r3] 3920: e1500003 cmp r0, r3 ssize_t readv( int fd, const struct iovec *iov, int iovcnt ) { 3924: e92d49f0 push {r4, r5, r6, r7, r8, fp, lr} 3928: e1a08002 mov r8, r2 int v; int bytes; rtems_libio_t *iop; bool all_zeros; rtems_libio_check_fd( fd ); 392c: 2a000005 bcs 3948 iop = rtems_libio_iop( fd ); 3930: e59f3130 ldr r3, [pc, #304] ; 3a68 3934: e5936000 ldr r6, [r3] 3938: e0866300 add r6, r6, r0, lsl #6 rtems_libio_check_is_open( iop ); 393c: e5963014 ldr r3, [r6, #20] 3940: e3130c01 tst r3, #256 ; 0x100 3944: 1a000002 bne 3954 3948: eb00299e bl dfc8 <__errno> <== NOT EXECUTED 394c: e3a03009 mov r3, #9 <== NOT EXECUTED 3950: ea00001d b 39cc <== NOT EXECUTED rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ ); 3954: e3130002 tst r3, #2 3958: 0a000019 beq 39c4 /* * Argument validation on IO vector */ if ( !iov ) 395c: e3510000 cmp r1, #0 3960: 0a000017 beq 39c4 rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt <= 0 ) 3964: e3520000 cmp r2, #0 3968: da000015 ble 39c4 rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt > IOV_MAX ) 396c: e3520b01 cmp r2, #1024 ; 0x400 3970: ca000013 bgt 39c4 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !iop->handlers->read_h ) 3974: e596303c ldr r3, [r6, #60] ; 0x3c 3978: e5933008 ldr r3, [r3, #8] 397c: e3530000 cmp r3, #0 3980: 1a000002 bne 3990 rtems_set_errno_and_return_minus_one( ENOTSUP ); 3984: eb00298f bl dfc8 <__errno> <== NOT EXECUTED 3988: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 398c: ea00000e b 39cc <== NOT EXECUTED 3990: e3a03000 mov r3, #0 3994: e1a05001 mov r5, r1 3998: e1a02001 mov r2, r1 399c: e3a07001 mov r7, #1 39a0: e1a01003 mov r1, r3 all_zeros = true; for ( total=0, v=0 ; v < iovcnt ; v++ ) { ssize_t old; if ( !iov[v].iov_base ) 39a4: e5920000 ldr r0, [r2] 39a8: e3500000 cmp r0, #0 * are obvious errors in the iovec. So this extra loop ensures * that we do not do anything if there is an argument error. */ all_zeros = true; for ( total=0, v=0 ; v < iovcnt ; v++ ) { 39ac: e2833001 add r3, r3, #1 ssize_t old; if ( !iov[v].iov_base ) 39b0: 0a000003 beq 39c4 if ( iov[v].iov_len < 0 ) rtems_set_errno_and_return_minus_one( EINVAL ); /* check for wrap */ old = total; total += iov[v].iov_len; 39b4: e592c004 ldr ip, [r2, #4] 39b8: e081000c add r0, r1, ip if ( total < old ) 39bc: e1500001 cmp r0, r1 39c0: aa000003 bge 39d4 rtems_set_errno_and_return_minus_one( EINVAL ); 39c4: eb00297f bl dfc8 <__errno> 39c8: e3a03016 mov r3, #22 39cc: e5803000 str r3, [r0] 39d0: ea000011 b 3a1c if ( iov[v].iov_len ) 39d4: e35c0000 cmp ip, #0 39d8: 13a07000 movne r7, #0 * are obvious errors in the iovec. So this extra loop ensures * that we do not do anything if there is an argument error. */ all_zeros = true; for ( total=0, v=0 ; v < iovcnt ; v++ ) { 39dc: e1530008 cmp r3, r8 39e0: e2822008 add r2, r2, #8 39e4: b1a01000 movlt r1, r0 39e8: baffffed blt 39a4 /* * A readv with all zeros logically has no effect. Even though * OpenGroup didn't address this case as they did with writev(), * we will handle it the same way for symmetry. */ if ( all_zeros == true ) { 39ec: e3570000 cmp r7, #0 39f0: 13a04000 movne r4, #0 39f4: 1a000018 bne 3a5c 39f8: e1a04007 mov r4, r7 /* * Now process the readv(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) { bytes = (*iop->handlers->read_h)( iop, iov[v].iov_base, iov[v].iov_len ); 39fc: e8950006 ldm r5, {r1, r2} 3a00: e596303c ldr r3, [r6, #60] ; 0x3c 3a04: e1a00006 mov r0, r6 3a08: e1a0e00f mov lr, pc 3a0c: e593f008 ldr pc, [r3, #8] if ( bytes < 0 ) 3a10: e3500000 cmp r0, #0 } /* * Now process the readv(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) { 3a14: e2877001 add r7, r7, #1 bytes = (*iop->handlers->read_h)( iop, iov[v].iov_base, iov[v].iov_len ); if ( bytes < 0 ) 3a18: aa000001 bge 3a24 3a1c: e3e04000 mvn r4, #0 3a20: ea00000d b 3a5c return -1; if ( bytes > 0 ) { 3a24: 0a000006 beq 3a44 iop->offset += bytes; 3a28: e286c00c add ip, r6, #12 3a2c: e89c1800 ldm ip, {fp, ip} 3a30: e09b2000 adds r2, fp, r0 3a34: e0ac3fc0 adc r3, ip, r0, asr #31 3a38: e586200c str r2, [r6, #12] 3a3c: e5863010 str r3, [r6, #16] total += bytes; 3a40: e0844000 add r4, r4, r0 } if (bytes != iov[ v ].iov_len) 3a44: e5953004 ldr r3, [r5, #4] 3a48: e1500003 cmp r0, r3 3a4c: 1a000002 bne 3a5c } /* * Now process the readv(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) { 3a50: e1570008 cmp r7, r8 3a54: e2855008 add r5, r5, #8 3a58: baffffe7 blt 39fc if (bytes != iov[ v ].iov_len) break; } return total; } 3a5c: e1a00004 mov r0, r4 3a60: e8bd89f0 pop {r4, r5, r6, r7, r8, fp, pc} 3a64: 0001b250 .word 0x0001b250 3a68: 0001ddc4 .word 0x0001ddc4 00016dd0 : { uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1); 16dd0: e59f310c ldr r3, [pc, #268] ; 16ee4 /* * Do not attempt to allocate memory if in a critical section or ISR. */ if (_System_state_Is_up(_System_state_Get())) { 16dd4: e59f210c ldr r2, [pc, #268] ; 16ee8 16dd8: e592c000 ldr ip, [r2] { uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1); 16ddc: e5932010 ldr r2, [r3, #16] /* * Do not attempt to allocate memory if in a critical section or ISR. */ if (_System_state_Is_up(_System_state_Get())) { 16de0: e35c0003 cmp ip, #3 { uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1); 16de4: e2822001 add r2, r2, #1 16de8: e92d40f1 push {r0, r4, r5, r6, r7, lr} 16dec: e5832010 str r2, [r3, #16] 16df0: e1a04000 mov r4, r0 16df4: e1a05001 mov r5, r1 /* * Do not attempt to allocate memory if in a critical section or ISR. */ if (_System_state_Is_up(_System_state_Get())) { 16df8: 1a000007 bne 16e1c if (_Thread_Dispatch_disable_level > 0) 16dfc: e59f30e8 ldr r3, [pc, #232] ; 16eec 16e00: e5933000 ldr r3, [r3] 16e04: e3530000 cmp r3, #0 16e08: 1a000032 bne 16ed8 return (void *) 0; if (_ISR_Nest_level > 0) 16e0c: e59f30dc ldr r3, [pc, #220] ; 16ef0 16e10: e5933000 ldr r3, [r3] 16e14: e3530000 cmp r3, #0 16e18: 1a00002e bne 16ed8 } /* * Continue with realloc(). */ if ( !ptr ) 16e1c: e3540000 cmp r4, #0 16e20: 1a000003 bne 16e34 return malloc( size ); 16e24: e1a00005 mov r0, r5 16e28: ebffab78 bl 1c10 16e2c: e1a04000 mov r4, r0 16e30: ea000029 b 16edc if ( !size ) { 16e34: e3550000 cmp r5, #0 16e38: 1a000003 bne 16e4c free( ptr ); 16e3c: e1a00004 mov r0, r4 <== NOT EXECUTED 16e40: ebffaac0 bl 1948 <== NOT EXECUTED 16e44: e1a04005 mov r4, r5 <== NOT EXECUTED return (void *) 0; 16e48: ea000023 b 16edc <== NOT EXECUTED } if ( !_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, ptr, &old_size) ) { 16e4c: e59f60a0 ldr r6, [pc, #160] ; 16ef4 16e50: e1a01004 mov r1, r4 16e54: e5960000 ldr r0, [r6] 16e58: e1a0200d mov r2, sp 16e5c: eb000055 bl 16fb8 <_Protected_heap_Get_block_size> 16e60: e2507000 subs r7, r0, #0 16e64: 1a000004 bne 16e7c errno = EINVAL; 16e68: ebffd338 bl bb50 <__errno> 16e6c: e3a03016 mov r3, #22 16e70: e5803000 str r3, [r0] 16e74: e1a04007 mov r4, r7 return (void *) 0; 16e78: ea000017 b 16edc #if defined(RTEMS_MALLOC_BOUNDARY_HELPERS) if (rtems_malloc_boundary_helpers) resize += (*rtems_malloc_boundary_helpers->overhead)(); #endif if ( _Protected_heap_Resize_block( RTEMS_Malloc_Heap, ptr, resize ) ) { 16e7c: e5960000 ldr r0, [r6] 16e80: e1a01004 mov r1, r4 16e84: e1a02005 mov r2, r5 16e88: eb00005b bl 16ffc <_Protected_heap_Resize_block> 16e8c: e3500000 cmp r0, #0 16e90: 1a000011 bne 16edc * There used to be a free on this error case but it is wrong to * free the memory per OpenGroup Single UNIX Specification V2 * and the C Standard. */ new_area = malloc( size ); 16e94: e1a00005 mov r0, r5 16e98: ebffab5c bl 1c10 MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */ 16e9c: e59f3040 ldr r3, [pc, #64] ; 16ee4 16ea0: e5932004 ldr r2, [r3, #4] if ( !new_area ) { 16ea4: e2506000 subs r6, r0, #0 * and the C Standard. */ new_area = malloc( size ); MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */ 16ea8: e2422001 sub r2, r2, #1 16eac: e5832004 str r2, [r3, #4] if ( !new_area ) { 16eb0: 0a000008 beq 16ed8 return (void *) 0; } memcpy( new_area, ptr, (size < old_size) ? size : old_size ); 16eb4: e59d2000 ldr r2, [sp] 16eb8: e1a01004 mov r1, r4 16ebc: e1550002 cmp r5, r2 16ec0: 31a02005 movcc r2, r5 16ec4: ebffd52f bl c388 free( ptr ); 16ec8: e1a00004 mov r0, r4 16ecc: ebffaa9d bl 1948 16ed0: e1a04006 mov r4, r6 return new_area; 16ed4: ea000000 b 16edc 16ed8: e3a04000 mov r4, #0 } 16edc: e1a00004 mov r0, r4 16ee0: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} 16ee4: 00018cc8 .word 0x00018cc8 16ee8: 00018fd0 .word 0x00018fd0 16eec: 00018e2c .word 0x00018e2c 16ef0: 00018ebc .word 0x00018ebc 16ef4: 0001758c .word 0x0001758c 00023410 : #include int rmdir( const char *pathname ) { 23410: e92d4070 push {r4, r5, r6, lr} 23414: e24dd02c sub sp, sp, #44 ; 0x2c 23418: e1a06000 mov r6, r0 /* * Get the parent node of the node we wish to remove. Find the parent path. */ parentpathlen = rtems_filesystem_dirname ( pathname ); 2341c: ebff8489 bl 4648 if ( parentpathlen == 0 ) 23420: e2505000 subs r5, r0, #0 23424: 1a000019 bne 23490 rtems_filesystem_get_start_loc( pathname, &i, &parentloc ); 23428: e5d63000 ldrb r3, [r6] 2342c: e353002f cmp r3, #47 ; 0x2f 23430: 1353005c cmpne r3, #92 ; 0x5c 23434: 0a000001 beq 23440 23438: e3530000 cmp r3, #0 <== NOT EXECUTED 2343c: 1a000009 bne 23468 <== NOT EXECUTED 23440: e59f325c ldr r3, [pc, #604] ; 236a4 23444: e593e000 ldr lr, [r3] 23448: e28ee018 add lr, lr, #24 2344c: e8be000f ldm lr!, {r0, r1, r2, r3} 23450: e28dc018 add ip, sp, #24 23454: e8ac000f stmia ip!, {r0, r1, r2, r3} 23458: e59e3000 ldr r3, [lr] 2345c: e3a04000 mov r4, #0 23460: e58c3000 str r3, [ip] 23464: ea000013 b 234b8 23468: e59f3234 ldr r3, [pc, #564] ; 236a4 <== NOT EXECUTED 2346c: e593e000 ldr lr, [r3] <== NOT EXECUTED 23470: e28ee004 add lr, lr, #4 <== NOT EXECUTED 23474: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 23478: e28dc018 add ip, sp, #24 <== NOT EXECUTED 2347c: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 23480: e59e3000 ldr r3, [lr] <== NOT EXECUTED 23484: e1a04005 mov r4, r5 <== NOT EXECUTED 23488: e58c3000 str r3, [ip] <== NOT EXECUTED 2348c: ea000009 b 234b8 <== NOT EXECUTED else { result = rtems_filesystem_evaluate_path(pathname, parentpathlen, 23490: e3a0c000 mov ip, #0 23494: e1a00006 mov r0, r6 23498: e1a01005 mov r1, r5 2349c: e3a02002 mov r2, #2 234a0: e28d3018 add r3, sp, #24 234a4: e58dc000 str ip, [sp] 234a8: ebff84ae bl 4768 RTEMS_LIBIO_PERMS_WRITE, &parentloc, false ); if ( result != 0 ) 234ac: e3500000 cmp r0, #0 234b0: 1a000077 bne 23694 234b4: e3a04001 mov r4, #1 /* * Start from the parent to find the node that should be under it. */ loc = parentloc; 234b8: e28de018 add lr, sp, #24 234bc: e8be000f ldm lr!, {r0, r1, r2, r3} 234c0: e28dc004 add ip, sp, #4 234c4: e8ac000f stmia ip!, {r0, r1, r2, r3} 234c8: e59e3000 ldr r3, [lr] name = pathname + parentpathlen; 234cc: e0865005 add r5, r6, r5 /* * Start from the parent to find the node that should be under it. */ loc = parentloc; 234d0: e58c3000 str r3, [ip] name = pathname + parentpathlen; name += rtems_filesystem_prefix_separators( name, strlen( name ) ); 234d4: e1a00005 mov r0, r5 234d8: eb006db0 bl 3eba0 234dc: e1a01000 mov r1, r0 234e0: e1a00005 mov r0, r5 234e4: ebff844b bl 4618 234e8: e0856000 add r6, r5, r0 result = rtems_filesystem_evaluate_relative_path( name , strlen( name ), 234ec: e1a00006 mov r0, r6 234f0: eb006daa bl 3eba0 234f4: e28d5004 add r5, sp, #4 234f8: e3a0c000 mov ip, #0 234fc: e1a01000 mov r1, r0 23500: e1a0200c mov r2, ip 23504: e1a00006 mov r0, r6 23508: e1a03005 mov r3, r5 2350c: e58dc000 str ip, [sp] 23510: ebff845c bl 4688 0, &loc, false ); if ( result != 0 ) { 23514: e3500000 cmp r0, #0 23518: 0a00000b beq 2354c if ( free_parentloc ) 2351c: e3540000 cmp r4, #0 23520: 0a00005b beq 23694 rtems_filesystem_freenode( &parentloc ); 23524: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 23528: e3530000 cmp r3, #0 <== NOT EXECUTED 2352c: 0a000058 beq 23694 <== NOT EXECUTED 23530: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 23534: e3530000 cmp r3, #0 <== NOT EXECUTED 23538: 0a000055 beq 23694 <== NOT EXECUTED 2353c: e28d0018 add r0, sp, #24 <== NOT EXECUTED 23540: e1a0e00f mov lr, pc <== NOT EXECUTED 23544: e12fff13 bx r3 <== NOT EXECUTED 23548: ea000051 b 23694 <== NOT EXECUTED /* * Verify you can remove this node as a directory. */ if ( !loc.ops->node_type_h ){ 2354c: e59d2010 ldr r2, [sp, #16] 23550: e5923010 ldr r3, [r2, #16] 23554: e3530000 cmp r3, #0 rtems_filesystem_freenode( &loc ); 23558: 0592301c ldreq r3, [r2, #28] /* * Verify you can remove this node as a directory. */ if ( !loc.ops->node_type_h ){ 2355c: 0a000021 beq 235e8 if ( free_parentloc ) rtems_filesystem_freenode( &parentloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ){ 23560: e1a00005 mov r0, r5 23564: e1a0e00f mov lr, pc 23568: e12fff13 bx r3 2356c: e3500001 cmp r0, #1 23570: 0a000014 beq 235c8 rtems_filesystem_freenode( &loc ); 23574: e59d3010 ldr r3, [sp, #16] 23578: e3530000 cmp r3, #0 2357c: 0a000004 beq 23594 23580: e593301c ldr r3, [r3, #28] 23584: e3530000 cmp r3, #0 23588: 11a00005 movne r0, r5 2358c: 11a0e00f movne lr, pc 23590: 112fff13 bxne r3 if ( free_parentloc ) 23594: e3540000 cmp r4, #0 23598: 0a000007 beq 235bc rtems_filesystem_freenode( &parentloc ); 2359c: e59d3024 ldr r3, [sp, #36] ; 0x24 235a0: e3530000 cmp r3, #0 235a4: 0a000004 beq 235bc 235a8: e593301c ldr r3, [r3, #28] 235ac: e3530000 cmp r3, #0 235b0: 128d0018 addne r0, sp, #24 235b4: 11a0e00f movne lr, pc 235b8: 112fff13 bxne r3 rtems_set_errno_and_return_minus_one( ENOTDIR ); 235bc: eb0052fd bl 381b8 <__errno> 235c0: e3a03014 mov r3, #20 235c4: ea000017 b 23628 /* * Use the filesystems rmnod to remove the node. */ if ( !loc.handlers->rmnod_h ){ 235c8: e59d300c ldr r3, [sp, #12] 235cc: e5933034 ldr r3, [r3, #52] ; 0x34 235d0: e3530000 cmp r3, #0 235d4: 1a000015 bne 23630 rtems_filesystem_freenode( &loc ); 235d8: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 235dc: e3530000 cmp r3, #0 <== NOT EXECUTED 235e0: 0a000004 beq 235f8 <== NOT EXECUTED 235e4: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 235e8: e3530000 cmp r3, #0 <== NOT EXECUTED 235ec: 11a00005 movne r0, r5 <== NOT EXECUTED 235f0: 11a0e00f movne lr, pc <== NOT EXECUTED 235f4: 112fff13 bxne r3 <== NOT EXECUTED if ( free_parentloc ) 235f8: e3540000 cmp r4, #0 <== NOT EXECUTED 235fc: 0a000007 beq 23620 <== NOT EXECUTED rtems_filesystem_freenode( &parentloc ); 23600: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 23604: e3530000 cmp r3, #0 <== NOT EXECUTED 23608: 0a000004 beq 23620 <== NOT EXECUTED 2360c: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 23610: e3530000 cmp r3, #0 <== NOT EXECUTED 23614: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 23618: 11a0e00f movne lr, pc <== NOT EXECUTED 2361c: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 23620: eb0052e4 bl 381b8 <__errno> <== NOT EXECUTED 23624: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 23628: e5803000 str r3, [r0] 2362c: ea000018 b 23694 } result = (*loc.handlers->rmnod_h)( &parentloc, &loc ); 23630: e28d0018 add r0, sp, #24 23634: e1a01005 mov r1, r5 23638: e1a0e00f mov lr, pc 2363c: e12fff13 bx r3 rtems_filesystem_freenode( &loc ); 23640: e59d3010 ldr r3, [sp, #16] 23644: e3530000 cmp r3, #0 if ( free_parentloc ) rtems_filesystem_freenode( &parentloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.handlers->rmnod_h)( &parentloc, &loc ); 23648: e1a06000 mov r6, r0 rtems_filesystem_freenode( &loc ); 2364c: 0a000004 beq 23664 23650: e593301c ldr r3, [r3, #28] 23654: e3530000 cmp r3, #0 23658: 11a00005 movne r0, r5 2365c: 11a0e00f movne lr, pc 23660: 112fff13 bxne r3 if ( free_parentloc ) 23664: e3540000 cmp r4, #0 23668: 0a00000a beq 23698 rtems_filesystem_freenode( &parentloc ); 2366c: e59d3024 ldr r3, [sp, #36] ; 0x24 23670: e3530000 cmp r3, #0 23674: 0a000007 beq 23698 23678: e593301c ldr r3, [r3, #28] 2367c: e3530000 cmp r3, #0 23680: 0a000004 beq 23698 23684: e28d0018 add r0, sp, #24 23688: e1a0e00f mov lr, pc 2368c: e12fff13 bx r3 23690: ea000000 b 23698 23694: e3e06000 mvn r6, #0 return result; } 23698: e1a00006 mov r0, r6 2369c: e28dd02c add sp, sp, #44 ; 0x2c 236a0: e8bd8070 pop {r4, r5, r6, pc} 236a4: 00052578 .word 0x00052578 00011d1c : sprintf(bad_buffer, "< %" PRId32 "[0x%" PRIx32 " ] >", bad_value, bad_value); #else static char bad_buffer[40] = ""; #endif return bad_buffer; } 11d1c: e59f0000 ldr r0, [pc, #0] ; 11d24 <== NOT EXECUTED 11d20: e12fff1e bx lr <== NOT EXECUTED 11d24: 00021008 .word 0x00021008 0000efec : const char *rtems_assoc_name_by_local( const rtems_assoc_t *ap, uint32_t local_value ) { efec: e92d4010 push {r4, lr} eff0: e1a04001 mov r4, r1 const rtems_assoc_t *nap; nap = rtems_assoc_ptr_by_local(ap, local_value); eff4: eb000006 bl f014 if (nap) eff8: e3500000 cmp r0, #0 effc: 0a000001 beq f008 return nap->name; return rtems_assoc_name_bad(local_value); } f000: e5900000 ldr r0, [r0] f004: e8bd8010 pop {r4, pc} nap = rtems_assoc_ptr_by_local(ap, local_value); if (nap) return nap->name; return rtems_assoc_name_bad(local_value); f008: e1a00004 mov r0, r4 <== NOT EXECUTED } f00c: e8bd4010 pop {r4, lr} <== NOT EXECUTED nap = rtems_assoc_ptr_by_local(ap, local_value); if (nap) return nap->name; return rtems_assoc_name_bad(local_value); f010: ea000b41 b 11d1c <== NOT EXECUTED 0000b81c : uint32_t rtems_assoc_remote_by_local( const rtems_assoc_t *ap, uint32_t local_value ) { b81c: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED const rtems_assoc_t *nap; nap = rtems_assoc_ptr_by_local(ap, local_value); b820: eb0000ad bl badc <== NOT EXECUTED if (nap) b824: e3500000 cmp r0, #0 <== NOT EXECUTED return nap->remote_value; b828: 15900008 ldrne r0, [r0, #8] <== NOT EXECUTED return 0; } b82c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED 00001820 : size_t length ) { const char *p; if ( !name ) 1820: e3500000 cmp r0, #0 const char *rtems_bsp_cmdline_get_param( const char *name, char *value, size_t length ) { 1824: e92d4070 push {r4, r5, r6, lr} 1828: e1a04001 mov r4, r1 182c: e1a05002 mov r5, r2 const char *p; if ( !name ) 1830: 0a00001c beq 18a8 return NULL; if ( !value ) 1834: e3510000 cmp r1, #0 1838: 0a00001b beq 18ac return NULL; if ( !length ) 183c: e3520000 cmp r2, #0 1840: 0a000018 beq 18a8 return NULL; value[0] = '\0'; 1844: e3a06000 mov r6, #0 1848: e5c16000 strb r6, [r1] p = rtems_bsp_cmdline_get_param_raw( name ); 184c: eb000018 bl 18b4 if ( !p ) 1850: e3500000 cmp r0, #0 1854: 0a000013 beq 18a8 int i; int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i quotes++; } else if ( ((quotes % 2) == 0) && *p == ' ' ) 1874: e3160001 tst r6, #1 1878: 1a000001 bne 1884 187c: e3520020 cmp r2, #32 1880: 0a000009 beq 18ac break; value[i++] = *p++; 1884: e7c42003 strb r2, [r4, r3] 1888: e2833001 add r3, r3, #1 value[i] = '\0'; 188c: e7c41003 strb r1, [r4, r3] int i; int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i 189c: e1530005 cmp r3, r5 18a0: 3afffff0 bcc 1868 18a4: ea000000 b 18ac <== NOT EXECUTED 18a8: e3a04000 mov r4, #0 return NULL; copy_string( p, value, length ); return value; } 18ac: e1a00004 mov r0, r4 18b0: e8bd8070 pop {r4, r5, r6, pc} 00002414 : void rtems_cpu_usage_report_with_plugin( void *context, rtems_printk_plugin_t print ) { 2414: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} Timestamp_Control uptime, total, ran; #else uint32_t total_units = 0; #endif if ( !print ) 2418: e251a000 subs sl, r1, #0 void rtems_cpu_usage_report_with_plugin( void *context, rtems_printk_plugin_t print ) { 241c: e24dd040 sub sp, sp, #64 ; 0x40 2420: e1a08000 mov r8, r0 Timestamp_Control uptime, total, ran; #else uint32_t total_units = 0; #endif if ( !print ) 2424: 0a000059 beq 2590 * When not using nanosecond CPU usage resolution, we have to count * the number of "ticks" we gave credit for to give the user a rough * guideline as to what each number means proportionally. */ #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ _TOD_Get_uptime( &uptime ); 2428: e28d4030 add r4, sp, #48 ; 0x30 242c: e1a00004 mov r0, r4 _Timestamp_Subtract( &CPU_usage_Uptime_at_last_reset, &uptime, &total ); 2430: e28d5028 add r5, sp, #40 ; 0x28 * When not using nanosecond CPU usage resolution, we have to count * the number of "ticks" we gave credit for to give the user a rough * guideline as to what each number means proportionally. */ #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ _TOD_Get_uptime( &uptime ); 2434: eb001326 bl 70d4 <_TOD_Get_uptime> _Timestamp_Subtract( &CPU_usage_Uptime_at_last_reset, &uptime, &total ); 2438: e1a01004 mov r1, r4 243c: e1a02005 mov r2, r5 2440: e59f0150 ldr r0, [pc, #336] ; 2598 2444: eb001c0a bl 9474 <_Timespec_Subtract> } } } #endif (*print)( 2448: e1a00008 mov r0, r8 244c: e59f1148 ldr r1, [pc, #328] ; 259c 2450: e1a0e00f mov lr, pc 2454: e12fff1a bx sl 2458: e59f4140 ldr r4, [pc, #320] ; 25a0 /* * If this is the currently executing thread, account for time * since the last context switch. */ ran = the_thread->cpu_time_used; if ( _Thread_Executing->Object.id == the_thread->Object.id ) { 245c: e59fb140 ldr fp, [pc, #320] ; 25a4 ); for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) { if ( !_Objects_Information_table[ api_index ] ) 2460: e5943004 ldr r3, [r4, #4] 2464: e3530000 cmp r3, #0 2468: 0a00003b beq 255c continue; information = _Objects_Information_table[ api_index ][ 1 ]; 246c: e5936004 ldr r6, [r3, #4] if ( information ) { 2470: e3560000 cmp r6, #0 2474: 13a07001 movne r7, #1 * since the last context switch. */ ran = the_thread->cpu_time_used; if ( _Thread_Executing->Object.id == the_thread->Object.id ) { Timestamp_Control used; _Timestamp_Subtract( 2478: 128d9018 addne r9, sp, #24 247c: 11a05004 movne r5, r4 api_index <= OBJECTS_APIS_LAST ; api_index++ ) { if ( !_Objects_Information_table[ api_index ] ) continue; information = _Objects_Information_table[ api_index ][ 1 ]; if ( information ) { 2480: 1a00002f bne 2544 2484: ea000034 b 255c <== NOT EXECUTED for ( i=1 ; i <= information->maximum ; i++ ) { the_thread = (Thread_Control *)information->local_table[ i ]; 2488: e596301c ldr r3, [r6, #28] 248c: e7934107 ldr r4, [r3, r7, lsl #2] if ( !the_thread ) 2490: e3540000 cmp r4, #0 2494: 0a000029 beq 2540 continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name ); 2498: e5940008 ldr r0, [r4, #8] 249c: eb000e90 bl 5ee4 (*print)( 24a0: e28d3008 add r3, sp, #8 24a4: e5942008 ldr r2, [r4, #8] 24a8: e1a00008 mov r0, r8 24ac: e59f10f4 ldr r1, [pc, #244] ; 25a8 24b0: e1a0e00f mov lr, pc 24b4: e12fff1a bx sl #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ /* * If this is the currently executing thread, account for time * since the last context switch. */ ran = the_thread->cpu_time_used; 24b8: e2843084 add r3, r4, #132 ; 0x84 24bc: e893000c ldm r3, {r2, r3} 24c0: e58d2020 str r2, [sp, #32] 24c4: e58d3024 str r3, [sp, #36] ; 0x24 if ( _Thread_Executing->Object.id == the_thread->Object.id ) { 24c8: e59b2000 ldr r2, [fp] 24cc: e5943008 ldr r3, [r4, #8] 24d0: e5922008 ldr r2, [r2, #8] 24d4: e1520003 cmp r2, r3 24d8: 1a000006 bne 24f8 Timestamp_Control used; _Timestamp_Subtract( 24dc: e59f00c8 ldr r0, [pc, #200] ; 25ac 24e0: e28d1030 add r1, sp, #48 ; 0x30 24e4: e1a02009 mov r2, r9 24e8: eb001be1 bl 9474 <_Timespec_Subtract> &_Thread_Time_of_last_context_switch, &uptime, &used ); _Timestamp_Add_to( &ran, &used ); 24ec: e28d0020 add r0, sp, #32 24f0: e1a01009 mov r1, r9 24f4: eb001ba4 bl 938c <_Timespec_Add_to> }; _Timestamp_Divide( &ran, &total, &ival, &fval ); 24f8: e28d203c add r2, sp, #60 ; 0x3c 24fc: e28d3038 add r3, sp, #56 ; 0x38 2500: e28d0020 add r0, sp, #32 2504: e28d1028 add r1, sp, #40 ; 0x28 2508: eb001bb3 bl 93dc <_Timespec_Divide> /* * Print the information */ (*print)( context, 250c: e3a01ffa mov r1, #1000 ; 0x3e8 2510: e59d0024 ldr r0, [sp, #36] ; 0x24 2514: eb005f6c bl 1a2cc <__aeabi_uidiv> 2518: e59d203c ldr r2, [sp, #60] ; 0x3c 251c: e58d2000 str r2, [sp] 2520: e59d2038 ldr r2, [sp, #56] ; 0x38 2524: e1a03000 mov r3, r0 2528: e58d2004 str r2, [sp, #4] 252c: e1a00008 mov r0, r8 2530: e59f1078 ldr r1, [pc, #120] ; 25b0 2534: e59d2020 ldr r2, [sp, #32] 2538: e1a0e00f mov lr, pc 253c: e12fff1a bx sl api_index++ ) { if ( !_Objects_Information_table[ api_index ] ) continue; information = _Objects_Information_table[ api_index ][ 1 ]; if ( information ) { for ( i=1 ; i <= information->maximum ; i++ ) { 2540: e2877001 add r7, r7, #1 2544: e1d631b0 ldrh r3, [r6, #16] 2548: e1570003 cmp r7, r3 the_thread = (Thread_Control *)information->local_table[ i ]; if ( !the_thread ) continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name ); 254c: e3a0100d mov r1, #13 2550: e28d2008 add r2, sp, #8 api_index++ ) { if ( !_Objects_Information_table[ api_index ] ) continue; information = _Objects_Information_table[ api_index ][ 1 ]; if ( information ) { for ( i=1 ; i <= information->maximum ; i++ ) { 2554: 9affffcb bls 2488 2558: e1a04005 mov r4, r5 " ID | NAME | TICKS | PERCENT\n" #endif "------------+----------------------------------------+---------------+---------\n" ); for ( api_index = 1 ; 255c: e59f3050 ldr r3, [pc, #80] ; 25b4 api_index++ ) { if ( !_Objects_Information_table[ api_index ] ) continue; information = _Objects_Information_table[ api_index ][ 1 ]; if ( information ) { for ( i=1 ; i <= information->maximum ; i++ ) { 2560: e2844004 add r4, r4, #4 " ID | NAME | TICKS | PERCENT\n" #endif "------------+----------------------------------------+---------------+---------\n" ); for ( api_index = 1 ; 2564: e1540003 cmp r4, r3 2568: 1affffbc bne 2460 } } } #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ (*print)( 256c: e3a01ffa mov r1, #1000 ; 0x3e8 2570: e59d002c ldr r0, [sp, #44] ; 0x2c 2574: eb005f54 bl 1a2cc <__aeabi_uidiv> 2578: e59f1038 ldr r1, [pc, #56] ; 25b8 257c: e1a03000 mov r3, r0 2580: e59d2028 ldr r2, [sp, #40] ; 0x28 2584: e1a00008 mov r0, r8 2588: e1a0e00f mov lr, pc 258c: e12fff1a bx sl "-------------------------------------------------------------------------------\n", _Watchdog_Ticks_since_boot - CPU_usage_Ticks_at_last_reset, total_units ); #endif } 2590: e28dd040 add sp, sp, #64 ; 0x40 2594: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} 2598: 00026fe0 .word 0x00026fe0 259c: 0001db18 .word 0x0001db18 25a0: 00026d68 .word 0x00026d68 25a4: 00026e60 .word 0x00026e60 25a8: 0001dc8a .word 0x0001dc8a 25ac: 00026e68 .word 0x00026e68 25b0: 0001dc9d .word 0x0001dc9d 25b4: 00026d78 .word 0x00026d78 25b8: 0001dcb5 .word 0x0001dcb5 0000b7f0 : { 0, 0, 0 }, }; int rtems_deviceio_errno(rtems_status_code code) { b7f0: e92d4010 push {r4, lr} <== NOT EXECUTED b7f4: e1a01000 mov r1, r0 <== NOT EXECUTED int rc; if ((rc = rtems_assoc_remote_by_local(errno_assoc, (uint32_t ) code))) b7f8: e59f0018 ldr r0, [pc, #24] ; b818 <== NOT EXECUTED b7fc: eb000006 bl b81c <== NOT EXECUTED b800: e2504000 subs r4, r0, #0 <== NOT EXECUTED b804: 0a000001 beq b810 <== NOT EXECUTED { errno = rc; b808: eb0000d0 bl bb50 <__errno> <== NOT EXECUTED b80c: e5804000 str r4, [r0] <== NOT EXECUTED return -1; } return -1; } b810: e3e00000 mvn r0, #0 <== NOT EXECUTED b814: e8bd8010 pop {r4, pc} <== NOT EXECUTED b818: 0001802c .word 0x0001802c 000064fc : int rtems_error( rtems_error_code_t error_flag, const char *printf_format, ... ) { 64fc: e92d000e push {r1, r2, r3} <== NOT EXECUTED 6500: e92d4001 push {r0, lr} <== NOT EXECUTED va_list arglist; int chars_written; va_start(arglist, printf_format); 6504: e28d300c add r3, sp, #12 <== NOT EXECUTED chars_written = rtems_verror(error_flag, printf_format, arglist); 6508: e1a02003 mov r2, r3 <== NOT EXECUTED 650c: e59d1008 ldr r1, [sp, #8] <== NOT EXECUTED ) { va_list arglist; int chars_written; va_start(arglist, printf_format); 6510: e58d3000 str r3, [sp] <== NOT EXECUTED chars_written = rtems_verror(error_flag, printf_format, arglist); 6514: ebffff84 bl 632c <== NOT EXECUTED va_end(arglist); return chars_written; } 6518: e8bd4008 pop {r3, lr} <== NOT EXECUTED 651c: e28dd00c add sp, sp, #12 <== NOT EXECUTED 6520: e12fff1e bx lr <== NOT EXECUTED 0000187c : int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc, int follow_link ) { 187c: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} /* * Verify Input parameters. */ if ( !pathname ) 1880: e2505000 subs r5, r0, #0 int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc, int follow_link ) { 1884: e1a07001 mov r7, r1 1888: e1a06002 mov r6, r2 188c: e1a0c003 mov ip, r3 1890: e59da020 ldr sl, [sp, #32] /* * Verify Input parameters. */ if ( !pathname ) 1894: 1a000002 bne 18a4 rtems_set_errno_and_return_minus_one( EFAULT ); 1898: eb0028ac bl bb50 <__errno> <== NOT EXECUTED 189c: e3a0300e mov r3, #14 <== NOT EXECUTED 18a0: ea000003 b 18b4 <== NOT EXECUTED if ( !pathloc ) 18a4: e3530000 cmp r3, #0 18a8: 1a000004 bne 18c0 rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */ 18ac: eb0028a7 bl bb50 <__errno> <== NOT EXECUTED 18b0: e3a03005 mov r3, #5 <== NOT EXECUTED 18b4: e5803000 str r3, [r0] <== NOT EXECUTED return rtems_filesystem_evaluate_relative_path( &pathname[i], pathnamelen - i, flags, pathloc, follow_link ); } 18b8: e3e00000 mvn r0, #0 <== NOT EXECUTED 18bc: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED /* * Evaluate the path using the optable evalpath. */ rtems_filesystem_get_start_loc( pathname, &i, pathloc ); 18c0: e5d53000 ldrb r3, [r5] 18c4: e353002f cmp r3, #47 ; 0x2f 18c8: 1353005c cmpne r3, #92 ; 0x5c 18cc: 13a08000 movne r8, #0 18d0: 03a08001 moveq r8, #1 18d4: 0a000001 beq 18e0 18d8: e3530000 cmp r3, #0 18dc: 1a000009 bne 1908 18e0: e59f305c ldr r3, [pc, #92] ; 1944 18e4: e5934000 ldr r4, [r3] 18e8: e2844018 add r4, r4, #24 18ec: e8b4000f ldm r4!, {r0, r1, r2, r3} 18f0: e1a0800c mov r8, ip 18f4: e8a8000f stmia r8!, {r0, r1, r2, r3} 18f8: e5942000 ldr r2, [r4] 18fc: e5882000 str r2, [r8] 1900: e3a08001 mov r8, #1 1904: ea000007 b 1928 1908: e59f3034 ldr r3, [pc, #52] ; 1944 190c: e5934000 ldr r4, [r3] 1910: e2844004 add r4, r4, #4 1914: e8b4000f ldm r4!, {r0, r1, r2, r3} 1918: e1a0900c mov r9, ip 191c: e8a9000f stmia r9!, {r0, r1, r2, r3} 1920: e5942000 ldr r2, [r4] 1924: e5892000 str r2, [r9] /* * We evaluation the path relative to the start location we get got. */ return rtems_filesystem_evaluate_relative_path( &pathname[i], 1928: e0681007 rsb r1, r8, r7 192c: e0850008 add r0, r5, r8 1930: e1a02006 mov r2, r6 1934: e1a0300c mov r3, ip 1938: e58da020 str sl, [sp, #32] pathnamelen - i, flags, pathloc, follow_link ); } 193c: e8bd47f0 pop {r4, r5, r6, r7, r8, r9, sl, lr} rtems_filesystem_get_start_loc( pathname, &i, pathloc ); /* * We evaluation the path relative to the start location we get got. */ return rtems_filesystem_evaluate_relative_path( &pathname[i], 1940: eaffff95 b 179c 1944: 00017718 .word 0x00017718 0000179c : /* * Verify Input parameters. */ if ( !pathname ) 179c: e3500000 cmp r0, #0 int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc, int follow_link ) { 17a0: e92d4030 push {r4, r5, lr} 17a4: e1a05002 mov r5, r2 17a8: e1a04003 mov r4, r3 /* * Verify Input parameters. */ if ( !pathname ) 17ac: 1a000002 bne 17bc rtems_set_errno_and_return_minus_one( EFAULT ); 17b0: eb0028e6 bl bb50 <__errno> <== NOT EXECUTED 17b4: e3a0300e mov r3, #14 <== NOT EXECUTED 17b8: ea000027 b 185c <== NOT EXECUTED if ( !pathloc ) 17bc: e3530000 cmp r3, #0 17c0: 1a000002 bne 17d0 rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */ 17c4: eb0028e1 bl bb50 <__errno> <== NOT EXECUTED 17c8: e3a03005 mov r3, #5 <== NOT EXECUTED 17cc: ea000022 b 185c <== NOT EXECUTED if ( !pathloc->ops->evalpath_h ) 17d0: e593c00c ldr ip, [r3, #12] 17d4: e59cc000 ldr ip, [ip] 17d8: e35c0000 cmp ip, #0 17dc: 0a00001c beq 1854 rtems_set_errno_and_return_minus_one( ENOTSUP ); result = (*pathloc->ops->evalpath_h)( pathname, pathnamelen, flags, pathloc ); 17e0: e1a0e00f mov lr, pc 17e4: e12fff1c bx ip /* * Get the Node type and determine if you need to follow the link or * not. */ if ( (result == 0) && follow_link ) { 17e8: e59d200c ldr r2, [sp, #12] 17ec: e2703001 rsbs r3, r0, #1 17f0: 33a03000 movcc r3, #0 17f4: e3520000 cmp r2, #0 17f8: 03a03000 moveq r3, #0 17fc: e3530000 cmp r3, #0 1800: 08bd8030 popeq {r4, r5, pc} if ( !pathloc->ops->node_type_h ){ 1804: e594200c ldr r2, [r4, #12] 1808: e5923010 ldr r3, [r2, #16] 180c: e3530000 cmp r3, #0 1810: 0a00000a beq 1840 rtems_filesystem_freenode( pathloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } type = (*pathloc->ops->node_type_h)( pathloc ); 1814: e1a00004 mov r0, r4 1818: e1a0e00f mov lr, pc 181c: e12fff13 bx r3 if ( ( type == RTEMS_FILESYSTEM_HARD_LINK ) || 1820: e2400003 sub r0, r0, #3 1824: e3500001 cmp r0, #1 1828: 83a00000 movhi r0, #0 182c: 88bd8030 pophi {r4, r5, pc} ( type == RTEMS_FILESYSTEM_SYM_LINK ) ) { if ( !pathloc->ops->eval_link_h ){ 1830: e594200c ldr r2, [r4, #12] 1834: e5923034 ldr r3, [r2, #52] ; 0x34 1838: e3530000 cmp r3, #0 183c: 1a000009 bne 1868 rtems_filesystem_freenode( pathloc ); 1840: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 1844: e3530000 cmp r3, #0 <== NOT EXECUTED 1848: 11a00004 movne r0, r4 <== NOT EXECUTED 184c: 11a0e00f movne lr, pc <== NOT EXECUTED 1850: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 1854: eb0028bd bl bb50 <__errno> <== NOT EXECUTED 1858: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 185c: e5803000 str r3, [r0] <== NOT EXECUTED 1860: e3e00000 mvn r0, #0 <== NOT EXECUTED 1864: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED * pathloc will be passed up (and eventually released). * Hence, the (valid) originial node that we submit to * eval_link_h() should be released by the handler. */ result = (*pathloc->ops->eval_link_h)( pathloc, flags ); 1868: e1a00004 mov r0, r4 186c: e1a01005 mov r1, r5 1870: e1a0e00f mov lr, pc 1874: e12fff13 bx r3 } } return result; } 1878: e8bd8030 pop {r4, r5, pc} 000015fc : * configuration is a single instantiation of the IMFS or miniIMFS with * a single "/dev" directory in it. */ void rtems_filesystem_initialize( void ) { 15fc: e92d40f0 push {r4, r5, r6, r7, lr} /* * Set the default umask to "022". */ rtems_filesystem_umask = 022; 1600: e59f6100 ldr r6, [pc, #256] ; 1708 1604: e5963000 ldr r3, [r6] 1608: e3a02012 mov r2, #18 160c: e583202c str r2, [r3, #44] ; 0x2c * configuration is a single instantiation of the IMFS or miniIMFS with * a single "/dev" directory in it. */ void rtems_filesystem_initialize( void ) { 1610: e24dd01c sub sp, sp, #28 */ rtems_filesystem_umask = 022; init_fs_mount_table(); 1614: eb000215 bl 1e70 /* * mount the first filesystem. */ if ( rtems_filesystem_mount_table_size == 0 ) 1618: e59f30ec ldr r3, [pc, #236] ; 170c 161c: e5933000 ldr r3, [r3] 1620: e3530000 cmp r3, #0 rtems_fatal_error_occurred( 0xABCD0001 ); 1624: 059f00e4 ldreq r0, [pc, #228] ; 1710 /* * mount the first filesystem. */ if ( rtems_filesystem_mount_table_size == 0 ) 1628: 0a000009 beq 1654 rtems_fatal_error_occurred( 0xABCD0001 ); mt = &rtems_filesystem_mount_table[0]; 162c: e59f30e0 ldr r3, [pc, #224] ; 1714 1630: e5932000 ldr r2, [r3] status = mount( 1634: e592300c ldr r3, [r2, #12] 1638: e58d3000 str r3, [sp] 163c: e28d0018 add r0, sp, #24 1640: e892000e ldm r2, {r1, r2, r3} 1644: eb000210 bl 1e8c &entry, mt->fs_ops, mt->fsoptions, mt->device, mt->mount_point ); if ( status == -1 ) 1648: e3700001 cmn r0, #1 164c: 1a000001 bne 1658 rtems_fatal_error_occurred( 0xABCD0002 ); 1650: e59f00c0 ldr r0, [pc, #192] ; 1718 <== NOT EXECUTED 1654: eb000e96 bl 50b4 <== NOT EXECUTED * set_private_env() - but then: that's * gonna hit performance. * * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root; 1658: e59de018 ldr lr, [sp, #24] &entry, mt->fs_ops, mt->fsoptions, mt->device, mt->mount_point ); if ( status == -1 ) rtems_fatal_error_occurred( 0xABCD0002 ); rtems_filesystem_link_counts = 0; 165c: e5967000 ldr r7, [r6] * set_private_env() - but then: that's * gonna hit performance. * * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root; 1660: e28ee01c add lr, lr, #28 1664: e8be000f ldm lr!, {r0, r1, r2, r3} 1668: e287c018 add ip, r7, #24 166c: e8ac000f stmia ip!, {r0, r1, r2, r3} 1670: e59e3000 ldr r3, [lr] &entry, mt->fs_ops, mt->fsoptions, mt->device, mt->mount_point ); if ( status == -1 ) rtems_fatal_error_occurred( 0xABCD0002 ); rtems_filesystem_link_counts = 0; 1674: e3a05000 mov r5, #0 * * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root; /* Clone the root pathloc */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 1678: e28d4004 add r4, sp, #4 * set_private_env() - but then: that's * gonna hit performance. * * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root; 167c: e58c3000 str r3, [ip] &entry, mt->fs_ops, mt->fsoptions, mt->device, mt->mount_point ); if ( status == -1 ) rtems_fatal_error_occurred( 0xABCD0002 ); rtems_filesystem_link_counts = 0; 1680: e1c753b0 strh r5, [r7, #48] ; 0x30 * * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root; /* Clone the root pathloc */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 1684: e1a03004 mov r3, r4 1688: e3a01001 mov r1, #1 168c: e1a02005 mov r2, r5 1690: e59f0084 ldr r0, [pc, #132] ; 171c rtems_filesystem_root = loc; 1694: e1a07004 mov r7, r4 * * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root; /* Clone the root pathloc */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 1698: e58d5000 str r5, [sp] 169c: eb000076 bl 187c rtems_filesystem_root = loc; 16a0: e596c000 ldr ip, [r6] 16a4: e8b7000f ldm r7!, {r0, r1, r2, r3} 16a8: e28cc018 add ip, ip, #24 16ac: e8ac000f stmia ip!, {r0, r1, r2, r3} 16b0: e5973000 ldr r3, [r7] /* One more clone for the current node */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 16b4: e1a02005 mov r2, r5 * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root; /* Clone the root pathloc */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); rtems_filesystem_root = loc; 16b8: e58c3000 str r3, [ip] /* One more clone for the current node */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 16bc: e3a01001 mov r1, #1 16c0: e1a03004 mov r3, r4 16c4: e59f0050 ldr r0, [pc, #80] ; 171c 16c8: e58d5000 str r5, [sp] 16cc: eb00006a bl 187c rtems_filesystem_current = loc; 16d0: e596c000 ldr ip, [r6] 16d4: e8b4000f ldm r4!, {r0, r1, r2, r3} 16d8: e28cc004 add ip, ip, #4 16dc: e8ac000f stmia ip!, {r0, r1, r2, r3} 16e0: e5973000 ldr r3, [r7] * * NOTE: UNIX root is 755 and owned by root/root (0/0). It is actually * created that way by the IMFS. */ status = mkdir( "/dev", 0777); 16e4: e59f0034 ldr r0, [pc, #52] ; 1720 /* Clone the root pathloc */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); rtems_filesystem_root = loc; /* One more clone for the current node */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); rtems_filesystem_current = loc; 16e8: e58c3000 str r3, [ip] * * NOTE: UNIX root is 755 and owned by root/root (0/0). It is actually * created that way by the IMFS. */ status = mkdir( "/dev", 0777); 16ec: e59f1030 ldr r1, [pc, #48] ; 1724 16f0: eb000184 bl 1d08 if ( status != 0 ) 16f4: e1500005 cmp r0, r5 rtems_fatal_error_occurred( 0xABCD0003 ); 16f8: 159f0028 ldrne r0, [pc, #40] ; 1728 * NOTE: UNIX root is 755 and owned by root/root (0/0). It is actually * created that way by the IMFS. */ status = mkdir( "/dev", 0777); if ( status != 0 ) 16fc: 1affffd4 bne 1654 * it will be mounted onto is created. Moreover, if it is going to * use a device, then it is REALLY unfair to attempt this * before device drivers are initialized. So we return via a base * filesystem image and nothing auto-mounted at this point. */ } 1700: e28dd01c add sp, sp, #28 1704: e8bd80f0 pop {r4, r5, r6, r7, pc} 1708: 00017718 .word 0x00017718 170c: 00017c8c .word 0x00017c8c 1710: abcd0001 .word 0xabcd0001 1714: 00017588 .word 0x00017588 1718: abcd0002 .word 0xabcd0002 171c: 000184bb .word 0x000184bb 1720: 000184bd .word 0x000184bd 1724: 000001ff .word 0x000001ff 1728: abcd0003 .word 0xabcd0003 000239b0 : ); bool rtems_filesystem_nodes_equal( const rtems_filesystem_location_info_t *loc1, const rtems_filesystem_location_info_t *loc2 ){ 239b0: e5903000 ldr r3, [r0] <== NOT EXECUTED 239b4: e5910000 ldr r0, [r1] <== NOT EXECUTED return ( loc1->node_access == loc2->node_access ); } 239b8: e1530000 cmp r3, r0 <== NOT EXECUTED 239bc: 13a00000 movne r0, #0 <== NOT EXECUTED 239c0: 03a00001 moveq r0, #1 <== NOT EXECUTED 239c4: e12fff1e bx lr <== NOT EXECUTED 000014bc : rtems_status_code rtems_io_lookup_name( const char *name, rtems_driver_name_t *device_info ) { 14bc: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} <== NOT EXECUTED 14c0: e24dd018 sub sp, sp, #24 <== NOT EXECUTED 14c4: e1a05001 mov r5, r1 <== NOT EXECUTED 14c8: e1a06000 mov r6, r0 <== NOT EXECUTED IMFS_jnode_t *the_jnode; rtems_filesystem_location_info_t loc; int result; rtems_filesystem_node_types_t node_type; result = rtems_filesystem_evaluate_path( name, strlen( name ), 0x00, &loc, true ); 14cc: eb002d90 bl cb14 <== NOT EXECUTED 14d0: e28d4004 add r4, sp, #4 <== NOT EXECUTED 14d4: e1a01000 mov r1, r0 <== NOT EXECUTED 14d8: e3a02000 mov r2, #0 <== NOT EXECUTED 14dc: e1a03004 mov r3, r4 <== NOT EXECUTED 14e0: e3a0c001 mov ip, #1 <== NOT EXECUTED 14e4: e1a00006 mov r0, r6 <== NOT EXECUTED 14e8: e58dc000 str ip, [sp] <== NOT EXECUTED 14ec: eb0000e2 bl 187c <== NOT EXECUTED the_jnode = loc.node_access; if ( !loc.ops->node_type_h ) { 14f0: e59d2010 ldr r2, [sp, #16] <== NOT EXECUTED 14f4: e5923010 ldr r3, [r2, #16] <== NOT EXECUTED 14f8: e3530000 cmp r3, #0 <== NOT EXECUTED IMFS_jnode_t *the_jnode; rtems_filesystem_location_info_t loc; int result; rtems_filesystem_node_types_t node_type; result = rtems_filesystem_evaluate_path( name, strlen( name ), 0x00, &loc, true ); 14fc: e1a07000 mov r7, r0 <== NOT EXECUTED the_jnode = loc.node_access; 1500: e59d8004 ldr r8, [sp, #4] <== NOT EXECUTED if ( !loc.ops->node_type_h ) { 1504: 1a000009 bne 1530 <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 1508: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 150c: e3530000 cmp r3, #0 <== NOT EXECUTED 1510: 11a00004 movne r0, r4 <== NOT EXECUTED 1514: 11a0e00f movne lr, pc <== NOT EXECUTED 1518: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 151c: eb00298b bl bb50 <__errno> <== NOT EXECUTED 1520: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 1524: e5803000 str r3, [r0] <== NOT EXECUTED 1528: e3e00000 mvn r0, #0 <== NOT EXECUTED 152c: ea000026 b 15cc <== NOT EXECUTED } node_type = (*loc.ops->node_type_h)( &loc ); 1530: e1a00004 mov r0, r4 <== NOT EXECUTED 1534: e1a0e00f mov lr, pc <== NOT EXECUTED 1538: e12fff13 bx r3 <== NOT EXECUTED if ( (result != 0) || node_type != RTEMS_FILESYSTEM_DEVICE ) { 153c: e3570000 cmp r7, #0 <== NOT EXECUTED 1540: 03500002 cmpeq r0, #2 <== NOT EXECUTED 1544: 03a0a000 moveq sl, #0 <== NOT EXECUTED 1548: 13a0a001 movne sl, #1 <== NOT EXECUTED 154c: e59d7010 ldr r7, [sp, #16] <== NOT EXECUTED 1550: 0a000008 beq 1578 <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 1554: e3570000 cmp r7, #0 <== NOT EXECUTED 1558: 0a000018 beq 15c0 <== NOT EXECUTED 155c: e597301c ldr r3, [r7, #28] <== NOT EXECUTED 1560: e3530000 cmp r3, #0 <== NOT EXECUTED 1564: 0a000015 beq 15c0 <== NOT EXECUTED 1568: e1a00004 mov r0, r4 <== NOT EXECUTED 156c: e1a0e00f mov lr, pc <== NOT EXECUTED 1570: e12fff13 bx r3 <== NOT EXECUTED 1574: ea000011 b 15c0 <== NOT EXECUTED return RTEMS_UNSATISFIED; } device_info->device_name = (char *) name; 1578: e5856000 str r6, [r5] <== NOT EXECUTED device_info->device_name_length = strlen( name ); 157c: e1a00006 mov r0, r6 <== NOT EXECUTED 1580: eb002d63 bl cb14 <== NOT EXECUTED 1584: e5850004 str r0, [r5, #4] <== NOT EXECUTED device_info->major = the_jnode->info.device.major; 1588: e5983050 ldr r3, [r8, #80] ; 0x50 <== NOT EXECUTED 158c: e5853008 str r3, [r5, #8] <== NOT EXECUTED device_info->minor = the_jnode->info.device.minor; 1590: e5983054 ldr r3, [r8, #84] ; 0x54 <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 1594: e3570000 cmp r7, #0 <== NOT EXECUTED } device_info->device_name = (char *) name; device_info->device_name_length = strlen( name ); device_info->major = the_jnode->info.device.major; device_info->minor = the_jnode->info.device.minor; 1598: e585300c str r3, [r5, #12] <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 159c: 0a000009 beq 15c8 <== NOT EXECUTED 15a0: e597301c ldr r3, [r7, #28] <== NOT EXECUTED 15a4: e3530000 cmp r3, #0 <== NOT EXECUTED 15a8: 0a000006 beq 15c8 <== NOT EXECUTED 15ac: e1a00004 mov r0, r4 <== NOT EXECUTED 15b0: e1a0e00f mov lr, pc <== NOT EXECUTED 15b4: e12fff13 bx r3 <== NOT EXECUTED 15b8: e1a0000a mov r0, sl <== NOT EXECUTED 15bc: ea000002 b 15cc <== NOT EXECUTED 15c0: e3a0000d mov r0, #13 <== NOT EXECUTED 15c4: ea000000 b 15cc <== NOT EXECUTED 15c8: e3a00000 mov r0, #0 <== NOT EXECUTED return RTEMS_SUCCESSFUL; } 15cc: e28dd018 add sp, sp, #24 <== NOT EXECUTED 15d0: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED 000019ec : * * Called by BSP startup code to initialize the libio subsystem. */ void rtems_libio_init( void ) { 19ec: e92d4011 push {r0, r4, lr} rtems_status_code rc; uint32_t i; rtems_libio_t *iop; if (rtems_libio_number_iops > 0) 19f0: e59f4098 ldr r4, [pc, #152] ; 1a90 19f4: e5940000 ldr r0, [r4] 19f8: e3500000 cmp r0, #0 19fc: 0a000013 beq 1a50 { rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops, 1a00: e3a01040 mov r1, #64 ; 0x40 1a04: eb001d20 bl 8e8c 1a08: e59f3084 ldr r3, [pc, #132] ; 1a94 sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL) 1a0c: e3500000 cmp r0, #0 uint32_t i; rtems_libio_t *iop; if (rtems_libio_number_iops > 0) { rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops, 1a10: e5830000 str r0, [r3] sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL) rtems_fatal_error_occurred(RTEMS_NO_MEMORY); 1a14: 0280001a addeq r0, r0, #26 if (rtems_libio_number_iops > 0) { rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops, sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL) 1a18: 0a000015 beq 1a74 rtems_fatal_error_occurred(RTEMS_NO_MEMORY); iop = rtems_libio_iop_freelist = rtems_libio_iops; 1a1c: e59f3074 ldr r3, [pc, #116] ; 1a98 for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++) 1a20: e5941000 ldr r1, [r4] rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops, sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL) rtems_fatal_error_occurred(RTEMS_NO_MEMORY); iop = rtems_libio_iop_freelist = rtems_libio_iops; 1a24: e5830000 str r0, [r3] for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++) 1a28: e3a03000 mov r3, #0 1a2c: ea000000 b 1a34 iop->data1 = iop + 1; 1a30: e500000c str r0, [r0, #-12] sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL) rtems_fatal_error_occurred(RTEMS_NO_MEMORY); iop = rtems_libio_iop_freelist = rtems_libio_iops; for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++) 1a34: e2833001 add r3, r3, #1 1a38: e1530001 cmp r3, r1 iop->data1 = iop + 1; 1a3c: e1a02000 mov r2, r0 sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL) rtems_fatal_error_occurred(RTEMS_NO_MEMORY); iop = rtems_libio_iop_freelist = rtems_libio_iops; for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++) 1a40: e2800040 add r0, r0, #64 ; 0x40 1a44: 3afffff9 bcc 1a30 iop->data1 = iop + 1; iop->data1 = NULL; 1a48: e3a03000 mov r3, #0 1a4c: e5823034 str r3, [r2, #52] ; 0x34 /* * Create the binary semaphore used to provide mutual exclusion * on the IOP Table. */ rc = rtems_semaphore_create( 1a50: e59fc044 ldr ip, [pc, #68] ; 1a9c 1a54: e59f0044 ldr r0, [pc, #68] ; 1aa0 1a58: e3a01001 mov r1, #1 1a5c: e3a02054 mov r2, #84 ; 0x54 1a60: e3a03000 mov r3, #0 1a64: e58dc000 str ip, [sp] 1a68: eb000b6c bl 4820 1, RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &rtems_libio_semaphore ); if ( rc != RTEMS_SUCCESSFUL ) 1a6c: e3500000 cmp r0, #0 1a70: 0a000000 beq 1a78 rtems_fatal_error_occurred( rc ); 1a74: eb000d8e bl 50b4 <== NOT EXECUTED /* * Initialize the base file system infrastructure. */ if (rtems_fs_init_helper) 1a78: e59f3024 ldr r3, [pc, #36] ; 1aa4 1a7c: e5933000 ldr r3, [r3] 1a80: e3530000 cmp r3, #0 (* rtems_fs_init_helper)(); 1a84: 11a0e00f movne lr, pc 1a88: 112fff13 bxne r3 } 1a8c: e8bd8018 pop {r3, r4, pc} 1a90: 00017580 .word 0x00017580 1a94: 00018cb0 .word 0x00018cb0 1a98: 00018cb4 .word 0x00018cb4 1a9c: 00018cb8 .word 0x00018cb8 1aa0: 4c42494f .word 0x4c42494f 1aa4: 0001757c .word 0x0001757c 000231b8 : rtems_filesystem_freenode( &env->root_directory); free(env); } } rtems_status_code rtems_libio_set_private_env(void) { 231b8: e92d41f0 push {r4, r5, r6, r7, r8, lr} rtems_status_code sc; rtems_id task_id; rtems_filesystem_location_info_t loc; sc=rtems_task_ident(RTEMS_SELF,0,&task_id); 231bc: e3a00000 mov r0, #0 rtems_filesystem_freenode( &env->root_directory); free(env); } } rtems_status_code rtems_libio_set_private_env(void) { 231c0: e24dd01c sub sp, sp, #28 rtems_status_code sc; rtems_id task_id; rtems_filesystem_location_info_t loc; sc=rtems_task_ident(RTEMS_SELF,0,&task_id); 231c4: e1a01000 mov r1, r0 231c8: e28d2018 add r2, sp, #24 231cc: eb00054e bl 2470c if (sc != RTEMS_SUCCESSFUL) return sc; 231d0: e2508000 subs r8, r0, #0 231d4: 1a00003f bne 232d8 /* Only for the first time a malloc is necesary */ if (rtems_current_user_env==&rtems_global_user_env) { 231d8: e59f4104 ldr r4, [pc, #260] ; 232e4 231dc: e59f3104 ldr r3, [pc, #260] ; 232e8 231e0: e5942000 ldr r2, [r4] 231e4: e1520003 cmp r2, r3 231e8: 1a00000f bne 2322c rtems_user_env_t *tmp = malloc(sizeof(rtems_user_env_t)); 231ec: e2800048 add r0, r0, #72 ; 0x48 231f0: ebff86ff bl 4df4 if (!tmp) 231f4: e2505000 subs r5, r0, #0 231f8: 03a0801a moveq r8, #26 231fc: 0a000035 beq 232d8 #ifdef HAVE_USERENV_REFCNT tmp->refcnt = 1; #endif sc = rtems_task_variable_add(RTEMS_SELF,(void*)&rtems_current_user_env,(void(*)(void *))free_user_env,Ù 23200: e1a00008 mov r0, r8 23204: e1a01004 mov r1, r4 23208: e59f20dc ldr r2, [pc, #220] ; 232ec 2320c: eb000635 bl 24ae8 if (sc != RTEMS_SUCCESSFUL) { 23210: e2506000 subs r6, r0, #0 * not initialized yet */ free(tmp); return sc; } rtems_current_user_env = tmp; 23214: 05845000 streq r5, [r4] #ifdef HAVE_USERENV_REFCNT tmp->refcnt = 1; #endif sc = rtems_task_variable_add(RTEMS_SELF,(void*)&rtems_current_user_env,(void(*)(void *))free_user_env,Ù if (sc != RTEMS_SUCCESSFUL) { 23218: 0a000003 beq 2322c /* don't use free_user_env because the pathlocs are * not initialized yet */ free(tmp); 2321c: e1a00005 mov r0, r5 <== NOT EXECUTED 23220: ebff8583 bl 4834 <== NOT EXECUTED 23224: e1a08006 mov r8, r6 <== NOT EXECUTED return sc; 23228: ea00002a b 232d8 <== NOT EXECUTED } rtems_current_user_env = tmp; }; *rtems_current_user_env = rtems_global_user_env; /* get the global values*/ 2322c: e59f60b0 ldr r6, [pc, #176] ; 232e4 23230: e5964000 ldr r4, [r6] 23234: e59f10ac ldr r1, [pc, #172] ; 232e8 23238: e3a02048 mov r2, #72 ; 0x48 2323c: e1a00004 mov r0, r4 23240: eb00600d bl 3b27c rtems_current_user_env->task_id=task_id; /* mark the local values*/ /* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC; 23244: e59f30a4 ldr r3, [pc, #164] ; 232f0 23248: e593e000 ldr lr, [r3] } rtems_current_user_env = tmp; }; *rtems_current_user_env = rtems_global_user_env; /* get the global values*/ rtems_current_user_env->task_id=task_id; /* mark the local values*/ 2324c: e59d3018 ldr r3, [sp, #24] 23250: e1a0c004 mov ip, r4 /* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC; 23254: e28ee01c add lr, lr, #28 } rtems_current_user_env = tmp; }; *rtems_current_user_env = rtems_global_user_env; /* get the global values*/ rtems_current_user_env->task_id=task_id; /* mark the local values*/ 23258: e48c3018 str r3, [ip], #24 /* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC; 2325c: e8be000f ldm lr!, {r0, r1, r2, r3} 23260: e8ac000f stmia ip!, {r0, r1, r2, r3} 23264: e59e3000 ldr r3, [lr] * code we must _not_ free the original locs because * what we are trying to do here is forking off * clones. */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 23268: e28d4004 add r4, sp, #4 2326c: e3a05000 mov r5, #0 *rtems_current_user_env = rtems_global_user_env; /* get the global values*/ rtems_current_user_env->task_id=task_id; /* mark the local values*/ /* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC; 23270: e58c3000 str r3, [ip] * code we must _not_ free the original locs because * what we are trying to do here is forking off * clones. */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 23274: e3a01001 mov r1, #1 23278: e1a03004 mov r3, r4 2327c: e1a02005 mov r2, r5 23280: e59f006c ldr r0, [pc, #108] ; 232f4 rtems_filesystem_root = loc; 23284: e1a07004 mov r7, r4 * code we must _not_ free the original locs because * what we are trying to do here is forking off * clones. */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 23288: e58d5000 str r5, [sp] 2328c: ebff8535 bl 4768 rtems_filesystem_root = loc; 23290: e596c000 ldr ip, [r6] 23294: e8b7000f ldm r7!, {r0, r1, r2, r3} 23298: e28cc018 add ip, ip, #24 2329c: e8ac000f stmia ip!, {r0, r1, r2, r3} 232a0: e5973000 ldr r3, [r7] rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 232a4: e1a02005 mov r2, r5 * what we are trying to do here is forking off * clones. */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); rtems_filesystem_root = loc; 232a8: e58c3000 str r3, [ip] rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0); 232ac: e3a01001 mov r1, #1 232b0: e1a03004 mov r3, r4 232b4: e59f0038 ldr r0, [pc, #56] ; 232f4 232b8: e58d5000 str r5, [sp] 232bc: ebff8529 bl 4768 rtems_filesystem_current = loc; 232c0: e596c000 ldr ip, [r6] 232c4: e8b4000f ldm r4!, {r0, r1, r2, r3} 232c8: e28cc004 add ip, ip, #4 232cc: e8ac000f stmia ip!, {r0, r1, r2, r3} 232d0: e5973000 ldr r3, [r7] 232d4: e58c3000 str r3, [ip] return RTEMS_SUCCESSFUL; } 232d8: e1a00008 mov r0, r8 232dc: e28dd01c add sp, sp, #28 232e0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 232e4: 00052578 .word 0x00052578 232e8: 0005fc2c .word 0x0005fc2c 232ec: 000230b0 .word 0x000230b0 232f0: 0005fc14 .word 0x0005fc14 232f4: 000569de .word 0x000569de 00023114 : * b) mutex access to rtems_filesystem_current, rtems_filesytem_root * while changing any of those (chdir(), chroot()). */ #ifndef HAVE_USERENV_REFCNT rtems_status_code rtems_libio_share_private_env(rtems_id task_id) { 23114: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED 23118: e1a05000 mov r5, r0 <== NOT EXECUTED rtems_status_code sc; rtems_user_env_t * shared_user_env; rtems_id current_task_id; sc=rtems_task_ident(RTEMS_SELF,0,¤t_task_id); 2311c: e3a00000 mov r0, #0 <== NOT EXECUTED 23120: e1a01000 mov r1, r0 <== NOT EXECUTED 23124: e1a0200d mov r2, sp <== NOT EXECUTED 23128: eb000577 bl 2470c <== NOT EXECUTED if (sc != RTEMS_SUCCESSFUL) return sc; 2312c: e2503000 subs r3, r0, #0 <== NOT EXECUTED 23130: 1a00001b bne 231a4 <== NOT EXECUTED if (rtems_current_user_env->task_id==current_task_id) { 23134: e59f1070 ldr r1, [pc, #112] ; 231ac <== NOT EXECUTED 23138: e5914000 ldr r4, [r1] <== NOT EXECUTED 2313c: e59d3000 ldr r3, [sp] <== NOT EXECUTED 23140: e5942000 ldr r2, [r4] <== NOT EXECUTED 23144: e1520003 cmp r2, r3 <== NOT EXECUTED 23148: 1a000004 bne 23160 <== NOT EXECUTED /* kill the current user env & task_var*/ rtems_user_env_t *tmp = rtems_current_user_env; sc = rtems_task_variable_delete(RTEMS_SELF,(void*)&rtems_current_user_env); 2314c: eb00068e bl 24b8c <== NOT EXECUTED if (sc != RTEMS_SUCCESSFUL) return sc; 23150: e2503000 subs r3, r0, #0 <== NOT EXECUTED 23154: 1a000012 bne 231a4 <== NOT EXECUTED free_user_env(tmp); 23158: e1a00004 mov r0, r4 <== NOT EXECUTED 2315c: ebffffd3 bl 230b0 <== NOT EXECUTED }; /* AT THIS POINT, rtems_current_user_env is DANGLING */ sc = rtems_task_variable_get(task_id,(void*)&rtems_current_user_env, 23160: e59f4044 ldr r4, [pc, #68] ; 231ac <== NOT EXECUTED 23164: e1a00005 mov r0, r5 <== NOT EXECUTED 23168: e1a01004 mov r1, r4 <== NOT EXECUTED 2316c: e28d2004 add r2, sp, #4 <== NOT EXECUTED 23170: eb0006a2 bl 24c00 <== NOT EXECUTED (void*)&shared_user_env ); if (sc != RTEMS_SUCCESSFUL) 23174: e2503000 subs r3, r0, #0 <== NOT EXECUTED 23178: 1a000006 bne 23198 <== NOT EXECUTED goto bailout; sc = rtems_task_variable_add(RTEMS_SELF,(void*)&rtems_current_user_env,free_user_env); 2317c: e59f202c ldr r2, [pc, #44] ; 231b0 <== NOT EXECUTED 23180: e1a01004 mov r1, r4 <== NOT EXECUTED 23184: eb000657 bl 24ae8 <== NOT EXECUTED if (sc != RTEMS_SUCCESSFUL) 23188: e2503000 subs r3, r0, #0 <== NOT EXECUTED goto bailout; /* the current_user_env is the same pointer that remote env */ rtems_current_user_env = shared_user_env; 2318c: 059d2004 ldreq r2, [sp, #4] <== NOT EXECUTED 23190: 05842000 streq r2, [r4] <== NOT EXECUTED (void*)&shared_user_env ); if (sc != RTEMS_SUCCESSFUL) goto bailout; sc = rtems_task_variable_add(RTEMS_SELF,(void*)&rtems_current_user_env,free_user_env); if (sc != RTEMS_SUCCESSFUL) 23194: 0a000002 beq 231a4 <== NOT EXECUTED return RTEMS_SUCCESSFUL; bailout: /* fallback to the global env */ rtems_current_user_env = &rtems_global_user_env; 23198: e59f1014 ldr r1, [pc, #20] ; 231b4 <== NOT EXECUTED 2319c: e59f2008 ldr r2, [pc, #8] ; 231ac <== NOT EXECUTED 231a0: e5821000 str r1, [r2] <== NOT EXECUTED return sc; } 231a4: e1a00003 mov r0, r3 <== NOT EXECUTED 231a8: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED 231ac: 00052578 .word 0x00052578 231b0: 000230b0 .word 0x000230b0 231b4: 0005fc2c .word 0x0005fc2c 00004eec : * size and thus we skip updating the statistics. */ static void rtems_malloc_statistics_at_free( void *pointer ) { 4eec: e92d4801 push {r0, fp, lr} <== NOT EXECUTED uintptr_t size; if (_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &size) ) { 4ef0: e59f3038 ldr r3, [pc, #56] ; 4f30 <== NOT EXECUTED * size and thus we skip updating the statistics. */ static void rtems_malloc_statistics_at_free( void *pointer ) { 4ef4: e1a01000 mov r1, r0 <== NOT EXECUTED uintptr_t size; if (_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &size) ) { 4ef8: e1a0200d mov r2, sp <== NOT EXECUTED 4efc: e5930000 ldr r0, [r3] <== NOT EXECUTED 4f00: eb00140f bl 9f44 <_Protected_heap_Get_block_size> <== NOT EXECUTED 4f04: e3500000 cmp r0, #0 <== NOT EXECUTED 4f08: 0a000007 beq 4f2c <== NOT EXECUTED MSBUMP(lifetime_freed, size); 4f0c: e59f3020 ldr r3, [pc, #32] ; 4f34 <== NOT EXECUTED 4f10: e59d0000 ldr r0, [sp] <== NOT EXECUTED 4f14: e283c024 add ip, r3, #36 ; 0x24 <== NOT EXECUTED 4f18: e89c1800 ldm ip, {fp, ip} <== NOT EXECUTED 4f1c: e09b1000 adds r1, fp, r0 <== NOT EXECUTED 4f20: e2ac2000 adc r2, ip, #0 <== NOT EXECUTED 4f24: e5831024 str r1, [r3, #36] ; 0x24 <== NOT EXECUTED 4f28: e5832028 str r2, [r3, #40] ; 0x28 <== NOT EXECUTED } } 4f2c: e8bd8808 pop {r3, fp, pc} <== NOT EXECUTED 4f30: 000522ac .word 0x000522ac 4f34: 0005fbe8 .word 0x0005fbe8 00004f38 : { uintptr_t actual_size = 0; uint32_t current_depth; rtems_malloc_statistics_t *s = &rtems_malloc_statistics; if ( !pointer ) 4f38: e2501000 subs r1, r0, #0 <== NOT EXECUTED } static void rtems_malloc_statistics_at_malloc( void *pointer ) { 4f3c: e92d4811 push {r0, r4, fp, lr} <== NOT EXECUTED uintptr_t actual_size = 0; uint32_t current_depth; rtems_malloc_statistics_t *s = &rtems_malloc_statistics; if ( !pointer ) 4f40: 0a000013 beq 4f94 <== NOT EXECUTED static void rtems_malloc_statistics_at_malloc( void *pointer ) { uintptr_t actual_size = 0; 4f44: e28d2004 add r2, sp, #4 <== NOT EXECUTED 4f48: e3a03000 mov r3, #0 <== NOT EXECUTED 4f4c: e5223004 str r3, [r2, #-4]! <== NOT EXECUTED rtems_malloc_statistics_t *s = &rtems_malloc_statistics; if ( !pointer ) return; _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size); 4f50: e59f3040 ldr r3, [pc, #64] ; 4f98 <== NOT EXECUTED 4f54: e1a0200d mov r2, sp <== NOT EXECUTED 4f58: e5930000 ldr r0, [r3] <== NOT EXECUTED 4f5c: eb0013f8 bl 9f44 <_Protected_heap_Get_block_size> <== NOT EXECUTED MSBUMP(lifetime_allocated, actual_size); 4f60: e59f3034 ldr r3, [pc, #52] ; 4f9c <== NOT EXECUTED 4f64: e59d4000 ldr r4, [sp] <== NOT EXECUTED 4f68: e283c01c add ip, r3, #28 <== NOT EXECUTED 4f6c: e89c1800 ldm ip, {fp, ip} <== NOT EXECUTED current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed); 4f70: e5932024 ldr r2, [r3, #36] ; 0x24 <== NOT EXECUTED if ( !pointer ) return; _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size); MSBUMP(lifetime_allocated, actual_size); 4f74: e09b0004 adds r0, fp, r4 <== NOT EXECUTED 4f78: e2ac1000 adc r1, ip, #0 <== NOT EXECUTED current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed); if (current_depth > s->max_depth) 4f7c: e593c018 ldr ip, [r3, #24] <== NOT EXECUTED _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size); MSBUMP(lifetime_allocated, actual_size); current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed); 4f80: e0622000 rsb r2, r2, r0 <== NOT EXECUTED if (current_depth > s->max_depth) 4f84: e152000c cmp r2, ip <== NOT EXECUTED if ( !pointer ) return; _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size); MSBUMP(lifetime_allocated, actual_size); 4f88: e583001c str r0, [r3, #28] <== NOT EXECUTED 4f8c: e5831020 str r1, [r3, #32] <== NOT EXECUTED current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed); if (current_depth > s->max_depth) s->max_depth = current_depth; 4f90: 85832018 strhi r2, [r3, #24] <== NOT EXECUTED } 4f94: e8bd8818 pop {r3, r4, fp, pc} <== NOT EXECUTED 4f98: 000522ac .word 0x000522ac 4f9c: 0005fbe8 .word 0x0005fbe8 00004fa0 : static void rtems_malloc_statistics_initialize( void ) { /* * Zero all the statistics */ (void) memset(&rtems_malloc_statistics, 0, sizeof(rtems_malloc_statistics)); 4fa0: e59f0008 ldr r0, [pc, #8] ; 4fb0 <== NOT EXECUTED 4fa4: e3a01000 mov r1, #0 <== NOT EXECUTED 4fa8: e3a0202c mov r2, #44 ; 0x2c <== NOT EXECUTED 4fac: ea00d939 b 3b498 <== NOT EXECUTED 4fb0: 0005fbe8 .word 0x0005fbe8 000064d0 : void rtems_panic( const char *printf_format, ... ) { 64d0: e92d000f push {r0, r1, r2, r3} <== NOT EXECUTED 64d4: e92d4001 push {r0, lr} <== NOT EXECUTED va_list arglist; va_start(arglist, printf_format); 64d8: e28d300c add r3, sp, #12 <== NOT EXECUTED (void) rtems_verror(RTEMS_ERROR_PANIC, printf_format, arglist); 64dc: e1a02003 mov r2, r3 <== NOT EXECUTED 64e0: e59d1008 ldr r1, [sp, #8] <== NOT EXECUTED 64e4: e3a00202 mov r0, #536870912 ; 0x20000000 <== NOT EXECUTED ... ) { va_list arglist; va_start(arglist, printf_format); 64e8: e58d3000 str r3, [sp] <== NOT EXECUTED (void) rtems_verror(RTEMS_ERROR_PANIC, printf_format, arglist); 64ec: ebffff8e bl 632c <== NOT EXECUTED va_end(arglist); } 64f0: e8bd4008 pop {r3, lr} <== NOT EXECUTED 64f4: e28dd010 add sp, sp, #16 <== NOT EXECUTED 64f8: e12fff1e bx lr <== NOT EXECUTED 0000a474 : /* * Initialization of FIFO/pipe module. */ void rtems_pipe_initialize (void) { if (!rtems_pipe_configured) a474: e59f3048 ldr r3, [pc, #72] ; a4c4 a478: e5d33000 ldrb r3, [r3] a47c: e3530000 cmp r3, #0 /* * Initialization of FIFO/pipe module. */ void rtems_pipe_initialize (void) { a480: e92d4001 push {r0, lr} if (!rtems_pipe_configured) a484: 0a00000d beq a4c0 return; if (rtems_pipe_semaphore) a488: e59fc038 ldr ip, [pc, #56] ; a4c8 <== NOT EXECUTED a48c: e59c3000 ldr r3, [ip] <== NOT EXECUTED a490: e3530000 cmp r3, #0 <== NOT EXECUTED a494: 1a000009 bne a4c0 <== NOT EXECUTED return; rtems_status_code sc; sc = rtems_semaphore_create( a498: e59f002c ldr r0, [pc, #44] ; a4cc <== NOT EXECUTED a49c: e3a01001 mov r1, #1 <== NOT EXECUTED a4a0: e3a02054 mov r2, #84 ; 0x54 <== NOT EXECUTED a4a4: e58dc000 str ip, [sp] <== NOT EXECUTED a4a8: ebffe8dc bl 4820 <== NOT EXECUTED rtems_build_name ('P', 'I', 'P', 'E'), 1, RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &rtems_pipe_semaphore); if (sc != RTEMS_SUCCESSFUL) a4ac: e3500000 cmp r0, #0 <== NOT EXECUTED rtems_fatal_error_occurred (sc); a4b0: 1bffeaff blne 50b4 <== NOT EXECUTED rtems_interval now; now = rtems_clock_get_ticks_since_boot(); a4b4: ebffe7de bl 4434 <== NOT EXECUTED rtems_pipe_no = now; a4b8: e59f3010 ldr r3, [pc, #16] ; a4d0 <== NOT EXECUTED a4bc: e1c300b0 strh r0, [r3] <== NOT EXECUTED } a4c0: e8bd8008 pop {r3, pc} a4c4: 000189a4 .word 0x000189a4 a4c8: 00018acc .word 0x00018acc a4cc: 50495045 .word 0x50495045 a4d0: 00018ad2 .word 0x00018ad2 00003014 : /* * Check if blown */ bool rtems_stack_checker_is_blown( void ) { 3014: e92d4810 push {r4, fp, lr} Stack_Control *the_stack = &_Thread_Executing->Start.Initial_stack; 3018: e59f307c ldr r3, [pc, #124] ; 309c 301c: e5933000 ldr r3, [r3] ) { #if defined(__GNUC__) void *sp = __builtin_frame_address(0); if ( sp < the_stack->area ) { 3020: e59300c4 ldr r0, [r3, #196] ; 0xc4 /* * Check if blown */ bool rtems_stack_checker_is_blown( void ) { 3024: e28db008 add fp, sp, #8 ) { #if defined(__GNUC__) void *sp = __builtin_frame_address(0); if ( sp < the_stack->area ) { 3028: e15b0000 cmp fp, r0 302c: 33a04000 movcc r4, #0 3030: 3a000004 bcc 3048 } /* * Check if blown */ bool rtems_stack_checker_is_blown( void ) 3034: e59340c0 ldr r4, [r3, #192] ; 0xc0 3038: e0804004 add r4, r0, r4 303c: e15b0004 cmp fp, r4 3040: 83a04000 movhi r4, #0 3044: 93a04001 movls r4, #1 /* * The stack checker must be initialized before the pattern is there * to check. */ if ( Stack_check_Initialized ) { 3048: e59f3050 ldr r3, [pc, #80] ; 30a0 304c: e5933000 ldr r3, [r3] 3050: e3530000 cmp r3, #0 3054: 03a01001 moveq r1, #1 3058: 0a000005 beq 3074 pattern_ok = (!memcmp( 305c: e59f1040 ldr r1, [pc, #64] ; 30a4 3060: e2800008 add r0, r0, #8 3064: e3a02010 mov r2, #16 3068: eb00e059 bl 3b1d4 306c: e2701001 rsbs r1, r0, #1 3070: 33a01000 movcc r1, #0 } /* * The Stack Pointer and the Pattern Area are OK so return false. */ if ( sp_ok && pattern_ok ) 3074: e3540000 cmp r4, #0 3078: 0a000002 beq 3088 307c: e3510000 cmp r1, #0 3080: 13a00000 movne r0, #0 3084: 18bd8810 popne {r4, fp, pc} return false; /* * Let's report as much as we can. */ Stack_check_report_blown_task( _Thread_Executing, pattern_ok ); 3088: e59f300c ldr r3, [pc, #12] ; 309c <== NOT EXECUTED 308c: e5930000 ldr r0, [r3] <== NOT EXECUTED 3090: ebffffb4 bl 2f68 <== NOT EXECUTED 3094: e3a00001 mov r0, #1 <== NOT EXECUTED return true; } 3098: e8bd8810 pop {r4, fp, pc} <== NOT EXECUTED 309c: 0005fe00 .word 0x0005fe00 30a0: 0005cf7c .word 0x0005cf7c 30a4: 0005fbb8 .word 0x0005fbb8 00002f58 : void rtems_stack_checker_report_usage( void ) { rtems_stack_checker_report_usage_with_plugin( NULL, printk_plugin ); 2f58: e59f1004 ldr r1, [pc, #4] ; 2f64 <== NOT EXECUTED 2f5c: e3a00000 mov r0, #0 <== NOT EXECUTED 2f60: eaffffe3 b 2ef4 <== NOT EXECUTED 2f64: 00005930 .word 0x00005930 00002ef4 : void rtems_stack_checker_report_usage_with_plugin( void *context, rtems_printk_plugin_t print ) { 2ef4: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED print_context = context; 2ef8: e59f4048 ldr r4, [pc, #72] ; 2f48 <== NOT EXECUTED void rtems_stack_checker_report_usage_with_plugin( void *context, rtems_printk_plugin_t print ) { 2efc: e1a05001 mov r5, r1 <== NOT EXECUTED 2f00: e1a06000 mov r6, r0 <== NOT EXECUTED print_context = context; print_handler = print; 2f04: e5841004 str r1, [r4, #4] <== NOT EXECUTED void rtems_stack_checker_report_usage_with_plugin( void *context, rtems_printk_plugin_t print ) { print_context = context; 2f08: e5840008 str r0, [r4, #8] <== NOT EXECUTED print_handler = print; (*print)( context, "Stack usage by thread\n"); 2f0c: e59f1038 ldr r1, [pc, #56] ; 2f4c <== NOT EXECUTED 2f10: e1a0e00f mov lr, pc <== NOT EXECUTED 2f14: e12fff15 bx r5 <== NOT EXECUTED (*print)( context, 2f18: e59f1030 ldr r1, [pc, #48] ; 2f50 <== NOT EXECUTED 2f1c: e1a00006 mov r0, r6 <== NOT EXECUTED 2f20: e1a0e00f mov lr, pc <== NOT EXECUTED 2f24: e12fff15 bx r5 <== NOT EXECUTED " ID NAME LOW HIGH CURRENT AVAILABLE USED\n" ); /* iterate over all threads and dump the usage */ rtems_iterate_over_all_threads( Stack_check_Dump_threads_usage ); 2f28: e59f0024 ldr r0, [pc, #36] ; 2f54 <== NOT EXECUTED 2f2c: eb0019fd bl 9728 <== NOT EXECUTED /* dump interrupt stack info if any */ Stack_check_Dump_threads_usage((Thread_Control *) -1); 2f30: e3e00000 mvn r0, #0 <== NOT EXECUTED 2f34: ebffff9f bl 2db8 <== NOT EXECUTED print_context = NULL; 2f38: e3a03000 mov r3, #0 <== NOT EXECUTED print_handler = NULL; 2f3c: e5843004 str r3, [r4, #4] <== NOT EXECUTED rtems_iterate_over_all_threads( Stack_check_Dump_threads_usage ); /* dump interrupt stack info if any */ Stack_check_Dump_threads_usage((Thread_Control *) -1); print_context = NULL; 2f40: e5843008 str r3, [r4, #8] <== NOT EXECUTED print_handler = NULL; } 2f44: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED 2f48: 0005cf7c .word 0x0005cf7c 2f4c: 00056820 .word 0x00056820 2f50: 00056837 .word 0x00056837 2f54: 00002db8 .word 0x00002db8 00018dec : #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) { 18dec: e92d40f1 push {r0, r4, r5, r6, r7, lr} STRING_TO_INPUT_TYPE result; char *end; if ( !n ) 18df0: e2514000 subs r4, r1, #0 #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) { 18df4: e1a05000 mov r5, r0 18df8: e1a06002 mov r6, r2 STRING_TO_INPUT_TYPE result; char *end; if ( !n ) 18dfc: 03a00009 moveq r0, #9 18e00: 0a000018 beq 18e68 return RTEMS_INVALID_ADDRESS; errno = 0; 18e04: eb007ceb bl 381b8 <__errno> 18e08: e3a03000 mov r3, #0 18e0c: e5803000 str r3, [r0] *n = 0; 18e10: e5843000 str r3, [r4] #ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); 18e14: e1a00005 mov r0, r5 18e18: e1a0100d mov r1, sp 18e1c: e3a02010 mov r2, #16 18e20: eb009c7a bl 40010 #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base ); #endif /* If the user wants the end pointer back, then return it. */ if ( endptr ) 18e24: e3560000 cmp r6, #0 *endptr = end; 18e28: 159d3000 ldrne r3, [sp] 18e2c: 15863000 strne r3, [r6] /* nothing was converted */ if ( end == s ) 18e30: e59d3000 ldr r3, [sp] 18e34: e1530005 cmp r3, r5 *n = 0; #ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); 18e38: e1a07000 mov r7, r0 /* If the user wants the end pointer back, then return it. */ if ( endptr ) *endptr = end; /* nothing was converted */ if ( end == s ) 18e3c: 03a0000b moveq r0, #11 18e40: 0a000008 beq 18e68 return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE)) 18e44: e3770001 cmn r7, #1 18e48: 1a000004 bne 18e60 18e4c: eb007cd9 bl 381b8 <__errno> <== NOT EXECUTED 18e50: e5903000 ldr r3, [r0] <== NOT EXECUTED 18e54: e3530022 cmp r3, #34 ; 0x22 <== NOT EXECUTED 18e58: 03a0000a moveq r0, #10 <== NOT EXECUTED 18e5c: 0a000001 beq 18e68 <== NOT EXECUTED if ( (result == STRING_TO_MIN) && (errno == ERANGE)) return RTEMS_INVALID_NUMBER; #endif #if defined(STRING_TO_POINTER) *n = (STRING_TO_TYPE) (uintptr_t)result; 18e60: e5847000 str r7, [r4] 18e64: e3a00000 mov r0, #0 #else *n = (STRING_TO_TYPE) result; #endif return RTEMS_SUCCESSFUL; } 18e68: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} 00003b58 : rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) { 3b58: e3500009 cmp r0, #9 3b5c: 012fff1e bxeq lr 3b60: ca000016 bgt 3bc0 3b64: e3500004 cmp r0, #4 3b68: 012fff1e bxeq lr 3b6c: ca00000a bgt 3b9c 3b70: e3500001 cmp r0, #1 3b74: 012fff1e bxeq lr 3b78: ca000002 bgt 3b88 3b7c: e3500000 cmp r0, #0 3b80: 012fff1e bxeq lr 3b84: ea000030 b 3c4c 3b88: e3500002 cmp r0, #2 <== NOT EXECUTED 3b8c: 012fff1e bxeq lr <== NOT EXECUTED 3b90: e3500003 cmp r0, #3 <== NOT EXECUTED 3b94: 1a00002c bne 3c4c <== NOT EXECUTED 3b98: e12fff1e bx lr <== NOT EXECUTED 3b9c: e3500006 cmp r0, #6 <== NOT EXECUTED 3ba0: 012fff1e bxeq lr <== NOT EXECUTED case B0: baud_index = 0; break; case B50: baud_index = 1; break; case B75: baud_index = 2; break; case B110: baud_index = 3; break; case B134: baud_index = 4; break; 3ba4: b3a00005 movlt r0, #5 <== NOT EXECUTED rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) { 3ba8: b12fff1e bxlt lr <== NOT EXECUTED 3bac: e3500007 cmp r0, #7 <== NOT EXECUTED 3bb0: 012fff1e bxeq lr <== NOT EXECUTED 3bb4: e3500008 cmp r0, #8 <== NOT EXECUTED 3bb8: 1a000023 bne 3c4c <== NOT EXECUTED 3bbc: e12fff1e bx lr <== NOT EXECUTED 3bc0: e350000e cmp r0, #14 <== NOT EXECUTED 3bc4: 012fff1e bxeq lr <== NOT EXECUTED 3bc8: ca000008 bgt 3bf0 <== NOT EXECUTED 3bcc: e350000b cmp r0, #11 <== NOT EXECUTED 3bd0: 012fff1e bxeq lr <== NOT EXECUTED case B134: baud_index = 4; break; case B150: baud_index = 5; break; case B200: baud_index = 6; break; case B300: baud_index = 7; break; case B600: baud_index = 8; break; case B1200: baud_index = 9; break; 3bd4: b3a0000a movlt r0, #10 <== NOT EXECUTED rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) { 3bd8: b12fff1e bxlt lr <== NOT EXECUTED 3bdc: e350000c cmp r0, #12 <== NOT EXECUTED 3be0: 012fff1e bxeq lr <== NOT EXECUTED 3be4: e350000d cmp r0, #13 <== NOT EXECUTED 3be8: 1a000017 bne 3c4c <== NOT EXECUTED 3bec: e12fff1e bx lr <== NOT EXECUTED 3bf0: e59f305c ldr r3, [pc, #92] ; 3c54 <== NOT EXECUTED 3bf4: e1500003 cmp r0, r3 <== NOT EXECUTED case B2400: baud_index = 11; break; case B4800: baud_index = 12; break; case B9600: baud_index = 13; break; case B19200: baud_index = 14; break; case B38400: baud_index = 15; break; case B57600: baud_index = 16; break; 3bf8: 03a00011 moveq r0, #17 <== NOT EXECUTED rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) { 3bfc: 012fff1e bxeq lr <== NOT EXECUTED 3c00: ca000005 bgt 3c1c <== NOT EXECUTED 3c04: e350000f cmp r0, #15 <== NOT EXECUTED 3c08: 012fff1e bxeq lr <== NOT EXECUTED 3c0c: e2433001 sub r3, r3, #1 <== NOT EXECUTED 3c10: e1500003 cmp r0, r3 <== NOT EXECUTED 3c14: 1a00000c bne 3c4c <== NOT EXECUTED 3c18: ea000007 b 3c3c <== NOT EXECUTED 3c1c: e59f3034 ldr r3, [pc, #52] ; 3c58 <== NOT EXECUTED 3c20: e1500003 cmp r0, r3 <== NOT EXECUTED case B4800: baud_index = 12; break; case B9600: baud_index = 13; break; case B19200: baud_index = 14; break; case B38400: baud_index = 15; break; case B57600: baud_index = 16; break; case B115200: baud_index = 17; break; 3c24: 03a00012 moveq r0, #18 <== NOT EXECUTED rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) { 3c28: 012fff1e bxeq lr <== NOT EXECUTED 3c2c: e2833001 add r3, r3, #1 <== NOT EXECUTED 3c30: e1500003 cmp r0, r3 <== NOT EXECUTED 3c34: 1a000004 bne 3c4c <== NOT EXECUTED 3c38: ea000001 b 3c44 <== NOT EXECUTED case B1800: baud_index = 10; break; case B2400: baud_index = 11; break; case B4800: baud_index = 12; break; case B9600: baud_index = 13; break; case B19200: baud_index = 14; break; case B38400: baud_index = 15; break; 3c3c: e3a00010 mov r0, #16 <== NOT EXECUTED case B57600: baud_index = 16; break; 3c40: e12fff1e bx lr <== NOT EXECUTED case B115200: baud_index = 17; break; case B230400: baud_index = 18; break; 3c44: e3a00013 mov r0, #19 <== NOT EXECUTED case B460800: baud_index = 19; break; 3c48: e12fff1e bx lr <== NOT EXECUTED 3c4c: e3e00000 mvn r0, #0 default: baud_index = -1; break; } return baud_index; } 3c50: e12fff1e bx lr 3c54: 00001002 .word 0x00001002 3c58: 00001003 .word 0x00001003 000026c0 : int cbufsize, int raw_input, int raw_output ) { rtems_termios_cbufsize = cbufsize; 26c0: e59f3008 ldr r3, [pc, #8] ; 26d0 <== NOT EXECUTED 26c4: e8830007 stm r3, {r0, r1, r2} <== NOT EXECUTED rtems_termios_raw_input_size = raw_input; rtems_termios_raw_output_size = raw_output; return RTEMS_SUCCESSFUL; } 26c8: e3a00000 mov r0, #0 <== NOT EXECUTED 26cc: e12fff1e bx lr <== NOT EXECUTED 26d0: 00017704 .word 0x00017704 00003acc : { rtems_libio_open_close_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; rtems_status_code sc; sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 3acc: e59f2180 ldr r2, [pc, #384] ; 3c54 rtems_status_code rtems_termios_close (void *arg) { rtems_libio_open_close_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; 3ad0: e5903000 ldr r3, [r0] rtems_status_code sc; sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 3ad4: e3a01000 mov r1, #0 } } rtems_status_code rtems_termios_close (void *arg) { 3ad8: e92d4030 push {r4, r5, lr} 3adc: e1a05000 mov r5, r0 rtems_libio_open_close_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; rtems_status_code sc; sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 3ae0: e5920000 ldr r0, [r2] 3ae4: e1a02001 mov r2, r1 rtems_status_code rtems_termios_close (void *arg) { rtems_libio_open_close_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; 3ae8: e5934034 ldr r4, [r3, #52] ; 0x34 rtems_status_code sc; sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 3aec: eb0003dd bl 4a68 if (sc != RTEMS_SUCCESSFUL) 3af0: e3500000 cmp r0, #0 3af4: 1a000022 bne 3b84 rtems_fatal_error_occurred (sc); if (--tty->refcount == 0) { 3af8: e5943008 ldr r3, [r4, #8] 3afc: e2433001 sub r3, r3, #1 3b00: e3530000 cmp r3, #0 3b04: e5843008 str r3, [r4, #8] 3b08: 1a00004c bne 3c40 if (rtems_termios_linesw[tty->t_line].l_close != NULL) { 3b0c: e59420cc ldr r2, [r4, #204] ; 0xcc 3b10: e59f3140 ldr r3, [pc, #320] ; 3c58 3b14: e0833282 add r3, r3, r2, lsl #5 3b18: e5931004 ldr r1, [r3, #4] 3b1c: e3510000 cmp r1, #0 3b20: 0a000003 beq 3b34 /* * call discipline-specific close */ sc = rtems_termios_linesw[tty->t_line].l_close(tty); 3b24: e1a00004 mov r0, r4 <== NOT EXECUTED 3b28: e1a0e00f mov lr, pc <== NOT EXECUTED 3b2c: e12fff11 bx r1 <== NOT EXECUTED 3b30: ea000006 b 3b50 <== NOT EXECUTED } else { /* * default: just flush output buffer */ sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 3b34: e5940018 ldr r0, [r4, #24] 3b38: e1a02001 mov r2, r1 3b3c: eb0003c9 bl 4a68 if (sc != RTEMS_SUCCESSFUL) { 3b40: e3500000 cmp r0, #0 3b44: 1a00000e bne 3b84 rtems_fatal_error_occurred (sc); } drainOutput (tty); 3b48: e1a00004 mov r0, r4 3b4c: ebfffe05 bl 3368 } if (tty->device.outputUsesInterrupts 3b50: e59430b4 ldr r3, [r4, #180] ; 0xb4 3b54: e3530002 cmp r3, #2 3b58: 1a00000a bne 3b88 == TERMIOS_TASK_DRIVEN) { /* * send "terminate" to I/O tasks */ sc = rtems_event_send( 3b5c: e59400c4 ldr r0, [r4, #196] ; 0xc4 <== NOT EXECUTED 3b60: e3a01001 mov r1, #1 <== NOT EXECUTED 3b64: eb0002ab bl 4618 <== NOT EXECUTED tty->rxTaskId, TERMIOS_RX_TERMINATE_EVENT); if (sc != RTEMS_SUCCESSFUL) 3b68: e3500000 cmp r0, #0 <== NOT EXECUTED 3b6c: 1a000004 bne 3b84 <== NOT EXECUTED rtems_fatal_error_occurred (sc); sc = rtems_event_send( 3b70: e59400c8 ldr r0, [r4, #200] ; 0xc8 <== NOT EXECUTED 3b74: e3a01001 mov r1, #1 <== NOT EXECUTED 3b78: eb0002a6 bl 4618 <== NOT EXECUTED tty->txTaskId, TERMIOS_TX_TERMINATE_EVENT); if (sc != RTEMS_SUCCESSFUL) 3b7c: e3500000 cmp r0, #0 <== NOT EXECUTED 3b80: 0a000000 beq 3b88 <== NOT EXECUTED rtems_fatal_error_occurred (sc); 3b84: eb00054a bl 50b4 <== NOT EXECUTED } if (tty->device.lastClose) 3b88: e594309c ldr r3, [r4, #156] ; 0x9c 3b8c: e3530000 cmp r3, #0 (*tty->device.lastClose)(tty->major, tty->minor, arg); 3b90: 11a02005 movne r2, r5 3b94: 1284000c addne r0, r4, #12 3b98: 18900003 ldmne r0, {r0, r1} 3b9c: 11a0e00f movne lr, pc 3ba0: 112fff13 bxne r3 if (tty->forw == NULL) { 3ba4: e894000c ldm r4, {r2, r3} 3ba8: e3520000 cmp r2, #0 if ( rtems_termios_ttyTail != NULL ) { rtems_termios_ttyTail->forw = NULL; } } else { tty->forw->back = tty->back; 3bac: 15823004 strne r3, [r2, #4] if (sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred (sc); } if (tty->device.lastClose) (*tty->device.lastClose)(tty->major, tty->minor, arg); if (tty->forw == NULL) { 3bb0: 1a000003 bne 3bc4 rtems_termios_ttyTail = tty->back; 3bb4: e59f10a0 ldr r1, [pc, #160] ; 3c5c if ( rtems_termios_ttyTail != NULL ) { 3bb8: e3530000 cmp r3, #0 rtems_fatal_error_occurred (sc); } if (tty->device.lastClose) (*tty->device.lastClose)(tty->major, tty->minor, arg); if (tty->forw == NULL) { rtems_termios_ttyTail = tty->back; 3bbc: e5813000 str r3, [r1] if ( rtems_termios_ttyTail != NULL ) { rtems_termios_ttyTail->forw = NULL; 3bc0: 15832000 strne r2, [r3] } } else { tty->forw->back = tty->back; } if (tty->back == NULL) { 3bc4: e5942004 ldr r2, [r4, #4] 3bc8: e5943000 ldr r3, [r4] 3bcc: e3520000 cmp r2, #0 if ( rtems_termios_ttyHead != NULL ) { rtems_termios_ttyHead->back = NULL; } } else { tty->back->forw = tty->forw; 3bd0: 15823000 strne r3, [r2] } } else { tty->forw->back = tty->back; } if (tty->back == NULL) { 3bd4: 1a000003 bne 3be8 rtems_termios_ttyHead = tty->forw; 3bd8: e59f1080 ldr r1, [pc, #128] ; 3c60 if ( rtems_termios_ttyHead != NULL ) { 3bdc: e3530000 cmp r3, #0 } else { tty->forw->back = tty->back; } if (tty->back == NULL) { rtems_termios_ttyHead = tty->forw; 3be0: e5813000 str r3, [r1] if ( rtems_termios_ttyHead != NULL ) { rtems_termios_ttyHead->back = NULL; 3be4: 15832004 strne r2, [r3, #4] } } else { tty->back->forw = tty->forw; } rtems_semaphore_delete (tty->isem); 3be8: e5940014 ldr r0, [r4, #20] 3bec: eb000376 bl 49cc rtems_semaphore_delete (tty->osem); 3bf0: e5940018 ldr r0, [r4, #24] 3bf4: eb000374 bl 49cc rtems_semaphore_delete (tty->rawOutBuf.Semaphore); 3bf8: e594008c ldr r0, [r4, #140] ; 0x8c 3bfc: eb000372 bl 49cc if ((tty->device.pollRead == NULL) || 3c00: e59430a0 ldr r3, [r4, #160] ; 0xa0 3c04: e3530000 cmp r3, #0 3c08: 0a000002 beq 3c18 (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN)) 3c0c: e59430b4 ldr r3, [r4, #180] ; 0xb4 3c10: e3530002 cmp r3, #2 3c14: 1a000001 bne 3c20 rtems_semaphore_delete (tty->rawInBuf.Semaphore); 3c18: e5940068 ldr r0, [r4, #104] ; 0x68 <== NOT EXECUTED 3c1c: eb00036a bl 49cc <== NOT EXECUTED free (tty->rawInBuf.theBuf); 3c20: e5940058 ldr r0, [r4, #88] ; 0x58 3c24: ebfff747 bl 1948 free (tty->rawOutBuf.theBuf); 3c28: e594007c ldr r0, [r4, #124] ; 0x7c 3c2c: ebfff745 bl 1948 free (tty->cbuf); 3c30: e594001c ldr r0, [r4, #28] 3c34: ebfff743 bl 1948 free (tty); 3c38: e1a00004 mov r0, r4 3c3c: ebfff741 bl 1948 } rtems_semaphore_release (rtems_termios_ttyMutex); 3c40: e59f300c ldr r3, [pc, #12] ; 3c54 3c44: e5930000 ldr r0, [r3] 3c48: eb0003cc bl 4b80 return RTEMS_SUCCESSFUL; } 3c4c: e3a00000 mov r0, #0 3c50: e8bd8030 pop {r4, r5, pc} 3c54: 00018d00 .word 0x00018d00 3c58: 000189c0 .word 0x000189c0 3c5c: 00018d04 .word 0x00018d04 3c60: 00018d08 .word 0x00018d08 000028c4 : rtems_status_code sc; /* * sum up character count already sent */ tty->t_dqlen += len; 28c4: e590c090 ldr ip, [r0, #144] ; 0x90 <== NOT EXECUTED if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) { 28c8: e59020b4 ldr r2, [r0, #180] ; 0xb4 <== NOT EXECUTED rtems_status_code sc; /* * sum up character count already sent */ tty->t_dqlen += len; 28cc: e08c1001 add r1, ip, r1 <== NOT EXECUTED if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) { 28d0: e3520002 cmp r2, #2 <== NOT EXECUTED * for each transmitted character. * It returns number of characters left to transmit */ int rtems_termios_dequeue_characters (void *ttyp, int len) { 28d4: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED rtems_status_code sc; /* * sum up character count already sent */ tty->t_dqlen += len; 28d8: e5801090 str r1, [r0, #144] ; 0x90 <== NOT EXECUTED if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) { 28dc: 1a000005 bne 28f8 <== NOT EXECUTED /* * send wake up to transmitter task */ sc = rtems_event_send(tty->txTaskId, 28e0: e59000c8 ldr r0, [r0, #200] ; 0xc8 <== NOT EXECUTED 28e4: e1a01002 mov r1, r2 <== NOT EXECUTED 28e8: eb00074a bl 4618 <== NOT EXECUTED TERMIOS_TX_START_EVENT); if (sc != RTEMS_SUCCESSFUL) 28ec: e3500000 cmp r0, #0 <== NOT EXECUTED 28f0: 0a00000c beq 2928 <== NOT EXECUTED rtems_fatal_error_occurred (sc); 28f4: eb0009ee bl 50b4 <== NOT EXECUTED return 0; /* nothing to output in IRQ... */ } else if (tty->t_line == PPPDISC ) { 28f8: e59030cc ldr r3, [r0, #204] ; 0xcc <== NOT EXECUTED 28fc: e3530005 cmp r3, #5 <== NOT EXECUTED 2900: 1a000006 bne 2920 <== NOT EXECUTED /* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) { 2904: e59f3024 ldr r3, [pc, #36] ; 2930 <== NOT EXECUTED 2908: e59330b4 ldr r3, [r3, #180] ; 0xb4 <== NOT EXECUTED 290c: e3530000 cmp r3, #0 <== NOT EXECUTED 2910: 0a000004 beq 2928 <== NOT EXECUTED rtems_termios_linesw[tty->t_line].l_start(tty); 2914: e1a0e00f mov lr, pc <== NOT EXECUTED 2918: e12fff13 bx r3 <== NOT EXECUTED 291c: ea000001 b 2928 <== NOT EXECUTED return 0; /* nothing to output in IRQ... */ } else { return rtems_termios_refill_transmitter(tty); } } 2920: e49de004 pop {lr} ; (ldr lr, [sp], #4) <== NOT EXECUTED rtems_termios_linesw[tty->t_line].l_start(tty); } return 0; /* nothing to output in IRQ... */ } else { return rtems_termios_refill_transmitter(tty); 2924: eaffff6d b 26e0 <== NOT EXECUTED } } 2928: e3a00000 mov r0, #0 <== NOT EXECUTED 292c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED 2930: 000189c0 .word 0x000189c0 00002934 : * device receive interrupt handler. * Returns the number of characters dropped because of overflow. */ int rtems_termios_enqueue_raw_characters (void *ttyp, char *buf, int len) { 2934: e92d4ff7 push {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr}<== NOT EXECUTED char c; int dropped = 0; bool flow_rcv = false; /* true, if flow control char received */ rtems_interrupt_level level; if (rtems_termios_linesw[tty->t_line].l_rint != NULL) { 2938: e59f32b8 ldr r3, [pc, #696] ; 2bf8 <== NOT EXECUTED * device receive interrupt handler. * Returns the number of characters dropped because of overflow. */ int rtems_termios_enqueue_raw_characters (void *ttyp, char *buf, int len) { 293c: e1a04000 mov r4, r0 <== NOT EXECUTED char c; int dropped = 0; bool flow_rcv = false; /* true, if flow control char received */ rtems_interrupt_level level; if (rtems_termios_linesw[tty->t_line].l_rint != NULL) { 2940: e59000cc ldr r0, [r0, #204] ; 0xcc <== NOT EXECUTED 2944: e0830280 add r0, r3, r0, lsl #5 <== NOT EXECUTED 2948: e5906010 ldr r6, [r0, #16] <== NOT EXECUTED 294c: e3560000 cmp r6, #0 <== NOT EXECUTED * device receive interrupt handler. * Returns the number of characters dropped because of overflow. */ int rtems_termios_enqueue_raw_characters (void *ttyp, char *buf, int len) { 2950: e1a0b001 mov fp, r1 <== NOT EXECUTED /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) { (*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg); 2954: 11a05002 movne r5, r2 <== NOT EXECUTED rtems_interrupt_level level; if (rtems_termios_linesw[tty->t_line].l_rint != NULL) { while (len--) { c = *buf++; rtems_termios_linesw[tty->t_line].l_rint(c,tty); 2958: 11a07003 movne r7, r3 <== NOT EXECUTED /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) { (*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg); 295c: 13a06000 movne r6, #0 <== NOT EXECUTED char c; int dropped = 0; bool flow_rcv = false; /* true, if flow control char received */ rtems_interrupt_level level; if (rtems_termios_linesw[tty->t_line].l_rint != NULL) { 2960: 1a00000e bne 29a0 <== NOT EXECUTED /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) { (*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg); 2964: e1a08002 mov r8, r2 <== NOT EXECUTED 2968: e2843030 add r3, r4, #48 ; 0x30 <== NOT EXECUTED if ((tty->flow_ctrl & FL_OSTOP) || (tty->rawOutBufState == rob_idle)) { /* if tx is stopped due to XOFF or out of data */ /* call write function here */ tty->flow_ctrl |= FL_ISNTXOF; (*tty->device.write)(tty->minor, 296c: e284204a add r2, r4, #74 ; 0x4a <== NOT EXECUTED 2970: e58d2008 str r2, [sp, #8] <== NOT EXECUTED /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) { (*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg); 2974: e58d3004 str r3, [sp, #4] <== NOT EXECUTED 2978: e1a09006 mov r9, r6 <== NOT EXECUTED 297c: e1a05006 mov r5, r6 <== NOT EXECUTED 2980: ea000091 b 2bcc <== NOT EXECUTED rtems_interrupt_level level; if (rtems_termios_linesw[tty->t_line].l_rint != NULL) { while (len--) { c = *buf++; rtems_termios_linesw[tty->t_line].l_rint(c,tty); 2984: e59430cc ldr r3, [r4, #204] ; 0xcc <== NOT EXECUTED 2988: e7db0006 ldrb r0, [fp, r6] <== NOT EXECUTED 298c: e0873283 add r3, r7, r3, lsl #5 <== NOT EXECUTED 2990: e1a0e00f mov lr, pc <== NOT EXECUTED 2994: e593f010 ldr pc, [r3, #16] <== NOT EXECUTED 2998: e2866001 add r6, r6, #1 <== NOT EXECUTED 299c: e2455001 sub r5, r5, #1 <== NOT EXECUTED int dropped = 0; bool flow_rcv = false; /* true, if flow control char received */ rtems_interrupt_level level; if (rtems_termios_linesw[tty->t_line].l_rint != NULL) { while (len--) { 29a0: e3550000 cmp r5, #0 <== NOT EXECUTED c = *buf++; rtems_termios_linesw[tty->t_line].l_rint(c,tty); 29a4: e1a01004 mov r1, r4 <== NOT EXECUTED int dropped = 0; bool flow_rcv = false; /* true, if flow control char received */ rtems_interrupt_level level; if (rtems_termios_linesw[tty->t_line].l_rint != NULL) { while (len--) { 29a8: 1afffff5 bne 2984 <== NOT EXECUTED } /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) { 29ac: e59430e4 ldr r3, [r4, #228] ; 0xe4 <== NOT EXECUTED 29b0: e3530000 cmp r3, #0 <== NOT EXECUTED 29b4: 1a00008c bne 2bec <== NOT EXECUTED 29b8: e59430dc ldr r3, [r4, #220] ; 0xdc <== NOT EXECUTED 29bc: e3530000 cmp r3, #0 <== NOT EXECUTED 29c0: 0a000089 beq 2bec <== NOT EXECUTED (*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg); 29c4: e2840030 add r0, r4, #48 ; 0x30 <== NOT EXECUTED 29c8: e59410e0 ldr r1, [r4, #224] ; 0xe0 <== NOT EXECUTED 29cc: e1a0e00f mov lr, pc <== NOT EXECUTED 29d0: e12fff13 bx r3 <== NOT EXECUTED tty->tty_rcvwakeup = 1; 29d4: e3a03001 mov r3, #1 <== NOT EXECUTED 29d8: e58430e4 str r3, [r4, #228] ; 0xe4 <== NOT EXECUTED 29dc: ea000083 b 2bf0 <== NOT EXECUTED while (len--) { c = *buf++; /* FIXME: implement IXANY: any character restarts output */ /* if incoming XON/XOFF controls outgoing stream: */ if (tty->flow_ctrl & FL_MDXON) { 29e0: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 29e4: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED } return 0; } while (len--) { c = *buf++; 29e8: e7dba006 ldrb sl, [fp, r6] <== NOT EXECUTED /* FIXME: implement IXANY: any character restarts output */ /* if incoming XON/XOFF controls outgoing stream: */ if (tty->flow_ctrl & FL_MDXON) { 29ec: 0a00000f beq 2a30 <== NOT EXECUTED /* if received char is V_STOP and V_START (both are equal value) */ if (c == tty->termios.c_cc[VSTOP]) { 29f0: e5d4204a ldrb r2, [r4, #74] ; 0x4a <== NOT EXECUTED 29f4: e152000a cmp r2, sl <== NOT EXECUTED 29f8: e5d43049 ldrb r3, [r4, #73] ; 0x49 <== NOT EXECUTED 29fc: 1a000007 bne 2a20 <== NOT EXECUTED if (c == tty->termios.c_cc[VSTART]) { 2a00: e1530002 cmp r3, r2 <== NOT EXECUTED /* received VSTOP and VSTART==VSTOP? */ /* then toggle "stop output" status */ tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF; 2a04: 059430b8 ldreq r3, [r4, #184] ; 0xb8 <== NOT EXECUTED } else { /* VSTOP received (other code than VSTART) */ /* stop output */ tty->flow_ctrl |= FL_ORCVXOF; 2a08: 159430b8 ldrne r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* if received char is V_STOP and V_START (both are equal value) */ if (c == tty->termios.c_cc[VSTOP]) { if (c == tty->termios.c_cc[VSTART]) { /* received VSTOP and VSTART==VSTOP? */ /* then toggle "stop output" status */ tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF; 2a0c: 02233010 eoreq r3, r3, #16 <== NOT EXECUTED } else { /* VSTOP received (other code than VSTART) */ /* stop output */ tty->flow_ctrl |= FL_ORCVXOF; 2a10: 13833010 orrne r3, r3, #16 <== NOT EXECUTED 2a14: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED } } } tty->rawInBufDropped += dropped; rtems_semaphore_release (tty->rawInBuf.Semaphore); return dropped; 2a18: e3a09001 mov r9, #1 <== NOT EXECUTED 2a1c: ea000005 b 2a38 <== NOT EXECUTED /* stop output */ tty->flow_ctrl |= FL_ORCVXOF; } flow_rcv = true; } else if (c == tty->termios.c_cc[VSTART]) { 2a20: e153000a cmp r3, sl <== NOT EXECUTED /* VSTART received */ /* restart output */ tty->flow_ctrl &= ~FL_ORCVXOF; 2a24: 059430b8 ldreq r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2a28: 03c33010 biceq r3, r3, #16 <== NOT EXECUTED /* stop output */ tty->flow_ctrl |= FL_ORCVXOF; } flow_rcv = true; } else if (c == tty->termios.c_cc[VSTART]) { 2a2c: 0afffff8 beq 2a14 <== NOT EXECUTED /* restart output */ tty->flow_ctrl &= ~FL_ORCVXOF; flow_rcv = true; } } if (flow_rcv) { 2a30: e3590000 cmp r9, #0 <== NOT EXECUTED 2a34: 0a000015 beq 2a90 <== NOT EXECUTED /* restart output according to FL_ORCVXOF flag */ if ((tty->flow_ctrl & (FL_ORCVXOF | FL_OSTOP)) == FL_OSTOP) { 2a38: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2a3c: e2033030 and r3, r3, #48 ; 0x30 <== NOT EXECUTED 2a40: e3530020 cmp r3, #32 <== NOT EXECUTED 2a44: 1a00005e bne 2bc4 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 2a48: e10f7000 mrs r7, CPSR <== NOT EXECUTED 2a4c: e3873080 orr r3, r7, #128 ; 0x80 <== NOT EXECUTED 2a50: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED /* disable interrupts */ rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP; 2a54: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) { 2a58: e5942094 ldr r2, [r4, #148] ; 0x94 <== NOT EXECUTED if (flow_rcv) { /* restart output according to FL_ORCVXOF flag */ if ((tty->flow_ctrl & (FL_ORCVXOF | FL_OSTOP)) == FL_OSTOP) { /* disable interrupts */ rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP; 2a5c: e3c33020 bic r3, r3, #32 <== NOT EXECUTED /* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) { 2a60: e3520000 cmp r2, #0 <== NOT EXECUTED if (flow_rcv) { /* restart output according to FL_ORCVXOF flag */ if ((tty->flow_ctrl & (FL_ORCVXOF | FL_OSTOP)) == FL_OSTOP) { /* disable interrupts */ rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP; 2a64: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) { 2a68: 0a000006 beq 2a88 <== NOT EXECUTED /* if chars available, call write function... */ (*tty->device.write)(tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail], 1); 2a6c: e5943084 ldr r3, [r4, #132] ; 0x84 <== NOT EXECUTED rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP; /* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) { /* if chars available, call write function... */ (*tty->device.write)(tty->minor, 2a70: e594107c ldr r1, [r4, #124] ; 0x7c <== NOT EXECUTED 2a74: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 2a78: e0811003 add r1, r1, r3 <== NOT EXECUTED 2a7c: e3a02001 mov r2, #1 <== NOT EXECUTED 2a80: e1a0e00f mov lr, pc <== NOT EXECUTED 2a84: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 2a88: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED 2a8c: ea00004c b 2bc4 <== NOT EXECUTED /* reenable interrupts */ rtems_interrupt_enable(level); } } else { newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size; 2a90: e5940060 ldr r0, [r4, #96] ; 0x60 <== NOT EXECUTED 2a94: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED 2a98: e2800001 add r0, r0, #1 <== NOT EXECUTED 2a9c: eb004a32 bl 1536c <__umodsi3> <== NOT EXECUTED 2aa0: e1a07000 mov r7, r0 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 2aa4: e10f2000 mrs r2, CPSR <== NOT EXECUTED 2aa8: e3823080 orr r3, r2, #128 ; 0x80 <== NOT EXECUTED 2aac: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 2ab0: e58d2000 str r2, [sp] <== NOT EXECUTED /* if chars_in_buffer > highwater */ rtems_interrupt_disable(level); if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size) 2ab4: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED 2ab8: e5940064 ldr r0, [r4, #100] ; 0x64 <== NOT EXECUTED 2abc: e0630000 rsb r0, r3, r0 <== NOT EXECUTED 2ac0: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED 2ac4: e0800007 add r0, r0, r7 <== NOT EXECUTED 2ac8: eb004a27 bl 1536c <__umodsi3> <== NOT EXECUTED % tty->rawInBuf.Size) > tty->highwater) && 2acc: e59430c0 ldr r3, [r4, #192] ; 0xc0 <== NOT EXECUTED 2ad0: e1500003 cmp r0, r3 <== NOT EXECUTED 2ad4: 9a000025 bls 2b70 <== NOT EXECUTED !(tty->flow_ctrl & FL_IREQXOF)) { 2ad8: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED } else { newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size; /* if chars_in_buffer > highwater */ rtems_interrupt_disable(level); if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size) 2adc: e3130001 tst r3, #1 <== NOT EXECUTED 2ae0: 1a000022 bne 2b70 <== NOT EXECUTED % tty->rawInBuf.Size) > tty->highwater) && !(tty->flow_ctrl & FL_IREQXOF)) { /* incoming data stream should be stopped */ tty->flow_ctrl |= FL_IREQXOF; 2ae4: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2ae8: e3833001 orr r3, r3, #1 <== NOT EXECUTED 2aec: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED if ((tty->flow_ctrl & (FL_MDXOF | FL_ISNTXOF)) 2af0: e59f3104 ldr r3, [pc, #260] ; 2bfc <== NOT EXECUTED 2af4: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED 2af8: e0023003 and r3, r2, r3 <== NOT EXECUTED 2afc: e3530b01 cmp r3, #1024 ; 0x400 <== NOT EXECUTED 2b00: 1a00000e bne 2b40 <== NOT EXECUTED == (FL_MDXOF ) ){ if ((tty->flow_ctrl & FL_OSTOP) || 2b04: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2b08: e3130020 tst r3, #32 <== NOT EXECUTED 2b0c: 1a000002 bne 2b1c <== NOT EXECUTED (tty->rawOutBufState == rob_idle)) { 2b10: e5943094 ldr r3, [r4, #148] ; 0x94 <== NOT EXECUTED 2b14: e3530000 cmp r3, #0 <== NOT EXECUTED 2b18: 1a000014 bne 2b70 <== NOT EXECUTED /* if tx is stopped due to XOFF or out of data */ /* call write function here */ tty->flow_ctrl |= FL_ISNTXOF; 2b1c: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2b20: e3833002 orr r3, r3, #2 <== NOT EXECUTED 2b24: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED (*tty->device.write)(tty->minor, 2b28: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 2b2c: e59d1008 ldr r1, [sp, #8] <== NOT EXECUTED 2b30: e3a02001 mov r2, #1 <== NOT EXECUTED 2b34: e1a0e00f mov lr, pc <== NOT EXECUTED 2b38: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED 2b3c: ea00000b b 2b70 <== NOT EXECUTED (void *)&(tty->termios.c_cc[VSTOP]), 1); } } else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF)) 2b40: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2b44: e2033f41 and r3, r3, #260 ; 0x104 <== NOT EXECUTED 2b48: e3530c01 cmp r3, #256 ; 0x100 <== NOT EXECUTED 2b4c: 1a000007 bne 2b70 <== NOT EXECUTED == (FL_MDRTS ) ) { tty->flow_ctrl |= FL_IRTSOFF; 2b50: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED /* deactivate RTS line */ if (tty->device.stopRemoteTx != NULL) { 2b54: e59430ac ldr r3, [r4, #172] ; 0xac <== NOT EXECUTED 1); } } else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF)) == (FL_MDRTS ) ) { tty->flow_ctrl |= FL_IRTSOFF; 2b58: e3822004 orr r2, r2, #4 <== NOT EXECUTED /* deactivate RTS line */ if (tty->device.stopRemoteTx != NULL) { 2b5c: e3530000 cmp r3, #0 <== NOT EXECUTED 1); } } else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF)) == (FL_MDRTS ) ) { tty->flow_ctrl |= FL_IRTSOFF; 2b60: e58420b8 str r2, [r4, #184] ; 0xb8 <== NOT EXECUTED /* deactivate RTS line */ if (tty->device.stopRemoteTx != NULL) { tty->device.stopRemoteTx(tty->minor); 2b64: 15940010 ldrne r0, [r4, #16] <== NOT EXECUTED 2b68: 11a0e00f movne lr, pc <== NOT EXECUTED 2b6c: 112fff13 bxne r3 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 2b70: e59d3000 ldr r3, [sp] <== NOT EXECUTED 2b74: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED } } /* reenable interrupts */ rtems_interrupt_enable(level); if (newTail == tty->rawInBuf.Head) { 2b78: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED 2b7c: e1570003 cmp r7, r3 <== NOT EXECUTED dropped++; 2b80: 02855001 addeq r5, r5, #1 <== NOT EXECUTED } } /* reenable interrupts */ rtems_interrupt_enable(level); if (newTail == tty->rawInBuf.Head) { 2b84: 0a00000e beq 2bc4 <== NOT EXECUTED dropped++; } else { tty->rawInBuf.theBuf[newTail] = c; 2b88: e5943058 ldr r3, [r4, #88] ; 0x58 <== NOT EXECUTED 2b8c: e7c3a007 strb sl, [r3, r7] <== NOT EXECUTED tty->rawInBuf.Tail = newTail; /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) { 2b90: e59430e4 ldr r3, [r4, #228] ; 0xe4 <== NOT EXECUTED 2b94: e3530000 cmp r3, #0 <== NOT EXECUTED if (newTail == tty->rawInBuf.Head) { dropped++; } else { tty->rawInBuf.theBuf[newTail] = c; tty->rawInBuf.Tail = newTail; 2b98: e5847060 str r7, [r4, #96] ; 0x60 <== NOT EXECUTED /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) { 2b9c: 1a000008 bne 2bc4 <== NOT EXECUTED 2ba0: e59430dc ldr r3, [r4, #220] ; 0xdc <== NOT EXECUTED 2ba4: e3530000 cmp r3, #0 <== NOT EXECUTED 2ba8: 0a000005 beq 2bc4 <== NOT EXECUTED (*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg); 2bac: e59d0004 ldr r0, [sp, #4] <== NOT EXECUTED 2bb0: e59410e0 ldr r1, [r4, #224] ; 0xe0 <== NOT EXECUTED 2bb4: e1a0e00f mov lr, pc <== NOT EXECUTED 2bb8: e12fff13 bx r3 <== NOT EXECUTED tty->tty_rcvwakeup = 1; 2bbc: e3a02001 mov r2, #1 <== NOT EXECUTED 2bc0: e58420e4 str r2, [r4, #228] ; 0xe4 <== NOT EXECUTED 2bc4: e2866001 add r6, r6, #1 <== NOT EXECUTED 2bc8: e2488001 sub r8, r8, #1 <== NOT EXECUTED tty->tty_rcvwakeup = 1; } return 0; } while (len--) { 2bcc: e3580000 cmp r8, #0 <== NOT EXECUTED 2bd0: 1affff82 bne 29e0 <== NOT EXECUTED tty->tty_rcvwakeup = 1; } } } } tty->rawInBufDropped += dropped; 2bd4: e5943078 ldr r3, [r4, #120] ; 0x78 <== NOT EXECUTED 2bd8: e0833005 add r3, r3, r5 <== NOT EXECUTED 2bdc: e5843078 str r3, [r4, #120] ; 0x78 <== NOT EXECUTED rtems_semaphore_release (tty->rawInBuf.Semaphore); 2be0: e5940068 ldr r0, [r4, #104] ; 0x68 <== NOT EXECUTED 2be4: eb0007e5 bl 4b80 <== NOT EXECUTED return dropped; 2be8: ea000000 b 2bf0 <== NOT EXECUTED 2bec: e3a05000 mov r5, #0 <== NOT EXECUTED } 2bf0: e1a00005 mov r0, r5 <== NOT EXECUTED 2bf4: e8bd8ffe pop {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc}<== NOT EXECUTED 2bf8: 000189c0 .word 0x000189c0 2bfc: 00000402 .word 0x00000402 00003724 : rtems_status_code rtems_termios_ioctl (void *arg) { rtems_libio_ioctl_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; 3724: e5903000 ldr r3, [r0] struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer; rtems_status_code sc; args->ioctl_return = 0; 3728: e3a01000 mov r1, #0 } } rtems_status_code rtems_termios_ioctl (void *arg) { 372c: e92d41f0 push {r4, r5, r6, r7, r8, lr} rtems_libio_ioctl_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer; rtems_status_code sc; args->ioctl_return = 0; 3730: e580100c str r1, [r0, #12] rtems_status_code rtems_termios_ioctl (void *arg) { rtems_libio_ioctl_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; 3734: e5934034 ldr r4, [r3, #52] ; 0x34 } } rtems_status_code rtems_termios_ioctl (void *arg) { 3738: e1a05000 mov r5, r0 struct rtems_termios_tty *tty = args->iop->data1; struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer; rtems_status_code sc; args->ioctl_return = 0; sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 373c: e1a02001 mov r2, r1 3740: e5940018 ldr r0, [r4, #24] rtems_status_code rtems_termios_ioctl (void *arg) { rtems_libio_ioctl_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer; 3744: e5957008 ldr r7, [r5, #8] rtems_status_code sc; args->ioctl_return = 0; sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 3748: eb0004c6 bl 4a68 if (sc != RTEMS_SUCCESSFUL) { 374c: e2506000 subs r6, r0, #0 3750: 1a0000d7 bne 3ab4 args->ioctl_return = sc; return sc; } switch (args->command) { 3754: e5953004 ldr r3, [r5, #4] 3758: e3530004 cmp r3, #4 375c: 0a0000ab beq 3a10 3760: 8a000005 bhi 377c 3764: e3530002 cmp r3, #2 3768: 0a000029 beq 3814 376c: 8a0000a0 bhi 39f4 3770: e3530001 cmp r3, #1 3774: 1a000010 bne 37bc 3778: ea00001b b 37ec 377c: e59f233c ldr r2, [pc, #828] ; 3ac0 <== NOT EXECUTED 3780: e1530002 cmp r3, r2 <== NOT EXECUTED 3784: 0a0000bd beq 3a80 <== NOT EXECUTED 3788: 8a000002 bhi 3798 <== NOT EXECUTED 378c: e3530005 cmp r3, #5 <== NOT EXECUTED 3790: 1a000009 bne 37bc <== NOT EXECUTED 3794: ea000099 b 3a00 <== NOT EXECUTED 3798: e59f2324 ldr r2, [pc, #804] ; 3ac4 <== NOT EXECUTED 379c: e1530002 cmp r3, r2 <== NOT EXECUTED if (rtems_termios_linesw[tty->t_line].l_open != NULL) { sc = rtems_termios_linesw[tty->t_line].l_open(tty); } break; case TIOCGETD: *(int*)(args->buffer)=tty->t_line; 37a0: 05953008 ldreq r3, [r5, #8] <== NOT EXECUTED 37a4: 059420cc ldreq r2, [r4, #204] ; 0xcc <== NOT EXECUTED 37a8: 05832000 streq r2, [r3] <== NOT EXECUTED sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) { args->ioctl_return = sc; return sc; } switch (args->command) { 37ac: 0a0000be beq 3aac <== NOT EXECUTED 37b0: e2822105 add r2, r2, #1073741825 ; 0x40000001 <== NOT EXECUTED 37b4: e1530002 cmp r3, r2 <== NOT EXECUTED 37b8: 0a000098 beq 3a20 <== NOT EXECUTED default: if (rtems_termios_linesw[tty->t_line].l_ioctl != NULL) { 37bc: e59420cc ldr r2, [r4, #204] ; 0xcc <== NOT EXECUTED 37c0: e59f3300 ldr r3, [pc, #768] ; 3ac8 <== NOT EXECUTED 37c4: e0833282 add r3, r3, r2, lsl #5 <== NOT EXECUTED 37c8: e5933018 ldr r3, [r3, #24] <== NOT EXECUTED 37cc: e3530000 cmp r3, #0 <== NOT EXECUTED 37d0: 03a0600a moveq r6, #10 <== NOT EXECUTED 37d4: 0a0000b4 beq 3aac <== NOT EXECUTED sc = rtems_termios_linesw[tty->t_line].l_ioctl(tty,args); 37d8: e1a00004 mov r0, r4 <== NOT EXECUTED 37dc: e1a01005 mov r1, r5 <== NOT EXECUTED 37e0: e1a0e00f mov lr, pc <== NOT EXECUTED 37e4: e12fff13 bx r3 <== NOT EXECUTED 37e8: ea0000a2 b 3a78 <== NOT EXECUTED sc = RTEMS_INVALID_NUMBER; } break; case RTEMS_IO_GET_ATTRIBUTES: *(struct termios *)args->buffer = tty->termios; 37ec: e5957008 ldr r7, [r5, #8] 37f0: e284c030 add ip, r4, #48 ; 0x30 37f4: e8bc000f ldm ip!, {r0, r1, r2, r3} 37f8: e1a0e007 mov lr, r7 37fc: e8ae000f stmia lr!, {r0, r1, r2, r3} 3800: e8bc000f ldm ip!, {r0, r1, r2, r3} 3804: e8ae000f stmia lr!, {r0, r1, r2, r3} 3808: e59c3000 ldr r3, [ip] 380c: e58e3000 str r3, [lr] break; 3810: ea0000a5 b 3aac case RTEMS_IO_SET_ATTRIBUTES: tty->termios = *(struct termios *)args->buffer; 3814: e595e008 ldr lr, [r5, #8] 3818: e8be000f ldm lr!, {r0, r1, r2, r3} 381c: e284c030 add ip, r4, #48 ; 0x30 3820: e8ac000f stmia ip!, {r0, r1, r2, r3} 3824: e8be000f ldm lr!, {r0, r1, r2, r3} 3828: e8ac000f stmia ip!, {r0, r1, r2, r3} /* * check for flow control options to be switched off */ /* check for outgoing XON/XOFF flow control switched off */ if (( tty->flow_ctrl & FL_MDXON) && 382c: e59420b8 ldr r2, [r4, #184] ; 0xb8 case RTEMS_IO_GET_ATTRIBUTES: *(struct termios *)args->buffer = tty->termios; break; case RTEMS_IO_SET_ATTRIBUTES: tty->termios = *(struct termios *)args->buffer; 3830: e59e3000 ldr r3, [lr] /* * check for flow control options to be switched off */ /* check for outgoing XON/XOFF flow control switched off */ if (( tty->flow_ctrl & FL_MDXON) && 3834: e3120c02 tst r2, #512 ; 0x200 case RTEMS_IO_GET_ATTRIBUTES: *(struct termios *)args->buffer = tty->termios; break; case RTEMS_IO_SET_ATTRIBUTES: tty->termios = *(struct termios *)args->buffer; 3838: e58c3000 str r3, [ip] /* * check for flow control options to be switched off */ /* check for outgoing XON/XOFF flow control switched off */ if (( tty->flow_ctrl & FL_MDXON) && 383c: 0a000019 beq 38a8 3840: e5943030 ldr r3, [r4, #48] ; 0x30 3844: e3130b01 tst r3, #1024 ; 0x400 3848: 1a000016 bne 38a8 !(tty->termios.c_iflag & IXON)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDXON | FL_ORCVXOF); 384c: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 3850: e3c33e21 bic r3, r3, #528 ; 0x210 <== NOT EXECUTED 3854: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* has output been stopped due to received XOFF? */ if (tty->flow_ctrl & FL_OSTOP) { 3858: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 385c: e3130020 tst r3, #32 <== NOT EXECUTED 3860: 0a000010 beq 38a8 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 3864: e10f7000 mrs r7, CPSR <== NOT EXECUTED 3868: e3873080 orr r3, r7, #128 ; 0x80 <== NOT EXECUTED 386c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED /* disable interrupts */ rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP; 3870: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) { 3874: e5942094 ldr r2, [r4, #148] ; 0x94 <== NOT EXECUTED /* has output been stopped due to received XOFF? */ if (tty->flow_ctrl & FL_OSTOP) { /* disable interrupts */ rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP; 3878: e3c33020 bic r3, r3, #32 <== NOT EXECUTED /* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) { 387c: e3520000 cmp r2, #0 <== NOT EXECUTED /* has output been stopped due to received XOFF? */ if (tty->flow_ctrl & FL_OSTOP) { /* disable interrupts */ rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP; 3880: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) { 3884: 0a000006 beq 38a4 <== NOT EXECUTED /* if chars available, call write function... */ (*tty->device.write)(tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1); 3888: e5943084 ldr r3, [r4, #132] ; 0x84 <== NOT EXECUTED rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP; /* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) { /* if chars available, call write function... */ (*tty->device.write)(tty->minor, 388c: e594107c ldr r1, [r4, #124] ; 0x7c <== NOT EXECUTED 3890: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 3894: e0811003 add r1, r1, r3 <== NOT EXECUTED 3898: e3a02001 mov r2, #1 <== NOT EXECUTED 389c: e1a0e00f mov lr, pc <== NOT EXECUTED 38a0: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 38a4: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED /* reenable interrupts */ rtems_interrupt_enable(level); } } /* check for incoming XON/XOFF flow control switched off */ if (( tty->flow_ctrl & FL_MDXOF) && 38a8: e59430b8 ldr r3, [r4, #184] ; 0xb8 38ac: e3130b01 tst r3, #1024 ; 0x400 38b0: 0a000008 beq 38d8 38b4: e5943030 ldr r3, [r4, #48] ; 0x30 <== NOT EXECUTED 38b8: e3130a01 tst r3, #4096 ; 0x1000 <== NOT EXECUTED 38bc: 1a000005 bne 38d8 <== NOT EXECUTED !(tty->termios.c_iflag & IXOFF)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDXOF); 38c0: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 38c4: e3c33b01 bic r3, r3, #1024 ; 0x400 <== NOT EXECUTED 38c8: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* FIXME: what happens, if we had sent XOFF but not yet XON? */ tty->flow_ctrl &= ~(FL_ISNTXOF); 38cc: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 38d0: e3c33002 bic r3, r3, #2 <== NOT EXECUTED 38d4: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED } /* check for incoming RTS/CTS flow control switched off */ if (( tty->flow_ctrl & FL_MDRTS) && 38d8: e59430b8 ldr r3, [r4, #184] ; 0xb8 38dc: e3130c01 tst r3, #256 ; 0x100 38e0: 0a000010 beq 3928 38e4: e5943038 ldr r3, [r4, #56] ; 0x38 <== NOT EXECUTED 38e8: e3530000 cmp r3, #0 <== NOT EXECUTED 38ec: ba00000d blt 3928 <== NOT EXECUTED !(tty->termios.c_cflag & CRTSCTS)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDRTS); 38f0: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 38f4: e3c33c01 bic r3, r3, #256 ; 0x100 <== NOT EXECUTED 38f8: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* restart remote Tx, if it was stopped */ if ((tty->flow_ctrl & FL_IRTSOFF) && 38fc: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 3900: e3130004 tst r3, #4 <== NOT EXECUTED 3904: 0a000004 beq 391c <== NOT EXECUTED (tty->device.startRemoteTx != NULL)) { 3908: e59430b0 ldr r3, [r4, #176] ; 0xb0 <== NOT EXECUTED !(tty->termios.c_cflag & CRTSCTS)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDRTS); /* restart remote Tx, if it was stopped */ if ((tty->flow_ctrl & FL_IRTSOFF) && 390c: e3530000 cmp r3, #0 <== NOT EXECUTED (tty->device.startRemoteTx != NULL)) { tty->device.startRemoteTx(tty->minor); 3910: 15940010 ldrne r0, [r4, #16] <== NOT EXECUTED 3914: 11a0e00f movne lr, pc <== NOT EXECUTED 3918: 112fff13 bxne r3 <== NOT EXECUTED } tty->flow_ctrl &= ~(FL_IRTSOFF); 391c: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 3920: e3c33004 bic r3, r3, #4 <== NOT EXECUTED 3924: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* * check for flow control options to be switched on */ /* check for incoming RTS/CTS flow control switched on */ if (tty->termios.c_cflag & CRTSCTS) { 3928: e5943038 ldr r3, [r4, #56] ; 0x38 392c: e3530000 cmp r3, #0 tty->flow_ctrl |= FL_MDRTS; 3930: b59430b8 ldrlt r3, [r4, #184] ; 0xb8 3934: b3833c01 orrlt r3, r3, #256 ; 0x100 3938: b58430b8 strlt r3, [r4, #184] ; 0xb8 } /* check for incoming XON/XOF flow control switched on */ if (tty->termios.c_iflag & IXOFF) { 393c: e5943030 ldr r3, [r4, #48] ; 0x30 3940: e3130a01 tst r3, #4096 ; 0x1000 tty->flow_ctrl |= FL_MDXOF; 3944: 159430b8 ldrne r3, [r4, #184] ; 0xb8 3948: 13833b01 orrne r3, r3, #1024 ; 0x400 394c: 158430b8 strne r3, [r4, #184] ; 0xb8 } /* check for outgoing XON/XOF flow control switched on */ if (tty->termios.c_iflag & IXON) { 3950: e5943030 ldr r3, [r4, #48] ; 0x30 3954: e3130b01 tst r3, #1024 ; 0x400 tty->flow_ctrl |= FL_MDXON; 3958: 159430b8 ldrne r3, [r4, #184] ; 0xb8 tty->termios = *(struct termios *)args->buffer; /* check for and process change in flow control options */ termios_set_flowctrl(tty); if (tty->termios.c_lflag & ICANON) { 395c: e594703c ldr r7, [r4, #60] ; 0x3c if (tty->termios.c_iflag & IXOFF) { tty->flow_ctrl |= FL_MDXOF; } /* check for outgoing XON/XOF flow control switched on */ if (tty->termios.c_iflag & IXON) { tty->flow_ctrl |= FL_MDXON; 3960: 13833c02 orrne r3, r3, #512 ; 0x200 3964: 158430b8 strne r3, [r4, #184] ; 0xb8 tty->termios = *(struct termios *)args->buffer; /* check for and process change in flow control options */ termios_set_flowctrl(tty); if (tty->termios.c_lflag & ICANON) { 3968: e2177002 ands r7, r7, #2 tty->rawInBufSemaphoreOptions = RTEMS_WAIT; 396c: 13a03000 movne r3, #0 tty->termios = *(struct termios *)args->buffer; /* check for and process change in flow control options */ termios_set_flowctrl(tty); if (tty->termios.c_lflag & ICANON) { 3970: 1a000014 bne 39c8 tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; } else { tty->vtimeTicks = tty->termios.c_cc[VTIME] * rtems_clock_get_ticks_per_second() / 10; 3974: e5d48046 ldrb r8, [r4, #70] ; 0x46 <== NOT EXECUTED 3978: eb0002a5 bl 4414 <== NOT EXECUTED tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; } else { tty->vtimeTicks = tty->termios.c_cc[VTIME] * 397c: e3a0100a mov r1, #10 <== NOT EXECUTED 3980: e0000098 mul r0, r8, r0 <== NOT EXECUTED 3984: eb0045e4 bl 1511c <__aeabi_uidiv> <== NOT EXECUTED rtems_clock_get_ticks_per_second() / 10; if (tty->termios.c_cc[VTIME]) { 3988: e5d43046 ldrb r3, [r4, #70] ; 0x46 <== NOT EXECUTED 398c: e3530000 cmp r3, #0 <== NOT EXECUTED tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; } else { tty->vtimeTicks = tty->termios.c_cc[VTIME] * 3990: e5840054 str r0, [r4, #84] ; 0x54 <== NOT EXECUTED 3994: e5d42047 ldrb r2, [r4, #71] ; 0x47 <== NOT EXECUTED rtems_clock_get_ticks_per_second() / 10; if (tty->termios.c_cc[VTIME]) { 3998: 0a000006 beq 39b8 <== NOT EXECUTED tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = tty->vtimeTicks; if (tty->termios.c_cc[VMIN]) tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; 399c: e3520000 cmp r2, #0 <== NOT EXECUTED 39a0: 01a02000 moveq r2, r0 <== NOT EXECUTED 39a4: 13a02000 movne r2, #0 <== NOT EXECUTED } else { tty->vtimeTicks = tty->termios.c_cc[VTIME] * rtems_clock_get_ticks_per_second() / 10; if (tty->termios.c_cc[VTIME]) { tty->rawInBufSemaphoreOptions = RTEMS_WAIT; 39a8: e584706c str r7, [r4, #108] ; 0x6c <== NOT EXECUTED tty->rawInBufSemaphoreTimeout = tty->vtimeTicks; if (tty->termios.c_cc[VMIN]) tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; 39ac: e5842074 str r2, [r4, #116] ; 0x74 <== NOT EXECUTED else { tty->vtimeTicks = tty->termios.c_cc[VTIME] * rtems_clock_get_ticks_per_second() / 10; if (tty->termios.c_cc[VTIME]) { tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = tty->vtimeTicks; 39b0: e5840070 str r0, [r4, #112] ; 0x70 <== NOT EXECUTED 39b4: ea000006 b 39d4 <== NOT EXECUTED tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; else tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks; } else { if (tty->termios.c_cc[VMIN]) { 39b8: e3520000 cmp r2, #0 <== NOT EXECUTED tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; } else { tty->rawInBufSemaphoreOptions = RTEMS_NO_WAIT; 39bc: 03a03001 moveq r3, #1 <== NOT EXECUTED 39c0: 0584306c streq r3, [r4, #108] ; 0x6c <== NOT EXECUTED tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; else tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks; } else { if (tty->termios.c_cc[VMIN]) { 39c4: 0a000002 beq 39d4 <== NOT EXECUTED tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; 39c8: e5843074 str r3, [r4, #116] ; 0x74 else tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks; } else { if (tty->termios.c_cc[VMIN]) { tty->rawInBufSemaphoreOptions = RTEMS_WAIT; 39cc: e584306c str r3, [r4, #108] ; 0x6c tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; 39d0: e5843070 str r3, [r4, #112] ; 0x70 else { tty->rawInBufSemaphoreOptions = RTEMS_NO_WAIT; } } } if (tty->device.setAttributes) 39d4: e59430a8 ldr r3, [r4, #168] ; 0xa8 39d8: e3530000 cmp r3, #0 39dc: 0a000032 beq 3aac (*tty->device.setAttributes)(tty->minor, &tty->termios); 39e0: e5940010 ldr r0, [r4, #16] 39e4: e2841030 add r1, r4, #48 ; 0x30 39e8: e1a0e00f mov lr, pc 39ec: e12fff13 bx r3 39f0: ea00002d b 3aac break; case RTEMS_IO_TCDRAIN: drainOutput (tty); 39f4: e1a00004 mov r0, r4 39f8: ebfffe5a bl 3368 break; 39fc: ea00002a b 3aac case RTEMS_IO_SNDWAKEUP: tty->tty_snd = *wakeup; 3a00: e897000c ldm r7, {r2, r3} <== NOT EXECUTED 3a04: e58420d4 str r2, [r4, #212] ; 0xd4 <== NOT EXECUTED 3a08: e58430d8 str r3, [r4, #216] ; 0xd8 <== NOT EXECUTED break; 3a0c: ea000026 b 3aac <== NOT EXECUTED case RTEMS_IO_RCVWAKEUP: tty->tty_rcv = *wakeup; 3a10: e897000c ldm r7, {r2, r3} <== NOT EXECUTED 3a14: e58420dc str r2, [r4, #220] ; 0xdc <== NOT EXECUTED 3a18: e58430e0 str r3, [r4, #224] ; 0xe0 <== NOT EXECUTED break; 3a1c: ea000022 b 3aac <== NOT EXECUTED #if 1 /* FIXME */ case TIOCSETD: /* * close old line discipline */ if (rtems_termios_linesw[tty->t_line].l_close != NULL) { 3a20: e59420cc ldr r2, [r4, #204] ; 0xcc <== NOT EXECUTED 3a24: e59f309c ldr r3, [pc, #156] ; 3ac8 <== NOT EXECUTED 3a28: e0833282 add r3, r3, r2, lsl #5 <== NOT EXECUTED 3a2c: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED 3a30: e3530000 cmp r3, #0 <== NOT EXECUTED 3a34: 0a000003 beq 3a48 <== NOT EXECUTED sc = rtems_termios_linesw[tty->t_line].l_close(tty); 3a38: e1a00004 mov r0, r4 <== NOT EXECUTED 3a3c: e1a0e00f mov lr, pc <== NOT EXECUTED 3a40: e12fff13 bx r3 <== NOT EXECUTED 3a44: e1a06000 mov r6, r0 <== NOT EXECUTED } tty->t_line=*(int*)(args->buffer); 3a48: e5953008 ldr r3, [r5, #8] <== NOT EXECUTED 3a4c: e5932000 ldr r2, [r3] <== NOT EXECUTED tty->t_sc = NULL; /* ensure that no more valid data */ /* * open new line discipline */ if (rtems_termios_linesw[tty->t_line].l_open != NULL) { 3a50: e59f3070 ldr r3, [pc, #112] ; 3ac8 <== NOT EXECUTED 3a54: e7933282 ldr r3, [r3, r2, lsl #5] <== NOT EXECUTED */ if (rtems_termios_linesw[tty->t_line].l_close != NULL) { sc = rtems_termios_linesw[tty->t_line].l_close(tty); } tty->t_line=*(int*)(args->buffer); tty->t_sc = NULL; /* ensure that no more valid data */ 3a58: e3a01000 mov r1, #0 <== NOT EXECUTED /* * open new line discipline */ if (rtems_termios_linesw[tty->t_line].l_open != NULL) { 3a5c: e3530000 cmp r3, #0 <== NOT EXECUTED */ if (rtems_termios_linesw[tty->t_line].l_close != NULL) { sc = rtems_termios_linesw[tty->t_line].l_close(tty); } tty->t_line=*(int*)(args->buffer); tty->t_sc = NULL; /* ensure that no more valid data */ 3a60: e58410d0 str r1, [r4, #208] ; 0xd0 <== NOT EXECUTED * close old line discipline */ if (rtems_termios_linesw[tty->t_line].l_close != NULL) { sc = rtems_termios_linesw[tty->t_line].l_close(tty); } tty->t_line=*(int*)(args->buffer); 3a64: e58420cc str r2, [r4, #204] ; 0xcc <== NOT EXECUTED tty->t_sc = NULL; /* ensure that no more valid data */ /* * open new line discipline */ if (rtems_termios_linesw[tty->t_line].l_open != NULL) { 3a68: 0a00000f beq 3aac <== NOT EXECUTED sc = rtems_termios_linesw[tty->t_line].l_open(tty); 3a6c: e1a00004 mov r0, r4 <== NOT EXECUTED 3a70: e1a0e00f mov lr, pc <== NOT EXECUTED 3a74: e12fff13 bx r3 <== NOT EXECUTED 3a78: e1a06000 mov r6, r0 <== NOT EXECUTED 3a7c: ea00000a b 3aac <== NOT EXECUTED *(int*)(args->buffer)=tty->t_line; break; #endif case FIONREAD: { int rawnc = tty->rawInBuf.Tail - tty->rawInBuf.Head; 3a80: e5942060 ldr r2, [r4, #96] ; 0x60 <== NOT EXECUTED 3a84: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED if ( rawnc < 0 ) 3a88: e0523003 subs r3, r2, r3 <== NOT EXECUTED rawnc += tty->rawInBuf.Size; 3a8c: 45942064 ldrmi r2, [r4, #100] ; 0x64 <== NOT EXECUTED 3a90: 40833002 addmi r3, r3, r2 <== NOT EXECUTED /* Half guess that this is the right operation */ *(int *)args->buffer = tty->ccount - tty->cindex + rawnc; 3a94: e2842020 add r2, r4, #32 <== NOT EXECUTED 3a98: e8920006 ldm r2, {r1, r2} <== NOT EXECUTED 3a9c: e0411002 sub r1, r1, r2 <== NOT EXECUTED 3aa0: e5952008 ldr r2, [r5, #8] <== NOT EXECUTED 3aa4: e0813003 add r3, r1, r3 <== NOT EXECUTED 3aa8: e5823000 str r3, [r2] <== NOT EXECUTED } break; } rtems_semaphore_release (tty->osem); 3aac: e5940018 ldr r0, [r4, #24] 3ab0: eb000432 bl 4b80 args->ioctl_return = sc; 3ab4: e585600c str r6, [r5, #12] return sc; } 3ab8: e1a00006 mov r0, r6 3abc: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 3ac0: 4004667f .word 0x4004667f 3ac4: 4004741a .word 0x4004741a 3ac8: 000189c0 .word 0x000189c0 00003c64 : rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) { 3c64: e92d4ff3 push {r0, r1, r4, r5, r6, r7, r8, r9, sl, fp, lr} 3c68: e1a08002 mov r8, r2 struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, 3c6c: e59f23e0 ldr r2, [pc, #992] ; 4054 rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) { 3c70: e1a0a001 mov sl, r1 struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, 3c74: e3a01000 mov r1, #0 rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) { 3c78: e1a09000 mov r9, r0 struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, 3c7c: e5920000 ldr r0, [r2] 3c80: e1a02001 mov r2, r1 rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) { 3c84: e1a0b003 mov fp, r3 struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, 3c88: eb000376 bl 4a68 RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) 3c8c: e2506000 subs r6, r0, #0 return sc; for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) { 3c90: 059f33c0 ldreq r3, [pc, #960] ; 4058 3c94: 05935000 ldreq r5, [r3] /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) 3c98: 0a000007 beq 3cbc 3c9c: ea0000e2 b 402c <== NOT EXECUTED return sc; for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) { if ((tty->major == major) && (tty->minor == minor)) 3ca0: e595300c ldr r3, [r5, #12] 3ca4: e1530009 cmp r3, r9 3ca8: 1a000002 bne 3cb8 3cac: e5953010 ldr r3, [r5, #16] 3cb0: e153000a cmp r3, sl 3cb4: 0a0000bb beq 3fa8 */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) return sc; for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) { 3cb8: e5955000 ldr r5, [r5] 3cbc: e3550000 cmp r5, #0 3cc0: 1afffff6 bne 3ca0 3cc4: ea0000da b 4034 return RTEMS_NO_MEMORY; } /* * allocate raw input buffer */ tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE; 3cc8: e59f738c ldr r7, [pc, #908] ; 405c 3ccc: e5973004 ldr r3, [r7, #4] 3cd0: e5853064 str r3, [r5, #100] ; 0x64 tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size); 3cd4: e5950064 ldr r0, [r5, #100] ; 0x64 3cd8: ebfff7cc bl 1c10 if (tty->rawInBuf.theBuf == NULL) { 3cdc: e3500000 cmp r0, #0 } /* * allocate raw input buffer */ tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE; tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size); 3ce0: e5850058 str r0, [r5, #88] ; 0x58 if (tty->rawInBuf.theBuf == NULL) { 3ce4: 1a000006 bne 3d04 free(tty); 3ce8: e1a00005 mov r0, r5 <== NOT EXECUTED 3cec: ebfff715 bl 1948 <== NOT EXECUTED rtems_semaphore_release (rtems_termios_ttyMutex); 3cf0: e59f335c ldr r3, [pc, #860] ; 4054 <== NOT EXECUTED 3cf4: e5930000 ldr r0, [r3] <== NOT EXECUTED 3cf8: eb0003a0 bl 4b80 <== NOT EXECUTED 3cfc: e3a0601a mov r6, #26 <== NOT EXECUTED return RTEMS_NO_MEMORY; 3d00: ea0000c9 b 402c <== NOT EXECUTED } /* * allocate raw output buffer */ tty->rawOutBuf.Size = RAW_OUTPUT_BUFFER_SIZE; 3d04: e5973008 ldr r3, [r7, #8] 3d08: e5853088 str r3, [r5, #136] ; 0x88 tty->rawOutBuf.theBuf = malloc (tty->rawOutBuf.Size); 3d0c: e5950088 ldr r0, [r5, #136] ; 0x88 3d10: ebfff7be bl 1c10 if (tty->rawOutBuf.theBuf == NULL) { 3d14: e3500000 cmp r0, #0 } /* * allocate raw output buffer */ tty->rawOutBuf.Size = RAW_OUTPUT_BUFFER_SIZE; tty->rawOutBuf.theBuf = malloc (tty->rawOutBuf.Size); 3d18: e585007c str r0, [r5, #124] ; 0x7c if (tty->rawOutBuf.theBuf == NULL) { 3d1c: 0a000006 beq 3d3c return RTEMS_NO_MEMORY; } /* * allocate cooked buffer */ tty->cbuf = malloc (CBUFSIZE); 3d20: e5970000 ldr r0, [r7] 3d24: ebfff7b9 bl 1c10 if (tty->cbuf == NULL) { 3d28: e3500000 cmp r0, #0 return RTEMS_NO_MEMORY; } /* * allocate cooked buffer */ tty->cbuf = malloc (CBUFSIZE); 3d2c: e585001c str r0, [r5, #28] if (tty->cbuf == NULL) { 3d30: 1a000004 bne 3d48 free((void *)(tty->rawOutBuf.theBuf)); 3d34: e595007c ldr r0, [r5, #124] ; 0x7c <== NOT EXECUTED 3d38: ebfff702 bl 1948 <== NOT EXECUTED free((void *)(tty->rawInBuf.theBuf)); 3d3c: e5950058 ldr r0, [r5, #88] ; 0x58 <== NOT EXECUTED 3d40: ebfff700 bl 1948 <== NOT EXECUTED 3d44: eaffffe7 b 3ce8 <== NOT EXECUTED tty->tty_rcvwakeup = 0; /* * link tty */ tty->forw = rtems_termios_ttyHead; 3d48: e59f3308 ldr r3, [pc, #776] ; 4058 3d4c: e5932000 ldr r2, [r3] return RTEMS_NO_MEMORY; } /* * Initialize wakeup callbacks */ tty->tty_snd.sw_pfn = NULL; 3d50: e3a03000 mov r3, #0 /* * link tty */ tty->forw = rtems_termios_ttyHead; tty->back = NULL; if (rtems_termios_ttyHead != NULL) 3d54: e3520000 cmp r2, #0 /* * link tty */ tty->forw = rtems_termios_ttyHead; tty->back = NULL; 3d58: e885000c stm r5, {r2, r3} if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty; 3d5c: 15825004 strne r5, [r2, #4] return RTEMS_NO_MEMORY; } /* * Initialize wakeup callbacks */ tty->tty_snd.sw_pfn = NULL; 3d60: e58530d4 str r3, [r5, #212] ; 0xd4 tty->tty_snd.sw_arg = NULL; 3d64: e58530d8 str r3, [r5, #216] ; 0xd8 tty->tty_rcv.sw_pfn = NULL; 3d68: e58530dc str r3, [r5, #220] ; 0xdc tty->tty_rcv.sw_arg = NULL; 3d6c: e58530e0 str r3, [r5, #224] ; 0xe0 tty->tty_rcvwakeup = 0; 3d70: e58530e4 str r3, [r5, #228] ; 0xe4 tty->forw = rtems_termios_ttyHead; tty->back = NULL; if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty; if (rtems_termios_ttyTail == NULL) 3d74: e59f32e4 ldr r3, [pc, #740] ; 4060 3d78: e5932000 ldr r2, [r3] tty->major = major; /* * Set up mutex semaphores */ sc = rtems_semaphore_create ( 3d7c: e59f72d8 ldr r7, [pc, #728] ; 405c tty->forw = rtems_termios_ttyHead; tty->back = NULL; if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty; if (rtems_termios_ttyTail == NULL) 3d80: e3520000 cmp r2, #0 rtems_termios_ttyTail = tty; 3d84: 05834000 streq r4, [r3] */ tty->forw = rtems_termios_ttyHead; tty->back = NULL; if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty; 3d88: e59f22c8 ldr r2, [pc, #712] ; 4058 tty->major = major; /* * Set up mutex semaphores */ sc = rtems_semaphore_create ( 3d8c: e5d7300c ldrb r3, [r7, #12] 3d90: e59f02cc ldr r0, [pc, #716] ; 4064 */ tty->forw = rtems_termios_ttyHead; tty->back = NULL; if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty; 3d94: e5824000 str r4, [r2] tty->major = major; /* * Set up mutex semaphores */ sc = rtems_semaphore_create ( 3d98: e1830000 orr r0, r3, r0 rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty; if (rtems_termios_ttyTail == NULL) rtems_termios_ttyTail = tty; tty->minor = minor; 3d9c: e584a010 str sl, [r4, #16] tty->major = major; 3da0: e584900c str r9, [r4, #12] /* * Set up mutex semaphores */ sc = rtems_semaphore_create ( 3da4: e284c014 add ip, r4, #20 3da8: e3a03000 mov r3, #0 3dac: e3a01001 mov r1, #1 3db0: e3a02054 mov r2, #84 ; 0x54 3db4: e58dc000 str ip, [sp] 3db8: eb000298 bl 4820 rtems_build_name ('T', 'R', 'i', c), 1, RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &tty->isem); if (sc != RTEMS_SUCCESSFUL) 3dbc: e2503000 subs r3, r0, #0 3dc0: 1a000095 bne 401c rtems_fatal_error_occurred (sc); sc = rtems_semaphore_create ( 3dc4: e5d7200c ldrb r2, [r7, #12] 3dc8: e59f0298 ldr r0, [pc, #664] ; 4068 3dcc: e284c018 add ip, r4, #24 3dd0: e1820000 orr r0, r2, r0 3dd4: e3a01001 mov r1, #1 3dd8: e3a02054 mov r2, #84 ; 0x54 3ddc: e58dc000 str ip, [sp] 3de0: eb00028e bl 4820 rtems_build_name ('T', 'R', 'o', c), 1, RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &tty->osem); if (sc != RTEMS_SUCCESSFUL) 3de4: e2501000 subs r1, r0, #0 3de8: 1a00008b bne 401c rtems_fatal_error_occurred (sc); sc = rtems_semaphore_create ( 3dec: e5d7300c ldrb r3, [r7, #12] 3df0: e59f0274 ldr r0, [pc, #628] ; 406c 3df4: e284c08c add ip, r4, #140 ; 0x8c 3df8: e1830000 orr r0, r3, r0 3dfc: e3a02020 mov r2, #32 3e00: e1a03001 mov r3, r1 3e04: e58dc000 str ip, [sp] 3e08: eb000284 bl 4820 rtems_build_name ('T', 'R', 'x', c), 0, RTEMS_SIMPLE_BINARY_SEMAPHORE | RTEMS_FIFO, RTEMS_NO_PRIORITY, &tty->rawOutBuf.Semaphore); if (sc != RTEMS_SUCCESSFUL) 3e0c: e250e000 subs lr, r0, #0 3e10: 1a000081 bne 401c tty->rawOutBufState = rob_idle; /* * Set callbacks */ tty->device = *callbacks; 3e14: e8bb000f ldm fp!, {r0, r1, r2, r3} 3e18: e284c098 add ip, r4, #152 ; 0x98 3e1c: e8ac000f stmia ip!, {r0, r1, r2, r3} 3e20: e89b000f ldm fp, {r0, r1, r2, r3} 3e24: e88c000f stm ip, {r0, r1, r2, r3} /* * Create I/O tasks */ if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) { 3e28: e59430b4 ldr r3, [r4, #180] ; 0xb4 3e2c: e3530002 cmp r3, #2 RTEMS_SIMPLE_BINARY_SEMAPHORE | RTEMS_FIFO, RTEMS_NO_PRIORITY, &tty->rawOutBuf.Semaphore); if (sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred (sc); tty->rawOutBufState = rob_idle; 3e30: e584e094 str lr, [r4, #148] ; 0x94 tty->device = *callbacks; /* * Create I/O tasks */ if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) { 3e34: 1a000017 bne 3e98 sc = rtems_task_create ( 3e38: e5d7300c ldrb r3, [r7, #12] <== NOT EXECUTED 3e3c: e59f022c ldr r0, [pc, #556] ; 4070 <== NOT EXECUTED 3e40: e284c0c8 add ip, r4, #200 ; 0xc8 <== NOT EXECUTED 3e44: e1830000 orr r0, r3, r0 <== NOT EXECUTED 3e48: e3a0100a mov r1, #10 <== NOT EXECUTED 3e4c: e3a02b01 mov r2, #1024 ; 0x400 <== NOT EXECUTED 3e50: e3a03c05 mov r3, #1280 ; 0x500 <== NOT EXECUTED 3e54: e58de000 str lr, [sp] <== NOT EXECUTED 3e58: e58dc004 str ip, [sp, #4] <== NOT EXECUTED 3e5c: eb00036e bl 4c1c <== NOT EXECUTED TERMIOS_TXTASK_STACKSIZE, RTEMS_NO_PREEMPT | RTEMS_NO_TIMESLICE | RTEMS_NO_ASR, RTEMS_NO_FLOATING_POINT | RTEMS_LOCAL, &tty->txTaskId); if (sc != RTEMS_SUCCESSFUL) 3e60: e250e000 subs lr, r0, #0 <== NOT EXECUTED 3e64: 1a00006c bne 401c <== NOT EXECUTED rtems_fatal_error_occurred (sc); sc = rtems_task_create ( 3e68: e5d7300c ldrb r3, [r7, #12] <== NOT EXECUTED 3e6c: e59f0200 ldr r0, [pc, #512] ; 4074 <== NOT EXECUTED 3e70: e284c0c4 add ip, r4, #196 ; 0xc4 <== NOT EXECUTED 3e74: e1830000 orr r0, r3, r0 <== NOT EXECUTED 3e78: e3a01009 mov r1, #9 <== NOT EXECUTED 3e7c: e3a02b01 mov r2, #1024 ; 0x400 <== NOT EXECUTED 3e80: e3a03c05 mov r3, #1280 ; 0x500 <== NOT EXECUTED 3e84: e58de000 str lr, [sp] <== NOT EXECUTED 3e88: e58dc004 str ip, [sp, #4] <== NOT EXECUTED 3e8c: eb000362 bl 4c1c <== NOT EXECUTED TERMIOS_RXTASK_STACKSIZE, RTEMS_NO_PREEMPT | RTEMS_NO_TIMESLICE | RTEMS_NO_ASR, RTEMS_NO_FLOATING_POINT | RTEMS_LOCAL, &tty->rxTaskId); if (sc != RTEMS_SUCCESSFUL) 3e90: e3500000 cmp r0, #0 <== NOT EXECUTED 3e94: 1a000060 bne 401c <== NOT EXECUTED rtems_fatal_error_occurred (sc); } if ((tty->device.pollRead == NULL) || 3e98: e59430a0 ldr r3, [r4, #160] ; 0xa0 3e9c: e3530000 cmp r3, #0 3ea0: 0a000002 beq 3eb0 (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN)){ 3ea4: e59430b4 ldr r3, [r4, #180] ; 0xb4 3ea8: e3530002 cmp r3, #2 3eac: 1a00000b bne 3ee0 sc = rtems_semaphore_create ( 3eb0: e59f31a4 ldr r3, [pc, #420] ; 405c <== NOT EXECUTED 3eb4: e59f01bc ldr r0, [pc, #444] ; 4078 <== NOT EXECUTED 3eb8: e5d3300c ldrb r3, [r3, #12] <== NOT EXECUTED 3ebc: e3a01000 mov r1, #0 <== NOT EXECUTED 3ec0: e1830000 orr r0, r3, r0 <== NOT EXECUTED 3ec4: e284c068 add ip, r4, #104 ; 0x68 <== NOT EXECUTED 3ec8: e3a02024 mov r2, #36 ; 0x24 <== NOT EXECUTED 3ecc: e1a03001 mov r3, r1 <== NOT EXECUTED 3ed0: e58dc000 str ip, [sp] <== NOT EXECUTED 3ed4: eb000251 bl 4820 <== NOT EXECUTED rtems_build_name ('T', 'R', 'r', c), 0, RTEMS_SIMPLE_BINARY_SEMAPHORE | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &tty->rawInBuf.Semaphore); if (sc != RTEMS_SUCCESSFUL) 3ed8: e3500000 cmp r0, #0 <== NOT EXECUTED 3edc: 1a00004e bne 401c <== NOT EXECUTED tty->termios.c_cc[VINTR] = '\003'; tty->termios.c_cc[VQUIT] = '\034'; tty->termios.c_cc[VERASE] = '\177'; tty->termios.c_cc[VKILL] = '\025'; tty->termios.c_cc[VEOF] = '\004'; tty->termios.c_cc[VEOL] = '\000'; 3ee0: e3a03000 mov r3, #0 tty->termios.c_cc[VDISCARD] = '\017'; tty->termios.c_cc[VWERASE] = '\027'; tty->termios.c_cc[VLNEXT] = '\026'; /* start with no flow control, clear flow control flags */ tty->flow_ctrl = 0; 3ee4: e58430b8 str r3, [r4, #184] ; 0xb8 /* * set low/highwater mark for XON/XOFF support */ tty->lowwater = tty->rawInBuf.Size * 1/2; 3ee8: e5941064 ldr r1, [r4, #100] ; 0x64 tty->highwater = tty->rawInBuf.Size * 3/4; 3eec: e594c064 ldr ip, [r4, #100] ; 0x64 tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL; tty->termios.c_oflag = OPOST | ONLCR | XTABS; tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL; tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL; tty->termios.c_cc[VINTR] = '\003'; 3ef0: e3a02003 mov r2, #3 tty->flow_ctrl = 0; /* * set low/highwater mark for XON/XOFF support */ tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; 3ef4: e0000c92 mul r0, r2, ip tty->termios.c_oflag = OPOST | ONLCR | XTABS; tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL; tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL; tty->termios.c_cc[VINTR] = '\003'; tty->termios.c_cc[VQUIT] = '\034'; 3ef8: e3a0c01c mov ip, #28 3efc: e5c4c042 strb ip, [r4, #66] ; 0x42 tty->termios.c_cc[VERASE] = '\177'; 3f00: e28cc063 add ip, ip, #99 ; 0x63 3f04: e5c4c043 strb ip, [r4, #67] ; 0x43 tty->termios.c_cc[VKILL] = '\025'; 3f08: e3a0c015 mov ip, #21 3f0c: e5c4c044 strb ip, [r4, #68] ; 0x44 tty->termios.c_cc[VEOF] = '\004'; 3f10: e3a0c004 mov ip, #4 3f14: e5c4c045 strb ip, [r4, #69] ; 0x45 tty->termios.c_cc[VEOL] = '\000'; tty->termios.c_cc[VEOL2] = '\000'; tty->termios.c_cc[VSTART] = '\021'; 3f18: e28cc00d add ip, ip, #13 3f1c: e5c4c049 strb ip, [r4, #73] ; 0x49 tty->termios.c_cc[VSTOP] = '\023'; 3f20: e28cc002 add ip, ip, #2 3f24: e5c4c04a strb ip, [r4, #74] ; 0x4a tty->termios.c_cc[VSUSP] = '\032'; 3f28: e28cc007 add ip, ip, #7 3f2c: e5c4c04b strb ip, [r4, #75] ; 0x4b tty->termios.c_cc[VREPRINT] = '\022'; 3f30: e3a0c012 mov ip, #18 3f34: e5c4c04d strb ip, [r4, #77] ; 0x4d tty->termios.c_cc[VDISCARD] = '\017'; 3f38: e3a0c00f mov ip, #15 3f3c: e5c4c04e strb ip, [r4, #78] ; 0x4e tty->termios.c_cc[VWERASE] = '\027'; 3f40: e28cc008 add ip, ip, #8 3f44: e5c4c04f strb ip, [r4, #79] ; 0x4f tty->termios.c_cc[VLNEXT] = '\026'; 3f48: e3a0c016 mov ip, #22 tty->termios.c_cc[VINTR] = '\003'; tty->termios.c_cc[VQUIT] = '\034'; tty->termios.c_cc[VERASE] = '\177'; tty->termios.c_cc[VKILL] = '\025'; tty->termios.c_cc[VEOF] = '\004'; tty->termios.c_cc[VEOL] = '\000'; 3f4c: e5c4304c strb r3, [r4, #76] ; 0x4c tty->termios.c_cc[VEOL2] = '\000'; 3f50: e5c43051 strb r3, [r4, #81] ; 0x51 tty->termios.c_cc[VSTOP] = '\023'; tty->termios.c_cc[VSUSP] = '\032'; tty->termios.c_cc[VREPRINT] = '\022'; tty->termios.c_cc[VDISCARD] = '\017'; tty->termios.c_cc[VWERASE] = '\027'; tty->termios.c_cc[VLNEXT] = '\026'; 3f54: e5c4c050 strb ip, [r4, #80] ; 0x50 tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL; tty->termios.c_oflag = OPOST | ONLCR | XTABS; tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL; tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL; tty->termios.c_cc[VINTR] = '\003'; 3f58: e5c42041 strb r2, [r4, #65] ; 0x41 tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z') 3f5c: e59f30f8 ldr r3, [pc, #248] ; 405c tty->flow_ctrl = 0; /* * set low/highwater mark for XON/XOFF support */ tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; 3f60: e1a00120 lsr r0, r0, #2 /* * Bump name characer */ if (c++ == 'z') 3f64: e5d3200c ldrb r2, [r3, #12] tty->flow_ctrl = 0; /* * set low/highwater mark for XON/XOFF support */ tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; 3f68: e58400c0 str r0, [r4, #192] ; 0xc0 } /* * Set default parameters */ tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL; 3f6c: e59f0108 ldr r0, [pc, #264] ; 407c 3f70: e5840030 str r0, [r4, #48] ; 0x30 tty->termios.c_oflag = OPOST | ONLCR | XTABS; 3f74: e59f0104 ldr r0, [pc, #260] ; 4080 3f78: e5840034 str r0, [r4, #52] ; 0x34 tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL; 3f7c: e59f0100 ldr r0, [pc, #256] ; 4084 3f80: e5840038 str r0, [r4, #56] ; 0x38 tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL; 3f84: e59f00fc ldr r0, [pc, #252] ; 4088 tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z') 3f88: e352007a cmp r2, #122 ; 0x7a /* start with no flow control, clear flow control flags */ tty->flow_ctrl = 0; /* * set low/highwater mark for XON/XOFF support */ tty->lowwater = tty->rawInBuf.Size * 1/2; 3f8c: e1a010a1 lsr r1, r1, #1 tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z') 3f90: e2822001 add r2, r2, #1 * Set default parameters */ tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL; tty->termios.c_oflag = OPOST | ONLCR | XTABS; tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL; tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL; 3f94: e584003c str r0, [r4, #60] ; 0x3c /* start with no flow control, clear flow control flags */ tty->flow_ctrl = 0; /* * set low/highwater mark for XON/XOFF support */ tty->lowwater = tty->rawInBuf.Size * 1/2; 3f98: e58410bc str r1, [r4, #188] ; 0xbc tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z') 3f9c: e5c3200c strb r2, [r3, #12] c = 'a'; 3fa0: 03a02061 moveq r2, #97 ; 0x61 3fa4: 05c3200c strbeq r2, [r3, #12] } args->iop->data1 = tty; if (!tty->refcount++) { 3fa8: e5953008 ldr r3, [r5, #8] */ if (c++ == 'z') c = 'a'; } args->iop->data1 = tty; 3fac: e5982000 ldr r2, [r8] if (!tty->refcount++) { 3fb0: e3530000 cmp r3, #0 3fb4: e2833001 add r3, r3, #1 */ if (c++ == 'z') c = 'a'; } args->iop->data1 = tty; 3fb8: e5825034 str r5, [r2, #52] ; 0x34 if (!tty->refcount++) { 3fbc: e5853008 str r3, [r5, #8] 3fc0: 1a000016 bne 4020 if (tty->device.firstOpen) 3fc4: e5953098 ldr r3, [r5, #152] ; 0x98 3fc8: e3530000 cmp r3, #0 (*tty->device.firstOpen)(major, minor, arg); 3fcc: 11a00009 movne r0, r9 3fd0: 11a0100a movne r1, sl 3fd4: 11a02008 movne r2, r8 3fd8: 11a0e00f movne lr, pc 3fdc: 112fff13 bxne r3 /* * start I/O tasks, if needed */ if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) { 3fe0: e59530b4 ldr r3, [r5, #180] ; 0xb4 3fe4: e3530002 cmp r3, #2 3fe8: 1a00000c bne 4020 sc = rtems_task_start(tty->rxTaskId, 3fec: e59500c4 ldr r0, [r5, #196] ; 0xc4 <== NOT EXECUTED 3ff0: e59f1094 ldr r1, [pc, #148] ; 408c <== NOT EXECUTED 3ff4: e1a02005 mov r2, r5 <== NOT EXECUTED 3ff8: eb0003ac bl 4eb0 <== NOT EXECUTED rtems_termios_rxdaemon, (rtems_task_argument)tty); if (sc != RTEMS_SUCCESSFUL) 3ffc: e3500000 cmp r0, #0 <== NOT EXECUTED 4000: 1a000005 bne 401c <== NOT EXECUTED rtems_fatal_error_occurred (sc); sc = rtems_task_start(tty->txTaskId, 4004: e1a02005 mov r2, r5 <== NOT EXECUTED 4008: e59500c8 ldr r0, [r5, #200] ; 0xc8 <== NOT EXECUTED 400c: e59f107c ldr r1, [pc, #124] ; 4090 <== NOT EXECUTED 4010: eb0003a6 bl 4eb0 <== NOT EXECUTED rtems_termios_txdaemon, (rtems_task_argument)tty); if (sc != RTEMS_SUCCESSFUL) 4014: e3500000 cmp r0, #0 <== NOT EXECUTED 4018: 0a000000 beq 4020 <== NOT EXECUTED rtems_fatal_error_occurred (sc); 401c: eb000424 bl 50b4 <== NOT EXECUTED } } rtems_semaphore_release (rtems_termios_ttyMutex); 4020: e59f302c ldr r3, [pc, #44] ; 4054 4024: e5930000 ldr r0, [r3] 4028: eb0002d4 bl 4b80 return RTEMS_SUCCESSFUL; } 402c: e1a00006 mov r0, r6 4030: e8bd8ffc pop {r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} static char c = 'a'; /* * Create a new device */ tty = calloc (1, sizeof (struct rtems_termios_tty)); 4034: e3a00001 mov r0, #1 4038: e3a010e8 mov r1, #232 ; 0xe8 403c: eb001392 bl 8e8c if (tty == NULL) { 4040: e3500000 cmp r0, #0 static char c = 'a'; /* * Create a new device */ tty = calloc (1, sizeof (struct rtems_termios_tty)); 4044: e1a05000 mov r5, r0 4048: e1a04000 mov r4, r0 if (tty == NULL) { 404c: 1affff1d bne 3cc8 4050: eaffff26 b 3cf0 <== NOT EXECUTED 4054: 00018d00 .word 0x00018d00 4058: 00018d08 .word 0x00018d08 405c: 00017704 .word 0x00017704 4060: 00018d04 .word 0x00018d04 4064: 54526900 .word 0x54526900 4068: 54526f00 .word 0x54526f00 406c: 54527800 .word 0x54527800 4070: 54785400 .word 0x54785400 4074: 52785400 .word 0x52785400 4078: 54527200 .word 0x54527200 407c: 00002502 .word 0x00002502 4080: 00001805 .word 0x00001805 4084: 000008bd .word 0x000008bd 4088: 0000823b .word 0x0000823b 408c: 00004100 .word 0x00004100 4090: 00004094 .word 0x00004094 00002c00 : const unsigned char *buf = _buf; unsigned int newHead; rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) { 2c00: e59230b4 ldr r3, [r2, #180] ; 0xb4 2c04: e3530000 cmp r3, #0 * Send characters to device-specific code */ void rtems_termios_puts ( const void *_buf, int len, struct rtems_termios_tty *tty) { 2c08: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 2c0c: e1a04002 mov r4, r2 2c10: e1a0a000 mov sl, r0 2c14: e1a06001 mov r6, r1 const unsigned char *buf = _buf; unsigned int newHead; rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) { 2c18: 1a000005 bne 2c34 (*tty->device.write)(tty->minor, (void *)buf, len); 2c1c: e1a01000 mov r1, r0 2c20: e1a02006 mov r2, r6 2c24: e5940010 ldr r0, [r4, #16] 2c28: e1a0e00f mov lr, pc 2c2c: e594f0a4 ldr pc, [r4, #164] ; 0xa4 return; 2c30: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} } newHead = tty->rawOutBuf.Head; 2c34: e5925080 ldr r5, [r2, #128] ; 0x80 <== NOT EXECUTED 2c38: e3a07000 mov r7, #0 <== NOT EXECUTED * with interrupts enabled. */ newHead = (newHead + 1) % tty->rawOutBuf.Size; rtems_interrupt_disable (level); while (newHead == tty->rawOutBuf.Tail) { tty->rawOutBufState = rob_wait; 2c3c: e3a09002 mov r9, #2 <== NOT EXECUTED } else { /* remember that output has been stopped due to flow ctrl*/ tty->flow_ctrl |= FL_OSTOP; } tty->rawOutBufState = rob_busy; 2c40: e3a0b001 mov fp, #1 <== NOT EXECUTED if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) { (*tty->device.write)(tty->minor, (void *)buf, len); return; } newHead = tty->rawOutBuf.Head; while (len) { 2c44: ea00002e b 2d04 <== NOT EXECUTED * len -= ncopy * * To minimize latency, the memcpy should be done * with interrupts enabled. */ newHead = (newHead + 1) % tty->rawOutBuf.Size; 2c48: e5941088 ldr r1, [r4, #136] ; 0x88 <== NOT EXECUTED 2c4c: e2850001 add r0, r5, #1 <== NOT EXECUTED 2c50: eb0049c5 bl 1536c <__umodsi3> <== NOT EXECUTED 2c54: e1a05000 mov r5, r0 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 2c58: e10f8000 mrs r8, CPSR <== NOT EXECUTED 2c5c: e3883080 orr r3, r8, #128 ; 0x80 <== NOT EXECUTED 2c60: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED rtems_interrupt_disable (level); while (newHead == tty->rawOutBuf.Tail) { 2c64: ea00000a b 2c94 <== NOT EXECUTED tty->rawOutBufState = rob_wait; 2c68: e5849094 str r9, [r4, #148] ; 0x94 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 2c6c: e129f008 msr CPSR_fc, r8 <== NOT EXECUTED rtems_interrupt_enable (level); sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore, 2c70: e3a01000 mov r1, #0 <== NOT EXECUTED 2c74: e594008c ldr r0, [r4, #140] ; 0x8c <== NOT EXECUTED 2c78: e1a02001 mov r2, r1 <== NOT EXECUTED 2c7c: eb000779 bl 4a68 <== NOT EXECUTED RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) 2c80: e3500000 cmp r0, #0 <== NOT EXECUTED rtems_fatal_error_occurred (sc); 2c84: 1b00090a blne 50b4 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 2c88: e10f8000 mrs r8, CPSR <== NOT EXECUTED 2c8c: e3883080 orr r3, r8, #128 ; 0x80 <== NOT EXECUTED 2c90: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED * To minimize latency, the memcpy should be done * with interrupts enabled. */ newHead = (newHead + 1) % tty->rawOutBuf.Size; rtems_interrupt_disable (level); while (newHead == tty->rawOutBuf.Tail) { 2c94: e5943084 ldr r3, [r4, #132] ; 0x84 <== NOT EXECUTED 2c98: e1550003 cmp r5, r3 <== NOT EXECUTED 2c9c: 0afffff1 beq 2c68 <== NOT EXECUTED RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred (sc); rtems_interrupt_disable (level); } tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++; 2ca0: e5943080 ldr r3, [r4, #128] ; 0x80 <== NOT EXECUTED 2ca4: e7da1007 ldrb r1, [sl, r7] <== NOT EXECUTED 2ca8: e594207c ldr r2, [r4, #124] ; 0x7c <== NOT EXECUTED 2cac: e7c21003 strb r1, [r2, r3] <== NOT EXECUTED tty->rawOutBuf.Head = newHead; if (tty->rawOutBufState == rob_idle) { 2cb0: e5943094 ldr r3, [r4, #148] ; 0x94 <== NOT EXECUTED 2cb4: e3530000 cmp r3, #0 <== NOT EXECUTED if (sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred (sc); rtems_interrupt_disable (level); } tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++; tty->rawOutBuf.Head = newHead; 2cb8: e5845080 str r5, [r4, #128] ; 0x80 <== NOT EXECUTED if (tty->rawOutBufState == rob_idle) { 2cbc: 1a00000d bne 2cf8 <== NOT EXECUTED /* check, whether XOFF has been received */ if (!(tty->flow_ctrl & FL_ORCVXOF)) { 2cc0: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2cc4: e3130010 tst r3, #16 <== NOT EXECUTED (*tty->device.write)(tty->minor, (char *)&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1); } else { /* remember that output has been stopped due to flow ctrl*/ tty->flow_ctrl |= FL_OSTOP; 2cc8: 159430b8 ldrne r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2ccc: 13833020 orrne r3, r3, #32 <== NOT EXECUTED 2cd0: 158430b8 strne r3, [r4, #184] ; 0xb8 <== NOT EXECUTED } tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++; tty->rawOutBuf.Head = newHead; if (tty->rawOutBufState == rob_idle) { /* check, whether XOFF has been received */ if (!(tty->flow_ctrl & FL_ORCVXOF)) { 2cd4: 1a000006 bne 2cf4 <== NOT EXECUTED (*tty->device.write)(tty->minor, (char *)&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1); 2cd8: e5943084 ldr r3, [r4, #132] ; 0x84 <== NOT EXECUTED tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++; tty->rawOutBuf.Head = newHead; if (tty->rawOutBufState == rob_idle) { /* check, whether XOFF has been received */ if (!(tty->flow_ctrl & FL_ORCVXOF)) { (*tty->device.write)(tty->minor, 2cdc: e594107c ldr r1, [r4, #124] ; 0x7c <== NOT EXECUTED 2ce0: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 2ce4: e0811003 add r1, r1, r3 <== NOT EXECUTED 2ce8: e3a02001 mov r2, #1 <== NOT EXECUTED 2cec: e1a0e00f mov lr, pc <== NOT EXECUTED 2cf0: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED } else { /* remember that output has been stopped due to flow ctrl*/ tty->flow_ctrl |= FL_OSTOP; } tty->rawOutBufState = rob_busy; 2cf4: e584b094 str fp, [r4, #148] ; 0x94 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 2cf8: e129f008 msr CPSR_fc, r8 <== NOT EXECUTED } rtems_interrupt_enable (level); len--; 2cfc: e2466001 sub r6, r6, #1 <== NOT EXECUTED 2d00: e2877001 add r7, r7, #1 <== NOT EXECUTED if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) { (*tty->device.write)(tty->minor, (void *)buf, len); return; } newHead = tty->rawOutBuf.Head; while (len) { 2d04: e3560000 cmp r6, #0 <== NOT EXECUTED 2d08: 1affffce bne 2c48 <== NOT EXECUTED 2d0c: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED 000033d4 : return RTEMS_SUCCESSFUL; } rtems_status_code rtems_termios_read (void *arg) { 33d4: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} <== NOT EXECUTED rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; 33d8: e5903000 ldr r3, [r0] <== NOT EXECUTED return RTEMS_SUCCESSFUL; } rtems_status_code rtems_termios_read (void *arg) { 33dc: e1a05000 mov r5, r0 <== NOT EXECUTED rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; 33e0: e5934034 ldr r4, [r3, #52] ; 0x34 <== NOT EXECUTED uint32_t count = args->count; char *buffer = args->buffer; rtems_status_code sc; sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 33e4: e3a01000 mov r1, #0 <== NOT EXECUTED rtems_termios_read (void *arg) { rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; uint32_t count = args->count; char *buffer = args->buffer; 33e8: e595300c ldr r3, [r5, #12] <== NOT EXECUTED rtems_status_code sc; sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 33ec: e5940014 ldr r0, [r4, #20] <== NOT EXECUTED 33f0: e1a02001 mov r2, r1 <== NOT EXECUTED rtems_status_code rtems_termios_read (void *arg) { rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; uint32_t count = args->count; 33f4: e5957010 ldr r7, [r5, #16] <== NOT EXECUTED char *buffer = args->buffer; 33f8: e58d3000 str r3, [sp] <== NOT EXECUTED rtems_status_code sc; sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 33fc: eb000599 bl 4a68 <== NOT EXECUTED if (sc != RTEMS_SUCCESSFUL) 3400: e2506000 subs r6, r0, #0 <== NOT EXECUTED 3404: 1a0000c1 bne 3710 <== NOT EXECUTED return sc; if (rtems_termios_linesw[tty->t_line].l_read != NULL) { 3408: e59420cc ldr r2, [r4, #204] ; 0xcc <== NOT EXECUTED 340c: e59f3304 ldr r3, [pc, #772] ; 3718 <== NOT EXECUTED 3410: e0833282 add r3, r3, r2, lsl #5 <== NOT EXECUTED 3414: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED 3418: e3530000 cmp r3, #0 <== NOT EXECUTED 341c: 0a000005 beq 3438 <== NOT EXECUTED sc = rtems_termios_linesw[tty->t_line].l_read(tty,args); 3420: e1a01005 mov r1, r5 <== NOT EXECUTED 3424: e1a00004 mov r0, r4 <== NOT EXECUTED 3428: e1a0e00f mov lr, pc <== NOT EXECUTED 342c: e12fff13 bx r3 <== NOT EXECUTED 3430: e1a06000 mov r6, r0 <== NOT EXECUTED 3434: ea0000b1 b 3700 <== NOT EXECUTED tty->tty_rcvwakeup = 0; rtems_semaphore_release (tty->isem); return sc; } if (tty->cindex == tty->ccount) { 3438: e5942024 ldr r2, [r4, #36] ; 0x24 <== NOT EXECUTED 343c: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED 3440: e1520003 cmp r2, r3 <== NOT EXECUTED 3444: 1a00009a bne 36b4 <== NOT EXECUTED tty->cindex = tty->ccount = 0; tty->read_start_column = tty->column; if (tty->device.pollRead != NULL 3448: e59420a0 ldr r2, [r4, #160] ; 0xa0 <== NOT EXECUTED rtems_semaphore_release (tty->isem); return sc; } if (tty->cindex == tty->ccount) { tty->cindex = tty->ccount = 0; tty->read_start_column = tty->column; 344c: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED if (tty->device.pollRead != NULL 3450: e3520000 cmp r2, #0 <== NOT EXECUTED rtems_semaphore_release (tty->isem); return sc; } if (tty->cindex == tty->ccount) { tty->cindex = tty->ccount = 0; tty->read_start_column = tty->column; 3454: e584302c str r3, [r4, #44] ; 0x2c <== NOT EXECUTED tty->tty_rcvwakeup = 0; rtems_semaphore_release (tty->isem); return sc; } if (tty->cindex == tty->ccount) { tty->cindex = tty->ccount = 0; 3458: e5846020 str r6, [r4, #32] <== NOT EXECUTED 345c: e5846024 str r6, [r4, #36] ; 0x24 <== NOT EXECUTED tty->read_start_column = tty->column; if (tty->device.pollRead != NULL 3460: 0a00003b beq 3554 <== NOT EXECUTED && tty->device.outputUsesInterrupts == TERMIOS_POLLED) 3464: e59430b4 ldr r3, [r4, #180] ; 0xb4 <== NOT EXECUTED 3468: e3530000 cmp r3, #0 <== NOT EXECUTED 346c: 1a000038 bne 3554 <== NOT EXECUTED static rtems_status_code fillBufferPoll (struct rtems_termios_tty *tty) { int n; if (tty->termios.c_lflag & ICANON) { 3470: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 3474: e3130002 tst r3, #2 <== NOT EXECUTED 3478: 0a00000d beq 34b4 <== NOT EXECUTED for (;;) { n = (*tty->device.pollRead)(tty->minor); 347c: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 3480: e1a0e00f mov lr, pc <== NOT EXECUTED 3484: e594f0a0 ldr pc, [r4, #160] ; 0xa0 <== NOT EXECUTED if (n < 0) { 3488: e3500000 cmp r0, #0 <== NOT EXECUTED rtems_task_wake_after (1); } else { if (siproc (n, tty)) 348c: e1a01004 mov r1, r4 <== NOT EXECUTED 3490: e20000ff and r0, r0, #255 ; 0xff <== NOT EXECUTED int n; if (tty->termios.c_lflag & ICANON) { for (;;) { n = (*tty->device.pollRead)(tty->minor); if (n < 0) { 3494: aa000002 bge 34a4 <== NOT EXECUTED rtems_task_wake_after (1); 3498: e3a00001 mov r0, #1 <== NOT EXECUTED 349c: eb00069b bl 4f10 <== NOT EXECUTED 34a0: eafffff5 b 347c <== NOT EXECUTED } else { if (siproc (n, tty)) 34a4: ebffff67 bl 3248 <== NOT EXECUTED 34a8: e3500000 cmp r0, #0 <== NOT EXECUTED 34ac: 0afffff2 beq 347c <== NOT EXECUTED 34b0: ea00007f b 36b4 <== NOT EXECUTED } } } else { rtems_interval then, now; then = rtems_clock_get_ticks_since_boot(); 34b4: eb0003de bl 4434 <== NOT EXECUTED 34b8: e1a08000 mov r8, r0 <== NOT EXECUTED for (;;) { n = (*tty->device.pollRead)(tty->minor); 34bc: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 34c0: e1a0e00f mov lr, pc <== NOT EXECUTED 34c4: e594f0a0 ldr pc, [r4, #160] ; 0xa0 <== NOT EXECUTED if (n < 0) { 34c8: e3500000 cmp r0, #0 <== NOT EXECUTED 34cc: aa000013 bge 3520 <== NOT EXECUTED if (tty->termios.c_cc[VMIN]) { 34d0: e5d43047 ldrb r3, [r4, #71] ; 0x47 <== NOT EXECUTED 34d4: e3530000 cmp r3, #0 <== NOT EXECUTED 34d8: e5d43046 ldrb r3, [r4, #70] ; 0x46 <== NOT EXECUTED 34dc: 0a000005 beq 34f8 <== NOT EXECUTED if (tty->termios.c_cc[VTIME] && tty->ccount) { 34e0: e3530000 cmp r3, #0 <== NOT EXECUTED 34e4: 0a00000a beq 3514 <== NOT EXECUTED 34e8: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED 34ec: e3530000 cmp r3, #0 <== NOT EXECUTED 34f0: 0a000007 beq 3514 <== NOT EXECUTED 34f4: ea000001 b 3500 <== NOT EXECUTED break; } } } else { if (!tty->termios.c_cc[VTIME]) 34f8: e3530000 cmp r3, #0 <== NOT EXECUTED 34fc: 0a00006c beq 36b4 <== NOT EXECUTED break; now = rtems_clock_get_ticks_since_boot(); 3500: eb0003cb bl 4434 <== NOT EXECUTED if ((now - then) > tty->vtimeTicks) { 3504: e5943054 ldr r3, [r4, #84] ; 0x54 <== NOT EXECUTED 3508: e0680000 rsb r0, r8, r0 <== NOT EXECUTED 350c: e1500003 cmp r0, r3 <== NOT EXECUTED 3510: 8a000067 bhi 36b4 <== NOT EXECUTED break; } } rtems_task_wake_after (1); 3514: e3a00001 mov r0, #1 <== NOT EXECUTED 3518: eb00067c bl 4f10 <== NOT EXECUTED 351c: eaffffe6 b 34bc <== NOT EXECUTED } else { siproc (n, tty); 3520: e20000ff and r0, r0, #255 ; 0xff <== NOT EXECUTED 3524: e1a01004 mov r1, r4 <== NOT EXECUTED 3528: ebffff46 bl 3248 <== NOT EXECUTED if (tty->ccount >= tty->termios.c_cc[VMIN]) 352c: e5d43047 ldrb r3, [r4, #71] ; 0x47 <== NOT EXECUTED 3530: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED 3534: e1520003 cmp r2, r3 <== NOT EXECUTED 3538: aa00005d bge 36b4 <== NOT EXECUTED break; if (tty->termios.c_cc[VMIN] && tty->termios.c_cc[VTIME]) 353c: e3530000 cmp r3, #0 <== NOT EXECUTED 3540: 0affffdd beq 34bc <== NOT EXECUTED 3544: e5d43046 ldrb r3, [r4, #70] ; 0x46 <== NOT EXECUTED 3548: e3530000 cmp r3, #0 <== NOT EXECUTED 354c: 0affffda beq 34bc <== NOT EXECUTED 3550: eaffffd7 b 34b4 <== NOT EXECUTED * Fill the input buffer from the raw input queue */ static rtems_status_code fillBufferQueue (struct rtems_termios_tty *tty) { rtems_interval timeout = tty->rawInBufSemaphoreFirstTimeout; 3554: e5948074 ldr r8, [r4, #116] ; 0x74 <== NOT EXECUTED if (((tty->flow_ctrl & (FL_MDXON | FL_ISNTXOF)) == (FL_MDXON | FL_ISNTXOF)) && ((tty->rawOutBufState == rob_idle) || (tty->flow_ctrl & FL_OSTOP))) { /* XON should be sent now... */ (*tty->device.write)(tty->minor, 3558: e284b049 add fp, r4, #73 ; 0x49 <== NOT EXECUTED 355c: e3a0a001 mov sl, #1 <== NOT EXECUTED while ( wait ) { /* * Process characters read from raw queue */ while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) && 3560: e59f91b4 ldr r9, [pc, #436] ; 371c <== NOT EXECUTED 3564: ea000041 b 3670 <== NOT EXECUTED (tty->ccount < (CBUFSIZE-1))) { unsigned char c; unsigned int newHead; newHead = (tty->rawInBuf.Head + 1) % tty->rawInBuf.Size; 3568: e594005c ldr r0, [r4, #92] ; 0x5c <== NOT EXECUTED 356c: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED 3570: e2800001 add r0, r0, #1 <== NOT EXECUTED 3574: eb00477c bl 1536c <__umodsi3> <== NOT EXECUTED c = tty->rawInBuf.theBuf[newHead]; 3578: e5943058 ldr r3, [r4, #88] ; 0x58 <== NOT EXECUTED 357c: e7d38000 ldrb r8, [r3, r0] <== NOT EXECUTED tty->rawInBuf.Head = newHead; 3580: e584005c str r0, [r4, #92] ; 0x5c <== NOT EXECUTED if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size) 3584: e5943060 ldr r3, [r4, #96] ; 0x60 <== NOT EXECUTED 3588: e5942064 ldr r2, [r4, #100] ; 0x64 <== NOT EXECUTED 358c: e0823003 add r3, r2, r3 <== NOT EXECUTED 3590: e0600003 rsb r0, r0, r3 <== NOT EXECUTED 3594: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED 3598: eb004773 bl 1536c <__umodsi3> <== NOT EXECUTED 359c: e59430bc ldr r3, [r4, #188] ; 0xbc <== NOT EXECUTED 35a0: e1500003 cmp r0, r3 <== NOT EXECUTED 35a4: 2a00001f bcs 3628 <== NOT EXECUTED % tty->rawInBuf.Size) < tty->lowwater) { tty->flow_ctrl &= ~FL_IREQXOF; 35a8: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 35ac: e3c33001 bic r3, r3, #1 <== NOT EXECUTED 35b0: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED /* if tx stopped and XON should be sent... */ if (((tty->flow_ctrl & (FL_MDXON | FL_ISNTXOF)) 35b4: e59f3164 ldr r3, [pc, #356] ; 3720 <== NOT EXECUTED 35b8: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED 35bc: e59f015c ldr r0, [pc, #348] ; 3720 <== NOT EXECUTED 35c0: e0023003 and r3, r2, r3 <== NOT EXECUTED 35c4: e1530000 cmp r3, r0 <== NOT EXECUTED 35c8: 1a00000b bne 35fc <== NOT EXECUTED 35cc: e5943094 ldr r3, [r4, #148] ; 0x94 <== NOT EXECUTED 35d0: e3530000 cmp r3, #0 <== NOT EXECUTED 35d4: 0a000002 beq 35e4 <== NOT EXECUTED == (FL_MDXON | FL_ISNTXOF)) && ((tty->rawOutBufState == rob_idle) || (tty->flow_ctrl & FL_OSTOP))) { 35d8: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size) % tty->rawInBuf.Size) < tty->lowwater) { tty->flow_ctrl &= ~FL_IREQXOF; /* if tx stopped and XON should be sent... */ if (((tty->flow_ctrl & (FL_MDXON | FL_ISNTXOF)) 35dc: e3130020 tst r3, #32 <== NOT EXECUTED 35e0: 0a000005 beq 35fc <== NOT EXECUTED == (FL_MDXON | FL_ISNTXOF)) && ((tty->rawOutBufState == rob_idle) || (tty->flow_ctrl & FL_OSTOP))) { /* XON should be sent now... */ (*tty->device.write)(tty->minor, 35e4: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 35e8: e1a0100b mov r1, fp <== NOT EXECUTED 35ec: e3a02001 mov r2, #1 <== NOT EXECUTED 35f0: e1a0e00f mov lr, pc <== NOT EXECUTED 35f4: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED 35f8: ea00000a b 3628 <== NOT EXECUTED (void *)&(tty->termios.c_cc[VSTART]), 1); } else if (tty->flow_ctrl & FL_MDRTS) { 35fc: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 3600: e3130c01 tst r3, #256 ; 0x100 <== NOT EXECUTED 3604: 0a000007 beq 3628 <== NOT EXECUTED tty->flow_ctrl &= ~FL_IRTSOFF; 3608: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED /* activate RTS line */ if (tty->device.startRemoteTx != NULL) { 360c: e59430b0 ldr r3, [r4, #176] ; 0xb0 <== NOT EXECUTED (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1); } else if (tty->flow_ctrl & FL_MDRTS) { tty->flow_ctrl &= ~FL_IRTSOFF; 3610: e3c22004 bic r2, r2, #4 <== NOT EXECUTED /* activate RTS line */ if (tty->device.startRemoteTx != NULL) { 3614: e3530000 cmp r3, #0 <== NOT EXECUTED (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1); } else if (tty->flow_ctrl & FL_MDRTS) { tty->flow_ctrl &= ~FL_IRTSOFF; 3618: e58420b8 str r2, [r4, #184] ; 0xb8 <== NOT EXECUTED /* activate RTS line */ if (tty->device.startRemoteTx != NULL) { tty->device.startRemoteTx(tty->minor); 361c: 15940010 ldrne r0, [r4, #16] <== NOT EXECUTED 3620: 11a0e00f movne lr, pc <== NOT EXECUTED 3624: 112fff13 bxne r3 <== NOT EXECUTED } } } /* continue processing new character */ if (tty->termios.c_lflag & ICANON) { 3628: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 362c: e3130002 tst r3, #2 <== NOT EXECUTED 3630: 0a000005 beq 364c <== NOT EXECUTED if (siproc (c, tty)) 3634: e1a00008 mov r0, r8 <== NOT EXECUTED 3638: e1a01004 mov r1, r4 <== NOT EXECUTED 363c: ebffff01 bl 3248 <== NOT EXECUTED 3640: e3500000 cmp r0, #0 <== NOT EXECUTED 3644: 1a000007 bne 3668 <== NOT EXECUTED 3648: ea000007 b 366c <== NOT EXECUTED wait = 0; } else { siproc (c, tty); 364c: e1a00008 mov r0, r8 <== NOT EXECUTED 3650: e1a01004 mov r1, r4 <== NOT EXECUTED 3654: ebfffefb bl 3248 <== NOT EXECUTED if (tty->ccount >= tty->termios.c_cc[VMIN]) 3658: e5d43047 ldrb r3, [r4, #71] ; 0x47 <== NOT EXECUTED 365c: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED 3660: e1520003 cmp r2, r3 <== NOT EXECUTED 3664: ba000000 blt 366c <== NOT EXECUTED 3668: e3a0a000 mov sl, #0 <== NOT EXECUTED wait = 0; } timeout = tty->rawInBufSemaphoreTimeout; 366c: e5948070 ldr r8, [r4, #112] ; 0x70 <== NOT EXECUTED while ( wait ) { /* * Process characters read from raw queue */ while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) && 3670: e594205c ldr r2, [r4, #92] ; 0x5c <== NOT EXECUTED 3674: e5943060 ldr r3, [r4, #96] ; 0x60 <== NOT EXECUTED 3678: e1520003 cmp r2, r3 <== NOT EXECUTED 367c: 0a000004 beq 3694 <== NOT EXECUTED 3680: e5993000 ldr r3, [r9] <== NOT EXECUTED 3684: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED 3688: e2433001 sub r3, r3, #1 <== NOT EXECUTED 368c: e1520003 cmp r2, r3 <== NOT EXECUTED 3690: baffffb4 blt 3568 <== NOT EXECUTED } /* * Wait for characters */ if ( wait ) { 3694: e35a0000 cmp sl, #0 <== NOT EXECUTED 3698: 0a000005 beq 36b4 <== NOT EXECUTED sc = rtems_semaphore_obtain (tty->rawInBuf.Semaphore, 369c: e2840068 add r0, r4, #104 ; 0x68 <== NOT EXECUTED 36a0: e8900003 ldm r0, {r0, r1} <== NOT EXECUTED 36a4: e1a02008 mov r2, r8 <== NOT EXECUTED 36a8: eb0004ee bl 4a68 <== NOT EXECUTED tty->rawInBufSemaphoreOptions, timeout); if (sc != RTEMS_SUCCESSFUL) 36ac: e3500000 cmp r0, #0 <== NOT EXECUTED 36b0: 0affffee beq 3670 <== NOT EXECUTED { rtems_interval timeout = tty->rawInBufSemaphoreFirstTimeout; rtems_status_code sc; int wait = (int)1; while ( wait ) { 36b4: e3a03000 mov r3, #0 <== NOT EXECUTED 36b8: ea000007 b 36dc <== NOT EXECUTED sc = fillBufferQueue (tty); if (sc != RTEMS_SUCCESSFUL) tty->cindex = tty->ccount = 0; } while (count && (tty->cindex < tty->ccount)) { *buffer++ = tty->cbuf[tty->cindex++]; 36bc: e594101c ldr r1, [r4, #28] <== NOT EXECUTED 36c0: e59d0000 ldr r0, [sp] <== NOT EXECUTED 36c4: e7d11002 ldrb r1, [r1, r2] <== NOT EXECUTED 36c8: e2822001 add r2, r2, #1 <== NOT EXECUTED 36cc: e7c01003 strb r1, [r0, r3] <== NOT EXECUTED 36d0: e5842024 str r2, [r4, #36] ; 0x24 <== NOT EXECUTED count--; 36d4: e2477001 sub r7, r7, #1 <== NOT EXECUTED 36d8: e2833001 add r3, r3, #1 <== NOT EXECUTED else sc = fillBufferQueue (tty); if (sc != RTEMS_SUCCESSFUL) tty->cindex = tty->ccount = 0; } while (count && (tty->cindex < tty->ccount)) { 36dc: e3570000 cmp r7, #0 <== NOT EXECUTED 36e0: 0a000003 beq 36f4 <== NOT EXECUTED 36e4: e2841020 add r1, r4, #32 <== NOT EXECUTED 36e8: e8910006 ldm r1, {r1, r2} <== NOT EXECUTED 36ec: e1520001 cmp r2, r1 <== NOT EXECUTED 36f0: bafffff1 blt 36bc <== NOT EXECUTED *buffer++ = tty->cbuf[tty->cindex++]; count--; } args->bytes_moved = args->count - count; 36f4: e5953010 ldr r3, [r5, #16] <== NOT EXECUTED 36f8: e0677003 rsb r7, r7, r3 <== NOT EXECUTED 36fc: e5857018 str r7, [r5, #24] <== NOT EXECUTED tty->tty_rcvwakeup = 0; 3700: e3a03000 mov r3, #0 <== NOT EXECUTED 3704: e58430e4 str r3, [r4, #228] ; 0xe4 <== NOT EXECUTED rtems_semaphore_release (tty->isem); 3708: e5940014 ldr r0, [r4, #20] <== NOT EXECUTED 370c: eb00051b bl 4b80 <== NOT EXECUTED return sc; } 3710: e1a00006 mov r0, r6 <== NOT EXECUTED 3714: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED 3718: 000189c0 .word 0x000189c0 371c: 00017704 .word 0x00017704 3720: 00000202 .word 0x00000202 000026e0 : int nToSend; rtems_interrupt_level level; int len; /* check for XOF/XON to send */ if ((tty->flow_ctrl & (FL_MDXOF | FL_IREQXOF | FL_ISNTXOF)) 26e0: e59020b8 ldr r2, [r0, #184] ; 0xb8 <== NOT EXECUTED 26e4: e59f31d0 ldr r3, [pc, #464] ; 28bc <== NOT EXECUTED 26e8: e0023003 and r3, r2, r3 <== NOT EXECUTED 26ec: e59f21cc ldr r2, [pc, #460] ; 28c0 <== NOT EXECUTED 26f0: e1530002 cmp r3, r2 <== NOT EXECUTED * in task-driven mode, this function is called in Tx task context * in interrupt-driven mode, this function is called in TxIRQ context */ int rtems_termios_refill_transmitter (struct rtems_termios_tty *tty) { 26f4: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED 26f8: e1a04000 mov r4, r0 <== NOT EXECUTED int nToSend; rtems_interrupt_level level; int len; /* check for XOF/XON to send */ if ((tty->flow_ctrl & (FL_MDXOF | FL_IREQXOF | FL_ISNTXOF)) 26fc: 1a00000e bne 273c <== NOT EXECUTED == (FL_MDXOF | FL_IREQXOF)) { /* XOFF should be sent now... */ (*tty->device.write)(tty->minor, 2700: e284104a add r1, r4, #74 ; 0x4a <== NOT EXECUTED 2704: e2422b01 sub r2, r2, #1024 ; 0x400 <== NOT EXECUTED 2708: e5900010 ldr r0, [r0, #16] <== NOT EXECUTED 270c: e1a0e00f mov lr, pc <== NOT EXECUTED 2710: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 2714: e10f3000 mrs r3, CPSR <== NOT EXECUTED 2718: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 271c: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED (void *)&(tty->termios.c_cc[VSTOP]), 1); rtems_interrupt_disable(level); tty->t_dqlen--; 2720: e5942090 ldr r2, [r4, #144] ; 0x90 <== NOT EXECUTED tty->flow_ctrl |= FL_ISNTXOF; 2724: e59410b8 ldr r1, [r4, #184] ; 0xb8 <== NOT EXECUTED /* XOFF should be sent now... */ (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTOP]), 1); rtems_interrupt_disable(level); tty->t_dqlen--; 2728: e2422001 sub r2, r2, #1 <== NOT EXECUTED tty->flow_ctrl |= FL_ISNTXOF; 272c: e3811002 orr r1, r1, #2 <== NOT EXECUTED 2730: e58410b8 str r1, [r4, #184] ; 0xb8 <== NOT EXECUTED /* XOFF should be sent now... */ (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTOP]), 1); rtems_interrupt_disable(level); tty->t_dqlen--; 2734: e5842090 str r2, [r4, #144] ; 0x90 <== NOT EXECUTED tty->flow_ctrl |= FL_ISNTXOF; rtems_interrupt_enable(level); 2738: ea000011 b 2784 <== NOT EXECUTED nToSend = 1; } else if ((tty->flow_ctrl & (FL_IREQXOF | FL_ISNTXOF)) 273c: e59030b8 ldr r3, [r0, #184] ; 0xb8 <== NOT EXECUTED 2740: e2033003 and r3, r3, #3 <== NOT EXECUTED 2744: e3530002 cmp r3, #2 <== NOT EXECUTED 2748: 1a000010 bne 2790 <== NOT EXECUTED * FIXME: this .write call will generate another * dequeue callback. This will advance the "Tail" in the data * buffer, although the corresponding data is not yet out! * Therefore the dequeue "length" should be reduced by 1 */ (*tty->device.write)(tty->minor, 274c: e2841049 add r1, r4, #73 ; 0x49 <== NOT EXECUTED 2750: e3a02001 mov r2, #1 <== NOT EXECUTED 2754: e5900010 ldr r0, [r0, #16] <== NOT EXECUTED 2758: e1a0e00f mov lr, pc <== NOT EXECUTED 275c: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED 2760: e10f3000 mrs r3, CPSR <== NOT EXECUTED 2764: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 2768: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED (void *)&(tty->termios.c_cc[VSTART]), 1); rtems_interrupt_disable(level); tty->t_dqlen--; 276c: e5942090 ldr r2, [r4, #144] ; 0x90 <== NOT EXECUTED tty->flow_ctrl &= ~FL_ISNTXOF; 2770: e59410b8 ldr r1, [r4, #184] ; 0xb8 <== NOT EXECUTED */ (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1); rtems_interrupt_disable(level); tty->t_dqlen--; 2774: e2422001 sub r2, r2, #1 <== NOT EXECUTED tty->flow_ctrl &= ~FL_ISNTXOF; 2778: e3c11002 bic r1, r1, #2 <== NOT EXECUTED 277c: e58410b8 str r1, [r4, #184] ; 0xb8 <== NOT EXECUTED */ (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1); rtems_interrupt_disable(level); tty->t_dqlen--; 2780: e5842090 str r2, [r4, #144] ; 0x90 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 2784: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 2788: e3a05001 mov r5, #1 <== NOT EXECUTED 278c: ea000048 b 28b4 <== NOT EXECUTED rtems_interrupt_enable(level); nToSend = 1; } else { if ( tty->rawOutBuf.Head == tty->rawOutBuf.Tail ) { 2790: e5902080 ldr r2, [r0, #128] ; 0x80 <== NOT EXECUTED 2794: e5903084 ldr r3, [r0, #132] ; 0x84 <== NOT EXECUTED 2798: e1520003 cmp r2, r3 <== NOT EXECUTED 279c: 1a000005 bne 27b8 <== NOT EXECUTED /* * buffer was empty */ if (tty->rawOutBufState == rob_wait) { 27a0: e5903094 ldr r3, [r0, #148] ; 0x94 <== NOT EXECUTED 27a4: e3530002 cmp r3, #2 <== NOT EXECUTED /* * this should never happen... */ rtems_semaphore_release (tty->rawOutBuf.Semaphore); 27a8: 0590008c ldreq r0, [r0, #140] ; 0x8c <== NOT EXECUTED 27ac: 0b0008f3 bleq 4b80 <== NOT EXECUTED 27b0: e3a05000 mov r5, #0 <== NOT EXECUTED 27b4: ea00003e b 28b4 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 27b8: e10f3000 mrs r3, CPSR <== NOT EXECUTED 27bc: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 27c0: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED return 0; } rtems_interrupt_disable(level); len = tty->t_dqlen; tty->t_dqlen = 0; 27c4: e3a02000 mov r2, #0 <== NOT EXECUTED } return 0; } rtems_interrupt_disable(level); len = tty->t_dqlen; 27c8: e5900090 ldr r0, [r0, #144] ; 0x90 <== NOT EXECUTED tty->t_dqlen = 0; 27cc: e5842090 str r2, [r4, #144] ; 0x90 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 27d0: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED rtems_interrupt_enable(level); newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size; 27d4: e5943084 ldr r3, [r4, #132] ; 0x84 <== NOT EXECUTED 27d8: e5941088 ldr r1, [r4, #136] ; 0x88 <== NOT EXECUTED 27dc: e0800003 add r0, r0, r3 <== NOT EXECUTED 27e0: eb004ae1 bl 1536c <__umodsi3> <== NOT EXECUTED tty->rawOutBuf.Tail = newTail; if (tty->rawOutBufState == rob_wait) { 27e4: e5943094 ldr r3, [r4, #148] ; 0x94 <== NOT EXECUTED 27e8: e3530002 cmp r3, #2 <== NOT EXECUTED rtems_interrupt_disable(level); len = tty->t_dqlen; tty->t_dqlen = 0; rtems_interrupt_enable(level); newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size; 27ec: e1a06000 mov r6, r0 <== NOT EXECUTED tty->rawOutBuf.Tail = newTail; 27f0: e5840084 str r0, [r4, #132] ; 0x84 <== NOT EXECUTED if (tty->rawOutBufState == rob_wait) { /* * wake up any pending writer task */ rtems_semaphore_release (tty->rawOutBuf.Semaphore); 27f4: 0594008c ldreq r0, [r4, #140] ; 0x8c <== NOT EXECUTED 27f8: 0b0008e0 bleq 4b80 <== NOT EXECUTED } if (newTail == tty->rawOutBuf.Head) { 27fc: e5943080 ldr r3, [r4, #128] ; 0x80 <== NOT EXECUTED 2800: e1560003 cmp r6, r3 <== NOT EXECUTED 2804: 1a00000a bne 2834 <== NOT EXECUTED nToSend = 0; /* * check to see if snd wakeup callback was set */ if ( tty->tty_snd.sw_pfn != NULL) { 2808: e59430d4 ldr r3, [r4, #212] ; 0xd4 <== NOT EXECUTED } if (newTail == tty->rawOutBuf.Head) { /* * Buffer has become empty */ tty->rawOutBufState = rob_idle; 280c: e3a05000 mov r5, #0 <== NOT EXECUTED nToSend = 0; /* * check to see if snd wakeup callback was set */ if ( tty->tty_snd.sw_pfn != NULL) { 2810: e3530000 cmp r3, #0 <== NOT EXECUTED } if (newTail == tty->rawOutBuf.Head) { /* * Buffer has become empty */ tty->rawOutBufState = rob_idle; 2814: e5845094 str r5, [r4, #148] ; 0x94 <== NOT EXECUTED nToSend = 0; /* * check to see if snd wakeup callback was set */ if ( tty->tty_snd.sw_pfn != NULL) { 2818: 01a05003 moveq r5, r3 <== NOT EXECUTED 281c: 0a000023 beq 28b0 <== NOT EXECUTED (*tty->tty_snd.sw_pfn)(&tty->termios, tty->tty_snd.sw_arg); 2820: e2840030 add r0, r4, #48 ; 0x30 <== NOT EXECUTED 2824: e59410d8 ldr r1, [r4, #216] ; 0xd8 <== NOT EXECUTED 2828: e1a0e00f mov lr, pc <== NOT EXECUTED 282c: e12fff13 bx r3 <== NOT EXECUTED 2830: ea00001e b 28b0 <== NOT EXECUTED } } /* check, whether output should stop due to received XOFF */ else if ((tty->flow_ctrl & (FL_MDXON | FL_ORCVXOF)) 2834: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 2838: e2033e21 and r3, r3, #528 ; 0x210 <== NOT EXECUTED 283c: e3530e21 cmp r3, #528 ; 0x210 <== NOT EXECUTED 2840: 1a00000a bne 2870 <== NOT EXECUTED static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile ( 2844: e10f3000 mrs r3, CPSR <== NOT EXECUTED 2848: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 284c: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED == (FL_MDXON | FL_ORCVXOF)) { /* Buffer not empty, but output stops due to XOFF */ /* set flag, that output has been stopped */ rtems_interrupt_disable(level); tty->flow_ctrl |= FL_OSTOP; 2850: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED 2854: e3822020 orr r2, r2, #32 <== NOT EXECUTED 2858: e58420b8 str r2, [r4, #184] ; 0xb8 <== NOT EXECUTED tty->rawOutBufState = rob_busy; /*apm*/ 285c: e3a02001 mov r2, #1 <== NOT EXECUTED 2860: e5842094 str r2, [r4, #148] ; 0x94 <== NOT EXECUTED static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile ( 2864: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 2868: e3a05000 mov r5, #0 <== NOT EXECUTED 286c: ea00000f b 28b0 <== NOT EXECUTED } else { /* * Buffer not empty, start tranmitter */ if (newTail > tty->rawOutBuf.Head) 2870: e5943080 ldr r3, [r4, #128] ; 0x80 <== NOT EXECUTED 2874: e1560003 cmp r6, r3 <== NOT EXECUTED nToSend = tty->rawOutBuf.Size - newTail; 2878: 85945088 ldrhi r5, [r4, #136] ; 0x88 <== NOT EXECUTED else nToSend = tty->rawOutBuf.Head - newTail; 287c: 95945080 ldrls r5, [r4, #128] ; 0x80 <== NOT EXECUTED /* when flow control XON or XOF, don't send blocks of data */ /* to allow fast reaction on incoming flow ctrl and low latency*/ /* for outgoing flow control */ if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) { 2880: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED * Buffer not empty, start tranmitter */ if (newTail > tty->rawOutBuf.Head) nToSend = tty->rawOutBuf.Size - newTail; else nToSend = tty->rawOutBuf.Head - newTail; 2884: e0665005 rsb r5, r6, r5 <== NOT EXECUTED /* when flow control XON or XOF, don't send blocks of data */ /* to allow fast reaction on incoming flow ctrl and low latency*/ /* for outgoing flow control */ if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) { 2888: e3130c06 tst r3, #1536 ; 0x600 <== NOT EXECUTED nToSend = 1; } tty->rawOutBufState = rob_busy; /*apm*/ (*tty->device.write)(tty->minor, 288c: e594107c ldr r1, [r4, #124] ; 0x7c <== NOT EXECUTED else nToSend = tty->rawOutBuf.Head - newTail; /* when flow control XON or XOF, don't send blocks of data */ /* to allow fast reaction on incoming flow ctrl and low latency*/ /* for outgoing flow control */ if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) { 2890: 13a05001 movne r5, #1 <== NOT EXECUTED nToSend = 1; } tty->rawOutBufState = rob_busy; /*apm*/ 2894: e3a03001 mov r3, #1 <== NOT EXECUTED 2898: e5843094 str r3, [r4, #148] ; 0x94 <== NOT EXECUTED (*tty->device.write)(tty->minor, 289c: e0811006 add r1, r1, r6 <== NOT EXECUTED 28a0: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 28a4: e1a02005 mov r2, r5 <== NOT EXECUTED 28a8: e1a0e00f mov lr, pc <== NOT EXECUTED 28ac: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED &tty->rawOutBuf.theBuf[newTail], nToSend); } tty->rawOutBuf.Tail = newTail; /*apm*/ 28b0: e5846084 str r6, [r4, #132] ; 0x84 <== NOT EXECUTED } return nToSend; } 28b4: e1a00005 mov r0, r5 <== NOT EXECUTED 28b8: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED 28bc: 00000403 .word 0x00000403 28c0: 00000401 .word 0x00000401 00004100 : /* * this task actually processes any receive events */ static rtems_task rtems_termios_rxdaemon(rtems_task_argument argument) { 4100: e92d40f3 push {r0, r1, r4, r5, r6, r7, lr} <== NOT EXECUTED 4104: e1a04000 mov r4, r0 <== NOT EXECUTED char c_buf; while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_RX_PROC_EVENT | 4108: e3a05000 mov r5, #0 <== NOT EXECUTED if (c != EOF) { /* * pollRead did call enqueue on its own */ c_buf = c; rtems_termios_enqueue_raw_characters ( 410c: e28d6007 add r6, sp, #7 <== NOT EXECUTED char c_buf; while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_RX_PROC_EVENT | 4110: e1a0300d mov r3, sp <== NOT EXECUTED 4114: e3a01002 mov r1, #2 <== NOT EXECUTED 4118: e3a02000 mov r2, #0 <== NOT EXECUTED 411c: e3a00003 mov r0, #3 <== NOT EXECUTED 4120: eb0000e0 bl 44a8 <== NOT EXECUTED TERMIOS_RX_TERMINATE_EVENT), RTEMS_EVENT_ANY | RTEMS_WAIT, RTEMS_NO_TIMEOUT, &the_event); if ((the_event & TERMIOS_RX_TERMINATE_EVENT) != 0) { 4124: e59d3000 ldr r3, [sp] <== NOT EXECUTED 4128: e3130001 tst r3, #1 <== NOT EXECUTED 412c: 0a000003 beq 4140 <== NOT EXECUTED tty->rxTaskId = 0; 4130: e58450c4 str r5, [r4, #196] ; 0xc4 <== NOT EXECUTED rtems_task_delete(RTEMS_SELF); 4134: e1a00005 mov r0, r5 <== NOT EXECUTED 4138: eb000309 bl 4d64 <== NOT EXECUTED 413c: eafffff3 b 4110 <== NOT EXECUTED } else { /* * do something */ c = tty->device.pollRead(tty->minor); 4140: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 4144: e1a0e00f mov lr, pc <== NOT EXECUTED 4148: e594f0a0 ldr pc, [r4, #160] ; 0xa0 <== NOT EXECUTED if (c != EOF) { 414c: e3700001 cmn r0, #1 <== NOT EXECUTED } else { /* * do something */ c = tty->device.pollRead(tty->minor); 4150: e1a03000 mov r3, r0 <== NOT EXECUTED if (c != EOF) { 4154: 0affffed beq 4110 <== NOT EXECUTED /* * pollRead did call enqueue on its own */ c_buf = c; rtems_termios_enqueue_raw_characters ( 4158: e1a00004 mov r0, r4 <== NOT EXECUTED 415c: e1a01006 mov r1, r6 <== NOT EXECUTED 4160: e3a02001 mov r2, #1 <== NOT EXECUTED c = tty->device.pollRead(tty->minor); if (c != EOF) { /* * pollRead did call enqueue on its own */ c_buf = c; 4164: e5cd3007 strb r3, [sp, #7] <== NOT EXECUTED rtems_termios_enqueue_raw_characters ( 4168: ebfff9f1 bl 2934 <== NOT EXECUTED 416c: eaffffe7 b 4110 <== NOT EXECUTED 000026d4 : void rtems_termios_rxirq_occured(struct rtems_termios_tty *tty) { /* * send event to rx daemon task */ rtems_event_send(tty->rxTaskId,TERMIOS_RX_PROC_EVENT); 26d4: e59000c4 ldr r0, [r0, #196] ; 0xc4 <== NOT EXECUTED 26d8: e3a01002 mov r1, #2 <== NOT EXECUTED 26dc: ea0007cd b 4618 <== NOT EXECUTED 00004094 : /* * this task actually processes any transmit events */ static rtems_task rtems_termios_txdaemon(rtems_task_argument argument) { 4094: e92d40f1 push {r0, r4, r5, r6, r7, lr} <== NOT EXECUTED } else { /* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) { 4098: e59f705c ldr r7, [pc, #92] ; 40fc <== NOT EXECUTED /* * this task actually processes any transmit events */ static rtems_task rtems_termios_txdaemon(rtems_task_argument argument) { 409c: e1a04000 mov r4, r0 <== NOT EXECUTED while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_TX_START_EVENT | 40a0: e3a05000 mov r5, #0 <== NOT EXECUTED 40a4: e1a0300d mov r3, sp <== NOT EXECUTED 40a8: e3a01002 mov r1, #2 <== NOT EXECUTED 40ac: e3a02000 mov r2, #0 <== NOT EXECUTED 40b0: e3a00003 mov r0, #3 <== NOT EXECUTED 40b4: eb0000fb bl 44a8 <== NOT EXECUTED TERMIOS_TX_TERMINATE_EVENT), RTEMS_EVENT_ANY | RTEMS_WAIT, RTEMS_NO_TIMEOUT, &the_event); if ((the_event & TERMIOS_TX_TERMINATE_EVENT) != 0) { 40b8: e59d3000 ldr r3, [sp] <== NOT EXECUTED 40bc: e3130001 tst r3, #1 <== NOT EXECUTED else { /* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) { rtems_termios_linesw[tty->t_line].l_start(tty); 40c0: e1a00004 mov r0, r4 <== NOT EXECUTED rtems_event_receive((TERMIOS_TX_START_EVENT | TERMIOS_TX_TERMINATE_EVENT), RTEMS_EVENT_ANY | RTEMS_WAIT, RTEMS_NO_TIMEOUT, &the_event); if ((the_event & TERMIOS_TX_TERMINATE_EVENT) != 0) { 40c4: 0a000003 beq 40d8 <== NOT EXECUTED tty->txTaskId = 0; 40c8: e58450c8 str r5, [r4, #200] ; 0xc8 <== NOT EXECUTED rtems_task_delete(RTEMS_SELF); 40cc: e1a00005 mov r0, r5 <== NOT EXECUTED 40d0: eb000323 bl 4d64 <== NOT EXECUTED 40d4: eafffff2 b 40a4 <== NOT EXECUTED } else { /* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) { 40d8: e59430cc ldr r3, [r4, #204] ; 0xcc <== NOT EXECUTED 40dc: e0873283 add r3, r7, r3, lsl #5 <== NOT EXECUTED 40e0: e5933014 ldr r3, [r3, #20] <== NOT EXECUTED 40e4: e3530000 cmp r3, #0 <== NOT EXECUTED rtems_termios_linesw[tty->t_line].l_start(tty); 40e8: 11a0e00f movne lr, pc <== NOT EXECUTED 40ec: 112fff13 bxne r3 <== NOT EXECUTED } /* * try to push further characters to device */ rtems_termios_refill_transmitter(tty); 40f0: e1a00004 mov r0, r4 <== NOT EXECUTED 40f4: ebfff979 bl 26e0 <== NOT EXECUTED 40f8: eaffffe9 b 40a4 <== NOT EXECUTED 40fc: 000189c0 .word 0x000189c0 000032a8 : rtems_status_code rtems_termios_write (void *arg) { rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; 32a8: e5903000 ldr r3, [r0] rtems_termios_puts (&c, 1, tty); } rtems_status_code rtems_termios_write (void *arg) { 32ac: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; 32b0: e5935034 ldr r5, [r3, #52] ; 0x34 rtems_status_code sc; sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 32b4: e3a01000 mov r1, #0 rtems_termios_puts (&c, 1, tty); } rtems_status_code rtems_termios_write (void *arg) { 32b8: e1a04000 mov r4, r0 rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1; rtems_status_code sc; sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 32bc: e1a02001 mov r2, r1 32c0: e5950018 ldr r0, [r5, #24] 32c4: eb0005e7 bl 4a68 if (sc != RTEMS_SUCCESSFUL) 32c8: e2506000 subs r6, r0, #0 32cc: 1a000022 bne 335c return sc; if (rtems_termios_linesw[tty->t_line].l_write != NULL) { 32d0: e59520cc ldr r2, [r5, #204] ; 0xcc 32d4: e59f3088 ldr r3, [pc, #136] ; 3364 32d8: e0833282 add r3, r3, r2, lsl #5 32dc: e593300c ldr r3, [r3, #12] 32e0: e3530000 cmp r3, #0 32e4: 0a000005 beq 3300 sc = rtems_termios_linesw[tty->t_line].l_write(tty,args); 32e8: e1a01004 mov r1, r4 <== NOT EXECUTED 32ec: e1a00005 mov r0, r5 <== NOT EXECUTED 32f0: e1a0e00f mov lr, pc <== NOT EXECUTED 32f4: e12fff13 bx r3 <== NOT EXECUTED 32f8: e1a06000 mov r6, r0 <== NOT EXECUTED 32fc: ea000014 b 3354 <== NOT EXECUTED rtems_semaphore_release (tty->osem); return sc; } if (tty->termios.c_oflag & OPOST) { 3300: e5953034 ldr r3, [r5, #52] ; 0x34 3304: e3130001 tst r3, #1 uint32_t count = args->count; 3308: 15948010 ldrne r8, [r4, #16] char *buffer = args->buffer; 330c: 1594a00c ldrne sl, [r4, #12] 3310: 11a07006 movne r7, r6 if (rtems_termios_linesw[tty->t_line].l_write != NULL) { sc = rtems_termios_linesw[tty->t_line].l_write(tty,args); rtems_semaphore_release (tty->osem); return sc; } if (tty->termios.c_oflag & OPOST) { 3314: 1a000004 bne 332c 3318: ea000007 b 333c <== NOT EXECUTED uint32_t count = args->count; char *buffer = args->buffer; while (count--) oproc (*buffer++, tty); 331c: e7da0007 ldrb r0, [sl, r7] 3320: ebfffe7a bl 2d10 3324: e2877001 add r7, r7, #1 3328: e2488001 sub r8, r8, #1 return sc; } if (tty->termios.c_oflag & OPOST) { uint32_t count = args->count; char *buffer = args->buffer; while (count--) 332c: e3580000 cmp r8, #0 oproc (*buffer++, tty); 3330: e1a01005 mov r1, r5 return sc; } if (tty->termios.c_oflag & OPOST) { uint32_t count = args->count; char *buffer = args->buffer; while (count--) 3334: 1afffff8 bne 331c 3338: ea000003 b 334c oproc (*buffer++, tty); args->bytes_moved = args->count; } else { rtems_termios_puts (args->buffer, args->count, tty); 333c: e284000c add r0, r4, #12 <== NOT EXECUTED 3340: e8900003 ldm r0, {r0, r1} <== NOT EXECUTED 3344: e1a02005 mov r2, r5 <== NOT EXECUTED 3348: ebfffe2c bl 2c00 <== NOT EXECUTED args->bytes_moved = args->count; 334c: e5943010 ldr r3, [r4, #16] 3350: e5843018 str r3, [r4, #24] } rtems_semaphore_release (tty->osem); 3354: e5950018 ldr r0, [r5, #24] 3358: eb000608 bl 4b80 return sc; } 335c: e1a00006 mov r0, r6 3360: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 3364: 000189c0 .word 0x000189c0 0000632c : static int rtems_verror( rtems_error_code_t error_flag, const char *printf_format, va_list arglist ) { 632c: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} <== NOT EXECUTED int local_errno = 0; int chars_written = 0; rtems_status_code status; if (error_flag & RTEMS_ERROR_PANIC) 6330: e2107202 ands r7, r0, #536870912 ; 0x20000000 <== NOT EXECUTED static int rtems_verror( rtems_error_code_t error_flag, const char *printf_format, va_list arglist ) { 6334: e1a06000 mov r6, r0 <== NOT EXECUTED 6338: e1a09001 mov r9, r1 <== NOT EXECUTED 633c: e1a04002 mov r4, r2 <== NOT EXECUTED int local_errno = 0; int chars_written = 0; rtems_status_code status; if (error_flag & RTEMS_ERROR_PANIC) 6340: 0a00000d beq 637c <== NOT EXECUTED { if (rtems_panic_in_progress++) 6344: e59f3160 ldr r3, [pc, #352] ; 64ac <== NOT EXECUTED 6348: e5932000 ldr r2, [r3] <== NOT EXECUTED 634c: e3520000 cmp r2, #0 <== NOT EXECUTED 6350: e2822001 add r2, r2, #1 <== NOT EXECUTED 6354: e5832000 str r2, [r3] <== NOT EXECUTED 6358: 0a000003 beq 636c <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 635c: e59f314c ldr r3, [pc, #332] ; 64b0 <== NOT EXECUTED 6360: e5932000 ldr r2, [r3] <== NOT EXECUTED 6364: e2822001 add r2, r2, #1 <== NOT EXECUTED 6368: e5832000 str r2, [r3] <== NOT EXECUTED _Thread_Disable_dispatch(); /* disable task switches */ /* don't aggravate things */ if (rtems_panic_in_progress > 2) 636c: e59f3138 ldr r3, [pc, #312] ; 64ac <== NOT EXECUTED 6370: e5933000 ldr r3, [r3] <== NOT EXECUTED 6374: e3530002 cmp r3, #2 <== NOT EXECUTED 6378: ca000049 bgt 64a4 <== NOT EXECUTED return 0; } (void) fflush(stdout); /* in case stdout/stderr same */ 637c: e59f3130 ldr r3, [pc, #304] ; 64b4 <== NOT EXECUTED 6380: e5933000 ldr r3, [r3] <== NOT EXECUTED 6384: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED 6388: eb003035 bl 12464 <== NOT EXECUTED status = error_flag & ~RTEMS_ERROR_MASK; if (error_flag & RTEMS_ERROR_ERRNO) /* include errno? */ 638c: e2165101 ands r5, r6, #1073741824 ; 0x40000000 <== NOT EXECUTED return 0; } (void) fflush(stdout); /* in case stdout/stderr same */ status = error_flag & ~RTEMS_ERROR_MASK; 6390: e3c68207 bic r8, r6, #1879048192 ; 0x70000000 <== NOT EXECUTED if (error_flag & RTEMS_ERROR_ERRNO) /* include errno? */ 6394: 0a000001 beq 63a0 <== NOT EXECUTED local_errno = errno; 6398: eb002f3e bl 12098 <__errno> <== NOT EXECUTED 639c: e5905000 ldr r5, [r0] <== NOT EXECUTED #if defined(RTEMS_MULTIPROCESSING) if (_System_state_Is_multiprocessing) fprintf(stderr, "[%" PRIu32 "] ", _Configuration_MP_table->node); #endif chars_written += vfprintf(stderr, printf_format, arglist); 63a0: e59fa10c ldr sl, [pc, #268] ; 64b4 <== NOT EXECUTED 63a4: e59a3000 ldr r3, [sl] <== NOT EXECUTED 63a8: e1a02004 mov r2, r4 <== NOT EXECUTED 63ac: e1a01009 mov r1, r9 <== NOT EXECUTED 63b0: e593000c ldr r0, [r3, #12] <== NOT EXECUTED 63b4: eb00484b bl 184e8 <== NOT EXECUTED if (status) 63b8: e3580000 cmp r8, #0 <== NOT EXECUTED #if defined(RTEMS_MULTIPROCESSING) if (_System_state_Is_multiprocessing) fprintf(stderr, "[%" PRIu32 "] ", _Configuration_MP_table->node); #endif chars_written += vfprintf(stderr, printf_format, arglist); 63bc: e1a04000 mov r4, r0 <== NOT EXECUTED if (status) 63c0: 0a000008 beq 63e8 <== NOT EXECUTED chars_written += fprintf(stderr, " (status: %s)", rtems_status_text(status)); 63c4: e59a3000 ldr r3, [sl] <== NOT EXECUTED 63c8: e1a00008 mov r0, r8 <== NOT EXECUTED 63cc: e593800c ldr r8, [r3, #12] <== NOT EXECUTED 63d0: ebffffd1 bl 631c <== NOT EXECUTED 63d4: e59f10dc ldr r1, [pc, #220] ; 64b8 <== NOT EXECUTED 63d8: e1a02000 mov r2, r0 <== NOT EXECUTED 63dc: e1a00008 mov r0, r8 <== NOT EXECUTED 63e0: eb0030dd bl 1275c <== NOT EXECUTED 63e4: e0844000 add r4, r4, r0 <== NOT EXECUTED if (local_errno) 63e8: e3550000 cmp r5, #0 <== NOT EXECUTED 63ec: 0a000015 beq 6448 <== NOT EXECUTED { if ((local_errno > 0) && *strerror(local_errno)) 63f0: da00000d ble 642c <== NOT EXECUTED 63f4: e1a00005 mov r0, r5 <== NOT EXECUTED 63f8: eb0033ea bl 133a8 <== NOT EXECUTED 63fc: e5d03000 ldrb r3, [r0] <== NOT EXECUTED 6400: e3530000 cmp r3, #0 <== NOT EXECUTED 6404: 0a000008 beq 642c <== NOT EXECUTED chars_written += fprintf(stderr, " (errno: %s)", strerror(local_errno)); 6408: e59f30a4 ldr r3, [pc, #164] ; 64b4 <== NOT EXECUTED 640c: e5933000 ldr r3, [r3] <== NOT EXECUTED 6410: e1a00005 mov r0, r5 <== NOT EXECUTED 6414: e593800c ldr r8, [r3, #12] <== NOT EXECUTED 6418: eb0033e2 bl 133a8 <== NOT EXECUTED 641c: e59f1098 ldr r1, [pc, #152] ; 64bc <== NOT EXECUTED 6420: e1a02000 mov r2, r0 <== NOT EXECUTED 6424: e1a00008 mov r0, r8 <== NOT EXECUTED 6428: ea000004 b 6440 <== NOT EXECUTED else chars_written += fprintf(stderr, " (unknown errno=%d)", local_errno); 642c: e59f3080 ldr r3, [pc, #128] ; 64b4 <== NOT EXECUTED 6430: e5933000 ldr r3, [r3] <== NOT EXECUTED 6434: e59f1084 ldr r1, [pc, #132] ; 64c0 <== NOT EXECUTED 6438: e593000c ldr r0, [r3, #12] <== NOT EXECUTED 643c: e1a02005 mov r2, r5 <== NOT EXECUTED 6440: eb0030c5 bl 1275c <== NOT EXECUTED 6444: e0844000 add r4, r4, r0 <== NOT EXECUTED } chars_written += fprintf(stderr, "\n"); 6448: e59f8064 ldr r8, [pc, #100] ; 64b4 <== NOT EXECUTED 644c: e5983000 ldr r3, [r8] <== NOT EXECUTED 6450: e59f106c ldr r1, [pc, #108] ; 64c4 <== NOT EXECUTED 6454: e593000c ldr r0, [r3, #12] <== NOT EXECUTED 6458: eb0030bf bl 1275c <== NOT EXECUTED (void) fflush(stderr); 645c: e5983000 ldr r3, [r8] <== NOT EXECUTED chars_written += fprintf(stderr, " (errno: %s)", strerror(local_errno)); else chars_written += fprintf(stderr, " (unknown errno=%d)", local_errno); } chars_written += fprintf(stderr, "\n"); 6460: e1a0a000 mov sl, r0 <== NOT EXECUTED (void) fflush(stderr); 6464: e593000c ldr r0, [r3, #12] <== NOT EXECUTED 6468: eb002ffd bl 12464 <== NOT EXECUTED if (error_flag & (RTEMS_ERROR_PANIC | RTEMS_ERROR_ABORT)) 646c: e3160203 tst r6, #805306368 ; 0x30000000 <== NOT EXECUTED chars_written += fprintf(stderr, " (errno: %s)", strerror(local_errno)); else chars_written += fprintf(stderr, " (unknown errno=%d)", local_errno); } chars_written += fprintf(stderr, "\n"); 6470: 008a0004 addeq r0, sl, r4 <== NOT EXECUTED (void) fflush(stderr); if (error_flag & (RTEMS_ERROR_PANIC | RTEMS_ERROR_ABORT)) 6474: 08bd87f0 popeq {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED { if (error_flag & RTEMS_ERROR_PANIC) 6478: e3570000 cmp r7, #0 <== NOT EXECUTED 647c: 0a000004 beq 6494 <== NOT EXECUTED { rtems_error(0, "fatal error, exiting"); 6480: e3a00000 mov r0, #0 <== NOT EXECUTED 6484: e59f103c ldr r1, [pc, #60] ; 64c8 <== NOT EXECUTED 6488: eb00001b bl 64fc <== NOT EXECUTED _exit(local_errno); 648c: e1a00005 mov r0, r5 <== NOT EXECUTED 6490: eb0002cf bl 6fd4 <_exit> <== NOT EXECUTED } else { rtems_error(0, "fatal error, aborting"); 6494: e59f1030 ldr r1, [pc, #48] ; 64cc <== NOT EXECUTED 6498: e1a00007 mov r0, r7 <== NOT EXECUTED 649c: eb000016 bl 64fc <== NOT EXECUTED abort(); 64a0: eb002ef3 bl 12074 <== NOT EXECUTED 64a4: e3a00000 mov r0, #0 <== NOT EXECUTED } } return chars_written; } 64a8: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED 64ac: 00023b08 .word 0x00023b08 64b0: 00023c8c .word 0x00023c8c 64b4: 00021044 .word 0x00021044 64b8: 000227df .word 0x000227df 64bc: 000227ed .word 0x000227ed 64c0: 000227fa .word 0x000227fa 64c4: 00022b21 .word 0x00022b21 64c8: 0002280e .word 0x0002280e 64cc: 00022823 .word 0x00022823 000220f4 : /* * Extract an integer value from the database */ static int scanInt(FILE *fp, int *val) { 220f4: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} 220f8: e3a04000 mov r4, #0 unsigned int limit = INT_MAX; int sign = 0; int d; for (;;) { c = getc(fp); 220fc: e59fb0d4 ldr fp, [pc, #212] ; 221d8 limit++; continue; } sign = 1; } if (!isdigit(c)) 22100: e59f90d4 ldr r9, [pc, #212] ; 221dc /* * Extract an integer value from the database */ static int scanInt(FILE *fp, int *val) { 22104: e58d1000 str r1, [sp] 22108: e1a05000 mov r5, r0 2210c: e3e08102 mvn r8, #-2147483648 ; 0x80000000 22110: e1a07004 mov r7, r4 sign = 1; } if (!isdigit(c)) return 0; d = c - '0'; if ((i > (limit / 10)) 22114: e3a0a00a mov sl, #10 unsigned int limit = INT_MAX; int sign = 0; int d; for (;;) { c = getc(fp); 22118: e5953004 ldr r3, [r5, #4] 2211c: e2433001 sub r3, r3, #1 22120: e3530000 cmp r3, #0 22124: e5853004 str r3, [r5, #4] 22128: a5953000 ldrge r3, [r5] 2212c: a4d36001 ldrbge r6, [r3], #1 22130: a5853000 strge r3, [r5] 22134: aa000003 bge 22148 22138: e59b0000 ldr r0, [fp] <== NOT EXECUTED 2213c: e1a01005 mov r1, r5 <== NOT EXECUTED 22140: eb006d1b bl 3d5b4 <__srget_r> <== NOT EXECUTED 22144: e1a06000 mov r6, r0 <== NOT EXECUTED if (c == ':') 22148: e356003a cmp r6, #58 ; 0x3a 2214c: 0a000019 beq 221b8 break; if (sign == 0) { 22150: e3540000 cmp r4, #0 22154: 1a000004 bne 2216c if (c == '-') { 22158: e356002d cmp r6, #45 ; 0x2d sign = -1; limit++; 2215c: 02888001 addeq r8, r8, #1 22160: 03e04000 mvneq r4, #0 for (;;) { c = getc(fp); if (c == ':') break; if (sign == 0) { if (c == '-') { 22164: 0affffeb beq 22118 sign = -1; limit++; continue; 22168: e3a04001 mov r4, #1 } sign = 1; } if (!isdigit(c)) 2216c: e5993000 ldr r3, [r9] 22170: e0833006 add r3, r3, r6 22174: e5d33001 ldrb r3, [r3, #1] 22178: e3130004 tst r3, #4 2217c: 0a000013 beq 221d0 return 0; d = c - '0'; if ((i > (limit / 10)) 22180: e1a00008 mov r0, r8 22184: e3a0100a mov r1, #10 22188: eb00b78e bl 4ffc8 <__aeabi_uidiv> 2218c: e1570000 cmp r7, r0 22190: 8a00000e bhi 221d0 } sign = 1; } if (!isdigit(c)) return 0; d = c - '0'; 22194: e2466030 sub r6, r6, #48 ; 0x30 if ((i > (limit / 10)) 22198: 1a000004 bne 221b0 2219c: e1a00008 mov r0, r8 <== NOT EXECUTED 221a0: e3a0100a mov r1, #10 <== NOT EXECUTED 221a4: eb00b81b bl 50218 <__umodsi3> <== NOT EXECUTED 221a8: e1560000 cmp r6, r0 <== NOT EXECUTED 221ac: 8a000007 bhi 221d0 <== NOT EXECUTED || ((i == (limit / 10)) && (d > (limit % 10)))) return 0; i = i * 10 + d; 221b0: e027679a mla r7, sl, r7, r6 221b4: eaffffd7 b 22118 } if (sign == 0) 221b8: e3540000 cmp r4, #0 return 0; *val = i * sign; 221bc: 10030497 mulne r3, r7, r4 221c0: 159d2000 ldrne r2, [sp] 221c4: 13a00001 movne r0, #1 221c8: 15823000 strne r3, [r2] return 1; 221cc: 1a000000 bne 221d4 221d0: e3a00000 mov r0, #0 <== NOT EXECUTED } 221d4: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 221d8: 00052d4c .word 0x00052d4c 221dc: 00052d40 .word 0x00052d40 000221e0 : /* * Extract a string value from the database */ static int scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag) { 221e0: e92d41f0 push {r4, r5, r6, r7, r8, lr} 221e4: e1a04002 mov r4, r2 int c; *name = *bufp; 221e8: e5922000 ldr r2, [r2] /* * Extract a string value from the database */ static int scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag) { 221ec: e59d6018 ldr r6, [sp, #24] int c; *name = *bufp; 221f0: e5812000 str r2, [r1] for (;;) { c = getc(fp); 221f4: e59f70c0 ldr r7, [pc, #192] ; 222bc /* * Extract a string value from the database */ static int scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag) { 221f8: e1a05000 mov r5, r0 221fc: e1a08003 mov r8, r3 int c; *name = *bufp; for (;;) { c = getc(fp); 22200: e5953004 ldr r3, [r5, #4] 22204: e2433001 sub r3, r3, #1 22208: e3530000 cmp r3, #0 2220c: e5853004 str r3, [r5, #4] 22210: a5953000 ldrge r3, [r5] 22214: a4d30001 ldrbge r0, [r3], #1 22218: a5853000 strge r3, [r5] 2221c: b5970000 ldrlt r0, [r7] 22220: b1a01005 movlt r1, r5 22224: bb006ce2 bllt 3d5b4 <__srget_r> if (c == ':') { 22228: e350003a cmp r0, #58 ; 0x3a 2222c: 1a000002 bne 2223c if (nlFlag) 22230: e3560000 cmp r6, #0 22234: 0a000013 beq 22288 22238: ea00001d b 222b4 <== NOT EXECUTED return 0; break; } if (c == '\n') { 2223c: e350000a cmp r0, #10 22240: 1a000002 bne 22250 if (!nlFlag) 22244: e3560000 cmp r6, #0 22248: 1a00000e bne 22288 2224c: ea000018 b 222b4 <== NOT EXECUTED return 0; break; } if (c == EOF) 22250: e3700001 cmn r0, #1 22254: 0a000016 beq 222b4 return 0; if (*nleft < 2) 22258: e5983000 ldr r3, [r8] 2225c: e3530001 cmp r3, #1 22260: 9a000013 bls 222b4 return 0; **bufp = c; 22264: e5943000 ldr r3, [r4] 22268: e5c30000 strb r0, [r3] ++(*bufp); 2226c: e5942000 ldr r2, [r4] --(*nleft); 22270: e5983000 ldr r3, [r8] if (c == EOF) return 0; if (*nleft < 2) return 0; **bufp = c; ++(*bufp); 22274: e2822001 add r2, r2, #1 --(*nleft); 22278: e2433001 sub r3, r3, #1 if (c == EOF) return 0; if (*nleft < 2) return 0; **bufp = c; ++(*bufp); 2227c: e5842000 str r2, [r4] --(*nleft); 22280: e5883000 str r3, [r8] } 22284: eaffffdd b 22200 **bufp = '\0'; 22288: e5943000 ldr r3, [r4] 2228c: e3a02000 mov r2, #0 22290: e5c32000 strb r2, [r3] ++(*bufp); 22294: e5942000 ldr r2, [r4] --(*nleft); 22298: e5983000 ldr r3, [r8] **bufp = c; ++(*bufp); --(*nleft); } **bufp = '\0'; ++(*bufp); 2229c: e2822001 add r2, r2, #1 --(*nleft); 222a0: e2433001 sub r3, r3, #1 **bufp = c; ++(*bufp); --(*nleft); } **bufp = '\0'; ++(*bufp); 222a4: e5842000 str r2, [r4] --(*nleft); 222a8: e5883000 str r3, [r8] 222ac: e3a00001 mov r0, #1 return 1; 222b0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 222b4: e3a00000 mov r0, #0 <== NOT EXECUTED } 222b8: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED 222bc: 00052d4c .word 0x00052d4c 000222c0 : FILE *fp, struct group *grp, char *buffer, size_t bufsize ) { 222c0: e92d41f0 push {r4, r5, r6, r7, r8, lr} 222c4: e24dd014 sub sp, sp, #20 int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) 222c8: e28d6008 add r6, sp, #8 222cc: e28d5004 add r5, sp, #4 FILE *fp, struct group *grp, char *buffer, size_t bufsize ) { 222d0: e58d2008 str r2, [sp, #8] 222d4: e58d3004 str r3, [sp, #4] int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) 222d8: e3a08000 mov r8, #0 222dc: e1a02006 mov r2, r6 222e0: e1a03005 mov r3, r5 222e4: e58d8000 str r8, [sp] FILE *fp, struct group *grp, char *buffer, size_t bufsize ) { 222e8: e1a07000 mov r7, r0 222ec: e1a04001 mov r4, r1 int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) 222f0: ebffffba bl 221e0 222f4: e1500008 cmp r0, r8 222f8: 0a00003b beq 223ec || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) 222fc: e1a00007 mov r0, r7 22300: e2841004 add r1, r4, #4 22304: e1a02006 mov r2, r6 22308: e1a03005 mov r3, r5 2230c: e58d8000 str r8, [sp] 22310: ebffffb2 bl 221e0 { int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) 22314: e1500008 cmp r0, r8 22318: 0a000033 beq 223ec || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &grgid) 2231c: e1a00007 mov r0, r7 22320: e28d1010 add r1, sp, #16 22324: ebffff72 bl 220f4 { int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) 22328: e1500008 cmp r0, r8 2232c: 0a00002e beq 223ec || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &grgid) || !scanString(fp, &grmem, &buffer, &bufsize, 1)) 22330: e1a03005 mov r3, r5 22334: e28d100c add r1, sp, #12 22338: e1a00007 mov r0, r7 2233c: e1a02006 mov r2, r6 22340: e3a05001 mov r5, #1 22344: e58d5000 str r5, [sp] 22348: ebffffa4 bl 221e0 { int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) 2234c: e1500008 cmp r0, r8 || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &grgid) || !scanString(fp, &grmem, &buffer, &bufsize, 1)) return 0; grp->gr_gid = grgid; 22350: 11dd31b0 ldrhne r3, [sp, #16] /* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { 22354: 159d100c ldrne r1, [sp, #12] if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &grgid) || !scanString(fp, &grmem, &buffer, &bufsize, 1)) return 0; grp->gr_gid = grgid; 22358: 11c430b8 strhne r3, [r4, #8] { int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) 2235c: 1a000003 bne 22370 22360: ea000021 b 223ec <== NOT EXECUTED /* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { if(*cp == ',') 22364: e352002c cmp r2, #44 ; 0x2c memcount++; 22368: 02855001 addeq r5, r5, #1 2236c: e2888001 add r8, r8, #1 grp->gr_gid = grgid; /* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { 22370: e7d12008 ldrb r2, [r1, r8] 22374: e3520000 cmp r2, #0 22378: 1afffff9 bne 22364 } /* * Hack to produce (hopefully) a suitably-aligned array of pointers */ if (bufsize < (((memcount+1)*sizeof(char *)) + 15)) 2237c: e1a05105 lsl r5, r5, #2 22380: e59d3004 ldr r3, [sp, #4] 22384: e2855013 add r5, r5, #19 22388: e1530005 cmp r3, r5 2238c: 3a000016 bcc 223ec return 0; grp->gr_mem = (char **)(((uintptr_t)buffer + 15) & ~15); 22390: e59d3008 ldr r3, [sp, #8] 22394: e283300f add r3, r3, #15 22398: e3c3300f bic r3, r3, #15 /* * Fill in pointer array */ grp->gr_mem[0] = grmem; 2239c: e5831000 str r1, [r3] /* * Hack to produce (hopefully) a suitably-aligned array of pointers */ if (bufsize < (((memcount+1)*sizeof(char *)) + 15)) return 0; grp->gr_mem = (char **)(((uintptr_t)buffer + 15) & ~15); 223a0: e584300c str r3, [r4, #12] /* * Fill in pointer array */ grp->gr_mem[0] = grmem; 223a4: e59d300c ldr r3, [sp, #12] for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { if(*cp == ',') { *cp = '\0'; 223a8: e1a00002 mov r0, r2 grp->gr_mem = (char **)(((uintptr_t)buffer + 15) & ~15); /* * Fill in pointer array */ grp->gr_mem[0] = grmem; 223ac: e2833001 add r3, r3, #1 223b0: e2822001 add r2, r2, #1 for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { 223b4: ea000005 b 223d0 if(*cp == ',') { 223b8: e351002c cmp r1, #44 ; 0x2c *cp = '\0'; 223bc: 05430001 strbeq r0, [r3, #-1] grp->gr_mem[memcount++] = cp + 1; 223c0: 0594100c ldreq r1, [r4, #12] 223c4: 07813102 streq r3, [r1, r2, lsl #2] 223c8: 02822001 addeq r2, r2, #1 223cc: e2833001 add r3, r3, #1 /* * Fill in pointer array */ grp->gr_mem[0] = grmem; for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { 223d0: e5531001 ldrb r1, [r3, #-1] 223d4: e3510000 cmp r1, #0 223d8: 1afffff6 bne 223b8 if(*cp == ',') { *cp = '\0'; grp->gr_mem[memcount++] = cp + 1; } } grp->gr_mem[memcount] = NULL; 223dc: e594300c ldr r3, [r4, #12] 223e0: e3a00001 mov r0, #1 223e4: e7831102 str r1, [r3, r2, lsl #2] return 1; 223e8: ea000000 b 223f0 223ec: e3a00000 mov r0, #0 <== NOT EXECUTED } 223f0: e28dd014 add sp, sp, #20 223f4: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 00022434 : FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) { 22434: e92d41f0 push {r4, r5, r6, r7, r8, lr} 22438: e24dd014 sub sp, sp, #20 int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 2243c: e28d7008 add r7, sp, #8 22440: e28d6004 add r6, sp, #4 FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) { 22444: e58d2008 str r2, [sp, #8] 22448: e58d3004 str r3, [sp, #4] int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 2244c: e3a08000 mov r8, #0 22450: e1a02007 mov r2, r7 22454: e1a03006 mov r3, r6 22458: e58d8000 str r8, [sp] FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) { 2245c: e1a05000 mov r5, r0 22460: e1a04001 mov r4, r1 int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 22464: ebffff5d bl 221e0 22468: e1500008 cmp r0, r8 2246c: 0a000038 beq 22554 || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) 22470: e1a00005 mov r0, r5 22474: e2841004 add r1, r4, #4 22478: e1a02007 mov r2, r7 2247c: e1a03006 mov r3, r6 22480: e58d8000 str r8, [sp] 22484: ebffff55 bl 221e0 size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 22488: e1500008 cmp r0, r8 2248c: 0a000030 beq 22554 || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) 22490: e1a00005 mov r0, r5 22494: e28d1010 add r1, sp, #16 22498: ebffff15 bl 220f4 size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 2249c: e1500008 cmp r0, r8 224a0: 0a00002b beq 22554 || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid) 224a4: e1a00005 mov r0, r5 224a8: e28d100c add r1, sp, #12 224ac: ebffff10 bl 220f4 size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 224b0: e1500008 cmp r0, r8 224b4: 0a000026 beq 22554 || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid) || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0) 224b8: e1a00005 mov r0, r5 224bc: e284100c add r1, r4, #12 224c0: e1a02007 mov r2, r7 224c4: e1a03006 mov r3, r6 224c8: e58d8000 str r8, [sp] 224cc: ebffff43 bl 221e0 size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 224d0: e1500008 cmp r0, r8 224d4: 0a00001e beq 22554 || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid) || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_gecos, &buffer, &bufsize, 0) 224d8: e1a00005 mov r0, r5 224dc: e2841010 add r1, r4, #16 224e0: e1a02007 mov r2, r7 224e4: e1a03006 mov r3, r6 224e8: e58d8000 str r8, [sp] 224ec: ebffff3b bl 221e0 size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 224f0: e1500008 cmp r0, r8 224f4: 0a000016 beq 22554 || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid) || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_gecos, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_dir, &buffer, &bufsize, 0) 224f8: e1a00005 mov r0, r5 224fc: e2841014 add r1, r4, #20 22500: e1a02007 mov r2, r7 22504: e1a03006 mov r3, r6 22508: e58d8000 str r8, [sp] 2250c: ebffff33 bl 221e0 size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 22510: e1500008 cmp r0, r8 22514: 0a00000e beq 22554 || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid) || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_gecos, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_dir, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_shell, &buffer, &bufsize, 1)) 22518: e1a00005 mov r0, r5 2251c: e1a02007 mov r2, r7 22520: e1a03006 mov r3, r6 22524: e3a05001 mov r5, #1 22528: e2841018 add r1, r4, #24 2252c: e58d5000 str r5, [sp] 22530: ebffff2a bl 221e0 size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0) 22534: e1500008 cmp r0, r8 22538: 0a000005 beq 22554 || !scanString(fp, &pwd->pw_gecos, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_dir, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_shell, &buffer, &bufsize, 1)) return 0; pwd->pw_uid = pwuid; pwd->pw_gid = pwgid; 2253c: e1dd30bc ldrh r3, [sp, #12] 22540: e1c430ba strh r3, [r4, #10] || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_gecos, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_dir, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_shell, &buffer, &bufsize, 1)) return 0; pwd->pw_uid = pwuid; 22544: e1dd31b0 ldrh r3, [sp, #16] pwd->pw_gid = pwgid; 22548: e1a00005 mov r0, r5 || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_gecos, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_dir, &buffer, &bufsize, 0) || !scanString(fp, &pwd->pw_shell, &buffer, &bufsize, 1)) return 0; pwd->pw_uid = pwuid; 2254c: e1c430b8 strh r3, [r4, #8] pwd->pw_gid = pwgid; return 1; 22550: ea000000 b 22558 22554: e3a00000 mov r0, #0 <== NOT EXECUTED } 22558: e28dd014 add sp, sp, #20 2255c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 000220ac : int setgid( gid_t gid ) { _POSIX_types_Gid = gid; 220ac: e59f300c ldr r3, [pc, #12] ; 220c0 <== NOT EXECUTED 220b0: e5933000 ldr r3, [r3] <== NOT EXECUTED 220b4: e1c303b4 strh r0, [r3, #52] ; 0x34 <== NOT EXECUTED return 0; } 220b8: e3a00000 mov r0, #0 <== NOT EXECUTED 220bc: e12fff1e bx lr <== NOT EXECUTED 220c0: 00052578 .word 0x00052578 00022664 : return NULL; return &grent; } void setgrent(void) { 22664: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED init_etc_passwd_group(); 22668: ebffffcb bl 2259c <== NOT EXECUTED if (group_fp != NULL) 2266c: e59f3020 ldr r3, [pc, #32] ; 22694 <== NOT EXECUTED 22670: e5930000 ldr r0, [r3] <== NOT EXECUTED 22674: e3500000 cmp r0, #0 <== NOT EXECUTED fclose(group_fp); 22678: 1b00571b blne 382ec <== NOT EXECUTED group_fp = fopen("/etc/group", "r"); 2267c: e59f0014 ldr r0, [pc, #20] ; 22698 <== NOT EXECUTED 22680: e59f1014 ldr r1, [pc, #20] ; 2269c <== NOT EXECUTED 22684: eb00593b bl 38b78 <== NOT EXECUTED 22688: e59f3004 ldr r3, [pc, #4] ; 22694 <== NOT EXECUTED 2268c: e5830000 str r0, [r3] <== NOT EXECUTED } 22690: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED 22694: 0005f784 .word 0x0005f784 22698: 00056520 .word 0x00056520 2269c: 00057113 .word 0x00057113 00022834 : return NULL; return &pwent; } void setpwent(void) { 22834: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED init_etc_passwd_group(); 22838: ebffff57 bl 2259c <== NOT EXECUTED if (passwd_fp != NULL) 2283c: e59f3020 ldr r3, [pc, #32] ; 22864 <== NOT EXECUTED 22840: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED 22844: e3500000 cmp r0, #0 <== NOT EXECUTED fclose(passwd_fp); 22848: 1b0056a7 blne 382ec <== NOT EXECUTED passwd_fp = fopen("/etc/passwd", "r"); 2284c: e59f0014 ldr r0, [pc, #20] ; 22868 <== NOT EXECUTED 22850: e59f1014 ldr r1, [pc, #20] ; 2286c <== NOT EXECUTED 22854: eb0058c7 bl 38b78 <== NOT EXECUTED 22858: e59f3004 ldr r3, [pc, #4] ; 22864 <== NOT EXECUTED 2285c: e5830004 str r0, [r3, #4] <== NOT EXECUTED } 22860: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED 22864: 0005f784 .word 0x0005f784 22868: 00056472 .word 0x00056472 2286c: 00057113 .word 0x00057113 00004954 : int setuid( uid_t uid ) { _POSIX_types_Uid = uid; 4954: e59f300c ldr r3, [pc, #12] ; 4968 <== NOT EXECUTED 4958: e5933000 ldr r3, [r3] <== NOT EXECUTED 495c: e1c303b2 strh r0, [r3, #50] ; 0x32 <== NOT EXECUTED return 0; } 4960: e3a00000 mov r0, #0 <== NOT EXECUTED 4964: e12fff1e bx lr <== NOT EXECUTED 4968: 00052578 .word 0x00052578 00003248 : int i; /* * Obtain output semaphore if character will be echoed */ if (tty->termios.c_lflag & (ECHO|ECHOE|ECHOK|ECHONL|ECHOPRT|ECHOCTL|ECHOKE)) { 3248: e591203c ldr r2, [r1, #60] ; 0x3c <== NOT EXECUTED 324c: e59f3050 ldr r3, [pc, #80] ; 32a4 <== NOT EXECUTED 3250: e0023003 and r3, r2, r3 <== NOT EXECUTED 3254: e3530000 cmp r3, #0 <== NOT EXECUTED /* * Process input character, with semaphore. */ static int siproc (unsigned char c, struct rtems_termios_tty *tty) { 3258: e92d4030 push {r4, r5, lr} <== NOT EXECUTED 325c: e1a04001 mov r4, r1 <== NOT EXECUTED 3260: e20050ff and r5, r0, #255 ; 0xff <== NOT EXECUTED int i; /* * Obtain output semaphore if character will be echoed */ if (tty->termios.c_lflag & (ECHO|ECHOE|ECHOK|ECHONL|ECHOPRT|ECHOCTL|ECHOKE)) { 3264: 0a00000b beq 3298 <== NOT EXECUTED rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); 3268: e3a01000 mov r1, #0 <== NOT EXECUTED 326c: e1a02001 mov r2, r1 <== NOT EXECUTED 3270: e5940018 ldr r0, [r4, #24] <== NOT EXECUTED 3274: eb0005fb bl 4a68 <== NOT EXECUTED i = iproc (c, tty); 3278: e1a01004 mov r1, r4 <== NOT EXECUTED 327c: e1a00005 mov r0, r5 <== NOT EXECUTED 3280: ebffff8b bl 30b4 <== NOT EXECUTED 3284: e1a05000 mov r5, r0 <== NOT EXECUTED rtems_semaphore_release (tty->osem); 3288: e5940018 ldr r0, [r4, #24] <== NOT EXECUTED 328c: eb00063b bl 4b80 <== NOT EXECUTED } else { i = iproc (c, tty); } return i; } 3290: e1a00005 mov r0, r5 <== NOT EXECUTED 3294: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); i = iproc (c, tty); rtems_semaphore_release (tty->osem); } else { i = iproc (c, tty); 3298: e1a00005 mov r0, r5 <== NOT EXECUTED } return i; } 329c: e8bd4030 pop {r4, r5, lr} <== NOT EXECUTED rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); i = iproc (c, tty); rtems_semaphore_release (tty->osem); } else { i = iproc (c, tty); 32a0: eaffff83 b 30b4 <== NOT EXECUTED 32a4: 00000e78 .word 0x00000e78 00005b54 : int _STAT_NAME( const char *path, struct stat *buf ) { 5b54: e92d4070 push {r4, r5, r6, lr} /* * Check to see if we were passed a valid pointer. */ if ( !buf ) 5b58: e2515000 subs r5, r1, #0 int _STAT_NAME( const char *path, struct stat *buf ) { 5b5c: e24dd018 sub sp, sp, #24 5b60: e1a06000 mov r6, r0 /* * Check to see if we were passed a valid pointer. */ if ( !buf ) 5b64: 1a000002 bne 5b74 rtems_set_errno_and_return_minus_one( EFAULT ); 5b68: eb00c992 bl 381b8 <__errno> 5b6c: e3a0300e mov r3, #14 5b70: ea000018 b 5bd8 status = rtems_filesystem_evaluate_path( path, strlen( path ), 5b74: eb00e409 bl 3eba0 5b78: e28d4004 add r4, sp, #4 5b7c: e1a01000 mov r1, r0 5b80: e3a0c001 mov ip, #1 5b84: e1a00006 mov r0, r6 5b88: e3a02000 mov r2, #0 5b8c: e1a03004 mov r3, r4 5b90: e58dc000 str ip, [sp] 5b94: ebfffaf3 bl 4768 0, &loc, _STAT_FOLLOW_LINKS ); if ( status != 0 ) 5b98: e2501000 subs r1, r0, #0 5b9c: 1a00000e bne 5bdc return -1; if ( !loc.handlers->fstat_h ){ 5ba0: e59d300c ldr r3, [sp, #12] 5ba4: e5933018 ldr r3, [r3, #24] 5ba8: e3530000 cmp r3, #0 5bac: 1a00000c bne 5be4 rtems_filesystem_freenode( &loc ); 5bb0: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 5bb4: e3530000 cmp r3, #0 <== NOT EXECUTED 5bb8: 0a000004 beq 5bd0 <== NOT EXECUTED 5bbc: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 5bc0: e3530000 cmp r3, #0 <== NOT EXECUTED 5bc4: 11a00004 movne r0, r4 <== NOT EXECUTED 5bc8: 11a0e00f movne lr, pc <== NOT EXECUTED 5bcc: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 5bd0: eb00c978 bl 381b8 <__errno> <== NOT EXECUTED 5bd4: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 5bd8: e5803000 str r3, [r0] 5bdc: e3e05000 mvn r5, #0 5be0: ea000010 b 5c28 /* * Zero out the stat structure so the various support * versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) ); 5be4: e3a02048 mov r2, #72 ; 0x48 5be8: e1a00005 mov r0, r5 5bec: eb00d629 bl 3b498 status = (*loc.handlers->fstat_h)( &loc, buf ); 5bf0: e1a01005 mov r1, r5 5bf4: e59d300c ldr r3, [sp, #12] 5bf8: e1a00004 mov r0, r4 5bfc: e1a0e00f mov lr, pc 5c00: e593f018 ldr pc, [r3, #24] rtems_filesystem_freenode( &loc ); 5c04: e59d3010 ldr r3, [sp, #16] 5c08: e3530000 cmp r3, #0 * versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) ); status = (*loc.handlers->fstat_h)( &loc, buf ); 5c0c: e1a05000 mov r5, r0 rtems_filesystem_freenode( &loc ); 5c10: 0a000004 beq 5c28 5c14: e593301c ldr r3, [r3, #28] 5c18: e3530000 cmp r3, #0 5c1c: 11a00004 movne r0, r4 5c20: 11a0e00f movne lr, pc 5c24: 112fff13 bxne r3 return status; } 5c28: e1a00005 mov r0, r5 5c2c: e28dd018 add sp, sp, #24 5c30: e8bd8070 pop {r4, r5, r6, pc} 00023740 : */ extern rtems_chain_control rtems_filesystem_mount_table_control; int statvfs (const char *path, struct statvfs *sb) { 23740: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED 23744: e24dd018 sub sp, sp, #24 <== NOT EXECUTED 23748: e1a05001 mov r5, r1 <== NOT EXECUTED 2374c: e1a06000 mov r6, r0 <== NOT EXECUTED * The root node of the mounted filesytem. * The node for the directory that the fileystem is mounted on. * The mount entry that is being refered to. */ if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x0, &loc, true ) ) 23750: eb006d12 bl 3eba0 <== NOT EXECUTED 23754: e28d4004 add r4, sp, #4 <== NOT EXECUTED 23758: e1a01000 mov r1, r0 <== NOT EXECUTED 2375c: e3a0c001 mov ip, #1 <== NOT EXECUTED 23760: e1a00006 mov r0, r6 <== NOT EXECUTED 23764: e3a02000 mov r2, #0 <== NOT EXECUTED 23768: e1a03004 mov r3, r4 <== NOT EXECUTED 2376c: e58dc000 str ip, [sp] <== NOT EXECUTED 23770: ebff83fc bl 4768 <== NOT EXECUTED 23774: e2501000 subs r1, r0, #0 <== NOT EXECUTED 23778: 1a000007 bne 2379c <== NOT EXECUTED return -1; mt_entry = loc.mt_entry; 2377c: e59d6014 ldr r6, [sp, #20] <== NOT EXECUTED fs_mount_root = &mt_entry->mt_fs_root; 23780: e5963028 ldr r3, [r6, #40] ; 0x28 <== NOT EXECUTED 23784: e5933044 ldr r3, [r3, #68] ; 0x44 <== NOT EXECUTED 23788: e3530000 cmp r3, #0 <== NOT EXECUTED 2378c: 1a000004 bne 237a4 <== NOT EXECUTED if ( !fs_mount_root->ops->statvfs_h ) rtems_set_errno_and_return_minus_one( ENOTSUP ); 23790: eb005288 bl 381b8 <__errno> <== NOT EXECUTED 23794: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 23798: e5803000 str r3, [r0] <== NOT EXECUTED 2379c: e3e05000 mvn r5, #0 <== NOT EXECUTED 237a0: ea000010 b 237e8 <== NOT EXECUTED memset (sb, 0, sizeof (struct statvfs)); 237a4: e3a02038 mov r2, #56 ; 0x38 <== NOT EXECUTED 237a8: e1a00005 mov r0, r5 <== NOT EXECUTED 237ac: eb005f39 bl 3b498 <== NOT EXECUTED result = ( fs_mount_root->ops->statvfs_h )( fs_mount_root, sb ); 237b0: e1a01005 mov r1, r5 <== NOT EXECUTED 237b4: e5963028 ldr r3, [r6, #40] ; 0x28 <== NOT EXECUTED 237b8: e286001c add r0, r6, #28 <== NOT EXECUTED 237bc: e1a0e00f mov lr, pc <== NOT EXECUTED 237c0: e593f044 ldr pc, [r3, #68] ; 0x44 <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 237c4: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 237c8: e3530000 cmp r3, #0 <== NOT EXECUTED if ( !fs_mount_root->ops->statvfs_h ) rtems_set_errno_and_return_minus_one( ENOTSUP ); memset (sb, 0, sizeof (struct statvfs)); result = ( fs_mount_root->ops->statvfs_h )( fs_mount_root, sb ); 237cc: e1a05000 mov r5, r0 <== NOT EXECUTED rtems_filesystem_freenode( &loc ); 237d0: 0a000004 beq 237e8 <== NOT EXECUTED 237d4: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 237d8: e3530000 cmp r3, #0 <== NOT EXECUTED 237dc: 11a00004 movne r0, r4 <== NOT EXECUTED 237e0: 11a0e00f movne lr, pc <== NOT EXECUTED 237e4: 112fff13 bxne r3 <== NOT EXECUTED return result; } 237e8: e1a00005 mov r0, r5 <== NOT EXECUTED 237ec: e28dd018 add sp, sp, #24 <== NOT EXECUTED 237f0: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED 000237f4 : int symlink( const char *actualpath, const char *sympath ) { 237f4: e92d4070 push {r4, r5, r6, lr} rtems_filesystem_location_info_t loc; int i; const char *name_start; int result; rtems_filesystem_get_start_loc( sympath, &i, &loc ); 237f8: e5d13000 ldrb r3, [r1] 237fc: e353002f cmp r3, #47 ; 0x2f 23800: 1353005c cmpne r3, #92 ; 0x5c int symlink( const char *actualpath, const char *sympath ) { 23804: e24dd018 sub sp, sp, #24 23808: e1a05001 mov r5, r1 rtems_filesystem_location_info_t loc; int i; const char *name_start; int result; rtems_filesystem_get_start_loc( sympath, &i, &loc ); 2380c: 13a06000 movne r6, #0 23810: 03a06001 moveq r6, #1 int symlink( const char *actualpath, const char *sympath ) { 23814: e1a04000 mov r4, r0 rtems_filesystem_location_info_t loc; int i; const char *name_start; int result; rtems_filesystem_get_start_loc( sympath, &i, &loc ); 23818: 0a000001 beq 23824 2381c: e3530000 cmp r3, #0 23820: 1a000009 bne 2384c 23824: e59f30f0 ldr r3, [pc, #240] ; 2391c 23828: e593e000 ldr lr, [r3] 2382c: e28ee018 add lr, lr, #24 23830: e8be000f ldm lr!, {r0, r1, r2, r3} 23834: e1a0c00d mov ip, sp 23838: e8ac000f stmia ip!, {r0, r1, r2, r3} 2383c: e59e3000 ldr r3, [lr] 23840: e3a00001 mov r0, #1 23844: e58c3000 str r3, [ip] 23848: ea000008 b 23870 2384c: e59f30c8 ldr r3, [pc, #200] ; 2391c 23850: e593e000 ldr lr, [r3] 23854: e28ee004 add lr, lr, #4 23858: e8be000f ldm lr!, {r0, r1, r2, r3} 2385c: e1a0c00d mov ip, sp 23860: e8ac000f stmia ip!, {r0, r1, r2, r3} 23864: e59e3000 ldr r3, [lr] 23868: e58c3000 str r3, [ip] 2386c: e1a00006 mov r0, r6 if ( !loc.ops->evalformake_h ) { 23870: e59d300c ldr r3, [sp, #12] 23874: e5933004 ldr r3, [r3, #4] 23878: e3530000 cmp r3, #0 2387c: 0a000010 beq 238c4 rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->evalformake_h)( &sympath[i], &loc, &name_start ); 23880: e0850000 add r0, r5, r0 23884: e1a0100d mov r1, sp 23888: e28d2014 add r2, sp, #20 2388c: e1a0e00f mov lr, pc 23890: e12fff13 bx r3 if ( result != 0 ) 23894: e3500000 cmp r0, #0 if ( !loc.ops->evalformake_h ) { rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->evalformake_h)( &sympath[i], &loc, &name_start ); 23898: e1a0600d mov r6, sp if ( result != 0 ) 2389c: 1a00000b bne 238d0 return -1; if ( !loc.ops->symlink_h ) { 238a0: e59d200c ldr r2, [sp, #12] 238a4: e5923038 ldr r3, [r2, #56] ; 0x38 238a8: e3530000 cmp r3, #0 238ac: 1a000009 bne 238d8 rtems_filesystem_freenode( &loc ); 238b0: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 238b4: e3530000 cmp r3, #0 <== NOT EXECUTED 238b8: 11a0000d movne r0, sp <== NOT EXECUTED 238bc: 11a0e00f movne lr, pc <== NOT EXECUTED 238c0: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 238c4: eb00523b bl 381b8 <__errno> <== NOT EXECUTED 238c8: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 238cc: e5803000 str r3, [r0] <== NOT EXECUTED 238d0: e3e04000 mvn r4, #0 238d4: ea00000d b 23910 } result = (*loc.ops->symlink_h)( &loc, actualpath, name_start); 238d8: e1a01004 mov r1, r4 238dc: e1a0000d mov r0, sp 238e0: e59d2014 ldr r2, [sp, #20] 238e4: e1a0e00f mov lr, pc 238e8: e12fff13 bx r3 rtems_filesystem_freenode( &loc ); 238ec: e59d300c ldr r3, [sp, #12] 238f0: e3530000 cmp r3, #0 if ( !loc.ops->symlink_h ) { rtems_filesystem_freenode( &loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->symlink_h)( &loc, actualpath, name_start); 238f4: e1a04000 mov r4, r0 rtems_filesystem_freenode( &loc ); 238f8: 0a000004 beq 23910 238fc: e593301c ldr r3, [r3, #28] 23900: e3530000 cmp r3, #0 23904: 11a0000d movne r0, sp 23908: 11a0e00f movne lr, pc 2390c: 112fff13 bxne r3 return result; } 23910: e1a00004 mov r0, r4 23914: e28dd018 add sp, sp, #24 23918: e8bd8070 pop {r4, r5, r6, pc} 2391c: 00052578 .word 0x00052578 0000fac0 : int fd, int opt, struct termios *tp ) { switch (opt) { fac0: e3510000 cmp r1, #0 int tcsetattr( int fd, int opt, struct termios *tp ) { fac4: e92d4030 push {r4, r5, lr} fac8: e1a04002 mov r4, r2 facc: e1a05000 mov r5, r0 switch (opt) { fad0: 0a00000a beq fb00 fad4: e3510001 cmp r1, #1 <== NOT EXECUTED fad8: 0a000003 beq faec <== NOT EXECUTED default: rtems_set_errno_and_return_minus_one( ENOTSUP ); fadc: eb000ec7 bl 13600 <__errno> <== NOT EXECUTED fae0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED fae4: e5803000 str r3, [r0] <== NOT EXECUTED fae8: ea000009 b fb14 <== NOT EXECUTED case TCSADRAIN: if (ioctl( fd, RTEMS_IO_TCDRAIN, NULL ) < 0) faec: e3a01003 mov r1, #3 <== NOT EXECUTED faf0: e3a02000 mov r2, #0 <== NOT EXECUTED faf4: eb000b7d bl 128f0 <== NOT EXECUTED faf8: e3500000 cmp r0, #0 <== NOT EXECUTED fafc: ba000004 blt fb14 <== NOT EXECUTED return -1; /* * Fall through to.... */ case TCSANOW: return ioctl( fd, RTEMS_IO_SET_ATTRIBUTES, tp ); fb00: e1a00005 mov r0, r5 fb04: e1a02004 mov r2, r4 fb08: e3a01002 mov r1, #2 } } fb0c: e8bd4030 pop {r4, r5, lr} return -1; /* * Fall through to.... */ case TCSANOW: return ioctl( fd, RTEMS_IO_SET_ATTRIBUTES, tp ); fb10: ea000b76 b 128f0 } } fb14: e3e00000 mvn r0, #0 <== NOT EXECUTED fb18: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED 0000b840 : #include int unlink( const char *path ) { b840: e92d4070 push {r4, r5, r6, lr} b844: e24dd02c sub sp, sp, #44 ; 0x2c b848: e1a06000 mov r6, r0 /* * Get the node to be unlinked. Find the parent path first. */ parentpathlen = rtems_filesystem_dirname ( path ); b84c: ebffd7c2 bl 175c if ( parentpathlen == 0 ) b850: e2505000 subs r5, r0, #0 b854: 1a000019 bne b8c0 rtems_filesystem_get_start_loc( path, &i, &parentloc ); b858: e5d63000 ldrb r3, [r6] b85c: e353002f cmp r3, #47 ; 0x2f b860: 1353005c cmpne r3, #92 ; 0x5c b864: 0a000001 beq b870 b868: e3530000 cmp r3, #0 b86c: 1a000009 bne b898 b870: e59f3248 ldr r3, [pc, #584] ; bac0 b874: e593e000 ldr lr, [r3] b878: e28ee018 add lr, lr, #24 b87c: e8be000f ldm lr!, {r0, r1, r2, r3} b880: e28dc018 add ip, sp, #24 b884: e8ac000f stmia ip!, {r0, r1, r2, r3} b888: e59e3000 ldr r3, [lr] b88c: e3a04000 mov r4, #0 b890: e58c3000 str r3, [ip] b894: ea000013 b b8e8 b898: e59f3220 ldr r3, [pc, #544] ; bac0 b89c: e593e000 ldr lr, [r3] b8a0: e28ee004 add lr, lr, #4 b8a4: e8be000f ldm lr!, {r0, r1, r2, r3} b8a8: e28dc018 add ip, sp, #24 b8ac: e8ac000f stmia ip!, {r0, r1, r2, r3} b8b0: e59e3000 ldr r3, [lr] b8b4: e1a04005 mov r4, r5 b8b8: e58c3000 str r3, [ip] b8bc: ea000009 b b8e8 else { result = rtems_filesystem_evaluate_path( path, parentpathlen, b8c0: e3a0c000 mov ip, #0 b8c4: e1a00006 mov r0, r6 b8c8: e1a01005 mov r1, r5 b8cc: e3a02002 mov r2, #2 b8d0: e28d3018 add r3, sp, #24 b8d4: e58dc000 str ip, [sp] b8d8: ebffd7e7 bl 187c RTEMS_LIBIO_PERMS_WRITE, &parentloc, false ); if ( result != 0 ) b8dc: e3500000 cmp r0, #0 b8e0: 1a000072 bne bab0 b8e4: e3a04001 mov r4, #1 /* * Start from the parent to find the node that should be under it. */ loc = parentloc; b8e8: e28de018 add lr, sp, #24 b8ec: e8be000f ldm lr!, {r0, r1, r2, r3} b8f0: e28dc004 add ip, sp, #4 b8f4: e8ac000f stmia ip!, {r0, r1, r2, r3} b8f8: e59e3000 ldr r3, [lr] name = path + parentpathlen; b8fc: e0865005 add r5, r6, r5 /* * Start from the parent to find the node that should be under it. */ loc = parentloc; b900: e58c3000 str r3, [ip] name = path + parentpathlen; name += rtems_filesystem_prefix_separators( name, strlen( name ) ); b904: e1a00005 mov r0, r5 b908: eb000481 bl cb14 b90c: e1a01000 mov r1, r0 b910: e1a00005 mov r0, r5 b914: ebffd784 bl 172c b918: e0856000 add r6, r5, r0 result = rtems_filesystem_evaluate_relative_path( name , strlen( name ), b91c: e1a00006 mov r0, r6 b920: eb00047b bl cb14 b924: e28d5004 add r5, sp, #4 b928: e3a0c000 mov ip, #0 b92c: e1a01000 mov r1, r0 b930: e1a0200c mov r2, ip b934: e1a00006 mov r0, r6 b938: e1a03005 mov r3, r5 b93c: e58dc000 str ip, [sp] b940: ebffd795 bl 179c 0, &loc, false ); if ( result != 0 ) { b944: e3500000 cmp r0, #0 b948: 0a00000b beq b97c if ( free_parentloc ) b94c: e3540000 cmp r4, #0 b950: 0a000056 beq bab0 rtems_filesystem_freenode( &parentloc ); b954: e59d3024 ldr r3, [sp, #36] ; 0x24 b958: e3530000 cmp r3, #0 b95c: 0a000053 beq bab0 b960: e593301c ldr r3, [r3, #28] b964: e3530000 cmp r3, #0 b968: 0a000050 beq bab0 b96c: e28d0018 add r0, sp, #24 b970: e1a0e00f mov lr, pc b974: e12fff13 bx r3 b978: ea00004c b bab0 return -1; } if ( !loc.ops->node_type_h ) { b97c: e59d2010 ldr r2, [sp, #16] b980: e5923010 ldr r3, [r2, #16] b984: e3530000 cmp r3, #0 b988: 0a00001c beq ba00 if ( free_parentloc ) rtems_filesystem_freenode( &parentloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } if ( (*loc.ops->node_type_h)( &loc ) == RTEMS_FILESYSTEM_DIRECTORY ) { b98c: e1a00005 mov r0, r5 b990: e1a0e00f mov lr, pc b994: e12fff13 bx r3 b998: e3500001 cmp r0, #1 b99c: e59d2010 ldr r2, [sp, #16] b9a0: 1a000013 bne b9f4 rtems_filesystem_freenode( &loc ); b9a4: e3520000 cmp r2, #0 b9a8: 0a000004 beq b9c0 b9ac: e592301c ldr r3, [r2, #28] b9b0: e3530000 cmp r3, #0 b9b4: 11a00005 movne r0, r5 b9b8: 11a0e00f movne lr, pc b9bc: 112fff13 bxne r3 if ( free_parentloc ) b9c0: e3540000 cmp r4, #0 b9c4: 0a000007 beq b9e8 rtems_filesystem_freenode( &parentloc ); b9c8: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED b9cc: e3530000 cmp r3, #0 <== NOT EXECUTED b9d0: 0a000004 beq b9e8 <== NOT EXECUTED b9d4: e593301c ldr r3, [r3, #28] <== NOT EXECUTED b9d8: e3530000 cmp r3, #0 <== NOT EXECUTED b9dc: 128d0018 addne r0, sp, #24 <== NOT EXECUTED b9e0: 11a0e00f movne lr, pc <== NOT EXECUTED b9e4: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EISDIR ); b9e8: eb000058 bl bb50 <__errno> b9ec: e3a03015 mov r3, #21 b9f0: ea000013 b ba44 } if ( !loc.ops->unlink_h ) { b9f4: e592300c ldr r3, [r2, #12] b9f8: e3530000 cmp r3, #0 b9fc: 1a000012 bne ba4c rtems_filesystem_freenode( &loc ); ba00: e592301c ldr r3, [r2, #28] <== NOT EXECUTED ba04: e3530000 cmp r3, #0 <== NOT EXECUTED ba08: 11a00005 movne r0, r5 <== NOT EXECUTED ba0c: 11a0e00f movne lr, pc <== NOT EXECUTED ba10: 112fff13 bxne r3 <== NOT EXECUTED if ( free_parentloc ) ba14: e3540000 cmp r4, #0 <== NOT EXECUTED ba18: 0a000007 beq ba3c <== NOT EXECUTED rtems_filesystem_freenode( &parentloc ); ba1c: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED ba20: e3530000 cmp r3, #0 <== NOT EXECUTED ba24: 0a000004 beq ba3c <== NOT EXECUTED ba28: e593301c ldr r3, [r3, #28] <== NOT EXECUTED ba2c: e3530000 cmp r3, #0 <== NOT EXECUTED ba30: 128d0018 addne r0, sp, #24 <== NOT EXECUTED ba34: 11a0e00f movne lr, pc <== NOT EXECUTED ba38: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); ba3c: eb000043 bl bb50 <__errno> <== NOT EXECUTED ba40: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED ba44: e5803000 str r3, [r0] ba48: ea000018 b bab0 } result = (*loc.ops->unlink_h)( &parentloc, &loc ); ba4c: e28d0018 add r0, sp, #24 ba50: e1a01005 mov r1, r5 ba54: e1a0e00f mov lr, pc ba58: e12fff13 bx r3 rtems_filesystem_freenode( &loc ); ba5c: e59d3010 ldr r3, [sp, #16] ba60: e3530000 cmp r3, #0 if ( free_parentloc ) rtems_filesystem_freenode( &parentloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->unlink_h)( &parentloc, &loc ); ba64: e1a06000 mov r6, r0 rtems_filesystem_freenode( &loc ); ba68: 0a000004 beq ba80 ba6c: e593301c ldr r3, [r3, #28] ba70: e3530000 cmp r3, #0 ba74: 11a00005 movne r0, r5 ba78: 11a0e00f movne lr, pc ba7c: 112fff13 bxne r3 if ( free_parentloc ) ba80: e3540000 cmp r4, #0 ba84: 0a00000a beq bab4 rtems_filesystem_freenode( &parentloc ); ba88: e59d3024 ldr r3, [sp, #36] ; 0x24 ba8c: e3530000 cmp r3, #0 ba90: 0a000007 beq bab4 ba94: e593301c ldr r3, [r3, #28] ba98: e3530000 cmp r3, #0 ba9c: 0a000004 beq bab4 baa0: e28d0018 add r0, sp, #24 baa4: e1a0e00f mov lr, pc baa8: e12fff13 bx r3 baac: ea000000 b bab4 bab0: e3e06000 mvn r6, #0 return result; } bab4: e1a00006 mov r0, r6 bab8: e28dd02c add sp, sp, #44 ; 0x2c babc: e8bd8070 pop {r4, r5, r6, pc} bac0: 00017718 .word 0x00017718 00023a04 : */ int unmount( const char *path ) { 23a04: e92d4030 push {r4, r5, lr} 23a08: e24dd018 sub sp, sp, #24 23a0c: e1a05000 mov r5, r0 * The root node of the mounted filesytem. * The node for the directory that the fileystem is mounted on. * The mount entry that is being refered to. */ if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x0, &loc, true ) ) 23a10: eb006c62 bl 3eba0 23a14: e28d4004 add r4, sp, #4 23a18: e1a01000 mov r1, r0 23a1c: e3a0c001 mov ip, #1 23a20: e1a00005 mov r0, r5 23a24: e3a02000 mov r2, #0 23a28: e1a03004 mov r3, r4 23a2c: e58dc000 str ip, [sp] 23a30: ebff834c bl 4768 23a34: e3500000 cmp r0, #0 23a38: 1a000057 bne 23b9c return -1; mt_entry = loc.mt_entry; 23a3c: e59d5014 ldr r5, [sp, #20] fs_mount_loc = &mt_entry->mt_point_node; fs_root_loc = &mt_entry->mt_fs_root; 23a40: e59d3004 ldr r3, [sp, #4] 23a44: e595201c ldr r2, [r5, #28] 23a48: e1520003 cmp r2, r3 23a4c: e59d3010 ldr r3, [sp, #16] 23a50: 0a000009 beq 23a7c /* * Verify this is the root node for the file system to be unmounted. */ if ( !rtems_filesystem_nodes_equal( fs_root_loc, &loc) ){ rtems_filesystem_freenode( &loc ); 23a54: e3530000 cmp r3, #0 23a58: 0a000004 beq 23a70 23a5c: e593301c ldr r3, [r3, #28] 23a60: e3530000 cmp r3, #0 23a64: 11a00004 movne r0, r4 23a68: 11a0e00f movne lr, pc 23a6c: 112fff13 bxne r3 rtems_set_errno_and_return_minus_one( EACCES ); 23a70: eb0051d0 bl 381b8 <__errno> 23a74: e3a0300d mov r3, #13 23a78: ea000023 b 23b0c /* * Free the loc node and just use the nodes from the mt_entry . */ rtems_filesystem_freenode( &loc ); 23a7c: e3530000 cmp r3, #0 23a80: 0a000004 beq 23a98 23a84: e593301c ldr r3, [r3, #28] 23a88: e3530000 cmp r3, #0 23a8c: 11a00004 movne r0, r4 23a90: 11a0e00f movne lr, pc 23a94: 112fff13 bxne r3 if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x0, &loc, true ) ) return -1; mt_entry = loc.mt_entry; fs_mount_loc = &mt_entry->mt_point_node; 23a98: e5953014 ldr r3, [r5, #20] 23a9c: e5933028 ldr r3, [r3, #40] ; 0x28 23aa0: e3530000 cmp r3, #0 23aa4: 0a000003 beq 23ab8 fs_root_loc = &mt_entry->mt_fs_root; 23aa8: e5953028 ldr r3, [r5, #40] ; 0x28 23aac: e593302c ldr r3, [r3, #44] ; 0x2c 23ab0: e3530000 cmp r3, #0 23ab4: 1a000002 bne 23ac4 if ( !fs_mount_loc->ops->unmount_h ) rtems_set_errno_and_return_minus_one( ENOTSUP ); if ( !fs_root_loc->ops->fsunmount_me_h ) rtems_set_errno_and_return_minus_one( ENOTSUP ); 23ab8: eb0051be bl 381b8 <__errno> <== NOT EXECUTED 23abc: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 23ac0: ea000011 b 23b0c <== NOT EXECUTED * that made the current node thread based instead * of system based? I thought it was but it doesn't * look like it in this version. */ if ( rtems_filesystem_current.mt_entry == mt_entry ) 23ac4: e59f30f0 ldr r3, [pc, #240] ; 23bbc 23ac8: e5933000 ldr r3, [r3] 23acc: e5933014 ldr r3, [r3, #20] 23ad0: e1530005 cmp r3, r5 /* * Search the mount table for any mount entries referencing this * mount entry. */ for ( the_node = rtems_filesystem_mount_table_control.first; 23ad4: 159f20e4 ldrne r2, [pc, #228] ; 23bc0 23ad8: 14923004 ldrne r3, [r2], #4 * that made the current node thread based instead * of system based? I thought it was but it doesn't * look like it in this version. */ if ( rtems_filesystem_current.mt_entry == mt_entry ) 23adc: 1a000005 bne 23af8 23ae0: ea000007 b 23b04 if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x0, &loc, true ) ) return -1; mt_entry = loc.mt_entry; fs_mount_loc = &mt_entry->mt_point_node; fs_root_loc = &mt_entry->mt_fs_root; 23ae4: e5930018 ldr r0, [r3, #24] 23ae8: e595102c ldr r1, [r5, #44] ; 0x2c 23aec: e1500001 cmp r0, r1 23af0: 0a000003 beq 23b04 * mount entry. */ for ( the_node = rtems_filesystem_mount_table_control.first; !rtems_chain_is_tail( &rtems_filesystem_mount_table_control, the_node ); the_node = the_node->next ) { 23af4: e5933000 ldr r3, [r3] 23af8: e1530002 cmp r3, r2 23afc: 1afffff8 bne 23ae4 23b00: ea000028 b 23ba8 * descriptors that are currently active and reference nodes in the * file system that we are trying to unmount */ if ( rtems_libio_is_open_files_in_fs( mt_entry ) == 1 ) rtems_set_errno_and_return_minus_one( EBUSY ); 23b04: eb0051ab bl 381b8 <__errno> 23b08: e3a03010 mov r3, #16 23b0c: e5803000 str r3, [r0] 23b10: ea000021 b 23b9c * Allow the file system being unmounted on to do its cleanup. * If it fails it will set the errno to the approprate value * and the fileystem will not be modified. */ if (( fs_mount_loc->ops->unmount_h )( mt_entry ) != 0 ) 23b14: e5953014 ldr r3, [r5, #20] 23b18: e1a00005 mov r0, r5 23b1c: e1a0e00f mov lr, pc 23b20: e593f028 ldr pc, [r3, #40] ; 0x28 23b24: e2504000 subs r4, r0, #0 23b28: 1a00001b bne 23b9c * NOTE: Fatal error is called in a case which should never happen * This was response was questionable but the best we could * come up with. */ if ((fs_root_loc->ops->fsunmount_me_h )( mt_entry ) != 0){ 23b2c: e5953028 ldr r3, [r5, #40] ; 0x28 23b30: e1a00005 mov r0, r5 23b34: e1a0e00f mov lr, pc 23b38: e593f02c ldr pc, [r3, #44] ; 0x2c 23b3c: e3500000 cmp r0, #0 23b40: 0a000007 beq 23b64 if (( fs_mount_loc->ops->mount_h )( mt_entry ) != 0 ) 23b44: e1a00005 mov r0, r5 <== NOT EXECUTED 23b48: e5953014 ldr r3, [r5, #20] <== NOT EXECUTED 23b4c: e1a0e00f mov lr, pc <== NOT EXECUTED 23b50: e593f020 ldr pc, [r3, #32] <== NOT EXECUTED 23b54: e3500000 cmp r0, #0 <== NOT EXECUTED 23b58: 0a00000f beq 23b9c <== NOT EXECUTED rtems_fatal_error_occurred( 0 ); 23b5c: e1a00004 mov r0, r4 <== NOT EXECUTED 23b60: ebff93f7 bl 8b44 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node ); 23b64: e1a00005 mov r0, r5 23b68: ebff94a8 bl 8e10 <_Chain_Extract> /* * Free the memory node that was allocated in mount * Free the memory associated with the extracted mount table entry. */ rtems_filesystem_freenode( fs_mount_loc ); 23b6c: e5953014 ldr r3, [r5, #20] 23b70: e3530000 cmp r3, #0 23b74: 0a000004 beq 23b8c 23b78: e593301c ldr r3, [r3, #28] 23b7c: e3530000 cmp r3, #0 23b80: 12850008 addne r0, r5, #8 23b84: 11a0e00f movne lr, pc 23b88: 112fff13 bxne r3 free( mt_entry ); 23b8c: e1a00005 mov r0, r5 23b90: ebff8327 bl 4834 23b94: e3a00000 mov r0, #0 return 0; 23b98: ea000000 b 23ba0 23b9c: e3e00000 mvn r0, #0 } 23ba0: e28dd018 add sp, sp, #24 23ba4: e8bd8030 pop {r4, r5, pc} * Run the file descriptor table to determine if there are any file * descriptors that are currently active and reference nodes in the * file system that we are trying to unmount */ if ( rtems_libio_is_open_files_in_fs( mt_entry ) == 1 ) 23ba8: e1a00005 mov r0, r5 23bac: ebff83d1 bl 4af8 23bb0: e3500001 cmp r0, #1 23bb4: 1affffd6 bne 23b14 23bb8: eaffffd1 b 23b04 23bbc: 00052578 .word 0x00052578 23bc0: 0005fc14 .word 0x0005fc14 00023bc4 : int utime( const char *path, const struct utimbuf *times ) { 23bc4: e92d4070 push {r4, r5, r6, lr} 23bc8: e24dd018 sub sp, sp, #24 23bcc: e1a05001 mov r5, r1 23bd0: e1a06000 mov r6, r0 rtems_filesystem_location_info_t temp_loc; int result; if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x00, &temp_loc, true ) ) 23bd4: eb006bf1 bl 3eba0 23bd8: e28d4004 add r4, sp, #4 23bdc: e1a01000 mov r1, r0 23be0: e3a0c001 mov ip, #1 23be4: e1a00006 mov r0, r6 23be8: e3a02000 mov r2, #0 23bec: e1a03004 mov r3, r4 23bf0: e58dc000 str ip, [sp] 23bf4: ebff82db bl 4768 23bf8: e3500000 cmp r0, #0 23bfc: 1a00000b bne 23c30 return -1; if ( !temp_loc.ops->utime_h ){ 23c00: e59d2010 ldr r2, [sp, #16] 23c04: e5923030 ldr r3, [r2, #48] ; 0x30 23c08: e3530000 cmp r3, #0 23c0c: 1a000009 bne 23c38 rtems_filesystem_freenode( &temp_loc ); 23c10: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 23c14: e3530000 cmp r3, #0 <== NOT EXECUTED 23c18: 11a00004 movne r0, r4 <== NOT EXECUTED 23c1c: 11a0e00f movne lr, pc <== NOT EXECUTED 23c20: 112fff13 bxne r3 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOTSUP ); 23c24: eb005163 bl 381b8 <__errno> <== NOT EXECUTED 23c28: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 23c2c: e5803000 str r3, [r0] <== NOT EXECUTED 23c30: e3e05000 mvn r5, #0 23c34: ea00000c b 23c6c } result = (*temp_loc.ops->utime_h)( &temp_loc, times->actime, times->modtime ); 23c38: e8950006 ldm r5, {r1, r2} 23c3c: e1a00004 mov r0, r4 23c40: e1a0e00f mov lr, pc 23c44: e12fff13 bx r3 rtems_filesystem_freenode( &temp_loc ); 23c48: e59d3010 ldr r3, [sp, #16] 23c4c: e3530000 cmp r3, #0 if ( !temp_loc.ops->utime_h ){ rtems_filesystem_freenode( &temp_loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*temp_loc.ops->utime_h)( &temp_loc, times->actime, times->modtime ); 23c50: e1a05000 mov r5, r0 rtems_filesystem_freenode( &temp_loc ); 23c54: 0a000004 beq 23c6c 23c58: e593301c ldr r3, [r3, #28] 23c5c: e3530000 cmp r3, #0 23c60: 11a00004 movne r0, r4 23c64: 11a0e00f movne lr, pc 23c68: 112fff13 bxne r3 return result; } 23c6c: e1a00005 mov r0, r5 23c70: e28dd018 add sp, sp, #24 23c74: e8bd8070 pop {r4, r5, r6, pc} 00016ef8 : ) { ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd ); 16ef8: e59f30b0 ldr r3, [pc, #176] ; 16fb0 16efc: e5933000 ldr r3, [r3] 16f00: e1500003 cmp r0, r3 ssize_t write( int fd, const void *buffer, size_t count ) { 16f04: e92d4070 push {r4, r5, r6, lr} 16f08: e1a05001 mov r5, r1 ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd ); 16f0c: 2a000005 bcs 16f28 iop = rtems_libio_iop( fd ); 16f10: e59f309c ldr r3, [pc, #156] ; 16fb4 16f14: e5934000 ldr r4, [r3] 16f18: e0844300 add r4, r4, r0, lsl #6 rtems_libio_check_is_open( iop ); 16f1c: e5943014 ldr r3, [r4, #20] 16f20: e3130c01 tst r3, #256 ; 0x100 16f24: 1a000002 bne 16f34 16f28: ebffd308 bl bb50 <__errno> <== NOT EXECUTED 16f2c: e3a03009 mov r3, #9 <== NOT EXECUTED 16f30: ea00000f b 16f74 <== NOT EXECUTED rtems_libio_check_buffer( buffer ); 16f34: e3510000 cmp r1, #0 16f38: 0a000004 beq 16f50 rtems_libio_check_count( count ); 16f3c: e3520000 cmp r2, #0 16f40: 01a00002 moveq r0, r2 16f44: 08bd8070 popeq {r4, r5, r6, pc} rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE ); 16f48: e3130004 tst r3, #4 16f4c: 1a000002 bne 16f5c 16f50: ebffd2fe bl bb50 <__errno> <== NOT EXECUTED 16f54: e3a03016 mov r3, #22 <== NOT EXECUTED 16f58: ea000005 b 16f74 <== NOT EXECUTED /* * Now process the write() request. */ if ( !iop->handlers->write_h ) 16f5c: e594303c ldr r3, [r4, #60] ; 0x3c 16f60: e593300c ldr r3, [r3, #12] 16f64: e3530000 cmp r3, #0 16f68: 1a000004 bne 16f80 rtems_set_errno_and_return_minus_one( ENOTSUP ); 16f6c: ebffd2f7 bl bb50 <__errno> <== NOT EXECUTED 16f70: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 16f74: e5803000 str r3, [r0] <== NOT EXECUTED 16f78: e3e00000 mvn r0, #0 <== NOT EXECUTED 16f7c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED rc = (*iop->handlers->write_h)( iop, buffer, count ); 16f80: e1a00004 mov r0, r4 16f84: e1a0e00f mov lr, pc 16f88: e12fff13 bx r3 if ( rc > 0 ) 16f8c: e3500000 cmp r0, #0 16f90: d8bd8070 pople {r4, r5, r6, pc} iop->offset += rc; 16f94: e284600c add r6, r4, #12 16f98: e8960060 ldm r6, {r5, r6} 16f9c: e0952000 adds r2, r5, r0 16fa0: e0a63fc0 adc r3, r6, r0, asr #31 16fa4: e584200c str r2, [r4, #12] 16fa8: e5843010 str r3, [r4, #16] return rc; } 16fac: e8bd8070 pop {r4, r5, r6, pc} 16fb0: 00017580 .word 0x00017580 16fb4: 00018cb0 .word 0x00018cb0 00005a88 : int bytes; rtems_libio_t *iop; ssize_t old; bool all_zeros; rtems_libio_check_fd( fd ); 5a88: e59f3164 ldr r3, [pc, #356] ; 5bf4 5a8c: e5933000 ldr r3, [r3] 5a90: e1500003 cmp r0, r3 ssize_t writev( int fd, const struct iovec *iov, int iovcnt ) { 5a94: e92d49f0 push {r4, r5, r6, r7, r8, fp, lr} 5a98: e1a08002 mov r8, r2 int bytes; rtems_libio_t *iop; ssize_t old; bool all_zeros; rtems_libio_check_fd( fd ); 5a9c: 2a000005 bcs 5ab8 iop = rtems_libio_iop( fd ); 5aa0: e59f3150 ldr r3, [pc, #336] ; 5bf8 5aa4: e5936000 ldr r6, [r3] 5aa8: e0866300 add r6, r6, r0, lsl #6 rtems_libio_check_is_open( iop ); 5aac: e5963014 ldr r3, [r6, #20] 5ab0: e3130c01 tst r3, #256 ; 0x100 5ab4: 1a000002 bne 5ac4 5ab8: eb002142 bl dfc8 <__errno> 5abc: e3a03009 mov r3, #9 5ac0: ea000025 b 5b5c rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE ); 5ac4: e3130004 tst r3, #4 5ac8: 0a000021 beq 5b54 /* * Argument validation on IO vector */ if ( !iov ) 5acc: e3510000 cmp r1, #0 5ad0: 0a00001f beq 5b54 rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt <= 0 ) 5ad4: e3520000 cmp r2, #0 5ad8: da00001d ble 5b54 rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt > IOV_MAX ) 5adc: e3520b01 cmp r2, #1024 ; 0x400 5ae0: ca00001b bgt 5b54 rtems_set_errno_and_return_minus_one( EINVAL ); if ( !iop->handlers->write_h ) 5ae4: e596303c ldr r3, [r6, #60] ; 0x3c 5ae8: e593300c ldr r3, [r3, #12] 5aec: e3530000 cmp r3, #0 5af0: 1a000002 bne 5b00 rtems_set_errno_and_return_minus_one( ENOTSUP ); 5af4: eb002133 bl dfc8 <__errno> <== NOT EXECUTED 5af8: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 5afc: ea000016 b 5b5c <== NOT EXECUTED 5b00: e3a03000 mov r3, #0 all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len; if ( total < old || total > SSIZE_MAX ) 5b04: e59fc0f0 ldr ip, [pc, #240] ; 5bfc if ( iovcnt > IOV_MAX ) rtems_set_errno_and_return_minus_one( EINVAL ); if ( !iop->handlers->write_h ) rtems_set_errno_and_return_minus_one( ENOTSUP ); 5b08: e1a05001 mov r5, r1 5b0c: e1a02001 mov r2, r1 5b10: e3a07001 mov r7, #1 5b14: e1a04003 mov r4, r3 * entering the write loop. */ all_zeros = true; for ( old=0, total=0, v=0 ; v < iovcnt ; v++ ) { if ( !iov[v].iov_base ) 5b18: e5921000 ldr r1, [r2] 5b1c: e3510000 cmp r1, #0 * this loop does that check as well and sets "all-zero" appropriately. * The variable "all_zero" is used as an early exit point before * entering the write loop. */ all_zeros = true; for ( old=0, total=0, v=0 ; v < iovcnt ; v++ ) { 5b20: e2833001 add r3, r3, #1 if ( !iov[v].iov_base ) 5b24: 0a00000a beq 5b54 rtems_set_errno_and_return_minus_one( EINVAL ); if ( iov[v].iov_len < 0 ) rtems_set_errno_and_return_minus_one( EINVAL ); if ( iov[v].iov_len ) 5b28: e5920004 ldr r0, [r2, #4] all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len; 5b2c: e0841000 add r1, r4, r0 if ( total < old || total > SSIZE_MAX ) 5b30: e1510004 cmp r1, r4 5b34: a3a04000 movge r4, #0 5b38: b3a04001 movlt r4, #1 5b3c: e151000c cmp r1, ip 5b40: c3844001 orrgt r4, r4, #1 rtems_set_errno_and_return_minus_one( EINVAL ); if ( iov[v].iov_len < 0 ) rtems_set_errno_and_return_minus_one( EINVAL ); if ( iov[v].iov_len ) 5b44: e3500000 cmp r0, #0 5b48: 13a07000 movne r7, #0 all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len; if ( total < old || total > SSIZE_MAX ) 5b4c: e3540000 cmp r4, #0 5b50: 0a000003 beq 5b64 rtems_set_errno_and_return_minus_one( EINVAL ); 5b54: eb00211b bl dfc8 <__errno> 5b58: e3a03016 mov r3, #22 5b5c: e5803000 str r3, [r0] 5b60: ea000011 b 5bac * this loop does that check as well and sets "all-zero" appropriately. * The variable "all_zero" is used as an early exit point before * entering the write loop. */ all_zeros = true; for ( old=0, total=0, v=0 ; v < iovcnt ; v++ ) { 5b64: e1530008 cmp r3, r8 5b68: e2822008 add r2, r2, #8 5b6c: b1a04001 movlt r4, r1 5b70: baffffe8 blt 5b18 } /* * A writev with all zeros is supposed to have no effect per OpenGroup. */ if ( all_zeros == true ) { 5b74: e3570000 cmp r7, #0 5b78: 1a00001b bne 5bec 5b7c: e1a04007 mov r4, r7 /* * Now process the writev(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) { /* all zero lengths has no effect */ if ( iov[v].iov_len == 0 ) 5b80: e5952004 ldr r2, [r5, #4] 5b84: e3520000 cmp r2, #0 } /* * Now process the writev(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) { 5b88: e2877001 add r7, r7, #1 /* all zero lengths has no effect */ if ( iov[v].iov_len == 0 ) 5b8c: 0a000013 beq 5be0 continue; bytes = (*iop->handlers->write_h)( iop, iov[v].iov_base, iov[v].iov_len ); 5b90: e5951000 ldr r1, [r5] 5b94: e596303c ldr r3, [r6, #60] ; 0x3c 5b98: e1a00006 mov r0, r6 5b9c: e1a0e00f mov lr, pc 5ba0: e593f00c ldr pc, [r3, #12] if ( bytes < 0 ) 5ba4: e3500000 cmp r0, #0 5ba8: aa000001 bge 5bb4 5bac: e3e04000 mvn r4, #0 5bb0: ea00000d b 5bec return -1; if ( bytes > 0 ) { 5bb4: 0a000006 beq 5bd4 iop->offset += bytes; 5bb8: e286c00c add ip, r6, #12 5bbc: e89c1800 ldm ip, {fp, ip} 5bc0: e09b2000 adds r2, fp, r0 5bc4: e0ac3fc0 adc r3, ip, r0, asr #31 5bc8: e586200c str r2, [r6, #12] 5bcc: e5863010 str r3, [r6, #16] total += bytes; 5bd0: e0844000 add r4, r4, r0 } if (bytes != iov[ v ].iov_len) 5bd4: e5953004 ldr r3, [r5, #4] 5bd8: e1500003 cmp r0, r3 5bdc: 1a000002 bne 5bec } /* * Now process the writev(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) { 5be0: e1570008 cmp r7, r8 5be4: e2855008 add r5, r5, #8 5be8: baffffe4 blt 5b80 if (bytes != iov[ v ].iov_len) break; } return total; } 5bec: e1a00004 mov r0, r4 5bf0: e8bd89f0 pop {r4, r5, r6, r7, r8, fp, pc} 5bf4: 0001b250 .word 0x0001b250 5bf8: 0001ddc4 .word 0x0001ddc4 5bfc: 00007fff .word 0x00007fff